Advisory

GHSA-grj5-8x6q-hc9q

Also known as: CVE-2021-36156

Summary

Path traversal in Grafana Loki

Details

An issue was discovered in Grafana Loki through 2.2.1. 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 Loki will attempt to parse a rules file at that location and include some of the contents in the error message.

Severity

Medium Basis: The source's own band: MODERATE

Dates

Published
2021-09-02 22:00 UTC
Modified
2026-08-07 08:12 UTC

Affected packages and fixes

github.com/grafana/loki

Go · All systems

Affected

  • introduced 0, fixed 2.3.0 (semver)

Fixed versions

2.3.0

Fix

Fix commands are the export's own generic commands. Ojuju never runs them. Check them against your setup first.

Check your own computer: guard packages check

View this record on OSV.dev

Source

Source: GitHub Advisory Database (reviewed advisories) · CC BY 4.0

Sources & licences