Service Azure qui fournit une plateforme de gestion hybride multicloud pour les API.
Exchange Online app-only authentication returns HTTP 401 on Get-EXOMailbox
RidermanIT8
0
Points de réputation
I’m configuring unattended Exchange Online PowerShell access with a certificate.
Configuration:
- PowerShell 7.6.4
- ExchangeOnlineManagement 3.10.1
- Connect-ExchangeOnline
- Get-EXOMailbox -ResultSize 1
The application has:
- Office 365 Exchange Online → Exchange.ManageAsApp
- Permission ID: dc50a0fb-09a3-484d-be87-e023b12c6440
- Admin consent granted
- Exchange service principal created with New-ServicePrincipal
- Application Exchange Full Access assigned
- Test-ServicePrincipalAuthorization returns IsValid: True
- Certificate thumbprint matches the certificate registered in Entra ID
Connect-ExchangeOnline succeeds, but:
Get-EXOMailbox -ResultSize 1
fails with:
Error while querying REST service.
HttpStatusCode=401
Is Exchange.ManageAsApp still the correct permission for Get-EXOMailbox, or is Exchange.ManageAsAppV2 also required
with the current ExchangeOnlineManagement module?
What could cause a REST HTTP 401 after successful certificate authentication and valid Exchange RBAC authorization?
Gestion des API Azure
Gestion des API Azure
Se connecter pour répondre