]> git.ipfire.org Git - thirdparty/pdns.git/log
thirdparty/pdns.git
5 years agoBackport #6562
Remi Gacogne [Wed, 16 May 2018 10:04:46 +0000 (12:04 +0200)] 
Backport #6562

5 years agocheck if parameter has been submitted before accessing it
Charles-Henri Bruyand [Wed, 2 May 2018 14:18:50 +0000 (16:18 +0200)] 
check if parameter has been submitted before accessing it

(cherry picked from commit 46d03ec1bde4eb3241f510f300e2a302dcfe65d0)

5 years agodetails version the subtree parameters has been added
Charles-Henri Bruyand [Wed, 2 May 2018 14:17:31 +0000 (16:17 +0200)] 
details version the subtree parameters has been added

(cherry picked from commit b3cccb9d3d61161c026ff2225582dcc685d4894a)

5 years agoSkip subtree option tests against auth
Charles-Henri Bruyand [Wed, 2 May 2018 13:55:34 +0000 (15:55 +0200)] 
Skip subtree option tests against auth

(cherry picked from commit 921442337d81d1e9a4fa0e1f70f140e1f3ccf472)

5 years agorec api: add subtree option to the cache flush endpoint
Charles-Henri Bruyand [Wed, 2 May 2018 12:07:13 +0000 (14:07 +0200)] 
rec api: add subtree option to the cache flush endpoint

(cherry picked from commit d19c22a15f8e75ebc6ff22665ba8e8c2152957db)

5 years agorec: Move doStats out of houseKeeping()
Remi Gacogne [Tue, 15 May 2018 08:30:32 +0000 (10:30 +0200)] 
rec: Move doStats out of houseKeeping()

(cherry picked from commit 5b05b92fde73d19f8b1c5edffa359b6065f96fd2)

5 years agorec: Remove extra new line
Remi Gacogne [Mon, 14 May 2018 07:44:15 +0000 (09:44 +0200)] 
rec: Remove extra new line

(cherry picked from commit 46b2604070c76cabd27fda3257b7f1539d3c64c4)

5 years agorec: Replace yet another 0 with s_distributorThreadID
Remi Gacogne [Mon, 14 May 2018 07:36:15 +0000 (09:36 +0200)] 
rec: Replace yet another 0 with s_distributorThreadID

(cherry picked from commit 08cb9fd69a0c0df570b81a2cc1a64e15f7ac97ac)

5 years agorec: Don't call the broadcast function twice in the handler thread
Remi Gacogne [Mon, 7 May 2018 13:21:31 +0000 (15:21 +0200)] 
rec: Don't call the broadcast function twice in the handler thread

Also add some comments to clarify how the threads work.

(cherry picked from commit d27edfeb252a2d7745cb8353a7145967b686cc1d)

5 years agorec: Set pointers to nullptr after delete in the broadcast functions
Remi Gacogne [Fri, 4 May 2018 09:02:31 +0000 (10:02 +0100)] 
rec: Set pointers to nullptr after delete in the broadcast functions

(cherry picked from commit e15b5d5d00040985d5e150ab0641ca77b358d36a)

5 years agorec: Fix ACL and domain map updates in the handler thread
Remi Gacogne [Thu, 3 May 2018 14:16:25 +0000 (15:16 +0100)] 
rec: Fix ACL and domain map updates in the handler thread

(cherry picked from commit b6904a9f1581fe5d9b9024748d34e999cf694d37)

5 years agorec: Use constants for the handler and distributor thread ids
Remi Gacogne [Thu, 3 May 2018 14:01:46 +0000 (15:01 +0100)] 
rec: Use constants for the handler and distributor thread ids

(cherry picked from commit badb05fe4c358ab8f206f4a7842368d87bd90415)

5 years agorec: Move carbon/webserver/control/stats handling to a separate thread
Remi Gacogne [Thu, 3 May 2018 12:27:18 +0000 (13:27 +0100)] 
rec: Move carbon/webserver/control/stats handling to a separate thread

This makes sure that no worker or distributor thread will get blocked
while waiting for a response from another thread, for example while
gathering stats or executing a command coming from the control
channel.

(cherry picked from commit b8dc631ae02733f35130af7b27ccb9342069e2d8)

