Basic Auth disabled by GPO - any way around this?
My client disables basic auth via GPO, thus adversely impacting M365DSC v1.20.1125.1. Is there any way around the requirement for Basic Auth?
It seems even the EXOv2 PowerShell modules still require basic auth be enabled for the OAthu token.
I am in the same situation. The only solution that I found is to use a VM to do it. Basic auth is needed for EXO, so there is no way around it as I am aware of.
Have you tried using a Service Principal with a Certificate instead? (AppID, TenantID & CertThumbprint)
The Service Principal method likely works, as I get a new error message, Authorization_RequestDenied, but I am still trying to figure out the API permissions required for the EXO component.
Most of the Teams resources use "$ConnectionMode = New-M365DSCConnection -Platform 'SkypeForBusiness' -InboundParameters $PSBoundParameters".
New-M365DSCConnection uses Test-MsCloudLogin, so I tried:
Test-MSCloudLogin -Platform $Platform
-ApplicationId $InboundParameters.ApplicationId
-TenantId $InboundParameters.TenantId
-CertificateThumbprint $InboundParameters.CertificateThumbprint
and
Test-MSCloudLogin -Platform $Platform `
-CloudCredential $InboundParameters.GlobalAdminAccount
and they both failed with the error "The WinRM client cannot process the request. Basic authentication is currently disabled in the client configuration"
Note that if $platform = "MicrosoftTeams" the Test-MsCloudLogin cmdlets work (both versions).
Basic auth for WinRM has been a long battle for Skype for Business Online PowerShell: https://docs.microsoft.com/en-us/skypeforbusiness/set-up-your-computer-for-windows-powershell/diagnose-problems-with-the-skype-for-business-online-connector#BKMKWinRMBasicAuth