【发布时间】:2015-11-15 08:05:00
【问题描述】:
我在 node app- 中使用以下模块的反向代理:
https://github.com/nodejitsu/node-http-proxy
我的问题是我是否需要修改反向代理状态的标头才能像标准一样工作?
【问题讨论】:
标签: node.js proxy reverse-proxy http-proxy node-http-proxy
我在 node app- 中使用以下模块的反向代理:
https://github.com/nodejitsu/node-http-proxy
我的问题是我是否需要修改反向代理状态的标头才能像标准一样工作?
【问题讨论】:
标签: node.js proxy reverse-proxy http-proxy node-http-proxy
根据我的基本理解,您需要使用额外的标头才能将信息传递到源服务器。
试试:
X-Forwarded-For //The IP address of the client.
X-Forwarded-Host //The original host requested by the client in the Host HTTP request header.
X-Forwarded-Server //The hostname of the proxy server.
此信息基于This
【讨论】: