2015-07-10 09:43:19 +03:00
|
|
|
RewriteEngine On
|
|
|
|
|
RewriteBase /
|
|
|
|
|
|
2015-07-10 09:28:49 +03:00
|
|
|
## SSL
|
|
|
|
|
# Enforce SSL
|
|
|
|
|
RewriteCond %{SERVER_PORT} !^443$
|
|
|
|
|
RewriteRule (.*) https://%{SERVER_NAME}%{REQUEST}
|
|
|
|
|
|
|
|
|
|
## Basic Auth protection
|
2015-07-09 00:06:31 +03:00
|
|
|
AuthType Basic
|
|
|
|
|
AuthName "secured area"
|
|
|
|
|
AuthUserFile /path/to/.htpasswd
|
|
|
|
|
require valid-user
|