我需要关于powershell命令- Enable-Bitlocker的帮助
下面的代码是一个示例:
$pw = ConvertTo-SecureString "123456" -AsPlainText -Force
Enable-BitLocker -MountPoint $env:SystemDrive -EncryptionMethod Aes256 -Pin $pw -TpmAndPinProtector -UsedSpaceOnly -SkipHardwareTest -ErrorAction SilentlyContinue
Start-Sleep 2
(Get-BitLockerVolume -MountPoint $env:HOMEDRIVE).KeyProtector > $env:UserProfile\Desktop\BitLocker_Recovery_Key.txt我的问题是,此命令的唯一输出是Bitlocker_Recovery_Key.txt中的以下内容
KeyProtectorId : {CC2206C6-1B69-4DC1-96FE-38EED6F576E1}
AutoUnlockProtector :
KeyProtectorType : TpmPin
KeyFileName :
RecoveryPassword :
KeyCertificateType :
Thumbprint : 我的目标是获取恢复密码(48字符串密码)作为我的bitlocker加密的备份。
提前感谢!
发布于 2021-03-04 20:58:33
在更彻底地阅读了微软的bitlocker文档后,我设法解决了我自己的问题。
似乎我已经完成了自动化该过程所需的每一步,但是为了接收恢复密钥,我们需要添加恢复密码保护器(请注意,添加恢复密码保护器并不要求我们实际提交密码,而只需要接收恢复密码和数字密码)接收密码的过程是通过调用powershell的以下命令来实现的。
Invoke-Expression "Manage-bde -protectors -add <drive of choice or $i if in a loop> -RecoveryPassword"需要管理员权限才能激活保护器,以下是使用命令manage-bde -protectors -get <$i或驱动器letter>的输出
Volume : []
All Key Protectors
TPM And PIN:
ID:
PCR Validation Profile:
Numerical Password:
ID: id
Password:
password
Numerical Password:
ID: id
Password:
password只有这样,我们才能在我们的方法中使用恢复密钥。
请注意,启用-bitlocker或管理-bde -on <驱动器或$i>不会自动生成恢复密码,我们需要添加恢复密码保护器。
https://stackoverflow.com/questions/66422997
复制相似问题