Uploaded image for project: 'JBoss Enterprise Application Platform'
  1. JBoss Enterprise Application Platform
  2. JBEAP-7924

Coverity: wrong condition in ProviderLoaderService.unregisterProviders (Elytron subsystem)

    XMLWordPrintable

Details

    • Bug
    • Resolution: Done
    • Critical
    • 7.1.0.DR11
    • 7.1.0.DR9
    • Security
    • None

    Description

      Coverity static-analysis scan found an issue in a loop within the ProviderLoaderService.unregisterProviders method.

      https://scan7.coverity.com/reports.htm#v16159/p12663/fileInstanceId=6892104&defectInstanceId=1794523&mergedDefectId=1388480&fileStart=1&fileEnd=250
      The condition is wrong in the code

      for (int i = providers.length - 1; i < 0; i--) {
          Security.removeProvider(providers[i].getName());
      }
      

      There should be i >= 0 instead of i < 0.

      Attachments

        Issue Links

          Activity

            People

              rhn-support-ivassile Ilia Vassilev
              josef.cacek@gmail.com Josef Cacek (Inactive)
              Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: