Lines Matching refs:N_BLOCK
270 #define block_copy(d, s) memcpy(d, s, N_BLOCK)
363 static void add_round_key(uint_8t d[N_BLOCK], const uint_8t k[N_BLOCK]) { in add_round_key() argument
367 static void shift_sub_rows(uint_8t st[N_BLOCK]) { in shift_sub_rows() argument
395 static void inv_shift_sub_rows(uint_8t st[N_BLOCK]) { in inv_shift_sub_rows() argument
424 static void mix_sub_columns(uint_8t dt[N_BLOCK]) { argument
425 uint_8t st[N_BLOCK];
428 static void mix_sub_columns(uint_8t dt[N_BLOCK], uint_8t st[N_BLOCK]) {
452 static void inv_mix_sub_columns(uint_8t dt[N_BLOCK]) { argument
453 uint_8t st[N_BLOCK];
456 static void inv_mix_sub_columns(uint_8t dt[N_BLOCK], uint_8t st[N_BLOCK]) {
546 return_type aes_encrypt(const unsigned char in[N_BLOCK], unsigned char out[N_BLOCK], const aes_cont… argument
548 uint_8t s1[N_BLOCK], r;
555 add_round_key(s1, ctx->ksch + r * N_BLOCK);
559 uint_8t s2[N_BLOCK];
561 copy_and_key(s1, s2, ctx->ksch + r * N_BLOCK);
565 copy_and_key(out, s1, ctx->ksch + r * N_BLOCK);
574 …const unsigned char* in, unsigned char* out, int n_block, unsigned char iv[N_BLOCK], const aes_con… argument
578 memcpy(out, iv, N_BLOCK);
579 in += N_BLOCK;
580 out += N_BLOCK;
591 return_type aes_decrypt(const unsigned char in[N_BLOCK], unsigned char out[N_BLOCK], const aes_cont… argument
593 uint_8t s1[N_BLOCK], r;
594 copy_and_key(s1, in, ctx->ksch + ctx->rnd * N_BLOCK);
600 add_round_key(s1, ctx->ksch + r * N_BLOCK);
605 uint_8t s2[N_BLOCK];
606 copy_and_key(s2, s1, ctx->ksch + r * N_BLOCK);
619 …const unsigned char* in, unsigned char* out, int n_block, unsigned char iv[N_BLOCK], const aes_con… argument
621 uint_8t tmp[N_BLOCK];
623 memcpy(tmp, in, N_BLOCK);
626 memcpy(iv, tmp, N_BLOCK);
627 in += N_BLOCK;
628 out += N_BLOCK;
639 static void update_encrypt_key_128(uint_8t k[N_BLOCK], uint_8t* rc) { argument
659 const unsigned char in[N_BLOCK], argument
660 unsigned char out[N_BLOCK], argument
661 const unsigned char key[N_BLOCK], argument
662 unsigned char o_key[N_BLOCK]) { argument
663 uint_8t s1[N_BLOCK], r, rc = 1;
677 uint_8t s2[N_BLOCK];
695 static void update_decrypt_key_128(uint_8t k[N_BLOCK], uint_8t* rc) { argument
714 const unsigned char in[N_BLOCK], argument
715 unsigned char out[N_BLOCK], argument
716 const unsigned char key[N_BLOCK], argument
717 unsigned char o_key[N_BLOCK]) { argument
718 uint_8t s1[N_BLOCK], r, rc = 0x6c;
733 uint_8t s2[N_BLOCK];
749 static void update_encrypt_key_256(uint_8t k[2 * N_BLOCK], uint_8t* rc) { argument
781 const unsigned char in[N_BLOCK], argument
782 unsigned char out[N_BLOCK], argument
783 const unsigned char key[2 * N_BLOCK],
784 unsigned char o_key[2 * N_BLOCK]) {
785 uint_8t s1[N_BLOCK], r, rc = 1;
805 uint_8t s2[N_BLOCK];
827 static void update_decrypt_key_256(uint_8t k[2 * N_BLOCK], uint_8t* rc) { argument
860 const unsigned char in[N_BLOCK], argument
861 unsigned char out[N_BLOCK], argument
862 const unsigned char key[2 * N_BLOCK],
863 unsigned char o_key[2 * N_BLOCK]) {
864 uint_8t s1[N_BLOCK], r, rc = 0x80;
886 uint_8t s2[N_BLOCK];