Skip to content

feat(api)!: Make SignKM accept generic crypto.Signer - #392

Closed
werwurm wants to merge 2 commits into
9elements:mainfrom
werwurm:generic_crypto_signer
Closed

feat(api)!: Make SignKM accept generic crypto.Signer#392
werwurm wants to merge 2 commits into
9elements:mainfrom
werwurm:generic_crypto_signer

Conversation

@werwurm

@werwurm werwurm commented Sep 6, 2024

Copy link
Copy Markdown
Contributor

Accepting crypto.PrivateKey uneccessarily restricts this library to software crypto algorithms provided by the golang crypto packages. By allowing the more generic crypto.Signer interface alternative implementations, e.g., backed by HSMs, can be supported.

@werwurm

werwurm commented Sep 6, 2024

Copy link
Copy Markdown
Contributor Author

I realize that this changes the API. It could be hidden by adding new API, e.g., SignKMGeneric. Let me know what you think.

Also, to really make use of this change, the fiano back end needs to be changed. Which I have proposed here [1] [2]

[1] linuxboot/fiano#421
[2] linuxboot/fiano#420

@walterchris walterchris left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

I think changing the API here is fine.

@walterchris

Copy link
Copy Markdown
Collaborator

Could you satisfy the linter? :)

@werwurm werwurm changed the title Make SignKM accept generic crypto.Signer feat(api!: Make SignKM accept generic crypto.Signer Sep 9, 2024
@werwurm werwurm changed the title feat(api!: Make SignKM accept generic crypto.Signer feat(api)!: Make SignKM accept generic crypto.Signer Sep 9, 2024
Accepting crypto.PrivateKey uneccessarily restricts this library to
software crypto algorithms provided by the golang crypto packages. By
allowing the more generic crypto.Signer interface alternative
implementations, e.g., backed by HSMs, can be supported.

Signed-off-by: Janis Danisevskis <jdanisevskis@aurora.tech>
@werwurm
werwurm force-pushed the generic_crypto_signer branch from 318545e to 6702af9 Compare September 9, 2024 16:11
@werwurm

werwurm commented Sep 9, 2024

Copy link
Copy Markdown
Contributor Author

Could you satisfy the linter? :)

Sure thing. I hope this fixes it. commitlint is new to me. So bare with me, please.
Is the final commit message constructed from the pull request or from the commit on the feature branch?

@walterchris

Copy link
Copy Markdown
Collaborator

We will rebase and cherry pick the commits - so no squash here :)

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.

2 participants