GitHub Advisoryadvisory · npm

GHSA-pgx9-497m-6c4v sm-crypto Affected by Private Key Recovery in SM2-PKE

CRITICAL Published 2026-01-21 Modified 2026-01-22 Official page ↗
Aliases
CVE-2026-23966
Ecosystem
npm
Packages
sm-crypto
Severity
Critical
CVSS vector
CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:N
Weaknesses
CWE-345
Reviewed
2026-01-21

Affected packages

• npm sm-crypto: < 0.3.14 → fixed in 0.3.14

Description

Summary A private key recovery vulnerability exists in the SM2 decryption logic of sm-crypto. By interacting with the SM2 decryption interface multiple times, an attacker can fully recover the private key within approximately several hundred interactions. Credit This vulnerability was discovered by: • XlabAI Team of Tencent Xuanwu Lab • Atuin Automated Vulnerability Discovery Engine

Related

Alias · CVE (1)

  • CVE-2026-23966 sm-crypto provides JavaScript implementations of the Chinese cryptographic algorithms SM2, SM3, and SM4. vulnerability

Weakness · CWE (1)

  • CWE-345 Insufficient Verification of Data Authenticity weakness

References