Skip to content

Whitepage after logging in (Code flow + PKCE) and Angular #1129

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
m-jayson opened this issue Mar 21, 2023 · 2 comments
Closed

Whitepage after logging in (Code flow + PKCE) and Angular #1129

m-jayson opened this issue Mar 21, 2023 · 2 comments
Assignees
Labels
for: stackoverflow A question that's better suited to stackoverflow.com

Comments

@m-jayson
Copy link

Describe the bug
I can see the login but after entering the username and password it redirects to http://localhost:9000/error?continue.
image

I'm trying to do the code flow + PKCE and I followed almost every example I found from the internet but still unable.

To Reproduce
Steps to reproduce the behavior.

  1. http://localhost:4200
  2. Browser redirects to the oauth login page
  3. Enter credetials
  4. redirects to the whiltelist page above

Expected behavior
Should be able the home page

Sample
https://github.com/mgonzaga1990/spring-oauth2-angular

the authorization server is in https://github.com/mgonzaga1990/spring-oauth2-angular/tree/main/services/authorization
the angular project is in https://github.com/mgonzaga1990/spring-oauth2-angular/tree/main/ui

@m-jayson m-jayson added the type: bug A general bug label Mar 21, 2023
@m-jayson m-jayson changed the title Whitepage after logging in Whitepage after logging in (Code flow + PKCE) and Angular Mar 21, 2023
@daveyx
Copy link

daveyx commented Mar 24, 2023

same here (not 100% same, but very similar)

Whitelabel Error Page
This application has no explicit mapping for /error, so you are seeing this as a fallback.

Sat Mar 25 00:36:32 CET 2023
There was an unexpected error (type=Not Found, status=404).

EDIT:
i must call http://localhost:9001/oauth2/authorize?response_type=code&client_id=messaging-client&scope=openid&redirect_uri=http://127.0.0.1:8080/login/oauth2/code/messaging-client-oidc

then i will get the code, cool

to summarize how to get the access token with authcodeflow, one must execute:

this works in my postman, needs then be applied to angular app

@jgrandja
Copy link
Collaborator

jgrandja commented Mar 27, 2023

@mgonzaga1990 @daveyx Questions are better suited to Stack Overflow. We prefer to use GitHub issues only for bugs and enhancements.

Take a look at this sample as it uses Angular. Also see this comment for additional details.

@jgrandja jgrandja self-assigned this Mar 27, 2023
@jgrandja jgrandja added for: stackoverflow A question that's better suited to stackoverflow.com and removed type: bug A general bug labels Mar 27, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
for: stackoverflow A question that's better suited to stackoverflow.com
Projects
None yet
Development

No branches or pull requests

3 participants