Skip to content

Commit

Permalink
java:chore - Adding improvements on Java Rules
Browse files Browse the repository at this point in the history
In this commit I changed to add Safe and Unsafe code in
all rules of the java. Reference from issue #630 and #1020.

Signed-off-by: Wilian Gabriel <wilian.silva@zup.com.br>
  • Loading branch information
wiliansilvazup committed Mar 17, 2022
1 parent 5570397 commit 78aa7d6
Show file tree
Hide file tree
Showing 6 changed files with 1,836 additions and 967 deletions.
1,695 changes: 997 additions & 698 deletions internal/services/engines/java/rules.go

Large diffs are not rendered by default.

6 changes: 6 additions & 0 deletions internal/services/engines/java/rules_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -837,6 +837,12 @@ func TestRulesSafeCode(t *testing.T) {
Src: SampleSafeHSJAVA134,
Filename: filepath.Join(tempDir, fmt.Sprintf("%s%s", "HS-JAVA-134", ".test")),
},
{
Name: "HS-JAVA-144",
Rule: NewNullCipherInsecure(),
Src: SampleSafeHSJAVA144,
Filename: filepath.Join(tempDir, fmt.Sprintf("%s%s", "HS-JAVA-134", ".test")),
},
{
Name: "HS-JAVA-145",
Rule: NewUnsafeHashEquals(),
Expand Down
Loading

0 comments on commit 78aa7d6

Please sign in to comment.