When format 5 isn't format 5
John Arbash Meinel
john at arbash-meinel.com
Tue May 16 15:40:02 BST 2006
Aaron Bentley wrote:
> Hi all,
>
> In updating changeset code, I've discovered that our inventory format
> has changed, without changing its version number.
>
> Specifically, new format 5 inventories contain a revision ID, and older
> ones do not. It looks like this change was introduced by Robert's patch
> to get rid of the trailing revision-id in basis-inventory filenames. I
> presume that it was intended that only basis inventories would include
> revision-ids, but it's also been applied inventories in the inventory weave.
>
> Revision testaments contain the inventory hash, which I believe is just
> the inventory XML SHA1 hash. This means that fixing existing
> repositories would break signatures.
>
> Among other things, this strongly suggests that our unit tests should
> include a test to make sure we get a reproduceable testament when we
> commit a revision with fixed values.
>
> Aaron
I was pretty sure that revision testaments do *not* contain the hash of
the xml. They should custom generate an RIO format of the inventory, and
hash that.
Our Revision XML does contain a bogus hash of the inventory XML. Bogus
because it is never checked, and is semi-inconsistent.
Which is why we wanted to change the inventory_sha1= into testament_sha1
or something more useful like that.
John
=:->
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 254 bytes
Desc: OpenPGP digital signature
Url : https://lists.ubuntu.com/archives/bazaar/attachments/20060516/4f0c8277/attachment.pgp
More information about the bazaar
mailing list