summaryrefslogtreecommitdiff
path: root/src/lib/libtls/tls_config.c
diff options
context:
space:
mode:
authorjsing <>2015-02-11 06:46:33 +0000
committerjsing <>2015-02-11 06:46:33 +0000
commitc6f3fe1fbc8da2fa6de30b10f1f219ab1f809438 (patch)
tree6438c97ac6c93d27e53440f04e1fb34004f999b8 /src/lib/libtls/tls_config.c
parent01fabf00f34c0ca7466352b13f7071a4170301fc (diff)
downloadopenbsd-c6f3fe1fbc8da2fa6de30b10f1f219ab1f809438.tar.gz
openbsd-c6f3fe1fbc8da2fa6de30b10f1f219ab1f809438.tar.bz2
openbsd-c6f3fe1fbc8da2fa6de30b10f1f219ab1f809438.zip
Be consistent with naming - only use "host" and "hostname" when referring
to an actual host and use "servername" when referring to the name of the TLS server that we expect to be indentified in the server certificate. Likewise, rename verify_host to verify_name and use the term "name" throughout the verification code (rather than host or hostname). Requested by and ok tedu@
Diffstat (limited to 'src/lib/libtls/tls_config.c')
-rw-r--r--src/lib/libtls/tls_config.c7
1 files changed, 4 insertions, 3 deletions
diff --git a/src/lib/libtls/tls_config.c b/src/lib/libtls/tls_config.c
index 7697fa6ee8..116cde8297 100644
--- a/src/lib/libtls/tls_config.c
+++ b/src/lib/libtls/tls_config.c
@@ -1,4 +1,4 @@
1/* $OpenBSD: tls_config.c,v 1.3 2015/02/07 06:19:26 jsing Exp $ */ 1/* $OpenBSD: tls_config.c,v 1.4 2015/02/11 06:46:33 jsing Exp $ */
2/* 2/*
3 * Copyright (c) 2014 Joel Sing <jsing@openbsd.org> 3 * Copyright (c) 2014 Joel Sing <jsing@openbsd.org>
4 * 4 *
@@ -208,10 +208,11 @@ tls_config_set_verify_depth(struct tls_config *config, int verify_depth)
208 config->verify_depth = verify_depth; 208 config->verify_depth = verify_depth;
209} 209}
210 210
211/* XXX - rename to noverifyname. */
211void 212void
212tls_config_insecure_noverifyhost(struct tls_config *config) 213tls_config_insecure_noverifyhost(struct tls_config *config)
213{ 214{
214 config->verify_host = 0; 215 config->verify_name = 0;
215} 216}
216 217
217void 218void
@@ -223,6 +224,6 @@ tls_config_insecure_noverifycert(struct tls_config *config)
223void 224void
224tls_config_verify(struct tls_config *config) 225tls_config_verify(struct tls_config *config)
225{ 226{
226 config->verify_host = 1;
227 config->verify_cert = 1; 227 config->verify_cert = 1;
228 config->verify_name = 1;
228} 229}