Dear Wiki user,

You have subscribed to a wiki page or wiki category on "Httpd Wiki" for change 
notification.

The following page has been changed by RichBowen:
http://wiki.apache.org/httpd/RewriteSSL

The comment on the change is:
is HTTPS set to ON, or is it set to on? I'm not sure.

------------------------------------------------------------------------------
- 
  Bunch of SSL recipes here, based on frequently asked questions about this. 
We'll start with the favorite:
  
  = Force SSL for a certain URLs =
@@ -15, +14 @@

  
  {{{
  RewriteEngine On
- RewriteCond %{HTTPS} !=on
+ RewriteCond %{HTTPS} !=on [NC]
  RewriteRule ^/(.*) https://%{SERVER_NAME}/$1 [R,L]
  }}}
  
@@ -29, +28 @@

  
  {{{
  RewriteEngine On
- RewriteCond %{HTTPS} !=on
+ RewriteCond %{HTTPS} !=on [NC}
  RewriteRule ^/secure(.*) https://%{SERVER_NAME}/secure$1 [R,L]
  }}}
  
@@ -48, +47 @@

  The following rules would go in your SSL vhost
  
  {{{
- RewriteCond %{HTTP_HOST} !=right.example.com
+ RewriteCond %{HTTP_HOST} !=right.example.com [NC]
  # checking for non-empty host header
  RewriteCond %{HTTP_HOST} !=""
- RewriteRule ^/(.*) http://right.example.com/$1 [R=301,L]
+ RewriteRule ^/(.*) https://right.example.com/$1 [R=301,L]
  }}}
  

Reply via email to