IBR-DTNSuite
0.8
|
#include <HashStream.h>
Public Member Functions | |
HashStream (const size_t hash, const size_t buffer=2048) | |
virtual | ~HashStream () |
Static Public Member Functions | |
static std::string | extract (std::istream &stream) |
Protected Member Functions | |
virtual void | update (char *buf, const size_t size)=0 |
virtual void | finalize (char *hash, unsigned int &size)=0 |
virtual int | sync () |
virtual std::char_traits< char > ::int_type | overflow (std::char_traits< char >::int_type=std::char_traits< char >::eof()) |
virtual std::char_traits< char > ::int_type | underflow () |
Definition at line 17 of file HashStream.h.
ibrcommon::HashStream::HashStream | ( | const size_t | hash, |
const size_t | buffer = 2048 |
||
) |
Definition at line 13 of file HashStream.cpp.
ibrcommon::HashStream::~HashStream | ( | ) | [virtual] |
Definition at line 21 of file HashStream.cpp.
std::string ibrcommon::HashStream::extract | ( | std::istream & | stream | ) | [static] |
Definition at line 27 of file HashStream.cpp.
Referenced by dtn::security::BundleAuthenticationBlock::calcMAC().
virtual void ibrcommon::HashStream::finalize | ( | char * | hash, |
unsigned int & | size | ||
) | [protected, pure virtual] |
Implemented in ibrcommon::HMacStream.
Referenced by underflow().
std::char_traits< char >::int_type ibrcommon::HashStream::overflow | ( | std::char_traits< char >::int_type | c = std::char_traits<char>::eof() | ) | [protected, virtual] |
Definition at line 43 of file HashStream.cpp.
References update().
Referenced by sync().
int ibrcommon::HashStream::sync | ( | ) | [protected, virtual] |
Definition at line 34 of file HashStream.cpp.
References overflow().
std::char_traits< char >::int_type ibrcommon::HashStream::underflow | ( | ) | [protected, virtual] |
Definition at line 68 of file HashStream.cpp.
References finalize().
virtual void ibrcommon::HashStream::update | ( | char * | buf, |
const size_t | size | ||
) | [protected, pure virtual] |
Implemented in ibrcommon::HMacStream.
Referenced by overflow().