diff options
author | 2018-11-11 06:58:14 +0000 | |
---|---|---|
committer | 2018-11-11 06:58:14 +0000 | |
commit | ca8dce7b8c165d8c0f044643ba260fb1bfde0cda (patch) | |
tree | fb513a7aeb7a6e4a60c8ebb7a64917297bfa0a4b /lib/libssl/ssl_lib.c | |
parent | Add Ribose Inc's implementation of the SM3 hashing function with (diff) | |
download | wireguard-openbsd-ca8dce7b8c165d8c0f044643ba260fb1bfde0cda.tar.xz wireguard-openbsd-ca8dce7b8c165d8c0f044643ba260fb1bfde0cda.zip |
Add SSL_set1_host(), a thin wrapper around X509_VERIFY_PARAM_set1_host().
Used by unbound's DNS over TLS implementation to do server name
verification.
ok jsing
Diffstat (limited to 'lib/libssl/ssl_lib.c')
-rw-r--r-- | lib/libssl/ssl_lib.c | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/lib/libssl/ssl_lib.c b/lib/libssl/ssl_lib.c index 31d411c4292..66e14b98161 100644 --- a/lib/libssl/ssl_lib.c +++ b/lib/libssl/ssl_lib.c @@ -1,4 +1,4 @@ -/* $OpenBSD: ssl_lib.c,v 1.192 2018/11/10 01:19:09 beck Exp $ */ +/* $OpenBSD: ssl_lib.c,v 1.193 2018/11/11 06:58:14 tb Exp $ */ /* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com) * All rights reserved. * @@ -453,6 +453,12 @@ SSL_set_trust(SSL *s, int trust) return (X509_VERIFY_PARAM_set_trust(s->param, trust)); } +int +SSL_set1_host(SSL *s, const char *hostname) +{ + return X509_VERIFY_PARAM_set1_host(s->param, hostname, 0); +} + X509_VERIFY_PARAM * SSL_CTX_get0_param(SSL_CTX *ctx) { |