Class MD5

Class Documentation

class MD5

Class MD5, for calculating MD5 hashes of strings or byte arrays it is not meant to be fast or secure

usage: 1) feed it blocks of uchars with update() 2) finalize() 3) get hexdigest() string or MD5(std::string).hexdigest()

assumes that char is 8 bit and int is 32 bit

Public Types

typedef unsigned char uint1
typedef unsigned int size_type

Public Functions

MD5()
MD5(const std::string &text)
void update(const unsigned char *buf, size_type length)
void update(const char *buf, size_type length)
MD5 &finalize()
std::string hexdigest() const
void init()

Public Members

uint1 digest[16]

Friends

friend std::ostream &operator<<(std::ostream&, MD5 &md5)