diff --git a/regress/hostkey-agent.sh b/regress/hostkey-agent.sh index fddb0415b..c007d7a5e 100644 --- a/regress/hostkey-agent.sh +++ b/regress/hostkey-agent.sh @@ -1,4 +1,4 @@ -# $OpenBSD: hostkey-agent.sh,v 1.3 2015/01/20 08:02:33 djm Exp $ +# $OpenBSD: hostkey-agent.sh,v 1.4 2015/01/27 12:01:36 djm Exp $ # Placed in the Public Domain. tid="hostkey agent" @@ -17,7 +17,7 @@ trace "load hostkeys" for k in `${SSH} -Q key-plain` ; do ${SSHKEYGEN} -qt $k -f $OBJ/agent-key.$k -N '' || fatal "ssh-keygen $k" ( - echo -n 'localhost-with-alias,127.0.0.1,::1 ' + printf 'localhost-with-alias,127.0.0.1,::1 ' cat $OBJ/agent-key.$k.pub ) >> $OBJ/known_hosts.orig ${SSHADD} $OBJ/agent-key.$k >/dev/null 2>&1 || \ diff --git a/regress/keygen-knownhosts.sh b/regress/keygen-knownhosts.sh index 35a5ea499..085aac650 100644 --- a/regress/keygen-knownhosts.sh +++ b/regress/keygen-knownhosts.sh @@ -1,4 +1,4 @@ -# $OpenBSD: keygen-knownhosts.sh,v 1.1 2015/01/18 22:00:18 djm Exp $ +# $OpenBSD: keygen-knownhosts.sh,v 1.2 2015/01/27 12:01:36 djm Exp $ # Placed in the Public Domain. tid="ssh-keygen known_hosts" @@ -13,13 +13,13 @@ for x in host-a host-b host-c host-d host-e host-f host-a2 host-b2; do echo "# $x" >> $OBJ/kh.hosts ( case "$x" in - host-a|host-b) echo -n "$x " ;; - host-c) echo -n "@cert-authority $x " ;; - host-d) echo -n "@revoked $x " ;; - host-e) echo -n "host-e* " ;; - host-f) echo -n "host-f,host-g,host-h " ;; - host-a2) echo -n "host-a " ;; - host-b2) echo -n "host-b " ;; + host-a|host-b) printf "$x " ;; + host-c) printf "@cert-authority $x " ;; + host-d) printf "@revoked $x " ;; + host-e) printf "host-e* " ;; + host-f) printf "host-f,host-g,host-h " ;; + host-a2) printf "host-a " ;; + host-b2) printf "host-b " ;; esac cat $OBJ/kh.${x}.pub # Blank line should be preserved. @@ -47,7 +47,7 @@ expect_key() { test "x$_mark" = "xREVOKED" && _marker="@revoked " test "x$_line" != "x" && echo "# Host $_host found: line $_line $_mark" >> $OBJ/kh.expect - echo -n "${_marker}$_hosts " >> $OBJ/kh.expect + printf "${_marker}$_hosts " >> $OBJ/kh.expect cat $OBJ/kh.${_key}.pub >> $OBJ/kh.expect || fatal "${_key}.pub missing" }