Skip to content
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

Proxy Origin and Referer #64

Closed
elias-garcia opened this issue Jan 16, 2018 · 4 comments
Closed

Proxy Origin and Referer #64

elias-garcia opened this issue Jan 16, 2018 · 4 comments
Assignees
Labels

Comments

@elias-garcia
Copy link

Hi! It would be a very interesting feature that when you use the proxy the Origin header of the HTTP request also changes to the proxied url. Because for example, I want to use the proxy to skip the CORS in a customer API that doesn't allow CORS.

This is the response I'm getting:

Response to preflight request doesn't pass access control check: No 'Access-Control-Allow-Origin' header is present on the requested resource. Origin 'http://127.0.0.1:5500' is therefore not allowed access.

So as I can see the proxy only changes the destination url, but not the Origin and the Referer. This could be a very interesting feature to easy skip CORS.

@ritwickdey
Copy link
Owner

ritwickdey commented Jan 18, 2018

Yep! CROS is not enabled yet. It's coming in upcoming update

@ritwickdey ritwickdey self-assigned this Jan 18, 2018
@elias-garcia
Copy link
Author

Nice to hear that! 😄

@dylantientcheu
Copy link

As of now I use a chrome extension to enable CORS.
https://chrome.google.com/webstore/detail/allow-control-allow-origi/nlfbmbojpeacfghkpbjhddihlkkiljbi

@ritwickdey
Copy link
Owner

This features is already added in v3.1.0. (Sorry, I forget to close it)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

4 participants