]> granicus.if.org Git - pdns/log
pdns
7 years agoMerge pull request #5480 from rgacogne/rec40-5416-cache-expired
Pieter Lexis [Mon, 3 Jul 2017 08:49:56 +0000 (10:49 +0200)]
Merge pull request #5480 from rgacogne/rec40-5416-cache-expired

rec: Backport #5416: Move expired cache entries to the front so they are expunged

7 years agoRemove just enough entries from the cache, not one more than asked
Remi Gacogne [Tue, 20 Jun 2017 15:09:56 +0000 (17:09 +0200)]
Remove just enough entries from the cache, not one more than asked

(cherry picked from commit f3cb7c78abe3ad639d4583880ae9302b3be99a9e)

7 years agorec: Move expired cache entries to the front so they are expunged
Remi Gacogne [Thu, 15 Jun 2017 16:17:23 +0000 (18:17 +0200)]
rec: Move expired cache entries to the front so they are expunged

(cherry picked from commit 197d755ea3972251352170261a9d7024ca95175c)

7 years agoMerge pull request #5471 from pieterlexis/rec-406-b-root
bert hubert [Thu, 29 Jun 2017 18:54:58 +0000 (20:54 +0200)]
Merge pull request #5471 from pieterlexis/rec-406-b-root

Backport #4497 and #5470: Add E and B root IPv6 addresses

7 years agorec: changed IPv6 addr of b.root-servers.net
Arsen Stasic [Tue, 27 Jun 2017 11:02:53 +0000 (13:02 +0200)]
rec: changed IPv6 addr of b.root-servers.net

http://www.internic.net/domain/db.cache
last update:    June 01, 2017
is effective since 2017-06-01

(cherry picked from commit 951ab1a12096a6cf8514282c5f5d4d7641bc87ae)

7 years agoe.root-servers.net has IPv6 now
phonedph1 [Fri, 23 Sep 2016 00:41:58 +0000 (18:41 -0600)]
e.root-servers.net has IPv6 now

(cherry picked from commit b815c62e1a4be01b4a2a7833855116b8781f86f6)

7 years agoMerge pull request #5462 from pieterlexis/rex-406-backport-5455
Pieter Lexis [Tue, 27 Jun 2017 10:05:31 +0000 (12:05 +0200)]
Merge pull request #5462 from pieterlexis/rex-406-backport-5455

Backport 5455: Travis: Use auth 4.0 for recursor tests

7 years agoTravis: Use auth 4.0 for recursor tests
Pieter Lexis [Fri, 23 Jun 2017 08:43:37 +0000 (10:43 +0200)]
Travis: Use auth 4.0 for recursor tests

(cherry picked from commit dad54543abf80aedefbe47f1d538542763794173)

7 years agoMerge pull request #5451 from rgacogne/rec40-requestor-payload-512
Peter van Dijk [Thu, 22 Jun 2017 14:07:25 +0000 (16:07 +0200)]
Merge pull request #5451 from rgacogne/rec40-requestor-payload-512

Backport #5446: rec: Treat requestor's payload size lower than 512 as equal to 512

7 years agorec: Treat requestor's payload size lower than 512 as equal to 512
Remi Gacogne [Thu, 22 Jun 2017 08:25:47 +0000 (10:25 +0200)]
rec: Treat requestor's payload size lower than 512 as equal to 512

(cherry picked from commit 320157487ec1cd0a9c4bcfd5309d9d651c26eb72)

7 years agoMerge pull request #5447 from Habbie/rec-4.0.x-uri
Pieter Lexis [Thu, 22 Jun 2017 12:22:51 +0000 (14:22 +0200)]
Merge pull request #5447 from Habbie/rec-4.0.x-uri

rec backport: make URI integers 16 bits, fixes #5443

7 years agoMerge pull request #5448 from mind04/rec-4.0.x
Pieter Lexis [Thu, 22 Jun 2017 12:22:42 +0000 (14:22 +0200)]
Merge pull request #5448 from mind04/rec-4.0.x

Rec 4.0.x: backport decaf signer

7 years agoadd ED448 to signers unit test
Kees Monshouwer [Mon, 19 Jun 2017 09:09:47 +0000 (11:09 +0200)]
add ED448 to signers unit test

7 years agoinitial stab at signer testing; has one 8080 test vector for now
Peter van Dijk [Sat, 17 Jun 2017 17:01:52 +0000 (19:01 +0200)]
initial stab at signer testing; has one 8080 test vector for now

