Skip to content

Commit d6ec408

Browse files
committed
chore(pmd): enable a couple of new rules from PMD 6.4.0
Quote from https://pmd.github.io/2018/05/29/PMD-6.4.0/#new-rules % The new Java rule HardCodedCryptoKey (java-security) detects hard coded keys used for encryption. It is recommended to store keys outside of the source code. The new Java rule IdenticalCatchBranches (java-codestyle) finds catch blocks, that catch different exception but perform the same exception handling and thus can be collapsed into a multi-catch try statement. %
1 parent 524db55 commit d6ec408

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

src/main/config/pmd.xml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -89,6 +89,7 @@
8989
<rule ref="category/java/codestyle.xml/FieldDeclarationsShouldBeAtStartOfClass" />
9090
<rule ref="category/java/codestyle.xml/ForLoopShouldBeWhileLoop" />
9191
<rule ref="category/java/codestyle.xml/GenericsNaming" />
92+
<rule ref="category/java/codestyle.xml/IdenticalCatchBranches" />
9293
<!--<rule ref="category/java/codestyle.xml/LocalHomeNamingConvention" />-->
9394
<!--<rule ref="category/java/codestyle.xml/LocalInterfaceSessionNamingConvention" />-->
9495
<!--<rule ref="category/java/codestyle.xml/LocalVariableCouldBeFinal" />-->
@@ -316,6 +317,7 @@
316317
<rule ref="category/java/performance.xml/UseStringBufferForStringAppends" />
317318
<rule ref="category/java/performance.xml/UseStringBufferLength" />
318319

320+
<rule ref="category/java/security.xml/HardCodedCryptoKey" />
319321
<rule ref="category/java/security.xml/InsecureCryptoIv" />
320322

321323
</ruleset>

0 commit comments

Comments
 (0)