EVP_SHA224(3ossl)
β¨ EVP_SHA224 β the SHA-2 glow-up, but for EVP β¨
okay bestie, welcome to the EVP_SHA224 page from the 3ossl manual π this is your group chat briefing on the whole SHA-2 family, so grab a strawberry π and let's get into it.
πΈ NAME πΈ
EVP_sha224, EVP_sha256, EVP_sha512_224, EVP_sha512_256, EVP_sha384, EVP_sha512 β SHA-2 For EVP. that's it, that's the whole vibe. six functions, one iconic family. π
π SYNOPSIS π
#include <openssl/evp.h>
const EVP_MD *EVP_sha224(void);
const EVP_MD *EVP_sha256(void);
const EVP_MD *EVP_sha512_224(void);
const EVP_MD *EVP_sha512_256(void);
const EVP_MD *EVP_sha384(void);
const EVP_MD *EVP_sha512(void);
no arguments, no drama, just vibes and a const EVP_MD * return. periodt. π
π¦ DESCRIPTION π¦
so. SHA-2. aka Secure Hash Algorithm 2. it's a whole family of cryptographic hash functions, standardized in NIST FIPS 180-4, and it first hit the scene in 2001. yes she's been that girl for decades. no cap. π
π the functions, one by one π
EVP_sha224(), EVP_sha256(), EVP_sha512_224, EVP_sha512_256, EVP_sha384(), EVP_sha512()
these are the SHA-2 algorithms SHA-224, SHA-256, SHA-512/224, SHA512/256, SHA-384 and SHA-512. and how many bits of output do they each squeeze out of a given input? literally in order: 224, 256, 224, 256, 384 and 512 bits respectively. slay. β¨
and now the plot twist that trips everyone up: those two, SHA-512/224 and SHA512/256? they're truncated forms of the SHA-512 algorithm. so even though their outputs are the same size as SHA-224 and SHA-256, they are distinct from them. do not mix them up, bestie, that's not the same algorithm just because the number matches. π
π«Ά NOTES π«Ά
okay listen, this is the part where I hold your hand. π₯Ί
developers should be aware of the negative performance implications of calling these functions multiple times. like, it's giving "why are you like this." instead, you should consider using EVP_MD_fetch(3) with EVP_MD-SHA2(7) instead. for further information, go peek at "Performance" in crypto(7). iykyk. π
fr fr, don't spam these calls when there's a fetch option sitting right there.
π RETURN VALUES π
these functions return an EVP_MD structure that contains the implementation of the message digest. wanna know the details of the EVP_MD structure? see EVP_MD_meth_new(3). she's got layers, and that page has them. π
π CONFORMING TO π
NIST FIPS 180-4. iconic standard behavior only. β
π₯ SEE ALSO π₯
go read them, they're part of the lore. π
π COPYRIGHT π
Copyright 2017-2023 The OpenSSL Project Authors. 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>.
that's the whole page bestie, and that's on periodt π π¦πΈ
OpenSSL 3.5.9 β dated 2026-09-29 β signing off from the EVP_SHA224(3ossl) page, mwah π
π¦ where this page comes from
- fedora 43: openssl-devel 1:3.5.9-1.fc43 Β· Apache-2.0
- fedora 43: openssl-devel 1:3.5.9-1.fc43 Β· Apache-2.0
- fedora 44: openssl-devel 1:3.5.9-1.fc44 Β· Apache-2.0
- fedora 44: openssl-devel 1:3.5.9-1.fc44 Β· Apache-2.0
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms