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

Add signerverifiers for RSAPSS, ECDSA, ED25519 #43

Merged
merged 8 commits into from
May 2, 2023

Conversation

adityasaky
Copy link
Member

This creates DSSE friendly signerverifiers for the these key types, with some of the logic inspired by in-toto-golang's keylib. The idea is to move this in here and use it for Metablock and DSSE in in-toto-golang going forward.

Signed-off-by: Aditya Sirish <aditya@saky.in>
Signed-off-by: Aditya Sirish <aditya@saky.in>
@adityasaky adityasaky requested a review from mnm678 April 30, 2023 23:03
@coveralls
Copy link

coveralls commented Apr 30, 2023

Pull Request Test Coverage Report for Build 4853551288

  • 204 of 260 (78.46%) changed or added relevant lines in 4 files are covered.
  • No unchanged relevant lines lost coverage.
  • Overall coverage decreased (-6.9%) to 84.77%

Changes Missing Coverage Covered Lines Changed/Added Lines %
signerverifier/ed25519.go 37 45 82.22%
signerverifier/ecdsa.go 42 57 73.68%
signerverifier/utils.go 63 78 80.77%
signerverifier/rsa.go 62 80 77.5%
Totals Coverage Status
Change from base Build 4658330519: -6.9%
Covered Lines: 423
Relevant Lines: 499

💛 - Coveralls

Signed-off-by: Aditya Sirish <aditya@saky.in>
Signed-off-by: Aditya Sirish <aditya@saky.in>
Signed-off-by: Aditya Sirish <aditya@saky.in>
Signed-off-by: Aditya Sirish <aditya@saky.in>
@adityasaky
Copy link
Member Author

@pxp928

Copy link

@pxp928 pxp928 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

looks good so far. Some small comments

signerverifier/ecdsa.go Outdated Show resolved Hide resolved
signerverifier/ed25519.go Show resolved Hide resolved
signerverifier/rsa.go Show resolved Hide resolved
signerverifier/signerverifier.go Outdated Show resolved Hide resolved
signerverifier/test-data/ecdsa-test-key Outdated Show resolved Hide resolved
* Address review comments from @pxp928
* Add docstrings
* Add credits for code from in-toto-golang
* Check if KeyVal is missing when creating signerverifiers
* Make KeyID public and calculate key ID while loading only if it's
  missing

Signed-off-by: Aditya Sirish <aditya@saky.in>
@adityasaky adityasaky force-pushed the add-signers branch 3 times, most recently from 13d3e0d to 7c1bd7e Compare May 1, 2023 18:04
@adityasaky adityasaky marked this pull request as ready for review May 1, 2023 18:04
* Add tests verifying Metablock signatures
* Fix RSA key load with trailing newline

Signed-off-by: Aditya Sirish <aditya@saky.in>
Copy link

@pxp928 pxp928 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@adityasaky adityasaky mentioned this pull request May 2, 2023
@adityasaky adityasaky merged commit e6e1a9e into secure-systems-lab:main May 2, 2023
10 checks passed
@adityasaky adityasaky deleted the add-signers branch May 2, 2023 17:29
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 this pull request may close these issues.

None yet

3 participants