Recover Bitlocker Recovery Password Powershell

If you use Bitlocker with Active Directory Recovery, then you can quickly recover the recovery password from AD using Powershell. Yes there is an RSAT plugin that will do the same thing, but I have been on servers that do not have this and I needed the password quick.

$Bitlocker = Get-ADObject -Filter {name -like <first 8 characters of recovery key> -and ObjectClass -eq 'msFVE-RecoveryInformation'} -Properties msFVE-RecoveryPassword | Select-Object msFVE-RecoveryPassword | Out-String
$keyString = $Bitlocker
 $keyString = $keyString.replace('msFVE-RecoveryPassword', '')
 $keyString = $keyString.replace('--', '')
 $keyString = $keyString.replace('
 ', '')
Write-Host $keyString

Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s