CVE-2026-22700

7.5 HIGH

📋 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

Products:
  • RustCrypto elliptic-curves crate
Versions: 0.14.0-pre.0 and 0.14.0-rc.0 only
Operating Systems: All platforms running Rust applications
Default Config Vulnerable: ⚠️ Yes
Notes: Only affects SM2 public-key encryption functionality; other elliptic curve operations are not impacted.

📦 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.

🌐 Internet-Facing: HIGH
🏢 Internal Only: MEDIUM

🎯 Exploit Status

Public PoC: ✅ No
Weaponized: UNKNOWN
Unauthenticated Exploit: ⚠️ Yes
Complexity: LOW

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

all

Add 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

📤 Share & Export