Update host with two IPs

jpmeijers

New Member
I wrote a simple python script to update my host's IP addresses. It first does a lookup for my IPv4 address, updates Zoneedit with that, then it tries the IPv6 address. This seems to trigger the rate limiter of the dynamic dns endpoint:

def zoneedit_update(host, ip):
response = requests.get(
'https://dynamic.zoneedit.com/auth/dynamic.html',
params={'host': host, 'dnsto': ip},
auth = HTTPBasicAuth(ZONEEDIT_USERNAME, ZONEEDIT_PASSWORD)
)
print("Response code:", response.status_code)
print("Response text:", response.text)

Starting
IPv4 setting <my.host.name> to 102.<redacted>.101
Response code: 200
Response text: <SUCCESS CODE="200" TEXT="<my.host.name> updated to 102.<redacted>.101" ZONE="<host.name>">

IPv6 setting <my.host.name> to 2c0f:<redacted>:c3d0
Response code: 200
Response text: <ERROR CODE="702" PARAM="600" TEXT="Minimum 600 seconds between requests" ZONE="<my.host.name>">

The simple solution would be to wait 600 seconds before updating my IPv6 address. But this will mean that every time after my ISP refresh my line, my servers will be inaccessible on IPv6 for 10 minutes.

Is there a way one can specify more that one IP address when making the GET request to update the host's IP address?
 
Top