summaryrefslogtreecommitdiffstats
path: root/bin/hostcert
diff options
context:
space:
mode:
authorJesse Luehrs <doy@tozt.net>2017-01-16 07:32:44 -0500
committerJesse Luehrs <doy@tozt.net>2017-01-21 06:37:31 -0500
commitdc6416f8d45f02b5ba9e38a4236c1821a4cf596e (patch)
tree3594beb07b645598574622c9a6fe4a2b5351185d /bin/hostcert
parent37136d5493410cf2f5b72184f952794f33be566e (diff)
downloadconf-dc6416f8d45f02b5ba9e38a4236c1821a4cf596e.tar.gz
conf-dc6416f8d45f02b5ba9e38a4236c1821a4cf596e.zip
split most functions out into scripts
Diffstat (limited to 'bin/hostcert')
-rwxr-xr-xbin/hostcert3
1 files changed, 3 insertions, 0 deletions
diff --git a/bin/hostcert b/bin/hostcert
new file mode 100755
index 0000000..561244c
--- /dev/null
+++ b/bin/hostcert
@@ -0,0 +1,3 @@
+#!/bin/bash
+
+openssl s_client -connect "$1" < /dev/null 2>/dev/null | perl -nle 'print if /BEGIN CERTIFICATE/../END CERTIFICATE/' | openssl x509 -text | perl -nle 'print unless /BEGIN CERTIFICATE/../END CERTIFICATE/'