nerdexam
HashiCorp

TA-002-P · Question #18

You should store secret data in the same version control repository as your Terraform configuration.

The correct answer is B. False. False. Storing secrets (API keys, passwords, tokens, certificates) in version control is a critical security risk. Even if a repository is private, secrets committed to git remain in history and can be exposed through leaks, misconfigurations, or access changes. Best practices…

Understand infrastructure as code (IaC) concepts

Question

You should store secret data in the same version control repository as your Terraform configuration.

Options

  • ATrue
  • BFalse

How the community answered

(38 responses)
  • A
    11% (4)
  • B
    89% (34)

Explanation

False. Storing secrets (API keys, passwords, tokens, certificates) in version control is a critical security risk. Even if a repository is private, secrets committed to git remain in history and can be exposed through leaks, misconfigurations, or access changes. Best practices include using environment variables, a secrets manager like HashiCorp Vault, AWS Secrets Manager, or passing sensitive values at runtime. Terraform also supports sensitive variable types to prevent accidental output exposure.

Topics

#Secrets Management#Security Best Practices#Version Control#IaC Security

Community Discussion

No community discussion yet for this question.

Full TA-002-P Practice