-
Notifications
You must be signed in to change notification settings - Fork 2.6k
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
Saving the serialized context to a file #3194
Conversation
programs/ssl/ssl_client2.c
Outdated
@@ -516,6 +523,9 @@ struct options | |||
* during renegotiation */ | |||
const char *cid_val; /* the CID to use for incoming messages */ | |||
int serialize; /* serialize/deserialize connection */ | |||
const char *serial_to_file; /* the file to write a serialized connection | |||
* in the form of base64 code ( serialize |
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.
Style: don't need spaces after (
in comments.
programs/ssl/ssl_client2.c
Outdated
" serialize=%%d default: 0 (do not serialize/deserialize)\n" \ | ||
" options: 1 (serialize)\n" \ | ||
" 2 (serialize with re-initialization)\n" \ | ||
" serial_to_file=%%s The file path to write a serialized connection\n"\ |
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.
Could we rename this to "context_file"? "Serial to file" doesn't make very much sense in English.
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.
Yes, I know. I wanted to use an abbreviation instead of a full word like for example 'renego' instead of 'renegotiation' :). I changed to 'context_file'
Signed-off-by: Piotr Nowicki <[email protected]>
20b35ed
to
8ea0f48
Compare
Added missing mbedtls_free to fix CI failure |
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.
LGTM, other than cleanup() function.
Signed-off-by: Piotr Nowicki <[email protected]>
8ea0f48
to
3de298f
Compare
CI passing, other than Mbed OS known issue which is being addressed separately. Good to go. |
Signed-off-by: Piotr Nowicki [email protected]
Description
This PR adds in the ssl_server2 and ssl_client2 programs the ability to save a serialized context to a file as base64 code.
Status
READY
Requires Backporting
NO