5.3medium
Denial of Service in uap-core
- Severity
- 5.3medium CVSS:3.1 by GitHub_M
- Exploit likelihood
- 2.55% (higher than 85% of CVEs; EPSS, by FIRST)
- Published
- Last changed
- Assigned by
- GitHub_M
- Also known as
- GHSA-p4pj-mg4r-x6v4
Description
uap-core in an open-source npm package which contains the core of BrowserScope's original user agent string parser. In uap-core before version 0.11.0, some regexes are vulnerable to regular expression denial of service (REDoS) due to overlapping capture groups. This allows remote attackers to overload a server by setting the User-Agent header in an HTTP(S) request to maliciously crafted long strings. This is fixed in version 0.11.0. Downstream packages such as uap-python, uap-ruby etc which depend upon uap-core follow different version schemes.
Affected
| Product or package | Versions | Reported by |
|---|---|---|
| ua-parser uap-core | < 0.11.0 | CVE List |
| uap-core (npm) | before 0.11.0 | GitHub Advisory Database |
| uap-core_project uap-core | before 0.11.0 | NVD |
All scores
| GitHub_M | 5.3medium CVSS:3.1 | CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:L |
| GitHub | 7.5high CVSS:3.1 | CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H |
| NVD | 5.3medium CVSS:3.1 | CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:L |
| NVD | 5.0medium CVSS:2.0 | AV:N/AC:L/Au:N/C:N/I:N/A:P |
Classification
What each source says
CVE List
uap-core in an open-source npm package which contains the core of BrowserScope's original user agent string parser. In uap-core before version 0.11.0, some regexes are vulnerable to regular expression denial of service (REDoS) due to overlapping capture groups. This allows remote attackers to overload a server by setting the User-Agent header in an HTTP(S) request to maliciously crafted long strings. This is fixed in version 0.11.0. Downstream packages such as uap-python, uap-ruby etc which depend upon uap-core follow different version schemes.
GitHub Advisory Database
Impact
Some regexes are vulnerable to regular expression denial of service (REDoS) due to overlapping capture groups. This allows remote attackers to overload a server by setting the User-Agent header in an HTTP(S) request to maliciously crafted long strings.
Patches
Please update uap-core to >= v0.11.0
Downstream packages such as uap-python, uap-ruby etc which depend upon uap-core follow different version schemes.
NVD (es)
uap-core en un paquete npm de código abierto que contiene el core del analizador de cadenas del agente de usuario original de BrowserScope. En uap-core versiones anteriores a 0.11.0, algunas expresiones regulares son vulnerables a una denegación de servicio de expresión regular (REDoS) debido a la superposición de grupos de captura. Esto permite a atacantes remotos sobrecargar un servidor configurando el encabezado User-Agent en una petición HTTP(S) en cadenas largas diseñadas maliciosamente. Esto es corregido en versión 0.11.0. Los paquetes posteriores como uap-python, uap-ruby, etc., que dependen de uap-core, siguen esquemas de versiones diferentes
References
| https://github.com/ua-parser/uap-core/security/advisories/GHSA-p4pj-mg4r-x6v4 | third-party-advisory, web | |
| https://github.com/ua-parser/uap-core/commit/dc9925d458214cfe87b93e35346980612f6ae96c | patch, web | |
| https://www.npmjs.com/package/uap-core | product, third-party-advisory, web | |
| https://nvd.nist.gov/vuln/detail/CVE-2021-21317 | advisory | |
| https://github.com/ua-parser/uap-core | package | |
Sources
| Source | Record | Licence |
|---|---|---|
| CVE List | CVE-2021-21317 changed 2024-08-03 | CVE Terms of Use |
| GitHub Advisory Database | GHSA-p4pj-mg4r-x6v4 changed 2026-07-08 | CC-BY-4.0 |
| NVD | CVE-2021-21317 changed 2026-06-17 | Public domain |