node-http-proxy icon indicating copy to clipboard operation
node-http-proxy copied to clipboard

hostRewrite/autoRewrite clarity

Open avaer opened this issue 7 years ago • 3 comments
trafficstars

From the Readme:

hostRewrite: rewrites the location hostname on (201/301/302/307/308) redirects.
autoRewrite: rewrites the location host/port on (201/301/302/307/308) redirects based on requested host/port. Default: false.

The following is not clear:

  • How does hostRewrite rewrite? To the target? To the response header?
  • What is the precedence of these options? Seems that they are not logically compatible.
  • What is the hostRewrite default?

avaer avatar Jan 08 '18 20:01 avaer