angular-oauth2-oidc – Read user claims

Issue I’m using angular-oauth2-oidc‘s Code Flow in an Angular application. It’s working all good, however I cannot read the user claims. I tried using this.oAuthService.getIdToken(), this.oAuthService.getAccessToken(), this.oauthService.getUserInfo() but I don’t seem to get any valid JWT that can be decoded

Continue reading

Azure B2C for Angular 8 app with angular-auth-oidc-client – b2clogin endpoint POST CORS error

Issue I used Damien Bod’s angular-auth-oidc-client in my angular 8 app with “new” Azure B2C endpoints: https://{tenant}.b2clogin.com/{tenant}.onmicrosoft.com/oauth2/v2.0/authorize https://{tenant}.b2clogin.com/{tenant}.onmicrosoft.com/oauth2/v2.0/token And STS Server looks like this: https://{tenant}.b2clogin.com/tfp/{tenant}/B2C_1_SuSi_v2/oauth2/v2.0/ But the problem is the oidc lib makes a POST request to https://{tenant}.b2clogin.com/{tenant}.onmicrosoft.com/oauth2/v2.0/token?p=b2c_1_susi_v2 and I

Continue reading

angular-oauth2-oidc token always invalid after log in

Issue I am trying to follow the guide on the documentation https://github.com/manfredsteyer/angular-oauth2-oidc. I have the following config in my constructor for the service: authCodeFlowConfig: AuthConfig = { issuer: ‘https://demo.identityserver.io’, redirectUri: window.location.origin + ‘/home’, clientId: ‘spa’, responseType: ‘code’, scope: ‘openid profile

Continue reading

How to get access token using angular-oauth2-oidc for PKCE code authentication?

Issue I am using angular-oauth2-oidc for authentication and I dont know how to get access token. I am using PKCE code flow with this configuraion authConfig: AuthConfig = { issuer: ‘https://test.com/oauth/token’, // requireHttps: false, redirectUri:’http://localhost:4200/’, strictDiscoveryDocumentValidation: false, tokenEndpoint: ‘https://test.com/oauth/token’, clientId:

Continue reading