aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorPierre Guillot <pierre.guillot@sonarsource.com>2019-05-10 09:40:58 +0200
committerSonarTech <sonartech@sonarsource.com>2019-05-22 20:21:15 +0200
commitcb3d8324f859cf5733646616e1e20efbd07ffebb (patch)
treee75afe2d8b3190c25c9596f26bc96e232904f315
parentea8bc156195d95eef947ff49dd4d2535a3c56d26 (diff)
downloadsonarqube-cb3d8324f859cf5733646616e1e20efbd07ffebb.tar.gz
sonarqube-cb3d8324f859cf5733646616e1e20efbd07ffebb.zip
SONAR-12026 add transition reset as to review
-rw-r--r--server/sonar-server-common/src/main/java/org/sonar/server/issue/workflow/IssueWorkflow.java49
-rw-r--r--server/sonar-server-common/src/test/java/org/sonar/server/issue/workflow/IssueWorkflowForSecurityHotspotsTest.java152
-rw-r--r--server/sonar-server/src/main/java/org/sonar/server/issue/ws/DoTransitionAction.java3
-rw-r--r--server/sonar-server/src/test/java/org/sonar/server/issue/ws/BulkChangeActionTest.java2
-rw-r--r--server/sonar-server/src/test/resources/com/sonar/governance/securityreport/ws/ShowActionTest/empty.json22
-rw-r--r--server/sonar-server/src/test/resources/com/sonar/governance/securityreport/ws/ShowActionTest/owaspNoCwe.json22
-rw-r--r--server/sonar-server/src/test/resources/com/sonar/governance/securityreport/ws/ShowActionTest/sansWithCwe.json8
-rw-r--r--server/sonar-server/src/test/resources/com/sonar/governance/securityreport/ws/ShowActionTest/sonarsourceSecurityNoCwe.json40
-rw-r--r--server/sonar-server/src/test/resources/com/sonar/governance/securityreport/ws/ShowActionTest/sonarsourceSecurityOnApplication.json42
-rw-r--r--server/sonar-server/src/test/resources/com/sonar/governance/securityreport/ws/ShowActionTest/sonarsourceSecurityWithCwe.json42
-rw-r--r--sonar-core/src/main/resources/org/sonar/l10n/core.properties22
-rw-r--r--sonar-plugin-api/src/main/java/org/sonar/api/issue/DefaultTransitions.java17
-rw-r--r--sonar-ws/src/main/protobuf/ws-security.proto4
13 files changed, 225 insertions, 200 deletions
diff --git a/server/sonar-server-common/src/main/java/org/sonar/server/issue/workflow/IssueWorkflow.java b/server/sonar-server-common/src/main/java/org/sonar/server/issue/workflow/IssueWorkflow.java
index 4304fb721c8..eca4e74b473 100644
--- a/server/sonar-server-common/src/main/java/org/sonar/server/issue/workflow/IssueWorkflow.java
+++ b/server/sonar-server-common/src/main/java/org/sonar/server/issue/workflow/IssueWorkflow.java
@@ -179,8 +179,7 @@ public class IssueWorkflow implements Startable {
.transition(Transition.builder(DefaultTransitions.OPEN_AS_VULNERABILITY)
.from(STATUS_REVIEWED).to(STATUS_OPEN)
.conditions(new HasType(RuleType.SECURITY_HOTSPOT))
- .functions(new SetResolution(null))
- .functions(new SetType(RuleType.VULNERABILITY))
+ .functions(new SetResolution(null), new SetType(RuleType.VULNERABILITY))
.requiredProjectPermission(UserRole.SECURITYHOTSPOT_ADMIN)
.build())
.transition(Transition.builder(DefaultTransitions.OPEN_AS_VULNERABILITY)
@@ -196,49 +195,25 @@ public class IssueWorkflow implements Startable {
.requiredProjectPermission(UserRole.SECURITYHOTSPOT_ADMIN)
.build())
- // all transitions below have to be removed by the end of the MMF-1635
- .transition(Transition.builder(DefaultTransitions.DETECT)
- .from(STATUS_TO_REVIEW).to(STATUS_OPEN)
+ .transition(Transition.builder(DefaultTransitions.RESET_AS_TO_REVIEW)
+ .from(STATUS_IN_REVIEW).to(STATUS_TO_REVIEW)
.conditions(new HasType(RuleType.SECURITY_HOTSPOT))
- .functions(new SetType(RuleType.VULNERABILITY))
+ .functions(new SetResolution(null))
.requiredProjectPermission(UserRole.SECURITYHOTSPOT_ADMIN)
.build())
- .transition(Transition.builder(DefaultTransitions.DETECT)
- .from(STATUS_RESOLVED).to(STATUS_OPEN)
- .conditions(new HasType(RuleType.SECURITY_HOTSPOT), new HasResolution(RESOLUTION_WONT_FIX))
- .functions(new SetType(RuleType.VULNERABILITY), new SetResolution(null))
+ .transition(Transition.builder(DefaultTransitions.RESET_AS_TO_REVIEW)
+ .from(STATUS_REVIEWED).to(STATUS_TO_REVIEW)
+ .conditions(new HasType(RuleType.SECURITY_HOTSPOT))
+ .functions(new SetResolution(null))
.requiredProjectPermission(UserRole.SECURITYHOTSPOT_ADMIN)
.build())
- .transition(Transition.builder(DefaultTransitions.DISMISS)
+ .transition(Transition.builder(DefaultTransitions.RESET_AS_TO_REVIEW)
.from(STATUS_OPEN).to(STATUS_TO_REVIEW)
- .conditions(IsManualVulnerability.INSTANCE)
- .functions(new SetType(RuleType.SECURITY_HOTSPOT))
- .requiredProjectPermission(UserRole.SECURITYHOTSPOT_ADMIN)
- .build())
- .transition(Transition.builder(DefaultTransitions.REJECT)
- .from(STATUS_RESOLVED).to(STATUS_REOPENED)
- .conditions(new HasType(RuleType.SECURITY_HOTSPOT), new HasResolution(RESOLUTION_FIXED))
- .functions(new SetType(RuleType.VULNERABILITY), new SetResolution(null))
- .requiredProjectPermission(UserRole.SECURITYHOTSPOT_ADMIN)
- .build())
- .transition(Transition.builder(DefaultTransitions.ACCEPT)
- .from(STATUS_RESOLVED).to(STATUS_RESOLVED)
- .conditions(new HasType(RuleType.SECURITY_HOTSPOT), new HasResolution(RESOLUTION_FIXED))
- .functions(new SetResolution(RESOLUTION_WONT_FIX))
- .requiredProjectPermission(UserRole.SECURITYHOTSPOT_ADMIN)
- .build())
- .transition(Transition.builder(DefaultTransitions.CLEAR)
- .from(STATUS_TO_REVIEW).to(STATUS_RESOLVED)
- .conditions(new HasType(RuleType.SECURITY_HOTSPOT))
- .functions(new SetResolution(RESOLUTION_WONT_FIX))
+ .conditions(new HasType(RuleType.VULNERABILITY), IsManualVulnerability.INSTANCE)
+ .functions(new SetType(RuleType.SECURITY_HOTSPOT), new SetResolution(null))
.requiredProjectPermission(UserRole.SECURITYHOTSPOT_ADMIN)
.build())
- .transition(Transition.builder(DefaultTransitions.REOPEN_HOTSPOT)
- .from(STATUS_RESOLVED).to(STATUS_TO_REVIEW)
- .conditions(new HasType(RuleType.SECURITY_HOTSPOT))
- .functions(new SetResolution(null))
- .requiredProjectPermission(UserRole.SECURITYHOTSPOT_ADMIN)
- .build());
+ ;
}
private static void buildAutomaticTransitions(StateMachine.Builder builder) {
diff --git a/server/sonar-server-common/src/test/java/org/sonar/server/issue/workflow/IssueWorkflowForSecurityHotspotsTest.java b/server/sonar-server-common/src/test/java/org/sonar/server/issue/workflow/IssueWorkflowForSecurityHotspotsTest.java
index 6e37f7bca71..7a5cff3c3ed 100644
--- a/server/sonar-server-common/src/test/java/org/sonar/server/issue/workflow/IssueWorkflowForSecurityHotspotsTest.java
+++ b/server/sonar-server-common/src/test/java/org/sonar/server/issue/workflow/IssueWorkflowForSecurityHotspotsTest.java
@@ -19,8 +19,6 @@
*/
package org.sonar.server.issue.workflow;
-import com.google.common.base.Function;
-import com.google.common.collect.Collections2;
import com.tngtech.java.junit.dataprovider.DataProvider;
import com.tngtech.java.junit.dataprovider.DataProviderRunner;
import com.tngtech.java.junit.dataprovider.UseDataProvider;
@@ -29,7 +27,6 @@ import java.util.Calendar;
import java.util.Collection;
import java.util.Date;
import java.util.List;
-import javax.annotation.Nullable;
import org.apache.commons.lang.time.DateUtils;
import org.junit.Test;
import org.junit.runner.RunWith;
@@ -40,12 +37,12 @@ import org.sonar.api.rules.RuleType;
import org.sonar.core.issue.DefaultIssue;
import org.sonar.core.issue.FieldDiffs;
import org.sonar.core.issue.IssueChangeContext;
+import org.sonar.core.util.stream.MoreCollectors;
import org.sonar.server.issue.IssueFieldsSetter;
import static org.assertj.core.api.Assertions.assertThat;
import static org.sonar.api.issue.Issue.RESOLUTION_FIXED;
import static org.sonar.api.issue.Issue.RESOLUTION_REMOVED;
-import static org.sonar.api.issue.Issue.RESOLUTION_WONT_FIX;
import static org.sonar.api.issue.Issue.STATUS_CLOSED;
import static org.sonar.api.issue.Issue.STATUS_IN_REVIEW;
import static org.sonar.api.issue.Issue.STATUS_OPEN;
@@ -65,6 +62,31 @@ public class IssueWorkflowForSecurityHotspotsTest {
private IssueWorkflow underTest = new IssueWorkflow(new FunctionExecutor(updater), updater);
+ @DataProvider
+ public static Object[][] allStatusesLeadingToClosed() {
+ return Arrays.stream(ALL_STATUSES_LEADING_TO_CLOSED)
+ .map(t -> new Object[] {t})
+ .toArray(Object[][]::new);
+ }
+
+ private static DefaultIssue newClosedIssue(String resolution) {
+ return new DefaultIssue()
+ .setKey("ABCDE")
+ .setRuleKey(RuleKey.of("js", "S001"))
+ .setResolution(resolution)
+ .setStatus(STATUS_CLOSED)
+ .setNew(false)
+ .setCloseDate(new Date(5_999_999L));
+ }
+
+ private static void setStatusPreviousToClosed(DefaultIssue issue, String previousStatus) {
+ addStatusChange(issue, new Date(), previousStatus, STATUS_CLOSED);
+ }
+
+ private static void addStatusChange(DefaultIssue issue, Date date, String previousStatus, String newStatus) {
+ issue.addChange(new FieldDiffs().setCreationDate(date).setDiff("status", previousStatus, newStatus));
+ }
+
@Test
public void list_out_transitions_in_status_to_review() {
underTest.start();
@@ -72,7 +94,7 @@ public class IssueWorkflowForSecurityHotspotsTest {
List<Transition> transitions = underTest.outTransitions(issue);
- assertThat(keys(transitions)).containsOnly("setinreview", "detect", "clear", "resolveasreviewed", "openasvulnerability");
+ assertThat(keys(transitions)).containsExactlyInAnyOrder("setinreview", "resolveasreviewed", "openasvulnerability");
}
@Test
@@ -82,27 +104,27 @@ public class IssueWorkflowForSecurityHotspotsTest {
List<Transition> transitions = underTest.outTransitions(issue);
- assertThat(keys(transitions)).containsOnly("resolveasreviewed", "openasvulnerability");
+ assertThat(keys(transitions)).containsExactlyInAnyOrder("resolveasreviewed", "openasvulnerability", "resetastoreview");
}
@Test
- public void list_out_transitions_in_status_reviwed() {
+ public void list_out_transitions_in_status_reviewed() {
underTest.start();
DefaultIssue issue = new DefaultIssue().setType(RuleType.SECURITY_HOTSPOT).setStatus(STATUS_REVIEWED);
List<Transition> transitions = underTest.outTransitions(issue);
- assertThat(keys(transitions)).containsOnly("openasvulnerability");
+ assertThat(keys(transitions)).containsExactlyInAnyOrder("openasvulnerability", "resetastoreview");
}
@Test
- public void list_out_transitions_in_status_open() {
+ public void list_out_vulnerability_transitions_in_status_open() {
underTest.start();
- DefaultIssue issue = new DefaultIssue().setType(RuleType.VULNERABILITY).setStatus(STATUS_OPEN).setResolution(RESOLUTION_FIXED).setIsFromHotspot(true);
+ DefaultIssue issue = new DefaultIssue().setType(RuleType.VULNERABILITY).setResolution(RESOLUTION_FIXED).setStatus(STATUS_OPEN).setIsFromHotspot(true);
List<Transition> transitions = underTest.outTransitions(issue);
- assertThat(keys(transitions)).containsOnly("resolveasreviewed", "dismiss"); // dismiss to be remove by the end of the MMF-1635
+ assertThat(keys(transitions)).containsExactlyInAnyOrder("resolveasreviewed", "resetastoreview");
}
@Test
@@ -203,6 +225,54 @@ public class IssueWorkflowForSecurityHotspotsTest {
}
@Test
+ public void reset_as_to_review_from_reviewed() {
+ underTest.start();
+ DefaultIssue issue = new DefaultIssue()
+ .setType(RuleType.SECURITY_HOTSPOT)
+ .setIsFromHotspot(true)
+ .setStatus(STATUS_REVIEWED)
+ .setResolution(RESOLUTION_FIXED);
+
+ boolean result = underTest.doManualTransition(issue, DefaultTransitions.RESET_AS_TO_REVIEW, IssueChangeContext.createUser(new Date(), "USER1"));
+ assertThat(result).isTrue();
+ assertThat(issue.type()).isEqualTo(RuleType.SECURITY_HOTSPOT);
+ assertThat(issue.getStatus()).isEqualTo(STATUS_TO_REVIEW);
+ assertThat(issue.resolution()).isNull();
+ }
+
+ @Test
+ public void reset_as_to_review_from_in_review() {
+ underTest.start();
+ DefaultIssue issue = new DefaultIssue()
+ .setType(RuleType.SECURITY_HOTSPOT)
+ .setIsFromHotspot(true)
+ .setStatus(STATUS_IN_REVIEW)
+ .setResolution(null);
+
+ boolean result = underTest.doManualTransition(issue, DefaultTransitions.RESET_AS_TO_REVIEW, IssueChangeContext.createUser(new Date(), "USER1"));
+ assertThat(result).isTrue();
+ assertThat(issue.type()).isEqualTo(RuleType.SECURITY_HOTSPOT);
+ assertThat(issue.getStatus()).isEqualTo(STATUS_TO_REVIEW);
+ assertThat(issue.resolution()).isNull();
+ }
+
+ @Test
+ public void reset_as_to_review_from_opened_as_vulnerability() {
+ underTest.start();
+ DefaultIssue issue = new DefaultIssue()
+ .setType(RuleType.VULNERABILITY)
+ .setIsFromHotspot(true)
+ .setStatus(STATUS_OPEN)
+ .setResolution(null);
+
+ boolean result = underTest.doManualTransition(issue, DefaultTransitions.RESET_AS_TO_REVIEW, IssueChangeContext.createUser(new Date(), "USER1"));
+ assertThat(result).isTrue();
+ assertThat(issue.type()).isEqualTo(RuleType.SECURITY_HOTSPOT);
+ assertThat(issue.getStatus()).isEqualTo(STATUS_TO_REVIEW);
+ assertThat(issue.resolution()).isNull();
+ }
+
+ @Test
public void automatically_close_resolved_security_hotspots_in_status_to_review() {
underTest.start();
DefaultIssue issue = new DefaultIssue()
@@ -260,6 +330,26 @@ public class IssueWorkflowForSecurityHotspotsTest {
}
@Test
+ public void automatically_close_hotspots_opened_as_vulnerability() {
+ underTest.start();
+ DefaultIssue issue = new DefaultIssue()
+ .setType(RuleType.VULNERABILITY)
+ .setResolution(null)
+ .setStatus(STATUS_OPEN)
+ .setIsFromHotspot(true)
+ .setNew(false)
+ .setBeingClosed(true);
+ Date now = new Date();
+
+ underTest.doAutomaticTransition(issue, IssueChangeContext.createScan(now));
+
+ assertThat(issue.resolution()).isEqualTo(RESOLUTION_FIXED);
+ assertThat(issue.status()).isEqualTo(STATUS_CLOSED);
+ assertThat(issue.closeDate()).isNotNull();
+ assertThat(issue.updateDate()).isEqualTo(DateUtils.truncate(now, Calendar.SECOND));
+ }
+
+ @Test
@UseDataProvider("allStatusesLeadingToClosed")
public void do_not_automatically_reopen_closed_issues_of_security_hotspots(String previousStatus) {
DefaultIssue[] issues = Arrays.stream(SUPPORTED_RESOLUTIONS_FOR_UNCLOSING)
@@ -318,13 +408,6 @@ public class IssueWorkflowForSecurityHotspotsTest {
});
}
- @DataProvider
- public static Object[][] allStatusesLeadingToClosed() {
- return Arrays.stream(ALL_STATUSES_LEADING_TO_CLOSED)
- .map(t -> new Object[] {t})
- .toArray(Object[][]::new);
- }
-
@Test
public void do_not_allow_to_doManualTransition_when_condition_fails() {
underTest.start();
@@ -332,38 +415,15 @@ public class IssueWorkflowForSecurityHotspotsTest {
.setKey("ABCDE")
// Detect is only available on hotspot
.setType(RuleType.VULNERABILITY)
- .setIsFromHotspot(true)
- .setStatus(STATUS_RESOLVED)
- .setResolution(RESOLUTION_WONT_FIX)
+ .setIsFromHotspot(false)
+ .setStatus(STATUS_OPEN)
+ .setResolution(null)
.setRuleKey(XOO_X1);
- assertThat(underTest.doManualTransition(issue, DefaultTransitions.DETECT, IssueChangeContext.createScan(new Date()))).isFalse();
- }
-
- private static DefaultIssue newClosedIssue(String resolution) {
- return new DefaultIssue()
- .setKey("ABCDE")
- .setRuleKey(RuleKey.of("js", "S001"))
- .setResolution(resolution)
- .setStatus(STATUS_CLOSED)
- .setNew(false)
- .setCloseDate(new Date(5_999_999L));
- }
-
- private static void setStatusPreviousToClosed(DefaultIssue issue, String previousStatus) {
- addStatusChange(issue, new Date(), previousStatus, STATUS_CLOSED);
- }
-
- private static void addStatusChange(DefaultIssue issue, Date date, String previousStatus, String newStatus) {
- issue.addChange(new FieldDiffs().setCreationDate(date).setDiff("status", previousStatus, newStatus));
+ assertThat(underTest.doManualTransition(issue, DefaultTransitions.RESET_AS_TO_REVIEW, IssueChangeContext.createScan(new Date()))).isFalse();
}
private Collection<String> keys(List<Transition> transitions) {
- return Collections2.transform(transitions, new Function<Transition, String>() {
- @Override
- public String apply(@Nullable Transition transition) {
- return transition.key();
- }
- });
+ return transitions.stream().map(Transition::key).collect(MoreCollectors.toList());
}
}
diff --git a/server/sonar-server/src/main/java/org/sonar/server/issue/ws/DoTransitionAction.java b/server/sonar-server/src/main/java/org/sonar/server/issue/ws/DoTransitionAction.java
index 463f1cd52f4..7b0659e69ef 100644
--- a/server/sonar-server/src/main/java/org/sonar/server/issue/ws/DoTransitionAction.java
+++ b/server/sonar-server/src/main/java/org/sonar/server/issue/ws/DoTransitionAction.java
@@ -40,6 +40,7 @@ import org.sonar.server.user.UserSession;
import static java.lang.String.format;
import static org.sonar.api.issue.DefaultTransitions.OPEN_AS_VULNERABILITY;
+import static org.sonar.api.issue.DefaultTransitions.RESET_AS_TO_REVIEW;
import static org.sonar.api.issue.DefaultTransitions.RESOLVE_AS_REVIEWED;
import static org.sonar.api.issue.DefaultTransitions.SET_AS_IN_REVIEW;
import static org.sonarqube.ws.client.issue.IssuesWsParameters.ACTION_DO_TRANSITION;
@@ -75,7 +76,7 @@ public class DoTransitionAction implements IssuesWsAction {
"The transitions involving security hotspots require the permission 'Administer Security Hotspot'.")
.setSince("3.6")
.setChangelog(
- new Change("7.8", format("added '%s', %s and %s transitions for security hotspots ", SET_AS_IN_REVIEW, RESOLVE_AS_REVIEWED, OPEN_AS_VULNERABILITY)),
+ new Change("7.8", format("added '%s', %s, %s and %s transitions for security hotspots ", SET_AS_IN_REVIEW, RESOLVE_AS_REVIEWED, OPEN_AS_VULNERABILITY, RESET_AS_TO_REVIEW)),
new Change("7.3", "added transitions for security hotspots"),
new Change("6.5", "the database ids of the components are removed from the response"),
new Change("6.5", "the response field components.uuid is deprecated. Use components.key instead."))
diff --git a/server/sonar-server/src/test/java/org/sonar/server/issue/ws/BulkChangeActionTest.java b/server/sonar-server/src/test/java/org/sonar/server/issue/ws/BulkChangeActionTest.java
index 87631fb449e..127e87d2530 100644
--- a/server/sonar-server/src/test/java/org/sonar/server/issue/ws/BulkChangeActionTest.java
+++ b/server/sonar-server/src/test/java/org/sonar/server/issue/ws/BulkChangeActionTest.java
@@ -345,7 +345,7 @@ public class BulkChangeActionTest {
BulkChangeWsResponse response = call(builder()
.setIssues(singletonList(issue.getKey()))
- .setDoTransition("dismiss")
+ .setDoTransition("resetastoreview")
.setSendNotifications(true)
.build());
diff --git a/server/sonar-server/src/test/resources/com/sonar/governance/securityreport/ws/ShowActionTest/empty.json b/server/sonar-server/src/test/resources/com/sonar/governance/securityreport/ws/ShowActionTest/empty.json
index e249486597c..efb9191e511 100644
--- a/server/sonar-server/src/test/resources/com/sonar/governance/securityreport/ws/ShowActionTest/empty.json
+++ b/server/sonar-server/src/test/resources/com/sonar/governance/securityreport/ws/ShowActionTest/empty.json
@@ -5,7 +5,7 @@
"vulnerabilities": 0,
"inReviewSecurityHotspots": 0,
"toReviewSecurityHotspots": 0,
- "resolvedSecurityHotspots": 0,
+ "reviewedSecurityHotspots": 0,
"distribution": [],
"activeRules": 1,
"totalRules": 1
@@ -15,7 +15,7 @@
"vulnerabilities": 0,
"inReviewSecurityHotspots": 0,
"toReviewSecurityHotspots": 0,
- "resolvedSecurityHotspots": 0,
+ "reviewedSecurityHotspots": 0,
"distribution": [],
"activeRules": 1,
"totalRules": 1
@@ -25,7 +25,7 @@
"vulnerabilities": 0,
"inReviewSecurityHotspots": 0,
"toReviewSecurityHotspots": 0,
- "resolvedSecurityHotspots": 0,
+ "reviewedSecurityHotspots": 0,
"distribution": [],
"activeRules": 0,
"totalRules": 1
@@ -35,7 +35,7 @@
"vulnerabilities": 0,
"inReviewSecurityHotspots": 0,
"toReviewSecurityHotspots": 0,
- "resolvedSecurityHotspots": 0,
+ "reviewedSecurityHotspots": 0,
"distribution": [],
"activeRules": 0,
"totalRules": 0
@@ -45,7 +45,7 @@
"vulnerabilities": 0,
"inReviewSecurityHotspots": 0,
"toReviewSecurityHotspots": 0,
- "resolvedSecurityHotspots": 0,
+ "reviewedSecurityHotspots": 0,
"distribution": [],
"activeRules": 0,
"totalRules": 0
@@ -55,7 +55,7 @@
"vulnerabilities": 0,
"inReviewSecurityHotspots": 0,
"toReviewSecurityHotspots": 0,
- "resolvedSecurityHotspots": 0,
+ "reviewedSecurityHotspots": 0,
"distribution": [],
"activeRules": 0,
"totalRules": 0
@@ -65,7 +65,7 @@
"vulnerabilities": 0,
"inReviewSecurityHotspots": 0,
"toReviewSecurityHotspots": 0,
- "resolvedSecurityHotspots": 0,
+ "reviewedSecurityHotspots": 0,
"distribution": [],
"activeRules": 0,
"totalRules": 0
@@ -75,7 +75,7 @@
"vulnerabilities": 0,
"inReviewSecurityHotspots": 0,
"toReviewSecurityHotspots": 0,
- "resolvedSecurityHotspots": 0,
+ "reviewedSecurityHotspots": 0,
"distribution": [],
"activeRules": 0,
"totalRules": 0
@@ -85,7 +85,7 @@
"vulnerabilities": 0,
"inReviewSecurityHotspots": 0,
"toReviewSecurityHotspots": 0,
- "resolvedSecurityHotspots": 0,
+ "reviewedSecurityHotspots": 0,
"distribution": [],
"activeRules": 0,
"totalRules": 0
@@ -95,7 +95,7 @@
"vulnerabilities": 0,
"inReviewSecurityHotspots": 0,
"toReviewSecurityHotspots": 0,
- "resolvedSecurityHotspots": 0,
+ "reviewedSecurityHotspots": 0,
"distribution": [],
"activeRules": 0,
"totalRules": 0
@@ -105,7 +105,7 @@
"vulnerabilities": 0,
"inReviewSecurityHotspots": 0,
"toReviewSecurityHotspots": 0,
- "resolvedSecurityHotspots": 0,
+ "reviewedSecurityHotspots": 0,
"distribution": [],
"activeRules": 1,
"totalRules": 2
diff --git a/server/sonar-server/src/test/resources/com/sonar/governance/securityreport/ws/ShowActionTest/owaspNoCwe.json b/server/sonar-server/src/test/resources/com/sonar/governance/securityreport/ws/ShowActionTest/owaspNoCwe.json
index 30e6a1057dc..60675e21b7b 100644
--- a/server/sonar-server/src/test/resources/com/sonar/governance/securityreport/ws/ShowActionTest/owaspNoCwe.json
+++ b/server/sonar-server/src/test/resources/com/sonar/governance/securityreport/ws/ShowActionTest/owaspNoCwe.json
@@ -5,7 +5,7 @@
"vulnerabilities": 0,
"inReviewSecurityHotspots": 0,
"toReviewSecurityHotspots": 0,
- "resolvedSecurityHotspots": 0,
+ "reviewedSecurityHotspots": 0,
"distribution": [],
"activeRules": 1,
"totalRules": 1
@@ -16,7 +16,7 @@
"vulnerabilityRating": 3,
"inReviewSecurityHotspots": 1,
"toReviewSecurityHotspots": 1,
- "resolvedSecurityHotspots": 1,
+ "reviewedSecurityHotspots": 1,
"distribution": [],
"activeRules": 1,
"totalRules": 1
@@ -26,7 +26,7 @@
"vulnerabilities": 0,
"inReviewSecurityHotspots": 0,
"toReviewSecurityHotspots": 0,
- "resolvedSecurityHotspots": 0,
+ "reviewedSecurityHotspots": 0,
"distribution": [],
"activeRules": 0,
"totalRules": 1
@@ -36,7 +36,7 @@
"vulnerabilities": 0,
"inReviewSecurityHotspots": 0,
"toReviewSecurityHotspots": 0,
- "resolvedSecurityHotspots": 0,
+ "reviewedSecurityHotspots": 0,
"distribution": [],
"activeRules": 0,
"totalRules": 0
@@ -46,7 +46,7 @@
"vulnerabilities": 0,
"inReviewSecurityHotspots": 0,
"toReviewSecurityHotspots": 0,
- "resolvedSecurityHotspots": 0,
+ "reviewedSecurityHotspots": 0,
"distribution": [],
"activeRules": 0,
"totalRules": 0
@@ -56,7 +56,7 @@
"vulnerabilities": 0,
"inReviewSecurityHotspots": 0,
"toReviewSecurityHotspots": 0,
- "resolvedSecurityHotspots": 0,
+ "reviewedSecurityHotspots": 0,
"distribution": [],
"activeRules": 0,
"totalRules": 0
@@ -66,7 +66,7 @@
"vulnerabilities": 0,
"inReviewSecurityHotspots": 0,
"toReviewSecurityHotspots": 0,
- "resolvedSecurityHotspots": 0,
+ "reviewedSecurityHotspots": 0,
"distribution": [],
"activeRules": 0,
"totalRules": 0
@@ -76,7 +76,7 @@
"vulnerabilities": 0,
"inReviewSecurityHotspots": 0,
"toReviewSecurityHotspots": 0,
- "resolvedSecurityHotspots": 0,
+ "reviewedSecurityHotspots": 0,
"distribution": [],
"activeRules": 0,
"totalRules": 0
@@ -86,7 +86,7 @@
"vulnerabilities": 0,
"inReviewSecurityHotspots": 0,
"toReviewSecurityHotspots": 0,
- "resolvedSecurityHotspots": 0,
+ "reviewedSecurityHotspots": 0,
"distribution": [],
"activeRules": 0,
"totalRules": 0
@@ -96,7 +96,7 @@
"vulnerabilities": 0,
"inReviewSecurityHotspots": 0,
"toReviewSecurityHotspots": 0,
- "resolvedSecurityHotspots": 0,
+ "reviewedSecurityHotspots": 0,
"distribution": [],
"activeRules": 0,
"totalRules": 0
@@ -106,7 +106,7 @@
"vulnerabilities": 0,
"inReviewSecurityHotspots": 0,
"toReviewSecurityHotspots": 0,
- "resolvedSecurityHotspots": 0,
+ "reviewedSecurityHotspots": 0,
"distribution": [],
"activeRules": 1,
"totalRules": 2
diff --git a/server/sonar-server/src/test/resources/com/sonar/governance/securityreport/ws/ShowActionTest/sansWithCwe.json b/server/sonar-server/src/test/resources/com/sonar/governance/securityreport/ws/ShowActionTest/sansWithCwe.json
index 036ffff353d..ce510484551 100644
--- a/server/sonar-server/src/test/resources/com/sonar/governance/securityreport/ws/ShowActionTest/sansWithCwe.json
+++ b/server/sonar-server/src/test/resources/com/sonar/governance/securityreport/ws/ShowActionTest/sansWithCwe.json
@@ -5,7 +5,7 @@
"vulnerabilities": 0,
"inReviewSecurityHotspots": 0,
"toReviewSecurityHotspots": 0,
- "resolvedSecurityHotspots": 0,
+ "reviewedSecurityHotspots": 0,
"distribution": [],
"activeRules": 0,
"totalRules": 1
@@ -15,7 +15,7 @@
"vulnerabilities": 0,
"inReviewSecurityHotspots": 0,
"toReviewSecurityHotspots": 0,
- "resolvedSecurityHotspots": 0,
+ "reviewedSecurityHotspots": 0,
"distribution": [],
"activeRules": 1,
"totalRules": 1
@@ -26,7 +26,7 @@
"vulnerabilityRating": 3,
"inReviewSecurityHotspots": 1,
"toReviewSecurityHotspots": 1,
- "resolvedSecurityHotspots": 0,
+ "reviewedSecurityHotspots": 0,
"distribution": [
{
"cwe": "89",
@@ -34,7 +34,7 @@
"vulnerabilityRating": 3,
"inReviewSecurityHotspots": 1,
"toReviewSecurityHotspots": 1,
- "resolvedSecurityHotspots": 0,
+ "reviewedSecurityHotspots": 0,
"activeRules": 1,
"totalRules": 1
}
diff --git a/server/sonar-server/src/test/resources/com/sonar/governance/securityreport/ws/ShowActionTest/sonarsourceSecurityNoCwe.json b/server/sonar-server/src/test/resources/com/sonar/governance/securityreport/ws/ShowActionTest/sonarsourceSecurityNoCwe.json
index 9d0acd1dc28..c00feb5f200 100644
--- a/server/sonar-server/src/test/resources/com/sonar/governance/securityreport/ws/ShowActionTest/sonarsourceSecurityNoCwe.json
+++ b/server/sonar-server/src/test/resources/com/sonar/governance/securityreport/ws/ShowActionTest/sonarsourceSecurityNoCwe.json
@@ -5,7 +5,7 @@
"vulnerabilities": 0,
"inReviewSecurityHotspots": 0,
"toReviewSecurityHotspots": 0,
- "resolvedSecurityHotspots": 0,
+ "reviewedSecurityHotspots": 0,
"distribution": [],
"activeRules": 0,
"totalRules": 0
@@ -15,7 +15,7 @@
"vulnerabilities": 0,
"inReviewSecurityHotspots": 0,
"toReviewSecurityHotspots": 0,
- "resolvedSecurityHotspots": 0,
+ "reviewedSecurityHotspots": 0,
"distribution": [],
"activeRules": 0,
"totalRules": 0
@@ -25,7 +25,7 @@
"vulnerabilities": 0,
"inReviewSecurityHotspots": 0,
"toReviewSecurityHotspots": 0,
- "resolvedSecurityHotspots": 0,
+ "reviewedSecurityHotspots": 0,
"distribution": [],
"activeRules": 0,
"totalRules": 0
@@ -35,7 +35,7 @@
"vulnerabilities": 0,
"inReviewSecurityHotspots": 0,
"toReviewSecurityHotspots": 0,
- "resolvedSecurityHotspots": 0,
+ "reviewedSecurityHotspots": 0,
"distribution": [],
"activeRules": 0,
"totalRules": 0
@@ -45,7 +45,7 @@
"vulnerabilities": 0,
"inReviewSecurityHotspots": 0,
"toReviewSecurityHotspots": 0,
- "resolvedSecurityHotspots": 0,
+ "reviewedSecurityHotspots": 0,
"distribution": [],
"activeRules": 0,
"totalRules": 0
@@ -55,7 +55,7 @@
"vulnerabilities": 0,
"inReviewSecurityHotspots": 0,
"toReviewSecurityHotspots": 0,
- "resolvedSecurityHotspots": 0,
+ "reviewedSecurityHotspots": 0,
"distribution": [],
"activeRules": 0,
"totalRules": 0
@@ -65,7 +65,7 @@
"vulnerabilities": 0,
"inReviewSecurityHotspots": 0,
"toReviewSecurityHotspots": 0,
- "resolvedSecurityHotspots": 0,
+ "reviewedSecurityHotspots": 0,
"distribution": [],
"activeRules": 0,
"totalRules": 0
@@ -75,7 +75,7 @@
"vulnerabilities": 0,
"inReviewSecurityHotspots": 0,
"toReviewSecurityHotspots": 0,
- "resolvedSecurityHotspots": 0,
+ "reviewedSecurityHotspots": 0,
"distribution": [],
"activeRules": 0,
"totalRules": 0
@@ -85,7 +85,7 @@
"vulnerabilities": 0,
"inReviewSecurityHotspots": 0,
"toReviewSecurityHotspots": 0,
- "resolvedSecurityHotspots": 0,
+ "reviewedSecurityHotspots": 0,
"distribution": [],
"activeRules": 0,
"totalRules": 0
@@ -95,7 +95,7 @@
"vulnerabilities": 0,
"inReviewSecurityHotspots": 0,
"toReviewSecurityHotspots": 0,
- "resolvedSecurityHotspots": 0,
+ "reviewedSecurityHotspots": 0,
"distribution": [],
"activeRules": 0,
"totalRules": 0
@@ -105,7 +105,7 @@
"vulnerabilities": 0,
"inReviewSecurityHotspots": 0,
"toReviewSecurityHotspots": 0,
- "resolvedSecurityHotspots": 0,
+ "reviewedSecurityHotspots": 0,
"distribution": [],
"activeRules": 0,
"totalRules": 0
@@ -115,7 +115,7 @@
"vulnerabilities": 0,
"inReviewSecurityHotspots": 0,
"toReviewSecurityHotspots": 0,
- "resolvedSecurityHotspots": 0,
+ "reviewedSecurityHotspots": 0,
"distribution": [],
"activeRules": 0,
"totalRules": 0
@@ -126,7 +126,7 @@
"vulnerabilityRating": 3,
"inReviewSecurityHotspots": 1,
"toReviewSecurityHotspots": 1,
- "resolvedSecurityHotspots": 1,
+ "reviewedSecurityHotspots": 1,
"distribution": [],
"activeRules": 1,
"totalRules": 1
@@ -136,7 +136,7 @@
"vulnerabilities": 0,
"inReviewSecurityHotspots": 0,
"toReviewSecurityHotspots": 0,
- "resolvedSecurityHotspots": 0,
+ "reviewedSecurityHotspots": 0,
"distribution": [],
"activeRules": 0,
"totalRules": 0
@@ -146,7 +146,7 @@
"vulnerabilities": 0,
"inReviewSecurityHotspots": 0,
"toReviewSecurityHotspots": 0,
- "resolvedSecurityHotspots": 0,
+ "reviewedSecurityHotspots": 0,
"distribution": [],
"activeRules": 0,
"totalRules": 0
@@ -156,7 +156,7 @@
"vulnerabilities": 0,
"inReviewSecurityHotspots": 0,
"toReviewSecurityHotspots": 0,
- "resolvedSecurityHotspots": 0,
+ "reviewedSecurityHotspots": 0,
"distribution": [],
"activeRules": 0,
"totalRules": 0
@@ -166,7 +166,7 @@
"vulnerabilities": 0,
"inReviewSecurityHotspots": 0,
"toReviewSecurityHotspots": 0,
- "resolvedSecurityHotspots": 0,
+ "reviewedSecurityHotspots": 0,
"distribution": [],
"activeRules": 0,
"totalRules": 0
@@ -176,7 +176,7 @@
"vulnerabilities": 0,
"inReviewSecurityHotspots": 0,
"toReviewSecurityHotspots": 0,
- "resolvedSecurityHotspots": 0,
+ "reviewedSecurityHotspots": 0,
"distribution": [],
"activeRules": 1,
"totalRules": 1
@@ -186,7 +186,7 @@
"vulnerabilities": 0,
"inReviewSecurityHotspots": 0,
"toReviewSecurityHotspots": 0,
- "resolvedSecurityHotspots": 0,
+ "reviewedSecurityHotspots": 0,
"distribution": [],
"activeRules": 1,
"totalRules": 1
@@ -196,7 +196,7 @@
"vulnerabilities": 0,
"inReviewSecurityHotspots": 0,
"toReviewSecurityHotspots": 0,
- "resolvedSecurityHotspots": 0,
+ "reviewedSecurityHotspots": 0,
"distribution": [],
"activeRules": 0,
"totalRules": 0
diff --git a/server/sonar-server/src/test/resources/com/sonar/governance/securityreport/ws/ShowActionTest/sonarsourceSecurityOnApplication.json b/server/sonar-server/src/test/resources/com/sonar/governance/securityreport/ws/ShowActionTest/sonarsourceSecurityOnApplication.json
index 258c0756f96..93df7186016 100644
--- a/server/sonar-server/src/test/resources/com/sonar/governance/securityreport/ws/ShowActionTest/sonarsourceSecurityOnApplication.json
+++ b/server/sonar-server/src/test/resources/com/sonar/governance/securityreport/ws/ShowActionTest/sonarsourceSecurityOnApplication.json
@@ -5,7 +5,7 @@
"vulnerabilities": 0,
"inReviewSecurityHotspots": 0,
"toReviewSecurityHotspots": 0,
- "resolvedSecurityHotspots": 0,
+ "reviewedSecurityHotspots": 0,
"distribution": []
},
{
@@ -13,7 +13,7 @@
"vulnerabilities": 0,
"inReviewSecurityHotspots": 0,
"toReviewSecurityHotspots": 0,
- "resolvedSecurityHotspots": 0,
+ "reviewedSecurityHotspots": 0,
"distribution": []
},
{
@@ -21,7 +21,7 @@
"vulnerabilities": 0,
"inReviewSecurityHotspots": 0,
"toReviewSecurityHotspots": 0,
- "resolvedSecurityHotspots": 0,
+ "reviewedSecurityHotspots": 0,
"distribution": []
},
{
@@ -29,7 +29,7 @@
"vulnerabilities": 0,
"inReviewSecurityHotspots": 0,
"toReviewSecurityHotspots": 0,
- "resolvedSecurityHotspots": 0,
+ "reviewedSecurityHotspots": 0,
"distribution": []
},
{
@@ -37,7 +37,7 @@
"vulnerabilities": 0,
"inReviewSecurityHotspots": 0,
"toReviewSecurityHotspots": 0,
- "resolvedSecurityHotspots": 0,
+ "reviewedSecurityHotspots": 0,
"distribution": []
},
{
@@ -45,7 +45,7 @@
"vulnerabilities": 0,
"inReviewSecurityHotspots": 0,
"toReviewSecurityHotspots": 0,
- "resolvedSecurityHotspots": 0,
+ "reviewedSecurityHotspots": 0,
"distribution": []
},
{
@@ -53,7 +53,7 @@
"vulnerabilities": 0,
"inReviewSecurityHotspots": 0,
"toReviewSecurityHotspots": 0,
- "resolvedSecurityHotspots": 0,
+ "reviewedSecurityHotspots": 0,
"distribution": []
},
{
@@ -61,7 +61,7 @@
"vulnerabilities": 0,
"inReviewSecurityHotspots": 0,
"toReviewSecurityHotspots": 0,
- "resolvedSecurityHotspots": 0,
+ "reviewedSecurityHotspots": 0,
"distribution": []
},
{
@@ -69,7 +69,7 @@
"vulnerabilities": 0,
"inReviewSecurityHotspots": 0,
"toReviewSecurityHotspots": 0,
- "resolvedSecurityHotspots": 0,
+ "reviewedSecurityHotspots": 0,
"distribution": []
},
{
@@ -77,7 +77,7 @@
"vulnerabilities": 0,
"inReviewSecurityHotspots": 0,
"toReviewSecurityHotspots": 0,
- "resolvedSecurityHotspots": 0,
+ "reviewedSecurityHotspots": 0,
"distribution": []
},
{
@@ -85,7 +85,7 @@
"vulnerabilities": 0,
"inReviewSecurityHotspots": 0,
"toReviewSecurityHotspots": 0,
- "resolvedSecurityHotspots": 0,
+ "reviewedSecurityHotspots": 0,
"distribution": []
},
{
@@ -93,7 +93,7 @@
"vulnerabilities": 0,
"inReviewSecurityHotspots": 0,
"toReviewSecurityHotspots": 0,
- "resolvedSecurityHotspots": 0,
+ "reviewedSecurityHotspots": 0,
"distribution": []
},
{
@@ -102,7 +102,7 @@
"vulnerabilityRating": 3,
"inReviewSecurityHotspots": 1,
"toReviewSecurityHotspots": 1,
- "resolvedSecurityHotspots": 1,
+ "reviewedSecurityHotspots": 1,
"distribution": [
{
"cwe": "89",
@@ -110,7 +110,7 @@
"vulnerabilityRating": 3,
"inReviewSecurityHotspots": 1,
"toReviewSecurityHotspots": 1,
- "resolvedSecurityHotspots": 1
+ "reviewedSecurityHotspots": 1
}
]
},
@@ -119,7 +119,7 @@
"vulnerabilities": 0,
"inReviewSecurityHotspots": 0,
"toReviewSecurityHotspots": 0,
- "resolvedSecurityHotspots": 0,
+ "reviewedSecurityHotspots": 0,
"distribution": []
},
{
@@ -127,7 +127,7 @@
"vulnerabilities": 0,
"inReviewSecurityHotspots": 0,
"toReviewSecurityHotspots": 0,
- "resolvedSecurityHotspots": 0,
+ "reviewedSecurityHotspots": 0,
"distribution": []
},
{
@@ -135,7 +135,7 @@
"vulnerabilities": 0,
"inReviewSecurityHotspots": 0,
"toReviewSecurityHotspots": 0,
- "resolvedSecurityHotspots": 0,
+ "reviewedSecurityHotspots": 0,
"distribution": []
},
{
@@ -143,7 +143,7 @@
"vulnerabilities": 0,
"inReviewSecurityHotspots": 0,
"toReviewSecurityHotspots": 0,
- "resolvedSecurityHotspots": 0,
+ "reviewedSecurityHotspots": 0,
"distribution": []
},
{
@@ -151,7 +151,7 @@
"vulnerabilities": 0,
"inReviewSecurityHotspots": 0,
"toReviewSecurityHotspots": 0,
- "resolvedSecurityHotspots": 0,
+ "reviewedSecurityHotspots": 0,
"distribution": []
},
{
@@ -159,7 +159,7 @@
"vulnerabilities": 0,
"inReviewSecurityHotspots": 0,
"toReviewSecurityHotspots": 0,
- "resolvedSecurityHotspots": 0,
+ "reviewedSecurityHotspots": 0,
"distribution": []
},
{
@@ -167,7 +167,7 @@
"vulnerabilities": 0,
"inReviewSecurityHotspots": 0,
"toReviewSecurityHotspots": 0,
- "resolvedSecurityHotspots": 0,
+ "reviewedSecurityHotspots": 0,
"distribution": []
}
]
diff --git a/server/sonar-server/src/test/resources/com/sonar/governance/securityreport/ws/ShowActionTest/sonarsourceSecurityWithCwe.json b/server/sonar-server/src/test/resources/com/sonar/governance/securityreport/ws/ShowActionTest/sonarsourceSecurityWithCwe.json
index 712067d6d7e..c9e6c748036 100644
--- a/server/sonar-server/src/test/resources/com/sonar/governance/securityreport/ws/ShowActionTest/sonarsourceSecurityWithCwe.json
+++ b/server/sonar-server/src/test/resources/com/sonar/governance/securityreport/ws/ShowActionTest/sonarsourceSecurityWithCwe.json
@@ -5,7 +5,7 @@
"vulnerabilities": 0,
"inReviewSecurityHotspots": 0,
"toReviewSecurityHotspots": 0,
- "resolvedSecurityHotspots": 0,
+ "reviewedSecurityHotspots": 0,
"distribution": [],
"activeRules": 0,
"totalRules": 0
@@ -15,7 +15,7 @@
"vulnerabilities": 0,
"inReviewSecurityHotspots": 0,
"toReviewSecurityHotspots": 0,
- "resolvedSecurityHotspots": 0,
+ "reviewedSecurityHotspots": 0,
"distribution": [],
"activeRules": 0,
"totalRules": 0
@@ -25,7 +25,7 @@
"vulnerabilities": 0,
"inReviewSecurityHotspots": 0,
"toReviewSecurityHotspots": 0,
- "resolvedSecurityHotspots": 0,
+ "reviewedSecurityHotspots": 0,
"distribution": [],
"activeRules": 0,
"totalRules": 0
@@ -35,7 +35,7 @@
"vulnerabilities": 0,
"inReviewSecurityHotspots": 0,
"toReviewSecurityHotspots": 0,
- "resolvedSecurityHotspots": 0,
+ "reviewedSecurityHotspots": 0,
"distribution": [],
"activeRules": 0,
"totalRules": 0
@@ -45,7 +45,7 @@
"vulnerabilities": 0,
"inReviewSecurityHotspots": 0,
"toReviewSecurityHotspots": 0,
- "resolvedSecurityHotspots": 0,
+ "reviewedSecurityHotspots": 0,
"distribution": [],
"activeRules": 0,
"totalRules": 0
@@ -55,7 +55,7 @@
"vulnerabilities": 0,
"inReviewSecurityHotspots": 0,
"toReviewSecurityHotspots": 0,
- "resolvedSecurityHotspots": 0,
+ "reviewedSecurityHotspots": 0,
"distribution": [],
"activeRules": 0,
"totalRules": 0
@@ -65,7 +65,7 @@
"vulnerabilities": 0,
"inReviewSecurityHotspots": 0,
"toReviewSecurityHotspots": 0,
- "resolvedSecurityHotspots": 0,
+ "reviewedSecurityHotspots": 0,
"distribution": [],
"activeRules": 0,
"totalRules": 0
@@ -75,7 +75,7 @@
"vulnerabilities": 0,
"inReviewSecurityHotspots": 0,
"toReviewSecurityHotspots": 0,
- "resolvedSecurityHotspots": 0,
+ "reviewedSecurityHotspots": 0,
"distribution": [],
"activeRules": 0,
"totalRules": 0
@@ -85,7 +85,7 @@
"vulnerabilities": 0,
"inReviewSecurityHotspots": 0,
"toReviewSecurityHotspots": 0,
- "resolvedSecurityHotspots": 0,
+ "reviewedSecurityHotspots": 0,
"distribution": [],
"activeRules": 0,
"totalRules": 0
@@ -95,7 +95,7 @@
"vulnerabilities": 0,
"inReviewSecurityHotspots": 0,
"toReviewSecurityHotspots": 0,
- "resolvedSecurityHotspots": 0,
+ "reviewedSecurityHotspots": 0,
"distribution": [],
"activeRules": 0,
"totalRules": 0
@@ -105,7 +105,7 @@
"vulnerabilities": 0,
"inReviewSecurityHotspots": 0,
"toReviewSecurityHotspots": 0,
- "resolvedSecurityHotspots": 0,
+ "reviewedSecurityHotspots": 0,
"distribution": [],
"activeRules": 0,
"totalRules": 0
@@ -115,7 +115,7 @@
"vulnerabilities": 0,
"inReviewSecurityHotspots": 0,
"toReviewSecurityHotspots": 0,
- "resolvedSecurityHotspots": 0,
+ "reviewedSecurityHotspots": 0,
"distribution": [],
"activeRules": 0,
"totalRules": 0
@@ -126,7 +126,7 @@
"vulnerabilityRating": 3,
"inReviewSecurityHotspots": 1,
"toReviewSecurityHotspots": 1,
- "resolvedSecurityHotspots": 1,
+ "reviewedSecurityHotspots": 1,
"distribution": [
{
"cwe": "89",
@@ -134,7 +134,7 @@
"vulnerabilityRating": 3,
"inReviewSecurityHotspots": 1,
"toReviewSecurityHotspots": 1,
- "resolvedSecurityHotspots": 1,
+ "reviewedSecurityHotspots": 1,
"activeRules": 1,
"totalRules": 1
}
@@ -147,7 +147,7 @@
"vulnerabilities": 0,
"inReviewSecurityHotspots": 0,
"toReviewSecurityHotspots": 0,
- "resolvedSecurityHotspots": 0,
+ "reviewedSecurityHotspots": 0,
"distribution": [],
"activeRules": 0,
"totalRules": 0
@@ -157,7 +157,7 @@
"vulnerabilities": 0,
"inReviewSecurityHotspots": 0,
"toReviewSecurityHotspots": 0,
- "resolvedSecurityHotspots": 0,
+ "reviewedSecurityHotspots": 0,
"distribution": [],
"activeRules": 0,
"totalRules": 0
@@ -167,7 +167,7 @@
"vulnerabilities": 0,
"inReviewSecurityHotspots": 0,
"toReviewSecurityHotspots": 0,
- "resolvedSecurityHotspots": 0,
+ "reviewedSecurityHotspots": 0,
"distribution": [],
"activeRules": 0,
"totalRules": 0
@@ -177,7 +177,7 @@
"vulnerabilities": 0,
"inReviewSecurityHotspots": 0,
"toReviewSecurityHotspots": 0,
- "resolvedSecurityHotspots": 0,
+ "reviewedSecurityHotspots": 0,
"distribution": [],
"activeRules": 0,
"totalRules": 0
@@ -187,7 +187,7 @@
"vulnerabilities": 0,
"inReviewSecurityHotspots": 0,
"toReviewSecurityHotspots": 0,
- "resolvedSecurityHotspots": 0,
+ "reviewedSecurityHotspots": 0,
"distribution": [],
"activeRules": 1,
"totalRules": 1
@@ -197,7 +197,7 @@
"vulnerabilities": 0,
"inReviewSecurityHotspots": 0,
"toReviewSecurityHotspots": 0,
- "resolvedSecurityHotspots": 0,
+ "reviewedSecurityHotspots": 0,
"distribution": [],
"activeRules": 1,
"totalRules": 1
@@ -207,7 +207,7 @@
"vulnerabilities": 0,
"inReviewSecurityHotspots": 0,
"toReviewSecurityHotspots": 0,
- "resolvedSecurityHotspots": 0,
+ "reviewedSecurityHotspots": 0,
"distribution": [],
"activeRules": 0,
"totalRules": 0
diff --git a/sonar-core/src/main/resources/org/sonar/l10n/core.properties b/sonar-core/src/main/resources/org/sonar/l10n/core.properties
index 74319838eaf..d089f70e9d4 100644
--- a/sonar-core/src/main/resources/org/sonar/l10n/core.properties
+++ b/sonar-core/src/main/resources/org/sonar/l10n/core.properties
@@ -618,20 +618,14 @@ issue.transition.close=Close
issue.transition.close.description=
issue.transition.wontfix=Resolve as won't fix
issue.transition.wontfix.description=This issue can be ignored because the rule is irrelevant in this context. Its effort won't be counted.
-issue.transition.detect=Detect
-issue.transition.detect.description=A Vulnerability exists here and must be fixed.
-issue.transition.dismiss=Dismiss
-issue.transition.dismiss.description=This vulnerability can't be fixed as is and needs more details from a security expert.
-issue.transition.reject=Reject
-issue.transition.reject.description=The fix has been reviewed by a security expert and the vulnerability is still there. Code must be fixed again.
-issue.transition.requestreview=Request review
-issue.transition.requestreview.description=The code has been fixed and a review by a security expert is required to confirm it.
-issue.transition.accept=Accept
-issue.transition.accept.description=The code has been fixed and the vulnerability has been removed. The issue can be closed.
-issue.transition.clear=Clear
-issue.transition.clear.description=There is no vulnerability in the code. The issue can be closed.
-issue.transition.reopenhotspot=Reopen
-issue.transition.reopenhotspot.description=This security hotspot should be analyzed again by a security expert.
+issue.transition.setinreview = Set as In Review
+issue.transition.setinreview.description = A review is required to check for a vulnerability
+issue.transition.resolveasreviewed = Resolve as Reviewed
+issue.transition.resolveasreviewed.description = There is no vulnerability in the code
+issue.transition.openasvulnerability = Open as Vulnerability
+issue.transition.openasvulnerability.description = There's a vulnerability in the code that must be fixed
+issue.transition.resetastoreview = Reset as security hotspot To Review
+issue.transition.resetastoreview.description = The security hotspot should be analyzed again
issue.set_severity=Change Severity
issue.set_type=Change Type
diff --git a/sonar-plugin-api/src/main/java/org/sonar/api/issue/DefaultTransitions.java b/sonar-plugin-api/src/main/java/org/sonar/api/issue/DefaultTransitions.java
index b000f18aa21..9888ee33983 100644
--- a/sonar-plugin-api/src/main/java/org/sonar/api/issue/DefaultTransitions.java
+++ b/sonar-plugin-api/src/main/java/org/sonar/api/issue/DefaultTransitions.java
@@ -42,16 +42,6 @@ public interface DefaultTransitions {
String WONT_FIX = "wontfix";
/**
- * @since 7.3
- */
- String DETECT = "detect";
- String DISMISS = "dismiss";
- String REJECT = "reject";
- String ACCEPT = "accept";
- String CLEAR = "clear";
- String REOPEN_HOTSPOT = "reopenhotspot";
-
- /**
* @since 7.8
*/
String SET_AS_IN_REVIEW = "setinreview";
@@ -67,8 +57,13 @@ public interface DefaultTransitions {
String OPEN_AS_VULNERABILITY = "openasvulnerability";
/**
+ * @since 7.8
+ */
+ String RESET_AS_TO_REVIEW = "resetastoreview";
+
+ /**
* @since 4.4
*/
List<String> ALL = unmodifiableList(asList(CONFIRM, UNCONFIRM, REOPEN, RESOLVE, FALSE_POSITIVE, WONT_FIX, CLOSE,
- DETECT, DISMISS, REJECT, SET_AS_IN_REVIEW, ACCEPT, CLEAR, REOPEN_HOTSPOT, RESOLVE_AS_REVIEWED, OPEN_AS_VULNERABILITY));
+ SET_AS_IN_REVIEW, RESOLVE_AS_REVIEWED, OPEN_AS_VULNERABILITY,RESET_AS_TO_REVIEW));
}
diff --git a/sonar-ws/src/main/protobuf/ws-security.proto b/sonar-ws/src/main/protobuf/ws-security.proto
index 17b894f8673..67d7c7e7264 100644
--- a/sonar-ws/src/main/protobuf/ws-security.proto
+++ b/sonar-ws/src/main/protobuf/ws-security.proto
@@ -37,7 +37,7 @@ message SecurityStandardCategoryStatistics {
optional int64 vulnerabilityRating = 3;
optional int64 inReviewSecurityHotspots = 4;
optional int64 toReviewSecurityHotspots = 5;
- optional int64 resolvedSecurityHotspots = 6;
+ optional int64 reviewedSecurityHotspots = 6;
repeated CweStatistics distribution = 7;
optional int64 activeRules = 8;
optional int64 totalRules = 9;
@@ -49,7 +49,7 @@ message CweStatistics {
optional int64 vulnerabilityRating = 3;
optional int64 inReviewSecurityHotspots = 4;
optional int64 toReviewSecurityHotspots = 5;
- optional int64 resolvedSecurityHotspots = 6;
+ optional int64 reviewedSecurityHotspots = 6;
optional int64 activeRules = 7;
optional int64 totalRules = 8;
}