7 years agodon't use the libdecaf ed25519 signer when libsodium is enabled
Kees Monshouwer [Wed, 21 Jun 2017 12:23:34 +0000 (14:23 +0200)]
don't use the libdecaf ed25519 signer when libsodium is enabled

7 years agohello decaf signers (ED25519 and ED448)
Kees Monshouwer [Sat, 17 Jun 2017 15:31:41 +0000 (17:31 +0200)]
hello decaf signers (ED25519 and ED448)
Testing algorithm 15: 'Decaf ED25519' ->'Decaf ED25519' -> 'Decaf ED25519' Signature & verify ok, signature 68usec, verify 93usec
Testing algorithm 16: 'Decaf ED448' ->'Decaf ED448' -> 'Decaf ED448' Signature & verify ok, signature 163usec, verify 252usec

7 years agomake URI integers 16 bits, fixes #5443
Peter van Dijk [Thu, 22 Jun 2017 08:09:01 +0000 (10:09 +0200)]
make URI integers 16 bits, fixes #5443

7 years agoMerge pull request #5411 from Habbie/4.0.x-5401
Peter van Dijk [Mon, 19 Jun 2017 15:12:00 +0000 (17:12 +0200)]
Merge pull request #5411 from Habbie/4.0.x-5401

unbreak quoting; fixes #5401

7 years agoMerge pull request #5424 from mind04/ed25519-r40
Peter van Dijk [Mon, 19 Jun 2017 14:46:21 +0000 (16:46 +0200)]
Merge pull request #5424 from mind04/ed25519-r40

Backport of #5422 do not hash the message in the ed25519 signer

7 years agodo not hash the message in the ed25519 signer
Kees Monshouwer [Fri, 16 Jun 2017 20:29:13 +0000 (22:29 +0200)]
do not hash the message in the ed25519 signer

https://www.rfc-editor.org/errata_search.php?rfc=8080

This is a Native zone
Metadata items: None
Zone has NSEC semantics
keys:
ID = 1 (CSK), flags = 257, tag = 3613, algo = 15, bits = 256      Active ( ED25519 )
CSK DNSKEY = example.com. IN DNSKEY 257 3 15 l02Woi0iS8Aa25FQkUd9RMzZHJpBoRQwAQEX1SxZJA4= ; ( ED25519 )
DS = example.com. IN DS 3613 15 1 b2c63605467c4a40942b47a953e9c0d38f81083a ; ( SHA1 digest )
DS = example.com. IN DS 3613 15 2 3aa5ab37efce57f737fc1627013fee07bdf241bd10f3b1964ab55c78e79a304b ; ( SHA256 digest )
DS = example.com. IN DS 3613 15 4 89389da437fca8372e67359dfc0dd4428fa2615df6e31bc5501677dd068514fea5c4efaf82188530a8a1645d9d3ef884 ; ( SHA-384 digest )

DNSKEY and DS match

7 years agoMerge pull request #5405 from rgacogne/rec40-disable-use-incoming-ecs
Peter van Dijk [Thu, 15 Jun 2017 12:30:59 +0000 (14:30 +0200)]
Merge pull request #5405 from rgacogne/rec40-disable-use-incoming-ecs

Backport #5402: rec: Disable use-incoming-edns-subnet by default

7 years agounbreak quoting; fixes #5401
Peter van Dijk [Thu, 15 Jun 2017 07:36:57 +0000 (09:36 +0200)]
unbreak quoting; fixes #5401

7 years agorec: Disable use-incoming-edns-subnet by default
Remi Gacogne [Wed, 14 Jun 2017 12:26:18 +0000 (14:26 +0200)]
rec: Disable use-incoming-edns-subnet by default

(cherry picked from commit a16c4536496ab0d3cf959bcb45e7a6cf41d02e3e)

7 years agoMerge pull request #5392 from pieterlexis/rec-405-sync-boost-m4 rec-4.0.5
Pieter Lexis [Tue, 13 Jun 2017 09:50:50 +0000 (11:50 +0200)]
Merge pull request #5392 from pieterlexis/rec-405-sync-boost-m4

Sync boost.m4 from master

7 years agoSync boost.m4 from master
Pieter Lexis [Tue, 13 Jun 2017 08:26:54 +0000 (10:26 +0200)]
Sync boost.m4 from master

