express-gateway
express-gateway copied to clipboard
[Question] Proxy changeOrigin not doing anything
How I understand is the changeProxy option in the proxy policy meant to change he origin header to the gateway's origing and not from the e.g. browser's origin right?
If that's not what it's meant to do, please correct me and explain what it is meant to do 😉
If that IS what it's meant to do, it doesn't seem to work:
- proxy:
action:
serviceEndpoint: coreService
changeOrigin: true
True or false, the origin I receive in my backend is always the origin of the browser and not of my gateway. I only want to allow the CORS from the gateway, not from the frontend if that's possible.
Thanks!
@jclaessens97 Did you find a solution ?
It was just a poc so I ended with adding the original origin to the CORS config, but no real solution found.
changeOrigin adjusts the Host header on the outgoing request, not the Origin header.