Merge pull request #1577 from moucho/error_tab

Do not allow {tab} as a valid character for a domain
This commit is contained in:
dpeca 2018-05-21 11:50:11 +02:00 committed by GitHub
commit b8375c5833
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -532,7 +532,7 @@ is_user_format_valid() {
is_domain_format_valid() {
object_name=${2-domain}
exclude="[!|@|#|$|^|&|*|(|)|+|=|{|}|:|,|<|>|?|_|/|\|\"|'|;|%|\`| ]"
if [[ $1 =~ $exclude ]] || [[ $1 =~ ^[0-9]+$ ]] || [[ $1 =~ "\.\." ]]; then
if [[ $1 =~ $exclude ]] || [[ $1 =~ ^[0-9]+$ ]] || [[ $1 =~ "\.\." ]] || [[ $1 =~ "$(printf '\t')" ]]; then
check_result $E_INVALID "invalid $object_name format :: $1"
fi
}