Redmine.pm and SVNListParentPath On
Added by Igor Olemskoi (Southbridge) over 16 years ago
Is there any possibility to allow any user to see the project's list using http://svn-server.com/svn/ url?
Now even after authorization web server returns Authentication required, error 401.
Replies (7)
RE: Redmine.pm and SVNListParentPath On
-
Added by Nicolas Chuche over 16 years ago
There's a bug in Redmine.pm that disallow anonymous users to browse public repositories. It's corrected in trunk Rev. 1776.
You can download last release of Redmine.pm here : http://redmine.rubyforge.org/svn/trunk/extra/svn/Redmine.pm
RE: Redmine.pm and SVNListParentPath On
-
Added by Igor Olemskoi (Southbridge) over 16 years ago
Thanks!
I have installed http://redmine.rubyforge.org/svn/trunk/extra/svn/Redmine.pm and configured apache according to instruction in Redmine.pm, but behaviour is the same: /svn/ asks the password and even if I enter correct username and password, it dosn't show the list if repositories.
The configuration is the following:
RewriteEngine On
RedirectMatch ^(/svn)$ $1/
- /usr/local/lib/perl5/site_perl/Apache/Authn/Redmine.pm (http://redmine.rubyforge.org/svn/trunk/extra/svn/Redmine.pm)
PerlLoadModule Apache::Authn::Redmine
<Location /svn/>
DAV svn
SVNParentPath /srv/svn
SVNListParentPath On
SVNAutoVersioning Off
Require valid-user
AuthType Basic
AuthName "Subversion Repository Access"
PerlAccessHandler Apache::Authn::Redmine::access_handler
PerlAuthenHandler Apache::Authn::Redmine::authen_handler
RedmineDSN "DBI:mysql:database=redmine;host=localhost"
RedmineDbUser "redmine"
RedmineDbPass "*********"
AddDefaultCharset utf-8
RemoveType .php .php3
</Location>
RE: Redmine.pm and SVNListParentPath On
-
Added by Nicolas Chuche over 16 years ago
Oups, Sorry I haven't read your question carefully enough.
No, it's not possible with the current Redmine.pm and it's not easy to add that in a clean way :
- how to do if there's private projects
- how to know a project is private without doing too many requests
- ...
If more people are interested by an option allowing to list project through svn for anonymous or registered users, I could try to find some time to propose a clean way
But for the moment this could be what you want in a « not so clean » way (it should be safe but I haven't verified more than that) :
--- /usr/local/apache/Redmine.pm.orig 2008-08-31 21:23:44.000000000 +0200 +++ /usr/local/apache/Redmine.pm 2008-08-31 21:22:33.000000000 +0200 @@ -217,7 +217,10 @@ my $method = $r->method; return OK unless defined $read_only_methods{$method}; - my $project_id = get_project_identifier($r); + my $project_id = get_project_identifier($r) || ""; + + $r->set_handlers(PerlAuthenHandler => [\&OK]) + if "" eq $project_id; $r->set_handlers(PerlAuthenHandler => [\&OK]) if is_public_project($project_id, $r);
RE: Redmine.pm and SVNListParentPath On
-
Added by Igor Olemskoi (Southbridge) over 16 years ago
I want to let everybody to see the whole list of SVN repositories but read/write access for each repository I want to set separately.
I have applied your patch, but even after I added the following strings in httpd.conf, Apache returns 403 access forbidden error.
<LimitExcept GET PROPFIND REPORT OPTIONS>
Require valid-user
</LimitExcept>
Thanks for help Nicolas!
RE: Redmine.pm and SVNListParentPath On
-
Added by Igor Olemskoi (Southbridge) over 16 years ago
Hmm. It seems it was cache. It works now. Sorry.
RE: Redmine.pm and SVNListParentPath On
-
Added by Bruno Medeiros almost 12 years ago
I'm also trying to use SVNListParentPath on
, do you think your patch still works?
RE: Redmine.pm and SVNListParentPath On
-
Added by Bruno Medeiros almost 12 years ago
I made a similar patch for my problem on http://www.redmine.org/issues/3827.