我偶然发现一个错误,我已将apache httpd配置为用作反向代理的虚拟主机,这是我的虚拟主机:
<VirtualHost *:80>
ServerName example2.com
ErrorDocument 404 /404.html
ErrorDocument 503 /503.html
ErrorDocument 401 /401.html
###redirect permanent####
Redirect permanent / https://example2.com/
</VirtualHost>
<VirtualHost _default_:443>
ServerName example2.com
DocumentRoot /var/www/proxyhost/public_html
ErrorLog /var/log/httpd/proxyhost_ssl_error.log
CustomLog /var/log/httpd/proxyhost_ssl_requests.log combined
SSLEngine on
SSLCertificateFile /etc/ssl/certs/apache-selfsigned.crt
SSLCertificateKeyFile /etc/ssl/private/apache-selfsigned.key
BrowserMatch "MSIE [2-8]" nokeepalive downgrade-1.0 force-response-1.0
RewriteEngine on
RewriteRule ^/test1$ /test1/ [R]
RewriteRule ^/test2$ /test2/ [R]
ProxyPass /test1/ ajp://host1:8009/test/
ProxyPassReverse /test1/ ajp://host1:8009/test/
ProxyPass /test2/ ajp://host2:8009/test2/
ProxyPassReverse /test2/ ajp://host2:8009/test2/
ProxyPreserveHost On
ErrorDocument 404 /404.html
ErrorDocument 503 /503.html
ErrorDocument 401 /401.html
</VirtualHost>
<Directory /var/www/proxyhost/public_html>
Options Indexes FollowSymLinks MultiViews
AllowOverride All
Order allow,deny
allow from all
</Directory>
问题是,使用上述配置与chrome和firefox等浏览器完美配合。但是,当我尝试使用Win Server 2003上的旧IE 6访问Web时,无法加载该页面。我尝试使用http(注释重定向功能)和https进行访问,但未显示任何内容。
这是错误日志
[Sun Oct 28 13:23:32.502672 2018] [alias:warn] [pid 22755] AH00671: The Alias directive in /etc/httpd/directory-enabled/DIR_BRI.conf at line 1 will probably never match because it overlaps an earlier Alias.
[Sun Oct 28 13:23:32.502679 2018] [alias:warn] [pid 22755] AH00671: The Alias directive in /etc/httpd/directory-enabled/DIR_BTN.conf at line 1 will probably never match because it overlaps an earlier Alias.
[Sun Oct 28 13:23:32.502685 2018] [alias:warn] [pid 22755] AH00671: The Alias directive in /etc/httpd/directory-enabled/DIR_MANDIRI.conf at line 1 will probably never match because it overlaps an earlier Alias.
[Sun Oct 28 13:23:32.503602 2018] [auth_digest:notice] [pid 22755] AH01757: generating secret for digest authentication ...
[Sun Oct 28 13:23:32.504221 2018] [lbmethod_heartbeat:notice] [pid 22755] AH02282: No slotmem from mod_heartmonitor
[Sun Oct 28 13:23:32.505594 2018] [ssl:warn] [pid 22755] AH02292: Init: Name-based SSL virtual hosts only work for clients with TLS server name indication support (RFC 4366)
[Sun Oct 28 13:23:32.507996 2018] [mpm_prefork:notice] [pid 22755] AH00163: Apache/2.4.6 (Red Hat Enterprise Linux) OpenSSL/1.0.2k-fips configured -- resuming normal operations
[Sun Oct 28 13:23:32.508016 2018] [core:notice] [pid 22755] AH00094: Command line: '/usr/sbin/httpd -D FOREGROUND'
是否有解决此问题的建议?因为我无权强迫我们的用户升级其操作系统和浏览器。
谢谢你, 加里(Galih)
答案 0 :(得分:0)
无论使用哪种浏览器,都需要修复配置错误。 Alias
,No slotmem from mod_heartmonitor
,...
对于SSL错误,您正在使用SNI(Name-based SSL virtual hosts only work for clients with TLS server name indication support (RFC 4366)
)。 IE 6不支持SNI。因此,Apache不知道IE 6用户正在尝试访问哪个站点。
当Apache收到未启用SNI的请求时,它将查看端口(此处为443),并在端口443(配置中自上而下)中找到第一个VirtualHost,以处理该请求。因此,IE 6用户将始终获得配置中第一个<VirtualHost *:443>
中标识的证书。
这时您有2个选择。
<VirtualHost *:443>
放入配置中。但是他们将无法触及其他人。编辑22:45 :如果IE6用户也无法访问您网站的http版本,则可能是:
LogLevel debug
)。