IaC Bazaar

Vault Policies & Auth

Vault policies, auth backends, and secret engine configuration as code.

terraformSecurity & Secrets#multi

Compare Secrets & Key Management across clouds →

vault-policiesterraform v1.7

Verification

Plan-validated

Passed: module logic verified on a mocked plan - inputs, validation rules, conditional creation and outputs resolve (no real provider, no cloud).

Conformance

  • Static validation (fmt · validate · tflint)
  • No applicable security policies for this provider
  • Plan tests (mocked: validation rules · outputs)

Provenance

Functional

  • Live test pending (no cloud run yet)

Last verified 2026-06-28 · how we verify

Verify this download

cosign · sha-256

Don't take our word for it. Every release is signed with cosign - check the bytes against our pinned public key before you trust them.

# 1. Our pinned public key - fetch once, trust out-of-band
curl -O https://www.iac-bazaar.com/cosign.pub

# 2. This module's Sigstore bundle
curl -o vault-policies-1.0.0.sigstore.json \
  https://www.iac-bazaar.com/api/artifacts/vault-policies/signature

# 3. Verify the tarball you downloaded
cosign verify-blob \
  --key cosign.pub \
  --bundle vault-policies-1.0.0.sigstore.json \
  vault-policies-1.0.0.tar.gz
# → Verified OK

# 4. (optional) confirm the checksum too
echo "08c0a9a5a38c6ebe33e8dabe47e47634b82fa52337f93ed90c7fa5625a0af56c  vault-policies-1.0.0.tar.gz" | sha256sum -c

Use it from the registry

terraform · opentofu
module "policies" {
  source  = "www.iac-bazaar.com/iac-bazaar/vault-policies/multi"
  version = "1.0.0"
}

Paid module — needs a purchase (or a subscription that covers it) plus a registry token from /account/tokens. Full setup: registry docs.

Inputs & outputs

Create a free account to read this module's contract

The declared contract — every input name, type, default and description, plus every output — is shown to signed-in accounts, not to anonymous visitors.

A free account sees the contract of every Free module. This one is Basic, so its contract unlocks when you buy it.

Documentation

vault-policies

Status: static-validated, live-test pending. Ships under live-test quarantine — Vault provisioning is verified with fmt, validate, and tflint, but the apply → verify → destroy lane against a real Vault is not yet wired up (a local dev-mode Vault container is the planned live-test lane).

Vault policies, auth methods, and secret engines as code in one composable module. Works with Terraform and OpenTofu (>= 1.6), hashicorp/vault provider >= 5.0, < 6.0. Three maps — policies, auth_backends, secret_engines — describe a Vault tenant's Day-1 access surface, and a single module call brings it up against an already-running Vault (self-hosted or HCP Vault Dedicated).

Secure defaults

  • Deny-by-default by construction. Vault grants nothing unless a policy names a path, so a least-privilege posture is the natural one. The example policies scope each consumer to exactly one path prefix.
  • Auth methods stay unlisted. tune.listing_visibility defaults to hidden, so enabled methods are not advertised on the unauthenticated UI/CLI surface unless you explicitly opt into unauth.
  • No secrets in code. The module configures Vault structure only; it never writes secret material. Provider auth (VAULT_ADDR/VAULT_TOKEN) is supplied by the environment, never hardcoded.
  • Per-mount hardening available. seal_wrap, lease ceilings, and audit_non_hmac_* keys are exposed per secret engine for engines that store especially sensitive material.
  • Reserved names rejected. Policy names are validated against ^[a-zA-Z0-9_./-]+$ and the reserved root/default policies are refused.

Requirements

  • Terraform or OpenTofu >= 1.6
  • hashicorp/vault >= 5.0, < 6.0
  • A reachable, unsealed Vault and a token with privileges to manage sys/policies/acl, sys/auth, and sys/mounts

License

Commercial — LicenseRef-IaCBazaar-Commercial. © IaC Bazaar. Original work (not derived from a third-party module).

Usage code & full reference unlock after purchase

The complete copy-paste usage, the full input/output reference, and operational notes ship with your licence - shown here and bundled in the download.

  • Usage
  • Inputs
  • Outputs
  • Notes

Related modules