简体   繁体   English

在IIS上的https标头中进行x-forwarded-for

[英]x-forwarded-for in https headers on IIS

So we have a site that sits behind a proxy and we were trying to use the x-forwarded-for header for logging purposes. 因此,我们有一个位于代理后面的站点,并且我们试图使用x-forwarded-for标头进行记录。 We then quickly noticed that x-forwarded-for is not in the https header information. 然后我们很快注意到x-forwarded-for不在https标头信息中。 Can anyone explain if or how you can get this into the https header on IIS 7? 任何人都可以解释是否或如何将其放入IIS 7的https标头中?

Thanks in advance 提前致谢

You need to offload/terminate SSL on the load balancer. 您需要在负载均衡器上卸载/终止SSL。 Since the communication is over an encrypted tunnel in SSL, the load balancer cannot see or modify the headers. 由于通信是通过SSL中的加密隧道进行的,因此负载平衡器无法查看或修改标头。 Once SSL terminates at the load balancer it add the header as it is for http. 一旦SSL在负载均衡器处终止,它将添加HTTP标头。 It can then re-establish the SSL tunnel back to the client if that is a requirement. 然后,如果需要,它可以重新建立回到客户端的SSL隧道。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM