
Terraform in the software supply chain: Modules & providers
6/1/2022
This post details the security mechanisms for Terraform providers, including the use of SHA256 hashes (zh) for zip files and dirhashes (h1) for provider directories, as recorded in the `.terraform.lock.hcl` file. It explains how these hashes are generated and how attackers could potentially exploit the lock file by adding malicious hashes. For modules, it highlights the vulnerability of mutable Git tags and recommends using specific commit SHAs as a more secure alternative. It also references existing work on malicious Terraform modules and static detection rules.




