Hey, I tried adding those lines without success. Still getting:
Running com.cloud.utils.crypto.RSAHelperTest 2016-12-08 15:16:13,276 INFO [utils.crypt.RSAHelper] (main:) [ignored]error during public key encryption: Unsupported format 2016-12-08 15:16:13,618 INFO [utils.crypt.RSAHelper] (main:) [ignored]error during public key encryption: JCE cannot authenticate the provider BC Tests run: 2, Failures: 1, Errors: 0, Skipped: 0, Time elapsed: 0.721 sec <<< FAILURE! - in com.cloud.utils.crypto.RSAHelperTest testEncryptWithRSA(com.cloud.utils.crypto.RSAHelperTest) Time elapsed: 0.34 sec <<< FAILURE! java.lang.AssertionError: null at org.junit.Assert.fail(Assert.java:86) at org.junit.Assert.assertTrue(Assert.java:41) at org.junit.Assert.assertNotNull(Assert.java:712) at org.junit.Assert.assertNotNull(Assert.java:722) at com.cloud.utils.crypto.RSAHelperTest.testEncryptWithRSA(RSAHelperTest.java:45) I checked my mvn version. I am running mvn 3.2.1 and JDK 1.7.0_55. I also tried updating the dependencies (-U) On Thu, Dec 8, 2016 at 2:20 PM, Rohit Yadav <bhais...@apache.org> wrote: > Hi Will and Patrick, > > I'm not able to reproduce the issue, we've recently upgraded the > bountycastle dependency to v1.55 on both 4.9 and master branch. > Travis too appears to pass and along with that Trillian/blueorangutan based > packaging: https://travis-ci.org/apache/cloudstack/builds/182254749 > > Can you check if you're using JDK 1.7? Is your JDK/dependencies able to > provide for BC. In the failing test, can you try and see if with following > changes your unit test pass: > > --- a/utils/src/test/java/com/cloud/utils/crypto/RSAHelperTest.java > +++ b/utils/src/test/java/com/cloud/utils/crypto/RSAHelperTest.java > @@ -22,11 +22,18 @@ package com.cloud.utils.crypto; > import static org.junit.Assert.assertNotNull; > import static org.junit.Assert.assertNull; > > +import org.bouncycastle.jce.provider.BouncyCastleProvider; > import org.junit.Test; > > import com.cloud.utils.crypt.RSAHelper; > +import java.security.Security; > > public class RSAHelperTest { > + > + public RSAHelperTest() { > + Security.addProvider(new BouncyCastleProvider()); > + } > + > > For reference, here is my Maven/JDK/env details: > > $ mvn -version > Apache Maven 3.3.9 > Maven home: /usr/share/maven > Java version: 1.7.0_80, vendor: Oracle Corporation > Java home: /usr/lib/jvm/java-7-oracle/jre > Default locale: en_US, platform encoding: UTF-8 > OS name: "linux", version: "4.4.0-45-generic", arch: "amd64", family: > "unix" > > Regards. > > On Fri, Dec 9, 2016 at 12:03 AM, Will Stevens <wstev...@cloudops.com> > wrote: > > > Hey Guys, > > I am not able to build master right now. I can build it if I specify "", > > but if I let the tests run, I get the following error. > > > > Running com.cloud.utils.backoff.impl.ConstantTimeBackoffTest > > 2016-12-08 13:29:28,099 INFO [backoff.impl.ConstantTimeBackoff] > > (Thread-0:) Thread Thread-0 interrupted while waiting for retry > > 2016-12-08 13:29:28,202 DEBUG [backoff.impl.ConstantTimeBackoffTest] > > (main:) thread started > > 2016-12-08 13:29:28,202 DEBUG [backoff.impl.ConstantTimeBackoffTest] > > (Thread-1:) before > > 2016-12-08 13:29:28,306 DEBUG [backoff.impl.ConstantTimeBackoffTest] > > (main:) testing wakeup > > 2016-12-08 13:29:28,307 INFO [backoff.impl.ConstantTimeBackoff] > > (Thread-1:) Thread Thread-1 interrupted while waiting for retry > > 2016-12-08 13:29:28,307 DEBUG [backoff.impl.ConstantTimeBackoffTest] > > (Thread-1:) after > > Tests run: 6, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 0.524 sec > > - in com.cloud.utils.backoff.impl.ConstantTimeBackoffTest > > Running com.cloud.utils.crypto.EncryptionSecretKeyCheckerTest > > 2016-12-08 13:29:28,317 DEBUG [utils.crypt.EncryptionSecretKeyChecker] > > (main:) Encryption Type: null > > 2016-12-08 13:29:28,320 DEBUG [utils.crypt.EncryptionSecretKeyChecker] > > (main:) Encryption Type: file > > Tests run: 1, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 0.015 sec > > - in com.cloud.utils.crypto.EncryptionSecretKeyCheckerTest > > Running com.cloud.utils.crypto.RSAHelperTest > > 2016-12-08 13:29:28,639 INFO [utils.crypt.RSAHelper] (main:) > > [ignored]error during public key encryption: Unsupported format > > 2016-12-08 13:29:29,196 INFO [utils.crypt.RSAHelper] (main:) > > [ignored]error during public key encryption: JCE cannot authenticate the > > provider BC > > Tests run: 2, Failures: 1, Errors: 0, Skipped: 0, Time elapsed: 0.871 sec > > <<< FAILURE! - in com.cloud.utils.crypto.RSAHelperTest > > testEncryptWithRSA(com.cloud.utils.crypto.RSAHelperTest) Time elapsed: > > 0.561 sec <<< FAILURE! > > java.lang.AssertionError: null > > at org.junit.Assert.fail(Assert.java:86) > > at org.junit.Assert.assertTrue(Assert.java:41) > > at org.junit.Assert.assertNotNull(Assert.java:712) > > at org.junit.Assert.assertNotNull(Assert.java:722) > > at com.cloud.utils.crypto.RSAHelperTest.testEncryptWithRSA( > > RSAHelperTest.java:38) > > ... > > Failed tests: > > RSAHelperTest.testEncryptWithRSA:38 null > > > > Is this a known issue? > > > > Thanks, > > > > *Will STEVENS* > > Lead Developer > > > > <https://goo.gl/NYZ8KK> > > > > >