While trying to get WSFederation working inside an ASP.NET Core application, I got the following error message:
SecurityTokenInvalidAudienceException: IDX10214: Audience validation failed. Audiences: '[PII is hidden]'. Did not match: validationParameters.ValidAudience: '[PII is hidden]' or validationParameters.ValidAudiences: '[PII is hidden]'.
Hiding the PII seems a good idea from a security perspective but makes it hard to debug this problem.
To make the PII visible, you can add the following line of code: