-
Notifications
You must be signed in to change notification settings - Fork 2.1k
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
CSR support in crypto HSM #7897
CSR support in crypto HSM #7897
Conversation
# Conflicts: # src/crypto/hsm/nxp/CHIPCryptoPALHsm_SE05X_Spake2p.cpp
…kulkarni-nxp/connectedhomeip into feature/CSR-support-in-crypto-hsm
memcpy((void *) &data_to_hash[buffer_index], pubkey, pubKeyLen); | ||
|
||
// Copy subject (in the current implementation only organisation name info is added) and organisation OID | ||
buffer_index = buffer_index - (1 + 1 + sizeof(SUBJECT_STR) - 1); |
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.
I don't really like how the buffer_index is decrease/calculated through out this function. It seems error prone.
The use of constants could help make this clearer
buffer_index -= kTlvHeader
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.
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.
Sure. Updated the code by using kTlvHeader,
Also before accessing the buffer using buffer index, check is added as,
"VerifyOrExit(buffer_index > 0, error = CHIP_ERROR_INTERNAL);"
de80490
to
c443e32
Compare
Size increase report for "esp32-example-build" from edd134c
Full report output
|
06e89fd
to
cedbf09
Compare
@sujaygkulkarni-nxp is |
* Added CSR support in HSM * updated keyid * added support for linux in simw build file * build fix * Added logs * build fix * Using HSM for ops key * Using HSM for OPS key * Using HSM for ops key * added logs * logs * restyled * updated readme * updated readme * restyled * using kTlvHeader for buffer index update * updating buffer index using kTlvHeader * restyled * Trigger Build * Trigger Build * Trigger Build Co-authored-by: Jagadish B E <[email protected]> Co-authored-by: Jagadish-NXP <[email protected]>
* Added CSR support in HSM * updated keyid * added support for linux in simw build file * build fix * Added logs * build fix * Using HSM for ops key * Using HSM for OPS key * Using HSM for ops key * added logs * logs * restyled * updated readme * updated readme * restyled * using kTlvHeader for buffer index update * updating buffer index using kTlvHeader * restyled * Trigger Build * Trigger Build * Trigger Build Co-authored-by: Jagadish B E <[email protected]> Co-authored-by: Jagadish-NXP <[email protected]>
* Added CSR support in HSM * updated keyid * added support for linux in simw build file * build fix * Added logs * build fix * Using HSM for ops key * Using HSM for OPS key * Using HSM for ops key * added logs * logs * restyled * updated readme * updated readme * restyled * using kTlvHeader for buffer index update * updating buffer index using kTlvHeader * restyled * Trigger Build * Trigger Build * Trigger Build Co-authored-by: Jagadish B E <[email protected]> Co-authored-by: Jagadish-NXP <[email protected]>
Problem
No CSR support in HSM layer
No HSM support for CASE protocol
Change overview
Testing