Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Implement TAP-12 for future-proofing #232

Closed
1 of 4 tasks
znewman01 opened this issue Mar 4, 2022 · 1 comment · Fixed by #310
Closed
1 of 4 tasks

Implement TAP-12 for future-proofing #232

znewman01 opened this issue Mar 4, 2022 · 1 comment · Fixed by #310
Assignees

Comments

@znewman01
Copy link
Contributor

With the python-tuf implementation, I think that we can move TAP 12 to accepted pretty quickly. Unless there are strong objections to the TAP that will lead to major changes (which I haven't seen), I'd argue for future-proofing go-tuf by implementing TAP 12 now. It may make the implementation temporarily out of sync with the specification, but not in a major way, and not in a way that affects security (as described in more detail in the TAP).

Originally posted by @mnm678 in #228 (comment)

@mnm678: I think I agree with you, but I want to clarify what that would mean:

  • We can just keep producing keyIDs using SHA2, no change needed there
  • We need to double-check that we don't add multiple distinct keys with the same keyID (this is done, but we should allow adding multiple identical keys to prevent errors)
  • Make sure keys are managed locally to each metadata file, not globally (I think this is the case but need to double-check)
  • During signature verification, need to enforce the uniqueness of each key
@mnm678
Copy link
Collaborator

mnm678 commented Mar 7, 2022

This looks like a good checklist. We may eventually want to add a couple of sanity checks in case a user adds a keyid not using SHA2. Generally the delegating user is trusted to set the mappings, but it'd be nice to have some kind of warning if they accidentally add the same key with a different keyid.

@znewman01 znewman01 self-assigned this Jun 8, 2022
znewman01 added a commit to znewman01/go-tuf that referenced this issue Jun 8, 2022
Main changes:

- allow IDs that aren't the SHA2 of the public key
- but disallow multiple distinct keys with the same ID
- test for TAP-12 compliance
  - Adding keys should disallow different keys with the same ID, but allow everything else
  - Verification should ensure that we have unique keys for each signature

Fixes theupdateframework#232.
znewman01 added a commit to znewman01/go-tuf that referenced this issue Jun 9, 2022
Main changes:

- allow IDs that aren't the SHA2 of the public key
- but disallow multiple distinct keys with the same ID
- test for TAP-12 compliance
  - Adding keys should disallow different keys with the same ID, but allow everything else
  - Verification should ensure that we have unique keys for each signature

Fixes theupdateframework#232.
znewman01 added a commit to znewman01/go-tuf that referenced this issue Jun 13, 2022
Main changes:

- allow IDs that aren't the SHA2 of the public key
- but disallow multiple distinct keys with the same ID
- test for TAP-12 compliance
  - Adding keys should disallow different keys with the same ID, but allow everything else
  - Verification should ensure that we have unique keys for each signature

Fixes theupdateframework#232.
znewman01 added a commit to znewman01/go-tuf that referenced this issue Jun 13, 2022
Main changes:

- allow IDs that aren't the SHA2 of the public key
- but disallow multiple distinct keys with the same ID
- test for TAP-12 compliance
  - Adding keys should disallow different keys with the same ID, but allow everything else
  - Verification should ensure that we have unique keys for each signature

Fixes theupdateframework#232.

Signed-off-by: Zachary Newman <z@znewman.net>
mnm678 pushed a commit that referenced this issue Jun 13, 2022
* docs: Add DCO instructions

Signed-off-by: Zachary Newman <z@znewman.net>

* feat: implement TAP-12 support

Main changes:

- allow IDs that aren't the SHA2 of the public key
- but disallow multiple distinct keys with the same ID
- test for TAP-12 compliance
  - Adding keys should disallow different keys with the same ID, but allow everything else
  - Verification should ensure that we have unique keys for each signature

Fixes #232.

Signed-off-by: Zachary Newman <z@znewman.net>

* feat: add Key ID to ErrRepeatID

Signed-off-by: Zachary Newman <z@znewman.net>

* test: add test for keyIDs case for delegations DB

Signed-off-by: Zachary Newman <z@znewman.net>

* test: clarify DB tests for TAP-12

Signed-off-by: Zachary Newman <z@znewman.net>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants