提问人:Bernard Edward 提问时间:11/16/2023 最后编辑:CompoBernard Edward 更新时间:11/16/2023 访问量:28
用于查找 bitlockered 驱动器并提取恢复密钥的批处理脚本
Batch script to find bitlockered drives and extract recovery keys
问:
如果键入,它将显示所有驱动器的位锁状态。然后,可以确定哪些 bitlocker 处于活动状态。Manage-bde -status
如果键入 ,则会为您提供驱动器号的恢复密钥。Manage-bde -protectors -get x:
X:
最后,如果我键入 ,它会将结果导出到文本文件。Manage-bde -protectors -get x: > y:\bitlockkey.txt
我希望批处理脚本能够识别位锁定驱动器本身,然后将它已识别的每个驱动器的恢复密钥导出到我选择的位置的文本文件中。
这可能吗?
我考虑过使用:识别机器上的所有驱动器号,然后搜索这些驱动器号,但不知何故我无法弄清楚。Wmic logicaldisk get caption
答: 暂无答案
评论
%SystemRoot%\System32\wbem\WMIC.exe /Output:"Y:\bitlockkey.txt" /Namespace:\\root\CIMV2\Security\MicrosoftVolumeEncryption Path Win32_EncryptableVolume Where "VolumeType<2 And ProtectionStatus=1" Call GetKeyProtectors