Redirection SSL si auth LL::NG

This commit is contained in:
Daniel Berteaud 2012-09-13 12:49:32 +02:00
parent 3366e27941
commit 9667b50445

View File

@ -1,11 +1,11 @@
{ {
my $ssl = $domain->prop('RequireSSL') || 'disabled'; my $ssl = $domain->prop('RequireSSL') || 'disabled';
my $lemon = $domain->prop('LemonLDAP') || 'disabled'; my $auth = $domain->prop('Authentication') || 'none';
if (($modSSL{TCPPort} || "443") eq $port){ if (($modSSL{TCPPort} || "443") eq $port){
$OUT .= " SSLEngine on\n"; $OUT .= " SSLEngine on\n";
} }
elsif (($ssl =~ m/^enabled|yes|on|1$/i) || ($lemon eq 'enabled')){ elsif (($ssl =~ m/^enabled|yes|on|1$/i) || ($auth eq 'LemonLDAP')){
$OUT .=<<'EOF'; $OUT .=<<'EOF';
RewriteEngine on RewriteEngine on
RewriteRule ^/(.*|$) https://%{HTTP_HOST}/$1 [L,R] RewriteRule ^/(.*|$) https://%{HTTP_HOST}/$1 [L,R]