Incorrect Redirect When Using Port 8080

We’ve implemented authentication in our React SPA using the PKCE workflow via the @auth0/auth0-react package.

We use 127.0.0.1:7080 and 127.0.0.1:8080 for test and dev work. Port 7080 works fine but when using port 8080 users get redirected to auth0.com after logging in. The two are of course configured identically in the Auth0 dashboard i.e. both are in the list of callback URLs, logout URLs, and origins.

The disconnect seems to be when ourdomain.auth0.com/login/callback gets called.

When using port 8080 the response location header is ourdomain.auth0.com/?code=XXXXXXXXXXXX

When using port 7080 the response location header is 127.0.0.1:7080.auth0.com/?code=XXXXXXXXXXXX

What you describe is highly unexpected, however, in order to troubleshoot it further the best thing would be to have an HTTP trace (HAR) that contains the requests leading to the issue. If you are okay with capturing one, redacting any value you deem sensitive while leaving at least some data specific to your tenant (for example, leaving the client ID which is not considered confidential information) we could possibly review this further.

If you have concerns even with sharing client identifiers, you can consider creating a temporary client application and repro with that one.