Stricter regex, should now catch all false positives

This commit is contained in:
9cco 2022-03-12 12:45:16 +01:00
parent 08ef1d559d
commit 00db8af28f
1 changed files with 1 additions and 1 deletions

View File

@ -28,7 +28,7 @@ else
fi
# Use regex to check for proper IPv4 format.
if [[ ! $ip =~ $ipv4_regex ]]; then
if [[ ! $ip =~ ^$ipv4_regex$ ]]; then
logger -s "DDNS Updater: Failed to find a valid IP."
exit 2
fi