What I am trying to achieve is to create a very small script to unlock my bitlocker drive, using the password, not the recovery password.
There is a Microsoft command for that, which is:
manage-bde -unlock D: -password
where D
is my bit locker drive. If I run this command line it will ask me for the password, and then the drive is properly unlocked.
At first I thought about creating a variable to ask for the password to the user, and then use this variable in the above command line, so that the script would look like:
set /p pass= what is your pass
manage-bde -unlock D: -password %pass%
The problem is that -password
does not seem to accept any argument, would it be the variable, or the password in clear, it will fail.
So, the only way to make it work seems to be an automatic reply to the prompt for the password, with the data in the variable.
But I don't know how to do that. I assume there is an extra command line to add after the manage-dbe
...
My programming skills are quite weak, so any help would be appreciated.
Unlock BitLocker Drives from Command PromptStep 1: Run Command Prompt as an admin. Step 2: Execute the command: manage-bde -unlock (drive letter): -password. The drive letter here is the one of the BitLocker drive you want to unlock. Step 3: Type the BitLocker password and press Enter button to confirm your password.
There is no way to bypass the BitLocker recovery key when you want to unlock a BitLocker encrypted drive without a password. However, you can reformat the drive to remove the encryption, which needs no password or recovery key.
2) Through Windows GUI mode Click Start, click Control Panel, click System and Security, and then click BitLocker Drive Encryption. Look for the drive on which you want BitLocker Drive Encryption turned off, and click Turn Off BitLocker.
Kind of late to the party but as mentioned here you can easily do this with only a couple of lines, if you don't have any problem using PowerShell:
PS C:\> $SecureString = ConvertTo-SecureString "fjuksAS1337" -AsPlainText -Force
PS C:\> Unlock-BitLocker -MountPoint "E:" -Password $SecureString
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With