公司有要求,要在ie上设置代理,在设置代理的ie访问特殊站点要跳转到另外一个站点 ,比如用代理访问 www.baidu.com 要跳转到www.google.com上
想到用apache的正向代理和反向代理结合着来做,配置代码如下
<VirtualHost 192.168.1.55:80>
ProxyRequests On
ProxyVia On
<Proxy>
Order deny,allow
Deny from all
Allow from all
</Proxy>
</VirtualHost>
<VirtualHost 192.168.1.55:80>
ProxyRequests Off
ProxyPass / http://www.google.com
ProxyPassReverse / http://www.google.com
ProxyVia On
ProxyTimeout 6
ServerName www.baidu.com
</VirtualHost>
这样访问baidu就可以跳转到google上了