Commit graph

10849 commits

Author SHA1 Message Date
Mark Andrews
b2ffe56fc5 add krb5-selfsub and ms-selfsub
(cherry picked from commit fbeefd4990)
2018-09-10 17:40:19 +10:00
Mark Andrews
6ff17d94bf check that name field is not a valid type
(cherry picked from commit 5fb75a3d75)
2018-09-10 17:25:07 +10:00
Mark Andrews
dbaf32a667 fix dns_ssumatchtype_subdomainms dns_ssumatchtype_subdomainkrb5 as they don't require the name field to be '.'
(cherry picked from commit 156d86e673)
2018-09-10 17:25:07 +10:00
Mark Andrews
ced589e379 avoid macro name collision with system defined macro
(cherry picked from commit 81b133d963)
2018-09-10 09:30:59 +10:00
Ondřej Surý
d20fd7b109 Remove excessive inclusion of isc/refcount.h from various header files 2018-09-07 16:55:22 +02:00
Ondřej Surý
b92a1791b3 Use isc/stdatomic.h to switch to __atomic builtins when compiling in C++ mode 2018-09-07 16:55:22 +02:00
Witold Kręcicki
3da95ab2ed Align CMSG buffers to a void* boundary, fixes crash on architectures with strict alignment
CHANGES entry

(cherry picked from commit 17212cf996)
2018-09-07 10:30:12 +02:00
Ondřej Surý
94a1c85366 Add C++ declarations to dns/fixedname.h 2018-09-05 18:00:32 -04:00
Ondřej Surý
302cae89f3 Bail-out early in the for install loops instead of continuing because for masks the error in the middle
(cherry picked from commit 25248eb097)
(cherry picked from commit 3fbceba0a8)
2018-09-03 13:49:35 +02:00
Witold Krecicki
eec06494aa Silence some warnings and errors
(cherry picked from commit 0f0dfc7f86)
2018-08-31 17:54:54 -07:00
Mark Andrews
10fdd1aa23 increase jitter to cover the entire potential steady state expire range when initially signing the zone
(cherry picked from commit 050fca2139)
2018-08-31 13:09:40 +10:00
Mark Andrews
20c79090bd fclose origfile and zonefile
(cherry picked from commit 455bb23236)
2018-08-31 12:25:01 +10:00
Evan Hunt
d3add15848 silence "missing print.h" warning
(cherry picked from commit 3c18b7d3fd)
2018-08-28 16:22:15 -07:00
Witold Kręcicki
80a025d1a7 rndc reconfig should not stat on existing zones, just load new ones. 2018-08-28 16:53:43 +02:00
Mark Andrews
c2c7020057 use sizeof(CK_SLOT_ID)
(cherry picked from commit 2c1d8b2e99)
2018-08-24 11:33:12 +10:00
Mark Andrews
58e33fcdb4 unlink before unlock
(cherry picked from commit 4742f4ecba)
2018-08-24 10:58:30 +10:00
Michał Kępień
cf7557dce0 Fix reloading inline-signed zones
While "rndc reload" causes dns_zone_asyncload() to be called for the
signed version of an inline-signed zone, the subsequent zone_load() call
causes the raw version to be reloaded from storage.  This means that
DNS_ZONEFLG_LOADPENDING gets set for the signed version of the zone by
dns_zone_asyncload() before the reload is attempted, but zone_postload()
is only called for the raw version and thus DNS_ZONEFLG_LOADPENDING is
cleared for the raw version, but not for the signed version.  This in
turn prevents zone maintenance from happening for the signed version of
the zone.

Until commit 749b3cacfc, this problem
remained dormant because DNS_ZONEFLG_LOADPENDING was previously
immediately, unconditionally cleared after zone loading was started
(whereas it should only be cleared when zone loading is finished or an
error occurs).  This behavior caused other issues [1] and thus had to be
changed.

Fix reloading inline-signed zones by clearing DNS_ZONEFLG_LOADPENDING
for the signed version of the zone once the raw version reload
completes.  Take care not to clear it prematurely during initial zone
load.  Also make sure that DNS_ZONEFLG_LOADPENDING gets cleared when
zone_postload() encounters an error or returns early, to prevent other
scenarios from resulting in the same problem.  Add comments aiming to
help explain code flow.

