From e6ad7a027f577d08ce8a43eff2864d74dd03f094 Mon Sep 17 00:00:00 2001 From: Adam Langley Date: Mon, 3 Dec 2018 14:37:44 -0800 Subject: [PATCH] Drop some explicit SSLKeyShare destructors. We zero out memory in |OPENSSL_free| already. Change-Id: I84a0f3cdfadd4544c0fade1d3d727baa6496ffe5 Reviewed-on: https://boringssl-review.googlesource.com/c/33446 Commit-Queue: Adam Langley Commit-Queue: David Benjamin Reviewed-by: David Benjamin --- ssl/ssl_key_share.cc | 4 ---- 1 file changed, 4 deletions(-) diff --git a/ssl/ssl_key_share.cc b/ssl/ssl_key_share.cc index 80b7d0a0..55c74633 100644 --- a/ssl/ssl_key_share.cc +++ b/ssl/ssl_key_share.cc @@ -38,7 +38,6 @@ namespace { class ECKeyShare : public SSLKeyShare { public: ECKeyShare(int nid, uint16_t group_id) : nid_(nid), group_id_(group_id) {} - ~ECKeyShare() override {} uint16_t GroupID() const override { return group_id_; } @@ -159,9 +158,6 @@ class ECKeyShare : public SSLKeyShare { class X25519KeyShare : public SSLKeyShare { public: X25519KeyShare() {} - ~X25519KeyShare() override { - OPENSSL_cleanse(private_key_, sizeof(private_key_)); - } uint16_t GroupID() const override { return SSL_CURVE_X25519; }