-
Notifications
You must be signed in to change notification settings - Fork 869
Closed
Description
The canonical commit representation returned by EncodeWithoutSignature will strip out any extra field it doesn't support.
Jujutsu commits would add extra fields like:
tree eddf38b125ad5ed8fbd9438b33e0c41662f8739d
parent 7f92e7685ce2cac51a8348d38be665faf1af314d
parent 185bd1d7dbb2464cf744dc33c0993de1965685a6
author Arthur Gautier <...> 1753582512 +0000
committer Arthur Gautier <...> 1754670137 -0700
change-id xkmmqzonpyyrvxvtxsuutmmxrzyyvwon
gpgsig -----BEGIN PGP SIGNATURE-----
-----END PGP SIGNATURE-----
Foobar
(notice the change-id which is jujutsu specific).
The canonical representation (the one to be signed) should be:
tree eddf38b125ad5ed8fbd9438b33e0c41662f8739d
parent 7f92e7685ce2cac51a8348d38be665faf1af314d
parent 185bd1d7dbb2464cf744dc33c0993de1965685a6
author Arthur Gautier <...> 1753582512 +0000
committer Arthur Gautier <...> 1754670137 -0700
change-id xkmmqzonpyyrvxvtxsuutmmxrzyyvwon
Foobar
but instead we get:
tree eddf38b125ad5ed8fbd9438b33e0c41662f8739d
parent 7f92e7685ce2cac51a8348d38be665faf1af314d
parent 185bd1d7dbb2464cf744dc33c0993de1965685a6
author Arthur Gautier <...> 1753582512 +0000
committer Arthur Gautier <...> 1754670137 -0700
Foobar
Which in effects breaks signatures.
The implementation should instead just filter out the gpgsig field and leave out the other ones.
Metadata
Metadata
Assignees
Labels
No labels