From de5891815932de36675e2f49faef3cbd7b479b96 Mon Sep 17 00:00:00 2001 From: Liong Sauw Ming Date: Mon, 8 Aug 2016 09:09:29 +0000 Subject: Re #1943: AES-GCM crypto support for SRTP Special thanks to Alexander Traud for the patch. git-svn-id: http://svn.pjsip.org/repos/pjproject/trunk@5412 74dad513-b988-da41-8d7b-12977e46ad98 --- aconfigure.ac | 10 ++++++++++ 1 file changed, 10 insertions(+) (limited to 'aconfigure.ac') diff --git a/aconfigure.ac b/aconfigure.ac index 4ea4d498..795c6e4e 100644 --- a/aconfigure.ac +++ b/aconfigure.ac @@ -1575,6 +1575,7 @@ fi dnl # Include SSL support AC_SUBST(ac_no_ssl) +AC_SUBST(ac_ssl_has_aes_gcm,0) AC_ARG_ENABLE(ssl, AS_HELP_STRING([--disable-ssl], [Exclude SSL support the build (default: autodetect)]) @@ -1600,6 +1601,15 @@ AC_ARG_ENABLE(ssl, AC_CHECK_LIB(ssl,SSL_library_init,[libssl_present=1 && LIBS="-lssl $LIBS"]) if test "x$openssl_h_present" = "x1" -a "x$libssl_present" = "x1" -a "x$libcrypto_present" = "x1"; then AC_MSG_RESULT([OpenSSL library found, SSL support enabled]) + + # Check if SRTP should be compiled with OpenSSL + # support, to enable cryptos such as AES GCM AC_CHECK_LIB(crypto,EVP_aes_128_gcm,[ac_ssl_has_aes_gcm=1]) + if test "x$ac_ssl_has_aes_gcm" = "x1"; then + AC_MSG_RESULT([OpenSSL has AES GCM support, SRTP will use OpenSSl version]) + else + AC_MSG_RESULT([OpenSSL AES GCM support not found, SRTP will only support AES CM cryptos]) + fi + # PJSIP_HAS_TLS_TRANSPORT setting follows PJ_HAS_SSL_SOCK #AC_DEFINE(PJSIP_HAS_TLS_TRANSPORT, 1) AC_DEFINE(PJ_HAS_SSL_SOCK, 1) -- cgit v1.2.3