Windows Vista Forums
Vista Forums Home Join Vista Forums Windows 7 Forum Vista Tutorials Tags
Welcome to Windows Vista Forums. Our forum is dedicated to helping you find solutions with any problems, errors or issues you are experiencing with Windows Vista. The Vista forum also covers news and updates and has an extensive Windows Vista tutorial section that covers a wide range of tips and tricks.

Go Back   Vista Forums > Misc Newsgroups > VB Script

Vista - Where is \root\cimv2\Security\MicrosoftVolumeEncryption?

Reply
 
Old 04-30-2009   #1 (permalink)
OldDog


 
 

Where is \root\cimv2\Security\MicrosoftVolumeEncryption?

Hi,

I have seen references to this class on TechNet, however when I check
my WMI classes on Vista Enterprise, I do not see it. I don't see
Security listed at all. Is there something I need to do to use this
class??

OldDog

My System SpecsSystem Spec
Old 04-30-2009   #2 (permalink)
OldDog


 
 

Re: Where is \root\cimv2\Security\MicrosoftVolumeEncryption?

On Apr 30, 1:59*pm, OldDog <mikef2...@xxxxxx> wrote:
Quote:

> Hi,
>
> I have seen references to this class on TechNet, however when I check
> my WMI classes on Vista Enterprise, I do not see it. I don't see
> Security listed at all. Is there something I need to do to use this
> class??
>
> OldDog
By using the WMI browser I found the elusive \root\cimv2\Security
\MicrosoftVolumeEncryption class.
So it's there, just kind of hidden. In any event, all that it will
show me is the encryptable volumes.
What I am really looking for is a way to determine if BitLocker is
enabled and running on a machine.
Via a script, of course. Any ideas?

OldDog


My System SpecsSystem Spec
Old 05-01-2009   #3 (permalink)
OldDog


 
 

Re: Where is \root\cimv2\Security\MicrosoftVolumeEncryption?

On Apr 30, 10:01*pm, OldDog <mikef2...@xxxxxx> wrote:
Quote:

> On Apr 30, 1:59*pm, OldDog <mikef2...@xxxxxx> wrote:
>
Quote:

> > Hi,
>
Quote:

> > I have seen references to this class on TechNet, however when I check
> > my WMI classes on Vista Enterprise, I do not see it. I don't see
> > Security listed at all. Is there something I need to do to use this
> > class??
>
Quote:

> > OldDog
>
> By using the WMI browser I found the elusive \root\cimv2\Security
> \MicrosoftVolumeEncryption class.
> So it's there, just kind of hidden. In any event, all that it will
> show me is the encryptable volumes.
> What I am really looking for is a way to determine if BitLocker is
> enabled and running on a machine.
> Via a script, of course. Any ideas?
>
> OldDog
I found this on the intertubes; one problem it reports 0 (zero) for
status regardless of the actual state;