7 years agoMerge pull request #5355 from rgacogne/rec40-backport-4924-1988 rec-4.0.5-rc2
Pieter Lexis [Thu, 1 Jun 2017 09:33:28 +0000 (11:33 +0200)]
Merge pull request #5355 from rgacogne/rec40-backport-4924-1988

rec-4.0.x: Backport #4924 and #4988

7 years agoMerge pull request #5345 from shinsterneck/backport-5335-rec-4.0.x
Pieter Lexis [Thu, 1 Jun 2017 09:33:19 +0000 (11:33 +0200)]
Merge pull request #5345 from shinsterneck/backport-5335-rec-4.0.x

Backport of #5335 to rec-4.0.x: configure.ac: corrects syntax error in test statement on existance of libcrypto_ecdsa

7 years agorec: Add `use-incoming-edns-subnet` to process and pass along ECS
Remi Gacogne [Thu, 9 Feb 2017 14:01:41 +0000 (15:01 +0100)]
rec: Add `use-incoming-edns-subnet` to process and pass along ECS

If set, the recusor will process and pass along a received EDNS
Client Subnet to authoritative servers.
The ECS information will only be sent for netmasks and domains listed
in `edns-subnet-whitelist`, and will be truncated if the received scope
exceeds `ecs-ipv4-bits` for IPv4 or `ecs-ipv6-bits` for IPv6.
An incoming ECS source prefix-length of 0 can also be used to
request that no ECS value be sent to the authoritative servers,
in accordance with RFC7871.

(cherry picked from commit b40562da39e3be0dcf193163c386eef369dcc4af)

7 years agoCorrectly parse ECS with a source prefix-length value of 0
Remi Gacogne [Thu, 9 Feb 2017 13:50:11 +0000 (14:50 +0100)]
Correctly parse ECS with a source prefix-length value of 0

It means there is no address there, but the family and source
prefix-length values are still relevant. rfc7871 explicitly says
that the family SHOULD be set to the transport over which the query
is sent if source prefix-length is 0.
It also states that a source prefix-length means the client is
asking that no ECS value be sent.

(cherry picked from commit 53221eafae3fe410586daf98cca0df3d81ea344c)

7 years agoadd iputils.cc to remotebackend tests
bert hubert [Wed, 18 Jan 2017 17:49:51 +0000 (18:49 +0100)]
add iputils.cc to remotebackend tests

(cherry picked from commit 4d541cb1bf211c1a707d34691ea0f3329be0bf1f)

7 years agolink in iputils.o in places that need it now for truncation of netmask
bert hubert [Wed, 18 Jan 2017 17:18:00 +0000 (18:18 +0100)]
link in iputils.o in places that need it now for truncation of netmask

(cherry picked from commit 4ba0ebc5fe17ea9263ade38d4e76b63072397296)

7 years agoadd ecs-ipv4-bits and ecs-ipv6-bits tunables for EDNS Client Subnet & document them...
bert hubert [Wed, 18 Jan 2017 15:18:46 +0000 (16:18 +0100)]
add ecs-ipv4-bits and ecs-ipv6-bits tunables for EDNS Client Subnet & document them. Split out ECS code from pdns_recursor.cc.

(cherry picked from commit 35695d184316e0686d1dc2d50ef4a4420bc95157)

7 years agomake EDNS client subnet do some better logging on --trace
bert hubert [Wed, 18 Jan 2017 15:18:23 +0000 (16:18 +0100)]
make EDNS client subnet do some better logging on --trace

(cherry picked from commit 43f759413685af3cc06587c3631009eea3434396)

7 years agoComboAddress truncate() is assumed to never throw. Enforce this.
bert hubert [Wed, 18 Jan 2017 15:17:06 +0000 (16:17 +0100)]
ComboAddress truncate() is assumed to never throw. Enforce this.

(cherry picked from commit 5b6099b2397c1b5a4789235ad5c06ac83ecfa818)

7 years agoEDNS Client Subnet parser delivered 'over precise' netmasks, like 1.2.3.4/16. This...
bert hubert [Wed, 18 Jan 2017 15:16:19 +0000 (16:16 +0100)]
EDNS Client Subnet parser delivered 'over precise' netmasks, like 1.2.3.4/16. This might have caused problems, but at the very least looks odd. We truncate now.

