Screencasts - Hilfsvideos

Gather Bitlocker Encryption Status - Powershell Custom Inventory

Created: 31 Aug. 2011 • Aktualisiert: 31 Aug. 2011 | 5 Kommentare
das Bild der EMercados
+7 7 Stimmen
Bitte loggen Sie sich ein, um abzustimmen

With VBScript losing favor over Powershell, and migrating to Windows 7, I felt that it was time to start migrating our scripts to Powershell exclusively and move off VBScript wherever we could. The detection of Bitlocker was a perfect target for script rewriting. This .ps1 script will detect if the C:\ drive is Bitlocker encrypted, and will send that information as a custom inventory into Altiris. Here are the requirements:

SMP: 7.1 (I'm on SP1)

Windows 7: Tested on both SP1 and non SP1

Powershell 2.0 (required; Powershell v1.0 will not work, however Windows 7 ships with 2.0)

While Bitlocker detection is nice, what was really the tricky part was getting a custom inventory to use Powershell as its language instead of vbscript. So even if you don't care about Bitlocker, this Powershell script is a good sample script for those wanting to move off VBscript for their custom inventories. Make sure to rename the file .ps1 extension after downloading.


Kommentare KommentareZum neuesten Kommentar

das Bild der s0n-s

This is a great help for powershell inventory!

Bitte loggen Sie sich ein, um abzustimmen
das Bild der rpoags

Thanks! Been trying to figure out that last setfield call.

Ryan Poag
Northrop Grumman
If your question has been resolved, please be sure to "Mark as Solution"! Thank you.

Bitte loggen Sie sich ein, um abzustimmen
das Bild der JAunmcs

If there is a usb flash drive plugged in when this runs it returns a "Disabled" status.  It would be nice if it only checked the status of drive C.

Bitte loggen Sie sich ein, um abzustimmen
das Bild der Sally5432s

I've never done custom inventory before but am interested in collecting bitlocker status.

Can anyone direct me to what the custom data class/attributes would be to make this powershell script work?

Would the class be Win32_EncryptableVolume?  Thanks!  

Don't forget to mark posts as helpful if they are, and mark answers as solutions.

Bitte loggen Sie sich ein, um abzustimmen
das Bild der Falquians

Hi, Sally5432:

Here you have another article for getting information from bitlocker:

Kind regards:


If this post is useful to you, remember to mark it as a solution ;)

Bitte loggen Sie sich ein, um abzustimmen