Unlock BitLocker protected drive with PowerShell

PowerShellI recently needed to unlock a HDD encrypted with BitLocker a number of times. I rapidly decided that entering the password manually every time was not something I wanted to do, so for that day, I needed a command line method of doing it. Fortunately, PowerShell has a commandlet available to do this:

$SecureString = ConvertTo-SecureString "{password}" -AsPlainText -Force
Unlock-BitLocker -MountPoint "X:" -Password $SecureString

The above came from the PowerShell section of the Microsoft Docs site.

The highlighted section, including braces, should be replaced with the password for the drive.

As the PowerShell script has to have the password embedded within it, this is not something I would recommend for every day use.

What should we write about next?

If there is a topic which fits the typical ones of this site, which you would like to see me write about, please use the form, below, to submit your idea.

Your Name

Your Email

Suggested Topic

Suggestion Details

2 thoughts on “Unlock BitLocker protected drive with PowerShell

  1. ute bosch says:

    you need admin rights to do that command

Leave a Reply

Your email address will not be published. Required fields are marked *