From 242d67fb17619670d9b757c442dcf2e26d8478a1 Mon Sep 17 00:00:00 2001 From: weidai Date: Thu, 20 Jan 2005 04:19:35 +0000 Subject: changes done for FIPS-140 lab code drop git-svn-id: svn://svn.code.sf.net/p/cryptopp/code/trunk/c5@195 57ff6487-cd31-0410-9ec3-f628ee90f5f0 --- filters.h | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) (limited to 'filters.h') diff --git a/filters.h b/filters.h index 1827c90..ad19b3e 100644 --- a/filters.h +++ b/filters.h @@ -214,7 +214,8 @@ private: class CRYPTOPP_DLL FilterWithInputQueue : public Filter { public: - FilterWithInputQueue(BufferedTransformation *attachment) : Filter(attachment) {} + FilterWithInputQueue(BufferedTransformation *attachment=NULL) : Filter(attachment) {} + unsigned int Put2(const byte *inString, unsigned int length, int messageEnd, bool blocking) { if (!blocking) @@ -267,8 +268,8 @@ typedef StreamTransformationFilter StreamCipherFilter; class CRYPTOPP_DLL HashFilter : public Bufferless, private FilterPutSpaceHelper { public: - HashFilter(HashTransformation &hm, BufferedTransformation *attachment = NULL, bool putMessage=false) - : m_hashModule(hm), m_putMessage(putMessage) {Detach(attachment);} + HashFilter(HashTransformation &hm, BufferedTransformation *attachment = NULL, bool putMessage=false, int truncatedDigestSize=-1) + : m_hashModule(hm), m_putMessage(putMessage), m_truncatedDigestSize(truncatedDigestSize) {Detach(attachment);} void IsolatedInitialize(const NameValuePairs ¶meters); unsigned int Put2(const byte *begin, unsigned int length, int messageEnd, bool blocking); @@ -278,7 +279,9 @@ public: private: HashTransformation &m_hashModule; bool m_putMessage; + int m_truncatedDigestSize; byte *m_space; + unsigned int m_digestSize; }; //! Filter Wrapper for HashTransformation -- cgit v1.2.1