Mod_rewrite https validation

Fix it!!

Mod_rewrite https validation

Postby rsaldiva » Tue Oct 29, 2002 8:46 am

Hello: I need to define a rule that allows that whenever somebody accesa my site, instead of using HTTP uses HTTPS, if they are connected to my site HTTP, automatically the protocol is HTTPS The structure is:

<Directory "/Apache2/htdocs/segura">

SSLVerifyClient none
SSLVerifyDepth 5

SSLCACertificateFile conf/ssl.crt/server.crt
SSLCACertificatePath conf/ssl.crt
SSLOptions +FakeBasicAuth

AuthName "User Secure"
AuthType Basic
AuthUserFile "/Apache2/bin/users"
Require valid-user


Please, Help Me...

Postby Caterham » Sat Dec 11, 2004 3:07 am

use this in your directoty
Code: Select all
RewriteEngine On
RewriteCond %{SERVER_PORT} !443
RewriteRule ^/(.*)$$1 [R=301,L]

Bob :)
Posts: 690
Joined: Fri Dec 10, 2004 1:30 pm

Return to Security with Mod_Rewrite

Who is online

Users browsing this forum: No registered users and 1 guest