From d43487a67907e24d7f19d2381d9adae745b20dfc Mon Sep 17 00:00:00 2001 From: pyllyukko Date: Tue, 1 Sep 2020 18:43:45 +0300 Subject: [PATCH] cas.sh: Fix country grepping --- cas.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/cas.sh b/cas.sh index 215a95a..a9f4b09 100644 --- a/cas.sh +++ b/cas.sh @@ -243,7 +243,7 @@ function print_countries() { for NICKNAME in "${NICKNAMES[@]}" do # print the PEM from the cert8.db and get the FP with openssl - COUNTRY=$( certutil -L -n "${NICKNAME}" -a -d "${FF_HOME}" | openssl x509 -noout -subject | grep -o "C=[A-Z]\+" ) + COUNTRY=$( certutil -L -n "${NICKNAME}" -a -d "${FF_HOME}" | openssl x509 -noout -subject | grep -o "C\s\?=\s\?[A-Z]\+" ) if [ -n "${COUNTRY}" ] then echo "${COUNTRY#C=}" -- 2.11.4.GIT