Kategorien
Apache Webserver

Xampp mehrer Virtual Hosts mit SSL

Wenn man unter Windows mehrere Webseiten mit SSL über das https-Protokoll betreiben will, muss man in der http-vhosts.conf folgende Einträge machen:

NameVirtualHost *:443
SSLStrictSNIVHostCheck off

<VirtualHost *:443>
  DocumentRoot "C:/xampp/htdocs/foo1"
 ServerName foo1.local 
  <Directory C:\xampp\htdocs\foo1> 
   AllowOverride All 
   Allow from All 
  </Directory> 
 SSLEngine on 
 SSLCipherSuite ALL:!ADH:!EXPORT56:RC4+RSA:+HIGH:+MEDIUM:+LOW:+SSLv2:+EXP:+eNULL 
 SSLCertificateFile "conf/ssl.crt/server.crt" 
 SSLCertificateKeyFile "conf/ssl.key/server.key" 
 <FilesMatch "\.(cgi|shtml|pl|asp|php)$"> 
 SSLOptions +StdEnvVars 
 </FilesMatch>
 <Directory "C:/xampp/cgi-bin">
 SSLOptions +StdEnvVars
 </Directory>
 BrowserMatch ".*MSIE.*" nokeepalive ssl-unclean-shutdown downgrade-1.0 force-response-1.0 
</VirtualHost>

<VirtualHost *:443>
  DocumentRoot "C:/xampp/htdocs/foo2"
 ServerName foo2.local 
  <Directory C:\xampp\htdocs\foo2> 
   AllowOverride All 
   Allow from All 
  </Directory> 
 SSLEngine on 
 SSLCipherSuite ALL:!ADH:!EXPORT56:RC4+RSA:+HIGH:+MEDIUM:+LOW:+SSLv2:+EXP:+eNULL 
 SSLCertificateFile "conf/ssl.crt/server.crt" 
 SSLCertificateKeyFile "conf/ssl.key/server.key" 
 <FilesMatch "\.(cgi|shtml|pl|asp|php)$"> 
 SSLOptions +StdEnvVars 
 </FilesMatch>
 <Directory "C:/xampp/cgi-bin">
 SSLOptions +StdEnvVars
 </Directory>
 BrowserMatch ".*MSIE.*" nokeepalive ssl-unclean-shutdown downgrade-1.0 force-response-1.0 
</VirtualHost>