summaryrefslogtreecommitdiffstats
path: root/lib/libssl/s3_lib.c
diff options
context:
space:
mode:
authorjsing <jsing@openbsd.org>2017-02-05 15:06:05 +0000
committerjsing <jsing@openbsd.org>2017-02-05 15:06:05 +0000
commit468e1c0804880b3725b4861ba8f64e2788ed8ece (patch)
tree950edf1579a369a2d3268bf9402a5b4af665e190 /lib/libssl/s3_lib.c
parentRename rootpass to _rootpass and localize it together with _rootkey. (diff)
downloadwireguard-openbsd-468e1c0804880b3725b4861ba8f64e2788ed8ece.tar.xz
wireguard-openbsd-468e1c0804880b3725b4861ba8f64e2788ed8ece.zip
Define values for SSL_CTRL_SET_GROUPS{,_LIST} and wire them up to the
SSL_{,CTX_}ctrl() functions. As crazy as it is, some software appears to call the control functions directly rather than using the macros (or functions) provided by the library. Discussed with beck@ and sthen@
Diffstat (limited to 'lib/libssl/s3_lib.c')
-rw-r--r--lib/libssl/s3_lib.c14
1 files changed, 13 insertions, 1 deletions
diff --git a/lib/libssl/s3_lib.c b/lib/libssl/s3_lib.c
index 108cc9f71e5..fbc2d511d3a 100644
--- a/lib/libssl/s3_lib.c
+++ b/lib/libssl/s3_lib.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: s3_lib.c,v 1.133 2017/01/26 12:16:13 beck Exp $ */
+/* $OpenBSD: s3_lib.c,v 1.134 2017/02/05 15:06:05 jsing Exp $ */
/* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com)
* All rights reserved.
*
@@ -2135,6 +2135,12 @@ ssl3_ctrl(SSL *s, int cmd, long larg, void *parg)
ret = 1;
break;
+ case SSL_CTRL_SET_GROUPS:
+ return SSL_set1_groups(s, parg, larg);
+
+ case SSL_CTRL_SET_GROUPS_LIST:
+ return SSL_set1_groups_list(s, parg);
+
case SSL_CTRL_GET_SERVER_TMP_KEY:
ret = ssl_ctrl_get_server_tmp_key(s, parg);
break;
@@ -2315,6 +2321,12 @@ ssl3_ctx_ctrl(SSL_CTX *ctx, int cmd, long larg, void *parg)
ctx->extra_certs = NULL;
break;
+ case SSL_CTRL_SET_GROUPS:
+ return SSL_CTX_set1_groups(ctx, parg, larg);
+
+ case SSL_CTRL_SET_GROUPS_LIST:
+ return SSL_CTX_set1_groups_list(ctx, parg);
+
default:
return (0);
}