Error Details
| Fact | Value | Source | Note |
|---|
| Exact error string | CAA20003 | Event Viewer - Application Log | -> WAM Broker |
| Affected build range | Windows 11 22H2 | Microsoft Support Documentation | |
| Registry key involved | HKCU\Software\Classes\Local Settings\Software\Microsoft\Cryptography\MSPrsKeys | Registry Editor | -> WAM Token Cache |
| Relevant service/endpoint URL | login.microsoftonline.com, teams.microsoft.com | Proxy Configuration | |
| Log line signature | WAM Broker failed to acquire token for Microsoft Teams | Event Viewer - Application Log | |
Log Files to Check
C:\Windows\System32\winevt\Logs\Application.evtxC:\Program Files (x86)\Microsoft\Edge\User Data\Default\Service Worker\Cache Storage
What This Error Actually Means
The error code CAA20003 is a specific hexadecimal value that indicates an authentication failure during the sign-in process for Microsoft Teams on Windows 11 22H2. The Web Account Manager (WAM) broker, which handles account management and token acquisition for applications like Microsoft Teams, raises this error when it fails to acquire a token from the MSAL token cache or encounters issues with the OAuth2 flow due to proxy interception. This can lead to a sign-in loop where users repeatedly see an "Something went wrong" screen, unable to proceed.
Affected Versions and Scope
This issue is specifically observed on Windows 11 build 22H2. It affects systems where the Web Account Manager (WAM) broker is involved in the authentication process for Microsoft Teams. The problem does not occur on other versions of Windows, or when using alternative methods to authenticate with Microsoft Teams such as browser-based sign-in.
Where To Look First: Logs and Event IDs
To diagnose this issue, start by examining two key log files:
C:\Windows\System32\winevt\Logs\Application.evtx
C:\Program Files (x86)\Microsoft\Edge\User Data\Default\Service Worker\Cache Storage
In the
Application.evtx log, look for entries related to WAM Broker failures. The exact log line you should grep is:
WAM Broker failed to acquire token for Microsoft Teams
This error is associated with Event ID 4096 (or similar depending on the specific implementation). Additionally, check for any errors or warnings in the Edge browser's cache storage related to OAuth2 flow interruptions.
Root Causes
The CAA20003 error can stem from several root causes:
Corrupted MSAL Token Cache
When the token cache is corrupted, WAM cannot retrieve tokens for Microsoft Teams. This corruption might occur due to system crashes or abrupt shutdowns during an authentication process.
Proxy Interception of OAuth2 Flow
If your organization uses a proxy server, it may intercept and modify the OAuth2 flow between Microsoft Teams and Microsoft's servers (login.microsoftonline.com and teams.microsoft.com). This can disrupt the token acquisition process.
Incomplete Removal of Work Accounts
Sometimes, when users remove their work accounts from Windows settings but do not completely clear associated data, remnants of these accounts can cause conflicts during sign-in attempts for Microsoft Teams.
Fix Procedure
To resolve this issue, follow the steps outlined below:
- Clear WAM Token Cache: Navigate to Settings > Accounts > Email & accounts and remove any work or school accounts associated with Microsoft Teams.
- Delete Local Application Data Folders: Open File Explorer and navigate to
%localappdata%\Packages\MicrosoftTeams_*. Delete all folders under this path. Be cautious not to delete system-critical files.
- Verify Proxy Configuration (if applicable): Ensure that the proxy settings allow direct access to login.microsoftonline.com and teams.microsoft.com by adding these URLs to the proxy bypass list.
- Clear MSAL Token Cache via Registry: Open the Registry Editor and navigate to
HKCU\Software\Classes\Local Settings\Software\Microsoft\Cryptography\MSPrsKeys. Delete any keys or values related to Microsoft Teams authentication. A WARNING: Incorrectly modifying registry entries can cause system instability.
- Run PowerShell Commands:
- Delete Edge browser cache using the following command:
Remove-Item -Path "C:\Program Files (x86)\Microsoft\Edge\User Data\Default\Service Worker\Cache Storage" -Recurse
- Check for any remaining work accounts in Intune admin center > Devices > Enrollment.
- Verify device enrollment status with:
dsregcmd /status
Error Code Variants
| Error Code | Description | Distinguishing Features |
| CAA20003 | WAM Broker token acquisition failure for Microsoft Teams. | Specific to WAM broker and MSAL cache issues. |
| CAA10004 | Generic authentication error during sign-in. | No specific mention of WAM or MSAL cache corruption. |
| CAA20005 | Error due to network connectivity issues with Microsoft's servers. | Involves HTTP status codes and network timeouts. |
Verification
To verify that the fix has been applied correctly, check for the following:
- No more errors in
C:\Windows\System32\winevt\Logs\Application.evtx related to WAM Broker failures.
- The Edge browser cache no longer contains entries from Microsoft Teams OAuth2 flow.
- Audit logs in Intune admin center > Devices > Audit log should show successful sign-in attempts for affected users.
Prevention
To prevent recurrence of this issue, implement the following policies:
- Regularly clear MSAL token cache: Use a scheduled task to run
Remove-Item -Path "HKCU\Software\Classes\Local Settings\Software\Microsoft\Cryptography\MSPrsKeys" -Recurse periodically.
- Configure proxy settings: Ensure that login.microsoftonline.com and teams.microsoft.com are always bypassed in the proxy configuration. Use OMA-URI
./Device/Vendor/MSFT/Proxycfg/BypassList to manage this setting centrally.
- Monitor for corrupted registry entries: Implement a script or policy that checks and repairs MSAL token cache keys regularly using PowerShell cmdlets like
Get-ItemProperty -Path "HKCU\Software\Classes\Local Settings\Software\Microsoft\Cryptography\MSPrsKeys".
A quick diagnostic shortcut is to run dsregcmd /status and check for any red flags in the output related to Microsoft Teams sign-in.