5 years agorec: Delay RPZ threads creation until the Lua config has been parsed
Remi Gacogne [Wed, 9 May 2018 10:53:06 +0000 (12:53 +0200)] 
rec: Delay RPZ threads creation until the Lua config has been parsed

Otherwise if the parsing of the remaining Lua directives takes longer
than the AXFR, our zone content will be replaced by an empty zone
once the parsing finishes.

(cherry picked from commit 1bf8d12ac362eadfc88567e050cc0ef3805ef355)

5 years agoUpdate copyright years to 2018 6611/head
Pieter Lexis [Tue, 2 Jan 2018 08:57:59 +0000 (09:57 +0100)] 
Update copyright years to 2018

Also update several years to match the data in pdns/version.cc

5 years agorec: Load RPZ safely from the RPZIXFRTracker
Pieter Lexis [Tue, 8 May 2018 20:47:33 +0000 (21:47 +0100)] 
rec: Load RPZ safely from the RPZIXFRTracker

(cherry picked from commit ed517a9a2c00814b81655d2ae518fdaafb7f063d)

5 years agorec: Fix the description of several metrics in the SNMP MIB
Remi Gacogne [Mon, 7 May 2018 13:01:15 +0000 (15:01 +0200)] 
rec: Fix the description of several metrics in the SNMP MIB

(cherry picked from commit b958640c49d95f6953a0bd1c5635802db883fa2a)

5 years agorec: Check that the query distribution pipe has been set non-blocking
Remi Gacogne [Mon, 7 May 2018 12:57:47 +0000 (14:57 +0200)] 
rec: Check that the query distribution pipe has been set non-blocking

(cherry picked from commit d10307c547c0a4178f71dac10e86428c2877b5f6)

5 years agorec: Use a separate, non-blocking pipe to distribute queries
Remi Gacogne [Thu, 3 May 2018 11:17:50 +0000 (12:17 +0100)] 
rec: Use a separate, non-blocking pipe to distribute queries

This allows us to drop queries when a pipe goes full, thus still
distributing queries to other threads instead of blocking. It also
adds a new metric to keep track of queries dropped because the pipe
was full.

(cherry picked from commit cf8cda180674c58d7a56b528d379aceaf9641746)

5 years agoMerge pull request #6596 from Habbie/backport-6478
Remi Gacogne [Fri, 11 May 2018 07:55:40 +0000 (09:55 +0200)] 
Merge pull request #6596 from Habbie/backport-6478

Fix a warning on botan >= 2.5.0

5 years agoFix a warning on botan >= 2.5.0 6596/head
Remi Gacogne [Thu, 12 Apr 2018 12:36:09 +0000 (14:36 +0200)] 
Fix a warning on botan >= 2.5.0

(cherry picked from commit 7d9895fe11d5371f5d775d9f13a8b52f494021b1)

5 years agoreorder includes to avoid Boost L conflict 6595/head
Peter van Dijk [Thu, 10 May 2018 11:42:44 +0000 (13:42 +0200)] 
reorder includes to avoid Boost L conflict

5 years agoMerge pull request #6583 from rgacogne/backport-6574
Pieter Lexis [Thu, 10 May 2018 07:56:47 +0000 (08:56 +0100)] 
Merge pull request #6583 from rgacogne/backport-6574

Backport 6574 to 4.1.x: rec: Add _raw versions for qname / ComboAddresses to the FFI API

5 years agoMerge pull request #6586 from rgacogne/rec41-ecs-index-canon
Pieter Lexis [Thu, 10 May 2018 07:56:06 +0000 (08:56 +0100)] 
Merge pull request #6586 from rgacogne/rec41-ecs-index-canon

 rec: Use canonical ordering in the ECS index

5 years agorec: Use canonical ordering in the ECS index 6586/head
Remi Gacogne [Wed, 9 May 2018 08:28:04 +0000 (10:28 +0200)] 
rec: Use canonical ordering in the ECS index

The recursor's ECS index used the `DNSName`'s case insensitive
reverse lexicographical ordering (default) instead of the canonical
ordering one.
While quite faster, it isn't exactly right.

