-
Notifications
You must be signed in to change notification settings - Fork 36
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[WSS-711]Introduce a system property "fips.enabled" so that WSS4J can… #313
base: master
Are you sure you want to change the base?
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I have a problem with making RSA 1.5 a default as it is not secure, see https://cxf.apache.org/note-on-cve-2011-2487.html
Hi @coheigea , Thanks for the feedback! I made RSA 1.5 as default because for the FIPS security provider
there is only
And no Also in jdk.crypto.cryptoki/share/classes/sun/security/pkcs11/P11RSACipher.java(used in FIPS mode)
This is why I get
If still use RSA-OAEP as default key transport algos. I'm double checking this concern from the related specs and asking the JDK expert why OAEPPadding isn't available in FIPS mode JDK/OS. Best Regards |
Hi @coheigea , Just FYI, after talking to OS and JDK guys who working in related area, I sent a feature request to support OAEP padding for SunPKCS11 security provider. Cheers |
Hi @jonas19 , I'm gonna revisit this issue soon. Freeman |
Thanks @ffang ! Meanwhile, is there a way to use wss4j on a FIPS env? |
… work easier in FIPS mode
Hi @coheigea , I just pushed another commit. I think for now to be able to run on FIPS machine/JDK, we need to introduce org.bouncycastle:bc-fips as an optional dependency, which supports RSA-OAEP padding. So this patch introduces a system propery "fips.enabled", when it is true, we change symEncAlgo from "AES_CBC" to "AES_GCM"(as CBC isn't allowed in FIPS). Also for the JasyptPasswordEncryptor, we change DEFAULT_ALGORITHM from PBEWithMD5AndTripleDES(this isn't allowed in FIPS) to PBEWithHmacSHA512AndAES_256, which requires Random Generator as PKCS11(the default SHA1PRNG isn't allowed in FIPS). Also there are follow up changes in CXF to reflect this change in WSS4J. WDYT? Thanks! |
… work easier in FIPS mode