Skip to content

Conversation

UndeadFu
Copy link

when I use rsa encrypt with "RAW", the result is wrong when the input contains no-ascii data.
I don't know if it's nesessary to "encodeUtf8(input)", but the bug fixed when i remove it.

@CLAassistant
Copy link

CLA assistant check
Thank you for your submission! We really appreciate it. Like many open source projects, we ask that you sign our Contributor License Agreement before we can accept your contribution.


x seems not to be a GitHub user. You need a GitHub account to be able to sign the CLA. If you have already a GitHub account, please add the email address used for this commit to your account.
You have signed the CLA already but the status is still pending? Let us recheck it.

@ThomasNotTom
Copy link

It seems to fail the unit tests. Might be worth double checking what the 'expected behaviour' actually is. It may be better to add your implementation as an option, rather than altering the standard implementation?

@UndeadFu
Copy link
Author

It seems to fail the unit tests. Might be worth double checking what the 'expected behaviour' actually is. It may be better to add your implementation as an option, rather than altering the standard implementation?

Thank you.I think the failure is caused by some wrong of the unit tests. The input of rsa should be seem as 'raw bytes' but not 'utf-8'. The encoding should be choose by user. Like the rightBottom in this img.
image

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

Successfully merging this pull request may close these issues.

3 participants