From 061d595d7859c456aec41e57ebdd900e4087395c Mon Sep 17 00:00:00 2001 From: bcook <> Date: Mon, 11 Aug 2014 13:29:43 +0000 Subject: Guard RSA / RC4-5 ASM when NO_ASM is not defined Most assembly blocks remain inactive if OPENSSL_NO_ASM is not defined, only enabling inline assembly, but the RSA / RC4-5 blocks (used only in amd64 systems) turn on implicitly. Guard these two as well. This simplifies enabling just inline ASM in portable, no effective change in OpenBSD. --- src/lib/libcrypto/engine/eng_rsax.c | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) (limited to 'src/lib/libcrypto/engine/eng_rsax.c') diff --git a/src/lib/libcrypto/engine/eng_rsax.c b/src/lib/libcrypto/engine/eng_rsax.c index 358dac2088..728b89d5f3 100644 --- a/src/lib/libcrypto/engine/eng_rsax.c +++ b/src/lib/libcrypto/engine/eng_rsax.c @@ -1,4 +1,4 @@ -/* $OpenBSD: eng_rsax.c,v 1.10 2014/07/12 16:03:37 miod Exp $ */ +/* $OpenBSD: eng_rsax.c,v 1.11 2014/08/11 13:29:43 bcook Exp $ */ /* Copyright (c) 2010-2010 Intel Corp. * Author: Vinodh.Gopal@intel.com * Jim Guilford @@ -81,8 +81,9 @@ /* RSAX is available **ONLY* on x86_64 CPUs */ #undef COMPILE_RSAX -#if (defined(__x86_64) || defined(__x86_64__) || \ - defined(_M_AMD64) || defined (_M_X64)) && !defined(OPENSSL_NO_ASM) +#if !defined(OPENSSL_NO_ASM) && defined(RSA_ASM) && \ + (defined(__x86_64) || defined(__x86_64__) || \ + defined(_M_AMD64) || defined (_M_X64)) #define COMPILE_RSAX static ENGINE *ENGINE_rsax (void); #endif -- cgit v1.2.3-55-g6feb