mybin

my ~/bin
git clone https://a3nm.net/git/mybin/
Log | Files | Refs | README

commit 084fbb4cb976a48c7f2a7e57901f3259043add36
parent 494c8bb6e66b5fe72c50fdba2738d464a28a8068
Author: Antoine Amarilli <a3nm@a3nm.net>
Date:   Sun,  5 May 2024 16:09:44 +0200

silence warnings about stdin

cf https://github.com/openssl/openssl/issues/22893

Diffstat:
ssleft | 4++--
1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/ssleft b/ssleft @@ -11,7 +11,7 @@ MARGIN_S=$((24*60*60 * $MARGIN)) CERT=$(echo | openssl s_client -connect $HOST:$PORT -servername $HOST 2>/dev/null) -DATES=$(echo "$CERT" | openssl x509 -noout -dates) +DATES=$(echo "$CERT" | openssl x509 -noout -dates -in /dev/stdin) if [[ $MARGIN -eq 0 ]] then @@ -20,7 +20,7 @@ then exit 0 fi -if ! (echo "$CERT" | openssl x509 -noout -checkend $MARGIN_S >/dev/null) +if ! (echo "$CERT" | openssl x509 -noout -checkend $MARGIN_S -in /dev/stdin >/dev/null) then echo "== cert for $HOST:$PORT will expire in <= $MARGIN days ==" echo "details of cert are:"