-
Notifications
You must be signed in to change notification settings - Fork 727
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
Add RSA PKCS#1 1.5 signing #208
Comments
OK, I will break this down:
|
Closed
This all landed! Awesome work! In the last set of changes, I tweaked the example to match the ring style (qualifying Thanks a ton for doing this! |
I should add: #225 contains a laundry list of follow-up tasks for improving the RSA internals. |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
There's a bunch of code to do the low-level RSA operation in
GFp_rsa_private_transform
incrypto/rsa/rsa_impl.c
that should be used.We need a new implementation of PKCS#1 1.5 padding (in Rust, unless there's a reason it can't be done in Rust for some reason).
We can (should, unless we're going to somehow implement blinding in Rust) use the blinding code in crypto/rsa/blinding.c. But, we need to write new Rust code that manages the pool of
BN_BLINDING
s in some kind of thread-safe way. I guess this largely depends on the threading model chosen for the signing API.NIST publishes test vectors for this, and testing using those test vectors are the minimum acceptable testing. Note that NIST's test vectors are in a format that's not really usable by ring's testing framework. The comments in
src/rsa_pkcs1_verify_tests.txt
explain what I did to reformat NIST's RSA PKCS#1 1.5 verification test vectors for ring; a similar thing needs to be done for the signing test vectors.This is complicated by the fact that there's no code for deserializing RSA private keys or for serializing RSA private keys. Adding the deserialization/serialization is probably a big task on its own so it might be worth splitting into a separate bug.
See also #205 for any general requirements on signing APIs.
The text was updated successfully, but these errors were encountered: