]> git.ipfire.org Git - thirdparty/openvpn.git/commit
Refactor key_state_export_keying_material functions
authorArne Schwabe <arne@rfc2549.org>
Fri, 14 Aug 2020 14:51:53 +0000 (16:51 +0200)
committerGert Doering <gert@greenie.muc.de>
Sun, 23 Aug 2020 19:49:21 +0000 (21:49 +0200)
commit10abd656a3ae279cea7344055ce23637b7a62f6b
tree1df36a144356b969012d9b2a49d347ab82ef4270
parent62560e2a29144ffefec231ae7147eb4e9c7dfebf
Refactor key_state_export_keying_material functions

This refactors the common code between mbed SSL and OpenSSL into
export_user_keying_material and also prepares the backend functions
to export more than one key.

Also fix checking the return value of SSL_export_keying_material
only 1 is a success, -1 is also an error.

Signed-off-by: Arne Schwabe <arne@rfc2549.org>
Patch V2: Cache secrets for mbed TLS instead generating all ekms
          in the call back function

Patch V3: comment is no longer a lie. (fixed doxygen)

Signed-off-by: Arne Schwabe <arne@rfc2549.org>
Acked-by: Steffan Karger <steffan@karger.me>
Message-Id: <20200814145153.12895-1-arne@rfc2549.org>
URL: https://www.mail-archive.com/openvpn-devel@lists.sourceforge.net/msg20739.html
Signed-off-by: Gert Doering <gert@greenie.muc.de>
src/openvpn/ssl.c
src/openvpn/ssl_backend.h
src/openvpn/ssl_mbedtls.c
src/openvpn/ssl_mbedtls.h
src/openvpn/ssl_openssl.c