diff options
Diffstat (limited to 'regress/ssh2putty.sh')
-rwxr-xr-x | regress/ssh2putty.sh | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/regress/ssh2putty.sh b/regress/ssh2putty.sh index dcb975d9..b89c1b2b 100755 --- a/regress/ssh2putty.sh +++ b/regress/ssh2putty.sh @@ -1,5 +1,5 @@ #!/bin/sh -# $OpenBSD: ssh2putty.sh,v 1.5 2019/11/21 05:18:47 tb Exp $ +# $OpenBSD: ssh2putty.sh,v 1.6 2021/05/24 10:25:18 dtucker Exp $ if test "x$1" = "x" -o "x$2" = "x" -o "x$3" = "x" ; then echo "Usage: ssh2putty hostname port ssh-private-key" @@ -19,13 +19,13 @@ else fi public_exponent=` - openssl rsa -noout -text -in $KEYFILE | grep ^publicExponent | + $OPENSSL rsa -noout -text -in $KEYFILE | grep ^publicExponent | sed 's/.*(//;s/).*//' ` test $? -ne 0 && exit 1 modulus=` - openssl rsa -noout -modulus -in $KEYFILE | grep ^Modulus= | + $OPENSSL rsa -noout -modulus -in $KEYFILE | grep ^Modulus= | sed 's/^Modulus=/0x/' | tr A-Z a-z ` test $? -ne 0 && exit 1 |