I’m trying to use the bouncycastle lib but I keep getting this error:
java.lang.NoSuchMethodError: ‘org.bouncycastle.util.StringList org.bouncycastle.util.Strings.newList()’
at org.bouncycastle.bcpg.ArmoredInputStream.(ArmoredInputStream.java:132)
at org.bouncycastle.bcpg.ArmoredInputStream.(ArmoredInputStream.java:146)
at org.bouncycastle.openpgp.PGPUtil.getDecoderStream(PGPUtil.java:391)
I’m referencing it was I’ve found in another topic:
I tried to reproduce your error but without success.
I put the following line: new ArmoredInputStream( null, false ); (That should be enough to reproduce your error I think) in an app but it executed without problem on Enonic XP 7.6
I first thought that maybe it is linked to the fact that you have both “fips” and “jdk15on”. Because they are not supposed to be used together. Do you have a requirement to use fips?
But even with the dependencies you copied, it still run without problem. Any chance the code of your application is public? Or do you have a minimal way to reproduce your issue?
After running through other third-party libs I’ve found out that one of them had an old version of bouncycastle in it and after excluding it from there everything started to work as intended.