Hi all,
I'm almost sure that somebody already solved the question, so I dare to
ask.
Apache 2.2+SVN+websvn. All configs are inherited from the previous admin;
I'm a noob in svn world.
Goal: to redirect all "svn checkout" requests from http to https. In other
words, if user types "svn checkout http://toolssvn/svn/repo", it shoould be
replaced with "svn checkout https://toolssvn/svn/repo" and commit should be
successfully finished.
Quotation from my config is below:
...
redirectMatch ^/index\.html /websvn/index.php
RewriteEngine On
RewriteCond %{HTTPS} off
RewriteRule (.*) https://%{HTTP_HOST}%{REQUEST_URI}
RewriteLog "logs/rewrite.log"
RewriteLogLevel 3
...
<Location /svn>
DAV svn
SVNParentPath /svn
<LimitExcept GET PROPFIND OPTIONS REPORT>
Deny from All
</LimitExcept>
</Location>
<Location /svn>
DAV svn
SVNParentPath /svn
AuthName "Subversion Repository"
AuthType Basic
# LDAP_Server sun-ds
# LDAP_Port 389
# Base_DN "ou=people,dc=sun,dc=com"
# UID_Attr uid
LDAP_Server sun-ds-edge
LDAP_Port 636
Base_DN "ou=people,dc=sun,dc=com"
UID_Attr employeenumber
<LimitExcept GET PROPFIND OPTIONS REPORT>
Require valid-user
# Need to reverse the effect of the non-SSL config.
Allow from all
</LimitExcept>
</Location>
Browser requests are redirecting right. But checkout returns error:
root@toolssvn-test:/tmp $svn checkout http://localhost/svn/admin
svn: PROPFIND request failed on '/svn/admin'
svn: PROPFIND of '/svn/admin': 302 Found (http://localhost)
(svn checkout https://localhost/svn/admin is ok)
In rewrite.log I see:
127.0.0.1 - - [04/Sep/2008:07:17:22 --0700]
[localhost/sid#87b98][rid#2475c8/initial] (2) init rewrite engine with
requested uri /svn/admin
127.0.0.1 - - [04/Sep/2008:07:17:22 --0700]
[localhost/sid#87b98][rid#2475c8/initial] (3) applying pattern '(.*)' to uri
'/svn/admin'
127.0.0.1 - - [04/Sep/2008:07:17:22 --0700]
[localhost/sid#87b98][rid#2475c8/initial] (2) rewrite /svn/admin ->
https://localhost/svn/admin
127.0.0.1 - - [04/Sep/2008:07:17:22 --0700]
[localhost/sid#87b98][rid#2475c8/initial] (2) implicitly forcing redirect
(rc=302) with https://localhost/svn/admin
127.0.0.1 - - [04/Sep/2008:07:17:22 --0700]
[localhost/sid#87b98][rid#2475c8/initial] (1) escaping
https://localhost/svn/admin for redirect
127.0.0.1 - - [04/Sep/2008:07:17:22 --0700]
[localhost/sid#87b98][rid#2475c8/initial] (1) redirect to
https://localhost/svn/admin [REDIRECT/302]
I'd appreciate any help there.
Thanks,
Z.
Received on 2008-09-04 16:29:49 CEST