summaryrefslogtreecommitdiff
path: root/auth2-hostbased.c
diff options
context:
space:
mode:
authordjm@openbsd.org <djm@openbsd.org>2015-05-04 06:10:48 +0000
committerDamien Miller <djm@mindrot.org>2015-05-10 11:38:04 +1000
commite661a86353e11592c7ed6a847e19a83609f49e77 (patch)
tree5fe2c206d56dd4296a79e20ca6cfbbb83cb7c40c /auth2-hostbased.c
parent0ef1de742be2ee4b10381193fe90730925b7f027 (diff)
downloadopenssh-git-e661a86353e11592c7ed6a847e19a83609f49e77.tar.gz
upstream commit
Remove pattern length argument from match_pattern_list(), we only ever use it for strlen(pattern). Prompted by hanno AT hboeck.de pointing an out-of-bound read error caused by an incorrect pattern length found using AFL and his own tools. ok markus@
Diffstat (limited to 'auth2-hostbased.c')
-rw-r--r--auth2-hostbased.c5
1 files changed, 2 insertions, 3 deletions
diff --git a/auth2-hostbased.c b/auth2-hostbased.c
index eebfe8fc..e2327cf7 100644
--- a/auth2-hostbased.c
+++ b/auth2-hostbased.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: auth2-hostbased.c,v 1.24 2015/01/28 22:36:00 djm Exp $ */
+/* $OpenBSD: auth2-hostbased.c,v 1.25 2015/05/04 06:10:48 djm Exp $ */
/*
* Copyright (c) 2000 Markus Friedl. All rights reserved.
*
@@ -109,8 +109,7 @@ userauth_hostbased(Authctxt *authctxt)
goto done;
}
if (match_pattern_list(sshkey_ssh_name(key),
- options.hostbased_key_types,
- strlen(options.hostbased_key_types), 0) != 1) {
+ options.hostbased_key_types, 0) != 1) {
logit("%s: key type %s not in HostbasedAcceptedKeyTypes",
__func__, sshkey_type(key));
goto done;