jce - Using bouncycastle in Websphere liberty profile -
Our application uses Bonsikastl I'm trying to now deploy my app on websphere independence profile and bottom error getting
[err] java.io.IOException: manufacturing error Mac: java.lang.SecurityException: JCE can not be certified provider BC [Err] org.bouncycastle.jce.provider.JDKPKCS12KeyStore.engineLoad ([err] .loadPrivateKeyByIssuer Unknown Source) [err on java.security.KeyStore.load on] (KeyStore.java:1214) on com.manh.jwt.JwtKeyManager (JwtKeyManager.java:213) so instead of Web-INF / lib having bouncycastle jar dir, I created a shared lib and as a the library added privateLibraryRef < / Strong> I still get the same error in my web application Here is my server.xml for your reference
. & Lt ;. Server Details = "New Server" & gt; & Lt ;! - Enable features - & gt; & Lt; FeatureManager & gt; & Lt; Feature & gt; Jsp-2.2 & lt; / Feature & gt; & Lt; Feature & gt; Servlet-3.0 & lt; / Feature & gt; & Lt; / FeatureManager & gt; & Lt; WebContainer deferServletLoad = "false" /> & Lt; HttpEndpoint id = "defaultHttpEndpoint" host = "localhost" httpPort = "20000" httpsPort = "9443" /> & Lt; Library id = "configResources" & gt; & Lt; Folder directory = "$ {server.config.dir} / conf" /> & Lt; / Library & gt; & Lt; Library id = "bc" & gt; & Lt; Fileset dir = "$ {server.config.dir} / bclib" includes = "* .jar" /> & Lt; / Library & gt; & Lt; WebApplication name = "scope" location = "scope.war" reference = "/" & gt; & Lt; Classloader privateLibraryRef = "configResources, bc" /> & Lt; / WebApplication & gt; & Lt; / Server & gt; Is there any other setting that I can try to do this work?
WAS magic here to get Bouncy Castle cryptography to work with Liberty, which Stacked products should work as well.
- Create the "jvm.options" file in the server work directory. In a default installation, add this WLP / usr / server /
- to "jvm.options" file. One
. -Djava.ext.dirs = // I have tested this with / opt / fun / libs and wlp / usr / servers / defaultserver and wlp / usr / servers / defaultserver / libs. All three worked if it included a path to the web-INF / Lib directory, it failed. B. -Dorg.osgi.framework.bootdelegation = org.bouncycastle.jce.provider - WEB-INF / lib java.ext.dirs defined directory to copy the bouncy castle jar directory (see above).
- Stop and start the server, as you are changing the JVM logic.
- Check the application or stacked product.
Comments
Post a Comment