{"schemaVersion":1,"url":"https://cve.openhack.com/cve/CVE-2021-36157","id":"CVE-2021-36157","title":"Path traversal in Grafana Cortex","description":"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 sen","descriptionLong":"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.)","published":"2021-08-03T14:03:49.000Z","updated":"2026-10-20T10:55:20.108913455Z","reserved":"2021-07-05T00:00:00.000Z","status":"Modified","rejected":false,"assigner":"mitre","metric":{"version":"3.1","score":5.3,"vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:L/I:N/A:N","rating":"medium","source":"NVD"},"metrics":[{"version":"3.1","score":5.3,"vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:L/I:N/A:N","rating":"medium","source":"NVD"},{"version":"3.1","score":5.3,"vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:L/I:N/A:N","rating":"medium","source":"OSV"},{"version":"2.0","score":5,"vector":"AV:N/AC:L/Au:N/C:P/I:N/A:N","rating":"medium","source":"NVD"}],"rating":"medium","products":[],"affectedProducts":[{"vendor":"n/a","product":"n/a","defaultStatus":null,"versions":[{"status":"affected","version":"n/a"}],"platforms":[]}],"packages":[{"ecosystem":"Go","name":"github.com/cortexproject/cortex","purl":"pkg:golang/github.com/cortexproject/cortex","ranges":["<=1.9.0"],"fixed":[],"advisory":"GHSA-jphm-g89m-v42p"}],"cwes":["CWE-22"],"aliases":["GHSA-jphm-g89m-v42p"],"references":[{"url":"https://grafana.com/docs/grafana/latest/release-notes/","tags":["x_refsource_MISC","x_transferred","Release Notes","Vendor Advisory","advisory"]},{"url":"https://github.com/cortexproject/cortex/pull/4375","tags":["x_refsource_MISC","x_transferred","Patch","Third Party Advisory","fix","web"]},{"url":"https://nvd.nist.gov/vuln/detail/CVE-2021-36157","tags":["advisory"]},{"url":"https://github.com/cortexproject/cortex/commit/d9e1f81f40c607b9e97c2fc6db70ae54679917c4","tags":["web"]},{"url":"https://github.com/cortexproject/cortex","tags":["package"]},{"url":"https://grafana.com/docs/grafana/latest/release-notes","tags":["web"]}],"patchReferenced":true,"fixAvailable":true,"exploitReferenced":false,"kev":false,"kevAdded":null,"kevDue":null,"kevEntry":null,"ssvc":null,"epss":0.01392,"epssPercentile":0.7295,"sources":[{"name":"CVE List","url":"https://www.cve.org/CVERecord?id=CVE-2021-36157","ok":true},{"name":"NVD","url":"https://nvd.nist.gov/vuln/detail/CVE-2021-36157","ok":true,"note":"Modified"},{"name":"OSV","url":"https://osv.dev/vulnerability/CVE-2021-36157","ok":true,"note":"1 package"},{"name":"GitHub Advisory","url":"https://github.com/advisories/GHSA-jphm-g89m-v42p","ok":true,"note":"GHSA-jphm-g89m-v42p"},{"name":"CISA KEV","url":"https://www.cisa.gov/known-exploited-vulnerabilities-catalog","ok":true,"note":"not listed"},{"name":"EPSS","url":"https://api.first.org/data/v1/epss?cve=CVE-2021-36157","ok":true,"note":"scored 2026-11-19"}],"aiTitle":false,"tech":[],"critical":[],"attention":null}