Skip to content

Commit

Permalink
Fix build since openssl 1.1.0 when ECDSA and/or RIPEMD are disabled (l…
Browse files Browse the repository at this point in the history
…ibssh2#666)

File: openssl.h

Notes:
In openssl 1.1.0 and later openssl decided to change some of the defines used to check if certain features are not compiled in the libraries. This updates the define checks.

Credit:
Harry Sintonen
Co-authored-by: Harry Sintonen <[email protected]>
  • Loading branch information
piru and Harry Sintonen authored Apr 5, 2022
1 parent 79855b3 commit b95e758
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/openssl.h
Original file line number Diff line number Diff line change
Expand Up @@ -115,7 +115,7 @@
# define LIBSSH2_DSA 1
#endif

#ifdef OPENSSL_NO_ECDSA
#if defined(OPENSSL_NO_ECDSA) || defined(OPENSSL_NO_EC)
# define LIBSSH2_ECDSA 0
#else
# define LIBSSH2_ECDSA 1
Expand All @@ -135,7 +135,7 @@
# define LIBSSH2_MD5 1
#endif

#ifdef OPENSSL_NO_RIPEMD
#if defined(OPENSSL_NO_RIPEMD) || defined(OPENSSL_NO_RMD160)
# define LIBSSH2_HMAC_RIPEMD 0
#else
# define LIBSSH2_HMAC_RIPEMD 1
Expand Down

0 comments on commit b95e758

Please sign in to comment.