summaryrefslogtreecommitdiff
path: root/regress/usr.bin/ssh/unittests
diff options
context:
space:
mode:
authorDamien Miller <djm@cvs.openbsd.org>2015-03-31 22:59:02 +0000
committerDamien Miller <djm@cvs.openbsd.org>2015-03-31 22:59:02 +0000
commitbad9762f95efca45de418edeb971b6b7a2b0ed2f (patch)
tree84547eb87c8308ab509e9d81ad387ed3c4ae1de6 /regress/usr.bin/ssh/unittests
parent5d55c3614b5027a03266e6bac9ddd5163b19f3b8 (diff)
adapt to recent hostfile.c change: when parsing known_hosts without
fully parsing the keys therein, hostkeys_foreach() will now correctly identify KEY_RSA1 keys; ok markus@ miod@
Diffstat (limited to 'regress/usr.bin/ssh/unittests')
-rw-r--r--regress/usr.bin/ssh/unittests/hostkeys/test_iterate.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/regress/usr.bin/ssh/unittests/hostkeys/test_iterate.c b/regress/usr.bin/ssh/unittests/hostkeys/test_iterate.c
index d23c852e22e..ecf95d05b15 100644
--- a/regress/usr.bin/ssh/unittests/hostkeys/test_iterate.c
+++ b/regress/usr.bin/ssh/unittests/hostkeys/test_iterate.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: test_iterate.c,v 1.3 2015/03/07 04:41:48 djm Exp $ */
+/* $OpenBSD: test_iterate.c,v 1.4 2015/03/31 22:59:01 djm Exp $ */
/*
* Regress test for hostfile.h hostkeys_foreach()
*
@@ -87,8 +87,8 @@ check(struct hostkey_foreach_line *l, void *_ctx)
expected->l.keytype : expected->no_parse_keytype;
#ifndef WITH_SSH1
- if (expected->l.keytype == KEY_RSA1 ||
- expected->no_parse_keytype == KEY_RSA1) {
+ if (parse_key && (expected->l.keytype == KEY_RSA1 ||
+ expected->no_parse_keytype == KEY_RSA1)) {
expected_status = HKF_STATUS_INVALID;
expected_keytype = KEY_UNSPEC;
parse_key = 0;