forked from wolfSSL/wolfssl
ascon: remove 6 round perm as its not used
This commit is contained in:
@ -70,8 +70,6 @@ static const byte round_constants[MAX_ROUNDS] = {
|
|||||||
static byte start_index(byte rounds)
|
static byte start_index(byte rounds)
|
||||||
{
|
{
|
||||||
switch (rounds) {
|
switch (rounds) {
|
||||||
case 6:
|
|
||||||
return 6;
|
|
||||||
case 8:
|
case 8:
|
||||||
return 4;
|
return 4;
|
||||||
case 12:
|
case 12:
|
||||||
@ -154,7 +152,9 @@ static void permutation(AsconState* a, byte rounds)
|
|||||||
tmp.s64[2] ^ rotrFixed64(tmp.s64[2], 1) ^ rotrFixed64(tmp.s64[2], 6); \
|
tmp.s64[2] ^ rotrFixed64(tmp.s64[2], 1) ^ rotrFixed64(tmp.s64[2], 6); \
|
||||||
} while (0)
|
} while (0)
|
||||||
|
|
||||||
#define p6(a) \
|
#define p8(a) \
|
||||||
|
p(a, 0xb4); \
|
||||||
|
p(a, 0xa5); \
|
||||||
p(a, 0x96); \
|
p(a, 0x96); \
|
||||||
p(a, 0x87); \
|
p(a, 0x87); \
|
||||||
p(a, 0x78); \
|
p(a, 0x78); \
|
||||||
@ -162,11 +162,6 @@ static void permutation(AsconState* a, byte rounds)
|
|||||||
p(a, 0x5a); \
|
p(a, 0x5a); \
|
||||||
p(a, 0x4b)
|
p(a, 0x4b)
|
||||||
|
|
||||||
#define p8(a) \
|
|
||||||
p(a, 0xb4); \
|
|
||||||
p(a, 0xa5); \
|
|
||||||
p6(a)
|
|
||||||
|
|
||||||
#define p12(a) \
|
#define p12(a) \
|
||||||
p(a, 0xf0); \
|
p(a, 0xf0); \
|
||||||
p(a, 0xe1); \
|
p(a, 0xe1); \
|
||||||
|
Reference in New Issue
Block a user