我似乎无法让 Apache 指令ProxyPassReverseCookieDomain实际重写域。
我的指令设置如下:
ProxyPassReverseCookieDomain "myinternalproxydomain.com" "thepublicdomain.com"
Run Code Online (Sandbox Code Playgroud)
我使用浏览器中的“网络”选项卡,可以看到Set-Cookie域没有被更改。我将 Set-Cookie 域视为thepublicdomain.com或.thepublicdomain.com。我尝试过添加
ProxyPassReverseCookieDomain "myinternalproxydomain.com" ".thepublicdomain.com"
Run Code Online (Sandbox Code Playgroud)
我已经搜索并阅读了文档,但是我不明白为什么没有设置 cookie 的域。
<VirtualHost *:443>
DocumentRoot /var/www/myinternalproxydomain.com
ServerName myinternalproxydomain.com
SSLEngine on
SSLCertificateFile /etc/ssl/certs/my.crt
SSLCertificateKeyFile /etc/ssl/private/my.key
SSLCACertificateFile /etc/ssl/certs/my.ca-bundle
SSLProxyEngine On
ProxyRequests Off
ProxyHTMLEnable On
ProxyPreserveHost Off
ProxyHTMLInterp On
ProxyHTMLExtended On
SSLProxyVerify none
SSLProxyCheckPeerCN off
SSLProxyCheckPeerName off
SSLProxyCheckPeerExpire off
ProxyPass "/" "https://thepublicdomain.com/"
ProxyPassReverse / https://thepublicdomain.com/
ProxyPassReverseCookiePath / /
ProxyPassReverseCookieDomain "myinternalproxydomain.com" "thepublicdomain.com"
ProxyPassReverseCookieDomain "myinternalproxydomain.com" "thepublicdomain.com"
ProxyPassReverseCookieDomain "myinternalproxydomain.com" ".thepublicdomain.com"
DirectorySlash On
ProxyHTMLURLMap "https://thepublicdomain.com" …Run Code Online (Sandbox Code Playgroud)