"Bert Huijben" <b...@vmoo.com> writes:

> In the old entries format we only kept one checksum, while we can have two
> pristine files, so just keeping it as MD5 can't solve all the issues.

That's NODE_DATA, nothing to do with single-db.

> But we can't just assume that we never see a collision with MD5 over an
> entire tree.. or we wouldn't have switched to SHA1 in the first place.
>
> Maybe we should use a somewhat broader structure then just a single (or
> dual) svn_wc_entry_t to keep the state while upgrading. This can then
> contain things like the SHA1 checksums and other values that can't be stored
> in just the entries.
>
> Just looking up a node by its MD5 in the pristines table will not resolve
> the collision problems :(

Single-db does make MD5 collisions more likely, but is it a real
problem? I know it's possible to create MD5 collisions in certain
circumstances, but are there any reports of accidental collisions
rather than deliberately created ones?

If we create the temporary MD5 index during the upgrade then we can
probably spot the collision and abort.  I think that would be good
enough.

-- 
Philip

Reply via email to