[svn.haxx.se] · SVN Dev · SVN Users · SVN Org · TSVN Dev · TSVN Users · Subclipse Dev · Subclipse Users · this month's index

Re: Branch 1.5.x: mod_dav_svn restricts third-party Subversion clients too much.

From: C. Michael Pilato <cmpilato_at_collab.net>
Date: Fri, 14 Mar 2008 23:43:45 -0400

Stefan Küng wrote:
> I remember we had this discussion when I first suggested the custom user
> agent string. I had to change my patch to make sure that it had 'SVN/'
> first and *then* the custom part.
> As far as I understand, SVNKit just wants to use a custom string so it's
> recognized as a different client. The indication of capabilities is done
> in the first part and (correct me if I'm wrong) has nothing to do with
> the client library but only with the numbers after the 'SVN/'.

Actually, I believe that capabilities reporting is done in a different way
altogether, not dependent on the User-Agent header, and definitely not
dependent on version numbers.

> I doubt that mod_dav_svn would interpret the numbers/capabilities
> differently if 'SVNKit/' instead of 'SVN/' was the first part of the
> string.

The question isn't about how mod_dav_svn interprets numbers or capabilities.
   It's all about having that "SVN/" in there. mod_dav_svn treats clients
which claim to be Subversion clients differently than other DAV clients.
For example, Subversion clients are not permitted to lock non-existent
files, but other DAV clients may (as required by Autoversioning).
Subversion client lock comments are stored in the repository as provided by
the client; non-Subversion client lock comments are stored as XML-ized
blocks. And there may be other differences I can't remember.

The point is, mod_dav_svn is explicitly looking for "SVN/" in the User-Agent
header as a way of knowing that it is talking to a Subversion client.
Trying to change that to look for "SVN/" and "SVNKit/" and "TortoiseSVN/"
and ... well, that's ridiculous. Hence, my suggestion that SVNKit keep the
"SVN/" at the head of the User-Agent line and appent "SVNKit" elsewhere. As
a bonus, they could actually use the version number associated with "SVN/"
as something meaningful (if only to humans) -- the version of Subversion
with which they claim basic compatibility.

> So, SVNKit could use the same first part of the user-agent string as the
> svn library, and then add the custom part at the end, as svn 1.5 does.
> Or am I completely off the road here? (wouldn't be the first time :)

You've got two wheels on and two wheels off. But that's okay -- from what
I've seen with TortoiseSVN, you're a Range Rover!

C. Michael Pilato <cmpilato_at_collab.net>
CollabNet   <>   www.collab.net   <>   Distributed Development On Demand

Received on 2008-03-15 04:44:04 CET

This is an archived mail posted to the Subversion Dev mailing list.