* DNSIMPLE: do not support unpaired double quotes in TXT
DNSimple supports multiple double-quotes strings in a TXT record, but does not correctly support unpaired or escaped double-quotes currently.
IE the following are valid
```
asdf
"asdf"
"asdf" "asdf"
!@#$ %^&*()([][{}{<></'`:;-_=+\
```
however `as\"df` and `as"df` are not
This removes the extra string processing in getTargetRecordPriority as all tests pass without it and currently only double-quotes cause problems in our TXT validations.
I added another test to prove additional quoting is not needed. We can remove it if undesired.
Also applied small lint changes to make my editor happy.
* Use backticks to prevent escaping
* Set TXT target record content to GetTargetRFC1035Quoted()
Co-authored-by: Tom Limoncelli <tlimoncelli@stackoverflow.com>
DNSimple does not support spaces in the records at this time. I have opened an internal ticket on the issue.
Fixes test breakage caused in #1377
Co-authored-by: Tom Limoncelli <tlimoncelli@stackoverflow.com>
Anthony delegates all tasks relating to our DNSControl DNSimple integration to me. It would be more efficient to set me as the code owner.
I am an employee of DNSimple and use DNSControl's DNSimple integration in my other projects as well.
CC @aeden in case he needs to sign off.
Fallback to using Application Default Credentials if no
private_key is available in the creds.json-file.
This allows usage with various short lived credentials, for example
GCE-instances, gcloud auth application-default login, OIDC Workload
Identity etc
Co-authored-by: Tom Limoncelli <tlimoncelli@stackoverflow.com>
As of 2022-06-23, the Hetzner DNS API is still responding with a 422
when a CAA record contains a quoted value with spaces.
```
format: number of fields does not match record type, expecting 3
```
Their support acknowledged my bug report a few weeks back and suggested
the removal of spaces to get past the limitation.
Spaces in CAA records are not common. Let's just skip the test and put
a notice in the docs.
Signed-off-by: Jakob Ackermann <das7pad@outlook.com>
* POWERDNS: Cleanup and fix parsing of TXT records
Signed-off-by: Jan-Philipp Benecke <jan-philipp@bnck.me>
* Add unit tests for convert functions
Signed-off-by: Jan-Philipp Benecke <jan-philipp@bnck.me>
* Restructure PowerDNS DSP based on layout for CSCGlobal
Signed-off-by: Jan-Philipp Benecke <jan-philipp@bnck.me>
* Rename api to dsp and make initializer function private
Signed-off-by: Jan-Philipp Benecke <jan-philipp@bnck.me>
Co-authored-by: Tom Limoncelli <tlimoncelli@stackoverflow.com>
Now that the Dockerfile uses pinned commit hashes for images, it is useful to have Dependabot create pull requests whenever the upstream image is updated.
Co-authored-by: Tom Limoncelli <tlimoncelli@stackoverflow.com>
* Move the registrar features to a separate file
* Prepare the testing framework
* Roughed out functions
* Fix up structs
* WIP!
* First tests pass
* wip!
* Flesh out remaining rTypes, get nameservers, etc
* Fix TXT records
* Clean up code
* More cleanups. Fix CAA/SRV
* Linting
* Cleanups/linting
* Fix CAA [more] and more cleanups
* CSC does not like very long txt records
* Use timer only when interactive
* Disable CAA for now
* Update docs
* Remove debug printf
* add go-isatty
* cleanups
* Preventing segfault when Cloudflare API limit is reached
Signed-off-by: Jan-Philipp Benecke <jan-philipp@bnck.me>
* Add comment for future me
Signed-off-by: Jan-Philipp Benecke <jan-philipp@bnck.me>