14 Commits

Author SHA1 Message Date
Tony Arcieri
35372d9516
Refactor PaddingScheme into a trait (#244)
Splits up the `PaddingScheme` enum into four structs, named after the
previous variants of the struct (adopting capitalization from the Rust
API guidelines):

- `oaep::Oaep`
- `pkcs1v15::{Pkcs1v15Encrypt, Pkcs1v15Sign}`
- `pss::Pss`

All of these are re-exported from the toplevel.

Each of these structs impls one or more of the following traits:

- `PaddingScheme`: used for encryption
- `SignatureScheme`: used for signing

The `PaddingScheme` constructors have been remapped as follows:

- `new_oaep` => `Oaep::new`
- `new_oaep_with_label` => `Oaep::new_with_label`
- `new_oaep_with_mgf_hash` => `Oaep::new_with_mgf_hash`
- `new_oaep_with_mgf_hash_with_label` => `Oaep::new_with_mgf_hash_and_label`
- `new_pkcs1v15_encrypt` => `Pkcs1v15Encrypt`
- `new_pkcs1v15_sign` => `Pkcs1v15Sign::new`
- `new_pkcs1v15_sign_raw` => `Pkcs1v15Sign::new_raw`
- `new_pss` => `Pss::{new, new_blinded}`
- `new_pss_with_salt` => `Pss::{new_with_salt new_blinded_with_salt}`
2023-01-10 13:59:31 -07:00
Tony Arcieri
8f41d209e6
Fix benches (#225)
...and test they build in CI
2022-11-15 10:38:48 -07:00
Artyom Pavlov
cf27569687
Replace rand dependency with rand_core (#148) 2022-03-13 19:50:05 +00:00
dignifiedquire
7a1eaa0329 refactor: rename RSA* to Rsa
This matches the rust naming convention better.

Closes #24
2021-07-26 23:25:13 +02:00
dignifiedquire
84bfd0d9eb fix benchmarks 2020-06-11 13:20:51 +02:00
dignifiedquire
062ab54739 fix benches 2020-03-06 21:24:09 +01:00
Patrick D Hayes
8e5ce15e18 feat(deps): update dependencies 2019-03-25 16:40:55 +01:00
phayes
ee66f6a505
rustfmt on benches 2019-03-18 09:39:35 -07:00
phayes
558d34f155
Moving to 2018 edition and applying 2018 idioms 2019-03-18 09:34:29 -07:00
dignifiedquire
ea09d34c75 feat: add support for SHA3 hashes 2019-02-25 10:38:45 +01:00
dignifiedquire
2608f42640 refactor: remove prime and math tooling now in num_bigint 2019-01-15 21:05:45 +01:00
dignifiedquire
79bb8fa9b3 test(bench): add decrypt and sign benchmarks 2018-07-24 15:09:03 +02:00
dignifiedquire
124e4b6dc7 feat(prime): implement RandPrime 2018-07-19 16:01:17 +02:00
dignifiedquire
dc021a4217 test(prime): add benchmarks 2018-07-18 23:03:47 +02:00