在反向代理为en.wikipedia.org而不是zh.wikipedia.org工作之后,我的检查器阻止SNI访问zh.wikipedia.org。如果没有SNI,那么只需更正/etc/主机中的IP就足够了。
原始配置:
defaults
log 127.0.0.1:514 user
timeout connect 5000s
timeout client 5000s
timeout server 5000s
listen reverse-proxy
bind 127.0.0.1:443
mode tcp
balance static-rr
server srv1 208.80.153.224下面是反向代理引起Firefox的原因:
这个站点使用HTTP严格传输安全(HSTS)来指定Firefox只能安全地连接到它。因此,无法为该证书添加异常。
更改配置:
global
tune.ssl.default-dh-param 2048
defaults
log 127.0.0.1:514 user
timeout connect 5000s
timeout client 5000s
timeout server 5000s
listen reverse-proxy
bind 127.0.0.1:443 ssl crt /home/test/wiki.pem
mode http
http-response set-header Strict-Transport-Security "max-age=16000000; includeSubDomains; preload;"
balance static-rr
server srv1 208.80.153.224 ssl verify none发布于 2019-03-08 09:50:15
在此配置中,您不能这样做,因为您使用的是mode tcp代理,因此您的haproxy只是透明地将整个HTTP会话传递到后端。您应该切换到mode http并操作标头。
https://serverfault.com/questions/957320
复制相似问题