fa5ee7998b
from brad
21 lines
680 B
Plaintext
21 lines
680 B
Plaintext
$OpenBSD: patch-src_ne_openssl_c,v 1.3 2012/06/27 12:10:19 jasper Exp $
|
|
|
|
Allow building against OpenSSL without SSLv2 support.
|
|
|
|
--- src/ne_openssl.c.orig Wed Jun 27 07:35:42 2012
|
|
+++ src/ne_openssl.c Wed Jun 27 07:47:58 2012
|
|
@@ -569,8 +569,13 @@ ne_ssl_context *ne_ssl_context_create(int mode)
|
|
ctx->ctx = SSL_CTX_new(SSLv23_server_method());
|
|
SSL_CTX_set_session_cache_mode(ctx->ctx, SSL_SESS_CACHE_CLIENT);
|
|
} else {
|
|
+#ifdef OPENSSL_NO_SSL2
|
|
+ ne_free(ctx);
|
|
+ return NULL;
|
|
+#else
|
|
ctx->ctx = SSL_CTX_new(SSLv2_server_method());
|
|
SSL_CTX_set_session_cache_mode(ctx->ctx, SSL_SESS_CACHE_CLIENT);
|
|
+#endif
|
|
}
|
|
return ctx;
|
|
}
|