Malicious Terraform Providers Distribute Go Malware via HashiCorp Registry

Researchers identified Go-based malware distributed through malicious Terraform providers and Go Modules hosted on the HashiCorp official registry, exposing DevOps environments to novel risks.

Why it matters

This represents the first known use of HashiCorp's trusted registry as a malware delivery channel, raising concerns about supply chain risks within infrastructure-as-code tooling.

SOC impact

Monitor for use of suspicious or unauthorized Terraform providers and Go Modules from the HashiCorp registry. Review environment configurations for deployment of these components and check logs for unexpected downloads or executions related to Terraform and Go modules.

Recommended actions

  1. Inventory deployed Terraform providers and Go Modules
  2. Analyze download logs from the HashiCorp registry for unusual activity
  3. Correlate telemetry for execution of unapproved infrastructure components
  4. Review DevOps pipeline configurations for inclusion of unauthorized modules
  5. Consult the original The Hacker News report for ongoing updates

Executive Summary

Security researchers have uncovered a novel malware distribution mechanism involving two Terraform providers and two Go Modules hosting Go-based malware directly on HashiCorp’s official registry. This technique leverages trusted infrastructure-as-code repositories, a new vector in supply chain attacks targeting DevOps workflows. Since these malicious providers have been downloaded hundreds of times, organizations using Terraform and Go Modules should prioritize detection of their deployment to assess potential exposure. Operationally, defenders must scrutinize infrastructure provisioning tools and related telemetry to identify any unauthorized or suspicious components sourced from the HashiCorp registry. This incident underscores the evolving threat landscape where authentic development and operations repositories can be weaponized to deliver malware.

SOC Impact

Monitor for use of suspicious or unauthorized Terraform providers and Go Modules from the HashiCorp registry. Review environment configurations for deployment of these components and check logs for unexpected downloads or executions related to Terraform and Go modules.

Infrastructure-as-Code Component Validation

  • Inventory deployed Terraform providers and Go Modules
  • Analyze download logs from the HashiCorp registry for unusual activity
  • Correlate telemetry for execution of unapproved infrastructure components
  • Review DevOps pipeline configurations for inclusion of unauthorized modules
  • Consult the original The Hacker News report for ongoing updates

Why It Matters

This represents the first known use of HashiCorp’s trusted registry as a malware delivery channel, raising concerns about supply chain risks within infrastructure-as-code tooling.

Source