tuxis-ie / nsedit

DNS Editor working with PowerDNS's new API
GNU General Public License v2.0
198 stars 55 forks source link

WIP: Place brackets around the hostname #199

Closed WilliamDEdwards closed 2 months ago

WilliamDEdwards commented 2 years ago

When setting $apiip to an IPv6 address, requests to the PowerDNS API fail with cURL error 0 and an empty curl_error. This is because cURL doesn't understand we're working with an IPv6 address. This should be fixed by placing brackets around the address.

This PR is not finished. AFAIK, we don't have to check the address family, because placing brackets around an IPv4 address works. However, we still don't know whether we're dealing with a hostname or not.

WilliamDEdwards commented 2 months ago

Superseded by https://github.com/tuxis-ie/nsedit/pull/204 (clean PR)