aboutsummaryrefslogtreecommitdiffstats
path: root/src/lib/pubkey/dh
diff options
context:
space:
mode:
authorRenĂ© Korthaus <[email protected]>2015-12-23 11:52:19 +0100
committerJack Lloyd <[email protected]>2016-01-08 19:09:51 -0500
commitd22bc10cd4f67924acd82bcd46a31e3de3b20ce3 (patch)
tree58459585e6675cd799b6ef5900be026825cd6f9d /src/lib/pubkey/dh
parent2fbfdd7e5afb5e888fd8c0b56c6df09e2bdeaca7 (diff)
Mass-prefix member vars with m_
Diffstat (limited to 'src/lib/pubkey/dh')
-rw-r--r--src/lib/pubkey/dh/dh.cpp24
1 files changed, 12 insertions, 12 deletions
diff --git a/src/lib/pubkey/dh/dh.cpp b/src/lib/pubkey/dh/dh.cpp
index 3888166bb..9eb4e5cd0 100644
--- a/src/lib/pubkey/dh/dh.cpp
+++ b/src/lib/pubkey/dh/dh.cpp
@@ -18,8 +18,8 @@ namespace Botan {
*/
DH_PublicKey::DH_PublicKey(const DL_Group& grp, const BigInt& y1)
{
- group = grp;
- y = y1;
+ m_group = grp;
+ m_y = y1;
}
/*
@@ -27,7 +27,7 @@ DH_PublicKey::DH_PublicKey(const DL_Group& grp, const BigInt& y1)
*/
std::vector<byte> DH_PublicKey::public_value() const
{
- return unlock(BigInt::encode_1363(y, group_p().bytes()));
+ return unlock(BigInt::encode_1363(m_y, group_p().bytes()));
}
/*
@@ -37,19 +37,19 @@ DH_PrivateKey::DH_PrivateKey(RandomNumberGenerator& rng,
const DL_Group& grp,
const BigInt& x_arg)
{
- group = grp;
- x = x_arg;
+ m_group = grp;
+ m_x = x_arg;
- if(x == 0)
+ if(m_x == 0)
{
const BigInt& p = group_p();
- x.randomize(rng, dl_exponent_size(p.bits()));
+ m_x.randomize(rng, dl_exponent_size(p.bits()));
}
- if(y == 0)
- y = power_mod(group_g(), x, group_p());
+ if(m_y == 0)
+ m_y = power_mod(group_g(), m_x, group_p());
- if(x == 0)
+ if(m_x == 0)
gen_check(rng);
else
load_check(rng);
@@ -63,8 +63,8 @@ DH_PrivateKey::DH_PrivateKey(const AlgorithmIdentifier& alg_id,
RandomNumberGenerator& rng) :
DL_Scheme_PrivateKey(alg_id, key_bits, DL_Group::ANSI_X9_42)
{
- if(y == 0)
- y = power_mod(group_g(), x, group_p());
+ if(m_y == 0)
+ m_y = power_mod(group_g(), m_x, group_p());
load_check(rng);
}