[1] see RT #47076

(cherry picked from commit 5431583971)
2018-08-22 11:46:08 +02:00
Michał Kępień
de6b8ded56 Set DNS_JOURNALOPT_RESIGN when loading the secure journal for an inline-signed zone
When an inline-signed zone is loaded, the master file for its signed
version is loaded and then a rollforward of the journal for the signed
version of the zone is performed.  If DNS_JOURNALOPT_RESIGN is not set
during the latter phase, signatures loaded from the journal for the
signed version of the zone will not be scheduled for refresh.  Fix the
conditional expression determining which flags should be used for the
dns_journal_rollforward() call so that DNS_JOURNALOPT_RESIGN is set when
zone_postload() is called for the signed version of an inline-signed
zone.

Extend bin/tests/system/stop.pl so that it can use "rndc halt" instead
of "rndc stop" as the former allows master file flushing upon shutdown
to be suppressed.

(cherry picked from commit 8db550c42f)
2018-08-22 10:56:42 +02:00
Ondřej Surý
32a0d602ea We want to install compatibility shim isc/int.h and isc/boolean.h headers 2018-08-22 09:07:39 +02:00
Ondřej Surý
e37e27c560 Update lwres to use stdint types to finish transition to using stdint types 2018-08-22 09:04:02 +02:00
Mark Andrews
d5cef9cd55 fix lock order reversal
(cherry picked from commit 2bb4392bb3)
2018-08-21 13:33:37 +10:00
Ondřej Surý
a2ffc37ad3 Don't install removed int.h and boolean.h headers 2018-08-14 20:14:05 -04:00
Mark Andrews
49b7ac4d44 add missing ATF_REQUIRE
(cherry picked from commit 0ce82e9d5f)
2018-08-14 19:59:06 -04:00
Mark Andrews
a21b1b86dc mempool didn't work for sizes less than sizeof(void*)
(cherry picked from commit 5dd1beec8e)
2018-08-14 09:12:41 -07:00
Michał Kępień
0d174c46ff Do not remove errors from the OpenSSL error queue in toresult()
dst__openssl_toresult3() first calls toresult() and subsequently uses
ERR_get_error_line_data() in a loop.  Given this, it is a mistake to use
ERR_get_error() in toresult() because it causes the retrieved error to
be removed from the OpenSSL error queue, thus preventing it from being
retrieved by the subsequent ERR_get_error_line_data() calls.  Fix by
using ERR_peek_error() instead of ERR_get_error() in toresult().

(cherry picked from commit 36436268b5)
2018-08-14 12:53:44 +02:00
Michał Kępień
c6d1239d90 Prevent rare rbt_insert_and_remove unit test failures
When two or more absolute, two-label names are added to a completely
empty RBT, an extra, empty node for the root name will be created due to
node splitting.  check_tree() expects that, but the extra node will not
be created when just one name is added to a completely empty RBT.  This
problem could be handled inside check_tree(), but that would introduce
unnecessary complexity into it since adding a single name will result in
a different node count for a completely empty RBT (node count will be 1)
and an RBT containing only an empty node for the root name, created due
to prior node splitting (node count will be 2).  Thus, first explicitly
create a node for the root name to prevent rare check_tree() failures
caused by a single name being added in the first iteration of the
insert/remove loop.

(cherry picked from commit 13fe763798)
2018-08-14 10:44:59 +02:00
Michał Kępień
cbd85e0137 Queue "rndc signing -nsec3param ..." requests if needed
If "rndc signing -nsec3param ..." is ran for a zone which has not yet
been loaded or transferred (i.e. its "db" field is NULL), it will be
silently ignored by named despite rndc logging an "nsec3param request
queued" message, which is misleading.  Prevent this by keeping a
per-zone queue of NSEC3PARAM change requests which arrive before a zone
is loaded or transferred and processing that queue once the raw version
of an inline-signed zone becomes available.

