RUSTSEC-2026-0385: Non-constant-time mask generation and `u128` comparisons
Chưa có ai nhận issue này.
Đánh giá
- Độ khó
- 1/5
- Thời gian dự kiến
- Dưới một giờ
- Mức phù hợp với người mới
- 10/100
Hướng nghiên cứu
The body describes a vulnerability in the ctutils crate and points to its advisory and upstream pull request, but names no files or tests in this repository. Start by checking whether the gateway uses the affected ctutils version and inspect its dependency lockfile. Done means confirming whether the dependency is present and, if so, identifying the remediation path; the issue gives no repository specific change or test.
Do mô hình lập chỉ mục viết ra từ nội dung của issue.
Mô tả
Non-constant-time mask generation and
u128comparisons
| Details | |
|---|---|
| Package | ctutils |
| Version | 0.4.2 |
| URL | https://github.com/RustCrypto/utils/pull/1569 |
| Date | 2026-10-23 |
| Patched versions | >=0.4.4 |
Summary
The ctutils::Choice type has mask generation functions for each unsigned
integer size (u8, u16, u32, u64, u128). These are const fn and
therefore can't reuse the asm!-backed mask generation in the cmov crate
that's otherwise used to ensure constant-time.
In releases prior to v0.4.4, the generated code from these functions could
include a branch on commonly used platforms. This has been corrected in this
release and now verified on several platforms using BINSEC.
Additionally, u128 comparison operations provided via ctutils::Choice and
intended to work in constant-time were generating branches on 32-bit targets.
This has been resolved via a special case implementation of these functions
for such targets.
Impact
Branch instructions on secret values can potentially leak such values via
covert channels. This can enable attackers to potentially recover such secrets.
Resolution
This has been resolved by calling Choice::to_u8() when generating the mask,
which in turn uses black_box as an optimization barrier. Verification that
this resulted in the desired change in the generated assembly across a variety
of target CPU architectures was performed by BINSEC, which now runs
automatically in CI using cargo checkct.
See advisory page for additional details.
- Ngôn ngữ chính
- Rust
- Star
- 0
- Fork
- 2
- Chỉ số merge pull request
- Không có pull request nào được merge trong 30 ngày
Chuẩn bị môi trường
Dự án này không cung cấp dev container, Dockerfile hay hướng dẫn đóng góp, nên bạn cần tự thiết lập môi trường: hãy bắt đầu từ README và xem hướng dẫn đóng góp lần đầu của chúng tôi để biết các bước chung.
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 stackabletech/postgresql-trino-gateway
-
RUSTSEC-2026-0348: Brotli certificate decompression can allocate up to 1 GiB before authenticationĐang mở
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 60/100
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 68/100
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 68/100
-
Độ khó 4/5 3-5 ngày Mức phù hợp với người mới 42/100
-
Độ khó 1/5 Dưới một giờ Mức phù hợp với người mới 25/100
Tất cả issue của stackabletech/postgresql-trino-gateway
Issue tương tự
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 73/100
haowjy/mars-agents#228 ·
Maintainer thường phản hồi trong vòng 1 ngày
-
Độ khó 1/5 Dưới một giờ Mức phù hợp với người mới 68/100
redlib-org/redlib#604 ·
Maintainer thường phản hồi trong vòng 3 ngày
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 68/100
Maintainer thường phản hồi trong vòng 2 ngày
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 68/100
dividebysandwich/rust-dos#240 ·
Maintainer thường phản hồi trong vòng 1 ngày
-
A-UI C-Bug S-Needs-Triage
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 75/100
bevyengine/bevy#26330 ·
Maintainer thường phản hồi trong vòng 2 ngày