5 years agorec: Add unit tests for wiping the cache
Remi Gacogne [Wed, 9 May 2018 08:02:19 +0000 (10:02 +0200)] 
rec: Add unit tests for wiping the cache

(cherry picked from commit ce3697ad69dd79be40fbe1f2b00a480c84a8f17a)

5 years agorec: Add _raw versions for qname / ComboAddresses to the FFI API 6583/head
Remi Gacogne [Mon, 7 May 2018 10:03:24 +0000 (12:03 +0200)] 
rec: Add _raw versions for qname / ComboAddresses to the FFI API

(cherry picked from commit aedec560c6494e838d92e9a8106d5ff87367eb83)

6 years agoMerge pull request #6514 from rgacogne/rec41-backport-6511
Remi Gacogne [Wed, 18 Apr 2018 08:30:33 +0000 (10:30 +0200)] 
Merge pull request #6514 from rgacogne/rec41-backport-6511

rec-4.1.x: Add -rdynamic to C{,XX}FLAGS when we build with LuaJIT

6 years agorec: Add -rdynamic to C{,XX}FLAGS when we build with LuaJIT 6514/head
Remi Gacogne [Wed, 18 Apr 2018 08:04:19 +0000 (10:04 +0200)] 
rec: Add -rdynamic to C{,XX}FLAGS when we build with LuaJIT

6 years agoMerge pull request #6418 from zeha/backport-6179
Remi Gacogne [Fri, 30 Mar 2018 08:42:03 +0000 (10:42 +0200)] 
Merge pull request #6418 from zeha/backport-6179

Backport of #6179

6 years agoMerge pull request #6419 from zeha/backport-6086
Remi Gacogne [Fri, 30 Mar 2018 08:41:55 +0000 (10:41 +0200)] 
Merge pull request #6419 from zeha/backport-6086

Backport of #6086

6 years agorec: Use the SyncRes time in our unit tests when checking cache validity 6419/head
Remi Gacogne [Mon, 11 Dec 2017 12:46:13 +0000 (13:46 +0100)] 
rec: Use the SyncRes time in our unit tests when checking cache validity

This might not fix our apparently random failures, but it will at least
remove on possible cause.

6 years agoIncrease MTasker stacksize 6418/head
James Cowgill [Fri, 12 Jan 2018 21:26:03 +0000 (22:26 +0100)] 
Increase MTasker stacksize

Throwing an exception uses libgcc's stack unwinder. On mips64el
the unwinder will overflow the default stack size of 8K. In turn
the return ucontext gets overwritten, resulting in a jump into
garbage.

6 years agoMerge pull request #6410 from Habbie/rec-4.1.x-json-sorting rec-4.1.2
Peter van Dijk [Tue, 27 Mar 2018 21:55:34 +0000 (23:55 +0200)] 
Merge pull request #6410 from Habbie/rec-4.1.x-json-sorting

backport jq/sorting fixes from #6304 to rec 4.1

6 years agomake travis happy about new json sorting? 6410/head
Peter van Dijk [Sun, 4 Mar 2018 21:24:23 +0000 (22:24 +0100)] 
make travis happy about new json sorting?

(cherry picked from commit c91df3a1425e507b08c5410196833eb80672eab6)

6 years agotest: fix comments-in-forward-zones-file sorting?
Peter van Dijk [Tue, 27 Feb 2018 21:11:12 +0000 (22:11 +0100)] 
test: fix comments-in-forward-zones-file sorting?

(cherry picked from commit ffc999e4a6feb44e8a558049e313b9d676e2c71a)

6 years agoMerge pull request #6387 from pieterlexis/rec-4.1.2-backports
Pieter Lexis [Tue, 27 Mar 2018 12:26:05 +0000 (14:26 +0200)] 
Merge pull request #6387 from pieterlexis/rec-4.1.2-backports

Recursor 4.1.2 backports

6 years agoMerge pull request #6385 from rgacogne/backport-6344
Pieter Lexis [Tue, 27 Mar 2018 12:25:42 +0000 (14:25 +0200)] 
Merge pull request #6385 from rgacogne/backport-6344

Backport 6344 to rec 4.1.x: Add a new Lua FFI hook, gettag-ffi

6 years agoBackport #6172 6387/head
Pieter Lexis [Mon, 26 Mar 2018 11:00:25 +0000 (13:00 +0200)] 
Backport #6172

