a8/a8/openssl.h
aozhiwei c1f8ea93f7 1
2022-12-13 18:25:13 +08:00

23 lines
620 B
C++
Executable File

#pragma once
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);
}
}