A small blog post to share my recent experience with Bitlocker encryption. I have been looking around for informatino in order to write my own script, and I thought I would simply share with everybody the information I have gathered during these (sometimes loooong) moments. I have written a PowerShell function myself so that we could ‘almost’ only use Switches. It is based on the Win32_TPM and the Win32_EncryptableVolume WMI classes. (and inspired from some of the links below). [important]You can download my latest Bitlocker encryption function by click this link. [/important]
1) Official TPMcmdlets for Windows 8.1 and Windows Server 2012 R2:
If you are working on some newer versions of Windows like Windows 8.1 and Windows 2012R2 you can check this link. (this sentence will look funny in a year or so ;))
2) Official Bitlocker cmdlets for Windows 8.1 and Windows Server 2012 R2:
A link to the freshly integrated Windows 8.1 Bitlocker cmdlets (based on the BitLocker Module). Click this link.
3) How to write bitlocker and TPM scripts with PowerShell for Windows 8 and prior versions? (Windows 7, Windows Xp…)
I have written a Bitlocker automation and remediation function that called the BitlockerSAK for Bitlocker Swiss Army knife. This tool is complete and allows you to manage your Bitlocker encryption and TPM activities through PowerShell in the same way that you would use Manage-BDE for example.[important]Read more about the BitlockerSAK function right here![/important]The BitlockerSAK did not fullfill your needs? You can always try to write your own cmdlets!
How to write your own PowerShell Bitlocker / TPM Cmdlets?
4) Bitlocker WMI classes:
Two links which makes everything possible concerning Bitlocker Drive encryption and its automations: The two WMI classes Win32_TPM and WIN32_EncryptableVolume.
- Win32_TPM –> http://msdn.microsoft.com/en-us/library/windows/desktop/aa376484(v=vs.85).aspx
- Win32_EncryptableVolume –> http://msdn.microsoft.com/en-us/library/windows/desktop/aa376483(v=vs.85).aspx
5) Inspire yourself from existing resources:
- Bitlocker Deployment VBS Script :
A link to a very good VBS script written by “StarrAndersen” which can help to understand how things are linked / connected to each other and find out the needed worklow.[important] Download the VBS script here[/important]
- GitHub Project
An open project on GitHub written by Thomas Malkewitz (aka “NecroMorhp”) which is actually focused on HP hardware, but it can be used as base in order to understand the exact workflow that needs to be respected.[important]Access the project by clicking here[/important]
6) Additional and external information:
- Books with Encryption scripts :
In my researches, I found this link to the book called : “Automating administration of active directoy with PowerShell 2.0” written by : Ken St. Cyr, Laura E. Hunter It contains good information on how to use the different WMI classes to automate the bitlocker tasks.[important]Check out the preview of the book on Google books right here.[/important]