mirror of
https://github.com/jedisct1/libsodium.git
synced 2026-08-25 08:37:13 +09:00
@@ -63,9 +63,9 @@ crypto_aead_aegis128l_init(const unsigned char *key, const unsigned char *nonce,
|
||||
state[2] = c2;
|
||||
state[3] = c1;
|
||||
state[4] = veorq_u8(k, n);
|
||||
state[5] = veorq_u8(k1, c2);
|
||||
state[6] = veorq_u8(k1, c1);
|
||||
state[7] = veorq_u8(k1, c2);
|
||||
state[5] = veorq_u8(k, c2);
|
||||
state[6] = veorq_u8(k, c1);
|
||||
state[7] = veorq_u8(k, c2);
|
||||
for (i = 0; i < 10; i++) {
|
||||
crypto_aead_aegis128l_update(state, n, k);
|
||||
}
|
||||
|
||||
@@ -51,8 +51,8 @@ crypto_aead_aegis256_init(const unsigned char *key, const unsigned char *nonce,
|
||||
|
||||
k1 = vld1q_u8(&key[0]);
|
||||
k2 = vld1q_u8(&key[16]);
|
||||
kxn3 = veorq_u8(k1, vld1q_u8(&nonce[0]));
|
||||
kxn4 = veorq_u8(k2, vld1q_u8(&nonce[16]));
|
||||
kxn1 = veorq_u8(k1, vld1q_u8(&nonce[0]));
|
||||
kxn2 = veorq_u8(k2, vld1q_u8(&nonce[16]));
|
||||
|
||||
state[0] = kxn1;
|
||||
state[1] = kxn2;
|
||||
|
||||
Reference in New Issue
Block a user