diff options
author | mark.j.leonard <mark.j.leonard@gmail.com> | 2019-03-12 12:39:57 +0000 |
---|---|---|
committer | mark.j.leonard <mark.j.leonard@gmail.com> | 2019-03-12 12:39:57 +0000 |
commit | f4f3d47609349f511ff6ff1a8589ab5cc181d92c (patch) | |
tree | 2590226bb86f2c7ed07b1d7e8815e0b390c0fe09 /src | |
parent | 6b74f2a06df4fd3bfb9f1b368f46db28f1e95ecb (diff) |
Fix Sonar vulnerability for SystemProperty enum
Sonar wrongly identifies the public set() method as a setter for the
enum and logs a violation (enums should not be mutable).
Change the access level modifier (to make it not public) as lowering the
visibility suppresses the Sonar false positive.
Change-Id: Ic3e5ade0410a7702a89e22fd72b6fbe4d8db0dc4
Issue-ID: AAI-2057
Signed-off-by: mark.j.leonard <mark.j.leonard@gmail.com>
Diffstat (limited to 'src')
-rw-r--r-- | src/main/java/org/onap/aai/validation/ValidationServiceApplication.java | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/main/java/org/onap/aai/validation/ValidationServiceApplication.java b/src/main/java/org/onap/aai/validation/ValidationServiceApplication.java index 5db497d..52cb339 100644 --- a/src/main/java/org/onap/aai/validation/ValidationServiceApplication.java +++ b/src/main/java/org/onap/aai/validation/ValidationServiceApplication.java @@ -72,7 +72,7 @@ public class ValidationServiceApplication extends SpringBootServletInitializer { return StringUtils.decrypt(propertyValue); } - public void set(String propertyValue) { + protected void set(String propertyValue) { System.setProperty(propertyName, propertyValue); } } |