lcp / mokutil

The utility to manipulate machine owner keys
GNU General Public License v3.0
69 stars 37 forks source link

efi_x509: use EVP_Digest()* functions instead of the deprecated SHA1_*() #39

Closed martinezjavier closed 3 years ago

martinezjavier commented 3 years ago

The SHA1_*() functions have been deprecated since OpenSSL 3.0, this leads to compile errors when building with -Werror=deprecated-declarations, i.e:

... mokutil.c: In function 'print_x509': mokutil.c:424:9: error: 'SHA1_Init' is deprecated: Since OpenSSL 3.0 [-Werror=deprecated-declarations] 424 | SHA1_Init (&ctx); | ^~~~~ ...

instead, the EVP_Digest*() functions could be used. Port to them and avoid these build failures with the latest OpenSSL 3.0 version.

Signed-off-by: Javier Martinez Canillas javierm@redhat.com

lcp commented 3 years ago

LGTM