aboutsummaryrefslogtreecommitdiffstats
path: root/src/lib/pubkey/ecdh
diff options
context:
space:
mode:
authorJack Lloyd <[email protected]>2015-07-31 11:09:24 -0400
committerJack Lloyd <[email protected]>2015-07-31 11:09:24 -0400
commit8e19ecf11c2c50b5a2d6642477d729091409fec8 (patch)
treed87cff14d376f69f1a7ea0d9e1679385e195623a /src/lib/pubkey/ecdh
parent4944797ede915a606c6d5bd0e5b0a0b8f21b8eca (diff)
parentc37ebd2d0bb9ad6d2cf6d4541a1de523b584b36e (diff)
Merge pull request #231 from tiwoc/add-override
Add override specifiers
Diffstat (limited to 'src/lib/pubkey/ecdh')
-rw-r--r--src/lib/pubkey/ecdh/ecdh.cpp2
-rw-r--r--src/lib/pubkey/ecdh/ecdh.h7
2 files changed, 5 insertions, 4 deletions
diff --git a/src/lib/pubkey/ecdh/ecdh.cpp b/src/lib/pubkey/ecdh/ecdh.cpp
index 61d3af816..bad0f2c0b 100644
--- a/src/lib/pubkey/ecdh/ecdh.cpp
+++ b/src/lib/pubkey/ecdh/ecdh.cpp
@@ -30,7 +30,7 @@ class ECDH_KA_Operation : public PK_Ops::Key_Agreement_with_KDF
l_times_priv = inverse_mod(cofactor, key.domain().get_order()) * key.private_value();
}
- secure_vector<byte> raw_agree(const byte w[], size_t w_len)
+ secure_vector<byte> raw_agree(const byte w[], size_t w_len) override
{
PointGFp point = OS2ECP(w, w_len, curve);
PointGFp S = (cofactor * point) * l_times_priv;
diff --git a/src/lib/pubkey/ecdh/ecdh.h b/src/lib/pubkey/ecdh/ecdh.h
index 1e806f119..ef3e8ef7a 100644
--- a/src/lib/pubkey/ecdh/ecdh.h
+++ b/src/lib/pubkey/ecdh/ecdh.h
@@ -38,7 +38,7 @@ class BOTAN_DLL ECDH_PublicKey : public virtual EC_PublicKey
* Get this keys algorithm name.
* @return this keys algorithm name
*/
- std::string algo_name() const { return "ECDH"; }
+ std::string algo_name() const override { return "ECDH"; }
/**
* Get the maximum number of bits allowed to be fed to this key.
@@ -46,7 +46,8 @@ class BOTAN_DLL ECDH_PublicKey : public virtual EC_PublicKey
* @return maximum number of input bits
*/
- size_t max_input_bits() const { return domain().get_order().bits(); }
+ size_t max_input_bits() const override
+ { return domain().get_order().bits(); }
/**
* @return public point value
@@ -82,7 +83,7 @@ class BOTAN_DLL ECDH_PrivateKey : public ECDH_PublicKey,
const BigInt& x = 0) :
EC_PrivateKey(rng, domain, x) {}
- std::vector<byte> public_value() const
+ std::vector<byte> public_value() const override
{ return ECDH_PublicKey::public_value(); }
};