CVE-2022-1929: Regular expression denial of service in devcert
7.5
CVSS Score
3.1
Basic Information
CVE ID
GHSA ID
EPSS Score
0.42639%
CWE
Published
6/3/2022
Updated
11/29/2023
KEV Status
No
Technology
JavaScript
Technical Details
CVSS Vector
CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H
| Package Name | Ecosystem | Vulnerable Versions | First Patched Version |
|---|---|---|---|
| devcert | npm | < 1.2.1 | 1.2.1 |
Vulnerability Intelligence
Miggo AI
Root Cause Analysis
The vulnerability stemmed from the VALID_DOMAIN regex pattern used in domain validation. The commit diff shows: 1) Removal of VALID_DOMAIN from constants.ts 2) Replacement of VALID_DOMAIN.test() with isValidDomain in certificateFor function. The CWE-1333 classification confirms this was an inefficient regex issue. The certificateFor function was the entry point for attacker-controlled input validation using this vulnerable regex, making it the clear vulnerable function. The high confidence comes from direct evidence of regex replacement in the patch and CVE's explicit mention of certificateFor as the attack vector.