1
0
mirror of synced 2026-10-24 12:59:22 +03:00
Files
cosign/pkg
Hayden B 2a34b4ca94 Fix idempotency error with signing (#3371)
The expected behavior is to fetch an existing entry from the log when
signing generates the same signature, so that signing is idempotent.

The bug was that the prepended shard ID was compared to the log ID. The
log ID is a sha256 hash of the log's public key, which is not the same
as the shard ID. Now we compare the prepended shard IDs from both the
request and response entry UUID when present.

This was not caught in tests since we used a valid shard ID as input
rather than the log ID.

Verified by generating an RSA key (which will generate the same
signature given the same input) and signing a container.

Signed-off-by: Hayden Blauzvern <hblauzvern@google.com>
2023-11-17 20:01:26 -08:00
..
2023-02-06 11:26:09 +01:00
2022-11-25 08:12:52 +01:00