CVE-2021-23362
MEDIUM 5.3CVSS 3.1Regular Expression Denial of Service in hosted-git-info
The package hosted-git-info before 3.0.8 are vulnerable to Regular Expression Denial of Service (ReDoS) via regular expression shortcutMatch in the fromUrl function in index.js. The affected regular expression exhibits polynomial worst-case time complexity.
- Published
- 23 Mar 2021
- Last modified
- 17 Jun 2026
- Assigned by
- report@snyk.io
- NVD status
- Modified
- Weakness
- CWE-1333CWE-400
- Also known as
- GHSA-43f8-2h32-f4cj
- Sources
- NVDJSONOSV GHSA-43f8-2h32-f4cjJSON
Scores
| Source | Scored by | Version | Score | Vector / decision |
|---|---|---|---|---|
| NVD | report@snyk.io (Secondary) | CVSS 3.1 | MEDIUM 5.3 | CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:L |
| NVD | nvd@nist.gov (Primary) | CVSS 3.1 | MEDIUM 5.3 | CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:L |
| OSV | GitHub | CVSS 3.1 | MEDIUM 5.3 | CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:L |
| NVD | nvd@nist.gov (Primary) | CVSS 2.0 | MEDIUM 5.0 | AV:N/AC:L/Au:N/C:N/I:N/A:P |
Affected
| Source | Vendor / ecosystem | Product / package | Affected versions | Fixed in |
|---|---|---|---|---|
| NVD | npmjs | hosted-git-infocpe:2.3:a:npmjs:hosted-git-info:*:*:*:*:*:*:*:* |
>= 2.0.0, < 2.8.9 | 2.8.9 |
| NVD | npmjs | hosted-git-infocpe:2.3:a:npmjs:hosted-git-info:*:*:*:*:*:*:*:* |
>= 3.0.0, < 3.0.8 | 3.0.8 |
| NVD | siemens | sinec_infrastructure_network_servicescpe:2.3:a:siemens:sinec_infrastructure_network_services:*:*:*:*:*:*:*:* |
< 1.0.1.1 | 1.0.1.1 |
| OSV | npm | hosted-git-info | < 2.8.9 | 2.8.9 |
| OSV | npm | hosted-git-info | >= 3.0.0, < 3.0.8 | 3.0.8 |
References
- https://cert-portal.siemens.com/productcert/pdf/ssa-389290.pdf · Patch, Third Party Advisory, WEB
- https://github.com/npm/hosted-git-info/commit/29adfe5ef789784c861b2cdeb15051ec2ba651a7 · Patch, Third Party Advisory, WEB
- https://github.com/npm/hosted-git-info/commit/8d4b3697d79bcd89cdb36d1db165e3696c783a01 · Patch, Third Party Advisory, WEB
- https://github.com/npm/hosted-git-info/commit/bede0dc38e1785e732bf0a48ba6f81a4a908eba3 · Patch, Third Party Advisory, WEB
- https://github.com/npm/hosted-git-info/commits/v2 · Patch, Third Party Advisory, WEB
- https://snyk.io/vuln/SNYK-JAVA-ORGWEBJARSNPM-1088356 · Exploit, Patch, Third Party Advisory, WEB
- https://snyk.io/vuln/SNYK-JS-HOSTEDGITINFO-1088355 · Exploit, Patch, Third Party Advisory, WEB
- https://nvd.nist.gov/vuln/detail/CVE-2021-23362 · ADVISORY
- https://github.com/npm/hosted-git-info/pull/76 · WEB
- https://github.com/npm/hosted-git-info · PACKAGE
History
- 25 Nov 2026 20:32 UTC · NVD: first stored (published 23 Mar 2021)
- 25 Nov 2026 20:10 UTC · OSV: first stored (published 6 May 2021)