-
Notifications
You must be signed in to change notification settings - Fork 94
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
Refresh blocked by CORS policy: No 'Access-Control-Allow-Origin' header #98
Comments
Hi @r300mrg , |
Hi @route443, thank you for your prompt reply. Let me try this out and get back to you. Thanks |
@route443, I deployed the change you suggested (excluding When the token expires its either ok, or I get the same CORS error/issue, but the pages seem to load/work without issues despite the console error and site error popups due to the console log error. Current code:
error.log contains the following type of errors only, but these have been present before I attempted to update the code. Any other ideas/thoughts? Thanks! |
@r300mrg, so, as I understand it, the current issue is that after the Looking at this issue more broadly, the |
Thank you @route443! I'm not even going to pretend to be an expert (this is all new to me) :) Effectively we are using the code here as it is, with the required environment values changed in I have tried to fix the Any help is greatly appreciated. Thank you |
Hi @r300mrg , I'd recommend not changing anything in |
Hi @route443, my configuration is effectively the same as this main repo:
My equivalent Could the issue be due to the server location setup in frontend.conf? I don't have access to the applications manifest. I can try and get the details and re-compare with the |
Hi @r300mrg , Could you try replacing your app (upstream) with something simpler, for example:
and check if you get the same behavior? |
@route443 sorry for the delay. Other work priorities and getting access to my dev environment are delaying my investigations/testing. I will get back once I have an update or further questions. Thank you for your patience. |
Hi @route443, Thank you for your patience, and apologies for the long reply that follows. I created a basic
This seems to work and no visible browser errors, but also seems hit or miss. Also the error.log still contain e.g.
For additional background on my environment and app setup. We run NGINX on an Azure Virtual Machine that hosts Ubuntu 20.04. Our app and NGINX all run on this Ubuntu VM. We have an Angular frontend at /machines/ that makes calls to /api/machines express node.js server) and that we specify auth for each route etc. Our
One difference in our
Our app has been built on a legacy openid-connect Any thoughts or recommendations? Many thanks |
Hi @route443, Just an update on our investigations and updates from my side. The error log entry Our configuration was still using the the v1.0 token Microsoft Entra ID Oauth links for e.g. We still have the CORS initial browser error, but are looking to re-align the |
Using the latest code as of July 26th 2024 and configured to use Identity Provider (IdP) of Microsoft Entra ID (updating our dev server running legacy version of this code from a few years ago, not ideal but coming from a working setup at one point in time).
Initial site loads and authenticates as expected. However, after the authentication token expires the browser refresh fails to re-authenticate with the browser console providing the following CORS related issue:
I’ve attempted to add
proxy_set_header Access-Control-Allow-Origin *;
under both/_token
and/_refresh
in fileopenid_connect.server_conf
, and this makes no difference.Any thoughts or ideas how to resolve? Thanks
The text was updated successfully, but these errors were encountered: