Project Lockbox · 16 of 16 chapters complete

HashiCorp Vault for Secret Consumers

Learn the application side of identity, policy, short-lived credentials, delivery, reload, failure, and recovery. The shared lab is disposable and creates no AWS or Kubernetes infrastructure.

Course outcome

Design and verify how an application, CI job, EC2 workload, or EKS pod authenticates to Vault and consumes KV data, dynamic PostgreSQL credentials, and short-lived certificates.

9 application/workload chapters5 human CLI chapters1 CI chapter1 supporting chapter

Safety contract

Never display secrets

Verify metadata, modes, TTLs, versions, fingerprints, status, and expected denial.

One ignored runtime area

Generated tokens, leases, credentials, certificates, and renders stay under learn-vault/.runtime.

Disposable by design

One cleanup command removes containers, volumes, and runtime material. No cloud resource is applied.

Before you start

cd learn-vault/labs/bootstrap
./preflight.sh
./setup.sh
source ../../.runtime/learner.env

Chapters

Chapter 1 Supporting context · all Lockbox consumers

Vault from the Consumer Perspective

Build the consumer mental model: authenticate, receive narrow capability, obtain secret material, renew or replace it, then revoke it.

Chapter 2 Human user · Priya

Safe Local Lab and First Login

Operate a disposable Vault lab without committing bootstrap tokens, generated credentials, certificates, or runtime configuration.

Chapter 3 Human user · Priya

CLI, API, UI, Paths, and Mounts

Translate one operation across CLI and HTTP API, and distinguish a mount path from the engine-specific API path.

Chapter 4 Human user · Priya

Tokens, Leases, TTLs, and Revocation

Reason about the independent lifetimes of the Vault token and the material obtained with it.

Chapter 5 Human user · Priya

Policies and 403 Troubleshooting

Turn permission denied into a precise capability diagnosis without broadening access blindly.

Chapter 6 Human user · Priya

KV v2 Without Secret Sprawl

Use versioned static secrets while keeping values out of source, logs, history, arguments, and durable application storage.

Chapter 7 Application/workload user · orders-api

Choose Workload Auth and Use AppRole

Prefer identity-native authentication and use AppRole only for constrained machines without a stronger runtime identity.

Chapter 8 Application/workload user · orders-api

Dynamic PostgreSQL Credentials

Replace a shared database password with leased PostgreSQL users, least privilege, pool rotation, and revocation.

Chapter 9 Application/workload user · orders-api

Short-Lived PKI Certificates

Issue a short-lived service certificate, validate its identity and chain, install it atomically, and replace it before expiry.

Chapter 10 Application/workload user · orders-api

Vault Agent for Applications

Use Vault Agent auto-auth and templates to separate token lifecycle from application code while preserving a clear reload contract.

Chapter 11 CI user · GitLab pipeline

GitLab CI with ID Tokens

Exchange a job-scoped GitLab OIDC ID token for narrow Vault access without storing a reusable CI credential.

Chapter 12 Application/workload user · orders-api

AWS IAM Authentication

Authenticate an AWS workload by proving IAM identity through a signed request instead of distributing a Vault login secret.

Chapter 13 Application/workload user · orders-api

Kubernetes Authentication on EKS

Authenticate a pod with a projected service-account token bound to namespace, service account, audience, and lifetime.

Chapter 14 Application/workload user · orders-api

Injector, CSI, or Direct API

Choose Kubernetes delivery by lifecycle ownership, update semantics, coupling, and failure behavior.

Chapter 15 Application/workload user · orders-api

Rotation, Reload, Caching, and Outages

Design a bounded state machine for fresh, renewing, stale-but-valid, terminal, and recovered secret states.

Chapter 16 Application/workload user · orders-api

Project Lockbox Readiness Drills

Assemble the design and prove it through rotation, revocation, outage, denial, cleanup, and recovery evidence.

Project Lockbox target

Runtime identitystep 1Vault policiesstep 2KV plus DB plus PKIstep 3Reload and readinessstep 4

orders-api ends with identity-native login, least-privilege paths, timed credentials, protected delivery, atomic reload, safe telemetry, and tested outage behavior.