(cherry picked from commit b85f49a0aa392d40f00e134708c2e12aa1231870)

7 years agocorrects syntax error in test statement on existance of libcrypto_ecdsa
Shin Sterneck [Tue, 23 May 2017 00:12:26 +0000 (09:12 +0900)]
corrects syntax error in test statement on existance of libcrypto_ecdsa

(cherry picked from commit 8189c881e5ebaa13f5f14d9345335d656bd34e43)

7 years agoUse un-annotated tags for determining version rec-4.0.5-rc1
Pieter Lexis [Thu, 18 May 2017 09:08:55 +0000 (11:08 +0200)]
Use un-annotated tags for determining version

7 years agoMerge pull request #5304 from pieterlexis/rec-405-backports
Pieter Lexis [Thu, 18 May 2017 08:23:33 +0000 (10:23 +0200)]
Merge pull request #5304 from pieterlexis/rec-405-backports

Recursor backports

7 years agoRecursor 4.0.5: Backport #5319
Pieter Lexis [Wed, 17 May 2017 19:22:41 +0000 (21:22 +0200)]
Recursor 4.0.5: Backport #5319

7 years agorec: Only check the netmask for subnet specific cache entries
Remi Gacogne [Fri, 12 May 2017 12:12:10 +0000 (14:12 +0200)]
rec: Only check the netmask for subnet specific cache entries

We used to check the netmask for all entries for a qname
if at least one of them was a subnet specific one. Since an empty
`Netmask` doesn't match anything, we would effectively ignore every
non subnet specific entries if we had at least one subnet specific
one.
This caused a very hard to reproduce issue with for example
f.root-servers.net that includes an EDNS Client Subnet option in its
answer for `NS .` if the query has an EDNS Client Subnet option.
This caused the recursor to cache a subnet specific entry for `NS .`.
When that entry expired, we retrieved and cached a non subnet specific
one, but that new one was ignored as long as the subnet specific
was not expunged from the cache.
Under certain circumstances that could cause a root refresh loop
using a lot of stack memory.

(cherry picked from commit 65fdd185f4930f685b87340d29535f40d8b52fb3)

7 years agoMerge pull request #5324 from rgacogne/rec40-yahttp-backports
Pieter Lexis [Wed, 17 May 2017 08:04:34 +0000 (10:04 +0200)]
Merge pull request #5324 from rgacogne/rec40-yahttp-backports

rec-4.0.x: YaHTTP: Sync with upstream changes

7 years agoYaHTTP: Sync with upstream changes
Remi Gacogne [Mon, 15 May 2017 10:50:24 +0000 (12:50 +0200)]
YaHTTP: Sync with upstream changes

Backport changes from upstream up to c5b83288a4c2f8ec07cb8cb7bd150f2210db67b6
"Add missing `YaHTTP::isdigit()`, fix locale-enabled versions"

7 years agoRecursor 4.0.5: Backport #5318
Pieter Lexis [Sat, 13 May 2017 09:42:32 +0000 (11:42 +0200)]
Recursor 4.0.5: Backport #5318

7 years agowhen (re)priming the root, we do so with auth=0. We'll only set auth=1 after we have...
bert hubert [Fri, 12 May 2017 10:34:44 +0000 (12:34 +0200)]
when (re)priming the root, we do so with auth=0. We'll only set auth=1 after we have an answer from the roots. This however opens up a small race condition in which the root is expired (ttl=0), but still auth=1 in the cache. Our attempt to replace it with auth=0 dta fails at that point. This is probably due to some fencepost error somewhere. To not be subtle about this, explicitly nuke the root when we reprime.

(cherry picked from commit 0d032a66afe508cc86a25eef26fc9be0867a117e)

7 years agoRecursor 4.0.5: Backport #5304
Pieter Lexis [Sat, 13 May 2017 08:16:37 +0000 (10:16 +0200)]
Recursor 4.0.5: Backport #5304

7 years agodon't age the root - this was a mistranslation from 3.x to 4.x
bert hubert [Thu, 11 May 2017 15:18:04 +0000 (17:18 +0200)]
don't age the root - this was a mistranslation from 3.x to 4.x

(cherry picked from commit 03c09afecec7098a605a632606600bca2992dfaf)

7 years agoRecursor 4.0.5: Backport #5312
Pieter Lexis [Sat, 13 May 2017 07:58:40 +0000 (09:58 +0200)]
Recursor 4.0.5: Backport #5312