6 years agoBackport #6055
Pieter Lexis [Mon, 26 Mar 2018 11:00:15 +0000 (13:00 +0200)] 
Backport #6055

6 years agoBackport #6300
Pieter Lexis [Mon, 26 Mar 2018 10:59:38 +0000 (12:59 +0200)] 
Backport #6300

6 years agoBackport #6320
Pieter Lexis [Mon, 26 Mar 2018 10:59:27 +0000 (12:59 +0200)] 
Backport #6320

6 years agoBackport #6379
Pieter Lexis [Mon, 26 Mar 2018 10:59:11 +0000 (12:59 +0200)] 
Backport #6379

6 years agorec: Set the visibility of FFI functions to 'default' (external) 6385/head
Remi Gacogne [Fri, 16 Mar 2018 08:36:49 +0000 (09:36 +0100)] 
rec: Set the visibility of FFI functions to 'default' (external)

This makes the symbols usable across shared object boundary (Lua FFI)
even if the default visibility is set to hidden.

(cherry picked from commit 4d9be0eba19ee15ed2b9c45b508086b9fd31d68a)

6 years agorec: Constify the methods of RecursorLua4 when possible
Remi Gacogne [Wed, 14 Mar 2018 10:14:34 +0000 (11:14 +0100)] 
rec: Constify the methods of RecursorLua4 when possible

(cherry picked from commit 5899ee547f3772a9eac3d37c6c6995056ee74ab9)

6 years agorec: Instruct LuaWrapper to stay away from our FFI pdns_ffi_param struct
Remi Gacogne [Mon, 12 Mar 2018 16:20:26 +0000 (17:20 +0100)] 
rec: Instruct LuaWrapper to stay away from our FFI pdns_ffi_param struct

(cherry picked from commit 4a639c365df629466e4a2916360a41d8a4302144)

6 years agorec: Add a new Lua FFI hook, gettag-ffi
Remi Gacogne [Mon, 12 Mar 2018 10:39:45 +0000 (11:39 +0100)] 
rec: Add a new Lua FFI hook, gettag-ffi

(cherry picked from commit 70fb28d91018e174998a024f6bc71f9963d4cd7e)

6 years agoMerge pull request #6383 from rgacogne/rec41-backport-6376
Pieter Lexis [Mon, 26 Mar 2018 10:28:09 +0000 (12:28 +0200)] 
Merge pull request #6383 from rgacogne/rec41-backport-6376

rec-4.1.x: Backport tests: lower dnsbulktest threshold in travis

6 years agotests: lower dnsbulktest threshold in travis 6383/head
Pieter Lexis [Wed, 21 Mar 2018 12:00:22 +0000 (13:00 +0100)] 
tests: lower dnsbulktest threshold in travis

(cherry picked from commit 280c2f89caaa1726fd02e6315e26f7b683ed6781)

6 years agoimport test for IXFR ending
Leon Xu [Fri, 12 Jan 2018 10:44:21 +0000 (18:44 +0800)] 
import test for IXFR ending

(cherry picked from commit 4f5cde492575eb62d8252df6ec413753f750e977)

6 years agospeed up IXFR transcation
Leon Xu [Thu, 11 Jan 2018 10:00:32 +0000 (18:00 +0800)] 
speed up IXFR transcation

IXFR client actively close connection to server once IXFR is done

(cherry picked from commit 397ed71dedda21effaaad2578b27fd316c00451d)

6 years agoIXFR shouldn't remove RRs which aren't in deleted list
Leon Xu [Thu, 11 Jan 2018 09:49:25 +0000 (17:49 +0800)] 
IXFR shouldn't remove RRs which aren't in deleted list

(cherry picked from commit 668624c8c617a40482a28b3c168701abed55aef0)

6 years agorec: Work around a RRSIG year-2038 issue in the negcache unit tests
Remi Gacogne [Tue, 5 Dec 2017 13:47:39 +0000 (14:47 +0100)] 
rec: Work around a RRSIG year-2038 issue in the negcache unit tests

On 32-bit OS with a signed 32-bit `time_t`, we have a known issue with
dates later than 2038 in `RecordTextWriter::xfrTime()`. For now we will
just use an earlier date than 2038 in these tests since the date has no
relevance there.

