Vulnerability Details : CVE-2021-36157
An issue was discovered in Grafana Cortex through 1.9.0. The header value X-Scope-OrgID is used to construct file paths for rules files, and if crafted to conduct directory traversal such as ae ../../sensitive/path/in/deployment pathname, then Cortex will attempt to parse a rules file at that location and include some of the contents in the error message. (Other Cortex API requests can also be sent a malicious OrgID header, e.g., tricking the ingester into writing metrics to a different location, but the effect is nuisance rather than information disclosure.)
Vulnerability category: Directory traversalInformation leak
Products affected by CVE-2021-36157
- cpe:2.3:a:linuxfoundation:cortex:*:*:*:*:*:*:*:*
Exploit prediction scoring system (EPSS) score for CVE-2021-36157
0.11%
Probability of exploitation activity in the next 30 days
EPSS Score History
~ 45 %
Percentile, the proportion of vulnerabilities that are scored at or less
CVSS scores for CVE-2021-36157
Base Score | Base Severity | CVSS Vector | Exploitability Score | Impact Score | Score Source | First Seen |
---|---|---|---|---|---|---|
5.0
|
MEDIUM | AV:N/AC:L/Au:N/C:P/I:N/A:N |
10.0
|
2.9
|
NIST | |
5.3
|
MEDIUM | CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:L/I:N/A:N |
3.9
|
1.4
|
NIST |
CWE ids for CVE-2021-36157
-
The product uses external input to construct a pathname that is intended to identify a file or directory that is located underneath a restricted parent directory, but the product does not properly neutralize special elements within the pathname that can cause the pathname to resolve to a location that is outside of the restricted directory.Assigned by: nvd@nist.gov (Primary)
References for CVE-2021-36157
-
https://grafana.com/docs/grafana/latest/release-notes/
Release notes | Grafana LabsRelease Notes;Vendor Advisory
-
https://github.com/cortexproject/cortex/pull/4375
Restrict path segments in TenantIDs (CVE-2021-36157) by simonswine · Pull Request #4375 · cortexproject/cortex · GitHubPatch;Third Party Advisory
Jump to