summaryrefslogtreecommitdiff
path: root/randpool.h
diff options
context:
space:
mode:
authorJeffrey Walton <noloader@gmail.com>2017-08-02 19:43:56 -0400
committerJeffrey Walton <noloader@gmail.com>2017-08-02 19:43:56 -0400
commit76ff3fc03b64fc2f491fae2e918733c1a153d444 (patch)
tree2aec1d661d783154be4c2ca63ae3b3fa809de652 /randpool.h
parent4da4ece5a573196edcc76785e3a2fa0ed8d4b47e (diff)
downloadcryptopp-git-76ff3fc03b64fc2f491fae2e918733c1a153d444.tar.gz
Remove pre-Crypto++ 5.5 interface
Users of OldRandomPool must use the new interface. All that means is they must call IncorporateEntropy instead of Put, and GenerateBlock instead of Get
Diffstat (limited to 'randpool.h')
-rw-r--r--randpool.h20
1 files changed, 2 insertions, 18 deletions
diff --git a/randpool.h b/randpool.h
index 11029f58..20f356c7 100644
--- a/randpool.h
+++ b/randpool.h
@@ -72,8 +72,7 @@ private:
//! HKDF.
//! \sa RandomPool, AutoSeededRandomPool, HKDF, P1363_KDF2, PKCS12_PBKDF, PKCS5_PBKDF2_HMAC
//! \since Crypto++ 6.0 (PGP 2.6.x style)
-class CRYPTOPP_DLL OldRandomPool : public RandomNumberGenerator,
- public Bufferless<BufferedTransformation>
+class CRYPTOPP_DLL OldRandomPool : public RandomNumberGenerator
{
public:
//! \brief Construct an OldRandomPool
@@ -84,26 +83,11 @@ public:
// RandomNumberGenerator interface (Crypto++ 5.5 and above)
bool CanIncorporateEntropy() const {return true;}
void IncorporateEntropy(const byte *input, size_t length);
-
- // BufferedTransformation interface (Crypto++ 5.4 and below)
- size_t Put2(const byte *begin, size_t length, int messageEnd, bool blocking);
-
- bool AnyRetrievable() const {return true;}
- lword MaxRetrievable() const {return ULONG_MAX;}
-
- size_t TransferTo2(BufferedTransformation &target, lword &transferBytes, const std::string &channel=DEFAULT_CHANNEL, bool blocking=true);
- size_t CopyRangeTo2(BufferedTransformation &target, lword &begin, lword end=LWORD_MAX, const std::string &channel=DEFAULT_CHANNEL, bool blocking=true) const
- {
- CRYPTOPP_UNUSED(target); CRYPTOPP_UNUSED(begin); CRYPTOPP_UNUSED(end);
- CRYPTOPP_UNUSED(channel); CRYPTOPP_UNUSED(blocking);
- throw NotImplemented("OldRandomPool: CopyRangeTo2() is not supported by this store");
- }
+ void GenerateIntoBufferedTransformation(BufferedTransformation &target, const std::string &channel, lword size);
byte GenerateByte();
void GenerateBlock(byte *output, size_t size);
- void IsolatedInitialize(const NameValuePairs &parameters) {CRYPTOPP_UNUSED(parameters);}
-
protected:
void Stir();