]> andersk Git - openssh.git/blob - rijndael.h
- markus@cvs.openbsd.org 2000/12/06 23:10:39
[openssh.git] / rijndael.h
1 /*
2  * rijndael-alg-fst.h   v2.4   April '2000
3  * rijndael-api-fst.h   v2.4   April '2000
4  *
5  * Optimised ANSI C code
6  *
7  */
8
9 #ifndef RIJNDAEL_H
10 #define RIJNDAEL_H
11
12 #define RIJNDAEL_MAXKC          (256/32)
13 #define RIJNDAEL_MAXROUNDS      14
14
15 #define RIJNDAEL_ENCRYPT        0
16 #define RIJNDAEL_DECRYPT        1
17
18 typedef struct {
19         int ROUNDS;             /* key-length-dependent number of rounds */
20         u_int8_t keySched[RIJNDAEL_MAXROUNDS+1][4][4];
21 } rijndael_key;
22
23 int rijndael_encrypt(rijndael_key *key, u_int8_t a[16], u_int8_t b[16]);
24 int rijndael_decrypt(rijndael_key *key, u_int8_t a[16], u_int8_t b[16]);
25 int rijndael_makekey(rijndael_key *key, int direction, int keyLen, u_int8_t *keyMaterial);
26
27 #endif
This page took 1.763301 seconds and 5 git commands to generate.