aboutsummaryrefslogtreecommitdiffstats
path: root/lib/crypto/test
diff options
context:
space:
mode:
authorMagnus Henoch <[email protected]>2016-09-08 15:49:13 +0100
committerMagnus Henoch <[email protected]>2016-09-14 14:31:31 +0100
commit6b4cf6c5759d1f1f952708ab191f563175950aa0 (patch)
treeb6fe7af2e460b4c91c1f0dc144397e9257b71e7f /lib/crypto/test
parent176b7c94e4146a65ccd2bd729d58487098dddd9c (diff)
downloadotp-6b4cf6c5759d1f1f952708ab191f563175950aa0.tar.gz
otp-6b4cf6c5759d1f1f952708ab191f563175950aa0.tar.bz2
otp-6b4cf6c5759d1f1f952708ab191f563175950aa0.zip
Fix compilation when OpenSSL doesn't support RC2
When OpenSSL has been configured with the "no-rc2" option, the header file rc2.h doesn't exist, and neither does the function EVP_rc2_cbc. Let's handle those by checking whether OPENSSL_NO_RC2 is defined. Also update pbe_SUITE, which uses RC2-CBC in one of the tests.
Diffstat (limited to 'lib/crypto/test')
-rw-r--r--lib/crypto/test/old_crypto_SUITE.erl4
1 files changed, 3 insertions, 1 deletions
diff --git a/lib/crypto/test/old_crypto_SUITE.erl b/lib/crypto/test/old_crypto_SUITE.erl
index 4a6753b2ed..10a3e52f29 100644
--- a/lib/crypto/test/old_crypto_SUITE.erl
+++ b/lib/crypto/test/old_crypto_SUITE.erl
@@ -1080,7 +1080,9 @@ rc2_cbc(doc) ->
"Encrypt and decrypt according to RC2 CBC and check the result. "
"Example stripped out from public_key application test";
rc2_cbc(Config) when is_list(Config) ->
-
+ if_supported(rc2_cbc, fun rc2_cbc_do/0).
+
+rc2_cbc_do() ->
Key = <<146,210,160,124,215,227,153,239,227,17,222,140,3,93,27,191>>,
IV = <<72,91,135,182,25,42,35,210>>,