aes_encryptor.h

来自「C++ web POSIX framewark」· C头文件 代码 · 共 33 行

H
33
字号
#ifndef CPPCMS_AES_ENCRYPTOR_H#define CPPCMS_AES_ENCRYPTOR_H#include <string>#include <gcrypt.h>#include "encryptor.h"namespace cppcms {namespace aes {class cipher : public encryptor {	gcry_cipher_hd_t hd_out;	gcry_cipher_hd_t hd_in;	struct aes_hdr {		char salt[16];		char md5[16];	};public:	virtual std::string encrypt(std::string const &plain,time_t timeout);	virtual bool decrypt(std::string const &cipher,std::string &plain,time_t *timeout=NULL) ;	cipher(std::string key);	~cipher();};} // aes} // cppcms#endif

⌨️ 快捷键说明

复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?