[ale] OT: MD5 checksums & math

Danny Cox danny at compgen.com
Tue Jul 18 07:29:05 EDT 2000


All,

On Mon, 17 Jul 2000, Robert Butera wrote:
> On Mon, 17 Jul 2000, Randy Janinda wrote:
> 
> > Not for the meek hearted:
> > 
> > Let me try to explain this request. 
> > 
> > I have four images. I know the md5sum of three of them and I want to
> > predict the md5sum of the fourth. 
> > 
> > Here's the facts:
> > 
> > ImageA is the same as ImageB except on minor addition to ImageB (we'll
> > call this addition X).
> > 
> > md5sums:
> > 
> > ImageA = c76ada9f51c10ee6ccbc9bccd2e05358
> > ImageB = 53485d8e8171766b533d13d2df0ffa97 (ImageA + X)
> > ImageC = b64a84171c956e14aab561b1545cbc70
> > 
> > Now assuming ImageD has the same exact addition as ImageB (the X
> > factor) can I predict the md5sum by adding that "X" factor to ImageC?
> > 
> > ImageD = ImageC + X
> 
> Definitely not for the weak!
> 
> Looking at the MD5sum algorithm at
> 
> ftp://ftp.isi.edu/in-notes/rfc1321.txt 
> 
> I would "guess" that the answer is no. It is nowhere near as straigtforward
> as a checksum algorithm.

	Just FYI, rsync uses two algorithms to determine if file
"blocks" are the same or not.  The first is a hash that like a checksum,
you can "subtract" say char 0, and "add" char N+1 thereby effectivly
"moving" the signature one byte ahead, without rescanning the whole
block.  BUT, if there is a match, an MD4 checksum is also used to ensure
there are no false positives.  I imagine that if Andrew could have done
the same with MD4 (or MD5), he wouldn't have bothered with the
additional hash function.

	If the preceeding paragraph isn't lucid, it's because I'm not
awake yet, so please forgive me.

Danny

--
To unsubscribe: mail majordomo at ale.org with "unsubscribe ale" in message body.





More information about the Ale mailing list