OpenSSL  1.0.1c
 All Classes Files Functions Variables Typedefs Enumerations Enumerator Macros
Macros | Typedefs | Functions
wp_block.c File Reference
#include "wp_locl.h"
#include <string.h>

Go to the source code of this file.

Macros

#define ROUNDS   10
 
#define STRICT_ALIGNMENT
 
#define N   8
 
#define LL(c0, c1, c2, c3, c4, c5, c6, c7)
 
#define C0(K, i)   (Cx.q[0+8*K.c[(i)*8+0]])
 
#define C1(K, i)   (Cx.q[1+8*K.c[(i)*8+1]])
 
#define C2(K, i)   (Cx.q[2+8*K.c[(i)*8+2]])
 
#define C3(K, i)   (Cx.q[3+8*K.c[(i)*8+3]])
 
#define C4(K, i)   (Cx.q[4+8*K.c[(i)*8+4]])
 
#define C5(K, i)   (Cx.q[5+8*K.c[(i)*8+5]])
 
#define C6(K, i)   (Cx.q[6+8*K.c[(i)*8+6]])
 
#define C7(K, i)   (Cx.q[7+8*K.c[(i)*8+7]])
 
#define RC   (&(Cx.q[256*N]))
 

Typedefs

typedef unsigned char u8
 
typedef unsigned long long u64
 

Functions

void whirlpool_block (WHIRLPOOL_CTX *ctx, const void *inp, size_t n)
 

Macro Definition Documentation

#define C0 (   K,
 
)    (Cx.q[0+8*K.c[(i)*8+0]])

Definition at line 168 of file wp_block.c.

#define C1 (   K,
 
)    (Cx.q[1+8*K.c[(i)*8+1]])

Definition at line 169 of file wp_block.c.

#define C2 (   K,
 
)    (Cx.q[2+8*K.c[(i)*8+2]])

Definition at line 170 of file wp_block.c.

#define C3 (   K,
 
)    (Cx.q[3+8*K.c[(i)*8+3]])

Definition at line 171 of file wp_block.c.

#define C4 (   K,
 
)    (Cx.q[4+8*K.c[(i)*8+4]])

Definition at line 172 of file wp_block.c.

#define C5 (   K,
 
)    (Cx.q[5+8*K.c[(i)*8+5]])

Definition at line 173 of file wp_block.c.

#define C6 (   K,
 
)    (Cx.q[6+8*K.c[(i)*8+6]])

Definition at line 174 of file wp_block.c.

#define C7 (   K,
 
)    (Cx.q[7+8*K.c[(i)*8+7]])

Definition at line 175 of file wp_block.c.

#define LL (   c0,
  c1,
  c2,
  c3,
  c4,
  c5,
  c6,
  c7 
)
Value:
c0,c1,c2,c3,c4,c5,c6,c7, \
c7,c0,c1,c2,c3,c4,c5,c6, \
c6,c7,c0,c1,c2,c3,c4,c5, \
c5,c6,c7,c0,c1,c2,c3,c4, \
c4,c5,c6,c7,c0,c1,c2,c3, \
c3,c4,c5,c6,c7,c0,c1,c2, \
c2,c3,c4,c5,c6,c7,c0,c1, \
c1,c2,c3,c4,c5,c6,c7,c0

Definition at line 160 of file wp_block.c.

#define N   8

Definition at line 159 of file wp_block.c.

#define RC   (&(Cx.q[256*N]))
#define ROUNDS   10

Definition at line 50 of file wp_block.c.

#define STRICT_ALIGNMENT

Definition at line 52 of file wp_block.c.

Typedef Documentation

typedef unsigned long long u64

Definition at line 47 of file wp_block.c.

typedef unsigned char u8

The Whirlpool hashing function.

References

The Whirlpool algorithm was developed by Paulo S. L. M. Barreto and Vincent Rijmen.

See P.S.L.M. Barreto, V. Rijmen, ``The Whirlpool hashing function,'' NESSIE submission, 2000 (tweaked version, 2001), https://www.cosic.esat.kuleuven.ac.be/nessie/workshop/submissions/whirlpool.zip

Based on "@version 3.0 (2003.03.12)" by Paulo S.L.M. Barreto and Vincent Rijmen. Lookup "reference implementations" on http://planeta.terra.com.br/informatica/paulobarreto/


THIS SOFTWARE IS PROVIDED BY THE AUTHORS ''AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHORS OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.

Definition at line 41 of file wp_block.c.

Function Documentation

void whirlpool_block ( WHIRLPOOL_CTX ctx,
const void inp,
size_t  n 
)

Definition at line 467 of file wp_block.c.

Variable Documentation

u8 c[(256 *N+ROUNDS)*sizeof(u64)]

Definition at line 193 of file wp_block.c.

u64 q[(256 *N+ROUNDS)]

Definition at line 194 of file wp_block.c.