7 years agowe would attempt to protobuf log DNS questions without a set question and get excepti...
bert hubert [Thu, 11 May 2017 15:16:20 +0000 (17:16 +0200)]
we would attempt to protobuf log DNS questions without a set question and get exceptions over that

(cherry picked from commit da5bcd9d891418b9462c76fbc87fd7e18fa374c8)

7 years agoMerge pull request #5300 from rgacogne/rec40-dnssec-cache-auth
Pieter Lexis [Tue, 9 May 2017 14:24:04 +0000 (16:24 +0200)]
Merge pull request #5300 from rgacogne/rec40-dnssec-cache-auth

Backport #5283: rec: Skip DNSSEC validation for cache hits from authoritative zones

7 years agoRecursor 4.0.5: Backport #5265
Pieter Lexis [Tue, 9 May 2017 12:54:25 +0000 (14:54 +0200)]
Recursor 4.0.5: Backport #5265

7 years agorec: Add support for RPZ wildcarded target names
Remi Gacogne [Sun, 23 Apr 2017 18:56:36 +0000 (20:56 +0200)]
rec: Add support for RPZ wildcarded target names

7 years agoRecursor 4.0.5: Backport #5278
Pieter Lexis [Tue, 9 May 2017 12:18:13 +0000 (14:18 +0200)]
Recursor 4.0.5: Backport #5278

7 years agoAlways wrap DNSCryptoKeyEngine objects in a shared pointer
Remi Gacogne [Thu, 27 Apr 2017 20:41:33 +0000 (22:41 +0200)]
Always wrap DNSCryptoKeyEngine objects in a shared pointer

It's done almost everywhere, but not quite, and some of the paths
where it's not could leak if an exception is raised.
Also mark the overridden virtual methods with `override` to prevent
future mistakes.

(cherry picked from commit e69c2dac28d798813dd8e4a986c5045c63806ef0)

7 years agoRecursor 4.0.5: Backport #5231
Pieter Lexis [Tue, 9 May 2017 10:17:46 +0000 (12:17 +0200)]
Recursor 4.0.5: Backport #5231

7 years agorec: Clear the RPZ NS IP table when clearing the policy
Remi Gacogne [Mon, 10 Apr 2017 16:33:30 +0000 (18:33 +0200)]
rec: Clear the RPZ NS IP table when clearing the policy

Be it the entire policy object or a single zone.

(cherry picked from commit 2ae5639865ca29aa0c7b722e55e9098b81627700)

7 years agoRcursor 4.0.5: Backport #5218
Pieter Lexis [Tue, 9 May 2017 10:12:24 +0000 (12:12 +0200)]
Rcursor 4.0.5: Backport #5218

7 years agorec: Fix cache-only queries against a forward-zone
Remi Gacogne [Mon, 3 Apr 2017 08:53:41 +0000 (10:53 +0200)]
rec: Fix cache-only queries against a forward-zone

We used to pass the return code from `asyncresolve` directly to the
caller, leading the success code (1) to be interpreted as `RCode::FormErr`.

(cherry picked from commit 6148fa9731f6e4cef35243c8f35399d2b1e89215)

7 years agoRecursor: Backport #5147
Pieter Lexis [Tue, 9 May 2017 10:11:15 +0000 (12:11 +0200)]
Recursor: Backport #5147

7 years agoLuaWrapper: Allow embedded NULs in strings received from Lua
Peter van Dijk [Fri, 10 Mar 2017 09:48:46 +0000 (10:48 +0100)]
LuaWrapper: Allow embedded NULs in strings received from Lua

(cherry picked from commit 448990ab9bd7355f42ff8752a973aff20bdaf4e7)

7 years agoRecursor 4.0.5: Backport #4912
Pieter Lexis [Tue, 9 May 2017 10:02:42 +0000 (12:02 +0200)]
Recursor 4.0.5: Backport #4912

7 years agoRefuse to start with chroot set in a systemd env
Pieter Lexis [Mon, 16 Jan 2017 11:37:13 +0000 (12:37 +0100)]
Refuse to start with chroot set in a systemd env

Closes #4848

(cherry picked from commit 75336810381e4cdc25d0beab7c19abb910cea3ab)

7 years agoRecursor 4.0.5: Backport #4877
Pieter Lexis [Tue, 9 May 2017 09:50:58 +0000 (11:50 +0200)]
Recursor 4.0.5: Backport #4877

