Uploaded image for project: 'WildFly Elytron'
  1. WildFly Elytron
  2. ELY-960

Coverity static analysis: Suspicious integer expression in BSDUnixDESCryptPasswordImpl (Elytron)

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Done
    • Icon: Major Major
    • 1.1.0.Beta29
    • 1.1.0.Beta24
    • Passwords
    • None

      Seems if statement will never be true, because invKeyPerm is of type byte[]. And permitted values for byte are -128...127.

      BSDUnixDESCryptPasswordImpl.java
      outBit = invKeyPerm[inBit];
      if (outBit == 255) {
          continue;
      }
      

      https://scan7.coverity.com/reports.htm#v23632/p11778/fileInstanceId=8553812&defectInstanceId=2138962&mergedDefectId=1377479&fileStart=1&fileEnd=250

              rhn-support-ivassile Ilia Vassilev
              mchoma@redhat.com Martin Choma
              Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

                Created:
                Updated:
                Resolved: