aboutsummaryrefslogtreecommitdiffstats
path: root/src/lib/rng/hmac_drbg
diff options
context:
space:
mode:
authorlloyd <[email protected]>2014-03-22 19:16:24 +0000
committerlloyd <[email protected]>2014-03-22 19:16:24 +0000
commit8ce4a125a6eaf012821852ce629ead2466a2fde8 (patch)
tree2902f436b55e22fecf31be72467f44477ed49f57 /src/lib/rng/hmac_drbg
parent6b043baa4f421e9d00272f3e0d93b7e40cac6b77 (diff)
Simpify HMAC_RNG reseeding process. Actually update HMAC_DRBG reseed counter.
Diffstat (limited to 'src/lib/rng/hmac_drbg')
-rw-r--r--src/lib/rng/hmac_drbg/hmac_drbg.cpp2
1 files changed, 2 insertions, 0 deletions
diff --git a/src/lib/rng/hmac_drbg/hmac_drbg.cpp b/src/lib/rng/hmac_drbg/hmac_drbg.cpp
index 96bd791ee..03b617af3 100644
--- a/src/lib/rng/hmac_drbg/hmac_drbg.cpp
+++ b/src/lib/rng/hmac_drbg/hmac_drbg.cpp
@@ -38,6 +38,8 @@ void HMAC_DRBG::randomize(byte out[], size_t length)
out += to_copy;
}
+ m_reseed_counter += length;
+
update(nullptr, 0); // additional_data is always empty
}