"Fossies" - the Fresh Open Source Software Archive

Member "postal-0.76/md5.h" (13 Dec 2016, 2350 Bytes) of package /linux/privat/postal-0.76.tgz:


As a special service "Fossies" has tried to format the requested source page into HTML format using (guessed) C and C++ source code syntax highlighting (style: standard) with prefixed line numbers and code folding option. Alternatively you can here view or download the uninterpreted source code file. For more information about "md5.h" see the Fossies "Dox" file reference documentation.

    1 /* GLOBAL.H - RSAREF types and constants
    2  */
    3 
    4 /* PROTOTYPES should be set to one if and only if the compiler supports
    5   function argument prototyping.
    6   The following makes PROTOTYPES default to 0 if it has not already
    7   been defined with C compiler flags.
    8  */
    9 #ifndef PROTOTYPES
   10 #  if __STDC__
   11 #    define PROTOTYPES 1
   12 #  else
   13 #    define PROTOTYPES 0
   14 #  endif
   15 #endif
   16 
   17 /* POINTER defines a generic pointer type */
   18 typedef unsigned char *POINTER;
   19 typedef const unsigned char *CPOINTER;
   20 
   21 /* UINT2 defines a two byte word */
   22 typedef unsigned short int UINT2;
   23 
   24 /* UINT4 defines a four byte word */
   25 #if defined(__alpha) && (defined(__osf__) || defined(__linux__))
   26 typedef unsigned int UINT4;
   27 #else
   28 typedef unsigned long int UINT4;
   29 #endif
   30 
   31 /* PROTO_LIST is defined depending on how PROTOTYPES is defined above.
   32    If using PROTOTYPES, then PROTO_LIST returns the list, otherwise it
   33   returns an empty list.
   34  */
   35 #if PROTOTYPES
   36 #define PROTO_LIST(list) list
   37 #else
   38 #define PROTO_LIST(list) ()
   39 #endif
   40 
   41 /* MD5.H - header file for MD5C.C
   42  */
   43 
   44 /* Copyright (C) 1991-2, RSA Data Security, Inc. Created 1991. All
   45 rights reserved.
   46 
   47 License to copy and use this software is granted provided that it
   48 is identified as the "RSA Data Security, Inc. MD5 Message-Digest
   49 Algorithm" in all material mentioning or referencing this software
   50 or this function.
   51 
   52 License is also granted to make and use derivative works provided
   53 that such works are identified as "derived from the RSA Data
   54 Security, Inc. MD5 Message-Digest Algorithm" in all material
   55 mentioning or referencing the derived work.
   56 
   57 RSA Data Security, Inc. makes no representations concerning either
   58 the merchantability of this software or the suitability of this
   59 software for any particular purpose. It is provided "as is"
   60 without express or implied warranty of any kind.
   61 
   62 These notices must be retained in any copies of any part of this
   63 documentation and/or software.
   64  */
   65 
   66 /* MD5 context. */
   67 typedef struct {
   68   UINT4 state[4];                                   /* state (ABCD) */
   69   UINT4 count[2];        /* number of bits, modulo 2^64 (lsb first) */
   70   unsigned char buffer[64];                         /* input buffer */
   71 } MD5_CTX;
   72 
   73 void MD5Init PROTO_LIST ((MD5_CTX *));
   74 void MD5Update PROTO_LIST
   75   ((MD5_CTX *, const unsigned char *, unsigned int));
   76 void MD5Final PROTO_LIST ((unsigned char [16], MD5_CTX *));
   77