OKlibrary  0.2.1.6
ConstraintTemplateRewriteRules.mac
Go to the documentation of this file.
00001 /* Matthew Gwynne, 28.9.2008 (Swansea) */
00002 /* Copyright 2008, 2009, 2010, 2011 Oliver Kullmann
00003 This file is part of the OKlibrary. OKlibrary is free software; you can redistribute
00004 it and/or modify it under the terms of the GNU General Public License as published by
00005 the Free Software Foundation and included in this library; either version 3 of the
00006 License, or any later version. */
00007 
00022 oklib_include("OKlib/ComputerAlgebra/Cryptology/Lisp/Cryptanalysis/Rijndael/ConstraintTemplateRewriteRules.mac")$
00023 oklib_include("OKlib/ComputerAlgebra/Cryptology/Lisp/Cryptanalysis/Rijndael/tests/ConstraintTemplateRewriteRules.mac")$
00024 
00025 
00026 /* ***********************************************
00027    * Constraint template rewrite translation     *
00028    ***********************************************
00029 */
00030 
00031 oktest_generate_aes_constraint_vars(generate_aes_constraint_vars);
00032 
00033 
00034 /* ***********************************************
00035    * Constraint template rewrite functions       *
00036    ***********************************************
00037 */
00038 
00039 okltest_aes_ns_var_l(aes_ns_var_l);
00040 okltest_aes_cstr_cstl(aes_cstr_cstl);
00041 
00042 okltest_aes_round_ns_var_l(aes_round_ns_var_l);
00043 okltest_aes_round_cstr_cstl(aes_round_cstr_cstl);
00044 
00045 okltest_aes_final_round_ns_var_l(aes_final_round_ns_var_l);
00046 okltest_aes_final_round_cstr_cstl(aes_final_round_cstr_cstl);
00047 
00048 okltest_aes_subbytes_ns_var_l(aes_subbytes_ns_var_l);
00049 okltest_aes_subbytes_cstr_cstl(aes_subbytes_cstr_cstl);
00050 
00051 okltest_aes_shiftrows_ns_var_l(aes_shiftrows_ns_var_l);
00052 okltest_aes_shiftrows_cstr_cstl(aes_shiftrows_cstr_cstl);
00053 
00054 okltest_aes_mixcolumns_ns_var_l(aes_mixcolumns_ns_var_l);
00055 okltest_aes_mixcolumns_cstr_cstl(aes_mixcolumns_cstr_cstl);
00056 
00057 
00058 okltest_aes_bi_mixcolumn_ns_var_l(aes_bi_mixcolumn_ns_var_l);
00059 okltest_aes_mixcolumn_ns_var_l(aes_mixcolumn_ns_var_l);
00060 okltest_aes_inv_mixcolumn_ns_var_l(aes_inv_mixcolumn_ns_var_l);
00061 okltest_aes_bi_mixcolumn_cstr_cstl(aes_bi_mixcolumn_cstr_cstl);
00062 okltest_aes_mixcolumn_cstr_cstl(aes_mixcolumn_cstr_cstl);
00063 
00064 okltest_aes_key_expansion_ns_var_l(aes_key_expansion_ns_var_l);
00065 okltest_aes_key_expansion_cstr_cstl(aes_key_expansion_cstr_cstl);
00066 
00067 
00068 /* ****************************************
00069    * Translation functions                *
00070    ****************************************
00071 */
00072 
00073 okltest_aes_add_cst_cl(aes_add_cst_cl);
00074 okltest_aes_eq_cst_cl(aes_eq_cst_cl);
00075 okltest_aes_const_cst_cl(aes_const_cst_cl);
00076 
00077 okltest_aes_sbox_pi_cst_cl(aes_sbox_pi_cst_cl);
00078 okltest_aes_sbox_ts_var_l(aes_sbox_ts_var_l);
00079 okltest_aes_sbox_ts_cst_cl(aes_sbox_ts_cst_cl);
00080 
00081 okltest_aes_mul2_pi_cst_cl(aes_mul2_pi_cst_cl);
00082 okltest_aes_mul2_ts_var_l(aes_mul2_ts_var_l);
00083 okltest_aes_mul2_ts_cst_cl(aes_mul2_ts_cst_cl);
00084 
00085 /* okltest_aes_mul3_pi_cst_cl(aes_mul3_pi_cst_cl); TEST FAILURE */
00086 okltest_aes_mul3_ts_var_l(aes_mul3_ts_var_l);
00087 okltest_aes_mul3_ts_cst_cl(aes_mul3_ts_cst_cl);
00088 
00089 okltest_aes_mul14_pi_cst_cl(aes_mul14_pi_cst_cl);
00090 okltest_aes_mul14_ts_var_l(aes_mul14_ts_var_l);
00091 okltest_aes_mul14_ts_cst_cl(aes_mul14_ts_cst_cl);
00092 
00093 okltest_aes_mul11_pi_cst_cl(aes_mul11_pi_cst_cl);
00094 okltest_aes_mul11_ts_var_l(aes_mul11_ts_var_l);
00095 okltest_aes_mul11_ts_cst_cl(aes_mul11_ts_cst_cl);
00096 
00097 okltest_aes_mul13_pi_cst_cl(aes_mul13_pi_cst_cl);
00098 okltest_aes_mul13_ts_var_l(aes_mul13_ts_var_l);
00099 okltest_aes_mul13_ts_cst_cl(aes_mul13_ts_cst_cl);
00100 
00101 okltest_aes_mul9_pi_cst_cl(aes_mul9_pi_cst_cl);
00102 okltest_aes_mul9_ts_var_l(aes_mul9_ts_var_l);
00103 okltest_aes_mul9_ts_cst_cl(aes_mul9_ts_cst_cl);
00104 
00105