Actively exploited · Published Oct 5, 2021 · Assigned by GitHub_M

CVE-2021-39226Snapshot authentication bypass in grafana

Critical 9.8 Exploited

In plain English

A critical-severity improper authentication in grafana from grafana. Attackers are actively exploiting it in the wild (listed by CISA on August 25, 2022). The chance it is exploited in the next 30 days is estimated at 99.9% (higher than 99.9% of all known vulnerabilities). Ready-made attack tooling exists: Nuclei. Fixed versions are available - upgrade the affected package.

Severity (CVSS 3.1)9.8Critical
Exploit odds (30 days)99.9%top 0.0% of all CVEs
Exploited in the wildYesCISA KEV since Aug 25, 2022
Attack tooling1Nuclei

CISA guidance

Apply updates per vendor instructions.

Federal agencies must remediate by Sep 15, 2022.

Official description

Grafana is an open source data visualization platform. In affected versions unauthenticated and authenticated users are able to view the snapshot with the lowest database key by accessing the literal paths: /dashboard/snapshot/:key, or /api/snapshots/:key. If the snapshot "public_mode" configuration setting is set to true (vs default of false), unauthenticated users are able to delete the snapshot with the lowest database key by accessing the literal path: /api/snapshots-delete/:deleteKey. Regardless of the snapshot "public_mode" setting, authenticated users are able to delete the snapshot with the lowest database key by accessing the literal paths: /api/snapshots/:key, or /api/snapshots-delete/:deleteKey. The combination of deletion and viewing enables a complete walk through all snapshot data while resulting in complete snapshot data loss. This issue has been resolved in versions 8.1.6 and 7.5.11. If for some reason you cannot upgrade you can use a reverse proxy or similar to block access to the literal paths: /api/snapshots/:key, /api/snapshots-delete/:deleteKey, /dashboard/snapshot/:key, and /api/snapshots/:key. They have no normal function and can be disabled without side effects.

Affected packages & fixed versions

EcosystemPackageFixed inAdvisory
Gogithub.com/grafana/grafana7.5.11GHSA-69j6-29vr-p3j9
Gogithub.com/grafana/grafana8.1.6GHSA-69j6-29vr-p3j9
Rocky Linux:8grafana0:7.3.6-3.el8_4RLSA-2021:3771

Affected products (as reported)

VendorProductVersions
grafana grafana >= 8.0.0, < 8.1.6< 7.5.11

Weakness: CWE-287 · Vector: CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H

References