2008-12-21 00:16:09 +00:00
|
|
|
/******************************************************************
|
|
|
|
* S-BOX for Twister
|
|
|
|
*
|
|
|
|
*
|
|
|
|
*******************************************************************/
|
|
|
|
|
2008-12-22 03:19:07 +00:00
|
|
|
#include "config.h"
|
2008-12-21 00:16:09 +00:00
|
|
|
#include <stdint.h>
|
|
|
|
|
2012-03-14 16:38:51 +00:00
|
|
|
#ifndef TWISTER_TABLES_H_
|
|
|
|
#define TWISTER_TABLES_H_
|
|
|
|
extern const uint8_t twister_sbox[256];
|
2008-12-21 00:16:09 +00:00
|
|
|
|
2008-12-22 03:19:07 +00:00
|
|
|
#ifndef TWISTER_MUL_TABLE
|
2008-12-21 00:16:09 +00:00
|
|
|
|
|
|
|
/* Twister MDS matrix */
|
2012-03-14 16:38:51 +00:00
|
|
|
extern const uint8_t twister_mds[8][8];
|
2008-12-21 00:16:09 +00:00
|
|
|
|
2008-12-22 03:19:07 +00:00
|
|
|
#else
|
|
|
|
|
2012-03-14 16:38:51 +00:00
|
|
|
extern const uint8_t twister_mds[8][8];
|
|
|
|
extern const uint8_t twister_multab[8][256];
|
2008-12-22 03:19:07 +00:00
|
|
|
|
|
|
|
#endif
|
|
|
|
|
2012-03-14 16:38:51 +00:00
|
|
|
#endif
|
2008-12-22 03:19:07 +00:00
|
|
|
|