Modifying headers with IIS7 Application Request Routing

前端 未结 2 1283
礼貌的吻别
礼貌的吻别 2020-12-08 08:15

I\'m using IIS7 Application Request Routing in front of Tomcat as a replacement for ISAPI redirection. The basic reverse proxy function is working well, but I don\'t have en

相关标签:
2条回答
  • 2020-12-08 08:26

    Application Request Routing has an option to preserve the original host header: preserveHostHeader. This option is by default false. You can enable it with:

    "C:\Windows\System32\inetsrv\appcmd.exe" set config -section:system.webServer/proxy /preserveHostHeader:"True" /commit:apphost
    
    0 讨论(0)
  • 2020-12-08 08:32

    You could set the preserveHostHeader flag by hand.

        <proxy enabled="true" preserveHostHeader="true" />
    
    </system.webServer>
    

    In the iis configuration gui you can find this value under system.webServer/proxy.

    0 讨论(0)
提交回复
热议问题