Course contentsShow
← Cloud and Infrastructure
Lesson 2267 of 2,98948. Secrets ManagementFree lesson

Vault Auto-Unseal and Seal Wrap

Using cloud KMS for automatic unsealing and protecting sensitive data with seal wrap encryption.

Vault Auto-Unseal and Seal Wrap

What you'll learn: How to eliminate manual unseal operations and add an extra encryption layer to Vault's most sensitive data using cloud KMS services.

The Manual Unseal Problem

By default, Vault requires operators to manually unseal it after each restart by providing key shares (remember lesson 2255?). This creates operational burden and delays service restoration. Auto-unseal solves this by delegating the master key encryption to an external Key Management Service (KMS), letting Vault unseal itself automatically.

How Auto-Unseal Works

Think of it like a safety deposit box: instead of splitting the key among people (Shamir shares), you store the master key in a bank vault (cloud KMS). When Vault starts, it authenticates to the KMS, retrieves the encrypted master key, decrypts it automatically, and unseals itself—no human intervention needed.

Supported KMS providers include AWS KMS, Azure Key Vault, and GCP Cloud KMS (the same services from lessons 2239-2250).

Configuration example concept:

seal "awskms" {
  region     = "us-east-1"
  kms_key_id = "alias/vault-unseal-key"
}

Seal Wrap: Extra Protection Layer

Seal wrap adds encryption on top of already-encrypted secrets. Critical data (like encryption keys and tokens) gets wrapped with the seal key before storage. If someone gains direct storage access, they'd need both the storage encryption key and the seal to decrypt sensitive values.

It's like double-locking your most valuable items: the vault itself is locked, and the jewelry box inside has its own lock.

Seal wrap automatically applies to extremely sensitive paths and can be enabled on custom mounts.

Key Takeaway: Auto-unseal eliminates manual unseal operations using cloud KMS, while seal wrap adds an additional encryption layer to protect Vault's most critical secrets—both significantly improve security and operational efficiency in production environments.