glusterfs
glusterfs copied to clipboard
checksum.c: Use the EVP API to compute the MD5 checksum
As MD5 function has been marked as deprecated in OpenSSL 3.0, this change uses EVP (Envelope) API to compute the MD5 checksum. Reference: https://www.openssl.org/docs/man1.0.2/man3/EVP_md5.html
Fixes: #4243
CLANG-FORMAT FAILURE: Before merging the patch, this diff needs to be considered for passing clang-format
index 74a3a0cb7..2c8ffa691 100644
--- a/libglusterfs/src/checksum.c
+++ b/libglusterfs/src/checksum.c
@@ -41,7 +41,7 @@ void
gf_rsync_md5_checksum(unsigned char *data, size_t len, unsigned char *md5)
{
EVP_MD_CTX *mdctx;
- const EVP_MD *md = EVP_md5(); // Use the MD5 digest algorithm
+ const EVP_MD *md = EVP_md5(); // Use the MD5 digest algorithm
mdctx = EVP_MD_CTX_new();
EVP_DigestInit_ex(mdctx, md, NULL);
/recheck smoke
/recheck smoke