7 years agoissue #4579
Roman Dayneko [Wed, 11 Jan 2017 14:46:17 +0000 (16:46 +0200)]
issue #4579

(cherry picked from commit 28fe507d1acc3b4fe7b5669caac9f4bd4a516093)

7 years agoBackport #4873 into Recursor 4.0.5
Pieter Lexis [Tue, 9 May 2017 09:46:41 +0000 (11:46 +0200)]
Backport #4873 into Recursor 4.0.5

7 years agohook up ed25519 signer in the recursor
Kees Monshouwer [Tue, 10 Jan 2017 21:50:12 +0000 (22:50 +0100)]
hook up ed25519 signer in the recursor

(cherry picked from commit d1b28475acae46cf39d2a883791953910b89ea67)

7 years agoupdate Ed25519 algorithm number and mnemonic
Kees Monshouwer [Tue, 10 Jan 2017 15:04:22 +0000 (16:04 +0100)]
update Ed25519 algorithm number and mnemonic
http://www.iana.org/assignments/dns-sec-alg-numbers/dns-sec-alg-numbers.xhtml

(cherry picked from commit 9d3727e0471f132f0294d6944349eb6afb2ba2ab)

7 years agorec: Skip DNSSEC validation for cache hits from authoritative zones
Remi Gacogne [Fri, 28 Apr 2017 17:01:26 +0000 (19:01 +0200)]
rec: Skip DNSSEC validation for cache hits from authoritative zones

(cherry picked from commit 129bb0c322b6a20860c14f0b1bcfcad2bd586389)

7 years agoMerge pull request #5148 from rgacogne/rec40-backport-5139
Peter van Dijk [Mon, 20 Mar 2017 13:07:09 +0000 (14:07 +0100)]
Merge pull request #5148 from rgacogne/rec40-backport-5139

Backport #5139: rec: Run unit tests, split recursor-specific unit tests from the auth

7 years agoMerge pull request #5164 from rgacogne/rec40-backport-5101
Peter van Dijk [Mon, 20 Mar 2017 13:06:20 +0000 (14:06 +0100)]
Merge pull request #5164 from rgacogne/rec40-backport-5101

Backport #5101: rec-4.0.x: Fix minor issues reported by `cppcheck`

7 years agoMerge pull request #5165 from rgacogne/rec40-backport-5058
Peter van Dijk [Mon, 20 Mar 2017 13:06:05 +0000 (14:06 +0100)]
Merge pull request #5165 from rgacogne/rec40-backport-5058

Backport #5058: Rec: Store the RPZ policies in an unordered_map instead of a map

7 years agoMerge pull request #5166 from rgacogne/rec40-backport-5042
Peter van Dijk [Mon, 20 Mar 2017 13:05:19 +0000 (14:05 +0100)]
Merge pull request #5166 from rgacogne/rec40-backport-5042

Backport #5042: StateHolder: Allocate (and copy if needed) before taking the lock

7 years agoStateHolder: Allocate (and copy if needed) before taking the lock
Remi Gacogne [Tue, 14 Feb 2017 17:46:38 +0000 (18:46 +0100)]
StateHolder: Allocate (and copy if needed) before taking the lock

(cherry picked from commit 47678b827e9b20a23352e381b16312f1c29831de)

7 years agoRec: Store the RPZ policies in an unordered_map instead of a map
Remi Gacogne [Mon, 20 Feb 2017 14:45:22 +0000 (15:45 +0100)]
Rec: Store the RPZ policies in an unordered_map instead of a map

This speeds up the loading of huge zones a bit (~20%) while also nicely
improving the lookup speed.
Also adds a `zoneSizeHint` parameter to `rpzFile()` and `rpzMaster()` to be
able to reserve space before loading the zone, to prevent reallocation
and rehashing when possible.

(cherry picked from commit a2d0450ec9fa958308fe0c40499ce28228bb3f00)

7 years agoFix minor issues reported by `cppcheck`
Remi Gacogne [Thu, 2 Mar 2017 14:07:56 +0000 (15:07 +0100)]
Fix minor issues reported by `cppcheck`

(cherry picked from commit d7c676a5d42d5d7e5078a8662d355c9a782bdb51)

