Installation of Bouncy Castle for use in TomEE itself is done in two steps:
$JAVA_HOME/jre/lib/ext
directory$JAVA_HOME/jre/lib/security/java.security
fileThe entry to java.security
will look something like the following:
security.provider.N=org.bouncycastle.jce.provider.BouncyCastleProvider
Replace N
with the order of precedence you would like to give Bouncy Castle in comparison to the
other providers in the file. Recommended would be the last entry in the list -- N
being the higest number in the list.
Warning that configuring Bouncy Castle as the first provider, security.provider.1
, may cause JVM errors.