-
Notifications
You must be signed in to change notification settings - Fork 2.4k
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
建议增加透传ip #686
Comments
臣附议 |
这样有一个问题: 然后服务端就绕过了代理链, 直接将返回报文发给了客户端. 而且客户端一般都是内网IP, 路由不可达. |
底层的TCP/IP 网络这方面我不太懂,但有没有可能像nginx一样设置一个参数供后端取值?客户端首先连的是gost那只有gost知道客户端的真实ip,如果依赖上层应用客户端和服务端判断,客户端很容易伪造这个信息。 |
nginx传客户端的ip给服务实例的时候不是修改源ip, 而是加了http的header. |
对,我的意思也是增加一个参数供后端取值,而不是交给客户端去设置这个参数。客户端比较容易伪造。 |
正常情况下是获取不到的,需要额外协议的支持例如proxy_protocol |
建议gost做转发的时候可以透传IP,这样可以方便源获取用户ip
The text was updated successfully, but these errors were encountered: