cyassl: add support for SSL_set_tlsext_host_name
authorJohn Crispin <john@openwrt.org>
Wed, 1 Apr 2015 10:42:28 +0000 (10:42 +0000)
committerJohn Crispin <john@openwrt.org>
Wed, 1 Apr 2015 10:42:28 +0000 (10:42 +0000)
Signed-off-by: John Crispin <blogic@openwrt.org>
SVN-Revision: 45215

package/libs/cyassl/Makefile
package/libs/cyassl/patches/300-SSL_set_tlsext_host_name.patch [new file with mode: 0644]

index a748adb..2be0198 100644 (file)
@@ -40,6 +40,8 @@ TARGET_CFLAGS += $(FPIC)
 CONFIGURE_ARGS += \
        --without-zlib \
        --enable-singlethreaded \
+       --enable-opensslextra \
+       --enable-sni \
        --disable-examples
 
 define Build/InstallDev
diff --git a/package/libs/cyassl/patches/300-SSL_set_tlsext_host_name.patch b/package/libs/cyassl/patches/300-SSL_set_tlsext_host_name.patch
new file mode 100644 (file)
index 0000000..d81e416
--- /dev/null
@@ -0,0 +1,10 @@
+--- a/cyassl/openssl/ssl.h
++++ b/cyassl/openssl/ssl.h
+@@ -372,6 +373,7 @@
+ #define SSL_CTX_get_ex_new_index CyaSSL_CTX_get_ex_new_index
++#define SSL_set_tlsext_host_name(x, y) CyaSSL_UseSNI(x, CYASSL_SNI_HOST_NAME, y, strlen(y))
+ #ifdef __cplusplus
+     } /* extern "C" */