(cherry picked from commit 08d99e35da19dc35a966418f888222fbd598f269)

6 years agoFix ECS-based cache entry refresh code
bert hubert [Wed, 31 Jan 2018 15:59:03 +0000 (16:59 +0100)] 
Fix ECS-based cache entry refresh code

This would lead to us not refreshing ECS-varying answers in the cache, and therefore an even more depressed cache rate.

Thanks to @liordot who found the issue & provided a fix in #6241.

(cherry picked from commit f9c681bf96bae3be671bb086efbfc99b09f3031b)

6 years agorec: Fix ECS-specific NS AAAA not being returned from the cache
Remi Gacogne [Thu, 1 Mar 2018 20:09:36 +0000 (20:09 +0000)] 
rec: Fix ECS-specific NS AAAA not being returned from the cache

Reported by Andreas Jakum (thanks!).

(cherry picked from commit 4474afe14deb3f34088f14c1abbada723458bdf8)

6 years agorec: Add RPZ statistics docs
Pieter Lexis [Fri, 23 Mar 2018 11:25:24 +0000 (12:25 +0100)] 
rec: Add RPZ statistics docs

(cherry picked from commit 4fe8a79ffcc2e3eec7b5e30f43adf0e2d71ccc1e)

6 years agorec: move the rpz stats to a different url
Pieter Lexis [Fri, 23 Mar 2018 11:02:42 +0000 (12:02 +0100)] 
rec: move the rpz stats to a different url

(cherry picked from commit 64c9da8c1b373bc55ceb30b4d97c57fded2a43f0)

6 years agorec: save rpzStats as a shared_ptr
Pieter Lexis [Fri, 23 Mar 2018 10:11:52 +0000 (11:11 +0100)] 
rec: save rpzStats as a shared_ptr

(cherry picked from commit 20c37deceb8a969580fcc8dda531de6c9f019a1c)

6 years agorec: update the number of records in the RPZ stats
Pieter Lexis [Fri, 23 Mar 2018 09:57:47 +0000 (10:57 +0100)] 
rec: update the number of records in the RPZ stats

(cherry picked from commit 03f752a0df9e39c504cf5542331e55a4258bc820)

6 years agoExpose rpz stats in the web-interface
Pieter Lexis [Thu, 22 Mar 2018 16:53:00 +0000 (17:53 +0100)] 
Expose rpz stats in the web-interface

(cherry picked from commit 2278ffdab2c5a3ff47c56021892926d7b47a811c)

6 years ago[WIP] rec: Add metrics for RPZ zones
Remi Gacogne [Tue, 6 Mar 2018 11:07:10 +0000 (12:07 +0100)] 
[WIP] rec: Add metrics for RPZ zones

[ci skip]

(cherry picked from commit 4ba9d5dc1db6ecd48c36d840e3302e86179b6477)

6 years agoMerge pull request #6336 from pieterlexis/rec-41-backport-rpz-retry
Remi Gacogne [Tue, 20 Mar 2018 08:59:48 +0000 (09:59 +0100)] 
Merge pull request #6336 from pieterlexis/rec-41-backport-rpz-retry

rec: Backport RPZ retry patches

6 years agorec: Ensure we don't hammer the RPZ master server 6336/head
Pieter Lexis [Wed, 21 Feb 2018 16:37:02 +0000 (17:37 +0100)] 
rec: Ensure we don't hammer the RPZ master server

Before, if the `refresh` was not set in the lua-config file's
`rpzMaster` statement, we would keep trying to get delta's the whole
time. This commit ensures we update the zone's refresh config to the
value from the AXFR'd zone (if not set in the config).

(cherry picked from commit 2c68abe75d908b4a32a7de229c75af137dc3ec5a)

6 years agoMove loading of RPZ zone to RPZIXFRTracker.
Erik Winkels [Mon, 29 Jan 2018 15:33:12 +0000 (16:33 +0100)] 
Move loading of RPZ zone to RPZIXFRTracker.

(cherry picked from commit bb8ffe202776f44722fa6333dbfc24c36c1d395e)

