CVE-2026-22700
📋 TL;DR
A denial-of-service vulnerability exists in RustCrypto's SM2 public-key encryption implementation where untrusted ciphertext can trigger bounds-check panics. This causes thread or process crashes in applications using affected versions of the elliptic-curves crate. Any Rust application using SM2 PKE from RustCrypto versions 0.14.0-pre.0 or 0.14.0-rc.0 is affected.
💻 Affected Systems
- RustCrypto elliptic-curves crate
📦 What is this software?
⚠️ Risk & Real-World Impact
Worst Case
Complete service disruption through repeated process crashes, potentially leading to extended downtime for affected applications.
Likely Case
Intermittent service interruptions as individual threads or processes crash when processing malicious ciphertext.
If Mitigated
Minimal impact with proper input validation and monitoring in place to detect and block malicious requests.
🎯 Exploit Status
Exploitation requires sending specially crafted ciphertext to the vulnerable decrypt() function.
🛠️ Fix & Mitigation
✅ Official Fix
Patch Version: Versions after commit e60e991 (0.14.0-rc.1 and later)
Vendor Advisory: https://github.com/RustCrypto/elliptic-curves/security/advisories/GHSA-j9xq-69pf-pcm8
Restart Required: Yes
Instructions:
1. Update Cargo.toml to use elliptic-curves >=0.14.0-rc.1
2. Run 'cargo update'
3. Rebuild and redeploy your application
4. Restart affected services
🔧 Temporary Workarounds
Input validation wrapper
allAdd custom input validation before calling decrypt() to ensure ciphertext meets minimum length requirements
// Rust code: Validate ciphertext length before decrypt() call
🧯 If You Can't Patch
- Implement network-level filtering to block or rate-limit requests containing SM2 ciphertext
- Deploy monitoring to detect and alert on process crashes related to SM2 decryption operations
🔍 How to Verify
Check if Vulnerable:
Check Cargo.lock for elliptic-curves version 0.14.0-pre.0 or 0.14.0-rc.0
Check Version:
grep -A2 'elliptic-curves' Cargo.lock
Verify Fix Applied:
Verify elliptic-curves version is >=0.14.0-rc.1 in Cargo.lock after update
📡 Detection & Monitoring
Log Indicators:
- Process crash logs mentioning 'panic' or 'unwind' in SM2 decryption context
- Increased error rates in SM2-related operations
Network Indicators:
- Unusual patterns of SM2 ciphertext submissions
- Repeated connection attempts to SM2 endpoints
SIEM Query:
process.name:your_app AND (log_message:*panic* OR log_message:*unwind*) AND log_message:*SM2*
🔗 References
- https://github.com/RustCrypto/elliptic-curves/commit/e60e99167a9a2b187ebe80c994c5204b0fdaf4ab
- https://github.com/RustCrypto/elliptic-curves/pull/1603
- https://github.com/RustCrypto/elliptic-curves/security/advisories/GHSA-j9xq-69pf-pcm8
- https://github.com/RustCrypto/elliptic-curves/security/advisories/GHSA-j9xq-69pf-pcm8