
Cloud Vulnerability DB
A community-led vulnerabilities database
A vulnerability in node-jose, a JavaScript implementation of JSON Object Signing and Encryption (JOSE) for web browsers and node.js-based servers, was discovered and assigned CVE-2023-25653. The vulnerability affects versions prior to v2.1.1 and was disclosed on February 16, 2023. The issue occurs when using the non-default 'fallback' crypto back-end, where ECC operations can trigger a Denial-of-Service (DoS) condition due to a possible infinite loop in an internal calculation (GitHub Advisory).
The vulnerability stems from the JOSE logic implementation when neither WebCrypto nor Node crypto module is available, forcing node-jose to use its 'fallback' implementations based on node-forge. The issue occurs during the computation of X coordinates of elliptic curve points, specifically in the getX() method (pointFpGetX() in lib/deps/ecc/math.js). The root cause is that the jsbn modInverse function sometimes returns negative results, which are mathematically correct but problematic for functions expecting positive results. The Barrett reduction algorithm implementation in node-jose explicitly doesn't handle negative inputs, leading to an infinite loop. The probability of triggering this condition is estimated at roughly one in every 2^20 inputs (GitHub Advisory).
The vulnerability affects several elliptic curve algorithms including elliptic curve key generation, converting elliptic curve private keys to public keys, ECDSA signing, ECDSA verification, and ECDH key agreement. In key generation, private key conversion, and signing operations, the vulnerability can only be triggered randomly. However, in verification and key agreement operations, the vulnerability can be deliberately triggered by malicious input, potentially leading to a denial of service condition (GitHub Advisory).
The vulnerability has been patched in version v2.2.0. As a workaround, users can ensure that either WebCrypto or the Node crypto module is available in the JavaScript environment where node-jose is being run, as this issue only affects the 'fallback' crypto implementation (GitHub Advisory).
Source: This report was generated using AI
Free Vulnerability Assessment
Evaluate your cloud security practices across 9 security domains to benchmark your risk level and identify gaps in your defenses.
Get a personalized demo
"Best User Experience I have ever seen, provides full visibility to cloud workloads."
"Wiz provides a single pane of glass to see what is going on in our cloud environments."
"We know that if Wiz identifies something as critical, it actually is."