strComputer = "."
Set objWMIService = GetObject("winmgmts:\\" & strComputer & "\root
\CIMV2\Security\MicrosoftVolumeEncryption")
Set colItems = objWMIService.ExecQuery("SELECT * FROM
Win32_EncryptableVolume",,48)

For Each objItem in colItems
Wscript.Echo "DeviceID: " & objItem.DeviceID
Wscript.Echo "DriveLetter: " & objItem.DriveLetter
Wscript.Echo "EncryptionMethod: " & objItem.GetEncryptionMethod
Wscript.Echo "ProtectionStatus: " & objItem.GetProtectionStatus
Wscript.Echo "ConversionStatus: " & objItem.GetConversionStatus
Next

I think this is on the right track, just something is missing.

OldDog
My System SpecsSystem Spec
Old 05-04-2009   #4 (permalink)
OldDog


 
 

Re: Where is \root\cimv2\Security\MicrosoftVolumeEncryption?

On May 1, 10:10*am, OldDog <mikef2...@xxxxxx> wrote:
Quote:

> On Apr 30, 10:01*pm, OldDog <mikef2...@xxxxxx> wrote:
>
>
>
>
>
Quote:

> > On Apr 30, 1:59*pm, OldDog <mikef2...@xxxxxx> wrote:
>
Quote:
Quote:

> > > Hi,
>
Quote:
Quote:

> > > I have seen references to this class on TechNet, however when I check
> > > my WMI classes on Vista Enterprise, I do not see it. I don't see
> > > Security listed at all. Is there something I need to do to use this
> > > class??
>
Quote:
Quote:

> > > OldDog
>
Quote:

> > By using the WMI browser I found the elusive \root\cimv2\Security
> > \MicrosoftVolumeEncryption class.
> > So it's there, just kind of hidden. In any event, all that it will
> > show me is the encryptable volumes.
> > What I am really looking for is a way to determine if BitLocker is
> > enabled and running on a machine.
> > Via a script, of course. Any ideas?
>
Quote:

> > OldDog
>
> I found this on the intertubes; one problem it reports 0 (zero) for
> status regardless of the actual state;
>
> strComputer = "."
> Set objWMIService = GetObject("winmgmts:\\" & strComputer & "\root
> \CIMV2\Security\MicrosoftVolumeEncryption")
> Set colItems = objWMIService.ExecQuery("SELECT * FROM
> Win32_EncryptableVolume",,48)
>
> For Each objItem in colItems
> * * * * Wscript.Echo "DeviceID: " & objItem.DeviceID
> * * * * Wscript.Echo "DriveLetter: " & objItem.DriveLetter
> * * * * Wscript.Echo "EncryptionMethod: " & objItem.GetEncryptionMethod
> * * * * Wscript.Echo "ProtectionStatus: " & objItem.GetProtectionStatus
> * * * * Wscript.Echo "ConversionStatus: " & objItem.GetConversionStatus
> Next
>
> I think this is on the right track, just something is missing.
>
> OldDog- Hide quoted text -
>
> - Show quoted text -
So I added an "if" statement that restricts the view to the system
drive ( C: ) %99.9 of the time.

<-------------- Start Script ----------------------------------->
strComputer = "."
Set oShell = CreateObject("WScript.Shell")
strSDL = oShell.ExpandEnvironmentStrings("%SystemDrive%")
Set objWMIService = GetObject("winmgmts:\\" & strComputer & "\root
\CIMV2\Security\MicrosoftVolumeEncryption")
Set colItems = objWMIService.ExecQuery("SELECT * FROM
Win32_EncryptableVolume",,48)

For Each objItem in colItems
If objItem.DriveLetter = strSDL then
WScript.Echo "DeviceID: " & objItem.DeviceID
Wscript.Echo "DriveLetter: " & objItem.DriveLetter
Wscript.Echo "EncryptionMethod: " & objItem.GetEncryptionMethod
Wscript.Echo "ProtectionStatus: " & objItem.GetProtectionStatus
Wscript.Echo "ConversionStatus: " & objItem.GetConversionStatus
End If
Next

<------------ End Script -------------------------->

Be carefull of the wrap, it's a killer.
I still have the issue where it reports a 0 (zero) for all three
objects.

Still working on it.

OldDog

My System SpecsSystem Spec
Reply

Thread Tools


Similar Threads
Thread Forum
HELP root web directory (where?how?) General Discussion
Solved Root Web Directory General Discussion
"Win32_NetworkAdapter" -namespace "root\CIMV2" -FilterAdapterTypeId=0 PowerShell
Security Matters — Microsoft 2006 Security Summits Provide Security Training for Detroit Businesses Vista News
Security Matters — Microsoft 2006 Security Summits Provide Security Training for Detroit Businesses Vista News


Vista Forums is an independent web site and has not been authorized,
sponsored, or otherwise approved by Microsoft Corporation.
"Windows Vista", the Start Orb, and related materials are trademarks of Microsoft Corp.
© Designer Media Ltd

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46