A++ » INCLUDE » TMD5

class TMD5


TMD5

This code implements the MD5 message-digest algorithm.
The algorithm is due to Ron Rivest. This code was
written by Colin Plumb in 1993, no copyright is claimed.
This code is in the public domain; do with it what you wish.

Equivalent code is available from RSA Data Security, Inc.
This code has been tested against that, and is equivalent,
except that you don't need to include two pages of legalese
with every copy.

To compute the message digest of a chunk of bytes, create an
TMD5 object, call Update() as needed on buffers full of bytes, and
then call Final(), which will, optionally, fill a supplied 16-byte
array with the digest.


Function Members (Methods)

public:
virtual~TMD5()
const char*AsString() const
static TClass*Class()
static TMD5*FileChecksum(const char* file)
static Int_tFileChecksum(const char* file, UChar_t[16] digest)
voidFinal()
voidFinal(UChar_t[16] digest)
virtual TClass*IsA() const
TMD5&operator=(const TMD5& rhs)
voidPrint() const
static TMD5*ReadChecksum(const char* file)
Int_tSetDigest(const char* md5ascii)
virtual voidShowMembers(TMemberInspector& insp) const
virtual voidStreamer(TBuffer&)
voidStreamerNVirtual(TBuffer& ClassDef_StreamerNVirtual_b)
TMD5()
TMD5(const UChar_t* digest)
TMD5(const TMD5& md5)
voidUpdate(const UChar_t* buf, UInt_t len)
static Int_tWriteChecksum(const char* file, const TMD5* md5)
private:
voidDecode(UInt_t* out, const UChar_t* in, UInt_t len)
voidEncode(UChar_t* out, const UInt_t* in, UInt_t len)
voidTransform(UInt_t[4] buf, const UChar_t[64] in)

Data Members

private:
UInt_tfBits[2]!temp buffer
UInt_tfBuf[4]!temp buffer
UChar_tfDigest[16]message digest
Bool_tfFinalizedtrue if message digest has been finalized
UChar_tfIn[64]!temp buffer
Char_tfString[33]!string representation of digest

Class Charts

Inheritance Chart:
TMD5

Function documentation

void Transform(UInt_t[4] buf, const UChar_t[64] in)
void Encode(UChar_t* out, const UInt_t* in, UInt_t len)
void Decode(UInt_t* out, const UChar_t* in, UInt_t len)
TMD5()
TMD5(const UChar_t* digest)
TMD5(const TMD5& md5)
virtual ~TMD5()
{ }
TMD5 & operator=(const TMD5& rhs)
void Update(const UChar_t* buf, UInt_t len)
void Final()
void Final(UChar_t[16] digest)
void Print() const
const char * AsString() const
Int_t SetDigest(const char* md5ascii)
TMD5 * ReadChecksum(const char* file)
Int_t WriteChecksum(const char* file, const TMD5* md5)
TMD5 * FileChecksum(const char* file)
Int_t FileChecksum(const char* file, UChar_t[16] digest)