diff options
Diffstat (limited to 'libavutil/aes.c')
-rw-r--r-- | libavutil/aes.c | 18 |
1 files changed, 9 insertions, 9 deletions
diff --git a/libavutil/aes.c b/libavutil/aes.c index 3ba5e9aef4..9eb2bb393c 100644 --- a/libavutil/aes.c +++ b/libavutil/aes.c @@ -3,20 +3,20 @@ * * some optimization ideas from aes128.c by Reimar Doeffinger * - * This file is part of Libav. + * This file is part of FFmpeg. * - * Libav is free software; you can redistribute it and/or + * FFmpeg is free software; you can redistribute it and/or * modify it under the terms of the GNU Lesser General Public * License as published by the Free Software Foundation; either * version 2.1 of the License, or (at your option) any later version. * - * Libav is distributed in the hope that it will be useful, + * FFmpeg is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with Libav; if not, write to the Free Software + * License along with FFmpeg; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA */ @@ -40,9 +40,7 @@ typedef struct AVAES { int rounds; } AVAES; -#if FF_API_CONTEXT_SIZE const int av_aes_size= sizeof(AVAES); -#endif struct AVAES *av_aes_alloc(void) { @@ -129,7 +127,7 @@ static inline void mix(av_aes_block state[2], uint32_t multbl[][256], int s1, in state[0].u32[3] = mix_core(multbl, src[3][0], src[s1-1][1], src[1][2], src[s3-1][3]); } -static inline void crypt(AVAES *a, int s, const uint8_t *sbox, +static inline void aes_crypt(AVAES *a, int s, const uint8_t *sbox, uint32_t multbl[][256]) { int r; @@ -148,7 +146,7 @@ void av_aes_crypt(AVAES *a, uint8_t *dst, const uint8_t *src, while (count--) { addkey_s(&a->state[1], src, &a->round_key[a->rounds]); if (decrypt) { - crypt(a, 0, inv_sbox, dec_multbl); + aes_crypt(a, 0, inv_sbox, dec_multbl); if (iv) { addkey_s(&a->state[0], iv, &a->state[0]); memcpy(iv, src, 16); @@ -157,7 +155,7 @@ void av_aes_crypt(AVAES *a, uint8_t *dst, const uint8_t *src, } else { if (iv) addkey_s(&a->state[1], iv, &a->state[1]); - crypt(a, 2, sbox, enc_multbl); + aes_crypt(a, 2, sbox, enc_multbl); addkey_d(dst, &a->state[0], &a->round_key[0]); if (iv) memcpy(iv, dst, 16); @@ -267,6 +265,7 @@ int av_aes_init(AVAES *a, const uint8_t *key, int key_bits, int decrypt) } #ifdef TEST +// LCOV_EXCL_START #include <string.h> #include "lfg.h" #include "log.h" @@ -339,4 +338,5 @@ int main(int argc, char **argv) } return err; } +// LCOV_EXCL_STOP #endif |