Commit graph

963 commits

Author SHA1 Message Date
Jakob Ackermann
1e67585e8f
HETZNER_V2: Add provider for Hetzner DNS API (#3837)
Closes https://github.com/StackExchange/dnscontrol/issues/3787

This PR is adding a `HETZNER_V2` provider for the "new" Hetzner DNS API.

Testing:
- The integration tests are passing.
- Manual testing:
  - `preview` (see diff for existing zone)
- `preview --populate-on-preview` (see full diff for newly created zone)
  - `push` (see full diff; no diff after push)
- `push` (see full diff; no diff after push to newly created zone --
i.e. single pass and done)

```js
var REG_NONE = NewRegistrar('none')
var DSP = NewDnsProvider('HETZNER_V2')

D('testing-2025-11-14-7.dev', REG_NONE, DnsProvider(DSP),
    A('@', '127.0.0.1')
)
```

<details>

```
# push for newly created zone
CONCURRENTLY checking for 1 zone(s)
SERIALLY checking for 0 zone(s)
Waiting for concurrent checking(s) to complete...DONE
******************** Domain: testing-2025-11-14-7.dev
1 correction (HETZNER_V2)
#1: Ensuring zone "testing-2025-11-14-7.dev" exists in "HETZNER_V2"
SUCCESS!
CONCURRENTLY gathering records of 1 zone(s)
SERIALLY gathering records of 0 zone(s)
Waiting for concurrent gathering(s) to complete...DONE
******************** Domain: testing-2025-11-14-7.dev
4 corrections (HETZNER_V2)
#1: ± MODIFY-TTL testing-2025-11-14-7.dev NS helium.ns.hetzner.de. ttl=(3600->300)
± MODIFY-TTL testing-2025-11-14-7.dev NS hydrogen.ns.hetzner.com. ttl=(3600->300)
± MODIFY-TTL testing-2025-11-14-7.dev NS oxygen.ns.hetzner.com. ttl=(3600->300)
SUCCESS!
#2: + CREATE testing-2025-11-14-7.dev A 127.0.0.1 ttl=300
SUCCESS!
Done. 5 corrections.
```
</details>

Feedback for @jooola and @LKaemmerling:
- The SDK was very useful in getting 80% there! Nice! 🎉 
- Footgun:
- The `result` values are not "up-to-date" after waiting for an
`Action`, e.g. `Zone.AuthoritativeNameservers.Assigned` is not set when
`Client.Zone.Create()` returns and the following "wait" will not update
it.
- Taking a step back here: Waiting for an `Action` with a separate SDK
call does not seem very natural to me. Does the SDK-user need to know
that you are processing operations asynchronous? (Which seems like an
implementation detail to me, something that the SDK could abstrct over.)
Can `Client.Zone.Create()` return the final `Zone` instead of the
intermediate result?
- Features missing compared to the DNS Console, in priority order:
- It is no longer possible to remove your provided name servers from the
root/apex. Use-case: dual-home/multi-home zone with fewer than three
servers from Hetzner. I'm operating one of these and cannot migrate over
until this is fixed.
- Performance regression due to lack of bulk create/modify. E.g. [one of
the test
suites](a71b89e5a2/integrationTest/integration_test.go (L619))
spends about 4.5 minutes on making creating 100 record-sets and then
another 4 minutes for deleting them in sequence again. With your async
API, these are `create 2*100 + delete 2*100 = 400` API calls.
Previously, these were `create 1 + delete 100 = 101` API calls. Are you
planning on adding batch processing again?
- Usability nits
- Compared to other record-set based APIs, upserts for record-sets are
missing. This applies to records of a record-set and the ttl of the
record-set (see separate SDK calls for the cases `diff2.CREATE` vs
`diff2.CHANGE` and two calls in `diff2.CHANGE` for updating the TTL vs
records).
- Some SDK methods return an `Action` (e.g. `Zone.ChangeRRSetTTL()`),
others wrap the `Action` in a struct (`Client.Zone.CreateRRSet()`) --
even when the struct has a single field (`ZoneRRSetDeleteResult`).

---------

Co-authored-by: "Jonas L." <jooola@users.noreply.github.com>
Co-authored-by: "Lukas Kämmerling" <LKaemmerling@users.noreply.github.com>
Co-authored-by: Tom Limoncelli <6293917+tlimoncelli@users.noreply.github.com>
2025-11-30 09:14:54 -05:00
Tom Limoncelli
1b2f5d4d34
BUGFIX: IDN support is broken for domain names (#3845)
# Issue

Fixes https://github.com/StackExchange/dnscontrol/issues/3842

CC @das7pad

# Resolution

Convert domain.Name to IDN earlier in the pipeline. Hack the --domains
processing to convert everything to IDN.

* Domain names are now stored 3 ways: The original input from
dnsconfig.js, canonical IDN format (`xn--...`), and Unicode format. All
are downcased. Providers that haven't been updated will receive the IDN
format instead of the original input format. This might break some
providers but only for users with unicode in their D("domain.tld").
PLEASE TEST YOUR PROVIDER.
* BIND filename formatting options have been added to access the new
formats.

# Breaking changes

* BIND zonefiles may change. The default used the name input in the D()
statement. It now defaults to the IDN name + "!tag" if there is a tag.
* Providers that are not IDN-aware may break (hopefully only if they
weren't processing IDN already)

---------

Co-authored-by: Jakob Ackermann <das7pad@outlook.com>
2025-11-29 12:17:44 -05:00
Patrik Kernstock
9aad2926fb
INWX: Fix INWX provider after their unexpected data-type breaking-change (#3855)
Fixes #3854 

Unfortunately I couldn't run the integrationTests properly as INWX
doesn't seem to have properly updated their sandbox environment (it
still presents `int` instead of `string` like production). Hence, the
tests do fail. I don't want to run this against my own production
account, to be frank.

See:
```shell
$ curl -X POST https://api.ote.domrobot.com/xmlrpc/ -H "Content-Type: application/xml" -d '<?xml version="1.0" encoding="UTF-8"?>
<methodCall>
   <methodName>nameserver.info</methodName>
   <params>
      <param>
         <value>
            <struct>
               <member>
                  <name>user</name>
                  <value>
                     <string>[USER]</string>
                  </value>
               </member>
               <member>
                  <name>lang</name>
                  <value>
                     <string>en</string>
                  </value>
               </member>
               <member>
                  <name>pass</name>
                  <value>
                     <string>[PASS]</string>
                  </value>
               </member>
               <member>
                  <name>domain</name>
                  <value>
                     <string>[DOMAIN]</string>
                  </value>
               </member>
            </struct>
         </value>
      </param>
   </params>
</methodCall>' | xmllint --format - | grep -iE "id|roId" -C3
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed
100  3968    0  2971  100   997  13375   4488 --:--:-- --:--:-- --:--:-- 17954
            <value>
              <struct>
                <member>
                  <name>roId</name>
                  <value>
                    <int>9677</int>
                  </value>
--
                        <value>
                          <struct>
                            <member>
                              <name>id</name>
                              <value>
                                <int>118057</int>
                              </value>
--
                        <value>
                          <struct>
                            <member>
                              <name>id</name>
                              <value>
                                <int>118060</int>
                              </value>
--
                        <value>
                          <struct>
                            <member>
                              <name>id</name>
                              <value>
                                <int>79610</int>
                              </value>
--
                        <value>
                          <struct>
                            <member>
                              <name>id</name>
                              <value>
                                <int>77243</int>
                              </value>
--
            </value>
          </member>
          <member>
            <name>svTRID</name>
            <value>
              <string>20251127--ote</string>
            </value>
```

Hence, only done manualy tests via `dnscontrol push --domains
<example.com>`:
(tested create, delete and modify)

```text
CONCURRENTLY checking for 0 zone(s)
SERIALLY checking for 1 zone(s)
Serially checking for zone: "example.tld"
CONCURRENTLY gathering records of 0 zone(s)
SERIALLY gathering records of 1 zone(s)
Serially Gathering: "example.tld"
******************** Domain: example.tld
3 corrections (PK-INWX)
#1: - DELETE _test1.example.tld TXT "123" ttl=43200
SUCCESS!
#2: ± MODIFY _test2.example.tld TXT ("1234" ttl=43200) -> ("12345" ttl=43200)
SUCCESS!
#3: + CREATE _test4.example.tld TXT "123" ttl=43200
SUCCESS!
Done. 3 corrections.
```
2025-11-29 12:17:13 -05:00
Tom Limoncelli
f306472d5a
CHORE: Maintainer changes for OPENSRS and DIGITALOCEAN (#3849)
# Issue

The maintainers of OPENSRC and DIGITALOCEAN have indicated they would
like to step down.

@chicks-net has stepped up to take over maintenance of DIGITALOCEAN.

# Resolution

* Update the `OWNERS` file.
* Update the `providerMaintainer` value for the providers.
* Update the README file.


CC @Deraen @philhug @chicks-net

---------

Co-authored-by: Jeffrey Cafferata <jeffrey@jcid.nl>
2025-11-24 20:29:43 -05:00
Sukka
b992ae32ef
CLOUDFLAREAPI: Skip read-only records inserted by provider (#3850) (#3852)
<!--
## Before submiting a pull request

Please make sure you've run the following commands from the root
directory.

    bin/generate-all.sh

(this runs commands like "go generate", fixes formatting, and so on)

## Release changelog section

Help keep the release changelog clear by pre-naming the proper section
in the GitHub pull request title.

Some examples:
* CICD: Add required GHA permissions for goreleaser
* DOCS: Fixed providers with "contributor support" table
* ROUTE53: Allow R53_ALIAS records to enable target health evaluation

More examples/context can be found in the file .goreleaser.yml under the
'build' > 'changelog' key.
!-->

The PR fixes #3850.
2025-11-24 20:28:38 -05:00
Gabe Van Engel
97209bc2fc
AKAMAIEDGEDNS: Add ALIAS and AKAMAITLC support to the Akamai Edge DNS provider (#3836) 2025-11-14 09:48:42 -05:00
Elvis Ratzlaff
a1e74eb11f
POWERDNS: Zone creation now abides by variant tags (#3830) 2025-11-05 09:33:47 -05:00
Elvis Ratzlaff
8f13dd1030
POWERDNS: Split horizon feature now enabled by flag (#3829) 2025-11-04 09:15:24 -05:00
Peter Feigl
25dd06aaa3
POWERDNS: Map dnscontrol Tags to powerdns Variants (#3803)
Co-authored-by: Peter Feigl <peter.feigl@nexoid.at>
Co-authored-by: Tom Limoncelli <6293917+tlimoncelli@users.noreply.github.com>
2025-11-03 11:46:09 -05:00
Eli Heady
c1b90d06a0
INWX: Let the API (not DNSControl) enforce the RFC 7505 prohibition of mixed regular/null MX records (#3805)
Co-authored-by: Tom Limoncelli <6293917+tlimoncelli@users.noreply.github.com>
2025-11-03 11:44:40 -05:00
Kevin Neufeld
24f602a5a1
feat(Route53): Add support for RoleArn and ExternalId #3816 (#3817)
Co-authored-by: Tom Limoncelli <6293917+tlimoncelli@users.noreply.github.com>
2025-11-03 11:38:13 -05:00
Elvis Ratzlaff
2a4e2509bc
POWERDNS: New record type: LUA (#3815) 2025-11-03 11:32:28 -05:00
Peter
6ef0648778
NETCUP: add TLSA support (#3802) 2025-10-23 10:41:35 -04:00
Tom Limoncelli
db21e30abb
Update deps (#3790) 2025-10-10 14:16:46 -04:00
Tom Limoncelli
3eddfcd037
feat(validation): Validation errors now include the line number (#3788) 2025-10-10 13:48:41 -04:00
Jan von Aschwege
a71b89e5a2
NEW FEATURE: Add SMIMEA support for BIND and deSEC (#3786) 2025-10-10 11:16:13 -04:00
Tom Limoncelli
5f4e1efdce
NS1: Fix NAPTR special case (#3785) 2025-10-02 06:53:19 -04:00
Louis Laureys
2122390f29
DOCS: Fill some question marks for cloudns (#3767)
Co-authored-by: Tom Limoncelli <6293917+tlimoncelli@users.noreply.github.com>
2025-10-01 15:47:50 -04:00
Will Power
9b32a2f9b2
NAMECHEAP: Enable get-zones (#3775) 2025-09-29 13:43:03 -04:00
Tom Limoncelli
9e77938e68
GANDI_V5: Increase API timeouts (#3770) 2025-09-15 14:02:47 -04:00
Eli Heady
cca9a1e433
DESEC: improve formatting of DS records on domain creation (#3766) 2025-09-12 11:04:01 -04:00
Tom Limoncelli
b529bc6593
CHORE: Upgrade github.com/failsafe-go/failsafe-go v0.6.9 to v0.7.0 (#3760) 2025-09-02 10:59:45 -04:00
Mynacol
c858e8fa57
AXFRDDNS: Chunk large changes in multiple packets (#3732)
Co-authored-by: Mynacol <Mynacol@users.noreply.github.com>
Co-authored-by: Tom Limoncelli <6293917+tlimoncelli@users.noreply.github.com>
2025-08-28 12:27:18 -04:00
James O'Gorman
89ac03faca
PORKBUN: Configurable retry parameters (#3746) 2025-08-28 12:24:40 -04:00
Tom Limoncelli
3645e332c3
security fix: Prevent exposure of creds in debug output (#3733) 2025-08-19 10:47:02 -04:00
Mynacol
3799f8b8e9
AXFRDDNS: Enable DNS compression for DDNS (#3730) 2025-08-18 16:35:17 -04:00
PJEilers
43e7dd5603
REALTIMEREGISTER: SRV prio 0 (#3725)
Co-authored-by: pieterjan.eilers <pieterjan.eilers@realtimeregister.com>
2025-08-13 09:41:03 -04:00
PJEilers
2b2f9d901e
REALTIMEREGISTER: Allow 0 prio for MX records (#3724)
Co-authored-by: pieterjan.eilers <pieterjan.eilers@realtimeregister.com>
2025-08-13 09:10:23 -04:00
Georg
8c8948e69a
NEW RECORD TYPE: OPENPGPKEY (basic) (#3718)
Signed-off-by: Georg Pfuetzenreuter <mail@georg-pfuetzenreuter.net>
Co-authored-by: Tom Limoncelli <tlimoncelli@stackoverflow.com>
2025-08-11 10:44:12 -04:00
Yuhui Xu
1e8d720fdd
GCORE: update create zone call signature from latest SDK (#3712)
Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-08-05 07:49:45 -04:00
Alex Trull
ca64774004
Joker: Implement DNS Provider (#3661)
Co-authored-by: Tom Limoncelli <tlimoncelli@stackoverflow.com>
2025-08-04 16:37:20 -04:00
Brandon Gilmore
304ce4cb4a
AXFRDDNS: Fix spurious AUTODNSSEC warnings (#3703) 2025-08-04 09:07:07 -04:00
Tom Limoncelli
633196e328
Warn if IGNORE() is unreliable for this provider (#3683) 2025-07-30 20:41:49 -04:00
Juho Teperi
66e7fd4d34
DIGITALOCEAN: Enable DocDualHost feature (#3698) 2025-07-30 09:27:33 -04:00
Juho Teperi
91c143694f
DIGITALOCEAN: Use diff2 to implement digitalocean provider (#3695) 2025-07-28 09:37:56 -04:00
Paul Donald
e84925b491
Loopia: feature updates (#3686) 2025-07-24 14:41:57 -04:00
Kai Schwarz
8b8d677735
CNR: nameserver corrections should be case insensitive (#3681) 2025-07-23 10:15:19 -04:00
Phil Pennock
3f4f9b8083
DNSIMPLE: DOCS: handle multiple provider instances (#3678) 2025-07-22 12:51:21 -04:00
Phil Pennock
570477f8d3
DNSIMPLE: pedantic correctness fix for concurrency (#3677) 2025-07-22 10:01:58 -04:00
Phil Pennock
ecbc4992d0
DOCS: expand upon concurrency (#3676) 2025-07-22 10:01:10 -04:00
Phil Pennock
af5907aafd
DNSIMPLE: preview data is now gathered concurrently (CanConcur) (#3675) 2025-07-21 15:09:44 -04:00
Klett IT
a815bdcf45
FORTIGATE: Add NS and MX record support (#3671)
Co-authored-by: Klett IT <git@klett-it.net>
2025-07-18 10:22:37 -04:00
Jan-Philipp Benecke
e3b6141715
chore: update go-powerdns to v0.6.7 and adjust SOAEditAPI type (#3664) 2025-07-14 09:42:26 -04:00
Costas Drogos
75821a8219
NS1: code reorganization (#3622) 2025-07-10 10:51:43 -04:00
e9b49e23aa
LUADNS: Support HTTPS record type, enable concurrency, adopt newest SDK (#3640) 2025-07-10 10:50:33 -04:00
Tom Limoncelli
8a6baa7c24 Reapply "CHORE: Remove the MSDNS provider (#3656)"
This reverts commit e9f136036f.
2025-07-09 13:07:03 -04:00
Tom Limoncelli
e9f136036f Revert "CHORE: Remove the MSDNS provider (#3656)"
This reverts commit 1ccd5eb532.
2025-07-09 13:06:42 -04:00
Tom Limoncelli
1ccd5eb532
CHORE: Remove the MSDNS provider (#3656) 2025-07-09 12:47:48 -04:00
Ishan Jain
e1830abb58
NEW PROVIDER: ADGUARDHOME (#3638) 2025-07-09 12:06:34 -04:00
James O'Gorman
4ce19352e9
PORKBUN: Improve retry handling, mark as concurrent (#3652) 2025-07-09 12:03:59 -04:00