add CBC-MAC and GM OTP, not tested

This commit is contained in:
Zhi Guan
2016-05-15 20:21:51 +02:00
parent 8c0439e7d6
commit 60d14da0cc
81 changed files with 2789 additions and 1401 deletions

View File

@@ -64,8 +64,7 @@
x4 = S32(x4); \
x4 = x0 ^ L32(x4)
void sms4_encrypt(sms4_key_t *key, const unsigned char *in, unsigned char *out)
void sms4_encrypt(const unsigned char *in, unsigned char *out, const sms4_key_t *key)
{
uint32_t *rk = key->rk;
uint32_t x0, x1, x2, x3, x4;