logo

CVE-2022-32149 golang.org/x/text

Package

Manager: go
Name: golang.org/x/text
Vulnerable Version: >=0 <0.3.8

Severity

Level: High

CVSS v3.1: CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H

CVSS v4.0: CVSS:4.0/AV:N/AC:L/AT:N/PR:L/UI:N/VC:N/VI:N/VA:H/SC:N/SI:N/SA:N

EPSS: 0.00046 pctl0.13556

Details

golang.org/x/text/language Denial of service via crafted Accept-Language header The BCP 47 tag parser has quadratic time complexity due to inherent aspects of its design. Since the parser is, by design, exposed to untrusted user input, this can be leveraged to force a program to consume significant time parsing Accept-Language headers. The parser cannot be easily rewritten to fix this behavior for various reasons. Instead the solution implemented in this CL is to limit the total complexity of tags passed into ParseAcceptLanguage by limiting the number of dashes in the string to 1000. This should be more than enough for the majority of real world use cases, where the number of tags being sent is likely to be in the single digits. ### Specific Go Packages Affected golang.org/x/text/language

Metadata

Created: 2022-10-14T19:00:40Z
Modified: 2025-05-16T02:08:37Z
Source: https://github.com/github/advisory-database/blob/main/advisories/github-reviewed/2022/10/GHSA-69ch-w2m2-3vjp/GHSA-69ch-w2m2-3vjp.json
CWE IDs: ["CWE-772"]
Alternative ID: GHSA-69ch-w2m2-3vjp
Finding: F067
Auto approve: 1