CVE-2024-58375 OpenTofu before 1.8.3 Secret Variable Leaking via Static Evaluation
OpenTofu users enabling static evaluation may inadvertently expose sensitive variables and locals, requiring an upgrade to prevent data leakage.
- Exploited in the wild
- Not known
- Login needed
- Not needed
- Attackable
- Over the internet
- Victim action needed
- Not needed
- Fix
- Available
What is CVE-2024-58375?
CVE-2024-58375 is a high-severity vulnerability in opentofu, published on 16 Aug 2026. An attacker can exploit it over the internet without logging in, with no action from the victim.
Official description
OpenTofu versions 1.8.0 through 1.8.2 do not properly restrict sensitive variables and locals when users have opted into static evaluation of module sources, versions, and backend configurations. As a result, values marked as sensitive may be exposed through these configuration elements instead of producing an error. This is fixed in OpenTofu 1.8.3, which adds explicit errors to prevent the use of sensitive values in these contexts.
Weakness: CWE-497
Which versions are affected by CVE-2024-58375?
3 open source packages ship an affected version, including github.com/opentofu/opentofu.
| Package | Affected | Fixed in |
|---|---|---|
github.com/opentofu/opentofu Go | From 1.8.0 | 1.8.3 |
github.com/opentofu/opentofu Go | From 1.8.0 | 1.8.3 |
github.com/opentofu/opentofu Go | From 1.8.0 | 1.8.3 |
How do I fix CVE-2024-58375?
Upgrade github.com/opentofu/opentofu to 1.8.3 or later.
Is CVE-2024-58375 being exploited?
There is no known exploitation of CVE-2024-58375 in the wild and no public exploit code.
Sources
Also known as GHSA-p8hv-x2cr-398f, GHSA-wpr2-j6gr-pjw9, GO-2024-3182.