Searched refs:BELT_BLOCK_LEN (Results 1 – 3 of 3) sorted by relevance
/freebsd/crypto/libecc/src/hash/ |
H A D | belt-hash.c | 117 void belt_encrypt(const u8 in[BELT_BLOCK_LEN], u8 out[BELT_BLOCK_LEN], const u8 ks[BELT_KEY_SCHED_L… in belt_encrypt() argument 158 void belt_decrypt(const u8 in[BELT_BLOCK_LEN], u8 out[BELT_BLOCK_LEN], const u8 ks[BELT_KEY_SCHED_L… in belt_decrypt() argument 201 static void sigma1_xor(const u8 x[2 * BELT_BLOCK_LEN], const u8 h[2 * BELT_BLOCK_LEN], u8 s[BELT_BL… in sigma1_xor() argument 202 u8 tmp1[BELT_BLOCK_LEN]; in sigma1_xor() 205 for(i = 0; i < (BELT_BLOCK_LEN / 2); i++){ in sigma1_xor() 206 tmp1[i] = (h[i] ^ h[i + BELT_BLOCK_LEN]); in sigma1_xor() 207 …tmp1[i + (BELT_BLOCK_LEN / 2)] = (h[i + (BELT_BLOCK_LEN / 2)] ^ h[i + BELT_BLOCK_LEN + (BELT_BLOCK… in sigma1_xor() 211 u8 tmp2[BELT_BLOCK_LEN]; in sigma1_xor() 215 for(i = 0; i < (BELT_BLOCK_LEN / 2); i++){ in sigma1_xor() 217 s[i + (BELT_BLOCK_LEN / 2)] ^= (tmp1[i + (BELT_BLOCK_LEN / 2)] ^ tmp2[i + (BELT_BLOCK_LEN / 2)]); in sigma1_xor() [all …]
|
/freebsd/crypto/libecc/src/sig/ |
H A D | bign_common.c | 207 u8 r[((MAX_DIGEST_SIZE / BELT_BLOCK_LEN) * BELT_BLOCK_LEN) + (2 * BELT_BLOCK_LEN)]; in __bign_determinitic_nonce() 208 u8 r_bar[((MAX_DIGEST_SIZE / BELT_BLOCK_LEN) * BELT_BLOCK_LEN) + (2 * BELT_BLOCK_LEN)]; in __bign_determinitic_nonce() 253 n = (hlen / BELT_BLOCK_LEN); in __bign_determinitic_nonce() 274 u8 s[BELT_BLOCK_LEN]; in __bign_determinitic_nonce() 275 u8 i_block[BELT_BLOCK_LEN]; in __bign_determinitic_nonce() 280 for(z = 0; z < BELT_BLOCK_LEN; z++){ in __bign_determinitic_nonce() 281 s[z] ^= r[(BELT_BLOCK_LEN * j) + z]; in __bign_determinitic_nonce() 285 ret = local_memcpy(&r[0], &r[BELT_BLOCK_LEN], (n - 2) * BELT_BLOCK_LEN); EG(ret, err); in __bign_determinitic_nonce() 290 belt_encrypt(s, &r[(n - 2) * BELT_BLOCK_LEN], theta); in __bign_determinitic_nonce() 291 for(z = 0; z < BELT_BLOCK_LEN; z++){ in __bign_determinitic_nonce() [all …]
|
/freebsd/crypto/libecc/include/libecc/hash/ |
H A D | belt-hash.h | 149 #define BELT_BLOCK_LEN 16 /* The BELT encryption block length */ macro 153 void belt_encrypt(const u8 in[BELT_BLOCK_LEN], u8 out[BELT_BLOCK_LEN], const u8 ks[BELT_KEY_SCHED_L… 154 void belt_decrypt(const u8 in[BELT_BLOCK_LEN], u8 out[BELT_BLOCK_LEN], const u8 ks[BELT_KEY_SCHED_L…
|