System.IdentityModel.Tokens.SecurityTokenException: Invalid issuer or signature RRS feed

  • Question

  • We have an provider hosted app running in Share Point Online which connects to internal IIS server hosting typical aspx application. The application tries to read the logged in share point online user details and fails with below exception.

    I see that application is unable to create share point context using CSOM and because of which the below exception might be thrown.

    Unable to figure out if this is happening due to any connectivity issue to O365. All firewalls seems to be open and there is access to internet.

    Any inputs to trouble shoot this is helpful.

    System.IdentityModel.Tokens.SecurityTokenException: Invalid issuer or signature.

    at Microsoft.IdentityModel.S2S.Tokens.JsonWebSecurityTokenHandler.VerifySignature(String signingInput, String signature, String algorithm, SecurityToken signingToken) at Microsoft.IdentityModel.S2S.Tokens.JsonWebSecurityTokenHandler.ReadTokenCore(String token, Boolean isActorToken)

    Monday, December 17, 2018 11:38 AM