In my experience, command is working locally but the communication to AzureAD is not. Check for proxies or other network interference that might alter traffic/packets.
BackupToAAD-BitLockerKeyProtector Access is denied. (Exception from HRESULT: 0x80070005 (E_ACCESSDENIED))
Bojan Dunkic
1
Reputation point
Hello everyone,
I have a problem when running this bit of Powershell code only on select devices on our company network:
BackupToAAD-BitLockerKeyProtector -MountPoint $env:SystemDrive -KeyProtectorId ((Get-BitLockerVolume -MountPoint $env:SystemDrive ).KeyProtector | where {$_.KeyProtectorType -eq "RecoveryPassword" }).KeyProtectorId
Namely, it throws an error exception like this:
BackupToAAD-BitLockerKeyProtector : Access is denied. (Exception from HRESULT: 0x80070005 (E_ACCESSDENIED))
At line:1 char:1
+ BackupToAAD-BitLockerKeyProtector $env:systemdrive -KeyProtectorId $R ...
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+ CategoryInfo : NotSpecified: (:) [Write-Error], UnauthorizedAccessException
+ FullyQualifiedErrorId : System.UnauthorizedAccessException,BackupToAAD-BitLockerKeyProtector
This is very strange as I'm running the powershell script as an Admin on the devices. Some manage to run the script successfully and some get the above error.
BitLocker is enabled on all devices on the network and the devices are Azure AD Hybrid Joined.
Anyone able to help?