diff --git a/sk-usbhid.c b/sk-usbhid.c index 2fdf3d94f..01412b697 100644 --- a/sk-usbhid.c +++ b/sk-usbhid.c @@ -31,6 +31,15 @@ #include #endif +/* + * Almost every use of OpenSSL in this file is for ECDSA-NISTP256. + * This is strictly a larger hammer than necessary, but it reduces changes + * with upstream. + */ +#ifndef OPENSSL_HAS_ECC +# undef WITH_OPENSSL +#endif + #ifdef WITH_OPENSSL #include #include diff --git a/ssh-sk.c b/ssh-sk.c index d254e77f9..393b4ccdd 100644 --- a/ssh-sk.c +++ b/ssh-sk.c @@ -29,10 +29,10 @@ #include #include -#ifdef WITH_OPENSSL +#if defined(WITH_OPENSSL) && defined(OPENSSL_HAS_ECC) #include #include -#endif /* WITH_OPENSSL */ +#endif /* WITH_OPENSSL && OPENSSL_HAS_ECC */ #include "log.h" #include "misc.h" @@ -45,6 +45,15 @@ #include "sk-api.h" #include "crypto_api.h" +/* + * Almost every use of OpenSSL in this file is for ECDSA-NISTP256. + * This is strictly a larger hammer than necessary, but it reduces changes + * with upstream. + */ +#ifndef OPENSSL_HAS_ECC +# undef WITH_OPENSSL +#endif + struct sshsk_provider { char *path; void *dlhandle;