CVE-2022-29526: Golang.org/x/sys Golang.org/x/sys/unix Has Incorrect Privilege Reporting Vulnerability
MODERATECVE-2022-29526 is a MODERATE (CVSS 5.3) golang.org/x/sys/unix has incorrect privilege reporting vulnerability (CWE-269: Improper Privilege Management) affecting Golang.org/x/sys libraries in the Go ecosystem. The issue involves golang.org/x/sys/unix has incorrect privilege reporting in syscall. Remediation is available by upgrading affected packages to version 0.0.0-20220412211240-33da011f77ad.
CVE-2022-29526 at a Glance
Security Impact
CVSS: 5.3
The security impact metrics below are parsed directly from the CVSS v3.1 vector string (CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:L/I:N/A:N).
How to Fix CVE-2022-29526
To remediate this vulnerability, upgrade all affected Golang.org/x/sys dependencies to a patched release. Both direct and transitive dependencies should be checked, as frameworks or security libraries may pull in vulnerable versions transitively.
Upgrade golang.org/x/sys to 0.0.0-20220412211240-33da011f77ad
Run the following command in your project directory to verify that all resolved dependencies use the patched release:
inspect dependencies for golang.org/x/sys
How to Check if You Are Affected
To determine whether your application is affected by CVE-2022-29526, inspect your project dependencies for Golang.org/x/sys:
inspect dependencies for golang.org/x/sys
Analyze the terminal output to locate any version of Golang.org/x/sys in your dependency tree. If any resolved version matches the vulnerable ranges listed in the table below (for example, versions earlier than 0.0.0-20220412211240-33da011f77ad), your application is affected.
Note: Verify declared build manifests and deployed runtime container environments.
Technical Details
Vulnerability Mechanism & Technical Analysis
This vulnerability is classified under CWE-269: Improper Privilege Management, where the product does not properly assign, modify, track, or check privileges for an actor, creating an unintended sphere of control for that actor. In Golang.org/x/sys, software state validation or input boundaries are circumvented during processing. Review the official source advisory statement below for specific affected components, classes, and reproduction details.
Source Advisory Statement
CVE-2022-29526 Affected Golang.org/x/sys Versions
1 component(s)| Product / Package | Ecosystem | Affected Versions | Fixed Version |
|---|---|---|---|
|
golang.org/x/sys
|
Go |
< 0.0.0-20220412211240-33da011f77ad
|
0.0.0-20220412211240-33da011f77ad
|
References
Frequently Asked Questions
What is CVE-2022-29526?
Which Golang.org/x/sys versions are affected?
What version fixes CVE-2022-29526?
Is golang.org/x/sys affected?
What is the CVSS score of CVE-2022-29526?
What CWE is associated with CVE-2022-29526?
How can I check Go dependencies for CVE-2022-29526?
Machine-readable OSV JSON
OSV v1.5 Schema
{
"schema_version" : "1.4.0",
"id" : "GHSA-p782-xgp4-8hr8",
"modified" : "2024-05-20T21:27:32Z",
"published" : "2022-06-24T00:00:30Z",
"aliases" : [ "CVE-2022-29526" ],
"summary" : "golang.org/x/sys/unix has Incorrect privilege reporting in syscall",
"details" : "Go before 1.17.10 and 1.18.x before 1.18.2 has Incorrect Privilege Reporting in syscall. When called with a non-zero flags parameter, the Faccessat function could incorrectly report that a file is accessible.\n\n### Specific Go Packages Affected\ngolang.org/x/sys/unix",
"severity" : [ {
"type" : "CVSS_V3",
"score" : "CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:L/I:N/A:N"
} ],
"affected" : [ {
"package" : {
"ecosystem" : "Go",
"name" : "golang.org/x/sys"
},
"ranges" : [ {
"type" : "ECOSYSTEM",
"events" : [ {
"introduced" : "0"
}, {
"fixed" : "0.0.0-20220412211240-33da011f77ad"
} ]
} ]
} ],
"references" : [ {
"type" : "ADVISORY",
"url" : "https://nvd.nist.gov/vuln/detail/CVE-2022-29526"
}, {
"type" : "WEB",
"url" : "https://github.com/golang/go/issues/52313"
}, {
"type" : "PACKAGE",
"url" : "https://github.com/golang/go"
}, {
"type" : "WEB",
"url" : "https://go.dev/cl/399539"
}, {
"type" : "WEB",
"url" : "https://go.dev/cl/400074"
}, {
"type" : "WEB",
"url" : "https://go.dev/issue/52313"
}, {
"type" : "WEB",
"url" : "https://groups.google.com/g/golang-announce"
}, {
"type" : "WEB",
"url" : "https://groups.google.com/g/golang-announce/c/Y5qrqw_lWdU"
}, {
"type" : "WEB",
"url" : "https://lists.fedoraproject.org/archives/list/package-announce@lists.fedoraproject.org/message/Q6GE5EQGE4L2KRVGW4T75QVIYAXCLO5X"
}, {
"type" : "WEB",
"url" : "https://lists.fedoraproject.org/archives/list/package-announce@lists.fedoraproject.org/message/RQXU752ALW53OJAF5MG3WMR5CCZVLWW6"
}, {
"type" : "WEB",
"url" : "https://lists.fedoraproject.org/archives/list/package-announce@lists.fedoraproject.org/message/Z55VUVGO7E5PJFXIOVAY373NZRHBNCI5"
}, {
"type" : "WEB",
"url" : "https://lists.fedoraproject.org/archives/list/package-announce@lists.fedoraproject.org/message/ZY2SLWOQR4ZURQ7UBRZ7JIX6H6F5JHJR"
}, {
"type" : "WEB",
"url" : "https://pkg.go.dev/vuln/GO-2022-0493"
}, {
"type" : "WEB",
"url" : "https://security.gentoo.org/glsa/202208-02"
}, {
"type" : "WEB",
"url" : "https://security.netapp.com/advisory/ntap-20220729-0001"
} ],
"database_specific" : {
"cwe_ids" : [ "CWE-269" ],
"severity" : "MODERATE",
"github_reviewed" : true,
"github_reviewed_at" : "2023-02-08T00:30:54Z",
"nvd_published_at" : "2022-06-23T17:15:00Z"
}
}