mirror of
https://github.com/dehydrated-io/dehydrated.git
synced 2026-03-13 05:35:16 +01:00
allow for spaces when extracting commonName from csr (fixes #423)
This commit is contained in:
@@ -498,7 +498,7 @@ extract_altnames() {
|
||||
|
||||
else
|
||||
# No SANs, extract CN
|
||||
altnames="$( <<<"${reqtext}" grep '^[[:space:]]*Subject:' | _sed -e 's/.* CN=([^ /,]*).*/\1/' )"
|
||||
altnames="$( <<<"${reqtext}" grep '^[[:space:]]*Subject:' | _sed -e 's/.* CN ?= ?([^ /,]*).*/\1/' )"
|
||||
echo "${altnames}"
|
||||
fi
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user