HashiCorp Vault — Introduction
This chapter introduces what HashiCorp Vault is, why secrets management matters, and how Vault’s architecture enables secure storage and access to sensitive data. By the end, you’ll understand Vault’s core concepts and be ready to install it.
What’s in This Chapter?
| # | Topic | Description |
|---|---|---|
| 1 | What Is Vault? | Secrets management, the problem Vault solves, core concepts |
| 2 | Vault Architecture | Barrier, storage backend, secrets engines, auth methods, audit |
| 3 | Seal & Unseal | Shamir’s Secret Sharing, auto-unseal, seal wrap |
| 4 | Dev vs Production Mode | Dev server quick start vs production hardening |
| 5 | Vault vs Alternatives | Vault vs AWS Secrets Manager, Azure Key Vault, CyberArk |
| 6 | Practice Exercises | 5 hands-on exercises to reinforce concepts |
Why Secrets Management Matters
Every application needs secrets — database passwords, API keys, TLS certificates, encryption keys. Without proper management, secrets end up:
- Hard-coded in source code
- Stored in environment variables without rotation
- Shared in plain text via Slack or email
- Scattered across config files with no audit trail
Vault solves this by providing a centralized, audited, dynamic system for managing secrets with fine-grained access control.
Key Concepts You’ll Learn
┌─────────────────────────────────────────────────────────┐
│ HashiCorp Vault │
│ │
│ ┌─────────────┐ ┌──────────────┐ ┌────────────────┐ │
│ │ Auth │ │ Secrets │ │ Audit │ │
│ │ Methods │ │ Engines │ │ Devices │ │
│ │ │ │ │ │ │ │
│ │ • Token │ │ • KV │ │ • File │ │
│ │ • AppRole │ │ • Database │ │ • Syslog │ │
│ │ • OIDC │ │ • Transit │ │ • Socket │ │
│ │ • K8s │ │ • PKI │ │ │ │
│ └─────────────┘ └──────────────┘ └────────────────┘ │
│ │
│ ┌─────────────────────────────────────────────────────┐ │
│ │ Barrier (Encryption Layer) │ │
│ └─────────────────────────────────────────────────────┘ │
│ │
│ ┌─────────────────────────────────────────────────────┐ │
│ │ Storage Backend (Raft / Consul) │ │
│ └─────────────────────────────────────────────────────┘ │
└─────────────────────────────────────────────────────────┘
- Auth Methods — How users and machines prove their identity
- Secrets Engines — Pluggable backends that store, generate, or encrypt data
- Audit Devices — Every operation is logged for compliance
- Barrier — All data is encrypted before it reaches storage
- Storage Backend — Where encrypted data is persisted (Raft, Consul, etc.)
Chapter Flow
Start with What Is Vault? to understand the problem Vault solves, then work through the architecture, seal/unseal mechanics, and deployment modes before comparing Vault to alternatives.
Next: What Is Vault?