Vulnerabilities in pkg:golang/github.com/grafana/loki/v3
PACKAGECVE-2026-21726 is a MODERATE (CVSS 5.3) path traversal vulnerability (CWE-601: URL Redirection to Untrusted Site ('Open Redirect')) affecting Github.com/grafana/loki/v3 libraries in the Go ecosystem. The issue involves grafana loki path traversal - cve-2021-36156 bypass. Remediation is available by upgrading affected packages to version 3.6.4.
pkg:golang/github.com/grafana/loki/v3
Vulnerability advisories affecting package pkg:golang/github.com/grafana/loki/v3. Select an advisory below to view technical details or fixes.
| Advisory ID | CVE / NVD | Severity | Summary |
|---|---|---|---|
| GHSA-497x-rrr9-68jp | CVE-2026-21726 | MODERATE | Grafana Loki Path Traversal - CVE-2021-36156 Bypass |
CVE-2026-21726 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-2026-21726
To remediate this vulnerability, upgrade all affected Github.com/grafana/loki/v3 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 github.com/grafana/loki/v3 to 3.6.4
Run the following command in your project directory to verify that all resolved dependencies use the patched release:
inspect dependencies for github.com/grafana/loki/v3
How to Check if You Are Affected
To determine whether your application is affected by CVE-2026-21726, inspect your project dependencies for Github.com/grafana/loki/v3:
inspect dependencies for github.com/grafana/loki/v3
Analyze the terminal output to locate any version of Github.com/grafana/loki/v3 in your dependency tree. If any resolved version matches the vulnerable ranges listed in the table below (for example, versions earlier than 3.6.4), 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-601: URL Redirection to Untrusted Site ('Open Redirect'), where the web application accepts a user-controlled input that specifies a link to an external site, and uses that link in a redirect. In Github.com/grafana/loki/v3, 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-2026-21726 Affected Github.com/grafana/loki/v3 Versions
1 component(s)| Product / Package | Ecosystem | Affected Versions | Fixed Version |
|---|---|---|---|
|
github.com/grafana/loki/v3
|
Go |
< 3.6.4
|
3.6.4
|
References
Frequently Asked Questions
What is CVE-2026-21726?
Which Github.com/grafana/loki/v3 versions are affected?
What version fixes CVE-2026-21726?
Is github.com/grafana/loki/v3 affected?
What is the CVSS score of CVE-2026-21726?
What CWE is associated with CVE-2026-21726?
How can I check Go dependencies for CVE-2026-21726?
Machine-readable OSV JSON
OSV v1.5 Schema
{
"schema_version" : "1.4.0",
"id" : "GHSA-497x-rrr9-68jp",
"modified" : "2026-04-16T21:42:00Z",
"published" : "2026-04-15T21:30:18Z",
"aliases" : [ "CVE-2026-21726" ],
"summary" : "Grafana Loki Path Traversal - CVE-2021-36156 Bypass",
"details" : "The CVE-2021-36156 fix validates the namespace parameter for path traversal sequences after a single URL decode, by double encoding, an attacker can read files at the Ruler API endpoint /loki/api/v1/rules/{namespace}\n\nThanks to Prasanth Sundararajan for reporting this vulnerability.",
"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" : "github.com/grafana/loki/v3"
},
"ranges" : [ {
"type" : "ECOSYSTEM",
"events" : [ {
"introduced" : "0"
}, {
"fixed" : "3.6.4"
} ]
} ]
} ],
"references" : [ {
"type" : "ADVISORY",
"url" : "https://nvd.nist.gov/vuln/detail/CVE-2026-21726"
}, {
"type" : "PACKAGE",
"url" : "https://github.com/grafana/loki"
}, {
"type" : "WEB",
"url" : "https://grafana.com/security/security-advisories/cve-2026-21726"
} ],
"database_specific" : {
"cwe_ids" : [ "CWE-22", "CWE-601" ],
"severity" : "MODERATE",
"github_reviewed" : true,
"github_reviewed_at" : "2026-04-16T21:42:00Z",
"nvd_published_at" : "2026-04-15T20:16:34Z"
}
}