7 years agoFix dns_random unit tests with gcc > 4
Remi Gacogne [Wed, 15 Mar 2017 14:42:02 +0000 (15:42 +0100)]
Fix dns_random unit tests with gcc > 4

(cherry picked from commit 4b587bc5a1a25a285c614ae772f0896d65954ad9)

7 years agorec: Run unit tests, split recursor-specific unit tests from the auth
Remi Gacogne [Mon, 13 Mar 2017 12:52:51 +0000 (13:52 +0100)]
rec: Run unit tests, split recursor-specific unit tests from the auth

Some unit tests are common and will be run twice, once in the auth
build and once in the rec one. This ensures that they will be run on
rec-4.0.x and auth-4.0.x branches as well.

(cherry picked from commit 35d883a830af0284efafe94d1a6bd1c1ad04bae7)

7 years agoMerge pull request #4935 from rgacogne/rec40-backport-4911
Pieter Lexis [Fri, 17 Feb 2017 09:59:13 +0000 (10:59 +0100)]
Merge pull request #4935 from rgacogne/rec40-backport-4911

Backport #4911: Fix negative port detection for IPv6 addresses on 32-bit

7 years agoMerge pull request #5047 from rgacogne/rec40-backport-4744
Pieter Lexis [Fri, 17 Feb 2017 09:58:52 +0000 (10:58 +0100)]
Merge pull request #5047 from rgacogne/rec40-backport-4744

backport #4744: Handle exceptions raised by `closesocket()`

7 years agoMerge pull request #5045 from rgacogne/rec40-backport-4917
Pieter Lexis [Fri, 17 Feb 2017 09:58:37 +0000 (10:58 +0100)]
Merge pull request #5045 from rgacogne/rec40-backport-4917

backport #4917: rec: Clean up, fix compiler warnings

7 years agoMerge pull request #4970 from rgacogne/rec40-tsig-canonical-algo
Pieter Lexis [Fri, 17 Feb 2017 09:58:28 +0000 (10:58 +0100)]
Merge pull request #4970 from rgacogne/rec40-tsig-canonical-algo

Backport #4961: Lowercase the TSIG algorithm name in hash computation

7 years agoExplicitely use const iterators in `validateWithKeySet` and `getKeysFor`
Remi Gacogne [Mon, 16 Jan 2017 17:05:34 +0000 (18:05 +0100)]
Explicitely use const iterators in `validateWithKeySet` and `getKeysFor`

(cherry picked from commit 7a4f4632913046afde9e8acbbff1213b8faf982d)

7 years agoMake sure `labelsToAdd` is not empty in `getZoneCuts()`
Remi Gacogne [Mon, 16 Jan 2017 16:53:06 +0000 (17:53 +0100)]
Make sure `labelsToAdd` is not empty in `getZoneCuts()`

(cherry picked from commit e2f91e7051975a411445ebd54a2a124c78a7d8ff)

7 years agoRemove `g_rootDS` leftover
Remi Gacogne [Mon, 16 Jan 2017 16:51:49 +0000 (17:51 +0100)]
Remove `g_rootDS` leftover

(cherry picked from commit 08d5ffac729f6aaa2f63d070a7fcefe42e3c32f4)

7 years agoRemove unused `RemoteLogger::sendData()` leftover
Remi Gacogne [Mon, 16 Jan 2017 16:46:59 +0000 (17:46 +0100)]
Remove unused `RemoteLogger::sendData()` leftover

(cherry picked from commit 59ab41170cee9b95513bdc931a5f125a0c3de205)

7 years agorec: Fix shadowed variables
Remi Gacogne [Mon, 16 Jan 2017 16:45:34 +0000 (17:45 +0100)]
rec: Fix shadowed variables

No real issue here, but I'd like to be able `-Wshadow` to prevent
future mishaps at some point.

(cherry picked from commit dd07976412d9b2b35db7179ceb590e542aff9eef)

7 years agoHandle exceptions raised by `closesocket()`
Remi Gacogne [Mon, 5 Dec 2016 15:42:55 +0000 (16:42 +0100)]
Handle exceptions raised by `closesocket()`

This was not very well handled, and could cause the PowerDNS process
to terminate. This is especially nasty when `closesocket()` is called
from a destructor, as we could already be dealing with an exception.

(cherry picked from commit a7b68ae7e414ec9f3184df70ac8008f8a310ae60)

