Docs / Scenarios / Disk encryption and recovery passwords

PDF329 KB

Disk encryption and recovery passwords

On this page

Goal: the recovery password of every encrypted RHEL workstation is in Active Directory, on the computer's BitLocker Recovery tab, so the help desk can read one out to a user who cannot boot, and a password that was given out stops working afterwards.

You need: workstations installed with LUKS disk encryption that unlocks automatically at boot (Clevis with the TPM2 chip, or a Tang server), and GPWarden. GPWarden does not encrypt disks itself; the Linux team does that at installation.

1. Automatic unlock (Linux team)

The disk is encrypted at installation (the installer's Encrypt my data). Then bind it to the TPM, so the computer boots without anyone typing a passphrase:

Shell
dnf install clevis-luks clevis-dracut
clevis luks bind -d /dev/nvme0n1p3 tpm2 '{"pcr_ids":"7"}'
dracut -f

GPWarden uses this automatic unlock to add the recovery password unattended. A volume that only opens with a typed passphrase is reported, not changed.

2. The policy

Microsoft's BitLocker settings, in a GPO linked to the Linux OU:

Computer Configuration > Policies > Administrative Templates > Windows Components > BitLocker Drive Encryption:

  • Operating System Drives > Choose how BitLocker-protected operating system drives can be recovered: Enabled, recovery password allowed, Save BitLocker recovery information to AD DS.
  • Fixed Data Drives > Choose how BitLocker-protected fixed drives can be recovered: the same, for other encrypted volumes.

Optional, and recommended: GPWarden > Disk encryption > Rotate the recovery password after it is used (Windows offers this through Intune only).

At the next refresh, each encrypted volume gets a 48-digit recovery password in the BitLocker format, added as a new LUKS keyslot and stored on the computer object as Windows stores it.

3. The help desk lookup

As for a Windows computer:

  • Active Directory Users and Computers, the computer's BitLocker Recovery tab;
  • or PowerShell:
PowerShell
$c = Get-ADComputer WS042
Get-ADObject -SearchBase $c.DistinguishedName -Filter "objectClass -eq 'msFVE-RecoveryInformation'" `
    -Properties msFVE-RecoveryPassword, whenCreated | Sort-Object whenCreated |
    Select-Object whenCreated, msFVE-RecoveryPassword

The BitLocker Recovery tab needs the BitLocker Recovery Password Viewer feature on the admin's computer (Install-WindowsFeature RSAT-Feature-Tools-BitLocker-BdeAducExt on a server). With View > Advanced Features, the recovery object is also visible under the computer itself:

The recovery object under the RHEL computer EL10 in Active Directory Users and Computers

The user types the 48 digits at the boot prompt where the disk passphrase is asked for. A computer with several encrypted volumes has one entry each; the volume ID is the volume's LUKS UUID (lsblk -o NAME,UUID).

4. After a password was used

With Rotate the recovery password after it is used, a volume that was opened without its automatic unlock (someone typed at the boot prompt) gets a new recovery password at the next refresh: the new one is stored in AD first, then the old keyslot and the old AD entry are deleted. The BitLocker Recovery tab then shows only the password that works.

The help desk can also have it done at once: the Linux team, or a script, runs gpwardenctl recovery rotate on the workstation.

Check

  • The computer's BitLocker Recovery tab shows an entry per volume.
  • On the workstation, gpwardenctl result shows a line per volume (disk encryption recovery: /dev/... escrowed to AD); cryptsetup luksDump /dev/nvme0n1p3 shows the keyslot with the gpwarden-recovery token.

Things to know

  • When the TPM changes (firmware update, Secure Boot change), the automatic unlock may stop working; the user then needs the recovery password, and the Linux team rebinds with clevis luks regen. Rotation waits until the automatic unlock works again.
  • Removing the policy leaves the keyslot and the AD entry in place, as BitLocker keeps its protectors.
  • Older entries. Recovery passwords escrowed by GPWarden 0.1.0-10 and earlier stay in AD after rotation; DEPLOYMENT.md has a one-time PowerShell cleanup.
  • Not mapped: BitLocker key packages (LUKS has no equivalent) and Do not enable BitLocker until recovery information is stored (GPWarden does not encrypt volumes).
Questions about this page? Ask in the chat or write to support@gpwarden.com.