|
ZNC trunk
|
does Blowfish w/64 bit feedback, no padding More...
#include <Utils.h>
Public Member Functions | |
| CBlowfish (const CString &sPassword, int iEncrypt, const CString &sIvec="") | |
| ~CBlowfish () | |
| CBlowfish (const CBlowfish &)=default | |
| CBlowfish & | operator= (const CBlowfish &)=default |
| void | Crypt (unsigned char *input, unsigned char *output, unsigned int ibytes) |
| output must be the same size as input | |
| unsigned char * | Crypt (unsigned char *input, unsigned int ibytes) |
| must free result | |
| CString | Crypt (const CString &sData) |
Static Public Member Functions | |
| static unsigned char * | MD5 (const unsigned char *input, unsigned int ilen) |
| output must be freed | |
| static CString | MD5 (const CString &sInput, bool bHexEncode=false) |
| returns an md5 of the CString (not hex encoded) | |
does Blowfish w/64 bit feedback, no padding
| sPassword | key to encrypt with |
| iEncrypt | encrypt method (BF_DECRYPT or BF_ENCRYPT) |
| sIvec | what to set the ivector to start with, default sets it all 0's |
| CBlowfish::~CBlowfish | ( | ) |
|
default |
| void CBlowfish::Crypt | ( | unsigned char * | input, |
| unsigned char * | output, | ||
| unsigned int | ibytes | ||
| ) |
output must be the same size as input
| unsigned char * CBlowfish::Crypt | ( | unsigned char * | input, |
| unsigned int | ibytes | ||
| ) |
must free result
returns an md5 of the CString (not hex encoded)
|
static |
output must be freed