Quick answers
- Is CVE-2023-25653 exploited in the wild?
- No. Junglewise Threat Intelligence has no report of CVE-2023-25653 being exploited in the wild.
- How severe is CVE-2023-25653?
- Low severity, with a CVSS score of 3.1, published 16 February 2023.
- Which products and versions are affected?
- node-jose (npm) SEMVER:introduced=0,fixed=2.2.0.
- Is there a fix for CVE-2023-25653?
- Yes. node-jose (npm): upgrade to 2.2.0 or later. Junglewise finds every place you run it, drafts the upgrade and applies it once you approve.
- How is CVE-2023-25653 attacked?
- It is attacked over the network, in a software library.
- Am I affected by CVE-2023-25653?
- Check whether you run node-jose (npm) at an affected version. Junglewise does that check for you around the clock: connect your code, cloud and domains, and it matches new vulnerabilities like this one against what you actually run and tells you when one reaches you.
How to fix
- node-jose (npm): upgrade to 2.2.0 or later
npm install node-jose@2.2.0
Technical details
The vulnerability exists in the fallback elliptic curve cryptography implementation (lib/deps/ecc/math.js) used when WebCrypto and Node.js crypto modules are unavailable. The root cause is improper handling of negative results from the jsbn library's modInverse function. When modInverse returns a negative value (mathematically correct but requiring special handling), the barrettReduce function fails to handle it correctly, causing an infinite loop. This affects EC key generation, ECDSA signing/verification, and ECDH key agreement. For random EC operations, triggering the bug requires a random bad value (probability ~2^-20); for ECDSA verification and ECDH, attackers can provide malicious points to trigger it. The vulnerability requires the fallback crypto backend to be active; environments with WebCrypto or Node.js crypto are unaffected. A fix is available in version 2.2.0.
Affected products
- Cisco node-jose < 2.2.0
Identifiers
- CVE-2023-25653
- GHSA-5h4j-qrvg-9xhw
Timeline
- 2023-02-16: disclosed