You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@subversion.apache.org by David Anderson <da...@calixo.net> on 2006/01/14 23:17:28 UTC

Re: SVNListParentPath

On Monday 02 January 2006 20:16, ESSI - Billie H. Cleek wrote:
> After 'SVNListParentPath on' does not list the repositories on our
> server; I get a 403 Forbidden error, but the contents of each repository
> displays fine.  Permissions for the SVNParentPath are set correctly (the
> same as for all subdir of SNVParentPath).  Any ideas on why I can't just
> flip the switch to turn on SVNListParentPath?

This is a problem due to the behaviour of authz, which incorrectly takes 
authority over the root of the SVNParentPath area and denies access. This is 
a bug.

I have investigated the problem and tracked it down to what I believe is an 
incorrect behaviour of dav_svn_split_uri (in mod_dav_svn/repos.c). When it 
encounters a relative (within the Location root) path equal to "/", it 
returns a 403 error and logs "No repository was given in the URI". The 
following patch corrects this, and makes it return giving a NULL repos_name, 
to indicate the URI refers to no repository.

This, along with a small test in mod_authz_svn, allows the latter to disregard 
accesses to the root of the SVNParentPath.

However, I ran into a problem while working on this. At first, I wanted 
mod_authz_svn to return DECLINED for requests to the ParentPath root, but 
that translated to 403 in my apache setup, and I was unable to change that. 
How would a user configure HTTPd to translate DECLINED into OK just for that 
path (and keep the default DENY for everything else) ?

The patch I ended up with is attached. Notice that it currently returns OK for 
the parent path instead of DECLINED, because of the reasons stated above. I 
have not yet checked for side-effects in other places where dav_svn_split_uri 
is used, so please don't commit this patch. I'm submitting it for review and 
approval on the concept of the fix. If it seems okay, I'll wrap up the 
verifications and modifications before commiting.

- Dave.

Re: SVNListParentPath

Posted by Norbert Unterberg <nu...@gmail.com>.
Hi,

since I am currently falling over this issue (see below) with
subversion 1.3.2, I wonder if this has been resolved in 1.4?

Norbert


2006/1/15, David Anderson <da...@calixo.net>:
> On Monday 02 January 2006 20:16, ESSI - Billie H. Cleek wrote:
> > After 'SVNListParentPath on' does not list the repositories on our
> > server; I get a 403 Forbidden error, but the contents of each repository
> > displays fine.  Permissions for the SVNParentPath are set correctly (the
> > same as for all subdir of SNVParentPath).  Any ideas on why I can't just
> > flip the switch to turn on SVNListParentPath?
>
> This is a problem due to the behaviour of authz, which incorrectly takes
> authority over the root of the SVNParentPath area and denies access. This is
> a bug.
>
> I have investigated the problem and tracked it down to what I believe is an
> incorrect behaviour of dav_svn_split_uri (in mod_dav_svn/repos.c). When it
> encounters a relative (within the Location root) path equal to "/", it
> returns a 403 error and logs "No repository was given in the URI". The
> following patch corrects this, and makes it return giving a NULL repos_name,
> to indicate the URI refers to no repository.
>
> This, along with a small test in mod_authz_svn, allows the latter to disregard
> accesses to the root of the SVNParentPath.
>
> However, I ran into a problem while working on this. At first, I wanted
> mod_authz_svn to return DECLINED for requests to the ParentPath root, but
> that translated to 403 in my apache setup, and I was unable to change that.
> How would a user configure HTTPd to translate DECLINED into OK just for that
> path (and keep the default DENY for everything else) ?
>
> The patch I ended up with is attached. Notice that it currently returns OK for
> the parent path instead of DECLINED, because of the reasons stated above. I
> have not yet checked for side-effects in other places where dav_svn_split_uri
> is used, so please don't commit this patch. I'm submitting it for review and
> approval on the concept of the fix. If it seems okay, I'll wrap up the
> verifications and modifications before commiting.
>
> - Dave.
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
> For additional commands, e-mail: dev-help@subversion.tigris.org
>
>
>

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org

Re: SVNListParentPath

Posted by David Anderson <da...@calixo.net>.
On Monday 16 January 2006 14:46, Carlos Alberto Costa Beppler wrote:
> If you specify the location os your SVNParentPath with a trainling
> slash, it works.

Yes, I know.  Afaict, that's just an artifact of the way Apache/mod_dav_svn 
interact.  But the fact remains that it is a bug to be resolved.

- Dave.

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org

Re: SVNListParentPath

Posted by Carlos Alberto Costa Beppler <be...@gmail.com>.
If you specify the location os your SVNParentPath with a trainling
slash, it works.

Example:

this does not work:
<Location /repos>
  DAV svn
  SVNParentPath "D:/beppler/subversion/repos/"
  AuthzSVNAccessFile "D:/beppler/subversion/repos/access.conf"
  SVNIndexXSLT "/svnindex.xsl"
  SVNAutoversioning On
  SVNListParentPath On
</Location>

But this works:
<Location /repos/>
  DAV svn
  SVNParentPath "D:/beppler/subversion/repos/"
  AuthzSVNAccessFile "D:/beppler/subversion/repos/access.conf"
  SVNIndexXSLT "/svnindex.xsl"
  SVNAutoversioning On
  SVNListParentPath On
</Location>

On 1/14/06, David Anderson <da...@calixo.net> wrote:
> On Monday 02 January 2006 20:16, ESSI - Billie H. Cleek wrote:
> > After 'SVNListParentPath on' does not list the repositories on our
> > server; I get a 403 Forbidden error, but the contents of each repository
> > displays fine.  Permissions for the SVNParentPath are set correctly (the
> > same as for all subdir of SNVParentPath).  Any ideas on why I can't just
> > flip the switch to turn on SVNListParentPath?
>