Uploaded image for project: 'SonarJava'
  1. SonarJava
  2. SONARJAVA-3805

Rule S5332 should support okhttp library

    XMLWordPrintable

    Details

    • Type: Improvement
    • Status: Closed
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: 6.15.1
    • Component/s: Rules
    • Labels:

      Description

      Should raise an issue when ConnectionSpec.CLEARTEXT is used as argument of these functions:

      • connectionSpecs() expect a list / array of connectionspec symbols, as soon as CLEARTEXT is found we should raise:
        OkHttpClient client1 = new OkHttpClient.Builder()
          .connectionSpecs(Arrays.asList(ConnectionSpec.MODERN_TLS, ConnectionSpec.CLEARTEXT)) // Noncompliant (s5332)
          .build();
        
      • Builder():
          
        ConnectionSpec spec = new ConnectionSpec.Builder(ConnectionSpec.CLEARTEXT) // Noncompliant (s5332)
          .build();
        

        Attachments

          Issue Links

            Activity

              People

              Assignee:
              quentin.jaquier Quentin Jaquier
              Reporter:
              eric.therond Eric Therond
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

                Dates

                Due:
                Created:
                Updated:
                Resolved: