]> source.dussan.org Git - sonarqube.git/commitdiff
SONAR-17061 add support for PCI DSS requirements name with paragraph letters
authorMatteo Mara <matteo.mara@sonarsource.com>
Sun, 24 Jul 2022 22:23:48 +0000 (00:23 +0200)
committersonartech <sonartech@sonarsource.com>
Mon, 25 Jul 2022 20:03:58 +0000 (20:03 +0000)
plugins/sonar-xoo-plugin/src/main/java/org/sonar/xoo/rule/XooRulesDefinition.java

index 3d87a2cbb16ec573b4731b3ff24dca2ff2fc6340..8da47aa22f59a8abf8804ef8f9569a5d4663f213 100644 (file)
@@ -48,7 +48,7 @@ import static org.sonar.api.server.rule.RulesDefinition.OwaspTop10Version.Y2021;
  */
 public class XooRulesDefinition implements RulesDefinition {
 
-  public static final String[] AVAILABLE_CONTEXTS = { "JavaScript", "JQuery", "Express.js", "React", "Axios" };
+  public static final String[] AVAILABLE_CONTEXTS = {"JavaScript", "JQuery", "Express.js", "React", "Axios"};
 
   public static final String XOO_REPOSITORY = "xoo";
   public static final String XOO2_REPOSITORY = "xoo2";
@@ -240,11 +240,15 @@ public class XooRulesDefinition implements RulesDefinition {
     if (version != null && version.isGreaterThanOrEqual(Version.create(9, 5))) {
       hotspot
         .addPciDss(PciDssVersion.V4_0, "6.5.1", "4.1")
-        .addPciDss(PciDssVersion.V3_2, "6.5.1", "4.2");
+        .addPciDss(PciDssVersion.V3_2, "6.5.1", "4.2")
+        .addPciDss(PciDssVersion.V4_0, "6.5a.1", "4.2c")
+        .addPciDss(PciDssVersion.V3_2, "6.5a.1b", "4.2b");
 
       oneVulnerabilityIssuePerModule
         .addPciDss(PciDssVersion.V4_0, "10.1")
-        .addPciDss(PciDssVersion.V3_2, "10.2");
+        .addPciDss(PciDssVersion.V3_2, "10.2")
+        .addPciDss(PciDssVersion.V4_0, "10.1a.2b")
+        .addPciDss(PciDssVersion.V3_2, "10.1a.2c");
     }
 
     NewRule hotspotWithContexts = repo.createRule(HotspotWithContextsSensor.RULE_KEY)