[openssh-commits] [openssh] 02/02: upstream commit
git+noreply at mindrot.org
git+noreply at mindrot.org
Wed Mar 4 04:54:36 AEDT 2015
This is an automated email from the git hooks/post-receive script.
djm pushed a commit to branch master
in repository openssh.
commit d608a51daad4f14ad6ab43d7cf74ef4801cc3fe9
Author: djm at openbsd.org <djm at openbsd.org>
Date: Tue Mar 3 17:53:40 2015 +0000
upstream commit
reorder logic for better portability; patch from Roumen
Petrov
---
regress/hostkey-rotate.sh | 9 ++++-----
1 file changed, 4 insertions(+), 5 deletions(-)
diff --git a/regress/hostkey-rotate.sh b/regress/hostkey-rotate.sh
index d964b35..b5d542d 100644
--- a/regress/hostkey-rotate.sh
+++ b/regress/hostkey-rotate.sh
@@ -1,4 +1,4 @@
-# $OpenBSD: hostkey-rotate.sh,v 1.1 2015/01/26 06:12:18 djm Exp $
+# $OpenBSD: hostkey-rotate.sh,v 1.2 2015/03/03 17:53:40 djm Exp $
# Placed in the Public Domain.
tid="hostkey rotate"
@@ -38,11 +38,10 @@ expect_nkeys() {
check_key_present() {
_type=$1
_kfile=$2
- _prog='print $2 " " $3'
test "x$_kfile" = "x" && _kfile="$OBJ/hkr.${_type}.pub"
- _ktext=`awk "/ $_type / { $_prog }" < $OBJ/known_hosts` || \
+ _kpub=`awk "/$_type /"' { print $2 }' < $_kfile` || \
fatal "awk failed"
- grep -q "$_ktext" $_kfile
+ fgrep "$_kpub" $OBJ/known_hosts > /dev/null
}
cp $OBJ/sshd_proxy.orig $OBJ/sshd_proxy
@@ -110,7 +109,7 @@ dossh -oStrictHostKeyChecking=yes -oHostKeyAlgorithms=ssh-rsa
expect_nkeys 1 "learn hostkeys"
check_key_present ssh-rsa || fail "didn't learn changed key"
-# $OpenBSD: hostkey-rotate.sh,v 1.1 2015/01/26 06:12:18 djm Exp $
+# $OpenBSD: hostkey-rotate.sh,v 1.2 2015/03/03 17:53:40 djm Exp $
# Placed in the Public Domain.
tid="hostkey rotate"
--
To stop receiving notification emails like this one, please contact
djm at mindrot.org.
More information about the openssh-commits
mailing list