You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Cloudflare API is down today and as a result at random returns the following instead of the IP address: {"success":false,"errors":[{"code":10000,"message":"Internal authentication error: internal server error"}]}
The causes $old_ip == $ip to fail and force a IP update.
FIX:
Sanitize and ensure that the returned string from the API call is actually an IP before comparing. Suggested snippet below adds a comparison to ensure $old_ip is a valid IP first:
if [[ $old_ip =~ ^[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}$ ]]; then # <== NEW
# Compare if they're the same
if [[ $ip == $old_ip ]]; then
logger "DDNS Updater: IP ($ip) for ${record_name} has not changed."
exit 0
fi
fi
The text was updated successfully, but these errors were encountered:
Cloudflare API is down today and as a result at random returns the following instead of the IP address:
{"success":false,"errors":[{"code":10000,"message":"Internal authentication error: internal server error"}]}
The causes
$old_ip == $ip
to fail and force a IP update.FIX:
Sanitize and ensure that the returned string from the API call is actually an IP before comparing. Suggested snippet below adds a comparison to ensure
$old_ip
is a valid IP first:The text was updated successfully, but these errors were encountered: