What’s Vulnerable › Vulnerabilities
CVE-2023-4782: Terraform Allows Arbitrary File Write During Init Operation
- Severity: high (CVSS 7.8 v3.1)
- Exploited in the wild: not listed in CISA KEV
- EPSS: 0.3% probability of exploitation in the next 30 days
- Public exploit or detection template: none known
- Published: 2023-09-08 · updated 2026-06-17
- Weakness: CWE-22
Description
Terraform version 1.0.8 through 1.5.6 allows arbitrary file write during the `init` operation if run on maliciously crafted Terraform configuration. This vulnerability is fixed in Terraform 1.5.7.
Affected products
- HashiCorp Terraform: from 1.0.8 before 1.5.7 — fixed in 1.5.7
How to fix
Upgrade to a fixed version: HashiCorp Terraform 1.5.7. Check the vendor advisory for mitigations.
References
- https://discuss.hashicorp.com/t/hcsec-2023-27-terraform-allows-arbitrary-file-write-during-init-operation/58082
- https://discuss.hashicorp.com/t/hcsec-2023-27-terraform-allows-arbitrary-file-write-during-init-operation/58082
Get alerted when CVE-2023-4782 or the next vulnerability affects your stack