-
Notifications
You must be signed in to change notification settings - Fork 3
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
Support key import #59
Conversation
cfe0627
to
b0f4b2e
Compare
bc501be
to
2dd6af7
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Partially reviewed. Will complete the remaining soon.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nice PR! Still reviewing.
While trying to use
|
Btw, just wanted to mention this - I was testing this against
I didn't want to get into these, so just put the following for my testing:
This could be an env issue on my side but thought you may want to know. |
I don't have any TLS issues with that same endpoint, and key generation takes 30 seconds from my end. (It needs to generate 2 keys, produce 2 signatures, and several Sobject updates). |
Right. I see #60 also addresses this. |
Private Key Import
This PR adds support for importing and representing an arbitrary OpenPGP Transferable Secret Key (henceforth TSK) in Fortanix DSM. This PGP key can come from other implementations such as Sequoia (locally), the GnuPG keyring, OpenPGPjs, etc.
Because nothing is known about the input key, the corresponding structure of Sobjects has been enhanced to represent it in fair generality. More fields have been added as custom metadata (fingerprint of each subkeys, external creation timestamps, ECDH additional algorithms, etc). Consequently, this next release (0.3.0) is not backwards compatible with previous versions.
The input key is accepted for import under the following assumptions:
C
orCS
,Et
orEr
subkey,C
, then there is at least oneS
subkey, andTesting
... against GnuPG
The test script
generate_gpg_import_dsm.sh
generates a key in the local GnuPG keyring, exports it, imports the TSK to Fortanix DSM, checks signature and encryption roundtrips, exports it from DSM, and imports it back on the local keyring. Phew.... against known keys
The test script
knownkeys_import_dsm.sh
attempts to import known keys, some of which are "exotic" (taken from the OpenPGP interoperability test suite. It checks signature and encryption roundtrips.Fixes #5