6 years agoFix failure to start RPZIXFRTracker tracker thread.
Erik Winkels [Fri, 26 Jan 2018 16:07:05 +0000 (17:07 +0100)] 
Fix failure to start RPZIXFRTracker tracker thread.

This is an initial commit and needs more work (but it's 17:07 on a
Friday, so yeah...).

(cherry picked from commit e9112b46b9d972aed25e1f1f9ec46253b6718d5c)

6 years agoMerge pull request #6303 from rgacogne/backport-6302
Remi Gacogne [Mon, 26 Feb 2018 10:09:13 +0000 (11:09 +0100)] 
Merge pull request #6303 from rgacogne/backport-6302

Backport 6302: ixfrdist: Also respect the AXFR timeout for the chunk's length

6 years agoixfrdist: Also respect the AXFR timeout for the chunk's length 6303/head
Remi Gacogne [Sun, 25 Feb 2018 15:41:36 +0000 (16:41 +0100)] 
ixfrdist: Also respect the AXFR timeout for the chunk's length

We used to apply the default timeout of 10s to retrieve the chunk's
length even if we were passed a different one.

(cherry picked from commit b726c12720f31a6cdd94a06ccb3a427a96f19669)

6 years agoMerge pull request #6298 from pieterlexis/rec-41-axfr-timeout
Pieter Lexis [Fri, 23 Feb 2018 08:15:27 +0000 (09:15 +0100)] 
Merge pull request #6298 from pieterlexis/rec-41-axfr-timeout

Backport: rec: Implement settable AXFR timeout for RPZ

6 years agorec: Fix AXFR timeout nits 6298/head
Pieter Lexis [Thu, 22 Feb 2018 09:34:56 +0000 (10:34 +0100)] 
rec: Fix AXFR timeout nits

(cherry picked from commit cb6218d2b539eb225c5d1ec88227fa7136dbcc94)

6 years agorec: Implement settable AXFR timeout for RPZ
Pieter Lexis [Wed, 21 Feb 2018 11:52:54 +0000 (12:52 +0100)] 
rec: Implement settable AXFR timeout for RPZ

(cherry picked from commit ea448a77fd2c664893e961b21d26408879e20360)

6 years agoresolver.{cc,hh}: Allow setting the inbound AXFR timeout
Pieter Lexis [Wed, 14 Feb 2018 12:58:15 +0000 (13:58 +0100)] 
resolver.{cc,hh}: Allow setting the inbound AXFR timeout

(cherry picked from commit 99bea744a47e6de2ec399e78c0e43cd1b54537b3)

6 years agoMerge pull request #6215 from aerique/bugfix/rec-4.1.x-ancestor-delegation-below rec-4.1.1
aerique [Mon, 22 Jan 2018 13:06:43 +0000 (14:06 +0100)] 
Merge pull request #6215 from aerique/bugfix/rec-4.1.x-ancestor-delegation-below

rec: Correctly handle ancestor delegation NSEC{,3} for children

6 years agorec: Add unit tests for ancestor delegation check in denial 6215/head
Remi Gacogne [Thu, 11 Jan 2018 14:05:00 +0000 (15:05 +0100)] 
rec: Add unit tests for ancestor delegation check in denial

(cherry picked from commit af37c3062fe016121867e68693d7b9e1ca9f60f2)

6 years agorec: Correctly handle ancestor delegation NSEC{,3} for children
Remi Gacogne [Thu, 11 Jan 2018 14:05:22 +0000 (15:05 +0100)] 
rec: Correctly handle ancestor delegation NSEC{,3} for children

(cherry picked from commit c943eb59dacc1ea2b178a8dcd28d1ecbe160cb7c)

6 years agoMerge pull request #6212 from pieterlexis/backport-6209
aerique [Mon, 22 Jan 2018 09:41:04 +0000 (10:41 +0100)] 
Merge pull request #6212 from pieterlexis/backport-6209

Backport 6209 - Make `primeHints` threadsafe

6 years agoFix copied code 6212/head
Chris Hofstaedtler [Fri, 19 Jan 2018 18:57:37 +0000 (19:57 +0100)] 
Fix copied code

(cherry picked from commit e4f772ceb545a883d4683d34dff0a38e023f98ee)

