Silent InsecureCipherMode Bazel has error-prone enabled which cases a build failure when creating the Cipher. This is a demo plugin on how to secure a config file with encryption: it is explicitily not targeting the highest level of security. Change-Id: Ia0058bcea76539d4f75de0bed3bc27343a914a2c
diff --git a/src/main/java/com/googlesource/gerrit/plugins/secureconfig/PBECodec.java b/src/main/java/com/googlesource/gerrit/plugins/secureconfig/PBECodec.java index 9b7c1ba..e592eaf 100644 --- a/src/main/java/com/googlesource/gerrit/plugins/secureconfig/PBECodec.java +++ b/src/main/java/com/googlesource/gerrit/plugins/secureconfig/PBECodec.java
@@ -88,6 +88,7 @@ private Cipher getCipher() throws NoSuchAlgorithmException, NoSuchProviderException, NoSuchPaddingException { + @SuppressWarnings("InsecureCipherMode") Cipher encoder = Cipher.getInstance(config.getCipher(), config.getJCEProvider()); return encoder;