Skip to content
Fencer Vulns
medium 5.3

CVE-2021-36157 json

Path traversal in Grafana Cortex

published 2021-08-03 5 y ago modified 2026-06-17 4 mo ago also GHSA-jphm-g89m-v42p , EUVD-2021-2088

cvss
5.3
version 3.1, NVD
cisa kev
Not listed
not in CISA's catalog
epss
1.4%
EPSS 1.4% chance of exploitation in 30 days, percentile 72%
public exploits
0
none known

Summary

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.)

Patch / fix

Vendor advisories

What the vendors themselves say about their products: affected, fixed or not affected, and what to do.

red hat product security vex CVE-2021-36157 updated cvss 5.3

cortex: Grafana Cortex directory traversal

  • Red Hat OpenShift Container Platform 4 openshift4/ose-grafana
    affected: no fix planned “Will not fix”
  • Red Hat Openshift Container Storage 4 ocs4/mcg-rhel8-operator, ocs4/ocs-rhel8-operator
    affected: no fix planned “Out of support scope”
  • Red Hat OpenShift Container Platform 4.13 openshift4/ose-cluster-storage-operator v4.13.0-202305181415.p0.g6479617.assembly.stream
    fixed: vendor fix RHSA-2023:3304
  • Red Hat OpenShift Container Platform 4.14 openshift4/ose-cluster-storage-operator v4.14.0-202310201027.p0.gdbb1514.assembly.stream
    fixed: vendor fix RHSA-2023:5006
  • Red Hat Logging Subsystem for Red Hat OpenShift openshift-logging/logging-loki-rhel8 Red Hat Advanced Cluster Management for Kubernetes 2 rhacm2/acm-grafana-rhel8, rhacm2/rbac-query-proxy-rhel8, rhacm2/metrics-collector-rhel8, rhacm2/grafana-dashboard-loader-rhel8, endpoint-monitoring-operator-container, rhacm2/multicluster-observability-rhel8-operator Red Hat Enterprise Linux 8 grafana, grafana-loki, grafana-mssql, grafana-mysql, grafana-selinux, grafana-graphite, +8 more Red Hat Enterprise Linux 9 grafana, grafana-selinux Red Hat OpenShift Container Platform 4 openshift4/ose-thanos-rhel9, openshift4/ose-prometheus-operator, openshift4/ose-cluster-monitoring-operator Red Hat OpenShift Container Platform 4.13 openshift4/ose-tests v4.13.0-202305220716.p0.g893ae57.assembly.stream, openshift4/ose-console v4.13.0-202305231941.p0.g6f58e08.assembly.stream, openshift4/ose-installer v4.13.0-202305202341.p0.g2f227cc.assembly.stream, openshift4/ose-sdn-rhel8 v4.13.0-202305180130.p0.gd56dc6a.assembly.stream, openshift4/ose-kube-proxy v4.13.0-202305180130.p0.gd56dc6a.assembly.stream, openshift4/ose-multus-cni v4.13.0-202305232329.p0.g5d283fa.assembly.stream, +46 more
    +2 more products
    Red Hat OpenShift Container Platform 4.14 rhcos 414.92.202310210434-0, openshift4/ose-cli v4.14.0-202310201027.p0.g0c63f9d.assembly.stream, openshift4/ose-pod v4.14.0-202310210404.p0.gf67aeb3.assembly.stream, openshift4/ose-tests v4.14.0-202310201027.p0.g948001a.assembly.stream, openshift4/ose-console v4.14.0-202310201027.p0.gc16ab01.assembly.stream, openshift4/ose-coredns v4.14.0-202310201027.p0.gfd70cf1.assembly.stream, +180 more Red Hat Openshift Data Foundation 4 odf4/mcg-rhel9-operator, odf4/ocs-rhel9-operator, odf4/odf-rhel8-operator
    not affected: vulnerable code not present

Red Hat CSAF VEX © Red Hat, Inc., from https://security.access.redhat.com/data/csaf/v2/vex/; changed: reduced to product statuses and remediations. CC BY 4.0 · csaf

Exploit prediction

1.39% chance of exploitation in the next 30 days, higher than 72% of all scored CVEs (FIRST EPSS, 2026-11-08).

CVSS scores

assigned by version score vector
NVD 3.1 5.3 CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:L/I:N/A:N
NVD 2.0 5.0 AV:N/AC:L/Au:N/C:P/I:N/A:N

Affected packages

ecosystem package affected fixed in
go github.com/cortexproject/cortex
<=1.9.0
no fix listed

Classification

Weakness
  • CWE-22 Improper Limitation of a Pathname to a Restricted Directory

References

Sources

Fencer Vulns keeps one entry per vulnerability: the CVE id wins, then GHSA, and records that alias each other are merged, except that two CVEs always keep separate entries. The same data is available as JSON.