]> Raphaƫl G. Git Repositories - ihttpd/blobdiff - SOURCES/ihttpd.conf
Version 2.4.62
[ihttpd] / SOURCES / ihttpd.conf
index beadf2363d40914194f78711c4bab0f4d17574dc..38f0c01c36cd979e0e19fcceca282ef41fedc573 100644 (file)
@@ -62,16 +62,30 @@ SSLCipherSuite HIGH:MEDIUM:!aNULL:!MD5
 SSLSessionCache shmcb:/run/ihttpd/ssl_scache(512000)
 SSLProtocol all -SSLv3
 
 SSLSessionCache shmcb:/run/ihttpd/ssl_scache(512000)
 SSLProtocol all -SSLv3
 
-# Redirect to https
+# Enable rewrite
 RewriteEngine On
 RewriteEngine On
+
+# Redirect to https
 RewriteCond %{HTTPS} !=on
 RewriteRule ^/?(.*) https://%{SERVER_NAME}/$1 [R,L]
 
 RewriteCond %{HTTPS} !=on
 RewriteRule ^/?(.*) https://%{SERVER_NAME}/$1 [R,L]
 
+# Redirect unexisting documents to script
+RewriteCond %{REQUEST_FILENAME} !-f
+RewriteCond %{REQUEST_FILENAME} !-d
+RewriteRule .* /index.bin [L]
+
 # SSL vhost
 <VirtualHost *:443>
 # SSL vhost
 <VirtualHost *:443>
+       # Enable ssl
        SSLEngine on
        SSLCertificateFile /etc/pki/tls/certs/ihttpd.pem
        SSLCertificateKeyFile /etc/pki/tls/private/ihttpd.pem
        SSLEngine on
        SSLCertificateFile /etc/pki/tls/certs/ihttpd.pem
        SSLCertificateKeyFile /etc/pki/tls/private/ihttpd.pem
+
+       # Inherit rewrite config
+       RewriteEngine On
+       RewriteOptions Inherit
+
+       # Set custom log
        CustomLog "/run/ihttpd/log/https.log" "%t %h %{SSL_PROTOCOL}x %{SSL_CIPHER}x \"%r\" %b"
 </VirtualHost>
 
        CustomLog "/run/ihttpd/log/https.log" "%t %h %{SSL_PROTOCOL}x %{SSL_CIPHER}x \"%r\" %b"
 </VirtualHost>