a8/a8/openssl.h
aozhiwei c9d4c5699c 1
2018-11-24 17:14:48 +08:00

26 lines
657 B
C++
Executable File

#ifndef A8_OPENSSL_H
#define A8_OPENSSL_H
namespace a8
{
namespace openssl
{
std::string md5(std::string msg);
#if 0
RSA* CreatePublicRSA(unsigned char* key);
RSA* CreatePrivateRSA(unsigned char* key);
bool RSAPublicDecrypt(std::string& from, std::string& to, RSA *rsa, int padding);
#endif
int Base64Decode(const std::string& from, std::string& to);
void Base64Encode(const std::string& from, std::string& to);
std::string Sha1Encode(std::string& from);
std::string sha1(std::string& from);
unsigned int Crc32(const unsigned char *buf, unsigned int size);
}
}
#endif