-
Notifications
You must be signed in to change notification settings - Fork 95
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
CRYPTO-162 openSslCipher support engine. #165
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.
@wenwj0
Thank you for the PR. See the scattered comments.
-1 until this PR has tests to cover all the new code.
@@ -378,4 +378,7 @@ protected void finalize() throws Throwable { | |||
clean(); | |||
} | |||
|
|||
public void engineSetDefaultCiphers(String engineId){ |
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.
Missing Javadoc, fix formatting.
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.
ok
@@ -60,6 +60,11 @@ public OpenSslCipher(final Properties props, final String transformation) // NOP | |||
} | |||
|
|||
openSslEngine = OpenSsl.getInstance(transformation); | |||
|
|||
String engineId = props.getProperty(CryptoCipherFactory.CIPHER_ENGINE_KEY); | |||
if(engineId != null && !engineId.isEmpty()) { |
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.
Fix formatting.
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.
ok
This PR is a wrapper over OpenSSL, but If we want to test it, we need to install a specific engine. In my case, i installed kae engine and it worked. But I have no idea that which engine should i choose in the unit test. |
You could use the Intel rdrand engine in the unit test. It's always available in OpenSSL for machines of the Ivy Bridge or later generation. |
No description provided.