KiCad PCB EDA Suite
Loading...
Searching...
No Matches
md5_hash.cpp File Reference
#include <cstring>
#include <cstdio>
#include <md5_hash.h>

Go to the source code of this file.

Macros

#define DBL_INT_ADD(a, b, c)   if (a > 0xffffffff - c) ++b; a += c;
 
#define ROTLEFT(a, b)   ((a << b) | (a >> (32-b)))
 
#define F(x, y, z)   ((x & y) | (~x & z))
 
#define G(x, y, z)   ((x & z) | (y & ~z))
 
#define H(x, y, z)   (x ^ y ^ z)
 
#define I(x, y, z)   (y ^ (x | ~z))
 
#define FF(a, b, c, d, m, s, t)
 
#define GG(a, b, c, d, m, s, t)
 
#define HH(a, b, c, d, m, s, t)
 
#define II(a, b, c, d, m, s, t)
 

Macro Definition Documentation

◆ DBL_INT_ADD

#define DBL_INT_ADD (   a,
  b,
 
)    if (a > 0xffffffff - c) ++b; a += c;

Definition at line 12 of file md5_hash.cpp.

◆ F

#define F (   x,
  y,
 
)    ((x & y) | (~x & z))

Definition at line 15 of file md5_hash.cpp.

◆ FF

#define FF (   a,
  b,
  c,
  d,
  m,
  s,
 
)
Value:
{ a += F(b,c,d) + m + t; \
a = b + ROTLEFT(a,s); }
#define F(x, y, z)
Definition: md5_hash.cpp:15
#define ROTLEFT(a, b)
Definition: md5_hash.cpp:13

Definition at line 20 of file md5_hash.cpp.

◆ G

#define G (   x,
  y,
 
)    ((x & z) | (y & ~z))

Definition at line 16 of file md5_hash.cpp.

◆ GG

#define GG (   a,
  b,
  c,
  d,
  m,
  s,
 
)
Value:
{ a += G(b,c,d) + m + t; \
a = b + ROTLEFT(a,s); }
#define G(x, y, z)
Definition: md5_hash.cpp:16

Definition at line 22 of file md5_hash.cpp.

◆ H

#define H (   x,
  y,
 
)    (x ^ y ^ z)

Definition at line 17 of file md5_hash.cpp.

◆ HH

#define HH (   a,
  b,
  c,
  d,
  m,
  s,
 
)
Value:
{ a += H(b,c,d) + m + t; \
a = b + ROTLEFT(a,s); }
#define H(x, y, z)
Definition: md5_hash.cpp:17

Definition at line 24 of file md5_hash.cpp.

◆ I

#define I (   x,
  y,
 
)    (y ^ (x | ~z))

Definition at line 18 of file md5_hash.cpp.

◆ II

#define II (   a,
  b,
  c,
  d,
  m,
  s,
 
)
Value:
{ a += I(b,c,d) + m + t; \
a = b + ROTLEFT(a,s); }
#define I(x, y, z)
Definition: md5_hash.cpp:18

Definition at line 26 of file md5_hash.cpp.

◆ ROTLEFT

#define ROTLEFT (   a,
 
)    ((a << b) | (a >> (32-b)))

Definition at line 13 of file md5_hash.cpp.