zcryptor.h
来自「这是一个加解密程序」· C头文件 代码 · 共 37 行
H
37 行
/* ZCryptor.h
定义“保密密钥加密算法”的抽象类 CZCryptor
张忠杰 2003-11-25
*/
#ifndef __ZCRYPTOR_H__
#define __ZCRYPTOR_H__
class CZCryptor {
public:
//设置密钥(密钥的长度根据加密算法确定)
virtual void SetKey(const void *Key)=0;
//读取密钥(密钥的长度根据加密算法确定)
virtual void GetKey(void *Key)=0;
//加密分组(分组的大小为64Bit)
virtual void Encrypt(void *Dst,const void *Src)=0;
//解密分组(分组的大小为64Bit)
virtual void Decrypt(void *Dst,const void *Src)=0;
//长报文加密
void LongEncrypt(void *Dst,const void *Src,int Len);
//长报文解密
void LongDecrypt(void *Dst,const void *Src,int Len);
//长报文Hash
void Hash(const void *Data,int Len,void *Result);
};
#endif /* __ZCRYPTOR_H__ */
⌨️ 快捷键说明
复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?