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

Re: [PATCH] checksums for text bases (early review opportunity)

From: Justin Erenkrantz <jerenkrantz_at_apache.org>
Date: 2002-04-12 10:36:56 CEST

On Thu, Apr 11, 2002 at 06:46:10PM -0500, Karl Fogel wrote:
> This isn't working yet, but its general shape is pretty clear, so I'm
> posting it now for people to review & comment early.
>
> Currently it can seg fault. The problem seems to occur in the xml
> quoting code, because I mistakenly thought that APR's Md5 digests were
> the long format (sixteen 7-bit chars or whatever it is). Apparently
> they're not, and I need to learn how to convert to a friendlier format
> for storage in the .svn/entries file anyway (independent of xml
> escaping problem). Does this require apr_xlate.h, or is there some
> easier way?

I've been gone for a long while, so excuse me if I'm jumping in here
without knowing what it is I'm talking about. =) All my SVN email
is queued up and I'll try to get at it soon-ish.

Anyway, I'm not really sure what you are talking about. The digest
should be returned as "unsigned char digest[MD5_DIGESTSIZE]" which
is 16 7-bit chars (unless I'm doing my math wrong too). So, that
seems like the long format. What is the output that you are getting
and what would you like it to be?

I believe it can be any of the 7-bit chars, which may cause a problem
for XML - just passing it through the escaper should do the trick
before writing it out to a file, right? You could also translate
each 7-bit char into a corresponding hex digit (which is what
md5sum et al do). Therefore, all you have is [0-9a-f] which XML
won't have a problem with.

apr_xlate is for EBCDIC which is something I don't *think* we're
focusing on here in SVN. If one of the IBMers wants to make it
run on the Big Blue, they can do that, but I don't think that's
going to help you make it all nice and pretty. -- justin

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org
Received on Fri Apr 12 10:37:56 2002

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

This site is subject to the Apache Privacy Policy and the Apache Public Forum Archive Policy.