Commit graph

1384 commits

Author SHA1 Message Date
Costas Drogos
6e802f2257 Emit warning in case of label having multiple TTLs
An RRSet (=label) consisting of multiple records with different TTLs is
something not supported by most providers, and should be avoided.
Furthermore it is deprecated in rfc2181#section-5.2

Emit a warning for now during validation, eventually turning it into a full-blown error.

Fixes #1372
2022-05-04 11:20:27 -04:00
Tom Limoncelli
1c43d03d89
Refactor: Move creds.json processing out of InitializeProviders (#1495)
* Rename providers/config to pkg/credsfile

* Refactor InitializeProviders in preparation for v3.16
2022-05-04 11:02:36 -04:00
Costas Drogos
c8a5060dfb
Emit warning in case of label having multiple TTLs (#1489)
* Emit warning in case of label having multiple TTLs

An RRSet (=label) consisting of multiple records with different TTLs is
something not supported by most providers, and should be avoided.
Furthermore it is deprecated in rfc2181#section-5.2

Emit a warning for now during validation, eventually turning it into a full-blown error.

Fixes #1372

* normalize: less verbose checkLabelHasMultipleTTLs

Code would previously emit a warning for each record it found matching a
previously found label but with a different ttl. This could potentially become
too verbose of an output for larger zones.

Split the loop into two loops, one storing labels and their records' TTLs, the
second checking for multiple TTLs, in order to minimize the messages logged to
one message per problematic label, regardless for the number of records involved.

Co-authored-by: Tom Limoncelli <tlimoncelli@stackoverflow.com>
2022-05-04 08:41:16 -04:00
Costas Drogos
156ec01ea0
TESTING: pkg/js/parse_tests: fix a broken test (#1498)
012_duration creates multiple records under the same label, with different TTLs
We plan to deprecate this going forward, in #1372.

Modify the test in a way that creates one label per record, each having a
different TTL format as before, to be validated.
2022-05-03 19:46:48 -04:00
adrian-hoasted
013a059dc7
CLOUDFLARE: Add support for PTR records (#1496) 2022-05-03 06:07:49 -04:00
Tom Limoncelli
19550aeed9
Refactor: Rename providers/config to pkg/credsfile (#1494) 2022-05-02 20:12:30 -04:00
dependabot[bot]
9f54ecce0d
Bump github/codeql-action from 1 to 2 (#1487)
Bumps [github/codeql-action](https://github.com/github/codeql-action) from 1 to 2.
- [Release notes](https://github.com/github/codeql-action/releases)
- [Changelog](https://github.com/github/codeql-action/blob/main/CHANGELOG.md)
- [Commits](https://github.com/github/codeql-action/compare/v1...v2)

---
updated-dependencies:
- dependency-name: github/codeql-action
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Tom Limoncelli <tlimoncelli@stackoverflow.com>
2022-05-01 17:32:35 -04:00
dependabot[bot]
d4dc335fe7
Bump google.golang.org/api from 0.76.0 to 0.77.0 (#1491)
Bumps [google.golang.org/api](https://github.com/googleapis/google-api-go-client) from 0.76.0 to 0.77.0.
- [Release notes](https://github.com/googleapis/google-api-go-client/releases)
- [Changelog](https://github.com/googleapis/google-api-go-client/blob/main/CHANGES.md)
- [Commits](https://github.com/googleapis/google-api-go-client/compare/v0.76.0...v0.77.0)

---
updated-dependencies:
- dependency-name: google.golang.org/api
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2022-05-01 13:21:38 -04:00
Tom Limoncelli
2e395a422c
Update dependencies (#1490) 2022-04-29 15:31:51 -04:00
Costas Drogos
6042d07944
DOCS: fix a forgotten "VOLUNTEER NEEDED" (#1488) 2022-04-29 15:06:39 -04:00
Tom Limoncelli
41d994bab6
Eliminate models.StringsToNameservers() (#1486)
* Eliminate StringsToNameservers()

* update comments
2022-04-24 09:08:40 -04:00
Tom Limoncelli
e2536ad406
In preparation of #1457, warn if cred-names contain colon (#1480) 2022-04-04 15:33:59 -04:00
Tom Limoncelli
17feddb157
go generate (#1479) 2022-04-04 14:55:35 -04:00
Tom Limoncelli
7c2938c6d3
Update depends (#1478) 2022-04-04 14:48:07 -04:00
Tom Limoncelli
99210c9d1c
Make skip_fqdn_check error message easier to understand and fix (#1477) 2022-04-04 14:05:49 -04:00
2e16f7b142
AUTODNS: Fix autodns documentation example javascript. (#1470) 2022-03-31 17:09:06 -04:00
Pascal Mathis
144adfd632
CLOUDNS: Fix creation of intra-zone NS records (see #1263) (#1469) 2022-03-31 14:38:42 -04:00
Phil Pennock
4a185909a8
DNSIMPLE: bug-fix, allow non-apex NS records (#1468) 2022-03-28 15:28:40 -04:00
Tom Limoncelli
729672f039
MAINT: Refactor GetDNSConfig (#1466)
* MAINT: Refactor GetDNSConfig

* do not return junk data
2022-03-27 18:00:13 -04:00
Tom Limoncelli
73de17adc2 Revert "_PROVIDER flag phase 1: generate warnings"
This reverts commit 26c632e05f.
2022-03-27 15:56:57 -04:00
Tom Limoncelli
26c632e05f _PROVIDER flag phase 1: generate warnings 2022-03-27 15:54:16 -04:00
arnoschoon
caedb9a7a6
NEW PROVIDER: AutoDNS (#1336)
* Implement AutoDNS provider to manage existing zones

* Moved AuditRecords() in to separate file to ease automatic updating

* S1011 - Use a single append to concatenate two slices

* Set list of available record types as returned by the system

* Fixed style, clarify code and add some extra comments

* Documented simple configuration and usage example of AutoDNS

* Convert MX and SRV record properly from string to actual structs and back

* Add support for integration tests of AutoDNS

* Return error message from update request instead of invoking panic()

* Skip AUTODNS in test for RFC 7505 (null MX)

* Update providers/autodns/autoDnsProvider.go

Co-authored-by: Tom Limoncelli <tlimoncelli@stackoverflow.com>
2022-03-25 15:22:59 -04:00
Koen Vlaswinkel
02d76affc0
LINODE: Add support for CAA records and implement get-zones (#1454)
* LINODE: Add support for CAA records

* LINODE: Implement get-zones

Co-authored-by: Tom Limoncelli <tlimoncelli@stackoverflow.com>
2022-03-25 15:22:20 -04:00
Tom Limoncelli
ffe21c6e6d
creds.json should not be executable under Windows (#1456)
* Skip CAA flag test for LINODE

* Require go 1.18

* Update CCI to use go 1.18

* go mod tidy

* working

* Update creds.json docs

* go generate
2022-03-25 15:20:30 -04:00
Tom Limoncelli
52a8964564
LINODE: Skip CAA flag test (#1455)
* Skip CAA flag test for LINODE

* Require go 1.18

* Update CCI to use go 1.18

* go mod tidy

* HEXONET: Adapt to new OTE endpoint (#1463)

* HEXONET: Adapt to new OTE endpoint

* CCI uses goreleaser which needs go 1.8

* HEXONET: Fix error format string (#1462)

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

* MAINT: "DUPLICATE E_RECORD" no longer a hard error (#1465)

* go generate
2022-03-25 15:16:36 -04:00
Tom Limoncelli
91592ce4a7
MAINT: "DUPLICATE E_RECORD" no longer a hard error (#1465) 2022-03-25 12:09:24 -04:00
Tom Limoncelli
cc428ca9e1
HEXONET: Fix error format string (#1462)
Fixes https://github.com/StackExchange/dnscontrol/issues/1461
2022-03-24 15:43:37 -04:00
Tom Limoncelli
9c7b84eefd
HEXONET: Adapt to new OTE endpoint (#1463)
* HEXONET: Adapt to new OTE endpoint

* CCI uses goreleaser which needs go 1.8
2022-03-24 12:53:42 -04:00
Tom Limoncelli
7814a837cd
MAINT: Minimum go version is now 1.18 (#1464)
* MAINT: Minimum go version is now 1.18
2022-03-24 12:42:14 -04:00
Costas Drogos
2b40f6fa70
ns1: enable autoDNSSEC capability (#1450)
* ns1: enable autoDNSSEC capability

NS1's API has support for enabling or disabling DNSSEC on zones under
DNSSEC-enabled accounts.

This commit enables support for detecting a zone's DNSSEC state and,
given the autoDNSSEC setting, pushing the right domain corrections
to our corrections stack.

Fixes #1444

* ns1: better comments

* ns1: Handle a forgotten error

* ns1: style: spacing between functions

Co-authored-by: Tom Limoncelli <tlimoncelli@stackoverflow.com>
2022-03-11 10:12:45 -05:00
Tom Limoncelli
4d125fca5f
Guard against nil (#1452) 2022-03-09 15:20:45 -05:00
Tom Limoncelli
71a849c5af
Release v3.15.0 (#1449)
* Release v3.15.0

* Document deprecations better
2022-03-07 13:51:14 -05:00
Tom Limoncelli
8bc72137f8
MAINT: upgrade Azure depends 2022-03-07 13:17:59 -05:00
Tom Limoncelli
9db12e4730
GANDI: Bump go-gandi/go-gandi v0.0.0-20211124085723 => v0.1.0 (#1439)
* GANDI: Bump go-gandi/go-gandi v0.0.0-20211124085723-a737785a1af0 => v0.1.0

* Use new NewDomainClient signature

* go mod tidy
2022-03-07 13:00:39 -05:00
dependabot[bot]
6ef4d791a1
Bump actions/checkout from 2.4.0 to 3 (#1447)
Bumps [actions/checkout](https://github.com/actions/checkout) from 2.4.0 to 3.
- [Release notes](https://github.com/actions/checkout/releases)
- [Changelog](https://github.com/actions/checkout/blob/main/CHANGELOG.md)
- [Commits](https://github.com/actions/checkout/compare/v2.4.0...v3)

---
updated-dependencies:
- dependency-name: actions/checkout
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Tom Limoncelli <tlimoncelli@stackoverflow.com>
2022-03-07 11:32:49 -05:00
Costas Drogos
e300a8e9ca
NS1: Enable DS & DSForChildren support (#1446)
Enable support for DS and DSForChildren sets of records in NS1.

Fixes #1445
2022-03-07 11:31:55 -05:00
Costas Drogos
b8a70d7556
ns1: ignore DNSKEY & RRSIG entries (#1443)
These entries are autoconfigured by NS1 when a zone is enabled for DNSSEC and can't be
modified via the API, producing a 405 API error on modification attempts.

While unmodifiable, these records are returned by the API, so we have to ignore them.

Co-authored-by: Tom Limoncelli <tlimoncelli@stackoverflow.com>
2022-03-07 10:43:48 -05:00
Tom Limoncelli
cc6f5eb8d4
fixup! (#1441) 2022-03-04 09:42:36 -05:00
Tom Limoncelli
95ea4eedc9
CLOUDFLARE: Bump cloudflare/cloudflare-go v0.33.0 => v0.34.0 (#1438) 2022-03-04 08:46:12 -05:00
Julius Rickert
6f9e2797b7
DOCS: Fix examples in documentation (#1435)
* Add example include

* Replace example includes

* Remove old example includes
2022-03-04 07:49:03 -05:00
Tom Limoncelli
619487738f
CLOUDFLARE: Bug: crash when SRV is missing target (#1437)
* CLOUDFLARE: Bug: crash when SRV is missing target

* fixup!
2022-03-03 16:53:54 -05:00
Tom Limoncelli
e2eb288482
BIND: Fix test that fails on second run (#1434)
* maint: sort lists in build/generate/featureMatrix.go

* maint: sort lists in docs/byo-secrets.md

* maint: sort lists in models/record.go

* maint: sort lists in pkg/normalize/validate.go

* maint: sort lists in providers/activedir/activedirProvider.go

* maint: sort lists in providers/akamaiedgedns/akamaiEdgeDnsProvider.go

* maint: sort lists in providers/axfrddns/axfrddnsProvider.go

* maint: sort lists in providers/azuredns/azureDnsProvider.go

* maint: sort lists in providers/cloudflare/cloudflareProvider.go

* maint: sort lists in providers/cloudns/cloudnsProvider.go

* maint: sort lists in providers/desec/desecProvider.go

* maint: sort lists in providers/digitalocean/digitaloceanProvider.go

* maint: sort lists in providers/dnsimple/dnsimpleProvider.go

* maint: sort lists in providers/dnsmadeeasy/dnsMadeEasyProvider.go

* maint: sort lists in providers/exoscale/exoscaleProvider.go

* maint: sort lists in providers/gandiv5/gandi_v5Provider.go

* maint: sort lists in providers/hedns/hednsProvider.go

* maint: sort lists in providers/hetzner/hetznerProvider.go

* maint: sort lists in providers/hexonet/hexonetProvider.go

* maint: sort lists in providers/inwx/inwxProvider.go

* maint: sort lists in providers/linode/linodeProvider.go

* maint: sort lists in providers/namecheap/namecheapProvider.go

* maint: sort lists in providers/namedotcom/namedotcomProvider.go

* maint: sort lists in providers/netcup/netcupProvider.go

* maint: sort lists in providers/ns1/ns1Provider.go

* maint: sort lists in providers/octodns/octodnsProvider.go

* maint: sort lists in providers/oracle/oracleProvider.go

* maint: sort lists in providers/ovh/ovhProvider.go

* maint: sort lists in providers/packetframe/packetframeProvider.go

* maint: sort lists in providers/powerdns/powerdnsProvider.go

* maint: sort lists in providers/route53/route53Provider.go

* maint: sort lists in providers/vultr/vultrProvider.go

* Update go:build pragmas for windows

* More sorting

* go generate

* fix failing test
2022-03-03 08:04:14 -05:00
Tom Limoncelli
444b893e1b
MAINT: Sort various lists (#1433)
* maint: sort lists in build/generate/featureMatrix.go

* maint: sort lists in docs/byo-secrets.md

* maint: sort lists in models/record.go

* maint: sort lists in pkg/normalize/validate.go

* maint: sort lists in providers/activedir/activedirProvider.go

* maint: sort lists in providers/akamaiedgedns/akamaiEdgeDnsProvider.go

* maint: sort lists in providers/axfrddns/axfrddnsProvider.go

* maint: sort lists in providers/azuredns/azureDnsProvider.go

* maint: sort lists in providers/cloudflare/cloudflareProvider.go

* maint: sort lists in providers/cloudns/cloudnsProvider.go

* maint: sort lists in providers/desec/desecProvider.go

* maint: sort lists in providers/digitalocean/digitaloceanProvider.go

* maint: sort lists in providers/dnsimple/dnsimpleProvider.go

* maint: sort lists in providers/dnsmadeeasy/dnsMadeEasyProvider.go

* maint: sort lists in providers/exoscale/exoscaleProvider.go

* maint: sort lists in providers/gandiv5/gandi_v5Provider.go

* maint: sort lists in providers/hedns/hednsProvider.go

* maint: sort lists in providers/hetzner/hetznerProvider.go

* maint: sort lists in providers/hexonet/hexonetProvider.go

* maint: sort lists in providers/inwx/inwxProvider.go

* maint: sort lists in providers/linode/linodeProvider.go

* maint: sort lists in providers/namecheap/namecheapProvider.go

* maint: sort lists in providers/namedotcom/namedotcomProvider.go

* maint: sort lists in providers/netcup/netcupProvider.go

* maint: sort lists in providers/ns1/ns1Provider.go

* maint: sort lists in providers/octodns/octodnsProvider.go

* maint: sort lists in providers/oracle/oracleProvider.go

* maint: sort lists in providers/ovh/ovhProvider.go

* maint: sort lists in providers/packetframe/packetframeProvider.go

* maint: sort lists in providers/powerdns/powerdnsProvider.go

* maint: sort lists in providers/route53/route53Provider.go

* maint: sort lists in providers/vultr/vultrProvider.go

* Update go:build pragmas for windows

* More sorting

* go generate
2022-03-02 11:19:15 -05:00
tpdn
fc75f89271
ClouDNS: Add CLOUDNS_WR (Web Redirects) (#1421)
Co-authored-by: Tom Limoncelli <tlimoncelli@stackoverflow.com>
2022-03-02 09:21:51 -05:00
Tom Limoncelli
1f741088a9
MAINT: Bump github.com/miekg/dns from 1.1.45 to 1.1.46 (#1431) 2022-03-01 14:53:10 -05:00
Tom Limoncelli
d9c4d391a9
MAINT: go generate (#1432) 2022-03-01 14:39:11 -05:00
Tom Limoncelli
0b15a3a6d2
MAINT: Update dependencies (#1429) 2022-03-01 13:01:51 -05:00
Tom Limoncelli
d457bce437
DOCS: Update README with GHA and LE news (#1428) 2022-03-01 11:44:41 -05:00
Tom Limoncelli
363558f369
EASYNAME: Source filename should conform to standard (#1422) 2022-03-01 09:53:20 -05:00
Tom Limoncelli
1f237b2c92
ROUTE53: Fix shortname bug for get-zones (#1418) 2022-02-28 11:35:17 -05:00