사용자가 내 구성에서 두 번째 도메인을 탐색 할 때 올바른 apache 서버를 가져 오는 데 문제가 있습니다. 다음은 현재 내 구성이 어떻게되어 있는지 보여주는 예입니다. 이 구성은 "서버 인증서가 URL과 일치하지 않습니다."클라이언트에 다음 오류를 제공합니다. 도움에 미리 감사드립니다.하나의 IP에서 실행되는 SSL을 사용하는 두 사이트
<VirtualHost *:80>
ServerName www.domain1.com
Redirect/https://www.domain1.com/
</VirtualHost>
<VirtualHost *:443>
ServerAdmin [email protected]
ServerName www.domain1.com
SSLEngine on
SSLCertificateFile /location/ofcerts/www_domain1_com.crt
SSLCertificateKeyFile /domain1/www_domain1_com.key
SSLCertificateChainFile /location/ofcerts/COMODORSAAddTrustCA.crt
SSLCertificateChainFIle /location/ofcerts/domain1.ca-bundle
SSLProtocol all -SSLv2 -SSLv3
SSLHonorCipherOrder on
SSLCipherSuite "EECDH+ECDSA+AESGCM EECDH+aRSA+AESGCM EECDH+ECDSA+SHA384 EECDH+ECDSA+SHA256 EECDH+aRSA+SHA384 EECDH+aRSA+SHA256 EECDH+aRSA+RC4 EECDH EDH+aRSA RC4 !aNULL !eNULL !LOW !3DES !MD5 !EXP !PSK !SRP !DSS !RC4"
<Location />
SetEnv no-gzip
</Location>
DocumentRoot /var/www/
<Directory />
Options FollowSymLinks
AllowOverride None
</Directory>
<Directory /var/www/>
Options Indexes FollowSymLinks MultiViews
AllowOverride None
Order allow,deny
allow from all
</Directory>
<Directory /var/www/sub>
Options Indexes FollowSymLinks MultiViews
AllowOverride All
Order allow,deny
allow from all
</Directory>
ScriptAlias /cgi-bin/ /usr/lib/cgi-bin/
<Directory "/usr/lib/cgi-bin">
AllowOverride None
Options +ExecCGI -MultiViews +SymLinksIfOwnerMatch
Order allow,deny
Allow from all
</Directory>
ErrorLog ${APACHE_LOG_DIR}/error.log
# Possible values include: debug, info, notice, warn, error, crit,
# alert, emerg.
LogLevel warn
CustomLog ${APACHE_LOG_DIR}/access.log combined
Alias /doc/ "/usr/share/doc/"
<Directory "/usr/share/doc/">
Options Indexes MultiViews FollowSymLinks
AllowOverride None
Order deny,allow
Deny from all
Allow from 127.0.0.0/255.0.0.0 ::1/128
</Directory>
</VirtualHost>
<VirtualHost *:443>
ServerAdmin [email protected]
ServerName www.domain2.com
SSLEngine on
SSLCertificateFile /location/of/domain2certs/www_domain2_com.crt
SSLCertificateKeyFile /domain2/www_domain2_com.key
SSLCertificateChainFile /location/of/domain2certs/COMODORSAAddTrustCA.crt
SSLCertificateChainFIle /location/of/domain2certs/domain2.ca-bundle
SSLProtocol all -SSLv2 -SSLv3
SSLHonorCipherOrder on
DocumentRoot /var/www/domain2
<Directory /var/www/domain2>
Options Indexes FollowSymLinks MultiViews
AllowOverride All
Order allow,deny
allow from all
</Directory>
</VirtualHost>
'https'의 한계 중 하나는 IP 주소 하나당 하나의 URL 만 허용한다는 것입니다. –
요청이 서버에 도착하면 호스트 헤더가 암호화되어 사용할 인증서를 결정할 방법이 없으므로 SNI를 사용하거나 다른 포트에서 dom2를 실행할 수 있습니다. –
나는 SNI를 살펴볼 것이다. 잘하면 나는 그렇게 할 수있다. – leigon