diff options
Diffstat (limited to 'src')
-rw-r--r-- | src/lib/pubkey/dl_algo/dl_algo.h | 4 | ||||
-rw-r--r-- | src/lib/pubkey/ecc_key/ecc_key.h | 4 | ||||
-rw-r--r-- | src/lib/pubkey/pk_keys.h | 8 |
3 files changed, 15 insertions, 1 deletions
diff --git a/src/lib/pubkey/dl_algo/dl_algo.h b/src/lib/pubkey/dl_algo/dl_algo.h index 044aae2e6..4c0d56931 100644 --- a/src/lib/pubkey/dl_algo/dl_algo.h +++ b/src/lib/pubkey/dl_algo/dl_algo.h @@ -73,6 +73,8 @@ class BOTAN_DLL DL_Scheme_PublicKey : public virtual Public_Key const std::vector<uint8_t>& key_bits, DL_Group::Format group_format); + DL_Scheme_PublicKey& operator=(const DL_Scheme_PublicKey& other) = default; + protected: DL_Scheme_PublicKey() {} @@ -114,6 +116,8 @@ class BOTAN_DLL DL_Scheme_PrivateKey : public virtual DL_Scheme_PublicKey, const secure_vector<uint8_t>& key_bits, DL_Group::Format group_format); + DL_Scheme_PrivateKey& operator=(const DL_Scheme_PrivateKey& other) = default; + protected: DL_Scheme_PrivateKey() {} diff --git a/src/lib/pubkey/ecc_key/ecc_key.h b/src/lib/pubkey/ecc_key/ecc_key.h index 60e29bffc..186182ba0 100644 --- a/src/lib/pubkey/ecc_key/ecc_key.h +++ b/src/lib/pubkey/ecc_key/ecc_key.h @@ -45,6 +45,8 @@ class BOTAN_DLL EC_PublicKey : public virtual Public_Key EC_PublicKey(const AlgorithmIdentifier& alg_id, const std::vector<uint8_t>& key_bits); + EC_PublicKey& operator=(const EC_PublicKey& other) = default; + /** * Get the public point of this key. * @throw Invalid_State is thrown if the @@ -133,6 +135,8 @@ class BOTAN_DLL EC_PrivateKey : public virtual EC_PublicKey, const secure_vector<uint8_t>& key_bits, bool with_modular_inverse=false); + EC_PrivateKey& operator=(const EC_PrivateKey& other) = default; + secure_vector<uint8_t> private_key_bits() const override; /** diff --git a/src/lib/pubkey/pk_keys.h b/src/lib/pubkey/pk_keys.h index 1e7bd3216..833dda69e 100644 --- a/src/lib/pubkey/pk_keys.h +++ b/src/lib/pubkey/pk_keys.h @@ -24,7 +24,9 @@ class RandomNumberGenerator; class BOTAN_DLL Public_Key { public: - virtual ~Public_Key() {} + virtual ~Public_Key() = default; + + virtual Public_Key& operator=(const Public_Key& other) = default; /** * Get the name of the underlying public key scheme. @@ -163,6 +165,10 @@ class BOTAN_DLL Public_Key class BOTAN_DLL Private_Key : public virtual Public_Key { public: + virtual ~Private_Key() = default; + + virtual Private_Key& operator=(const Private_Key& other) = default; + /** * @return BER encoded private key bits */ |