`RsaPrivateKey::validate()` does not ensure `precompute()` won't fail
Nessuno ha ancora preso questa issue.
Valutazione
- Difficoltà
- 3/5
- Tempo stimato
- 1-2 giorni
- Idoneità per principianti
- 45/100
- Tipo di issue
- Bug
- Chiarezza
- Abbastanza chiara
- Stato di attività
- Ferma
- Stack tecnologico
- rust
- Ambito
- cryptography
Direzione di ricerca
Start with RsaPrivateKey::validate(), RsaPrivateKey::from_components(), and the precompute() call described in the issue. Check whether valid keys can fail during precomputation and whether the error is currently discarded. Done means validation and construction handle precompute failures consistently, with relevant tests covering the failure path.
Scritto dal modello di indicizzazione a partire dal testo della issue.
Descrizione
In RsaPrivateKey::from_components(), precompute() errors are ignored because it is claimed that the previous call to validate() guarantees it succeeds.
First of all, this is not the case - there can be bugs in precompute itself. I bumped into it while working on #506. In
let q_mod_p = BoxedMontyForm::new(q_mod_p, p_params.clone());
where I accidentally typed q_params instead of p_params, so the subsequent inversion failed.
Second, what are we even achieving by ignoring the errors there? Are there valid keys for which the values cannot be precomputed? from_components() already returns a Result, we might as well just forward the precompute() error to it.
- Lingua principale
- Rust
- Stelle
- 673
- Fork
- 190
- Metriche di merge delle PR
- Nessuna PR unita negli ultimi 30g
Guida per i contributori
Nessuna guida per i contributori indicizzata per questo repository
Come iniziare
- Leggi tutta la issue e poi la guida ai contributi del progetto.
- Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
- Fai un fork del repository e lavora su un branch.
- Apri una pull request che faccia riferimento al numero della issue.
Altre issue di RustCrypto/RSA
-
Bump MSRV to 1.89 Aperta
Difficoltà 2/5 1-3 ore Idoneità per principianti 68/100
RustCrypto/RSA#707 · 2 commenti · 1 reazione ·
-
Difficoltà 3/5 Mezza giornata Idoneità per principianti 74/100
RustCrypto/RSA#703 ·
-
Difficoltà 4/5 3-5 giorni Idoneità per principianti 48/100
RustCrypto/RSA#686 · 4 commenti ·
-
`rsa` v0.10 release tracking Aperta
Difficoltà 5/5 Più di una settimana Idoneità per principianti 35/100
RustCrypto/RSA#647 · 9 commenti · 1 reazione ·
-
broken rust docs Aperta
Difficoltà 4/5 3-5 giorni Idoneità per principianti 35/100
RustCrypto/RSA#641 · 3 reazioni ·
Tutte le issue di RustCrypto/RSA
Issue simili
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 75/100
TheLarkInn/aipm#2413 ·
-
documentation
Difficoltà 1/5 Meno di un'ora Idoneità per principianti 90/100
alexgorbatchev/simple-ptt#15 ·
-
tooling
Difficoltà 2/5 1-3 ore Idoneità per principianti 75/100
-
todo:ticket
Difficoltà 2/5 1-3 ore Idoneità per principianti 70/100
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 75/100
taikoxyz/taiko-mono#22168 · 1 commento ·