libckteec: Add EDDSA attribute serialization#324
Merged
jforissier merged 1 commit intoOP-TEE:masterfrom Oct 6, 2022
Merged
Conversation
etienne-lms
reviewed
Sep 30, 2022
Contributor
etienne-lms
left a comment
There was a problem hiding this comment.
LGTM aside these few comments.
| CK_ULONG ulTagBits; | ||
| }; | ||
|
|
||
| /* EDDSA */ |
Contributor
There was a problem hiding this comment.
Suggestion: /* EdDSA (RFC 8032) */ as that's the reference we find in the litterature?
| #define CKK_DH 0x002 | ||
| #define CKK_ECDSA 0x003 | ||
| #define CKK_EC 0x003 | ||
| #define CKK_EC_EDWARDS 0x040 |
Contributor
There was a problem hiding this comment.
to move at the end (numerical order)
I propose you mention that this is from pkcs11 v3.1-cs01:
`#define CKK_EC_EDWARDS 0x040 /* from PKCS#11 v3.1-cs01 */
| #define CKM_ECDH1_COFACTOR_DERIVE 0x01051 | ||
| #define CKM_ECMQV_DERIVE 0x01052 | ||
| #define CKM_ECDH_AES_KEY_WRAP 0x01053 | ||
| #define CKM_EDDSA 0x01057 |
Contributor
There was a problem hiding this comment.
#define CKM_ECMQV_DERIVE 0x01052
#define CKM_ECDH_AES_KEY_WRAP 0x01053
#define CKM_RSA_AES_KEY_WRAP 0x01054
+#define CKM_EC_EDWARDS_KEY_PAIR_GEN 0x01055
+#define CKM_EDDSA 0x01057
#define CKM_AES_KEY_GEN 0x01080
#define CKM_AES_ECB 0x01081| PKCS11_CKM_ECDSA_SHA512 = 0x01046, | ||
| PKCS11_CKM_ECDH1_DERIVE = 0x01050, | ||
| PKCS11_CKM_ECDH1_COFACTOR_DERIVE = 0x01051, | ||
| PKCS11_CKM_EDDSA = 0x01057, |
aba80ff to
be84913
Compare
etienne-lms
reviewed
Oct 4, 2022
Contributor
etienne-lms
left a comment
There was a problem hiding this comment.
Reviewed-by: Etienne Carriere <etienne.carriere@linaro.org> with 2 minor comments addressed.
| #define CKM_ECDH_AES_KEY_WRAP 0x01053 | ||
| #define CKM_RSA_AES_KEY_WRAP 0x01054 | ||
| #define CKM_EC_EDWARDS_KEY_PAIR_GEN 0x01055 | ||
| #define CKM_EDDSA 0x01057 |
Contributor
There was a problem hiding this comment.
nitpicking: remove 1 or 2 tabulations
| PKCS11_CKM_ECMQV_DERIVE = 0x01052, | ||
| PKCS11_CKM_ECDH_AES_KEY_WRAP = 0x01053, | ||
| PKCS11_CKM_RSA_AES_KEY_WRAP = 0x01054, | ||
| PKCS11_CKM_EDDSA = 0x01057, |
The PKCS#11 Specification: https://docs.oasis-open.org/pkcs11/pkcs11-spec/v3.1/cs01/ pkcs11-spec-v3.1-cs01.pdf 6.3.16 EC mechanism parameters Signed-off-by: Valerii Chubar <valerii_chubar@epam.com> Reviewed-by: Etienne Carriere <etienne.carriere@linaro.org>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
The PKCS#11 Specification:
https://docs.oasis-open.org/pkcs11/pkcs11-spec/v3.1/cs01/pkcs11-spec-v3.1-cs01.pdf
The pull request should be merged with the following pull requests:
OP-TEE/optee_os#5559
OP-TEE/optee_test#618