md4.c File Reference
#include "squid.h"
#include <string.h>
#include "smblib/md4.h"
Include dependency graph for md4.c:

Go to the source code of this file.

Macros

#define ROUND1(a, b, c, d, k, s)   a = lshift(a + F(b,c,d) + X[k], s)
 
#define ROUND2(a, b, c, d, k, s)   a = lshift(a + G(b,c,d) + X[k] + (uint32)0x5A827999,s)
 
#define ROUND3(a, b, c, d, k, s)   a = lshift(a + H(b,c,d) + X[k] + (uint32)0x6ED9EBA1,s)
 

Typedefs

typedef unsigned int uint32
 

Functions

static uint32 F (uint32 X, uint32 Y, uint32 Z)
 
static uint32 G (uint32 X, uint32 Y, uint32 Z)
 
static uint32 H (uint32 X, uint32 Y, uint32 Z)
 
static uint32 lshift (uint32 x, int s)
 
static void mdfour64 (uint32 *M)
 
static void copy64 (uint32 *M, unsigned char *in)
 
static void copy4 (unsigned char *out, uint32 x)
 
void mdfour (unsigned char *out, unsigned char *in, int n)
 

Variables

static uint32 A
 
static uint32 B
 
static uint32 C
 
static uint32 D
 

Macro Definition Documentation

#define ROUND1 (   a,
  b,
  c,
  d,
  k,
 
)    a = lshift(a + F(b,c,d) + X[k], s)

Definition at line 70 of file md4.c.

Referenced by mdfour64().

#define ROUND2 (   a,
  b,
  c,
  d,
  k,
 
)    a = lshift(a + G(b,c,d) + X[k] + (uint32)0x5A827999,s)

Definition at line 71 of file md4.c.

Referenced by mdfour64().

#define ROUND3 (   a,
  b,
  c,
  d,
  k,
 
)    a = lshift(a + H(b,c,d) + X[k] + (uint32)0x6ED9EBA1,s)

Definition at line 72 of file md4.c.

Referenced by mdfour64().

Typedef Documentation

typedef unsigned int uint32

Definition at line 41 of file md4.c.

Function Documentation

static void copy4 ( unsigned char *  out,
uint32  x 
)
static

Definition at line 166 of file md4.c.

Referenced by mdfour().

static void copy64 ( uint32 M,
unsigned char *  in 
)
static

Definition at line 156 of file md4.c.

References i.

Referenced by mdfour().

static uint32 G ( uint32  X,
uint32  Y,
uint32  Z 
)
static

Definition at line 52 of file md4.c.

static uint32 H ( uint32  X,
uint32  Y,
uint32  Z 
)
static

Definition at line 58 of file md4.c.

static uint32 lshift ( uint32  x,
int  s 
)
static

Definition at line 64 of file md4.c.

void mdfour ( unsigned char *  out,
unsigned char *  in,
int  n 
)

Definition at line 176 of file md4.c.

References A, B, buf, copy4(), copy64(), D, i, and mdfour64().

Referenced by E_md4hash().

static void mdfour64 ( uint32 M)
static

Definition at line 76 of file md4.c.

References A, B, C, D, ROUND1, ROUND2, and ROUND3.

Referenced by mdfour().

Variable Documentation

uint32 D
static

Definition at line 43 of file md4.c.

Referenced by StatHist::deltaPctile(), mdfour(), and mdfour64().

 

Introduction

Documentation

Support

Miscellaneous

Web Site Translations

Mirrors