2

I am using this Windows API wrapper to try and get bitlocker status.

My code is:

test, err := wapi.GetBitLockerConversionStatus()

I am getting the following error:

err wmi.Connect: permission denied: Exception occurred. (Access denied )

When I'm logged with the same user I can get results with C# code:

IShellProperty prop = ShellObject.FromParsingName("C:").Properties.GetProperty("System.Volume.BitLockerProtection");

I have tried to call other functions in the Go wrapper such as wapi.ProcessList() and it works, so the permission issue seems to be specific to the BitLocker function and not the whole package or anything else.

My question is why does it require special permission in Go but not in C# and is there a way to get that information without elevated permission?

VonC
  • 1,262,500
  • 529
  • 4,410
  • 5,250

0 Answers0