mirror of
https://github.com/drwetter/testssl.sh.git
synced 2026-09-20 08:38:14 +02:00
Fix Shellcheck SC2021
This commit fixes Shellecheck issue SC2021 by not enclosing list of characters in "[...]' for the 'tr' command.
This commit is contained in:
+1
-1
@@ -23429,7 +23429,7 @@ determine_rdns() {
|
|||||||
# circumstances (see #1506) can show up here. The blacklist is taken from RFC 1912 ("Allowable characters in a
|
# circumstances (see #1506) can show up here. The blacklist is taken from RFC 1912 ("Allowable characters in a
|
||||||
# label for a host name are only ASCII, letters, digits, and the `-' character")
|
# label for a host name are only ASCII, letters, digits, and the `-' character")
|
||||||
while read -r line; do
|
while read -r line; do
|
||||||
line="$(tr -dc '[a-zA-Z0-9-_.]' <<< "$line")"
|
line="$(tr -dc 'a-zA-Z0-9-_.' <<< "$line")"
|
||||||
[[ -z "$rdns" ]] && rdns="$line" || rdns="$rdns $line"
|
[[ -z "$rdns" ]] && rdns="$line" || rdns="$rdns $line"
|
||||||
done <<< "$rDNS"
|
done <<< "$rDNS"
|
||||||
rDNS="$rdns"
|
rDNS="$rdns"
|
||||||
|
|||||||
Reference in New Issue
Block a user