Squid3反向ssl代理SQUID_X509_V_ERR_DOMAIN_MISMATCH错误

时间:2014-10-24 12:53:51

标签: apache ssl proxy squid

我们在Debian上运行squid 3.3.4作为两个带SSL页面的apache webservers的反向代理。基于正在接收的URL并将其定向到一个或另一个服务器来分割流量。

acl acl_app urlpath_regex -i ^/app ^/store ^/admin
acl acl_old_app urlpath_regex -i ^/
acl valid_domain_acl dstdomain test.example.com

http_port 80 accel vhost
https_port 443 cert=/etc/ssl/private/example.com/current/example.com.bundle key=/etc/ssl/private/example.com/current/example.com.key  accel vhost cafile=/etc/ssl/private/example.com/current/example.com.ca-bundle

# new public site
cache_peer public.test parent 443 0 no-query no-digest originserver name=old_app ssl ssldomain=test.example.com login=PASS sslflags=DONT_VERIFY_PEER

# new app
cache_peer app.test parent 444 0 no-query no-digest originserver name=app forceddomain=test.example.com ssl ssldomain=test.example.com login=PASS sslflags=DONT_VERIFY_PEER

#these rules perform the following logic
#send /app traffic to app cache_peer
#send all other traffic to old_app cache_peer
cache_peer_access old_app deny acl_app
cache_peer_access old_app allow acl_old_app valid_domain_acl
cache_peer_access app allow acl_app valid_domain_acl
cache_peer_access app deny acl_old_app

如果我们放入sslflags = DONT_VERIFY_PEER选项,我们就可以根据需要访问这些页面但如果我们删除了sslflags设置,则会收到错误SQUID_X509_V_ERR_DOMAIN_MISMATCH

squid和Web服务器上的证书是相同的,访问的域名与证书中的名称相匹配。

虽然squid和apache之间的网络是私有网络,但我们担心通过有效地设置squid来忽略无效证书来降低网络安全性。

任何建议都将不胜感激

我使用访问该网站的网址为https://www.example.com/,该网址应重定向到public.test和https://www.example.com/app/的服务器,该网址应重定向到app.test

0 个答案:

没有答案
相关问题