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 SM Cipher certificate test header: certs_test_sm.h #6825

Closed
wants to merge 2 commits into from

Conversation

gojimmypi
Copy link
Contributor

@gojimmypi gojimmypi commented Oct 2, 2023

Description

This update adds the certs_test_sm.h file: the SM Cipher specific certs in array format, partially addressing #6681.

Contents were semi-manually generated using gencertbuf.pl. I still need to create a script to automatically refresh it.

I'm in the process of polishing my Espressif examples that support the SM ciphers and need to have this file available not only here, but also in the ESP Registry. See also #6708

Fixes zd# n/a

Testing

Tested with ESP32 embedded apps only.

Checklist

  • added tests
  • updated/added doxygen
  • updated appropriate READMEs
  • Updated manual and documentation

@gojimmypi
Copy link
Contributor Author

retest this please

@JacobBarthelmeh
Copy link
Contributor

JacobBarthelmeh commented Oct 3, 2023

retest this please Jenkins

@JacobBarthelmeh
Copy link
Contributor

fails test for special characters found

[check-source-text] [2 of 7] [3980560f00]

weird control chars, hard tabs, CRs, trailing whitespace:

./wolfssl/certs_test_sm.h:7028:»0x43, 0x65, 0x72, 0x74, 0x69, 0x66, 0x69, 0x63, 0x61, 0x74,
./wolfssl/certs_test_sm.h:7029:»0x65, 0x3A, 0x0A, 0x20, 0x20, 0x20, 0x20, 0x44, 0x61, 0x74,
./wolfssl/certs_test_sm.h:7030:»0x61, 0x3A, 0x0A, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20,
./wolfssl/certs_test_sm.h:7031:»0x20, 0x56, 0x65, 0x72, 0x73, 0x69, 0x6F, 0x6E, 0x3A, 0x20,
./wolfssl/certs_test_sm.h:7032:»0x33, 0x20, 0x28, 0x30, 0x78, 0x32, 0x29, 0x0A, 0x20, 0x20,
./wolfssl/certs_test_sm.h:7033:»0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x53, 0x65, 0x72, 0x69,
./wolfssl/certs_test_sm.h:7034:»0x61, 0x6C, 0x20, 0x4E, 0x75, 0x6D, 0x62, 0x65, 0x72, 0x3A,
./wolfssl/certs_test_sm.h:7035:»0x0A, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20,
./wolfssl/certs_test_sm.h:7036:»0x20, 0x20, 0x20, 0x36, 0x30, 0x3A, 0x61, 0x30, 0x3A, 0x34,
./wolfssl/certs_test_sm.h:7037:»0x61, 0x3A, 0x30, 0x62, 0x3A, 0x33, 0x36, 0x3A, 0x65, 0x62,
[...and more...]

@gojimmypi
Copy link
Contributor Author

fails test for special characters found

cleaned

Copy link
Contributor

@JacobBarthelmeh JacobBarthelmeh left a comment

Choose a reason for hiding this comment

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

I like the addition of certs_test_sm.h but thinking on it more, should it go into the wolfsm repository and get added to wolfssl with the wolfsm/install.sh script?

@@ -0,0 +1,8400 @@
/* certs_test_sm.h */
/* This file was generated using: ./gencertbuf_sm.pl */
Copy link
Contributor

Choose a reason for hiding this comment

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

was gencertbuf_sm.pl supposed to be in this PR?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Yes, see #6681 although the correct name is gencert_sm.sh and needs to be cleaned up.

@gojimmypi
Copy link
Contributor Author

should it go into the wolfsm repository and get added to wolfssl with the wolfsm/install.sh script?

@JacobBarthelmeh : yes, good catch. I agree the certs should be copied with SM install instead.

I'll be creating a new PR over there in wolfsm this week.

@gojimmypi gojimmypi closed this Nov 12, 2023
@gojimmypi
Copy link
Contributor Author

@JacobBarthelmeh would you like me to also move the certs/sm2 files to wolfSSL/wolfsm as well & include in the respective install.sh?

cc: @SparkiDev

@gojimmypi
Copy link
Contributor Author

I'm planning to instead update existing certs_test.h here as noted in wolfSSL/wolfsm#16 (comment)

@gojimmypi gojimmypi self-assigned this Nov 22, 2023
@gojimmypi gojimmypi marked this pull request as draft November 22, 2023 20:09
@gojimmypi
Copy link
Contributor Author

I'm closing this lingering PR. I'd still like to do this at some point.

I've added this to my Mothball section in #6234

@gojimmypi gojimmypi closed this Jun 21, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants