OpenTofu, SHA256SUMS Signed By OpenTofu's Key

tofu on EL 10 from the GitHub release. The role imports OpenTofu's OpenPGP key into a GnuPG home of its own, refuses a keyring whose fingerprint is not the pinned one, verifies the SHA256SUMS signature, and only then lets Ansible's get_url check the zip against that file. The live test re-verifies the signature and runs tofu init. Original role, live-tested on Rocky Linux 10.

ansibleCloud Tooling

Verification

Live-tested

Really deployed to a container sandbox, proven idempotent (a second run changes nothing), verified against the role’s assertions, then torn down.

Conformance

  • Static validation (yamllint · ansible-lint)

Provenance

  • SHA-256 checksum
  • Signature (pending)

Functional

  • Live-tested - applied, verified, destroyed

Last verified 2026-09-20 · podman 4.9.3 · ansible 2.21.4 · how we verify

Documentation

opentofu

OpenTofu tofu on EL 10 from the vendor's release, checked against the published SHA-256 and the vendor's signature on it, pinned to a version, installed as root's binary in /usr/local/bin. Original role for EL 10, live-tested with podman on Rocky Linux 10.

No package worth the name. EL 10 carries no tofu, and a third-party repository is one more key to trust. This role takes the release from github.com/opentofu/opentofu, has Ansible's get_url refuse the asset unless its SHA-256 is the published one, and the live test checks the asset on disk against the same published value again.

The checksum file is signed, and the signature is checked first. OpenTofu signs tofu_1.12.6_SHA256SUMS; the role ships OpenTofu's public key (E3E6 E43D 84CB 852E ADB0 051D 0C0A F313 E5FD 9F80), imports it into a GnuPG home of its own under /usr/local/src, asserts that fingerprint, and verifies the signature before get_url is allowed to trust the file. The live test re-verifies the signature and asserts the home holds exactly the expected key(s).

Pinned. opentofu_version is what gets installed, kept in a directory of its own so the checksum file and the asset it names stay together. A newer release is a variable change and a run; the same version is changed=0.

Proven to run. The live test runs tofu -chdir=/tmp init -no-color and expects "OpenTofu initialized in an empty directory" - the binary ran all the way to the point where it needed something this host does not have.

The key's name is misleading, and the release verifies anyway. The key at get.opentofu.org/opentofu.asc carries the user id "This key is used to sign opentofu providers"; it is also what signs tofu_<version>_SHA256SUMS.gpgsig, and gpg --verify reports a good signature from it. OpenTofu also publishes cosign .sig/.pem pairs; this role checks the OpenPGP signature. tofu init in a directory with no configuration is the live test's proof that the binary runs: it says "initialized in an empty directory" and exits 0.

License

Commercial - IaC Bazaar EULA. (c) IaC Bazaar.

Usage code & full reference need an account

The complete copy-paste usage, the full input/output reference, and operational notes are free with an account - shown here and bundled in the download. Sign in and this section fills in.

  • Variables
  • Test

Related modules

Live-tested

ansible-consul-cli

consul on EL 10 from releases.hashicorp.com: the client binary, not a server. HashiCorp's key lives in a GnuPG home of its own, pinned by fingerprint; the SHA256SUMS signature is verified before get_url checks the zip against that file, and the live test verifies it again, then runs consul members against nothing and expects the refused connection. Original role, live-tested on Rocky Linux 10.

View module
Live-tested

ansible-gh-cli

gh on EL 10 from the release tarball, refused by Ansible's get_url unless its SHA-256 is the one in GitHub's checksums file, and re-checked with sha256sum -c by the live test; one more file to trust and no more repositories. Tokens are per user; gh auth status with none stops at 'not logged into any GitHub hosts', the live test's proof the client ran. Original role, live-tested on Rocky Linux 10.

View module
Live-tested

ansible-nomad-cli

nomad on EL 10 from releases.hashicorp.com: the client binary, not a server. HashiCorp's key lives in a GnuPG home of its own, pinned by fingerprint; the SHA256SUMS signature is verified before get_url checks the zip against that file, and the live test verifies it again, then runs nomad status against nothing and expects the refused connection. Original role, live-tested on Rocky Linux 10.

View module
Live-tested

ansible-packer-cli

packer on EL 10 from releases.hashicorp.com, the SHA256SUMS signature verified against HashiCorp's key in a GnuPG home of its own, pinned by fingerprint, before get_url checks the zip against that file. Pinned; the live test re-verifies the signature and runs packer validate to its 'no config file' answer. Original role, live-tested on Rocky Linux 10.

View module
Live-tested

ansible-terraform-cli

terraform on EL 10 from releases.hashicorp.com. HashiCorp's security key lives in a GnuPG home of its own, pinned by fingerprint; the SHA256SUMS signature is verified before get_url checks the zip against that file, and the live test verifies it again. BSL-licensed since 1.6; opentofu in this catalogue is the MPL alternative. Original role, live-tested on Rocky Linux 10.

View module
Live-tested

ansible-terragrunt-cli

terragrunt on EL 10 from the GitHub release, refused by Ansible's get_url unless its SHA-256 is the one in Gruntwork's SHA256SUMS, and re-checked with sha256sum -c by the live test. The asset is the bare binary; the checksum file covers every build. Needs a tofu or terraform in the PATH; pair it with opentofu or terraform-cli. Original role, live-tested on Rocky Linux 10.

View module