diff options
author | Peiwei Hu <jlu.hpw@foxmail.com> | 2021-11-15 00:27:31 +0800 |
---|---|---|
committer | Tomas Mraz <tomas@openssl.org> | 2021-11-22 15:22:03 +0100 |
commit | fd6a1e21f906883d0cc7ebef7826cf2f55f87832 (patch) | |
tree | 5482a22f0dfdebd3f140b834792a2ab83df36de9 /apps/s_server.c | |
parent | bcb8c7eeae5b81316104799f401f8c2e6f5156cd (diff) |
SSL_export_keying_material: fix return check
Reviewed-by: Paul Dale <pauli@openssl.org>
Reviewed-by: Tomas Mraz <tomas@openssl.org>
(Merged from https://github.com/openssl/openssl/pull/17028)
(cherry picked from commit 40649e36c4c0c9438f62e1bf2ccb983f6854c662)
Diffstat (limited to 'apps/s_server.c')
-rw-r--r-- | apps/s_server.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/apps/s_server.c b/apps/s_server.c index 0e71c161ef..d95bf14cbf 100644 --- a/apps/s_server.c +++ b/apps/s_server.c @@ -2940,11 +2940,11 @@ static void print_connection_info(SSL *con) BIO_printf(bio_s_out, " Label: '%s'\n", keymatexportlabel); BIO_printf(bio_s_out, " Length: %i bytes\n", keymatexportlen); exportedkeymat = app_malloc(keymatexportlen, "export key"); - if (!SSL_export_keying_material(con, exportedkeymat, + if (SSL_export_keying_material(con, exportedkeymat, keymatexportlen, keymatexportlabel, strlen(keymatexportlabel), - NULL, 0, 0)) { + NULL, 0, 0) <= 0) { BIO_printf(bio_s_out, " Error\n"); } else { BIO_printf(bio_s_out, " Keying material: "); |