/* * Copyright (c) 2023, yzrh * * SPDX-License-Identifier: Apache-2.0 */ #include #include int strmd5(unsigned char **dst, int *dst_size, const unsigned char * restrict src, int src_size) { *dst_size = MD5_DIGEST_LENGTH; *dst = malloc(*dst_size); if (*dst == NULL) return 1; MD5(src, src_size, *dst); return 0; }