6 years agoMinimal fix to make primeHints threadsafe
Chris Hofstaedtler [Fri, 19 Jan 2018 18:54:44 +0000 (19:54 +0100)] 
Minimal fix to make primeHints threadsafe

(cherry picked from commit e863a05ab7566450710f8cdc2c08750f00bcde33)

6 years agoMerge pull request #6202 from aerique/bugfix/backport-6167
aerique [Thu, 18 Jan 2018 11:44:06 +0000 (12:44 +0100)] 
Merge pull request #6202 from aerique/bugfix/backport-6167

rec: Initialize the result var before calling the preoutquery hook

6 years agoMerge pull request #6201 from aerique/bugfix/backport-6137
aerique [Thu, 18 Jan 2018 11:23:25 +0000 (12:23 +0100)] 
Merge pull request #6201 from aerique/bugfix/backport-6137

rec: Don't validate signature for "glue" CNAME

6 years agoMerge pull request #6200 from aerique/bugfix/backport-6095
aerique [Thu, 18 Jan 2018 11:04:41 +0000 (12:04 +0100)] 
Merge pull request #6200 from aerique/bugfix/backport-6095

rec: Pass the correct buffer size to arecvfrom()

6 years agoMerge pull request #6199 from aerique/bugfix/backport-6092
aerique [Thu, 18 Jan 2018 10:44:31 +0000 (11:44 +0100)] 
Merge pull request #6199 from aerique/bugfix/backport-6092

 rec: Fix the computation of the closest encloser for positive answers #6092

6 years agoMerge pull request #6198 from aerique/bugfix/backport-6085
aerique [Thu, 18 Jan 2018 09:39:36 +0000 (10:39 +0100)] 
Merge pull request #6198 from aerique/bugfix/backport-6085

rec: Don't process records for another class than IN

6 years agorec: Initialize the result var before calling the preoutquery hook 6202/head
Remi Gacogne [Wed, 10 Jan 2018 13:18:10 +0000 (14:18 +0100)] 
rec: Initialize the result var before calling the preoutquery hook

If the `preoutquery` hook was defined but didn't handle the query,
the resulting variable was left uninitialized.

(cherry picked from commit 17cecc84cc0e9f7b1dc9991e2568d1f8f4fc2b08)

6 years agorec: Add unit tests to make sure we correctly detect an unsigned DS 6201/head
Remi Gacogne [Mon, 8 Jan 2018 14:43:47 +0000 (15:43 +0100)] 
rec: Add unit tests to make sure we correctly detect an unsigned DS

(cherry picked from commit f100caacf6b5fe6624aa3909ad6cb988d7f22148)

6 years agorec: Don't validate signature for "glue" CNAME
Remi Gacogne [Wed, 3 Jan 2018 11:34:02 +0000 (12:34 +0100)] 
rec: Don't validate signature for "glue" CNAME

Anything else than the initial CNAME can't be considered authoritative.

(cherry picked from commit 933299e88c46fdc1cf8c64ff9bf11e6839686a94)

6 years agorec: Don't stop the reactor in the regression tests 6200/head
Remi Gacogne [Thu, 14 Dec 2017 12:48:28 +0000 (13:48 +0100)] 
rec: Don't stop the reactor in the regression tests

So, there is one and only one global reactor for every test suites,
ever, and you can't restart it if you stop it (see the awful
`ReactorNotRestartable` exception).
That doesn't prevent you from adding new ports to listen on to the
existing one, so let's just start if it isn't already running and
never stop it.

(cherry picked from commit fbfaa4a7ee59829cbf2d3765a3a967edb823bb39)

6 years agorec: Add regression tests for UDP outgoing buffer size
Remi Gacogne [Thu, 14 Dec 2017 10:14:35 +0000 (11:14 +0100)] 
rec: Add regression tests for UDP outgoing buffer size

(cherry picked from commit fb611f07566e08adf31c374e6453a6494df7d696)

6 years agorec: Pass the correct buffer size to arecvfrom()
Remi Gacogne [Tue, 12 Dec 2017 13:56:03 +0000 (14:56 +0100)] 
rec: Pass the correct buffer size to arecvfrom()

