# OpenTofu arbitrary file read via malicious git URL

Source: https://junglewise.ai/threats/opentofu-arbitrary-file-read-via-malicious-git-url-018b3ffb  
Publisher: Junglewise Threat Intelligence, https://junglewise.ai/threats  
Published: 2026-06-19. Updated: 2026-06-19  
License: CC BY 4.0 with a link back

Severity: high · CVSS 7.5 · Published 2026-06-19

OpenTofu, an open-source infrastructure-as-code tool, is vulnerable to a data exposure flaw when downloading external modules or providers. An attacker could provide a specially crafted URL that, when processed by OpenTofu, allows them to read sensitive files from the system running the software. This could lead to the theft of confidential configuration files, credentials, or other private data.

Technologies: [OpenTofu](https://junglewise.ai/threats/technologies/opentofu). Vendors: [OpenTofu](https://junglewise.ai/threats/vendors/opentofu).

## Quick answers

**Is This vulnerability exploited in the wild?** No. Junglewise Threat Intelligence has no report of This vulnerability being exploited in the wild.

**How severe is This vulnerability?** High severity, with a CVSS score of 7.5, published 19 June 2026.

**Which products and versions are affected?** OpenTofu < 1.11.10, >= 1.12.0-beta1, < 1.12.3, 1.10.x.

**Is there a fix for This vulnerability?** A patch was published on 2026-06-19: OpenTofu v1.11.10 and v1.12.3 released Junglewise finds every place you run it, drafts the upgrade and applies it once you approve.

**How is This vulnerability attacked?** It is attacked over the network, in a software library.

**Am I affected?** Check whether you run OpenTofu at an affected version. Junglewise does that check for you around the clock: connect your code, cloud and domains, and it matches new vulnerabilities like this one against what you actually run and tells you when one reaches you.

## Technical details

OpenTofu is affected by a vulnerability in its dependency, hashicorp/go-getter (specifically CVE-2026-4660), which is used to download modules and providers. When OpenTofu performs git operations against a maliciously crafted URL, the go-getter library fails to properly sanitize the input, potentially allowing an attacker to read arbitrary files from the local filesystem of the operator. The vulnerability is reachable over the network if an attacker can influence the source URL of a module or provider. The issue is resolved by upgrading go-getter to version 1.8.6, which is included in OpenTofu versions 1.11.10 and 1.12.3.

## Affected products

- OpenTofu OpenTofu < 1.11.10, >= 1.12.0-beta1, < 1.12.3, 1.10.x

## Timeline

- 2026-06-18: disclosed: Initial report and pull requests submitted
- 2026-06-19: advisory: GitHub Advisory GHSA-q7j3-v8qv-22vq published
- 2026-06-19: patched: OpenTofu v1.11.10 and v1.12.3 released

## References

- [https://github.com/opentofu/opentofu/security/advisories/GHSA-q7j3-v8qv-22vq](https://github.com/opentofu/opentofu/security/advisories/GHSA-q7j3-v8qv-22vq)
- [https://github.com/opentofu/opentofu/pull/4288](https://github.com/opentofu/opentofu/pull/4288)
- [https://github.com/opentofu/opentofu/pull/4292](https://github.com/opentofu/opentofu/pull/4292)
- [https://github.com/opentofu/opentofu/pull/4293](https://github.com/opentofu/opentofu/pull/4293)
- [https://github.com/hashicorp/go-getter/releases/tag/v1.8.6](https://github.com/hashicorp/go-getter/releases/tag/v1.8.6)

## Related threats

- [OpenTofu denial of service via untrusted server connections](https://junglewise.ai/threats/opentofu-denial-of-service-via-untrusted-server-connections-9195aa10)
- [OpenTofu denial of service in tofu init with malicious .zip archives](https://junglewise.ai/threats/cve-2026-74797-opentofu-denial-of-service-in-tofu-init-with-malicious-zip)
- [OpenTofu symlink following in provider cache directory](https://junglewise.ai/threats/cve-2026-74796-opentofu-symlink-following-in-provider-cache-directory)
- [OpenTofu denial of service in tofu init via malicious dependencies](https://junglewise.ai/threats/opentofu-denial-of-service-in-tofu-init-via-malicious-dependencies-f7d4163e)
