diff options
author | Leif Johansson <leifj@sunet.se> | 2015-08-21 14:45:27 +0200 |
---|---|---|
committer | Leif Johansson <leifj@sunet.se> | 2015-08-21 14:45:27 +0200 |
commit | 63e3ebb09ceef992671129978846552e62df12e6 (patch) | |
tree | e66f86c8c8e6f41fd3aa50382c3198927fa82556 /scripts | |
parent | deee49e7b5e8b6e773a2a200c2bca4729f6970a2 (diff) |
a couple of tools...
Diffstat (limited to 'scripts')
-rwxr-xr-x | scripts/cert-retrieve.sh | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/scripts/cert-retrieve.sh b/scripts/cert-retrieve.sh new file mode 100755 index 00000000..5440b0f8 --- /dev/null +++ b/scripts/cert-retrieve.sh @@ -0,0 +1,8 @@ +#!/bin/sh +# +# usage: retrieve-cert.sh remote.host.name [port] +# +REMHOST=$1 +REMPORT=${2:-443} + +echo | openssl s_client -connect ${REMHOST}:${REMPORT} 2>&1 | sed -ne '/-BEGIN CERTIFICATE-/,/-END CERTIFICATE-/p' |