- This project was generated with Angular CLI version 11.0.5.
- A simple demonstration of using OAuth 2 and OpenId Connect in Angular.
- Login via Code Flow + PKCE (Proof Key for Code Exchange).
- Identity Provider
- Credentials:
Usernme: alice, Password: alice
.
Angular OAuth 2 & OIDC Client
npm i angular-oauth2-oidc
Run ng serve -o
for opening the dev server directly into your browser using default setting, i.e. http://localhost:4200/
. The default host and port settings are crucial as the identity server is configured against these.
- Route to the login page incase no user is logged in.
- Proceed to the next page after getting response from Identity Provider while making sure (via guard) that valid Id and access tokens are present.