Skip to content
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

Encrypt/Decrypt Problem with RSA #7

Closed
catcherwong opened this issue Jan 17, 2018 · 1 comment
Closed

Encrypt/Decrypt Problem with RSA #7

catcherwong opened this issue Jan 17, 2018 · 1 comment
Labels

Comments

@catcherwong
Copy link
Contributor

When calling RSAEncrypt and RSADecrypt method in Linux/OS X , those two methods can not run well !

The main reason is that both Linux and OS X don't support RSAEncryptionPadding.OaepSHA512 !!

And RSAEncryptionPadding.OaepSHA512 is not optional in the source code !

Following EncryptProvider.cs#L364 and EncryptProvider.cs#L383

This is also the reason why the Unit Tests of RSA can not pass in my Mac book.

When I change RSAEncryptionPadding from OaepSHA512 to Pkcs1 , it runs well !

When calling RSA.Create() , it will create an instance of RSAOpenSsl in Linux , RSASecurityTransforms in OS X and RSACng in Windows.

Is there any other considerations to use RSAEncryptionPadding.OaepSHA512 ?

@myloveCc
Copy link
Owner

myloveCc commented Jan 23, 2018

Thanks for your pull request. I just test on windows.

At version 2.0.5 ,you can set RSAEncryptionPadding as you like.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants