EVP_SM3(3ossl)

πŸ“¦ version 3.5.0, in opensuse-leap 16.0

πŸ’œ EVP_SM3 β€” the SM3 tea, explained

okay so bestie, this is the OpenSSL manual page for EVP_sm3 β€” she's a little function that hands you the SM3 hash like it's nothing, and honestly? iconic. Manual name is EVP_SM3(3ossl), so if you're citing her, that's the vibe. ✨


🌸 SYNOPSIS

#include <openssl/evp.h>

const EVP_MD *EVP_sm3(void);

literally that's it. one include, one function, zero drama. πŸŽ€


πŸ¦‹ DESCRIPTION

So SM3 is a cryptographic hash function with a 256-bit output, and she's defined in GB/T 32905-2016. That's it, that's the whole girl. 🌈

  • EVP_sm3() β€” this one is the SM3 hash function, like she didn't even need a glow-up. πŸ’…

🫢 NOTES

okay babes, listen, this part is important and I say it with love: developers should be aware of the negative performance implications of calling this function multiple times, and should consider using EVP_MD_fetch(3) with EVP_MD-SM3(7) instead. πŸ’€

fr fr β€” like, cute of you to call EVP_sm3() in a loop, but she's not built for that. check out "Performance" in crypto(7) for further information. iykyk. ✨

πŸ‘‘ RETURN VALUES

these functions return an EVP_MD structure that contains the implementation of the message digest. like, she hands you the whole structure, not just a vibe. πŸ’–

if you're like "okay but what even is an EVP_MD structure", see EVP_MD_meth_new(3) for details of the EVP_MD structure. no cap, that's where the lore lives. πŸŽ€


⭐ CONFORMING TO

  • GB/T 32905-2016 β€” yes bestie, she conforms
  • GM/T 0004-2012 β€” and this one too, overachiever πŸ†

🌟 SEE ALSO

both of these are the supportive besties of this page, go read them. πŸ¦‹


Copyright 2017-2023 The OpenSSL Project Authors. All Rights Reserved. Copyright 2017 Ribose Inc. All Rights Reserved.

Licensed under the Apache License 2.0 (the "License"). You may not use this file except in compliance with the License. You can obtain a copy in the file LICENSE in the source distribution or at <https://www.openssl.org/source/license.html>.

like literally please respect the license, it's the bare minimum and it's giving main character energy to actually read it. πŸ’…

and that's the whole page!! πŸŒˆπŸŽ€ this one came from OpenSSL 3.5.0, dated 2026-09-25, EVP_SM3(3ossl) β€” periodt. πŸ’–βœ¨πŸ¦‹πŸŒΈ

πŸ“¦ where this page comes from