This is an automated email from the ASF dual-hosted git repository. thenatog pushed a commit to branch NIFIREG-286 in repository https://gitbox.apache.org/repos/asf/nifi-registry.git
commit aadd74af2d3ec0912193ca55510dcc33c973285b Author: thenatog <[email protected]> AuthorDate: Wed Jul 24 12:25:22 2019 -0400 NIFIREG-286 - Upgraded bouncycastle deps --- nifi-registry-core/nifi-registry-framework/pom.xml | 2 +- nifi-registry-core/nifi-registry-properties/pom.xml | 2 +- .../registry/properties/AESSensitivePropertyProviderTest.groovy | 9 +++++---- nifi-registry-core/nifi-registry-security-utils/pom.xml | 4 ++-- 4 files changed, 9 insertions(+), 8 deletions(-) diff --git a/nifi-registry-core/nifi-registry-framework/pom.xml b/nifi-registry-core/nifi-registry-framework/pom.xml index 8fec098..3ab8101 100644 --- a/nifi-registry-core/nifi-registry-framework/pom.xml +++ b/nifi-registry-core/nifi-registry-framework/pom.xml @@ -246,7 +246,7 @@ <dependency> <groupId>org.bouncycastle</groupId> <artifactId>bcprov-jdk15on</artifactId> - <version>1.55</version> + <version>1.61</version> </dependency> <dependency> <groupId>commons-io</groupId> diff --git a/nifi-registry-core/nifi-registry-properties/pom.xml b/nifi-registry-core/nifi-registry-properties/pom.xml index e945b21..51d0d7e 100644 --- a/nifi-registry-core/nifi-registry-properties/pom.xml +++ b/nifi-registry-core/nifi-registry-properties/pom.xml @@ -49,7 +49,7 @@ <dependency> <groupId>org.bouncycastle</groupId> <artifactId>bcprov-jdk15on</artifactId> - <version>1.55</version> + <version>1.61</version> </dependency> <dependency> <groupId>org.codehaus.groovy</groupId> diff --git a/nifi-registry-core/nifi-registry-properties/src/test/groovy/org/apache/nifi/registry/properties/AESSensitivePropertyProviderTest.groovy b/nifi-registry-core/nifi-registry-properties/src/test/groovy/org/apache/nifi/registry/properties/AESSensitivePropertyProviderTest.groovy index 98fdd9b..ed071ac 100644 --- a/nifi-registry-core/nifi-registry-properties/src/test/groovy/org/apache/nifi/registry/properties/AESSensitivePropertyProviderTest.groovy +++ b/nifi-registry-core/nifi-registry-properties/src/test/groovy/org/apache/nifi/registry/properties/AESSensitivePropertyProviderTest.groovy @@ -277,9 +277,10 @@ class AESSensitivePropertyProviderTest extends GroovyTestCase { SensitivePropertyProvider spp = new AESSensitivePropertyProvider(Hex.decode(getKeyOfSize(keySize))) logger.info("Initialized ${spp.name} with key size ${keySize}") String cipherText = spp.protect(PLAINTEXT) + // Remove the IV from the "complete" cipher text final String MISSING_IV_CIPHER_TEXT = cipherText[18..-1] - logger.info("Manipulated ${cipherText} to\n${MISSING_IV_CIPHER_TEXT.padLeft(163)}") + logger.info("Manipulated ${cipherText} to\n${MISSING_IV_CIPHER_TEXT.padLeft(172)}") def msg = shouldFail(IllegalArgumentException) { spp.unprotect(MISSING_IV_CIPHER_TEXT) @@ -288,9 +289,9 @@ class AESSensitivePropertyProviderTest extends GroovyTestCase { // Remove the IV from the "complete" cipher text but keep the delimiter final String MISSING_IV_CIPHER_TEXT_WITH_DELIMITER = cipherText[16..-1] - logger.info("Manipulated ${cipherText} to\n${MISSING_IV_CIPHER_TEXT_WITH_DELIMITER.padLeft(163)}") + logger.info("Manipulated ${cipherText} to\n${MISSING_IV_CIPHER_TEXT_WITH_DELIMITER.padLeft(172)}") - def msgWithDelimiter = shouldFail(DecoderException) { + def msgWithDelimiter = shouldFail(IllegalArgumentException) { spp.unprotect(MISSING_IV_CIPHER_TEXT_WITH_DELIMITER) } logger.expected("${msgWithDelimiter} for keySize ${keySize} and cipher text [${MISSING_IV_CIPHER_TEXT_WITH_DELIMITER}]") @@ -299,7 +300,7 @@ class AESSensitivePropertyProviderTest extends GroovyTestCase { assert msg == "The cipher text does not contain the delimiter || -- it should be of the form Base64(IV) || Base64(cipherText)" // Assert - assert msgWithDelimiter =~ "unable to decode base64 string" + assert msgWithDelimiter == "The IV (0 bytes) must be at least 12 bytes" } } diff --git a/nifi-registry-core/nifi-registry-security-utils/pom.xml b/nifi-registry-core/nifi-registry-security-utils/pom.xml index 2425209..9fb5f4f 100644 --- a/nifi-registry-core/nifi-registry-security-utils/pom.xml +++ b/nifi-registry-core/nifi-registry-security-utils/pom.xml @@ -26,12 +26,12 @@ <dependency> <groupId>org.bouncycastle</groupId> <artifactId>bcprov-jdk15on</artifactId> - <version>1.55</version> + <version>1.61</version> </dependency> <dependency> <groupId>org.bouncycastle</groupId> <artifactId>bcpkix-jdk15on</artifactId> - <version>1.55</version> + <version>1.61</version> </dependency> <dependency> <groupId>org.apache.commons</groupId>
