aboutsummaryrefslogtreecommitdiffstats
path: root/src/lib/pubkey/rfc6979/rfc6979.cpp
diff options
context:
space:
mode:
authorSimon Warta <[email protected]>2015-06-23 20:07:15 +0200
committerSimon Warta <[email protected]>2015-06-23 20:07:15 +0200
commitfd1c77c5cf8d86c6ba6d2f5c8cf898502c463eba (patch)
tree6ac5df8e74d2ad203f03da28aba46e2a4bfdbea5 /src/lib/pubkey/rfc6979/rfc6979.cpp
parent2a83523815461a4aa461ce5cc3b1288727440705 (diff)
lib/pubkey: Convert &vec[0] to vec.data()
Diffstat (limited to 'src/lib/pubkey/rfc6979/rfc6979.cpp')
-rw-r--r--src/lib/pubkey/rfc6979/rfc6979.cpp8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/lib/pubkey/rfc6979/rfc6979.cpp b/src/lib/pubkey/rfc6979/rfc6979.cpp
index 58cdbaa1b..5f606891d 100644
--- a/src/lib/pubkey/rfc6979/rfc6979.cpp
+++ b/src/lib/pubkey/rfc6979/rfc6979.cpp
@@ -35,19 +35,19 @@ RFC6979_Nonce_Generator::RFC6979_Nonce_Generator(const std::string& hash,
m_rng_in(m_rlen * 2),
m_rng_out(m_rlen)
{
- BigInt::encode_1363(&m_rng_in[0], m_rlen, x);
+ BigInt::encode_1363(m_rng_in.data(), m_rlen, x);
}
const BigInt& RFC6979_Nonce_Generator::nonce_for(const BigInt& m)
{
BigInt::encode_1363(&m_rng_in[m_rlen], m_rlen, m);
m_hmac_drbg->clear();
- m_hmac_drbg->add_entropy(&m_rng_in[0], m_rng_in.size());
+ m_hmac_drbg->add_entropy(m_rng_in.data(), m_rng_in.size());
do
{
- m_hmac_drbg->randomize(&m_rng_out[0], m_rng_out.size());
- m_k.binary_decode(&m_rng_out[0], m_rng_out.size());
+ m_hmac_drbg->randomize(m_rng_out.data(), m_rng_out.size());
+ m_k.binary_decode(m_rng_out.data(), m_rng_out.size());
m_k >>= (8*m_rlen - m_qlen);
}
while(m_k == 0 || m_k >= m_order);