The size we used to pass to arecvfrom() along with our buffer was off by
one byte, resulting in the last byte of our buffer to be uninitialized for
answers exactly matching our outgoing buffer size. Since we passed the
correct size to MOADNSParser, we were reading one bye of unitialized
memory for such answers.
This caused issue with some authoritative servers sending an answer of our
exact buffer size, causing a parsing error. We would then retry without EDNS,
causing DNSSEC validation failures for some domains on such authoritative
servers.

(cherry picked from commit 4185f0895fbda41e8ffa21f39721db1f018a3466)

6 years agorec: Switch the exception thrown by `getDenial()` to a `PDNSException` 6199/head
Remi Gacogne [Fri, 15 Dec 2017 13:30:46 +0000 (14:30 +0100)] 
rec: Switch the exception thrown by `getDenial()` to a `PDNSException`

(cherry picked from commit dfbe5d76143f9227b287555ca0df9216f2f544d1)

6 years agorec: Fix the computation of the closest encloser for positive answers
Remi Gacogne [Wed, 13 Dec 2017 14:03:24 +0000 (15:03 +0100)] 
rec: Fix the computation of the closest encloser for positive answers

When the positive answer is expanded from a wildcard with NSEC3,
the closest encloser is not always parent of the qname, depending
on the number of labels in the initial wildcard.

(cherry picked from commit e4894ce07a529e174b542d20eae327a026e171e8)

6 years agorec: Don't process records for another class than IN 6198/head
Remi Gacogne [Wed, 29 Nov 2017 13:59:26 +0000 (14:59 +0100)] 
rec: Don't process records for another class than IN

(cherry picked from commit c5310862fe5d5813d9533e6e1a73ef512ca5044f)

6 years agoMerge pull request #6140 from Habbie/4.1.x-travis-jan2018
Remi Gacogne [Fri, 5 Jan 2018 09:12:10 +0000 (10:12 +0100)] 
Merge pull request #6140 from Habbie/4.1.x-travis-jan2018

rec 4.1.x: travis fixes/improvements

6 years agofix recursor prequery scripts 6140/head
Aki Tuomi [Fri, 7 Jul 2017 15:46:47 +0000 (18:46 +0300)] 
fix recursor prequery scripts

(cherry picked from commit c1feb3a819ac425fe535d8c21c0d0f79c6fbf069)

6 years agolimit builds to recursor only
Peter van Dijk [Thu, 4 Jan 2018 14:53:50 +0000 (15:53 +0100)] 
limit builds to recursor only

6 years agoMerge pull request #6041 from rgacogne/mplexer-time rec-4.1.0
Peter van Dijk [Mon, 4 Dec 2017 11:34:00 +0000 (12:34 +0100)] 
Merge pull request #6041 from rgacogne/mplexer-time

Add the missing <sys/time.h> include to mplexer.hh for struct timeval

6 years agoAdd the missing <sys/time.h> include to mplexer.hh for struct timeval 6041/head
Remi Gacogne [Mon, 4 Dec 2017 08:41:49 +0000 (09:41 +0100)] 
Add the missing <sys/time.h> include to mplexer.hh for struct timeval

6 years agoMerge pull request #6023 from rgacogne/dnsdist-ebpf-doc
Pieter Lexis [Fri, 1 Dec 2017 15:50:40 +0000 (16:50 +0100)] 
Merge pull request #6023 from rgacogne/dnsdist-ebpf-doc

dnsdist: Add missing documentation about ClientState, eBPF dynamic filters

6 years agoMerge pull request #5956 from job/priv_drop
Pieter Lexis [Fri, 1 Dec 2017 15:50:15 +0000 (16:50 +0100)] 
Merge pull request #5956 from job/priv_drop

Priv drop

6 years agoMerge pull request #6034 from Habbie/ragel-path
Peter van Dijk [Fri, 1 Dec 2017 15:16:28 +0000 (16:16 +0100)] 
Merge pull request #6034 from Habbie/ragel-path

centralise ragel check+remove .cc symlink

6 years agoMerge pull request #6032 from rgacogne/rec-getrr-cleanup
bert hubert [Fri, 1 Dec 2017 12:22:41 +0000 (13:22 +0100)] 
Merge pull request #6032 from rgacogne/rec-getrr-cleanup

rec: Use getRR<T>() instead of directly using a dynamic cast