7 years agoMerge pull request #5034 from pieterlexis/rec-backport-4508
Pieter Lexis [Thu, 16 Feb 2017 11:22:23 +0000 (12:22 +0100)]
Merge pull request #5034 from pieterlexis/rec-backport-4508

Backport #4508: Revert "Merge pull request #947 from mind04/right" (rec)

7 years agoMerge pull request #5028 from pieterlexis/backport-4619
Pieter Lexis [Thu, 16 Feb 2017 11:22:16 +0000 (12:22 +0100)]
Merge pull request #5028 from pieterlexis/backport-4619

Backport #4619: Document the -pub- variants

7 years agoMerge pull request #5023 from pieterlexis/backport-4767
Pieter Lexis [Thu, 16 Feb 2017 11:22:09 +0000 (12:22 +0100)]
Merge pull request #5023 from pieterlexis/backport-4767

Backport #4767: hide ttl in RPZ tests to avoid random failures

7 years agoMerge pull request #5035 from pieterlexis/backport-4794
Pieter Lexis [Thu, 16 Feb 2017 11:21:50 +0000 (12:21 +0100)]
Merge pull request #5035 from pieterlexis/backport-4794

Backport #4794: RPZ: some logging fixes

7 years agoMerge pull request #5031 from pieterlexis/backport-4603
Pieter Lexis [Thu, 16 Feb 2017 11:21:13 +0000 (12:21 +0100)]
Merge pull request #5031 from pieterlexis/backport-4603

Backport #4603: g.root-servers.net added IPv6

7 years agoMerge pull request #5025 from pieterlexis/rec-backport-4762
Pieter Lexis [Thu, 16 Feb 2017 11:20:28 +0000 (12:20 +0100)]
Merge pull request #5025 from pieterlexis/rec-backport-4762

Backport #4762: SuffixMatchNode: Fix insertion issue for an existing node (rec)

7 years agoMerge pull request #5022 from pieterlexis/backport-4775
Pieter Lexis [Thu, 16 Feb 2017 11:19:39 +0000 (12:19 +0100)]
Merge pull request #5022 from pieterlexis/backport-4775

Backport #4775: LuaWrapper: Use the correct index when storing a function

7 years agoMerge pull request #5021 from pieterlexis/backport-4777
Pieter Lexis [Thu, 16 Feb 2017 11:19:28 +0000 (12:19 +0100)]
Merge pull request #5021 from pieterlexis/backport-4777

Backport #4777: only delegate if NS's are below apex in auth-zones

7 years agoMerge pull request #5020 from pieterlexis/rec-backport-4793
Pieter Lexis [Thu, 16 Feb 2017 11:19:16 +0000 (12:19 +0100)]
Merge pull request #5020 from pieterlexis/rec-backport-4793

Backport #4793: Don't call `hostname -f` on openbsd (rec)

7 years agoMerge pull request #5018 from pieterlexis/backport-4804
Pieter Lexis [Thu, 16 Feb 2017 11:19:02 +0000 (12:19 +0100)]
Merge pull request #5018 from pieterlexis/backport-4804

Backport #4804: remove hardcoding of port 53 for TCP/IP forwarded zones in recursor, …

7 years agoMerge pull request #5017 from pieterlexis/rec-backport-4838
Pieter Lexis [Thu, 16 Feb 2017 11:18:50 +0000 (12:18 +0100)]
Merge pull request #5017 from pieterlexis/rec-backport-4838

backport #4838: Check if we can link against libatomic if needed (rec)

7 years agoMerge pull request #5014 from pieterlexis/rec-backport-4868
Pieter Lexis [Thu, 16 Feb 2017 11:18:26 +0000 (12:18 +0100)]
Merge pull request #5014 from pieterlexis/rec-backport-4868

Backport #4868: Document that carbon-server requires IP address, no hostname accepted. (rec)

7 years agoMerge pull request #5012 from pieterlexis/rec-backport-4879
Pieter Lexis [Thu, 16 Feb 2017 11:18:11 +0000 (12:18 +0100)]
Merge pull request #5012 from pieterlexis/rec-backport-4879

Backport #4879: Remove a relative import in yahttp-config.h (rec)

7 years agoMerge pull request #5010 from pieterlexis/backport-4940
Pieter Lexis [Thu, 16 Feb 2017 11:17:43 +0000 (12:17 +0100)]
Merge pull request #5010 from pieterlexis/backport-4940

Backport #4940: Backport json11 fixes from upstream