aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/src/box_aes.c
diff options
context:
space:
mode:
authorEgor Tensin <Egor.Tensin@gmail.com>2015-06-17 20:07:32 +0300
committerEgor Tensin <Egor.Tensin@gmail.com>2015-06-17 20:07:32 +0300
commit522a5b906d7620bcebddb5a8f476b022c140ab27 (patch)
tree8b02e4f5b5948da91e4117c6892d850eeeac8445 /src/box_aes.c
parentrefactoring (diff)
downloadaes-tools-522a5b906d7620bcebddb5a8f476b022c140ab27.tar.gz
aes-tools-522a5b906d7620bcebddb5a8f476b022c140ab27.zip
factoring out AES-specific stuff
Diffstat (limited to 'src/box_aes.c')
-rw-r--r--src/box_aes.c33
1 files changed, 33 insertions, 0 deletions
diff --git a/src/box_aes.c b/src/box_aes.c
new file mode 100644
index 0000000..5253415
--- /dev/null
+++ b/src/box_aes.c
@@ -0,0 +1,33 @@
+/**
+ * \file
+ * \author Egor Tensin <Egor.Tensin@gmail.com>
+ * \date 2015
+ * \copyright This file is licensed under the terms of the MIT License.
+ * See LICENSE.txt for details.
+ */
+
+#include <aesni/all.h>
+
+AesNI_BoxAlgorithmInterface aesni_box_aes128_iface =
+{
+ &aesni_box_derive_params_aes128,
+ &aesni_box_encrypt_aes128,
+ &aesni_box_decrypt_aes128,
+ &aesni_box_xor_block_aes,
+};
+
+AesNI_BoxAlgorithmInterface aesni_box_aes192_iface =
+{
+ &aesni_box_derive_params_aes192,
+ &aesni_box_encrypt_aes192,
+ &aesni_box_decrypt_aes192,
+ &aesni_box_xor_block_aes,
+};
+
+AesNI_BoxAlgorithmInterface aesni_box_aes256_iface =
+{
+ &aesni_box_derive_params_aes256,
+ &aesni_box_encrypt_aes256,
+ &aesni_box_decrypt_aes256,
+ &aesni_box_xor_block_aes,
+};