mirror of
https://github.com/serghey-rodin/vesta.git
synced 2025-08-20 21:34:11 -07:00
fixed wildcards bug and dns restart issue
This commit is contained in:
parent
805bc37cd7
commit
d66f30117f
2 changed files with 12 additions and 2 deletions
|
@ -116,7 +116,7 @@ increase_user_value "$user" '$U_DNS_DOMAINS'
|
||||||
increase_user_value "$user" '$U_DNS_RECORDS' "$records"
|
increase_user_value "$user" '$U_DNS_RECORDS' "$records"
|
||||||
|
|
||||||
# Restart named
|
# Restart named
|
||||||
$BIN/v_restart_web "$EVENT"
|
$BIN/v_restart_dns "$EVENT"
|
||||||
|
|
||||||
# Logging
|
# Logging
|
||||||
log_history "$EVENT"
|
log_history "$EVENT"
|
||||||
|
|
12
func/main.sh
12
func/main.sh
|
@ -562,6 +562,16 @@ validate_format_domain() {
|
||||||
fi
|
fi
|
||||||
}
|
}
|
||||||
|
|
||||||
|
# Domain alias
|
||||||
|
validate_format_domain_alias() {
|
||||||
|
exclude="[!|@|#|$|^|&|(|)|+|=|{|}|:|,|<|>|?|_|/|\|\"|'|;|%|\`| ]"
|
||||||
|
if [[ "$1" =~ $exclude ]] || [[ "$1" =~ "^[0-9]+$" ]]; then
|
||||||
|
echo "Error: domain alias $1 is not valid"
|
||||||
|
log_event "$E_INVALID" "$EVENT"
|
||||||
|
exit $E_INVALID
|
||||||
|
fi
|
||||||
|
}
|
||||||
|
|
||||||
# Database
|
# Database
|
||||||
validate_format_database() {
|
validate_format_database() {
|
||||||
exclude="[!|@|#|$|^|&|*|(|)|+|=|{|}|:|,|.|<|>|?|/|\|\"|'|;|%|\`| ]"
|
exclude="[!|@|#|$|^|&|*|(|)|+|=|{|}|:|,|.|<|>|?|/|\|\"|'|;|%|\`| ]"
|
||||||
|
@ -698,7 +708,7 @@ validate_format(){
|
||||||
dkim) validate_format_boolean "$arg" 'dkim' ;;
|
dkim) validate_format_boolean "$arg" 'dkim' ;;
|
||||||
dkim_size) validate_format_key_size "$arg" ;;
|
dkim_size) validate_format_key_size "$arg" ;;
|
||||||
domain) validate_format_domain "$arg" ;;
|
domain) validate_format_domain "$arg" ;;
|
||||||
dom_alias) validate_format_domain "$arg" ;;
|
dom_alias) validate_format_domain_alias "$arg" ;;
|
||||||
dvalue) validate_format_dvalue "$arg";;
|
dvalue) validate_format_dvalue "$arg";;
|
||||||
email) validate_format_email "$arg" ;;
|
email) validate_format_email "$arg" ;;
|
||||||
exp) validate_format_date "$arg" ;;
|
exp) validate_format_date "$arg" ;;
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue