Allow RSADecrypter to work in setups where private key material is not exposed

Issue #184 resolved
Dimitar A. Stoikov created an issue

Hi All,

We would like to modify the com.nimbusds.jose.crypto.RSADecrypter's contract so that it does not require private key instances to implement the java.security.interfaces.RSAPrivateKey interface.

This will allow the RSADecrypter to be used with keys that cannot expose private material and consequently do not advertise themselves as java.security.interfaces.RSAPrivateKey-s.

Attached please find a patch. It replaces RSAPrivateKey with PrivateKey in the same way as it is done for the RSASSASigner class.

Thank you!

Best Regards, Dimitar

P.S. The patch is based on the 4.15 release.

Comments (5)

  1. Vladimir Dzhuvinov

    Thanks for the suggestion, this makes good sense and will align the decryption api with the one for rsa signing. Stay tuned for a new release!

  2. Log in to comment