• Main Page
  • Related Pages
  • Modules
  • Data Structures
  • Files
  • File List
  • Globals

include/beecrypt/md4.h

Go to the documentation of this file.
00001 /*
00002  * This library is free software; you can redistribute it and/or
00003  * modify it under the terms of the GNU Lesser General Public
00004  * License as published by the Free Software Foundation; either
00005  * version 2.1 of the License, or (at your option) any later version.
00006  *
00007  * This library is distributed in the hope that it will be useful,
00008  * but WITHOUT ANY WARRANTY; without even the implied warranty of
00009  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
00010  * Lesser General Public License for more details.
00011  *
00012  * You should have received a copy of the GNU Lesser General Public
00013  * License along with this library; if not, write to the Free Software
00014  * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
00015  *
00016  */
00017 
00025 #ifndef _MD4_H
00026 #define _MD4_H
00027 
00028 #include "beecrypt/beecrypt.h"
00029 
00033 #ifdef __cplusplus
00034 struct BEECRYPTAPI md4Param
00035 #else
00036 struct _md4Param
00037 #endif
00038 {
00041     uint32_t h[4];
00044     uint32_t data[16];
00049     #if (MP_WBITS == 64)
00050     mpw length[1];
00051     #elif (MP_WBITS == 32)
00052     mpw length[2];
00053     #else
00054     # error
00055     #endif
00056 
00060     uint32_t offset;
00061 };
00062 
00063 #ifndef __cplusplus
00064 typedef struct _md4Param md4Param;
00065 #endif
00066 
00067 #ifdef __cplusplus
00068 extern "C" {
00069 #endif
00070 
00074 /*@unchecked@*/ /*@observer@*/
00075 extern BEECRYPTAPI const hashFunction md4;
00076 
00083 BEECRYPTAPI
00084 void md4Process(md4Param* mp)
00085     /*@modifies mp @*/;
00086 
00093 BEECRYPTAPI
00094 int md4Reset   (md4Param* mp)
00095     /*@modifies mp @*/;
00096 
00105 BEECRYPTAPI
00106 int md4Update  (md4Param* mp, const byte* data, size_t size)
00107     /*@modifies mp @*/;
00108 
00116 BEECRYPTAPI
00117 int md4Digest  (md4Param* mp, byte* digest)
00118     /*@modifies mp digest @*/;
00119 
00120 #ifdef __cplusplus
00121 }
00122 #endif
00123 
00124 #endif

Generated on Tue Mar 1 2011 for BeeCrypt by  doxygen 1.7.1