Instance config inline secret exposure
Key facts
- Attack vector
- Network
- Privileges required
- None
- User interaction
- None
- Attack complexity
- Low
- Impact type
- Information disclosure
- Confidentiality · integrity · availability
- High · None · None
- Fix status
- Fixed
Attack profile from CVSS 3.1 · NVD. Fix status from CNA and GitHub. Impact type from CWE-200.
Summary
Grafana Agent is a telemetry collector for sending metrics, logs, and trace data to the opinionated Grafana observability stack. Prior to versions 0.20.1 and 0.21.2, inline secrets defined within a metrics instance config are exposed in plaintext over two endpoints: metrics instance configs defined in the base YAML file are exposed at `/-/config` and metrics instance configs defined for the scraping service are exposed at `/agent/api/v1/configs/:key`. Inline secrets will be exposed to anyone being able to reach these endpoints. If HTTPS with client authentication is not configured, these endpoints are accessible to unauthenticated users. Secrets found in these sections are used for delivering metrics to a Prometheus Remote Write system, authenticating against a system for discovering Prometheus targets, and authenticating against a system for collecting metrics. This does not apply for non-inlined secrets, such as `*_file` based secrets. This issue is patched in Grafana Agent versions 0.20.1 and 0.21.2. A few workarounds are available. Users who cannot upgrade should use non-inline secrets where possible. Users may also desire to restrict API access to Grafana Agent with some combination of restricting the network interfaces Grafana Agent listens on through `http_listen_address` in the `server` block, configuring Grafana Agent to use HTTPS with client authentication, and/or using firewall rules to restrict external access to Grafana Agent's API.
Why it matters now
SSVC decision points
Not available: CISA has not published SSVC decision points for this record.
Affected products
| Vendor | Product | Affected versions | Fixed in | Status | Source |
|---|---|---|---|---|---|
| Grafana | agent | 0.14.0 to before 0.20.1; 0.21.0 to before 0.21.2 | 0.20.1, 0.21.2 | Patch available | CNA |
| — | github.com/grafana/agent (Go) | 0.14.0 to before 0.21.2 | 0.21.2 | Patch available | GHSA-9c4x-5hgq-q3wh |
- agent VendorGrafana Affected 0.14.0 to before 0.20.1; 0.21.0 to before 0.21.2 Fixed in 0.20.1, 0.21.2 Patch available CNA
- github.com/grafana/agent (Go) Vendor— Affected 0.14.0 to before 0.21.2 Fixed in 0.21.2 Patch available GHSA-9c4x-5hgq-q3wh
Remediation
- Fix · CNA agent (grafana) Fixed in 0.20.1, 0.21.2
- Fix · GHSA-9c4x-5hgq-q3wh github.com/grafana/agent (Go) Fixed in 0.21.2 Advisory →
Timeline
- 2026-10-02 Threatist record created from CVE-2021-41090
- 2026-10-03 Alias added: GHSA-9c4x-5hgq-q3wh
References
Patch 2
Advisory 5
More Grafana Agent vulnerabilities
- TI-2024-08354 Grafana Agent Flow on Windows Unquoted service path CVSS 3.1HIGH 7.8
Sources
- CVE-2021-41090 · CVE Program
- CVE-2021-41090 · NVD
- FIRST EPSS
- GHSA-9c4x-5hgq-q3wh · GitHub Advisory Database · CC BY 4.0
This product uses the NVD API but is not endorsed or certified by the NVD. Sources and licences