]> git.cryptolib.org Git - avr-crypto-lib.git/blob - rc6.h
+RC5 +size-statistics tool +small modification to nessie_bc_test (optional free(...
[avr-crypto-lib.git] / rc6.h
1 /* 
2  * File:        rc6.h
3  * Author:      Daniel Otte
4  * Date:        06.08.2006
5  * License: GPL
6  * Description: Implementation of the RC6 cipher algorithm.
7  *      This implementation is restricted to 32-bit words, but free in the choice of number of rounds (0 to 255).
8  *      so it is RC6-32/r/b
9  */
10  
11  #include <stdint.h>
12  
13  typedef struct rc6_ctx_st{
14         uint8_t         rounds;         /* specifys the number of rounds; default: 20 */
15         uint32_t*       S;                      /* the round-keys */
16  } rc6_ctx_t;
17  
18  
19  uint8_t rc6_init(rc6_ctx_t *s,void* key, uint16_t keylength);
20  
21  uint8_t rc6_initl(rc6_ctx_t *s,void* key, uint16_t keylength, uint8_t rounds);
22  
23  void rc6_enc(rc6_ctx_t *s, void* block);
24  
25  void rc6_dec(rc6_ctx_t *s, void* block);
26  
27  void rc6_free(rc6_ctx_t *s); 
28