revert
This commit is contained in:
1279
nodemgmt-scripts copy.sh
Executable file
1279
nodemgmt-scripts copy.sh
Executable file
File diff suppressed because it is too large
Load Diff
@@ -584,7 +584,6 @@ LISTCERTS(){
|
|||||||
echo -e "Subject Name Expires Alternate Subjects"
|
echo -e "Subject Name Expires Alternate Subjects"
|
||||||
DIVIDER
|
DIVIDER
|
||||||
for certdir in /etc/letsencrypt/live/*/ ; do
|
for certdir in /etc/letsencrypt/live/*/ ; do
|
||||||
echo $certdir
|
|
||||||
SUBJECT=$(openssl x509 -in ${certdir}/cert.pem -noout -subject|grep -oP '(?<=CN = )[^,]+'|sort -uV)
|
SUBJECT=$(openssl x509 -in ${certdir}/cert.pem -noout -subject|grep -oP '(?<=CN = )[^,]+'|sort -uV)
|
||||||
SUBJECTNAMES=$(openssl x509 -in ${certdir}/cert.pem -noout -text|grep -oP '(?<=DNS:|IP Address:)[^,]+'|sort -uV)
|
SUBJECTNAMES=$(openssl x509 -in ${certdir}/cert.pem -noout -text|grep -oP '(?<=DNS:|IP Address:)[^,]+'|sort -uV)
|
||||||
SUBJECTNAMES=${SUBJECTNAMES//$'\n'/, }
|
SUBJECTNAMES=${SUBJECTNAMES//$'\n'/, }
|
||||||
@@ -594,22 +593,6 @@ LISTCERTS(){
|
|||||||
CERTEXPIRE=$(date -d "$(: | openssl x509 -in ${certdir}/cert.pem -text | grep 'Not After' |awk '{print $4,$5,$7}')" '+%s');
|
CERTEXPIRE=$(date -d "$(: | openssl x509 -in ${certdir}/cert.pem -text | grep 'Not After' |awk '{print $4,$5,$7}')" '+%s');
|
||||||
DAYS=14; DUEIN=$(($(date +%s) + (86400*$DAYS)));
|
DAYS=14; DUEIN=$(($(date +%s) + (86400*$DAYS)));
|
||||||
|
|
||||||
AWK=$(which awk)
|
|
||||||
DATE=$(which date)
|
|
||||||
GREP=$(which grep)
|
|
||||||
OPENSSL=$(which openssl)
|
|
||||||
SED=$(which sed)
|
|
||||||
|
|
||||||
|
|
||||||
#CERTDATE=$(${OPENSSL} x509 -in ${certdir}/cert.pem -text -enddate | grep 'Not After')
|
|
||||||
|
|
||||||
# COMMONNAME=$(${OPENSSL} x509 -in ${certdir}/cert.pem -text -subject | \
|
|
||||||
# ${SED} -e 's/.*CN=//' | \
|
|
||||||
# ${SED} -e 's/\/.*//')
|
|
||||||
|
|
||||||
#SUBJECT=${COMMONNAME}
|
|
||||||
|
|
||||||
|
|
||||||
declare -i cw; declare -i spc1; declare -i c
|
declare -i cw; declare -i spc1; declare -i c
|
||||||
c=0; cw=30; spc=''
|
c=0; cw=30; spc=''
|
||||||
spc1=${cw}-${#SUBJECT}
|
spc1=${cw}-${#SUBJECT}
|
||||||
|
|||||||
Reference in New Issue
Block a user