?? des.h
字號(hào):
#ifndef BYTE
#define BYTE unsigned char
#endif
#ifndef byte
#define byte unsigned char
#endif
#ifndef uint8
#define uint8 unsigned char
#endif
#ifndef uint32
#define uint32 unsigned long int
#endif
// common DES modes
#define DES_LEFT 0
#define DES_RIGHT 1
#define SECA_PC 2
#define DES_HASH 8
#define DES_PC1 16
#define DES_IP 32
#define DES_FP 64
#define DES_MOD 128
#define PRV_DES_ENCRYPT (DES_LEFT|DES_PC1|DES_IP|DES_FP)
#define PRV_DES_DECRYPT (DES_RIGHT|DES_PC1|DES_IP|DES_FP)
#define VIA_DES (DES_LEFT|DES_MOD)
#define VIA_DES_HASH (DES_LEFT|DES_HASH|DES_MOD)
//#define SECA_DES_ENCR (PRV_DES_ENCRYPT|SECA_PC)
//#define SECA_DES_DECR (PRV_DES_DECRYPT|SECA_PC)
//#define NAGRA_DES_ENCR PRV_DES_ENCRYPT
//#define NAGRA_DES_DECR PRV_DES_DECRYPT
// common Cryptoworks DES modes
#define CRW_DES_LEFT 0
#define CRW_DES_RIGHT 1
#define DESMOD1 2
#define DES 4
#define DESMOD3 8
#define DES2_DECRYPT (DES|DESMOD3|CRW_DES_LEFT)
#define DES2_ENCRYPT (DES|DESMOD1|CRW_DES_RIGHT)
#define CRW_DES_DECRYPT DES
extern const byte E[], S[][64], P[], LS[], IP[], FP[];
extern byte _PC1[], _PC2[];
void cDes_Des(unsigned char *data, const unsigned char *key, int mode);
unsigned int cDes_Mod (unsigned int R, unsigned int key7);
void cDes_Permute (unsigned char *data, const unsigned char *P, int n);
void cDes_3DES(unsigned char *data, unsigned char *key);
?? 快捷鍵說(shuō)明
復(fù)制代碼
Ctrl + C
搜索代碼
Ctrl + F
全屏模式
F11
切換主題
Ctrl + Shift + D
顯示快捷鍵
?
增大字號(hào)
Ctrl + =
減小字號(hào)
Ctrl + -