4

Hi I am calling an Azure Application Proxy endpoint (myapp.msappproxy.net) through the browser and am running into a CORs issue. How/where can I configure CORs for the Azure Application Proxy endpoint? I've looked in both the old and new Azure portals.

The error I'm getting is on the OPTIONS preflight request.

XMLHttpRequest cannot load https://myapp.msappproxy.net. Response for preflight is invalid (redirect)

I realize that you set the access-control headers on the API endpoint, in this case the App Proxy, but I can not find where to do so. Additionally, I must set a custom header in my request, because am using bearer token authentication.

Thanks!

user959729
  • 1,127
  • 2
  • 12
  • 19
  • 1
    Were you ever able to resolve the issue? – Nitin Rastogi May 18 '17 at 17:35
  • Nope.. I contacted the Microsoft team as well and they did not have a good answer. We ended up moving completely away from the Azure Application Proxy. – user959729 May 19 '17 at 19:01
  • Found a workaround. There is a limitation with the App Proxy. you can find more details here - http://stackoverflow.com/questions/43955808/cors-prelight-issue – Nitin Rastogi May 21 '17 at 14:43

1 Answers1

2

Just had the same issue. I have an Azure Application Proxy. So an internal page is available for externals. But normally the Application Body is set to No. With that setting browsers having huge CORS errors. To fix these CORS problems you have to set the Application Body to Yes. Now the body is correctly set and all browsers are able to show the website without CORS issues.

application proxy settings

Also good hints you can find in the Enable link translation section.

kwoxer
  • 3,734
  • 4
  • 40
  • 70
  • 1
    I'm looking at my initial post and it was over 3 years ago! Happy that there is new functionality that enables this. – user959729 Apr 30 '20 at 19:33