diff options
author | Shane Lontis <shane.lontis@oracle.com> | 2021-03-09 11:53:33 +1000 |
---|---|---|
committer | Shane Lontis <shane.lontis@oracle.com> | 2021-03-18 17:52:37 +1000 |
commit | 8a6e9125200223fa2294d3634d3dfec24857264b (patch) | |
tree | 456f123f76f8d213acc195450d4a8502cd2fda23 /crypto/sm4 | |
parent | 7bbadfc15a446134d15d8fd0aa5362628b8c96be (diff) | |
download | openssl-new-8a6e9125200223fa2294d3634d3dfec24857264b.tar.gz |
Add ossl_ symbols for sm3 and sm4
Partial fix for #12964
Reviewed-by: Paul Dale <pauli@openssl.org>
(Merged from https://github.com/openssl/openssl/pull/14473)
Diffstat (limited to 'crypto/sm4')
-rw-r--r-- | crypto/sm4/sm4.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/crypto/sm4/sm4.c b/crypto/sm4/sm4.c index a62993c272..5e525d96e5 100644 --- a/crypto/sm4/sm4.c +++ b/crypto/sm4/sm4.c @@ -129,7 +129,7 @@ static ossl_inline uint32_t SM4_T(uint32_t X) rotl(SM4_SBOX_T[(uint8_t)X], 8); } -int SM4_set_key(const uint8_t *key, SM4_KEY *ks) +int ossl_sm4_set_key(const uint8_t *key, SM4_KEY *ks) { /* * Family Key @@ -184,7 +184,7 @@ int SM4_set_key(const uint8_t *key, SM4_KEY *ks) B3 ^= F(B0 ^ B1 ^ B2 ^ ks->rk[k3]); \ } while(0) -void SM4_encrypt(const uint8_t *in, uint8_t *out, const SM4_KEY *ks) +void ossl_sm4_encrypt(const uint8_t *in, uint8_t *out, const SM4_KEY *ks) { uint32_t B0 = load_u32_be(in, 0); uint32_t B1 = load_u32_be(in, 1); @@ -210,7 +210,7 @@ void SM4_encrypt(const uint8_t *in, uint8_t *out, const SM4_KEY *ks) store_u32_be(B0, out + 12); } -void SM4_decrypt(const uint8_t *in, uint8_t *out, const SM4_KEY *ks) +void ossl_sm4_decrypt(const uint8_t *in, uint8_t *out, const SM4_KEY *ks) { uint32_t B0 = load_u32_be(in, 0); uint32_t B1 = load_u32_be(in, 1); |