Skip to main content

CVE-2022-21673: CWE-200: Exposure of Sensitive Information to an Unauthorized Actor in grafana grafana

Medium
Published: Tue Jan 18 2022 (01/18/2022, 21:35:10 UTC)
Source: CVE
Vendor/Project: grafana
Product: grafana

Description

Grafana is an open-source platform for monitoring and observability. In affected versions when a data source has the Forward OAuth Identity feature enabled, sending a query to that datasource with an API token (and no other user credentials) will forward the OAuth Identity of the most recently logged-in user. This can allow API token holders to retrieve data for which they may not have intended access. This attack relies on the Grafana instance having data sources that support the Forward OAuth Identity feature, the Grafana instance having a data source with the Forward OAuth Identity feature toggled on, the Grafana instance having OAuth enabled, and the Grafana instance having usable API keys. This issue has been patched in versions 7.5.13 and 8.3.4.

AI-Powered Analysis

AILast updated: 06/23/2025, 18:33:15 UTC

Technical Analysis

CVE-2022-21673 is a vulnerability in Grafana, an open-source platform widely used for monitoring and observability. The flaw arises when the Forward OAuth Identity feature is enabled on a data source. Specifically, if an API token is used to send a query to such a data source without additional user credentials, the OAuth identity of the most recently logged-in user is forwarded unintentionally. This means that an attacker possessing a valid API token can retrieve data associated with another user’s OAuth identity, potentially accessing sensitive information beyond their intended scope. For exploitation, several conditions must be met: the Grafana instance must have OAuth enabled, at least one data source must support and have the Forward OAuth Identity feature enabled, and usable API keys must exist. The vulnerability affects Grafana versions from 7.2.0 up to but not including 7.5.13, and from 8.0.0 up to but not including 8.3.4. The issue has been addressed in versions 7.5.13 and 8.3.4. This vulnerability is categorized under CWE-200, indicating exposure of sensitive information to unauthorized actors. There are no known exploits in the wild at this time. The vulnerability does not require user interaction but does require possession of an API token, which may be obtained through other means or misconfigurations. The flaw impacts confidentiality primarily, as unauthorized data access is possible, but does not directly affect integrity or availability of the system.

Potential Impact

For European organizations, the impact of this vulnerability can be significant, especially for those relying on Grafana for monitoring critical infrastructure, IT systems, or business operations. Unauthorized access to sensitive monitoring data could lead to exposure of internal system metrics, user activity logs, or other confidential operational data. This could facilitate further attacks, such as lateral movement, reconnaissance, or data leakage. Organizations in sectors such as finance, healthcare, energy, and government are particularly at risk due to the sensitive nature of their monitored data. The vulnerability could undermine trust in monitoring systems and complicate compliance with data protection regulations like GDPR, as unauthorized data exposure may constitute a breach. Although exploitation requires an API token, which limits the attack surface, API tokens are often used for automation and integration, and may be stored or transmitted insecurely, increasing risk. The absence of known exploits suggests limited active threat but does not preclude targeted attacks or future exploitation.

Mitigation Recommendations

To mitigate this vulnerability, European organizations should: 1) Immediately upgrade Grafana instances to versions 7.5.13 or 8.3.4 or later, where the vulnerability is patched. 2) Audit and restrict API token usage, ensuring tokens have minimal necessary privileges and are rotated regularly. 3) Review and disable the Forward OAuth Identity feature on data sources unless explicitly required. 4) Implement strict access controls and monitoring on API tokens to detect anomalous usage patterns. 5) Enforce OAuth configurations carefully, ensuring that OAuth identities are not forwarded unintentionally. 6) Conduct internal penetration testing and vulnerability scanning focused on Grafana deployments to identify misconfigurations or token exposures. 7) Educate DevOps and security teams about secure API key management and the risks of forwarding OAuth identities. 8) Use network segmentation and firewall rules to limit access to Grafana API endpoints to trusted systems only. These steps go beyond generic advice by focusing on configuration hardening, token management, and operational security specific to this vulnerability.

Need more detailed analysis?Get Pro

Technical Details

Data Version
5.1
Assigner Short Name
GitHub_M
Date Reserved
2021-11-16T00:00:00.000Z
Cisa Enriched
true

Threat ID: 682d9842c4522896dcbf225f

Added to database: 5/21/2025, 9:09:22 AM

Last enriched: 6/23/2025, 6:33:15 PM

Last updated: 7/29/2025, 3:19:41 PM

Views: 14

Actions

PRO

Updates to AI analysis are available only with a Pro account. Contact root@offseq.com for access.

Please log in to the Console to use AI analysis features.

Need enhanced features?

Contact root@offseq.com for Pro access with improved analysis and higher rate limits.

Latest Threats