Home
last modified time | relevance | path

Searched refs:Nb (Results 1 – 4 of 4) sorted by relevance

/tinycrypt-3.7.0/lib/source/
Daes_encrypt.c86 s->words[i] = ((uint32_t)k[Nb*i]<<24) | (k[Nb*i+1]<<16) | in tc_aes128_set_encrypt_key()
87 (k[Nb*i+2]<<8) | (k[Nb*i+3]); in tc_aes128_set_encrypt_key()
90 for (; i < (Nb * (Nr + 1)); ++i) { in tc_aes128_set_encrypt_key()
117 for (i = 0; i < (Nb * Nk); ++i) { in sub_bytes()
134 uint8_t t[Nb*Nk]; in mix_columns()
137 mult_row_column(&t[Nb], s+Nb); in mix_columns()
138 mult_row_column(&t[2 * Nb], s + (2 * Nb)); in mix_columns()
139 mult_row_column(&t[3 * Nb], s + (3 * Nb)); in mix_columns()
149 uint8_t t[Nb * Nk]; in shift_rows()
160 uint8_t state[Nk*Nb]; in tc_aes_encrypt()
[all …]
Daes_decrypt.c83 uint8_t t[Nb*Nk]; in inv_mix_columns()
86 mult_row_column(&t[Nb], s+Nb); in inv_mix_columns()
87 mult_row_column(&t[2*Nb], s+(2*Nb)); in inv_mix_columns()
88 mult_row_column(&t[3*Nb], s+(3*Nb)); in inv_mix_columns()
108 for (i = 0; i < (Nb*Nk); ++i) { in inv_sub_bytes()
120 uint8_t t[Nb*Nk]; in inv_shift_rows()
131 uint8_t state[Nk*Nb]; in tc_aes_decrypt()
144 add_round_key(state, s->words + Nb*Nr); in tc_aes_decrypt()
149 add_round_key(state, s->words + Nb*i); in tc_aes_decrypt()
Dccm_mode.c79 T[i++ % (Nb * Nk)] ^= *data++; in ccm_cbc_mac()
80 if (((i % (Nb * Nk)) == 0) || dlen == i) { in ccm_cbc_mac()
154 uint8_t b[Nb * Nk]; in tc_ccm_generation_encryption()
155 uint8_t tag[Nb * Nk]; in tc_ccm_generation_encryption()
215 uint8_t b[Nb * Nk]; in tc_ccm_decryption_verification()
216 uint8_t tag[Nb * Nk]; in tc_ccm_decryption_verification()
/tinycrypt-3.7.0/lib/include/tinycrypt/
Daes.h58 #define Nb (4) /* number of columns (32-bit words) comprising the state */ macro
61 #define TC_AES_BLOCK_SIZE (Nb*Nk)
62 #define TC_AES_KEY_SIZE (Nb*Nk)
65 unsigned int words[Nb*(Nr+1)];