HashiCorp Vault Architecture
What you'll learn: How HashiCorp Vault's core components work together to securely manage, store, and distribute secrets at scale.
What is Vault's Architecture?
HashiCorp Vault is built around a client-server model with a pluggable backend design. Think of Vault as a secure vault in a bank: the vault itself has thick walls (encryption), multiple locks (seal mechanism), authorized key holders (authentication), and a secure deposit box system inside (storage backend).
Core Components
Storage Backends
Vault doesn't store data itself—it uses pluggable storage backends like Consul, etcd, filesystem, or cloud storage (S3, Azure Blob). All data is encrypted before being written to storage. The storage backend only sees encrypted blobs; it never has access to plaintext secrets. This separation means even if someone compromises your storage, they cannot read the secrets without Vault's encryption keys.
Seal/Unseal Mechanism
When Vault starts, it's sealed—encrypted and inert. The encryption key protecting Vault's data is itself encrypted by a master key. To unseal Vault, operators must provide key shares (using Shamir's Secret Sharing by default, requiring a quorum like 3 of 5 keys) that reconstruct the master key. Once unsealed, Vault can decrypt its encryption key and become operational. This prevents unauthorized access even if someone reboots the server.
Authentication Methods
Vault supports multiple auth methods (tokens, usernames/passwords, cloud IAM roles, Kubernetes service accounts, etc.). Each method validates identity and issues a Vault token that carries policies defining what secrets that identity can access—pure least privilege.
Key Takeaway: Vault's architecture separates storage (encrypted backend), access control (seal/unseal + auth methods), and policy enforcement, ensuring secrets remain encrypted at rest and accessible only to authenticated, authorized entities.