⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 moo.h

📁 DES/DES3 with operators of CBC and OFB
💻 H
字号:
#pragma once


#ifndef _MOO_H
#define _MOO_H

#ifndef unit8
#define unit8  unsigned char
#endif

#ifndef unit32
#define unit32 unsigned int
#endif



bool set_file( char* pfile, char* efile, char* dfile );

/* CBC_DES routines */

bool cbc_des_init( unit32* iv, unit8 key[], unit8 nkeys );
bool cbc_des_encode( FILE* infile, FILE* outfile );
bool cbc_des_decode( FILE* infile, FILE* outfile );

// using one key
void cbc_des_encode( unit8* string, unit32 len );
void cbc_des_decode( unit8* string, unit32 len);
bool cbc_des_encode_file( char* inputfile, char* outputfile );
bool cbc_des_decode_file( char* inputfile, char* outputfile );

// using more than one keys
void cbc_des3_encode( unit8* string, unit32 len );
void cbc_des3_decoce( unit8* string, unit32 len );
bool cbc_des3_encode_file( char* inputfile, char* outputfile );
bool cbc_des3_decode_file( char* inputfile, char* outputfile );




/* OFB_DES routines */

bool ofb_des_init( unit32* iv, unit8 key[], unit8 nkeys, unit8 j = 8 );
bool ofb_des_encode( FILE* infile, FILE* outfile );
bool ofb_des_decode( FILE* infile, FILE* outfile );

// using one key
void ofb_des_encode( unit8* string, unit32 len );
void ofb_des_decode( unit8* string, unit32 len );
bool ofb_des_encode_file( char* inputfile, char* outfile );
bool ofb_des_decode_file( char* inputfile, char* outfile );

// using more than one keys 
void ofb_des3_encode( unit8* string, unit32 len );
void ofb_des3_decode( unit8* string, unit32 len );
bool ofb_des3_encode_file( char* inputfile, char* outputfile );
bool ofb_des3_decode_file( char* inputfile, char* outputfile );



#endif /*MOO.h*/


	

⌨️ 快捷键说明

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