Advisory

GHSA-wpr2-j6gr-pjw9

Also known as: CVE-2024-58375, GO-2024-3182

Summary

OpenTofu potential leaking of secret variable values when using static evaluation in v1.8

Details

Impact
Users who have opted into static evaluation of module sources, versions, and backend configurations may be at risk of exposing sensitive variables and locals. This is a workflow that should not be possible and explicitly show errors.

Workarounds
Check that you are not using sensitive variables in module sources and versions, as well as backend configurations. The patch will add explicit errors and prevent this from being possible.

Examples

variable "backend_path" {
        type = string
        sensitive = true
}

terraform {
        backend "local" {
                path = var.backend_path
        }
}
variable "mod_info" {
        type = string
        sensitive = true
}

module "foo" {
        source = var.mod_info
        //version = var.mod_info
}

Severity

Low Basis: The source's own band: LOW

Dates

Published
2024-10-03 16:51 UTC
Modified
2026-08-17 03:55 UTC

Affected packages and fixes

github.com/opentofu/opentofu

Go · All systems

Affected

  • introduced 1.8.0, fixed 1.8.3 (semver)

Fixed versions

1.8.3

Fix

Fix commands are the export's own generic commands. Ojuju never runs them. Check them against your setup first.

Check your own computer: guard packages check

View this record on OSV.dev

Source

Source: GitHub Advisory Database (reviewed advisories) · CC BY 4.0

Sources & licences