Interview Prep/DevSecOps/Tool Internals and Comparisons

What does a Vault policy look like?

IntermediateConceptTool Internals and Comparisons
Answer

Policies are HCL rules granting capabilities on paths; default is deny.

path "secret/data/payments/*" {
  capabilities = ["read"]
}

path "database/creds/payments-ro" {
  capabilities = ["read"]
}

path "secret/data/payments/admin" {
  capabilities = ["deny"]
}

Capabilities: create, read, update, patch, delete, list, sudo, deny. deny always wins. Attach policies to auth roles, e.g. a Kubernetes auth role bound to one service account in one namespace, never to broad groups.

All DevSecOps questions

More on Tool Internals and Comparisons