(cherry picked from commit cb40c5229a)
2018-08-14 09:29:54 +02:00
Ondřej Surý
af6fe731fb Make ENOBUFS a soft error
(cherry picked from commit ebf3083e08)
2018-08-13 19:23:21 +02:00
Ondřej Surý
8ad12f613e Fix extra closing parenthesis in DNSTAP code 2018-08-12 16:12:14 +02:00
Ondřej Surý
71059dac02 Fix various build failures on Windows (Courtesy of rockerinthelocker) 2018-08-11 05:57:52 -04:00
Ondřej Surý
bfd31e282a Fix missing config.h in win32/socket.c and replace config.h with <config.h>
(cherry picked from commit d87c1a120d)
2018-08-11 11:00:50 +02:00
Ondřej Surý
0a10dfa524 Add compatibility isc/boolean.h and isc/int.h headers
(cherry picked from commit 0dad73aafa)
2018-08-10 15:20:58 +02:00
Ondřej Surý
eb745a2125 Remove duplicate config.h
(cherry picked from commit 7351c505a0)
(cherry picked from commit 2844f6529d)
2018-08-10 15:20:58 +02:00
Ondřej Surý
1084b40b44 Replace custom isc_boolean_t with C standard bool type
(cherry picked from commit 994e656977)
(cherry picked from commit 884929400c)
2018-08-10 15:20:57 +02:00
Ondřej Surý
aaa76dc654 Replace custom isc_u?intNN_t types with C99 u?intNN_t types
(cherry picked from commit cb6a185c69)
(cherry picked from commit d61e6a3111)
2018-08-10 15:20:57 +02:00
Ondřej Surý
07970c501d Get rid of extra UINT64_MAX definition in lib/isc/win32/time.c
(cherry picked from commit 055278c936)
(cherry picked from commit 3523850065)
2018-08-10 15:20:57 +02:00
Ondřej Surý
bfc6a25f2d Replace ISC_PRINT_QUADFORMAT with inttypes.h format constants
(cherry picked from commit 64fe6bbaf2)
(cherry picked from commit c863a076ae)
2018-08-10 15:20:57 +02:00
Evan Hunt
ba162bd0d4 caclulate nlabels and set *chainingp correctly
(cherry picked from commit e78e55f435)
2018-08-08 14:27:44 -07:00
Tinderbox User
4b0b459e5b prep 9.11.4-P1 2018-08-08 14:27:44 -07:00
Evan Hunt
98b2377de3 explicit DNAME query could trigger a crash if deny-answer-aliases was set
(cherry picked from commit a21c3810d3453548cc05ae19995125dabea9ca9c)
(cherry picked from commit 6e187b8656)
2018-08-08 14:27:17 -07:00
Mark Andrews
4130859964 remove dead code
(cherry picked from commit 83a1e87dd2)
2018-08-03 09:50:45 +10:00
Mark Andrews
c4089d38cd treat the signed instance of a inline zone as dynamic
(cherry picked from commit 9130f055f4)
2018-08-02 14:27:41 +10:00
Mark Andrews
a65c8e27b1 handle dns_aclelementtype_geoip
(cherry picked from commit 57eadf4d4f)
2018-08-02 09:59:58 +10:00
Mark Andrews
c47f3abead test dns_acl_isinsecure with geoip element
(cherry picked from commit fb8bb4e306)
2018-08-02 09:59:58 +10:00
Mark Andrews
d024898f35 use tlsa and smime structs to set common values
(cherry picked from commit 63c9ec367f)
2018-08-02 08:52:30 +10:00
Mark Andrews
0a9f953a2f refcount errors on error paths
(cherry picked from commit 4093efc900)
2018-07-31 18:43:18 +10:00
Mark Andrews
43c6f0d801 remove re-initalisation of common structure
(cherry picked from commit 6e06d3e7c6)
2018-07-12 09:49:01 +10:00
Mark Andrews
f1f2c0c493 remove redundant test
(cherry picked from commit 6eec7fe092)
2018-07-10 19:05:12 -07:00
Mark Andrews
078962a616 fix spelling of 'telemetry'
(cherry picked from commit 4f18b6a09a)
2018-07-10 18:30:45 -07:00
Tinderbox User
3bbd725a2c prep 9.11.4rc2 2018-06-28 05:07:42 +00:00