-
Notifications
You must be signed in to change notification settings - Fork 20
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
CORS issue when connecting to DevTunnel #296
Comments
Were you able to solve this somehow? I'm running into the same issue. |
Hi @klvnraju, In my case I tried to use wildcard subdomains (e.g. "https://*.devtunnels.ms") and there are two things that I was missing:
This issue can be closed from my end as it is not an issue related to Dev Tunnels. It just something to keep in mind while one is setting up CORS configuration 😄 |
Glad to hear that. Closing the issue. |
I currently have a scenario where I'm running into an issue with CORS when I try to connect from one dev tunnel to another.
In my scenario I'm hosting an Angular application on devtunnel1.devtunnels.ms and my ASP.NET Core backend on devtunnel2.devtunnels.ms. I would like to communicate my Angular application (hosted on devtunnel1) to communicate with my backend hosted on devtunnel2.
Since the HTTP requests are performed by the browser, CORS is checked an I'm receiving an error of the following kind:
Access to XMLHttpRequest at 'https://devtunnel1.devtunnels.ms' from origin 'https://devtunnel2.devtunnels.ms' has been blocked by CORS policy: No 'Access-Control-Allow-Origin' header is present on the requested resource.
I should mention that the request itself is routed successfully to my backend on devtunnel2, since the response code is a 200 and I also see the request coming through. The response is blocked from the browser due to the mentioned CORS error.
Did I configure something wrong or is this scenario not supported yet?
The text was updated successfully, but these errors were encountered: