`RsaPrivateKey::validate()` does not ensure `precompute()` won't fail
Chưa có ai nhận issue này.
Đánh giá
- Độ khó
- 3/5
- Thời gian dự kiến
- 1-2 ngày
- Mức phù hợp với người mới
- 45/100
- Loại issue
- Lỗi
- Độ rõ ràng
- Khá rõ ràng
- Mức độ hoạt động
- Đình trệ
- Công nghệ
- rust
- Lĩnh vực
- cryptography
Hướng nghiên cứu
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.
Do mô hình lập chỉ mục viết ra từ nội dung của issue.
Mô tả
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.
- Ngôn ngữ chính
- Rust
- Star
- 673
- Fork
- 190
- Chỉ số merge pull request
- Không có pull request nào được merge trong 30 ngày
Hướng dẫn đóng góp
Chưa lập chỉ mục được hướng dẫn đóng góp cho kho mã nguồn này
Bắt đầu từ đâu
- Đọc hết issue, rồi đọc hướng dẫn đóng góp của dự án.
- Bình luận trên issue rằng bạn sẽ nhận — tránh hai người làm cùng một việc.
- Fork repository và làm thay đổi trên một nhánh.
- Mở pull request có tham chiếu số hiệu của issue.
Issue khác của RustCrypto/RSA
-
Bump MSRV to 1.89 Đang mở
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 68/100
RustCrypto/RSA#707 · 2 bình luận · 1 reaction ·
-
Độ khó 3/5 Nửa ngày Mức phù hợp với người mới 74/100
RustCrypto/RSA#703 ·
-
Độ khó 4/5 3-5 ngày Mức phù hợp với người mới 48/100
RustCrypto/RSA#686 · 4 bình luận ·
-
`rsa` v0.10 release tracking Đang mở
Độ khó 5/5 Hơn một tuần Mức phù hợp với người mới 35/100
RustCrypto/RSA#647 · 9 bình luận · 1 reaction ·
-
broken rust docs Đang mở
Độ khó 4/5 3-5 ngày Mức phù hợp với người mới 35/100
RustCrypto/RSA#641 · 3 reaction ·
Tất cả issue của RustCrypto/RSA
Issue tương tự
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 88/100
-
bug core
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 86/100
-
JIT-compiled number -> Decimal conversion silently overflows instead of raising DECIMAL_OVERFLOW Đang mởfuzz
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 82/100
ClickHouse/ClickHouse#122114 ·
-
Độ khó 1/5 Dưới một giờ Mức phù hợp với người mới 92/100
linebender/vello_svg#90 ·
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 74/100