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

Re: SHA-1 collision in repository?

From: Stefan Sperling <stsp_at_elego.de>
Date: Sun, 4 Mar 2018 11:28:05 +0100

On Sat, Mar 03, 2018 at 09:08:41PM -0500, Nathan Hartman wrote:
> On Mar 2, 2018, at 6:16 PM, Philip Martin <philip_at_codematters.co.uk> wrote:
> >
> > Since the file being committed matched a SHA1 in the rep-cache the
> > commit process will attempt to remove this delta but will first verify
> > that the fulltext obtained by expanding the delta in the protorev file
> > matches the fulltext in the repository, see get_shared_rep() in
> > subversion/libsvn_fs_fs/transaction.c.
> >
> Does this mean that content being committed to the repository is never elided
> based on the SHA hash alone but only after a fulltext verification that the
> content actually already exists in the repository?

Yes. And if the content differs, it must be rejected, because an FSFS
repository can only store one content per SHA1 checksum.
Received on 2018-03-04 11:28:36 CET

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

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