Compare commits
1
Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
1896343049 |
@@ -11,7 +11,6 @@ BraceWrapping:
|
||||
AfterFunction: false # should also be MultiLine, but not yet supported
|
||||
AfterExternBlock: false
|
||||
BeforeElse: false
|
||||
BeforeWhile: false
|
||||
IndentBraces: false
|
||||
SplitEmptyFunction: true
|
||||
AllowShortIfStatementsOnASingleLine: false
|
||||
@@ -20,7 +19,6 @@ AlwaysBreakAfterReturnType: All
|
||||
Cpp11BracedListStyle: false
|
||||
ColumnLimit: 80
|
||||
AlignAfterOpenBracket: Align
|
||||
AlignConsecutiveBitFields: true
|
||||
AlignConsecutiveDeclarations: false
|
||||
AlignConsecutiveMacros: true
|
||||
AlignTrailingComments: true
|
||||
@@ -64,7 +62,6 @@ IncludeCategories:
|
||||
Priority: 1
|
||||
- Regex: '.*'
|
||||
Priority: 0
|
||||
IndentExternBlock: NoIndent
|
||||
KeepEmptyLinesAtTheStartOfBlocks: false
|
||||
MaxEmptyLinesToKeep: 1
|
||||
PenaltyBreakAssignment: 30
|
||||
|
||||
@@ -11,7 +11,6 @@ BraceWrapping:
|
||||
AfterFunction: false # should also be MultiLine, but not yet supported
|
||||
AfterExternBlock: false
|
||||
BeforeElse: false
|
||||
BeforeWhile: false
|
||||
IndentBraces: false
|
||||
SplitEmptyFunction: true
|
||||
AllowShortIfStatementsOnASingleLine: false
|
||||
@@ -20,7 +19,6 @@ AlwaysBreakAfterReturnType: All
|
||||
Cpp11BracedListStyle: false
|
||||
ColumnLimit: 80
|
||||
AlignAfterOpenBracket: Align
|
||||
AlignConsecutiveBitFields: true
|
||||
AlignConsecutiveDeclarations: true
|
||||
AlignConsecutiveMacros: true
|
||||
AlignTrailingComments: true
|
||||
@@ -52,7 +50,6 @@ IncludeCategories:
|
||||
Priority: 1
|
||||
- Regex: '".*"'
|
||||
Priority: 9
|
||||
IndentExternBlock: NoIndent
|
||||
KeepEmptyLinesAtTheStartOfBlocks: false
|
||||
MaxEmptyLinesToKeep: 1
|
||||
PenaltyBreakAssignment: 30
|
||||
|
||||
@@ -106,9 +106,6 @@
|
||||
(list
|
||||
"--enable=all"
|
||||
"--suppress=missingIncludeSystem"
|
||||
"--suppress=nullPointerRedundantCheck"
|
||||
(concat "--suppressions-list=" (expand-file-name
|
||||
(concat directory-of-current-dir-locals-file "util/suppressions.txt")))
|
||||
(concat "-include=" (expand-file-name
|
||||
(concat directory-of-current-dir-locals-file "config.h")))
|
||||
)
|
||||
|
||||
@@ -1,8 +1,6 @@
|
||||
*.sln.in eol=crlf
|
||||
*.vcxproj.* eol=crlf
|
||||
|
||||
/fuzz/dns_rdata_fromwire_text.in/input-* -text
|
||||
|
||||
.gitignore export-ignore
|
||||
/conftools export-ignore
|
||||
/doc/design export-ignore
|
||||
|
||||
@@ -1,15 +0,0 @@
|
||||
name: 'Lock down mirror repository'
|
||||
|
||||
on:
|
||||
issues:
|
||||
types: opened
|
||||
pull_request:
|
||||
types: opened
|
||||
|
||||
jobs:
|
||||
lockdown:
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- uses: dessant/repo-lockdown@v2
|
||||
with:
|
||||
github-token: ${{ github.token }}
|
||||
+2
-33
@@ -39,6 +39,7 @@ __pycache__/
|
||||
/depcomp
|
||||
/install-sh
|
||||
/isc-config.sh
|
||||
/libltdl/*
|
||||
/libtool
|
||||
/ltmain.sh
|
||||
/m4/libtool.m4
|
||||
@@ -56,45 +57,13 @@ Makefile
|
||||
Makefile.in
|
||||
ans.run
|
||||
gen.dSYM/
|
||||
kyua.log
|
||||
named.memstats
|
||||
named.run
|
||||
timestamp
|
||||
/compile_commands.json
|
||||
# Gets generated by Build Ear (bear)
|
||||
/compile_commands.commands.json
|
||||
/cppcheck_html/
|
||||
/cppcheck.results
|
||||
/tsan
|
||||
/util/check-make-install
|
||||
/INSTALL
|
||||
doc/man/dnssec-cds.8in
|
||||
doc/man/dnssec-checkds.8in
|
||||
doc/man/dnssec-coverage.8in
|
||||
doc/man/dnssec-dsfromkey.8in
|
||||
doc/man/dnssec-importkey.8in
|
||||
doc/man/dnssec-keyfromlabel.8in
|
||||
doc/man/dnssec-keygen.8in
|
||||
doc/man/dnssec-keymgr.8in
|
||||
doc/man/dnssec-revoke.8in
|
||||
doc/man/dnssec-settime.8in
|
||||
doc/man/dnssec-signzone.8in
|
||||
doc/man/dnssec-verify.8in
|
||||
doc/man/named-checkconf.8in
|
||||
doc/man/named-checkzone.8in
|
||||
doc/man/named-journalprint.8in
|
||||
doc/man/named-nzd2nzf.8in
|
||||
doc/man/nsec3hash.8in
|
||||
doc/man/pkcs11-destroy.8in
|
||||
doc/man/pkcs11-keygen.8in
|
||||
doc/man/pkcs11-list.8in
|
||||
doc/man/pkcs11-tokens.8in
|
||||
# clangd index directory
|
||||
/\.cache/
|
||||
# GNU Global index files
|
||||
/GPATH
|
||||
/GRTAGS
|
||||
/GTAGS
|
||||
# Emacs specific files
|
||||
\.dir-locals-2.el
|
||||
/emacs.desktop
|
||||
/emacs.desktop-lock
|
||||
|
||||
+267
-457
File diff suppressed because it is too large
Load Diff
@@ -1,33 +0,0 @@
|
||||
<!--
|
||||
THIS ISSUE TEMPLATE IS INTENDED ONLY FOR INTERNAL USE.
|
||||
|
||||
If the bug you are reporting is potentially security-related - for example,
|
||||
if it involves an assertion failure or other crash in `named` that can be
|
||||
triggered repeatedly - then please do *NOT* report it here, but send an
|
||||
email to [security-officer@isc.org](security-officer@isc.org).
|
||||
-->
|
||||
|
||||
### CVE-specific actions
|
||||
|
||||
- [ ] Assign a CVE identifier
|
||||
- [ ] Determine CVSS score
|
||||
- [ ] Determine the range of BIND versions affected (including the Subscription Edition)
|
||||
- [ ] Determine whether workarounds for the problem exists
|
||||
- [ ] Create a draft of the security advisory and put the information above in there
|
||||
- [ ] Prepare a detailed description of the problem which should include the following by default:
|
||||
- instructions for reproducing the problem (a system test is good enough)
|
||||
- explanation of code flow which triggers the problem (a system test is *not* good enough)
|
||||
- [ ] Prepare a private merge request containing the following items in separate commits:
|
||||
- a test for the issue (may be moved to a separate merge request for deferred merging)
|
||||
- a fix for the issue
|
||||
- documentation updates (`CHANGES`, release notes, anything else applicable)
|
||||
- [ ] Ensure the merge request from the previous step is reviewed by SWENG staff and has no outstanding discussions
|
||||
- [ ] Ensure the documentation changes introduced by the merge request addressing the problem are reviewed by Support and Marketing staff
|
||||
- [ ] Prepare backports of the merge request addressing the problem for all affected (and still maintained) BIND branches (backporting might affect the issue's scope and/or description)
|
||||
- [ ] Prepare a standalone patch for the last stable release of each affected (and still maintained) BIND branch
|
||||
|
||||
### Release-specific actions
|
||||
|
||||
- [ ] Create/update the private issue containing links to fixes & reproducers for all CVEs fixed in a given release cycle
|
||||
- [ ] Reserve a block of `CHANGES` placeholders once the complete set of vulnerabilities fixed in a given release cycle is determined
|
||||
- [ ] Ensure the merge requests containing CVE fixes are merged into `security-*` branches in CVE identifier order
|
||||
@@ -6,26 +6,6 @@
|
||||
|
||||
**Public Release:**
|
||||
|
||||
## Documentation Review Links
|
||||
|
||||
**Closed issues assigned to the milestone without a release note:**
|
||||
|
||||
- []()
|
||||
- []()
|
||||
- []()
|
||||
|
||||
**Merge requests merged into the milestone without a release note:**
|
||||
|
||||
- []()
|
||||
- []()
|
||||
- []()
|
||||
|
||||
**Merge requests merged into the milestone without a `CHANGES` entry:**
|
||||
|
||||
- []()
|
||||
- []()
|
||||
- []()
|
||||
|
||||
## Release Checklist
|
||||
|
||||
### Before the Code Freeze
|
||||
@@ -41,17 +21,20 @@
|
||||
|
||||
- [ ] ***(QA)*** Look for outstanding documentation issues (e.g. `CHANGES` mistakes) and address them if any are found.
|
||||
- [ ] ***(QA)*** Ensure release notes are correct, ask Support and Marketing to check them as well.
|
||||
- [ ] ***(QA)*** Update API files for libraries with new version information.
|
||||
- [ ] ***(QA)*** Change software version and library versions in `configure.ac` (new major release only).
|
||||
- [ ] ***(QA)*** Rebuild `configure` using Autoconf on `docs.isc.org`.
|
||||
- [ ] ***(QA)*** Update `CHANGES`.
|
||||
- [ ] ***(QA)*** Update `CHANGES.SE` (Subscription Edition only).
|
||||
- [ ] ***(QA)*** Update `README.md`.
|
||||
- [ ] ***(QA)*** Update `version`.
|
||||
- [ ] ***(QA)*** Build documentation on `docs.isc.org`.
|
||||
- [ ] ***(Support)*** Check release notes, ask QA to correct any mistakes found.
|
||||
- [ ] ***(Marketing)*** Check release notes, ask QA to correct any mistakes found.
|
||||
- [ ] ***(SwEng)*** Update API files for libraries with new version information.
|
||||
- [ ] ***(SwEng)*** Change software version and library versions in `configure.ac` (new major release only).
|
||||
- [ ] ***(SwEng)*** Rebuild `configure` using Autoconf on `docs.isc.org`.
|
||||
- [ ] ***(SwEng)*** Update `CHANGES`.
|
||||
- [ ] ***(SwEng)*** Update `CHANGES.SE` (Subscription Edition only).
|
||||
- [ ] ***(SwEng)*** Update `README.md`.
|
||||
- [ ] ***(SwEng)*** Update `version`.
|
||||
- [ ] ***(SwEng)*** Build documentation on `docs.isc.org`.
|
||||
- [ ] ***(QA)*** Check that all the above steps were performed correctly.
|
||||
- [ ] ***(QA)*** Check that the formatting is correct for text, PDF, and HTML versions of release notes.
|
||||
- [ ] ***(QA)*** Check that the formatting of the generated man pages is correct.
|
||||
- [ ] ***(QA)*** Tag the releases in the private repository (`git tag -s -m "BIND 9.x.y" v9_x_y`).
|
||||
- [ ] ***(SwEng)*** Tag the releases[^2]. (Tags may only be pushed to the public repository for releases which are *not* security releases.)
|
||||
- [ ] ***(SwEng)*** If this is the first tag for a release (e.g. beta), create a release branch named `release_v9_X_Y` to allow development to continue on the maintenance branch whilst release engineering continues.
|
||||
|
||||
### Before the ASN Deadline (for ASN Releases) or the Public Release Date (for Regular Releases)
|
||||
|
||||
@@ -71,7 +54,6 @@
|
||||
- [ ] ***(Support)*** Publish links to downloads on ISC website.
|
||||
- [ ] ***(Support)*** Write release email to *bind-announce*.
|
||||
- [ ] ***(Support)*** Write email to *bind-users* (if a major release).
|
||||
- [ ] ***(Support)*** Send eligible customers updated links to the Subscription Edition (update the -S edition delivery tickets, even if those links were provided earlier via an ASN ticket).
|
||||
- [ ] ***(Support)*** Update tickets in case of waiting support customers.
|
||||
- [ ] ***(QA)*** Build and test any outstanding private packages.
|
||||
- [ ] ***(QA)*** Build public packages (`*.deb`, RPMs).
|
||||
@@ -81,13 +63,12 @@
|
||||
- [ ] ***(Marketing)*** Update [Wikipedia entry for BIND](https://en.wikipedia.org/wiki/BIND).
|
||||
- [ ] ***(Marketing)*** Write blog article (if a major release).
|
||||
- [ ] ***(QA)*** Ensure all new tags are annotated and signed.
|
||||
- [ ] ***(QA)*** Push tags for the published releases to the public repository.
|
||||
- [ ] ***(QA)*** Merge the automatically prepared `prep 9.x.y` commit which updates `version` and documentation on the release branch into the relevant maintenance branch (`v9_x`).
|
||||
- [ ] ***(SwEng)*** Merge the automatically prepared `prep 9.X.Y` commit which updates `version` and documentation on the release branch into the relevant maintenance branch (`v9_X`).
|
||||
- [ ] ***(SwEng)*** Push tags for the published releases to the public repository.
|
||||
- [ ] ***(QA)*** For each maintained branch, update the `BIND_BASELINE_VERSION` variable for the `abi-check` job in `.gitlab-ci.yml` to the latest published BIND version tag for a given branch.
|
||||
- [ ] ***(QA)*** Prepare empty release notes for the next set of releases.
|
||||
- [ ] ***(QA)*** Sanitize confidential issues which are assigned to the current release milestone and do not describe a security vulnerability, then make them public.
|
||||
- [ ] ***(QA)*** Sanitize confidential issues which are assigned to older release milestones and describe security vulnerabilities, then make them public if appropriate[^2].
|
||||
- [ ] ***(QA)*** Update QA tools used in GitLab CI (e.g. Flake8, PyLint) by modifying the relevant `Dockerfile`.
|
||||
|
||||
[^1]: If not, use the time remaining until the tagging deadline to ensure all outstanding issues are either resolved or moved to a different milestone.
|
||||
[^2]: As a rule of thumb, security vulnerabilities which have reproducers merged to the public repository are considered okay for full disclosure.
|
||||
|
||||
[^2]: Preferred command line: `git tag -u <DEVELOPER_KEYID> -a -s -m "BIND 9.X.Y[alphatag]" v9_X_Y[alphatag]`, where `[alphatag]` is an optional string such as `b1`, `rc1`, etc.
|
||||
|
||||
@@ -13,7 +13,6 @@ extraction:
|
||||
- "libidn2-dev"
|
||||
- "libmaxminddb-dev"
|
||||
- "libuv1-dev"
|
||||
- "libnghttp2-dev"
|
||||
configure:
|
||||
command:
|
||||
- "autoreconf -fi"
|
||||
@@ -30,6 +29,7 @@ path_classifiers:
|
||||
- "**/*.5"
|
||||
- "**/*.8"
|
||||
queries:
|
||||
- exclude: libltdl/
|
||||
- exclude: fuzz/
|
||||
- exclude: "bin/tests/system/*/ans*/*.py"
|
||||
- exclude: cpp/use-of-goto
|
||||
|
||||
@@ -5,4 +5,3 @@ disable=
|
||||
C0116, # missing-function-docstring
|
||||
R0801, # duplicate-code
|
||||
C0103, # invalid-name
|
||||
C0415,# import-outside-toplevel
|
||||
|
||||
@@ -1,819 +1,15 @@
|
||||
5652. [bug] Copy and paste error caused the socket option to
|
||||
be enabled instead of disabled. [GL #2746]
|
||||
|
||||
5651. [func] Refactor zone dumping to be processed asynchronously
|
||||
via the uv_work_t thread pool API. [GL #2732]
|
||||
|
||||
5650. [bug] Prevent a crash that could occur if serve-stale
|
||||
was enabled and a prefetch was triggered during a
|
||||
query restart. [GL #2733]
|
||||
|
||||
5649. [bug] If a query was answered with stale data on a server
|
||||
with DNS64 enabled, an assertion could occur if a
|
||||
non-stale answer arrived afterward. [GL #2731]
|
||||
|
||||
5648. [bug] The calculation of the estimated IXFR transaction
|
||||
size by dns_journal_iter_init() was invalid. [GL #2685]
|
||||
|
||||
5647. [func] The interfacemgr has been refactored to use fewer
|
||||
clientmgr objects, which in turn use fewer memory
|
||||
contexts and tasks. This should result in less
|
||||
fragmented memory and better startup performance.
|
||||
[GL #2433]
|
||||
|
||||
5646. [bug] The default TCP timeout for rndc has been increased
|
||||
to 60 seconds. This was its original value, but it
|
||||
had been inadvertently lowered to 10. [GL #2643]
|
||||
|
||||
5645. [cleanup] Remove the rarely-used dns_name_copy() function
|
||||
and rename dns_name_copynf() to dns_name_copy().
|
||||
[GL !5081]
|
||||
|
||||
5644. [bug] Fix a race condition in reading and writing key files
|
||||
for KASP zones in multiple views. [GL #1875]
|
||||
|
||||
5643. [placeholder]
|
||||
|
||||
5642. [bug] Check "key-directory" conflicts in "named.conf" for
|
||||
zones in multiple views with different "dnssec-policy".
|
||||
[GL #2463].
|
||||
|
||||
5641. [bug] Address potential memory leak in dst_key_fromnamedfile.
|
||||
[GL #2689]
|
||||
|
||||
5640. [func] Add new configuration option to set the operating system
|
||||
receive and send buffers. [GL #2313]
|
||||
|
||||
5639. [bug] Check that the first and last SOA record of an AXFR
|
||||
are consistent. [GL #2528]
|
||||
|
||||
--- 9.17.13 released ---
|
||||
|
||||
5638. [bug] Improvements related to network manager/task manager
|
||||
integration:
|
||||
- isc_managers_create() and isc_managers_destroy()
|
||||
functions were added to handle setup and teardown of
|
||||
netmgr, taskmgr, timermgr, and socketmgr, since these
|
||||
require a precise order of operations now.
|
||||
- Event queue processing is now quantized to prevent
|
||||
infinite looping.
|
||||
- The netmgr can now be paused from within a netmgr
|
||||
thread.
|
||||
- Deadlocks due to a conflict between netmgr's
|
||||
pause/resume and listen/stoplistening operations were
|
||||
fixed.
|
||||
[GL #2654]
|
||||
|
||||
5637. [placeholder]
|
||||
|
||||
5636. [bug] named and named-checkconf did not report an error when
|
||||
multiple zones with the "dnssec-policy" option set were
|
||||
using the same zone file. This has been fixed.
|
||||
[GL #2603]
|
||||
|
||||
5635. [bug] Journal compaction could fail when a journal with
|
||||
invalid transaction headers was not detected at startup.
|
||||
This has been fixed. [GL #2670]
|
||||
|
||||
5634. [bug] If "dnssec-policy" was active and a private key file was
|
||||
temporarily offline during a rekey event, named could
|
||||
incorrectly introduce replacement keys and break a
|
||||
signed zone. This has been fixed. [GL #2596]
|
||||
|
||||
5633. [doc] The "inline-signing" option was incorrectly described as
|
||||
being inherited from the "options"/"view" levels and was
|
||||
incorrectly accepted at those levels without effect.
|
||||
This has been fixed. [GL #2536]
|
||||
|
||||
5632. [func] Add a new built-in KASP, "insecure", which is used to
|
||||
transition a zone from a signed to an unsigned state.
|
||||
The existing built-in KASP "none" should no longer be
|
||||
used to unsign a zone. [GL #2645]
|
||||
|
||||
5631. [protocol] Update the implementation of the ZONEMD RR type to match
|
||||
RFC 8976. [GL #2658]
|
||||
|
||||
5630. [func] Treat DNSSEC responses containing NSEC3 records with
|
||||
iteration counts greater than 150 as insecure.
|
||||
[GL #2445]
|
||||
|
||||
5629. [func] Reduce the maximum supported number of NSEC3 iterations
|
||||
that can be configured for a zone to 150. [GL #2642]
|
||||
|
||||
5628. [bug] Host and nslookup could crash upon receiving a SERVFAIL
|
||||
response. This has been fixed. [GL #2564]
|
||||
|
||||
5627. [bug] RRSIG(SOA) RRsets placed anywhere other than at the zone
|
||||
apex were triggering infinite resigning loops. This has
|
||||
been fixed. [GL #2650]
|
||||
|
||||
5626. [bug] When generating zone signing keys, KASP now also checks
|
||||
for key ID conflicts among newly created keys, rather
|
||||
than just between new and existing ones. [GL #2628]
|
||||
|
||||
5625. [bug] A deadlock could occur when multiple "rndc addzone",
|
||||
"rndc delzone", and/or "rndc modzone" commands were
|
||||
invoked simultaneously for different zones. This has
|
||||
been fixed. [GL #2626]
|
||||
|
||||
5624. [func] Task manager events are now processed inside network
|
||||
manager loops. The task manager no longer needs its own
|
||||
set of worker threads, which improves resolver
|
||||
performance. [GL #2638]
|
||||
|
||||
5623. [bug] When named was shut down during an ongoing zone
|
||||
transfer, xfrin_fail() could incorrectly be called
|
||||
twice. This has been fixed. [GL #2630]
|
||||
|
||||
5622. [cleanup] The lib/samples/ directory has been removed, as export
|
||||
versions of libraries are no longer maintained.
|
||||
[GL !4835]
|
||||
|
||||
5621. [placeholder]
|
||||
|
||||
5620. [bug] If zone journal files written by BIND 9.16.11 or earlier
|
||||
were present when BIND was upgraded, the zone file for
|
||||
that zone could have been inadvertently rewritten with
|
||||
the current zone contents. This caused the original zone
|
||||
file structure (e.g. comments, $INCLUDE directives) to
|
||||
be lost, although the zone data itself was preserved.
|
||||
This has been fixed. [GL #2623]
|
||||
|
||||
5619. [protocol] Implement draft-vandijk-dnsop-nsec-ttl, updating the
|
||||
protocol such that NSEC(3) TTL values are set to the
|
||||
minimum of the SOA MINIMUM value or the SOA TTL.
|
||||
[GL #2347]
|
||||
|
||||
5618. [bug] Change 5149 introduced some inconsistencies in the way
|
||||
record TTLs were presented in cache dumps. These
|
||||
inconsistencies have been eliminated. [GL #389]
|
||||
[GL #2289]
|
||||
|
||||
--- 9.17.12 released ---
|
||||
|
||||
5617. [placeholder]
|
||||
|
||||
5616. [security] named crashed when a DNAME record placed in the ANSWER
|
||||
section during DNAME chasing turned out to be the final
|
||||
answer to a client query. (CVE-2021-25215) [GL #2540]
|
||||
|
||||
5615. [security] Insufficient IXFR checks could result in named serving a
|
||||
zone without an SOA record at the apex, leading to a
|
||||
RUNTIME_CHECK assertion failure when the zone was
|
||||
subsequently refreshed. This has been fixed by adding an
|
||||
owner name check for all SOA records which are included
|
||||
in a zone transfer. (CVE-2021-25214) [GL #2467]
|
||||
|
||||
5614. [bug] Ensure all resources are properly cleaned up when a call
|
||||
to gss_accept_sec_context() fails. [GL #2620]
|
||||
|
||||
5613. [bug] It was possible to write an invalid transaction header
|
||||
in the journal file for a managed-keys database after
|
||||
upgrading. This has been fixed. Invalid headers in
|
||||
existing journal files are detected and named is able
|
||||
to recover from them. [GL #2600]
|
||||
|
||||
5612. [bug] Continued refactoring of the network manager:
|
||||
- allow recovery from read and connect timeout events,
|
||||
- ensure that calls to isc_nm_*connect() always
|
||||
return the connection status via a callback
|
||||
function.
|
||||
[GL #2401]
|
||||
|
||||
5611. [func] Set "stale-answer-client-timeout" to "off" by default.
|
||||
[GL #2608]
|
||||
|
||||
5610. [bug] Prevent a crash which could happen when a lookup
|
||||
triggered by "stale-answer-client-timeout" was attempted
|
||||
right after recursion for a client query finished.
|
||||
[GL #2594]
|
||||
|
||||
5609. [func] The ISC implementation of SPNEGO was removed from BIND 9
|
||||
source code. It was no longer necessary as all major
|
||||
contemporary Kerberos/GSSAPI libraries include support
|
||||
for SPNEGO. [GL #2607]
|
||||
|
||||
5608. [bug] When sending queries over TCP, dig now properly handles
|
||||
"+tries=1 +retry=0" by not retrying the connection when
|
||||
the remote server closes the connection prematurely.
|
||||
[GL #2490]
|
||||
|
||||
5607. [bug] As "rndc dnssec -checkds" and "rndc dnssec -rollover"
|
||||
commands may affect the next scheduled key event,
|
||||
reconfiguration of zone keys is now triggered after
|
||||
receiving either of these commands to prevent
|
||||
unnecessary key rollover delays. [GL #2488]
|
||||
|
||||
5606. [bug] CDS/CDNSKEY DELETE records are now removed when a zone
|
||||
transitions from a secure to an insecure state.
|
||||
named-checkzone also no longer reports an error when
|
||||
such records are found in an unsigned zone. [GL #2517]
|
||||
|
||||
5605. [bug] "dig -u" now uses the CLOCK_REALTIME clock source for
|
||||
more accurate time reporting. [GL #2592]
|
||||
|
||||
5604. [experimental] A "filter-a.so" plugin, which is similar to the
|
||||
"filter-aaaa.so" plugin but which omits A records
|
||||
instead of AAAA records, has been added. Thanks to
|
||||
GitLab user @treysis. [GL #2585]
|
||||
|
||||
5603. [placeholder]
|
||||
|
||||
5602. [bug] Fix TCPDNS and TLSDNS timers in Network Manager. This
|
||||
makes the "tcp-initial-timeout" and "tcp-idle-timeout"
|
||||
options work correctly again. [GL #2583]
|
||||
|
||||
5601. [bug] Zones using KASP could not be thawed after they were
|
||||
frozen using "rndc freeze". This has been fixed.
|
||||
[GL #2523]
|
||||
|
||||
5600. [bug] Send a full certificate chain instead of just the leaf
|
||||
certificate to DNS-over-TLS (DoT) and DNS-over-HTTPS
|
||||
(DoH) clients. This makes BIND 9 DoT/DoH servers
|
||||
compatible with a broader set of clients. [GL #2514]
|
||||
|
||||
5599. [bug] Fix a named crash which occurred after skipping a
|
||||
primary server while transferring a zone over TLS.
|
||||
[GL #2562]
|
||||
|
||||
5598. [port] Silence -Wchar-subscripts compiler warnings triggered on
|
||||
some platforms due to calling character classification
|
||||
functions declared in the <ctype.h> header with
|
||||
arguments of type char. [GL #2567]
|
||||
|
||||
--- 9.17.11 released ---
|
||||
|
||||
5597. [bug] When serve-stale was enabled and starting the recursive
|
||||
resolution process for a query failed, a named instance
|
||||
could crash if it was configured as both a recursive and
|
||||
authoritative server. This problem was introduced by
|
||||
change 5573 and has now been fixed. [GL #2565]
|
||||
|
||||
5596. [func] Client-side support for DNS-over-HTTPS (DoH) has been
|
||||
added to dig. "dig +https" can now query a server via
|
||||
HTTP/2. [GL #1641]
|
||||
|
||||
5595. [cleanup] Public header files for BIND 9 libraries no longer
|
||||
directly include third-party library headers. This
|
||||
prevents the need to include paths to third-party header
|
||||
files in CFLAGS whenever BIND 9 public header files are
|
||||
used, which could cause build-time issues on hosts with
|
||||
older versions of BIND 9 installed. [GL #2357]
|
||||
|
||||
5594. [bug] Building with --enable-dnsrps --enable-dnsrps-dl failed.
|
||||
[GL #2298]
|
||||
|
||||
5593. [bug] Journal files written by older versions of named can now
|
||||
be read when loading zones, so that journal
|
||||
incompatibility does not cause problems on upgrade.
|
||||
Outdated journals are updated to the new format after
|
||||
loading. [GL #2505]
|
||||
|
||||
5592. [bug] Prevent hazard pointer table overflows on machines with
|
||||
many cores, by allowing the thread IDs (serving as
|
||||
indices into hazard pointer tables) of finished threads
|
||||
to be reused by those created later. [GL #2396]
|
||||
|
||||
5591. [bug] Fix a crash that occurred when
|
||||
"stale-answer-client-timeout" was triggered without any
|
||||
(stale) data available in the cache to answer the query.
|
||||
[GL #2503]
|
||||
|
||||
5590. [bug] NSEC3 records were not immediately created for dynamic
|
||||
zones using NSEC3 with "dnssec-policy", resulting in
|
||||
such zones going bogus. Add code to process the
|
||||
NSEC3PARAM queue at zone load time so that NSEC3 records
|
||||
for such zones are created immediately. [GL #2498]
|
||||
|
||||
5589. [placeholder]
|
||||
|
||||
5588. [func] Add a new "purge-keys" option for "dnssec-policy". This
|
||||
option determines the period of time for which key files
|
||||
are retained after they become obsolete. [GL #2408]
|
||||
|
||||
5587. [bug] A standalone libtool script no longer needs to be
|
||||
present in PATH to build BIND 9 from a source tarball
|
||||
prepared using "make dist". [GL #2504]
|
||||
|
||||
5586. [bug] An invalid direction field in a LOC record resulted in
|
||||
an INSIST failure when a zone file containing such a
|
||||
record was loaded. [GL #2499]
|
||||
|
||||
5585. [func] Memory contexts and memory pool implementations were
|
||||
refactored to reduce lock contention for shared memory
|
||||
contexts by replacing mutexes with atomic operations.
|
||||
The internal memory allocator was simplified so that it
|
||||
is only a thin wrapper around the system allocator. This
|
||||
change made the "-M external" named option redundant and
|
||||
it was therefore removed. [GL #2433]
|
||||
|
||||
5584. [bug] No longer set the IP_DONTFRAG option on UDP sockets, to
|
||||
prevent dropping outgoing packets exceeding
|
||||
"max-udp-size". [GL #2466]
|
||||
|
||||
5583. [func] Changes to DNS-over-HTTPS (DoH) configuration syntax:
|
||||
- When "http" is specified in "listen-on" or
|
||||
"listen-on-v6" statements, "tls" must also now be
|
||||
specified. If an unencrypted connection is desired
|
||||
(for example, when running behind a reverse proxy),
|
||||
use "tls none".
|
||||
- "http default" can now be specified in "listen-on" and
|
||||
"listen-on-v6" statements to use the default HTTP
|
||||
endpoint of "/dns-query". It is no longer necessary to
|
||||
include an "http" statement in named.conf unless
|
||||
overriding this value.
|
||||
[GL #2472]
|
||||
|
||||
5582. [bug] BIND 9 failed to build when static OpenSSL libraries
|
||||
were used and the pkg-config files for libssl and/or
|
||||
libcrypto were unavailable. This has been fixed by
|
||||
ensuring that the correct linking order for libssl and
|
||||
libcrypto is always used. [GL #2402]
|
||||
|
||||
5581. [bug] Fix a memory leak that occurred when inline-signed zones
|
||||
were added to the configuration, followed by a
|
||||
reconfiguration of named. [GL #2041]
|
||||
|
||||
5580. [test] The system test framework no longer differentiates
|
||||
between SKIPPED and UNTESTED system test results. Any
|
||||
system test which is not run is now marked as SKIPPED.
|
||||
[GL !4517]
|
||||
|
||||
5579. [bug] If an invalid key name (e.g. "a..b") was specified in a
|
||||
primaries list in named.conf, the wrong size was passed
|
||||
to isc_mem_put(), resulting in the returned memory being
|
||||
put on the wrong free list. This prevented named from
|
||||
starting up. [GL #2460]
|
||||
|
||||
--- 9.17.10 released ---
|
||||
|
||||
5578. [protocol] Make "check-names" accept A records below "_spf",
|
||||
"_spf_rate", and "_spf_verify" labels in order to cater
|
||||
for the "exists" SPF mechanism specified in RFC 7208
|
||||
section 5.7 and appendix D.1. [GL #2377]
|
||||
|
||||
5577. [bug] Fix the "three is a crowd" key rollover bug in KASP by
|
||||
correctly implementing Equation (2) of the "Flexible and
|
||||
Robust Key Rollover" paper. [GL #2375]
|
||||
|
||||
5576. [experimental] Initial server-side implementation of DNS-over-HTTPS
|
||||
(DoH). Support for both TLS-encrypted and unencrypted
|
||||
HTTP/2 connections has been added to the network manager
|
||||
and integrated into named. (Note: there is currently no
|
||||
client-side support for DNS-over-HTTPS; this will be
|
||||
added to dig in a future release.) [GL #1144]
|
||||
|
||||
5575. [bug] When migrating to KASP, BIND 9 considered keys with the
|
||||
"Inactive" and/or "Delete" timing metadata to be
|
||||
possible active keys. This has been fixed. [GL #2406]
|
||||
|
||||
5574. [func] Incoming zone transfers can now use TLS. Addresses in a
|
||||
"primaries" list take an optional "tls" argument,
|
||||
specifying either a previously configured "tls" block or
|
||||
"ephemeral"; SOA queries and zone transfer requests are
|
||||
then sent via TLS. [GL #2392]
|
||||
|
||||
5573. [func] When serve-stale is enabled and stale data is available,
|
||||
named now returns stale answers upon encountering any
|
||||
unexpected error in the query resolution process.
|
||||
However, the "stale-refresh-time" window is still only
|
||||
started upon a timeout. [GL #2434]
|
||||
|
||||
5572. [bug] Address potential double free in generatexml().
|
||||
[GL #2420]
|
||||
|
||||
5571. [bug] named failed to start when its configuration included a
|
||||
zone with a non-builtin "allow-update" ACL attached.
|
||||
[GL #2413]
|
||||
|
||||
5570. [bug] Improve performance of the DNSSEC verification code by
|
||||
reducing the number of repeated calls to
|
||||
dns_dnssec_keyfromrdata(). [GL #2073]
|
||||
|
||||
5569. [bug] Emit useful error message when "rndc retransfer" is
|
||||
applied to a zone of inappropriate type. [GL #2342]
|
||||
|
||||
5568. [bug] Fixed a crash in "dnssec-keyfromlabel" when using ECDSA
|
||||
keys. [GL #2178]
|
||||
|
||||
5567. [bug] Dig now reports unknown dash options while pre-parsing
|
||||
the options. This prevents "-multi" instead of "+multi"
|
||||
from reporting memory usage before ending option parsing
|
||||
with "Invalid option: -lti". [GL #2403]
|
||||
|
||||
5566. [func] Add "stale-answer-client-timeout" option, which is the
|
||||
amount of time a recursive resolver waits before
|
||||
attempting to answer the query using stale data from
|
||||
cache. [GL #2247]
|
||||
|
||||
5565. [func] The SONAMEs for BIND 9 libraries now include the current
|
||||
BIND 9 version number, in an effort to tightly couple
|
||||
internal libraries with a specific release. [GL #2387]
|
||||
|
||||
5564. [cleanup] Network manager's TLSDNS module was refactored to use
|
||||
libuv and libssl directly instead of a stack of TCP/TLS
|
||||
sockets. [GL #2335]
|
||||
|
||||
5563. [cleanup] Changed several obsolete configuration options to
|
||||
ancient, making them fatal errors. Also cleaned up the
|
||||
number of clause flags in the configuration parser.
|
||||
[GL #1086]
|
||||
|
||||
5562. [placeholder]
|
||||
|
||||
5561. [bug] KASP incorrectly set signature validity to the value of
|
||||
the DNSKEY signature validity. This is now fixed.
|
||||
[GL #2383]
|
||||
|
||||
5560. [func] The default value of "max-stale-ttl" has been changed
|
||||
from 12 hours to 1 day and the default value of
|
||||
"stale-answer-ttl" has been changed from 1 second to 30
|
||||
seconds, following RFC 8767 recommendations. [GL #2248]
|
||||
|
||||
--- 9.17.9 released ---
|
||||
|
||||
5559. [bug] The --with-maxminddb=PATH form of the build-time option
|
||||
enabling support for libmaxminddb was not working
|
||||
correctly. This has been fixed. [GL #2366]
|
||||
|
||||
5558. [bug] Asynchronous hook modules could trigger an assertion
|
||||
failure when the fetch handle was detached too late.
|
||||
Thanks to Jinmei Tatuya at Infoblox. [GL #2379]
|
||||
|
||||
5557. [bug] Prevent RBTDB instances from being destroyed by multiple
|
||||
threads at the same time. [GL #2317]
|
||||
|
||||
5556. [bug] Further tweak newline printing in dnssec-signzone and
|
||||
dnssec-verify. [GL #2359]
|
||||
|
||||
5555. [placeholder]
|
||||
|
||||
5554. [bug] dnssec-signzone and dnssec-verify were missing newlines
|
||||
between log messages. [GL #2359]
|
||||
|
||||
5553. [bug] When reconfiguring named, removing "auto-dnssec" did not
|
||||
turn off DNSSEC maintenance. [GL #2341]
|
||||
|
||||
5552. [func] When switching to "dnssec-policy none;", named now
|
||||
permits a safe transition to insecure mode and publishes
|
||||
the CDS and CDNSKEY DELETE records, as described in RFC
|
||||
8078. [GL #1750]
|
||||
|
||||
5551. [bug] named no longer attempts to assign threads to CPUs
|
||||
outside the CPU affinity set. Thanks to Ole Bjørn
|
||||
Hessen. [GL #2245]
|
||||
|
||||
5550. [func] dnssec-signzone and named now log a warning when falling
|
||||
back to the "increment" SOA serial method. [GL #2058]
|
||||
|
||||
5549. [protocol] ipv4only.arpa is now served when DNS64 is configured.
|
||||
[GL #385]
|
||||
|
||||
5548. [placeholder]
|
||||
|
||||
5547. [placeholder]
|
||||
|
||||
--- 9.17.8 released ---
|
||||
|
||||
5546. [placeholder]
|
||||
|
||||
5545. [func] OS support for load-balanced sockets is no longer
|
||||
required to receive incoming queries in multiple netmgr
|
||||
threads. [GL #2137]
|
||||
|
||||
5544. [func] Restore the default value of "nocookie-udp-size" to 4096
|
||||
bytes. [GL #2250]
|
||||
|
||||
5543. [bug] Fix UDP performance issues caused by making netmgr
|
||||
callbacks asynchronous-only. [GL #2320]
|
||||
|
||||
5542. [bug] Refactor netmgr. [GL #1920] [GL #2034] [GL #2061]
|
||||
[GL #2194] [GL #2221] [GL #2266] [GL #2283] [GL #2318]
|
||||
[GL #2321]
|
||||
|
||||
5541. [func] Adjust the "max-recursion-queries" default from 75 to
|
||||
100. [GL #2305]
|
||||
|
||||
5540. [port] Fix building with native PKCS#11 support for AEP Keyper.
|
||||
[GL #2315]
|
||||
|
||||
5539. [bug] Tighten handling of missing DNS COOKIE responses over
|
||||
UDP by falling back to TCP. [GL #2275]
|
||||
|
||||
5538. [func] Add NSEC3 support to KASP. A new option for
|
||||
"dnssec-policy", "nsec3param", can be used to set the
|
||||
desired NSEC3 parameters. NSEC3 salt collisions are
|
||||
automatically prevented during resalting. Salt
|
||||
generation is now logged with zone context. [GL #1620]
|
||||
|
||||
5537. [func] The query plugin mechanism has been extended
|
||||
to support asynchronous operations. For example, a
|
||||
plugin can now trigger recursion and resume
|
||||
processing when it is complete. Thanks to Jinmei
|
||||
Tatuya at Infoblox. [GL #2141]
|
||||
|
||||
5536. [func] Dig can now report the DNS64 prefixes in use
|
||||
(+dns64prefix). [GL #1154]
|
||||
|
||||
5535. [bug] dig/nslookup/host could crash on shutdown after an
|
||||
interrupt. [GL #2287] [GL #2288]
|
||||
|
||||
5534. [bug] The CNAME synthesized from a DNAME was incorrectly
|
||||
followed when the QTYPE was CNAME or ANY. [GL #2280]
|
||||
|
||||
--- 9.17.7 released ---
|
||||
|
||||
5533. [func] Add the "stale-refresh-time" option, a time window that
|
||||
starts after a failed lookup, during which a stale RRset
|
||||
is served directly from cache before a new attempt to
|
||||
refresh it is made. [GL #2066]
|
||||
|
||||
5532. [cleanup] Unused header files were removed:
|
||||
bin/rndc/include/rndc/os.h, lib/isc/timer_p.h,
|
||||
lib/isccfg/include/isccfg/dnsconf.h and code related
|
||||
to those files. [GL #1913]
|
||||
|
||||
5531. [func] Add support for DNS over TLS (DoT) to dig and named.
|
||||
dig output now includes the transport protocol used.
|
||||
[GL #1816] [GL #1840]
|
||||
|
||||
5530. [bug] dnstap did not capture responses to forwarded UPDATE
|
||||
requests. [GL #2252]
|
||||
|
||||
5529. [func] The network manager API is now used by named to send
|
||||
zone transfer requests. [GL #2016]
|
||||
|
||||
5528. [func] Convert dig, host, and nslookup to use the network
|
||||
manager API. As a side effect of this change, "dig
|
||||
+unexpected" no longer works, and has been disabled.
|
||||
[GL #2140]
|
||||
|
||||
5527. [bug] A NULL pointer dereference occurred when creating an NTA
|
||||
recheck query failed. [GL #2244]
|
||||
|
||||
5526. [bug] Fix a race/NULL dereference in TCPDNS read. [GL #2227]
|
||||
|
||||
5525. [placeholder]
|
||||
|
||||
5524. [func] Added functionality to the network manager to support
|
||||
outgoing DNS queries in addition to incoming ones.
|
||||
[GL #2235]
|
||||
|
||||
5523. [bug] The initial lookup in a zone transitioning to/from a
|
||||
signed state could fail if the DNSKEY RRset was not
|
||||
found. [GL #2236]
|
||||
|
||||
5522. [bug] Fixed a race/NULL dereference in TCPDNS send. [GL #2227]
|
||||
|
||||
5521. [func] All use of libltdl was dropped. libuv's shared library
|
||||
handling interface is now used instead. [GL !4278]
|
||||
|
||||
5520. [bug] Fixed a number of shutdown races, reference counting
|
||||
errors, and spurious log messages that could occur
|
||||
in the network manager. [GL #2221]
|
||||
|
||||
5519. [cleanup] Unused source code was removed: lib/dns/dbtable.c,
|
||||
lib/dns/portlist.c, lib/isc/bufferlist.c, and code
|
||||
related to those files. [GL #2060]
|
||||
|
||||
5518. [bug] Stub zones now work correctly with primary servers using
|
||||
"minimal-responses yes". [GL #1736]
|
||||
|
||||
5517. [bug] Do not treat UV_EOF as a TCP4RecvErr or a TCP6RecvErr.
|
||||
[GL #2208]
|
||||
|
||||
--- 9.17.6 released ---
|
||||
|
||||
5516. [func] The default EDNS buffer size has been changed from 4096
|
||||
to 1232 bytes, the EDNS buffer size probing has been
|
||||
removed, and named now sets the DF (Don't Fragment) flag
|
||||
on outgoing UDP packets. [GL #2183]
|
||||
|
||||
5515. [func] Add 'rndc dnssec -rollover' command to trigger a manual
|
||||
rollover for a specific key. [GL #1749]
|
||||
|
||||
5514. [bug] Fix KASP expected key size for Ed25519 and Ed448.
|
||||
[GL #2171]
|
||||
|
||||
5513. [doc] The ARM section describing the "rrset-order" statement
|
||||
was rewritten to make it unambiguous and up-to-date with
|
||||
the source code. [GL #2139]
|
||||
|
||||
5512. [bug] "rrset-order" rules using "order none" were causing
|
||||
named to crash despite named-checkconf treating them as
|
||||
valid. [GL #2139]
|
||||
|
||||
5511. [bug] 'dig -u +yaml' failed to display timestamps to the
|
||||
microsecond. [GL #2190]
|
||||
|
||||
5510. [bug] Implement the attach/detach semantics for dns_message_t
|
||||
to fix a data race in accessing an already-destroyed
|
||||
fctx->rmessage. [GL #2124]
|
||||
|
||||
5509. [bug] filter-aaaa: named crashed upon shutdown if it was in
|
||||
the process of recursing for A RRsets. [GL #1040]
|
||||
|
||||
5508. [func] Added new parameter "-expired" for "rndc dumpdb" that
|
||||
also prints expired RRsets (awaiting cleanup) to the
|
||||
dump file. [GL #1870]
|
||||
|
||||
5507. [bug] Named could compute incorrect SIG(0) responses.
|
||||
[GL #2109]
|
||||
|
||||
5506. [bug] Properly handle failed sysconf() calls, so we don't
|
||||
report invalid memory size. [GL #2166]
|
||||
|
||||
5505. [bug] Updating contents of a mixed-case RPZ could cause some
|
||||
rules to be ignored. [GL #2169]
|
||||
|
||||
5504. [func] The "glue-cache" option has been marked as deprecated.
|
||||
The glue cache feature will be permanently enabled in a
|
||||
future release. [GL #2146]
|
||||
|
||||
5503. [bug] Cleaned up reference counting of network manager
|
||||
handles, now using isc_nmhandle_attach() and _detach()
|
||||
instead of _ref() and _unref(). [GL #2122]
|
||||
|
||||
--- 9.17.5 released ---
|
||||
|
||||
5502. [func] 'dig +bufsize=0' no longer disables EDNS. [GL #2054]
|
||||
|
||||
5501. [func] Log CDS/CDNSKEY publication. [GL #1748]
|
||||
|
||||
5500. [bug] Fix (non-)publication of CDS and CDNSKEY records.
|
||||
[GL #2103]
|
||||
|
||||
5499. [func] Add '-P ds' and '-D ds' arguments to dnssec-settime.
|
||||
[GL #1748]
|
||||
|
||||
5498. [test] The --with-gperftools-profiler configure option was
|
||||
removed. [GL !4045]
|
||||
|
||||
5497. [placeholder]
|
||||
|
||||
5496. [bug] Address a TSAN report by ensuring each rate limiter
|
||||
object holds a reference to its task. [GL #2081]
|
||||
|
||||
5495. [bug] With query minimization enabled, named failed to
|
||||
resolve ip6.arpa. names that had extra labels to the
|
||||
left of the IPv6 part. [GL #1847]
|
||||
|
||||
5494. [bug] Silence the EPROTO syslog message on older systems.
|
||||
[GL #1928]
|
||||
|
||||
5493. [bug] Fix off-by-one error when calculating new hash table
|
||||
size. [GL #2104]
|
||||
|
||||
5492. [bug] Tighten LOC parsing to reject a period (".") and/or "m"
|
||||
as a value. Fix handling of negative altitudes which are
|
||||
not whole meters. [GL #2074]
|
||||
|
||||
5491. [bug] rbtversion->glue_table_size could be read without the
|
||||
appropriate lock being held. [GL #2080]
|
||||
|
||||
5490. [func] Refactor readline support to use pkg-config and add
|
||||
support for the editline library. [GL !3942]
|
||||
|
||||
5489. [bug] Named erroneously accepted certain invalid resource
|
||||
records that were incorrectly processed after
|
||||
subsequently being written to disk and loaded back, as
|
||||
the wire format differed. Such records include: CERT,
|
||||
IPSECKEY, NSEC3, NSEC3PARAM, NXT, SIG, TLSA, WKS, and
|
||||
X25. [GL !3953]
|
||||
|
||||
5488. [bug] NTA code needed to have a weak reference on its
|
||||
associated view to prevent the latter from being deleted
|
||||
while NTA tests were being performed. [GL #2067]
|
||||
|
||||
5487. [cleanup] Update managed keys log messages to be less confusing.
|
||||
[GL #2027]
|
||||
|
||||
5486. [func] Add 'rndc dnssec -checkds' command, which signals to
|
||||
named that the DS record for a given zone or key has
|
||||
been updated in the parent zone. [GL #1613]
|
||||
|
||||
--- 9.17.4 released ---
|
||||
|
||||
5485. [placeholder]
|
||||
|
||||
5484. [func] Expire zero TTL records quickly rather than using them
|
||||
for stale answers. [GL #1829]
|
||||
|
||||
5483. [func] Keeping "stale" answers in cache has been disabled by
|
||||
default and can be re-enabled with a new configuration
|
||||
option "stale-cache-enable". [GL #1712]
|
||||
|
||||
5482. [bug] If the Duplicate Address Detection (DAD) mechanism had
|
||||
not yet finished after adding a new IPv6 address to the
|
||||
system, BIND 9 would fail to bind to IPv6 addresses in a
|
||||
tentative state. [GL #2038]
|
||||
|
||||
5481. [security] "update-policy" rules of type "subdomain" were
|
||||
incorrectly treated as "zonesub" rules, which allowed
|
||||
keys used in "subdomain" rules to update names outside
|
||||
of the specified subdomains. The problem was fixed by
|
||||
making sure "subdomain" rules are again processed as
|
||||
described in the ARM. (CVE-2020-8624) [GL #2055]
|
||||
|
||||
5480. [security] When BIND 9 was compiled with native PKCS#11 support, it
|
||||
was possible to trigger an assertion failure in code
|
||||
determining the number of bits in the PKCS#11 RSA public
|
||||
key with a specially crafted packet. (CVE-2020-8623)
|
||||
[GL #2037]
|
||||
|
||||
5479. [security] named could crash in certain query resolution scenarios
|
||||
where QNAME minimization and forwarding were both
|
||||
enabled. (CVE-2020-8621) [GL #1997]
|
||||
|
||||
5478. [security] It was possible to trigger an assertion failure by
|
||||
sending a specially crafted large TCP DNS message.
|
||||
(CVE-2020-8620) [GL #1996]
|
||||
|
||||
5477. [bug] The idle timeout for connected TCP sockets, which was
|
||||
previously set to a high fixed value, is now derived
|
||||
from the client query processing timeout configured for
|
||||
a resolver. [GL #2024]
|
||||
|
||||
5476. [security] It was possible to trigger an assertion failure when
|
||||
verifying the response to a TSIG-signed request.
|
||||
(CVE-2020-8622) [GL #2028]
|
||||
|
||||
5475. [bug] Wildcard RPZ passthru rules could incorrectly be
|
||||
overridden by other rules that were loaded from RPZ
|
||||
zones which appeared later in the "response-policy"
|
||||
statement. This has been fixed. [GL #1619]
|
||||
|
||||
5474. [bug] dns_rdata_hip_next() failed to return ISC_R_NOMORE
|
||||
when it should have. [GL !3880]
|
||||
|
||||
5473. [func] The RBT hash table implementation has been changed
|
||||
to use a faster hash function (HalfSipHash2-4) and
|
||||
Fibonacci hashing for better distribution. Setting
|
||||
"max-cache-size" now preallocates a fixed-size hash
|
||||
table so that rehashing does not cause resolution
|
||||
brownouts while the hash table is grown. [GL #1775]
|
||||
|
||||
5472. [func] The statistics channel has been updated to use the
|
||||
new network manager. [GL #2022]
|
||||
|
||||
5471. [bug] The introduction of KASP support inadvertently caused
|
||||
the second field of "sig-validity-interval" to always be
|
||||
calculated in hours, even in cases when it should have
|
||||
been calculated in days. This has been fixed. (Thanks to
|
||||
Tony Finch.) [GL !3735]
|
||||
|
||||
5470. [port] gsskrb5_register_acceptor_identity() is now only called
|
||||
if gssapi_krb5.h is present. [GL #1995]
|
||||
|
||||
5469. [port] On illumos, a constant called SEC is already defined in
|
||||
<sys/time.h>, which conflicts with an identically named
|
||||
constant in libbind9. This conflict has been resolved.
|
||||
[GL #1993]
|
||||
|
||||
5468. [bug] Addressed potential double unlock in process_fd().
|
||||
[GL #2005]
|
||||
|
||||
5467. [func] The control channel and the rndc utility have been
|
||||
updated to use the new network manager. To support
|
||||
this, the network manager was updated to enable
|
||||
the initiation of client TCP connections. Its
|
||||
internal reference counting has been refactored.
|
||||
|
||||
Note: As a side effect of this change, rndc cannot
|
||||
currently be used with UNIX-domain sockets, and its
|
||||
default timeout has changed from 60 seconds to 30.
|
||||
These will be addressed in a future release.
|
||||
[GL #1759]
|
||||
|
||||
5466. [bug] Addressed an error in recursive clients stats reporting.
|
||||
[GL #1719]
|
||||
|
||||
5465. [func] Added fallback to built-in trust-anchors, managed-keys,
|
||||
or trusted-keys if the bindkeys-file (bind.keys) cannot
|
||||
be parsed. [GL #1235]
|
||||
|
||||
5464. [bug] Requesting more than 128 files to be saved when rolling
|
||||
dnstap log files caused a buffer overflow. This has been
|
||||
fixed. [GL #1989]
|
||||
|
||||
5463. [placeholder]
|
||||
|
||||
5462. [bug] Move LMDB locking from LMDB itself to named. [GL #1976]
|
||||
|
||||
5461. [bug] The STALE rdataset header attribute was updated while
|
||||
the write lock was not being held, leading to incorrect
|
||||
statistics. The header attributes are now converted to
|
||||
use atomic operations. [GL #1475]
|
||||
5461. [bug] The header STALE attribute was not being updated with
|
||||
the write lock being held leading to incorrect
|
||||
statistics. Convert the header attributes to use atomic
|
||||
operations. [GL #1475]
|
||||
|
||||
5460. [cleanup] tsig-keygen was previously an alias for
|
||||
ddns-confgen and was documented in the ddns-confgen
|
||||
man page. This has been reversed; tsig-keygen is
|
||||
now the primary name. [GL #1998]
|
||||
|
||||
5459. [bug] Fixed bad isc_mem_put() size when an invalid type was
|
||||
specified in an "update-policy" rule. [GL #1990]
|
||||
|
||||
--- 9.17.3 released ---
|
||||
5459. [bug] Bad isc_mem_put() size when an invalid type was
|
||||
specified in a update-policy rule. [GL #1990]
|
||||
|
||||
5458. [bug] Prevent a theoretically possible NULL dereference caused
|
||||
by a data race between zone_maintenance() and
|
||||
@@ -823,21 +19,23 @@
|
||||
|
||||
5456. [func] Added "primaries" as a synonym for "masters" in
|
||||
named.conf, and "primary-only" as a synonym for
|
||||
"master-only" in the parameters to "notify", to bring
|
||||
terminology up-to-date with RFC 8499. [GL #1948]
|
||||
"master-only" in the parameters to "notify",
|
||||
in order to bring terminology up to date with
|
||||
RFC 8499. [GL #1948]
|
||||
|
||||
5455. [bug] named could crash when cleaning dead nodes in
|
||||
lib/dns/rbtdb.c that were being reused. [GL #1968]
|
||||
5455. [bug] `named` could crash when cleaning dead nodes
|
||||
in lib/dns/rbtdb.c that have been reused meanwhile.
|
||||
[GL #1968]
|
||||
|
||||
5454. [bug] Address a startup crash that occurred when the server
|
||||
was under load and the root zone had not yet been
|
||||
loaded. [GL #1862]
|
||||
5454. [bug] Address a startup crash happening when server is
|
||||
under load and root zone is not yet loaded. [GL #1862]
|
||||
|
||||
5453. [bug] named crashed on shutdown when a new rndc connection was
|
||||
received during shutdown. [GL #1747]
|
||||
5453. [bug] `named` would crash on shutdown when new `rndc`
|
||||
connection is received at the same time as
|
||||
shutting down. [GL #1747]
|
||||
|
||||
5452. [bug] The "blackhole" ACL was accidentally disabled for client
|
||||
queries. [GL #1936]
|
||||
5452. [bug] The "blackhole" ACL was accidentally disabled with
|
||||
respect to client queries. [GL #1936]
|
||||
|
||||
5451. [func] Add 'rndc dnssec -status' command. [GL #1612]
|
||||
|
||||
@@ -855,14 +53,14 @@
|
||||
|
||||
5446. [bug] The validator could fail to accept a properly signed
|
||||
RRset if an unsupported algorithm appeared earlier in
|
||||
the DNSKEY RRset than a supported algorithm. It could
|
||||
the DNSKEY RRset than a supported algorithm. It could
|
||||
also stop if it detected a malformed public key.
|
||||
[GL #1689]
|
||||
|
||||
5445. [cleanup] Disable and disallow static linking. [GL #1933]
|
||||
|
||||
5444. [bug] 'rndc dnstap -roll <value>' did not limit the number of
|
||||
saved files to <value>. [GL !3728]
|
||||
5444. [bug] 'rndc dnstap -roll <value>' was not limiting the
|
||||
number of saved files to <value>. [GL !3728]
|
||||
|
||||
5443. [bug] The "primary" and "secondary" keywords, when used
|
||||
as parameters for "check-names", were not
|
||||
@@ -875,8 +73,8 @@
|
||||
|
||||
5440. [placeholder]
|
||||
|
||||
5439. [bug] The DS RRset returned by dns_keynode_dsset() was used in
|
||||
a non-thread-safe manner. [GL #1926]
|
||||
5439. [bug] The dsset returned by dns_keynode_dsset() was not
|
||||
thread safe. [GL #1926]
|
||||
|
||||
--- 9.17.2 released ---
|
||||
|
||||
|
||||
+3
-3
@@ -6,9 +6,9 @@ on every aspect of the mission - including mentorship, teaching, and connecting
|
||||
people.
|
||||
|
||||
Diversity is one of our huge strengths, but it can also lead to communication
|
||||
issues and unhappiness. To that end, we have a few ground rules that we ask
|
||||
people to adhere to. This code applies equally to the core development team,
|
||||
open source contributors and those seeking help and guidance.
|
||||
issues and unhappiness. To that end, we have a few ground rules to which we expect
|
||||
people to adhere. This code applies equally to the core development team, open source contributors and those
|
||||
seeking help and guidance.
|
||||
|
||||
This isn't an exhaustive list of things that you can't do. Rather, take it in
|
||||
the spirit in which it's intended - a guide to make it easier to enrich all of
|
||||
|
||||
+16
-19
@@ -39,28 +39,29 @@ anyone can see the source, but only ISC employees have commit access.
|
||||
In the past, the source could only be seen once ISC had published
|
||||
a release; read access to the source repository was restricted just
|
||||
as commit access was. That has changed, as ISC now provides a
|
||||
public git repository of the BIND source tree (see below).
|
||||
public git mirror to the BIND source tree (see below).
|
||||
|
||||
At ISC, we're committed to
|
||||
building communities that are welcoming and inclusive: environments where people
|
||||
are encouraged to share ideas, treat each other with respect, and collaborate
|
||||
towards the best solutions. To reinforce our commitment, ISC
|
||||
has adopted a slightly modified version of the Django
|
||||
[Code of Conduct](https://gitlab.isc.org/isc-projects/bind9/-/blob/main/CODE_OF_CONDUCT.md)
|
||||
for the BIND 9 project, as well as for the conduct of our developers throughout
|
||||
the industry.
|
||||
[Code of Conduct](https://gitlab.isc.org/isc-projects/bind9/-/blob/master/CODE_OF_CONDUCT.md) for the BIND 9 project, as well as for the conduct of our
|
||||
developers throughout the industry.
|
||||
|
||||
### <a name="access"></a>Access to source code
|
||||
|
||||
Public BIND releases are always available from the
|
||||
[ISC FTP site](ftp://ftp.isc.org/isc/bind9).
|
||||
|
||||
A public-access git repository is also available at
|
||||
[https://gitlab.isc.org](https://gitlab.isc.org). This repository
|
||||
contains all public release branches. Upcoming releases can be viewed in
|
||||
their current state at any time. Short-lived development branches
|
||||
contain unreviewed work in progress. Commits which address security
|
||||
vulnerablilities are withheld until after public disclosure.
|
||||
A public-access GIT repository is also available at
|
||||
[https://gitlab.isc.org](https://gitlab.isc.org).
|
||||
This repository is a mirror, updated several times per day, of the
|
||||
source repository maintained by ISC. It contains all the public release
|
||||
branches; upcoming releases can be viewed in their current state at any
|
||||
time. It does *not* contain development branches or unreviewed work in
|
||||
progress. Commits which address security vulnerablilities are withheld
|
||||
until after public disclosure.
|
||||
|
||||
You can browse the source online via
|
||||
[https://gitlab.isc.org/isc-projects/bind9](https://gitlab.isc.org/isc-projects/bind9)
|
||||
@@ -79,7 +80,7 @@ Whenever a branch is ready for publication, a tag is placed of the
|
||||
form `v9_X_Y`. The 9.12.0 release, for instance, is tagged as `v9_12_0`.
|
||||
|
||||
The branch in which the next major release is being developed is called
|
||||
`main`.
|
||||
`master`.
|
||||
|
||||
### <a name="bugs"></a>Reporting bugs
|
||||
|
||||
@@ -99,7 +100,6 @@ use credentials from an existing account at GitHub, GitLab, Google,
|
||||
Twitter, or Facebook.
|
||||
|
||||
### Reporting possible security issues
|
||||
|
||||
If you think you may be seeing a potential security vulnerability in BIND
|
||||
(for example, a crash with REQUIRE, INSIST, or ASSERT failure), please
|
||||
report it immediately by emailing to security-officer@isc.org. Plain-text
|
||||
@@ -111,8 +111,7 @@ Do not discuss undisclosed security vulnerabilities on any public mailing list.
|
||||
ISC has a long history of handling reported vulnerabilities promptly and
|
||||
effectively and we respect and acknowledge responsible reporters.
|
||||
|
||||
ISC's Security Vulnerability Disclosure Policy is documented at
|
||||
[https://kb.isc.org/docs/aa-00861](https://kb.isc.org/docs/aa-00861).
|
||||
ISC's Security Vulnerability Disclosure Policy is documented at [https://kb.isc.org/docs/aa-00861](https://kb.isc.org/docs/aa-00861).
|
||||
|
||||
If you have a crash, you may want to consult
|
||||
["What to do if your BIND or DHCP server has crashed."](https://kb.isc.org/docs/aa-00340)
|
||||
@@ -121,8 +120,7 @@ If you have a crash, you may want to consult
|
||||
|
||||
BIND is licensed under the
|
||||
[Mozilla Public License 2.0](https://www.mozilla.org/en-US/MPL/2.0/).
|
||||
Earlier versions (BIND 9.10 and earlier) were licensed under the
|
||||
[ISC License](https://www.isc.org/licenses/)
|
||||
Earlier versions (BIND 9.10 and earlier) were licensed under the [ISC License](https://www.isc.org/licenses/)
|
||||
|
||||
ISC does not require an explicit copyright assignment for patch
|
||||
contributions. However, by submitting a patch to ISC, you implicitly
|
||||
@@ -138,7 +136,7 @@ Patches for BIND may be submitted directly via merge requests in
|
||||
repository for BIND.
|
||||
|
||||
Patches can also be submitted as diffs against a specific version of
|
||||
BIND -- preferably the current top of the `main` branch. Diffs may
|
||||
BIND -- preferably the current top of the `master` branch. Diffs may
|
||||
be generated using either `git format-patch` or `git diff`.
|
||||
|
||||
Those wanting to write code for BIND may be interested in the
|
||||
@@ -186,8 +184,7 @@ of documentation in the BIND source tree:
|
||||
they document, in files ending in `.rst`: for example, the
|
||||
`named` man page is `bin/named/named.rst`.
|
||||
* The *BIND 9 Administrator Reference Manual* is in the .rst files in
|
||||
`doc/arm/`; the PDF and HTML versions are automatically generated from
|
||||
the `.rst` files.
|
||||
`doc/arm/`; the PDF and HTML versions are automatically generated from the `.rst` files.
|
||||
* API documentation is in the header file describing the API, in
|
||||
Doxygen-formatted comments.
|
||||
|
||||
|
||||
@@ -1,8 +1,8 @@
|
||||
Copyright (C) 1996-2021 Internet Systems Consortium, Inc. ("ISC")
|
||||
Copyright (C) 1996-2020 Internet Systems Consortium, Inc. ("ISC")
|
||||
|
||||
This Source Code Form is subject to the terms of the Mozilla Public
|
||||
License, v. 2.0. If a copy of the MPL was not distributed with this
|
||||
file, you can obtain one at https://mozilla.org/MPL/2.0/.
|
||||
file, You can obtain one at http://mozilla.org/MPL/2.0/.
|
||||
|
||||
-----------------------------------------------------------------------------
|
||||
|
||||
@@ -367,25 +367,3 @@ distributed under the License is distributed on an "AS IS" BASIS,
|
||||
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
See the License for the specific language governing permissions and
|
||||
limitations under the License.
|
||||
|
||||
-----------------------------------------------------------------------------
|
||||
|
||||
Copyright Joyent, Inc. and other Node contributors. All rights reserved.
|
||||
|
||||
Permission is hereby granted, free of charge, to any person obtaining a copy
|
||||
of this software and associated documentation files (the "Software"), to
|
||||
deal in the Software without restriction, including without limitation the
|
||||
rights to use, copy, modify, merge, publish, distribute, sublicense, and/or
|
||||
sell copies of the Software, and to permit persons to whom the Software is
|
||||
furnished to do so, subject to the following conditions:
|
||||
|
||||
The above copyright notice and this permission notice shall be included in
|
||||
all copies or substantial portions of the Software.
|
||||
|
||||
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
||||
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
||||
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
||||
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
||||
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
|
||||
FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS
|
||||
IN THE SOFTWARE.
|
||||
|
||||
+1
-1
@@ -1,6 +1,6 @@
|
||||
include $(top_srcdir)/Makefile.top
|
||||
|
||||
SUBDIRS = . lib doc bin fuzz
|
||||
SUBDIRS = . libltdl lib doc bin
|
||||
|
||||
BUILT_SOURCES = bind.keys.h
|
||||
CLEANFILES = bind.keys.h
|
||||
|
||||
@@ -10,7 +10,6 @@ AM_V_SPHINX_0 = @echo " SPHINX $@";
|
||||
SPHINXBUILDDIR = $(builddir)/_build
|
||||
|
||||
common_SPHINXOPTS = \
|
||||
-W \
|
||||
-c $(srcdir) \
|
||||
-a \
|
||||
$(SPHINX_V)
|
||||
|
||||
+2
-3
@@ -3,9 +3,8 @@
|
||||
|
||||
AM_CPPFLAGS += \
|
||||
$(CMOCKA_CFLAGS) \
|
||||
-DNAMED_PLUGINDIR=\"$(libdir)/named\" \
|
||||
-DSKIPPED_TEST_EXIT_CODE=77 \
|
||||
-DTESTS_DIR=\"$(abs_srcdir)\"
|
||||
-DTESTS_DIR=\"$(abs_srcdir)\" \
|
||||
-DNAMED_PLUGINDIR=\"$(libdir)/named\"
|
||||
|
||||
LDADD = \
|
||||
$(CMOCKA_LIBS)
|
||||
|
||||
+30
-6
@@ -11,12 +11,10 @@ AM_CPPFLAGS = \
|
||||
-include $(top_builddir)/config.h \
|
||||
-I$(srcdir)/include
|
||||
|
||||
AM_LDFLAGS =
|
||||
|
||||
if HOST_MACOS
|
||||
AM_LDFLAGS += \
|
||||
-Wl,-flat_namespace
|
||||
endif HOST_MACOS
|
||||
if HAVE_GSSAPI
|
||||
AM_CPPFLAGS += \
|
||||
$(GSSAPI_CFLAGS)
|
||||
endif
|
||||
|
||||
LIBISC_CFLAGS = \
|
||||
-I$(top_srcdir)/include \
|
||||
@@ -25,6 +23,16 @@ LIBISC_CFLAGS = \
|
||||
-I$(top_srcdir)/lib/isc/include \
|
||||
-I$(top_builddir)/lib/isc/include
|
||||
|
||||
if HAVE_JSON_C
|
||||
LIBISC_CFLAGS += \
|
||||
$(JSON_C_CFLAGS)
|
||||
endif HAVE_JSON_C
|
||||
|
||||
if HAVE_LIBXML2
|
||||
LIBISC_CFLAGS += \
|
||||
$(LIBXML2_CFLAGS)
|
||||
endif HAVE_LIBXML2
|
||||
|
||||
LIBISC_LIBS = $(top_builddir)/lib/isc/libisc.la
|
||||
|
||||
LIBDNS_CFLAGS = \
|
||||
@@ -34,6 +42,16 @@ LIBDNS_CFLAGS = \
|
||||
LIBDNS_LIBS = \
|
||||
$(top_builddir)/lib/dns/libdns.la
|
||||
|
||||
if HAVE_DNSTAP
|
||||
LIBDNS_CFLAGS += \
|
||||
$(DNSTAP_CFLAGS)
|
||||
endif HAVE_DNSTAP
|
||||
|
||||
if HAVE_LMDB
|
||||
LIBDNS_CFLAGS += \
|
||||
$(LMDB_CFLAGS)
|
||||
endif HAVE_LMDB
|
||||
|
||||
LIBNS_CFLAGS = \
|
||||
-I$(top_srcdir)/lib/ns/include
|
||||
|
||||
@@ -63,3 +81,9 @@ LIBBIND9_CFLAGS = \
|
||||
|
||||
LIBBIND9_LIBS = \
|
||||
$(top_builddir)/lib/bind9/libbind9.la
|
||||
|
||||
LIBLTDL_CFLAGS = \
|
||||
-I$(top_srcdir)/libltdl
|
||||
|
||||
LIBLTDL_LIBS = \
|
||||
$(top_builddir)/libltdl/libltdlc.la
|
||||
|
||||
+14
-13
@@ -8,19 +8,20 @@
|
||||
- See the COPYRIGHT file distributed with this work for additional
|
||||
- information regarding copyright ownership.
|
||||
-->
|
||||
Setting the `CPPFLAGS` environment variable before running `configure`
|
||||
can be used to enable certain compile-time options that are not
|
||||
explicitly defined in `configure`.
|
||||
Setting the `STD_CDEFINES` environment variable before running `configure`
|
||||
can be used to enable certain compile-time options that are not explicitly
|
||||
defined in `configure`.
|
||||
|
||||
Some of these settings are:
|
||||
|
||||
| Setting | Description |
|
||||
| ---------------------------- | -------------------------------------------------------------------------------------------------------------------------------------- |
|
||||
| `-DCHECK_LOCAL=0` | Don't check out-of-zone addresses in `named-checkzone` |
|
||||
| `-DCHECK_SIBLING=0` | Don't check sibling glue in `named-checkzone` |
|
||||
| `-DISC_FACILITY=LOG_LOCAL0` | Change the default syslog facility for `named` |
|
||||
| `-DISC_HEAP_CHECK` | Test heap consistency after every heap operation; used when debugging |
|
||||
| `-DISC_MEM_DEFAULTFILL=1` | Overwrite memory with tag values when allocating or freeing it; this impairs performance but makes debugging of memory problems easier |
|
||||
| `-DISC_MEM_TRACKLINES=0` | Don't track memory allocations by file and line number; this improves performance but makes debugging more difficult |
|
||||
| `-DNAMED_RUN_PID_DIR=0` | Create default PID files in `${localstatedir}/run` rather than `${localstatedir}/run/named/` |
|
||||
| `-DNS_CLIENT_DROPPORT=0` | Disable dropping queries from particular well-known ports |
|
||||
|Setting |Description |
|
||||
|-----------------------------------|----------------------------------------|
|
||||
|`-DISC_MEM_DEFAULTFILL=1`|Overwrite memory with tag values when allocating or freeing it; this impairs performance but makes debugging of memory problems easier.|
|
||||
|`-DISC_MEM_TRACKLINES=0`|Don't track memory allocations by file and line number; this improves performance but makes debugging more difficult.|
|
||||
|<nobr>`-DISC_FACILITY=LOG_LOCAL0`</nobr>|Change the default syslog facility for `named`|
|
||||
|`-DNS_CLIENT_DROPPORT=0`|Disable dropping queries from particular well-known ports:|
|
||||
|`-DCHECK_SIBLING=0`|Don't check sibling glue in `named-checkzone`|
|
||||
|`-DCHECK_LOCAL=0`|Don't check out-of-zone addresses in `named-checkzone`|
|
||||
|`-DNS_RUN_PID_DIR=0`|Create default PID files in `${localstatedir}/run` rather than `${localstatedir}/run/named/`|
|
||||
|`-DISC_BUFFER_USEINLINE=0`|Disable the use of inline functions to implement the `isc_buffer` API: this reduces performance but may be useful when debugging |
|
||||
|`-DISC_HEAP_CHECK`|Test heap consistency after every heap operation; used when debugging|
|
||||
|
||||
+10
-10
@@ -13,7 +13,7 @@
|
||||
In general, this version of BIND will build and run on any POSIX-compliant
|
||||
system with a C11-compliant C compiler, BSD-style sockets with RFC-compliant
|
||||
IPv6 support, POSIX-compliant threads, the `libuv` asynchronous I/O library,
|
||||
the OpenSSL cryptography library, and the `nghttp2` HTTP/2 library.
|
||||
and the OpenSSL cryptography library.
|
||||
|
||||
The following C11 features are used in BIND 9:
|
||||
|
||||
@@ -42,16 +42,16 @@ offer support on a "best effort" basis for some.
|
||||
|
||||
### Regularly tested platforms
|
||||
|
||||
As of Nov 2020, BIND 9.17 is fully supported and regularly tested on the
|
||||
As of Jul 2020, BIND 9.17 is fully supported and regularly tested on the
|
||||
following systems:
|
||||
|
||||
* Debian 9, 10
|
||||
* Ubuntu LTS 18.04, 20.04
|
||||
* Fedora 34
|
||||
* Ubuntu LTS 16.04, 20.04
|
||||
* Fedora 32
|
||||
* Red Hat Enterprise Linux / CentOS 7, 8
|
||||
* FreeBSD 11.4, 12.2, 13.0
|
||||
* OpenBSD 6.9
|
||||
* Alpine Linux 3.13
|
||||
* FreeBSD 11.4, 12.1
|
||||
* OpenBSD 6.7
|
||||
* Alpine Linux 3.12
|
||||
|
||||
The amd64, i386, armhf and arm64 CPU architectures are all fully supported.
|
||||
|
||||
@@ -61,7 +61,7 @@ The following are platforms on which BIND is known to build and run.
|
||||
ISC makes every effort to fix bugs on these platforms, but may be unable to
|
||||
do so quickly due to lack of hardware, less familiarity on the part of
|
||||
engineering staff, and other constraints. With the exception of Windows
|
||||
Server 2016, none of these are tested regularly by ISC.
|
||||
Server 2012 R2, none of these are tested regularly by ISC.
|
||||
|
||||
* Windows Server 2012 R2, 2016 / x64
|
||||
* Windows 10 / x64
|
||||
@@ -69,7 +69,7 @@ Server 2016, none of these are tested regularly by ISC.
|
||||
* Solaris 11
|
||||
* NetBSD
|
||||
* Other Linux distributions still supported by their vendors, such as:
|
||||
* Ubuntu 20.10+
|
||||
* Ubuntu 19.04+
|
||||
* Gentoo
|
||||
* Arch Linux
|
||||
* OpenWRT/LEDE 17.01+
|
||||
@@ -86,7 +86,7 @@ assessed against the risk of adverse effect on officially supported
|
||||
platforms.
|
||||
|
||||
* Platforms past or close to their respective EOL dates, such as:
|
||||
* Ubuntu 14.04, 16.04 (Ubuntu ESM releases are not supported)
|
||||
* Ubuntu 14.04, 18.10
|
||||
* CentOS 6
|
||||
* Debian Jessie
|
||||
* FreeBSD 10.x
|
||||
|
||||
@@ -15,6 +15,7 @@
|
||||
1. [Introduction](#intro)
|
||||
1. [Reporting bugs and getting help](#help)
|
||||
1. [Contributing to BIND](#contrib)
|
||||
1. [BIND 9.17 features](#features)
|
||||
1. [Building BIND](#build)
|
||||
1. [macOS](#macos)
|
||||
1. [Dependencies](#dependencies)
|
||||
@@ -124,17 +125,27 @@ If you prefer, you may also submit code by opening a
|
||||
including your patch as an attachment, preferably generated by
|
||||
`git format-patch`.
|
||||
|
||||
### <a name="features"/> BIND 9.17 features
|
||||
|
||||
BIND 9.17 is the newest development branch of BIND 9. It includes a
|
||||
number of changes from BIND 9.16 and earlier releases. New features include:
|
||||
|
||||
* The new option `max-ixfr-ratio` to limit the size of outgoing IXFR responses
|
||||
before falling back to full zone transfers.
|
||||
* `rndc nta -d` and `rndc secroots` now include `validate-except` entries
|
||||
when listing negative trust anchors.
|
||||
|
||||
### <a name="build"/> Building BIND 9
|
||||
|
||||
At a minimum, BIND requires a Unix or Linux system with an ANSI C compiler,
|
||||
basic POSIX support, and a 64-bit integer type. BIND also requires the
|
||||
`libuv` asynchronous I/O library, the `nghttp2` HTTP/2 library, and a
|
||||
cryptography provider library such as OpenSSL or a hardware service
|
||||
module supporting PKCS#11. On Linux, BIND requires the `libcap` library
|
||||
to set process privileges, though this requirement can be overridden by
|
||||
disabling capability support at compile time. See [Compile-time
|
||||
options](#opts) below for details on other libraries that may be
|
||||
required to support optional features.
|
||||
`libuv` asynchronous I/O library, and a cryptography provider library
|
||||
such as OpenSSL or a hardware service module supporting PKCS#11. On
|
||||
Linux, BIND requires the `libcap` library to set process privileges,
|
||||
though this requirement can be overridden by disabling capability
|
||||
support at compile time. See [Compile-time options](#opts) below
|
||||
for details on other libraries that may be required to support
|
||||
optional features.
|
||||
|
||||
Successful builds have been observed on many versions of Linux and
|
||||
Unix, including RHEL/CentOS, Fedora, Debian, Ubuntu, SLES, openSUSE,
|
||||
@@ -151,7 +162,8 @@ To build on a Unix or Linux system, use:
|
||||
$ ./configure
|
||||
$ make
|
||||
|
||||
If you're using Emacs, you might find `make tags` helpful.
|
||||
If you're planning on making changes to the BIND 9 source, you should run
|
||||
`make depend`. If you're using Emacs, you might find `make tags` helpful.
|
||||
|
||||
Several environment variables, which can be set before running `configure`,
|
||||
affect compilation. Significant ones are:
|
||||
@@ -173,8 +185,9 @@ command:
|
||||
Building on macOS assumes that the "Command Tools for Xcode" are installed.
|
||||
These can be downloaded from
|
||||
[https://developer.apple.com/download/more/](https://developer.apple.com/download/more/)
|
||||
or, if you have Xcode already installed, you can run `xcode-select --install`.
|
||||
(Note that an Apple ID may be required to access the download page.)
|
||||
or, if you have Xcode already installed, you can run
|
||||
`xcode-select--install`. (Note that an Apple ID may be required to access the download
|
||||
page.)
|
||||
|
||||
#### <a name="dependencies"> Dependencies
|
||||
|
||||
@@ -189,11 +202,15 @@ installed:
|
||||
autoconf (includes autoreconf)
|
||||
automake
|
||||
libtool
|
||||
libltdl-dev (Debian) / libtool-ltdl-dev (Fedora/CentOS) / libltdl (FreeBSD)
|
||||
|
||||
#### <a name="opts"/> Compile-time options
|
||||
|
||||
To see a full list of configuration options, run `configure --help`.
|
||||
|
||||
To build shared libraries, specify `--with-libtool` on the `configure`
|
||||
command line.
|
||||
|
||||
For the server to support DNSSEC, you need to build it with crypto support.
|
||||
To use OpenSSL, you should have OpenSSL 1.0.2e or newer installed. If the
|
||||
OpenSSL library is installed in a nonstandard location, specify the prefix
|
||||
@@ -322,7 +339,7 @@ the change that was made; these categories are:
|
||||
| [cleanup] | Minor corrections and refactoring |
|
||||
| [doc] | Documentation |
|
||||
| [contrib] | Changes to the contributed tools and libraries in the 'contrib' subdirectory |
|
||||
| [placeholder] | Used in the main development branch to reserve change numbers for use in other branches, e.g., when fixing a bug that only exists in older releases |
|
||||
| [placeholder] | Used in the master development branch to reserve change numbers for use in other branches, e.g., when fixing a bug that only exists in older releases |
|
||||
|
||||
In general, [func] and [experimental] tags only appear in new-feature
|
||||
releases (i.e., those with version numbers ending in zero). Some new
|
||||
|
||||
@@ -3,7 +3,7 @@
|
||||
*
|
||||
* This Source Code Form is subject to the terms of the Mozilla Public
|
||||
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
||||
* file, you can obtain one at https://mozilla.org/MPL/2.0/.
|
||||
* file, You can obtain one at http://mozilla.org/MPL/2.0/.
|
||||
*
|
||||
* See the COPYRIGHT file distributed with this work for additional
|
||||
* information regarding copyright ownership.
|
||||
|
||||
@@ -3,7 +3,7 @@
|
||||
*
|
||||
* This Source Code Form is subject to the terms of the Mozilla Public
|
||||
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
||||
* file, you can obtain one at https://mozilla.org/MPL/2.0/.
|
||||
* file, You can obtain one at http://mozilla.org/MPL/2.0/.
|
||||
*
|
||||
* See the COPYRIGHT file distributed with this work for additional
|
||||
* information regarding copyright ownership.
|
||||
|
||||
@@ -3,7 +3,7 @@
|
||||
*
|
||||
* This Source Code Form is subject to the terms of the Mozilla Public
|
||||
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
||||
* file, you can obtain one at https://mozilla.org/MPL/2.0/.
|
||||
* file, You can obtain one at http://mozilla.org/MPL/2.0/.
|
||||
*
|
||||
* See the COPYRIGHT file distributed with this work for additional
|
||||
* information regarding copyright ownership.
|
||||
|
||||
@@ -3,7 +3,7 @@
|
||||
|
||||
This Source Code Form is subject to the terms of the Mozilla Public
|
||||
License, v. 2.0. If a copy of the MPL was not distributed with this
|
||||
file, you can obtain one at https://mozilla.org/MPL/2.0/.
|
||||
file, You can obtain one at http://mozilla.org/MPL/2.0/.
|
||||
|
||||
See the COPYRIGHT file distributed with this work for additional
|
||||
information regarding copyright ownership.
|
||||
|
||||
@@ -3,7 +3,7 @@
|
||||
*
|
||||
* This Source Code Form is subject to the terms of the Mozilla Public
|
||||
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
||||
* file, you can obtain one at https://mozilla.org/MPL/2.0/.
|
||||
* file, You can obtain one at http://mozilla.org/MPL/2.0/.
|
||||
*
|
||||
* See the COPYRIGHT file distributed with this work for additional
|
||||
* information regarding copyright ownership.
|
||||
|
||||
@@ -3,7 +3,7 @@
|
||||
|
||||
This Source Code Form is subject to the terms of the Mozilla Public
|
||||
License, v. 2.0. If a copy of the MPL was not distributed with this
|
||||
file, you can obtain one at https://mozilla.org/MPL/2.0/.
|
||||
file, You can obtain one at http://mozilla.org/MPL/2.0/.
|
||||
|
||||
See the COPYRIGHT file distributed with this work for additional
|
||||
information regarding copyright ownership.
|
||||
@@ -21,6 +21,8 @@
|
||||
|
||||
.. highlight: console
|
||||
|
||||
.. _man_named-checkzone:
|
||||
|
||||
named-checkzone, named-compilezone - zone file validity checking or converting tool
|
||||
-----------------------------------------------------------------------------------
|
||||
|
||||
|
||||
@@ -77,7 +77,7 @@
|
||||
<GenerateDebugInformation>true</GenerateDebugInformation>
|
||||
<OutputFile>..\..\..\Build\$(Configuration)\$(TargetName)$(TargetExt)</OutputFile>
|
||||
<AdditionalLibraryDirectories>$(Configuration);..\..\..\lib\isc\win32\$(Configuration);..\..\..\lib\dns\win32\$(Configuration);..\..\..\lib\isccfg\win32\$(Configuration);..\..\..\lib\isccc\win32\$(Configuration);..\..\..\lib\bind9\win32\$(Configuration);..\..\..\lib\ns\win32\$(Configuration);%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>
|
||||
<AdditionalDependencies>@OPENSSL_LIBCRYPTO@@OPENSSL_LIBSSL@checktool.lib;libisc.lib;libdns.lib;libisccfg.lib;libisccc.lib;libbind9.lib;libns.lib;ws2_32.lib;%(AdditionalDependencies)</AdditionalDependencies>
|
||||
<AdditionalDependencies>@OPENSSL_LIB@checktool.lib;libisc.lib;libdns.lib;libisccfg.lib;libisccc.lib;libbind9.lib;libns.lib;ws2_32.lib;%(AdditionalDependencies)</AdditionalDependencies>
|
||||
</Link>
|
||||
</ItemDefinitionGroup>
|
||||
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|@PLATFORM@'">
|
||||
@@ -108,7 +108,7 @@
|
||||
<OptimizeReferences>true</OptimizeReferences>
|
||||
<OutputFile>..\..\..\Build\$(Configuration)\$(TargetName)$(TargetExt)</OutputFile>
|
||||
<AdditionalLibraryDirectories>$(Configuration);..\..\..\lib\isc\win32\$(Configuration);..\..\..\lib\dns\win32\$(Configuration);..\..\..\lib\isccfg\win32\$(Configuration);..\..\..\lib\isccc\win32\$(Configuration);..\..\..\lib\bind9\win32\$(Configuration);..\..\..\lib\ns\win32\$(Configuration);%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>
|
||||
<AdditionalDependencies>@OPENSSL_LIBCRYPTO@@OPENSSL_LIBSSL@checktool.lib;libisc.lib;libdns.lib;libisccfg.lib;libisccc.lib;libbind9.lib;libns.lib;ws2_32.lib;%(AdditionalDependencies)</AdditionalDependencies>
|
||||
<AdditionalDependencies>@OPENSSL_LIB@checktool.lib;libisc.lib;libdns.lib;libisccfg.lib;libisccc.lib;libbind9.lib;libns.lib;ws2_32.lib;%(AdditionalDependencies)</AdditionalDependencies>
|
||||
<LinkTimeCodeGeneration>Default</LinkTimeCodeGeneration>
|
||||
</Link>
|
||||
</ItemDefinitionGroup>
|
||||
|
||||
@@ -77,7 +77,7 @@
|
||||
<GenerateDebugInformation>true</GenerateDebugInformation>
|
||||
<OutputFile>..\..\..\Build\$(Configuration)\$(TargetName)$(TargetExt)</OutputFile>
|
||||
<AdditionalLibraryDirectories>$(Configuration);..\..\..\lib\isc\win32\$(Configuration);..\..\..\lib\dns\win32\$(Configuration);..\..\..\lib\isccfg\win32\$(Configuration);..\..\..\lib\ns\win32\$(Configuration);%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>
|
||||
<AdditionalDependencies>@OPENSSL_LIBCRYPTO@@OPENSSL_LIBSSL@checktool.lib;libisc.lib;libdns.lib;libisccfg.lib;libns.lib;ws2_32.lib;%(AdditionalDependencies)</AdditionalDependencies>
|
||||
<AdditionalDependencies>@OPENSSL_LIB@checktool.lib;libisc.lib;libdns.lib;libisccfg.lib;libns.lib;ws2_32.lib;%(AdditionalDependencies)</AdditionalDependencies>
|
||||
</Link>
|
||||
<PostBuildEvent>
|
||||
<Command>cd ..\..\..\Build\$(Configuration)
|
||||
@@ -114,7 +114,7 @@ copy /Y named-checkzone.ilk named-compilezone.ilk
|
||||
<OptimizeReferences>true</OptimizeReferences>
|
||||
<OutputFile>..\..\..\Build\$(Configuration)\$(TargetName)$(TargetExt)</OutputFile>
|
||||
<AdditionalLibraryDirectories>$(Configuration);..\..\..\lib\isc\win32\$(Configuration);..\..\..\lib\dns\win32\$(Configuration);..\..\..\lib\isccfg\win32\$(Configuration);..\..\..\lib\ns\win32\$(Configuration);%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>
|
||||
<AdditionalDependencies>@OPENSSL_LIBCRYPTO@@OPENSSL_LIBSSL@checktool.lib;libisc.lib;libdns.lib;libisccfg.lib;libns.lib;ws2_32.lib;%(AdditionalDependencies)</AdditionalDependencies>
|
||||
<AdditionalDependencies>@OPENSSL_LIB@checktool.lib;libisc.lib;libdns.lib;libisccfg.lib;libns.lib;ws2_32.lib;%(AdditionalDependencies)</AdditionalDependencies>
|
||||
<LinkTimeCodeGeneration>Default</LinkTimeCodeGeneration>
|
||||
</Link>
|
||||
<PostBuildEvent>
|
||||
|
||||
@@ -3,7 +3,7 @@
|
||||
*
|
||||
* This Source Code Form is subject to the terms of the Mozilla Public
|
||||
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
||||
* file, you can obtain one at https://mozilla.org/MPL/2.0/.
|
||||
* file, You can obtain one at http://mozilla.org/MPL/2.0/.
|
||||
*
|
||||
* See the COPYRIGHT file distributed with this work for additional
|
||||
* information regarding copyright ownership.
|
||||
|
||||
@@ -3,7 +3,7 @@
|
||||
*
|
||||
* This Source Code Form is subject to the terms of the Mozilla Public
|
||||
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
||||
* file, you can obtain one at https://mozilla.org/MPL/2.0/.
|
||||
* file, You can obtain one at http://mozilla.org/MPL/2.0/.
|
||||
*
|
||||
* See the COPYRIGHT file distributed with this work for additional
|
||||
* information regarding copyright ownership.
|
||||
|
||||
@@ -3,7 +3,7 @@
|
||||
*
|
||||
* This Source Code Form is subject to the terms of the Mozilla Public
|
||||
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
||||
* file, you can obtain one at https://mozilla.org/MPL/2.0/.
|
||||
* file, You can obtain one at http://mozilla.org/MPL/2.0/.
|
||||
*
|
||||
* See the COPYRIGHT file distributed with this work for additional
|
||||
* information regarding copyright ownership.
|
||||
|
||||
@@ -3,7 +3,7 @@
|
||||
*
|
||||
* This Source Code Form is subject to the terms of the Mozilla Public
|
||||
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
||||
* file, you can obtain one at https://mozilla.org/MPL/2.0/.
|
||||
* file, You can obtain one at http://mozilla.org/MPL/2.0/.
|
||||
*
|
||||
* See the COPYRIGHT file distributed with this work for additional
|
||||
* information regarding copyright ownership.
|
||||
|
||||
@@ -3,7 +3,7 @@
|
||||
|
||||
This Source Code Form is subject to the terms of the Mozilla Public
|
||||
License, v. 2.0. If a copy of the MPL was not distributed with this
|
||||
file, you can obtain one at https://mozilla.org/MPL/2.0/.
|
||||
file, You can obtain one at http://mozilla.org/MPL/2.0/.
|
||||
|
||||
See the COPYRIGHT file distributed with this work for additional
|
||||
information regarding copyright ownership.
|
||||
|
||||
@@ -3,7 +3,7 @@
|
||||
*
|
||||
* This Source Code Form is subject to the terms of the Mozilla Public
|
||||
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
||||
* file, you can obtain one at https://mozilla.org/MPL/2.0/.
|
||||
* file, You can obtain one at http://mozilla.org/MPL/2.0/.
|
||||
*
|
||||
* See the COPYRIGHT file distributed with this work for additional
|
||||
* information regarding copyright ownership.
|
||||
|
||||
@@ -3,7 +3,7 @@
|
||||
|
||||
This Source Code Form is subject to the terms of the Mozilla Public
|
||||
License, v. 2.0. If a copy of the MPL was not distributed with this
|
||||
file, you can obtain one at https://mozilla.org/MPL/2.0/.
|
||||
file, You can obtain one at http://mozilla.org/MPL/2.0/.
|
||||
|
||||
See the COPYRIGHT file distributed with this work for additional
|
||||
information regarding copyright ownership.
|
||||
@@ -21,12 +21,14 @@
|
||||
|
||||
.. highlight: console
|
||||
|
||||
.. _man_tsig-keygen:
|
||||
|
||||
tsig-keygen, ddns-confgen - TSIG key generation tool
|
||||
----------------------------------------------------
|
||||
|
||||
Synopsis
|
||||
~~~~~~~~
|
||||
:program:`tsig-keygen` [**-a** algorithm] [**-h**] [**-r** randomfile] [name]
|
||||
:program:`tsig-keygen` [**-a** algorithm] [**-h**] [**-r** randomfile] [**-s** name]
|
||||
|
||||
:program:`ddns-confgen` [**-a** algorithm] [**-h**] [**-k** keyname] [**-q**] [**-r** randomfile] [**-s** name] [**-z** zone]
|
||||
|
||||
|
||||
@@ -3,7 +3,7 @@
|
||||
*
|
||||
* This Source Code Form is subject to the terms of the Mozilla Public
|
||||
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
||||
* file, you can obtain one at https://mozilla.org/MPL/2.0/.
|
||||
* file, You can obtain one at http://mozilla.org/MPL/2.0/.
|
||||
*
|
||||
* See the COPYRIGHT file distributed with this work for additional
|
||||
* information regarding copyright ownership.
|
||||
|
||||
+1
-1
@@ -3,7 +3,7 @@
|
||||
*
|
||||
* This Source Code Form is subject to the terms of the Mozilla Public
|
||||
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
||||
* file, you can obtain one at https://mozilla.org/MPL/2.0/.
|
||||
* file, You can obtain one at http://mozilla.org/MPL/2.0/.
|
||||
*
|
||||
* See the COPYRIGHT file distributed with this work for additional
|
||||
* information regarding copyright ownership.
|
||||
|
||||
+1
-1
@@ -3,7 +3,7 @@
|
||||
*
|
||||
* This Source Code Form is subject to the terms of the Mozilla Public
|
||||
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
||||
* file, you can obtain one at https://mozilla.org/MPL/2.0/.
|
||||
* file, You can obtain one at http://mozilla.org/MPL/2.0/.
|
||||
*
|
||||
* See the COPYRIGHT file distributed with this work for additional
|
||||
* information regarding copyright ownership.
|
||||
|
||||
@@ -3,7 +3,7 @@
|
||||
*
|
||||
* This Source Code Form is subject to the terms of the Mozilla Public
|
||||
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
||||
* file, you can obtain one at https://mozilla.org/MPL/2.0/.
|
||||
* file, You can obtain one at http://mozilla.org/MPL/2.0/.
|
||||
*
|
||||
* See the COPYRIGHT file distributed with this work for additional
|
||||
* information regarding copyright ownership.
|
||||
|
||||
@@ -77,7 +77,7 @@
|
||||
<GenerateDebugInformation>true</GenerateDebugInformation>
|
||||
<OutputFile>..\..\..\Build\$(Configuration)\$(TargetName)$(TargetExt)</OutputFile>
|
||||
<AdditionalLibraryDirectories>$(Configuration);..\..\..\lib\isc\win32\$(Configuration);..\..\..\lib\dns\win32\$(Configuration);%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>
|
||||
<AdditionalDependencies>@OPENSSL_LIBCRYPTO@@OPENSSL_LIBSSL@confgentool.lib;libisc.lib;libdns.lib;ws2_32.lib;%(AdditionalDependencies)</AdditionalDependencies>
|
||||
<AdditionalDependencies>@OPENSSL_LIB@confgentool.lib;libisc.lib;libdns.lib;ws2_32.lib;%(AdditionalDependencies)</AdditionalDependencies>
|
||||
</Link>
|
||||
</ItemDefinitionGroup>
|
||||
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|@PLATFORM@'">
|
||||
@@ -109,7 +109,7 @@
|
||||
<OutputFile>..\..\..\Build\$(Configuration)\$(TargetName)$(TargetExt)</OutputFile>
|
||||
<LinkTimeCodeGeneration>Default</LinkTimeCodeGeneration>
|
||||
<AdditionalLibraryDirectories>$(Configuration);..\..\..\lib\isc\win32\$(Configuration);..\..\..\lib\dns\win32\$(Configuration);%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>
|
||||
<AdditionalDependencies>@OPENSSL_LIBCRYPTO@@OPENSSL_LIBSSL@confgentool.lib;libisc.lib;libdns.lib;ws2_32.lib;%(AdditionalDependencies)</AdditionalDependencies>
|
||||
<AdditionalDependencies>@OPENSSL_LIB@confgentool.lib;libisc.lib;libdns.lib;ws2_32.lib;%(AdditionalDependencies)</AdditionalDependencies>
|
||||
</Link>
|
||||
</ItemDefinitionGroup>
|
||||
<ItemGroup>
|
||||
|
||||
@@ -77,7 +77,7 @@
|
||||
<GenerateDebugInformation>true</GenerateDebugInformation>
|
||||
<OutputFile>..\..\..\Build\$(Configuration)\$(TargetName)$(TargetExt)</OutputFile>
|
||||
<AdditionalLibraryDirectories>$(Configuration);..\..\..\lib\isc\win32\$(Configuration);..\..\..\lib\dns\win32\$(Configuration);%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>
|
||||
<AdditionalDependencies>@OPENSSL_LIBCRYPTO@@OPENSSL_LIBSSL@confgentool.lib;libisc.lib;libdns.lib;ws2_32.lib;%(AdditionalDependencies)</AdditionalDependencies>
|
||||
<AdditionalDependencies>@OPENSSL_LIB@confgentool.lib;libisc.lib;libdns.lib;ws2_32.lib;%(AdditionalDependencies)</AdditionalDependencies>
|
||||
</Link>
|
||||
<PostBuildEvent>
|
||||
<Command>cd ..\..\..\Build\$(Configuration)
|
||||
@@ -115,7 +115,7 @@ copy /Y tsig-keygen.ilk ddns-confgen.ilk
|
||||
<OutputFile>..\..\..\Build\$(Configuration)\$(TargetName)$(TargetExt)</OutputFile>
|
||||
<LinkTimeCodeGeneration>Default</LinkTimeCodeGeneration>
|
||||
<AdditionalLibraryDirectories>$(Configuration);..\..\..\lib\isc\win32\$(Configuration);..\..\..\lib\dns\win32\$(Configuration);%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>
|
||||
<AdditionalDependencies>@OPENSSL_LIBCRYPTO@@OPENSSL_LIBSSL@confgentool.lib;libisc.lib;libdns.lib;ws2_32.lib;%(AdditionalDependencies)</AdditionalDependencies>
|
||||
<AdditionalDependencies>@OPENSSL_LIB@confgentool.lib;libisc.lib;libdns.lib;ws2_32.lib;%(AdditionalDependencies)</AdditionalDependencies>
|
||||
</Link>
|
||||
<PostBuildEvent>
|
||||
<Command>cd ..\..\..\Build\$(Configuration)
|
||||
|
||||
+21
-17
@@ -3,7 +3,7 @@
|
||||
*
|
||||
* This Source Code Form is subject to the terms of the Mozilla Public
|
||||
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
||||
* file, you can obtain one at https://mozilla.org/MPL/2.0/.
|
||||
* file, You can obtain one at http://mozilla.org/MPL/2.0/.
|
||||
*
|
||||
* See the COPYRIGHT file distributed with this work for additional
|
||||
* information regarding copyright ownership.
|
||||
@@ -34,10 +34,8 @@
|
||||
#include <isc/hex.h>
|
||||
#include <isc/lib.h>
|
||||
#include <isc/log.h>
|
||||
#include <isc/managers.h>
|
||||
#include <isc/md.h>
|
||||
#include <isc/mem.h>
|
||||
#include <isc/netmgr.h>
|
||||
#ifdef WIN32
|
||||
#include <isc/ntpaths.h>
|
||||
#endif /* ifdef WIN32 */
|
||||
@@ -612,13 +610,11 @@ key_fromconfig(const cfg_obj_t *key, dns_client_t *client) {
|
||||
dns_name_t *keyname;
|
||||
isc_result_t result;
|
||||
bool match_root = false;
|
||||
enum {
|
||||
INITIAL_KEY,
|
||||
STATIC_KEY,
|
||||
INITIAL_DS,
|
||||
STATIC_DS,
|
||||
TRUSTED
|
||||
} anchortype;
|
||||
enum { INITIAL_KEY,
|
||||
STATIC_KEY,
|
||||
INITIAL_DS,
|
||||
STATIC_DS,
|
||||
TRUSTED } anchortype;
|
||||
const cfg_obj_t *obj;
|
||||
|
||||
keynamestr = cfg_obj_asstring(cfg_tuple_get(key, "name"));
|
||||
@@ -1738,7 +1734,6 @@ main(int argc, char *argv[]) {
|
||||
dns_namelist_t namelist;
|
||||
unsigned int resopt;
|
||||
isc_appctx_t *actx = NULL;
|
||||
isc_nm_t *netmgr = NULL;
|
||||
isc_taskmgr_t *taskmgr = NULL;
|
||||
isc_socketmgr_t *socketmgr = NULL;
|
||||
isc_timermgr_t *timermgr = NULL;
|
||||
@@ -1762,8 +1757,9 @@ main(int argc, char *argv[]) {
|
||||
isc_mem_create(&mctx);
|
||||
|
||||
CHECK(isc_appctx_create(mctx, &actx));
|
||||
isc_managers_create(mctx, 1, 0, 0, &netmgr, &taskmgr, &timermgr,
|
||||
&socketmgr);
|
||||
CHECK(isc_taskmgr_createinctx(mctx, 1, 0, &taskmgr));
|
||||
CHECK(isc_socketmgr_createinctx(mctx, &socketmgr));
|
||||
CHECK(isc_timermgr_createinctx(mctx, &timermgr));
|
||||
|
||||
parse_args(argc, argv);
|
||||
|
||||
@@ -1783,8 +1779,8 @@ main(int argc, char *argv[]) {
|
||||
#endif /* ifndef WIN32 */
|
||||
|
||||
/* Create client */
|
||||
result = dns_client_create(mctx, actx, taskmgr, socketmgr, timermgr, 0,
|
||||
&client, srcaddr4, srcaddr6);
|
||||
result = dns_client_createx(mctx, actx, taskmgr, socketmgr, timermgr, 0,
|
||||
&client, srcaddr4, srcaddr6);
|
||||
if (result != ISC_R_SUCCESS) {
|
||||
delv_log(ISC_LOG_ERROR, "dns_client_create: %s",
|
||||
isc_result_totext(result));
|
||||
@@ -1804,7 +1800,7 @@ main(int argc, char *argv[]) {
|
||||
CHECK(convert_name(&qfn, &query_name, qname));
|
||||
|
||||
/* Set up resolution options */
|
||||
resopt = DNS_CLIENTRESOPT_NOCDFLAG;
|
||||
resopt = DNS_CLIENTRESOPT_ALLOWRUN | DNS_CLIENTRESOPT_NOCDFLAG;
|
||||
if (no_sigs) {
|
||||
resopt |= DNS_CLIENTRESOPT_NODNSSEC;
|
||||
}
|
||||
@@ -1866,7 +1862,15 @@ cleanup:
|
||||
if (client != NULL) {
|
||||
dns_client_destroy(&client);
|
||||
}
|
||||
isc_managers_destroy(&netmgr, &taskmgr, &timermgr, &socketmgr);
|
||||
if (taskmgr != NULL) {
|
||||
isc_taskmgr_destroy(&taskmgr);
|
||||
}
|
||||
if (timermgr != NULL) {
|
||||
isc_timermgr_destroy(&timermgr);
|
||||
}
|
||||
if (socketmgr != NULL) {
|
||||
isc_socketmgr_destroy(&socketmgr);
|
||||
}
|
||||
if (actx != NULL) {
|
||||
isc_appctx_destroy(&actx);
|
||||
}
|
||||
|
||||
+1
-1
@@ -3,7 +3,7 @@
|
||||
|
||||
This Source Code Form is subject to the terms of the Mozilla Public
|
||||
License, v. 2.0. If a copy of the MPL was not distributed with this
|
||||
file, you can obtain one at https://mozilla.org/MPL/2.0/.
|
||||
file, You can obtain one at http://mozilla.org/MPL/2.0/.
|
||||
|
||||
See the COPYRIGHT file distributed with this work for additional
|
||||
information regarding copyright ownership.
|
||||
|
||||
@@ -75,7 +75,7 @@
|
||||
<GenerateDebugInformation>true</GenerateDebugInformation>
|
||||
<OutputFile>..\..\..\Build\$(Configuration)\$(TargetName)$(TargetExt)</OutputFile>
|
||||
<AdditionalLibraryDirectories>..\..\..\lib\isc\win32\$(Configuration);..\..\..\lib\dns\win32\$(Configuration);..\..\..\lib\isccfg\win32\$(Configuration);..\..\..\lib\irs\win32\$(Configuration);%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>
|
||||
<AdditionalDependencies>@OPENSSL_LIBCRYPTO@@OPENSSL_LIBSSL@libisc.lib;libdns.lib;libisccfg.lib;libirs.lib;ws2_32.lib;%(AdditionalDependencies)</AdditionalDependencies>
|
||||
<AdditionalDependencies>@OPENSSL_LIB@libisc.lib;libdns.lib;libisccfg.lib;libirs.lib;ws2_32.lib;%(AdditionalDependencies)</AdditionalDependencies>
|
||||
</Link>
|
||||
</ItemDefinitionGroup>
|
||||
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|@PLATFORM@'">
|
||||
@@ -107,7 +107,7 @@
|
||||
<OutputFile>..\..\..\Build\$(Configuration)\$(TargetName)$(TargetExt)</OutputFile>
|
||||
<LinkTimeCodeGeneration>Default</LinkTimeCodeGeneration>
|
||||
<AdditionalLibraryDirectories>..\..\..\lib\isc\win32\$(Configuration);..\..\..\lib\dns\win32\$(Configuration);..\..\..\lib\isccfg\win32\$(Configuration);..\..\..\lib\irs\win32\$(Configuration);%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>
|
||||
<AdditionalDependencies>@OPENSSL_LIBCRYPTO@@OPENSSL_LIBSSL@libisc.lib;libdns.lib;libisccfg.lib;libirs.lib;ws2_32.lib;%(AdditionalDependencies)</AdditionalDependencies>
|
||||
<AdditionalDependencies>@OPENSSL_LIB@libisc.lib;libdns.lib;libisccfg.lib;libirs.lib;ws2_32.lib;%(AdditionalDependencies)</AdditionalDependencies>
|
||||
</Link>
|
||||
</ItemDefinitionGroup>
|
||||
<ItemGroup>
|
||||
|
||||
+3
-12
@@ -25,15 +25,6 @@ libdighost_la_SOURCES = \
|
||||
|
||||
bin_PROGRAMS = dig host nslookup
|
||||
|
||||
nslookup_CPPFLAGS = \
|
||||
$(AM_CPPFLAGS)
|
||||
|
||||
nslookup_LDADD = \
|
||||
$(LDADD)
|
||||
|
||||
if HAVE_READLINE
|
||||
nslookup_CPPFLAGS += \
|
||||
$(READLINE_CFLAGS)
|
||||
nslookup_LDADD += \
|
||||
$(READLINE_LIBS)
|
||||
endif HAVE_READLINE
|
||||
nslookup_LDADD = \
|
||||
$(LDADD) \
|
||||
$(READLINE_LIB)
|
||||
|
||||
+52
-279
@@ -3,7 +3,7 @@
|
||||
*
|
||||
* This Source Code Form is subject to the terms of the Mozilla Public
|
||||
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
||||
* file, you can obtain one at https://mozilla.org/MPL/2.0/.
|
||||
* file, You can obtain one at http://mozilla.org/MPL/2.0/.
|
||||
*
|
||||
* See the COPYRIGHT file distributed with this work for additional
|
||||
* information regarding copyright ownership.
|
||||
@@ -30,7 +30,6 @@
|
||||
#include <pk11/site.h>
|
||||
|
||||
#include <dns/byaddr.h>
|
||||
#include <dns/dns64.h>
|
||||
#include <dns/fixedname.h>
|
||||
#include <dns/masterdump.h>
|
||||
#include <dns/message.h>
|
||||
@@ -186,7 +185,7 @@ help(void) {
|
||||
" +[no]besteffort (Try to parse even "
|
||||
"illegal "
|
||||
"messages)\n"
|
||||
" +bufsize[=###] (Set EDNS0 Max UDP packet "
|
||||
" +bufsize=### (Set EDNS0 Max UDP packet "
|
||||
"size)\n"
|
||||
" +[no]cdflag (Set checking disabled "
|
||||
"flag in query)\n"
|
||||
@@ -207,8 +206,6 @@ help(void) {
|
||||
" fields in records)\n"
|
||||
" +[no]defname (Use search list "
|
||||
"(+[no]search))\n"
|
||||
" +[no]dns64prefix (Get the DNS64 prefixes "
|
||||
"from ipv4only.arpa)\n"
|
||||
" +[no]dnssec (Request DNSSEC records)\n"
|
||||
" +domain=### (Set default domainname)\n"
|
||||
" +[no]dscp[=###] (Set the DSCP value to "
|
||||
@@ -228,10 +225,6 @@ help(void) {
|
||||
"SERVFAIL)\n"
|
||||
" +[no]header-only (Send query without a "
|
||||
"question section)\n"
|
||||
" +[no]https[=###] (DNS over HTTPS mode) "
|
||||
"[/]\n"
|
||||
" +[no]https-get (Use GET instead of "
|
||||
"default POST method\n"
|
||||
" +[no]identify (ID responders in short "
|
||||
"answers)\n"
|
||||
#ifdef HAVE_LIBIDN2
|
||||
@@ -294,7 +287,6 @@ help(void) {
|
||||
"(+[no]tcflag))\n"
|
||||
" +[no]tcp (TCP mode (+[no]vc))\n"
|
||||
" +timeout=### (Set query timeout) [5]\n"
|
||||
" +[no]tls (DNS over TLS mode)\n"
|
||||
" +[no]trace (Trace delegation down "
|
||||
"from root "
|
||||
"[+dnssec])\n"
|
||||
@@ -304,6 +296,9 @@ help(void) {
|
||||
"in records)\n"
|
||||
" +[no]ttlunits (Display TTLs in "
|
||||
"human-readable units)\n"
|
||||
" +[no]unexpected (Print replies from "
|
||||
"unexpected sources\n"
|
||||
" default=off)\n"
|
||||
" +[no]unknownformat (Print RDATA in RFC 3597 "
|
||||
"\"unknown\" "
|
||||
"format)\n"
|
||||
@@ -343,28 +338,13 @@ received(unsigned int bytes, isc_sockaddr_t *from, dig_query_t *query) {
|
||||
}
|
||||
|
||||
if (query->lookup->stats) {
|
||||
const char *proto;
|
||||
diff = isc_time_microdiff(&query->time_recv, &query->time_sent);
|
||||
if (query->lookup->use_usec) {
|
||||
printf(";; Query time: %ld usec\n", (long)diff);
|
||||
} else {
|
||||
printf(";; Query time: %ld msec\n", (long)diff / 1000);
|
||||
}
|
||||
if (query->lookup->tls_mode) {
|
||||
proto = "TLS";
|
||||
} else if (query->lookup->https_mode) {
|
||||
if (query->lookup->http_plain) {
|
||||
proto = "HTTP";
|
||||
} else {
|
||||
proto = "HTTPS";
|
||||
}
|
||||
} else if (query->lookup->tcp_mode) {
|
||||
proto = "TCP";
|
||||
} else {
|
||||
proto = "UDP";
|
||||
}
|
||||
printf(";; SERVER: %s(%s) (%s)\n", fromtext, query->userarg,
|
||||
proto);
|
||||
printf(";; SERVER: %s(%s)\n", fromtext, query->servname);
|
||||
time(&tnow);
|
||||
(void)localtime_r(&tnow, &tmnow);
|
||||
|
||||
@@ -486,50 +466,6 @@ say_message(dns_rdata_t *rdata, dig_query_t *query, isc_buffer_t *buf) {
|
||||
return (ISC_R_SUCCESS);
|
||||
}
|
||||
|
||||
/*%
|
||||
* short_form message print handler. Calls above say_message()
|
||||
*/
|
||||
static isc_result_t
|
||||
dns64prefix_answer(dns_message_t *msg, isc_buffer_t *buf) {
|
||||
dns_rdataset_t *rdataset = NULL;
|
||||
dns_fixedname_t fixed;
|
||||
dns_name_t *name;
|
||||
isc_result_t result;
|
||||
isc_netprefix_t prefix[10];
|
||||
size_t i, count = 10;
|
||||
|
||||
name = dns_fixedname_initname(&fixed);
|
||||
result = dns_name_fromstring(name, "ipv4only.arpa", 0, NULL);
|
||||
check_result(result, "dns_name_fromstring");
|
||||
|
||||
result = dns_message_findname(msg, DNS_SECTION_ANSWER, name,
|
||||
dns_rdatatype_aaaa, dns_rdatatype_none,
|
||||
NULL, &rdataset);
|
||||
if (result == DNS_R_NXDOMAIN || result == DNS_R_NXRRSET) {
|
||||
return (ISC_R_SUCCESS);
|
||||
} else if (result != ISC_R_SUCCESS) {
|
||||
return (result);
|
||||
}
|
||||
|
||||
result = dns_dns64_findprefix(rdataset, prefix, &count);
|
||||
if (result == ISC_R_NOTFOUND)
|
||||
return (ISC_R_SUCCESS);
|
||||
if (count > 10)
|
||||
count = 10;
|
||||
for (i = 0; i < count; i++) {
|
||||
result = isc_netaddr_totext(&prefix[i].addr, buf);
|
||||
if (result != ISC_R_SUCCESS) {
|
||||
return (result);
|
||||
}
|
||||
result = isc_buffer_printf(buf, "/%u\n", prefix[i].prefixlen);
|
||||
if (result != ISC_R_SUCCESS) {
|
||||
return (result);
|
||||
}
|
||||
}
|
||||
|
||||
return (ISC_R_SUCCESS);
|
||||
}
|
||||
|
||||
/*%
|
||||
* short_form message print handler. Calls above say_message()
|
||||
*/
|
||||
@@ -616,12 +552,9 @@ printmessage(dig_query_t *query, const isc_buffer_t *msgbuf, dns_message_t *msg,
|
||||
dns_master_style_t *style = NULL;
|
||||
unsigned int styleflags = 0;
|
||||
bool isquery = (msg == query->lookup->sendmsg);
|
||||
bool dns64prefix = query->lookup->dns64prefix;
|
||||
|
||||
UNUSED(msgbuf);
|
||||
|
||||
dig_idnsetup(query->lookup, true);
|
||||
|
||||
styleflags |= DNS_STYLEFLAG_REL_OWNER;
|
||||
if (yaml) {
|
||||
msg->indent.string = " ";
|
||||
@@ -681,16 +614,14 @@ printmessage(dig_query_t *query, const isc_buffer_t *msgbuf, dns_message_t *msg,
|
||||
check_result(result, "dns_master_stylecreate");
|
||||
|
||||
if (query->lookup->cmdline[0] != 0) {
|
||||
if (!short_form && !dns64prefix && printcmd) {
|
||||
if (!short_form && printcmd) {
|
||||
printf("%s", query->lookup->cmdline);
|
||||
}
|
||||
query->lookup->cmdline[0] = '\0';
|
||||
}
|
||||
debug("printmessage(%s %s %s)", headers ? "headers" : "noheaders",
|
||||
query->lookup->comments ? "comments" : "nocomments",
|
||||
short_form ? "short_form"
|
||||
: dns64prefix ? "dns64prefix_form"
|
||||
: "long_form");
|
||||
short_form ? "short_form" : "long_form");
|
||||
|
||||
flags = 0;
|
||||
if (!headers) {
|
||||
@@ -711,6 +642,7 @@ printmessage(dig_query_t *query, const isc_buffer_t *msgbuf, dns_message_t *msg,
|
||||
if (yaml) {
|
||||
enum { Q = 0x1, R = 0x2 }; /* Q:query; R:ecursive */
|
||||
unsigned int tflag = 0;
|
||||
isc_sockaddr_t saddr;
|
||||
char sockstr[ISC_SOCKADDR_FORMATSIZE];
|
||||
uint16_t sport;
|
||||
char *hash;
|
||||
@@ -743,25 +675,15 @@ printmessage(dig_query_t *query, const isc_buffer_t *msgbuf, dns_message_t *msg,
|
||||
|
||||
if (!isc_time_isepoch(&query->time_sent)) {
|
||||
char tbuf[100];
|
||||
if (query->lookup->use_usec) {
|
||||
isc_time_formatISO8601us(&query->time_sent,
|
||||
tbuf, sizeof(tbuf));
|
||||
} else {
|
||||
isc_time_formatISO8601ms(&query->time_sent,
|
||||
tbuf, sizeof(tbuf));
|
||||
}
|
||||
isc_time_formatISO8601ms(&query->time_sent, tbuf,
|
||||
sizeof(tbuf));
|
||||
printf(" query_time: !!timestamp %s\n", tbuf);
|
||||
}
|
||||
|
||||
if (!isquery && !isc_time_isepoch(&query->time_recv)) {
|
||||
char tbuf[100];
|
||||
if (query->lookup->use_usec) {
|
||||
isc_time_formatISO8601us(&query->time_recv,
|
||||
tbuf, sizeof(tbuf));
|
||||
} else {
|
||||
isc_time_formatISO8601ms(&query->time_recv,
|
||||
tbuf, sizeof(tbuf));
|
||||
}
|
||||
isc_time_formatISO8601ms(&query->time_recv, tbuf,
|
||||
sizeof(tbuf));
|
||||
printf(" response_time: !!timestamp %s\n", tbuf);
|
||||
}
|
||||
|
||||
@@ -791,9 +713,10 @@ printmessage(dig_query_t *query, const isc_buffer_t *msgbuf, dns_message_t *msg,
|
||||
printf(" response_port: %u\n", sport);
|
||||
}
|
||||
|
||||
if (query->handle != NULL) {
|
||||
isc_sockaddr_t saddr =
|
||||
isc_nmhandle_localaddr(query->handle);
|
||||
if (query->sock != NULL &&
|
||||
isc_socket_getsockname(query->sock, &saddr) ==
|
||||
ISC_R_SUCCESS)
|
||||
{
|
||||
sport = isc_sockaddr_getport(&saddr);
|
||||
isc_sockaddr_format(&saddr, sockstr, sizeof(sockstr));
|
||||
hash = strchr(sockstr, '#');
|
||||
@@ -811,7 +734,7 @@ printmessage(dig_query_t *query, const isc_buffer_t *msgbuf, dns_message_t *msg,
|
||||
printf(" %s:\n", isquery ? "query_message_data"
|
||||
: "response_message_data");
|
||||
result = dns_message_headertotext(msg, style, flags, buf);
|
||||
} else if (query->lookup->comments && !short_form && !dns64prefix) {
|
||||
} else if (query->lookup->comments && !short_form) {
|
||||
if (query->lookup->cmdline[0] != '\0' && printcmd) {
|
||||
printf("; %s\n", query->lookup->cmdline);
|
||||
}
|
||||
@@ -892,7 +815,7 @@ printmessage(dig_query_t *query, const isc_buffer_t *msgbuf, dns_message_t *msg,
|
||||
|
||||
repopulate_buffer:
|
||||
|
||||
if (query->lookup->comments && headers && !short_form && !dns64prefix) {
|
||||
if (query->lookup->comments && headers && !short_form) {
|
||||
result = dns_message_pseudosectiontotext(
|
||||
msg, DNS_PSEUDOSECTION_OPT, style, flags, buf);
|
||||
if (result == ISC_R_NOSPACE) {
|
||||
@@ -906,7 +829,7 @@ repopulate_buffer:
|
||||
}
|
||||
|
||||
if (query->lookup->section_question && headers) {
|
||||
if (!short_form && !dns64prefix) {
|
||||
if (!short_form) {
|
||||
result = dns_message_sectiontotext(
|
||||
msg, DNS_SECTION_QUESTION, style, flags, buf);
|
||||
if (result == ISC_R_NOSPACE) {
|
||||
@@ -916,18 +839,13 @@ repopulate_buffer:
|
||||
}
|
||||
}
|
||||
if (query->lookup->section_answer) {
|
||||
if (!short_form && !dns64prefix) {
|
||||
if (!short_form) {
|
||||
result = dns_message_sectiontotext(
|
||||
msg, DNS_SECTION_ANSWER, style, flags, buf);
|
||||
if (result == ISC_R_NOSPACE) {
|
||||
goto buftoosmall;
|
||||
}
|
||||
check_result(result, "dns_message_sectiontotext");
|
||||
} else if (dns64prefix) {
|
||||
result = dns64prefix_answer(msg, buf);
|
||||
if (result == ISC_R_NOSPACE)
|
||||
goto buftoosmall;
|
||||
check_result(result, "dns64prefix_answer");
|
||||
} else {
|
||||
result = short_answer(msg, flags, buf, query);
|
||||
if (result == ISC_R_NOSPACE) {
|
||||
@@ -937,7 +855,7 @@ repopulate_buffer:
|
||||
}
|
||||
}
|
||||
if (query->lookup->section_authority) {
|
||||
if (!short_form && !dns64prefix) {
|
||||
if (!short_form) {
|
||||
result = dns_message_sectiontotext(
|
||||
msg, DNS_SECTION_AUTHORITY, style, flags, buf);
|
||||
if (result == ISC_R_NOSPACE) {
|
||||
@@ -947,7 +865,7 @@ repopulate_buffer:
|
||||
}
|
||||
}
|
||||
if (query->lookup->section_additional) {
|
||||
if (!short_form && !dns64prefix) {
|
||||
if (!short_form) {
|
||||
result = dns_message_sectiontotext(
|
||||
msg, DNS_SECTION_ADDITIONAL, style, flags, buf);
|
||||
if (result == ISC_R_NOSPACE) {
|
||||
@@ -989,9 +907,6 @@ repopulate_buffer:
|
||||
if (style != NULL) {
|
||||
dns_master_styledestroy(&style, mctx);
|
||||
}
|
||||
|
||||
dig_idnsetup(query->lookup, false);
|
||||
|
||||
return (result);
|
||||
}
|
||||
|
||||
@@ -1041,9 +956,8 @@ printgreeting(int argc, char **argv, dig_lookup_t *lookup) {
|
||||
* XXX doc options
|
||||
*/
|
||||
|
||||
static dig_lookup_t *
|
||||
plus_option(char *option, bool is_batchfile, bool *need_clone,
|
||||
dig_lookup_t *lookup) {
|
||||
static void
|
||||
plus_option(char *option, bool is_batchfile, dig_lookup_t *lookup) {
|
||||
isc_result_t result;
|
||||
char *cmd, *value, *last = NULL, *code, *extra;
|
||||
uint32_t num;
|
||||
@@ -1054,7 +968,7 @@ plus_option(char *option, bool is_batchfile, bool *need_clone,
|
||||
|
||||
if ((cmd = strtok_r(option, "=", &last)) == NULL) {
|
||||
printf(";; Invalid option %s\n", option);
|
||||
return (lookup);
|
||||
return;
|
||||
}
|
||||
if (strncasecmp(cmd, "no", 2) == 0) {
|
||||
cmd += 2;
|
||||
@@ -1076,17 +990,6 @@ plus_option(char *option, bool is_batchfile, bool *need_clone,
|
||||
(_l >= sizeof(B) || strncasecmp(cmd, B, _l) != 0)) \
|
||||
goto invalid_option; \
|
||||
} while (0)
|
||||
#define FULLCHECK6(A, B, C, D, E, F) \
|
||||
do { \
|
||||
size_t _l = strlen(cmd); \
|
||||
if ((_l >= sizeof(A) || strncasecmp(cmd, A, _l) != 0) && \
|
||||
(_l >= sizeof(B) || strncasecmp(cmd, B, _l) != 0) && \
|
||||
(_l >= sizeof(C) || strncasecmp(cmd, C, _l) != 0) && \
|
||||
(_l >= sizeof(D) || strncasecmp(cmd, D, _l) != 0) && \
|
||||
(_l >= sizeof(E) || strncasecmp(cmd, E, _l) != 0) && \
|
||||
(_l >= sizeof(F) || strncasecmp(cmd, F, _l) != 0)) \
|
||||
goto invalid_option; \
|
||||
} while (0)
|
||||
|
||||
switch (cmd[0]) {
|
||||
case 'a':
|
||||
@@ -1144,13 +1047,12 @@ plus_option(char *option, bool is_batchfile, bool *need_clone,
|
||||
break;
|
||||
case 'u': /* bufsize */
|
||||
FULLCHECK("bufsize");
|
||||
if (value == NULL) {
|
||||
goto need_value;
|
||||
}
|
||||
if (!state) {
|
||||
goto invalid_option;
|
||||
}
|
||||
if (value == NULL) {
|
||||
lookup->udpsize = DEFAULT_EDNS_BUFSIZE;
|
||||
break;
|
||||
}
|
||||
result = parse_uint(&num, value, COMMSIZE,
|
||||
"buffer size");
|
||||
if (result != ISC_R_SUCCESS) {
|
||||
@@ -1197,7 +1099,7 @@ plus_option(char *option, bool is_batchfile, bool *need_clone,
|
||||
case 'o': /* cookie */
|
||||
FULLCHECK("cookie");
|
||||
if (state && lookup->edns == -1) {
|
||||
lookup->edns = DEFAULT_EDNS_VERSION;
|
||||
lookup->edns = 0;
|
||||
}
|
||||
lookup->sendcookie = state;
|
||||
if (value != NULL) {
|
||||
@@ -1232,57 +1134,13 @@ plus_option(char *option, bool is_batchfile, bool *need_clone,
|
||||
usesearch = state;
|
||||
}
|
||||
break;
|
||||
case 'n':
|
||||
switch (cmd[2]) {
|
||||
case 's':
|
||||
switch (cmd[3]) {
|
||||
case '6': /* dns64prefix */
|
||||
FULLCHECK("dns64prefix");
|
||||
if (state) {
|
||||
if (*need_clone) {
|
||||
lookup = clone_lookup(
|
||||
default_lookup,
|
||||
true);
|
||||
}
|
||||
*need_clone = true;
|
||||
lookup->dns64prefix = state;
|
||||
strlcpy(lookup->textname,
|
||||
"ipv4only.arpa",
|
||||
sizeof(lookup->textname));
|
||||
printcmd = false;
|
||||
lookup->section_additional =
|
||||
false;
|
||||
lookup->section_answer = true;
|
||||
lookup->section_authority =
|
||||
false;
|
||||
lookup->section_question =
|
||||
false;
|
||||
lookup->comments = false;
|
||||
lookup->stats = false;
|
||||
lookup->rrcomments = -1;
|
||||
lookup->rdtype =
|
||||
dns_rdatatype_aaaa;
|
||||
lookup->rdtypeset = true;
|
||||
ISC_LIST_APPEND(lookup_list,
|
||||
lookup, link);
|
||||
}
|
||||
break;
|
||||
case 's': /* dnssec */
|
||||
FULLCHECK("dnssec");
|
||||
dnssec:
|
||||
if (state && lookup->edns == -1) {
|
||||
lookup->edns =
|
||||
DEFAULT_EDNS_VERSION;
|
||||
}
|
||||
lookup->dnssec = state;
|
||||
break;
|
||||
default:
|
||||
goto invalid_option;
|
||||
}
|
||||
break;
|
||||
default:
|
||||
goto invalid_option;
|
||||
case 'n': /* dnssec */
|
||||
FULLCHECK("dnssec");
|
||||
dnssec:
|
||||
if (state && lookup->edns == -1) {
|
||||
lookup->edns = 0;
|
||||
}
|
||||
lookup->dnssec = state;
|
||||
break;
|
||||
case 'o': /* domain ... but treat "do" as synonym for dnssec */
|
||||
if (cmd[2] == '\0') {
|
||||
@@ -1332,8 +1190,7 @@ plus_option(char *option, bool is_batchfile, bool *need_clone,
|
||||
break;
|
||||
}
|
||||
if (value == NULL) {
|
||||
lookup->edns =
|
||||
DEFAULT_EDNS_VERSION;
|
||||
lookup->edns = 0;
|
||||
break;
|
||||
}
|
||||
result = parse_uint(&num, value,
|
||||
@@ -1433,78 +1290,8 @@ plus_option(char *option, bool is_batchfile, bool *need_clone,
|
||||
lookup->servfail_stops = state;
|
||||
break;
|
||||
case 'h':
|
||||
switch (cmd[1]) {
|
||||
case 'e': /* header-only */
|
||||
FULLCHECK("header-only");
|
||||
lookup->header_only = state;
|
||||
break;
|
||||
case 't':
|
||||
FULLCHECK6("https", "https-get", "https-post",
|
||||
"http-plain", "http-plain-get",
|
||||
"http-plain-post");
|
||||
if (lookup->https_path != NULL) {
|
||||
isc_mem_free(mctx, lookup->https_path);
|
||||
lookup->https_path = NULL;
|
||||
}
|
||||
if (!state) {
|
||||
lookup->https_mode = false;
|
||||
break;
|
||||
}
|
||||
lookup->https_mode = true;
|
||||
if (cmd[4] == '-') {
|
||||
lookup->http_plain = true;
|
||||
switch (cmd[10]) {
|
||||
case '\0':
|
||||
FULLCHECK("http-plain");
|
||||
break;
|
||||
case '-':
|
||||
switch (cmd[6]) {
|
||||
case 'p':
|
||||
FULLCHECK("https-plain-post");
|
||||
break;
|
||||
case 'g':
|
||||
FULLCHECK("https-plain-get");
|
||||
lookup->https_get = true;
|
||||
break;
|
||||
}
|
||||
break;
|
||||
default:
|
||||
goto invalid_option;
|
||||
}
|
||||
} else {
|
||||
switch (cmd[5]) {
|
||||
case '\0':
|
||||
FULLCHECK("https");
|
||||
break;
|
||||
case '-':
|
||||
switch (cmd[6]) {
|
||||
case 'p':
|
||||
FULLCHECK("https-post");
|
||||
break;
|
||||
case 'g':
|
||||
FULLCHECK("https-get");
|
||||
lookup->https_get = true;
|
||||
break;
|
||||
}
|
||||
break;
|
||||
default:
|
||||
goto invalid_option;
|
||||
}
|
||||
}
|
||||
if (!lookup->tcp_mode_set) {
|
||||
lookup->tcp_mode = state;
|
||||
}
|
||||
if (value == NULL) {
|
||||
lookup->https_path = isc_mem_strdup(
|
||||
mctx, DEFAULT_HTTPS_PATH);
|
||||
} else {
|
||||
lookup->https_path = isc_mem_strdup(mctx,
|
||||
value);
|
||||
}
|
||||
break;
|
||||
default:
|
||||
goto invalid_option;
|
||||
}
|
||||
FULLCHECK("header-only");
|
||||
lookup->header_only = state;
|
||||
break;
|
||||
case 'i':
|
||||
switch (cmd[1]) {
|
||||
@@ -1618,7 +1405,7 @@ plus_option(char *option, bool is_batchfile, bool *need_clone,
|
||||
case 'i': /* nsid */
|
||||
FULLCHECK("nsid");
|
||||
if (state && lookup->edns == -1) {
|
||||
lookup->edns = DEFAULT_EDNS_VERSION;
|
||||
lookup->edns = 0;
|
||||
}
|
||||
lookup->nsid = state;
|
||||
break;
|
||||
@@ -1688,7 +1475,7 @@ plus_option(char *option, bool is_batchfile, bool *need_clone,
|
||||
case 'p':
|
||||
FULLCHECK("padding");
|
||||
if (state && lookup->edns == -1) {
|
||||
lookup->edns = DEFAULT_EDNS_VERSION;
|
||||
lookup->edns = 0;
|
||||
}
|
||||
if (value == NULL) {
|
||||
goto need_value;
|
||||
@@ -1874,7 +1661,7 @@ plus_option(char *option, bool is_batchfile, bool *need_clone,
|
||||
break;
|
||||
}
|
||||
if (lookup->edns == -1) {
|
||||
lookup->edns = DEFAULT_EDNS_VERSION;
|
||||
lookup->edns = 0;
|
||||
}
|
||||
if (lookup->ecs_addr != NULL) {
|
||||
isc_mem_free(mctx, lookup->ecs_addr);
|
||||
@@ -1927,13 +1714,6 @@ plus_option(char *option, bool is_batchfile, bool *need_clone,
|
||||
timeout = 1;
|
||||
}
|
||||
break;
|
||||
case 'l':
|
||||
FULLCHECK("tls");
|
||||
lookup->tls_mode = state;
|
||||
if (!lookup->tcp_mode_set) {
|
||||
lookup->tcp_mode = state;
|
||||
}
|
||||
break;
|
||||
case 'o':
|
||||
FULLCHECK("topdown");
|
||||
fprintf(stderr, ";; +topdown option is deprecated");
|
||||
@@ -2017,8 +1797,7 @@ plus_option(char *option, bool is_batchfile, bool *need_clone,
|
||||
switch (cmd[2]) {
|
||||
case 'e':
|
||||
FULLCHECK("unexpected");
|
||||
fprintf(stderr, ";; +unexpected option "
|
||||
"is deprecated");
|
||||
lookup->accept_reply_unexpected_src = state;
|
||||
break;
|
||||
case 'k':
|
||||
FULLCHECK("unknownformat");
|
||||
@@ -2062,7 +1841,7 @@ plus_option(char *option, bool is_batchfile, bool *need_clone,
|
||||
fprintf(stderr, "Invalid option: +%s\n", option);
|
||||
usage();
|
||||
}
|
||||
return (lookup);
|
||||
return;
|
||||
|
||||
#if !TARGET_OS_IPHONE
|
||||
exit_or_usage:
|
||||
@@ -2188,10 +1967,10 @@ dash_option(char *option, char *next, dig_lookup_t **lookup,
|
||||
srcport = 0;
|
||||
}
|
||||
if (have_ipv6 && inet_pton(AF_INET6, value, &in6) == 1) {
|
||||
isc_sockaddr_fromin6(&localaddr, &in6, srcport);
|
||||
isc_sockaddr_fromin6(&bind_address, &in6, srcport);
|
||||
isc_net_disableipv4();
|
||||
} else if (have_ipv4 && inet_pton(AF_INET, value, &in4) == 1) {
|
||||
isc_sockaddr_fromin(&localaddr, &in4, srcport);
|
||||
isc_sockaddr_fromin(&bind_address, &in4, srcport);
|
||||
isc_net_disableipv6();
|
||||
} else {
|
||||
if (hash != NULL) {
|
||||
@@ -2235,7 +2014,6 @@ dash_option(char *option, char *next, dig_lookup_t **lookup,
|
||||
fatal("Couldn't parse port number");
|
||||
}
|
||||
port = num;
|
||||
port_set = true;
|
||||
return (value_from_next);
|
||||
case 'q':
|
||||
if (!config_only) {
|
||||
@@ -2432,20 +2210,16 @@ preparse_args(int argc, char **argv) {
|
||||
continue;
|
||||
}
|
||||
/* Look for dash value option. */
|
||||
if (strpbrk(option, dash_opts) != &option[0]) {
|
||||
goto invalid_option;
|
||||
}
|
||||
if (strlen(option) > 1U) {
|
||||
/* value in option. */
|
||||
if (strpbrk(option, dash_opts) != &option[0] ||
|
||||
strlen(option) > 1U) {
|
||||
/* Error or value in option. */
|
||||
continue;
|
||||
}
|
||||
/* Dash value is next argument so we need to skip it. */
|
||||
rc--, rv++;
|
||||
/* Handle missing argument */
|
||||
if (rc == 0) {
|
||||
invalid_option:
|
||||
fprintf(stderr, "Invalid option: -%s\n", option);
|
||||
usage();
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -2502,7 +2276,7 @@ parse_args(bool is_batchfile, bool config_only, int argc, char **argv) {
|
||||
debug("making new lookup");
|
||||
default_lookup = make_empty_lookup();
|
||||
default_lookup->adflag = true;
|
||||
default_lookup->edns = DEFAULT_EDNS_VERSION;
|
||||
default_lookup->edns = 0;
|
||||
default_lookup->sendcookie = true;
|
||||
|
||||
#ifndef NOPOSIX
|
||||
@@ -2577,8 +2351,7 @@ parse_args(bool is_batchfile, bool config_only, int argc, char **argv) {
|
||||
}
|
||||
}
|
||||
} else if (rv[0][0] == '+') {
|
||||
lookup = plus_option(&rv[0][1], is_batchfile,
|
||||
&need_clone, lookup);
|
||||
plus_option(&rv[0][1], is_batchfile, lookup);
|
||||
} else if (rv[0][0] == '-') {
|
||||
if (rc <= 1) {
|
||||
if (dash_option(&rv[0][1], NULL, &lookup,
|
||||
|
||||
+22
-51
@@ -3,7 +3,7 @@
|
||||
|
||||
This Source Code Form is subject to the terms of the Mozilla Public
|
||||
License, v. 2.0. If a copy of the MPL was not distributed with this
|
||||
file, you can obtain one at https://mozilla.org/MPL/2.0/.
|
||||
file, You can obtain one at http://mozilla.org/MPL/2.0/.
|
||||
|
||||
See the COPYRIGHT file distributed with this work for additional
|
||||
information regarding copyright ownership.
|
||||
@@ -251,10 +251,12 @@ abbreviation is unambiguous; for example, ``+cd`` is equivalent to
|
||||
This option attempts to display the contents of messages which are malformed. The
|
||||
default is to not display malformed answers.
|
||||
|
||||
``+bufsize[=B]``
|
||||
This option sets the UDP message buffer size advertised using EDNS0 to
|
||||
``B`` bytes. The maximum and minimum sizes of this buffer are 65535 and
|
||||
0, respectively. ``+bufsize`` restores the default buffer size.
|
||||
``+bufsize=B``
|
||||
This option sets the UDP message buffer size advertised using EDNS0 to ``B``
|
||||
bytes. The maximum and minimum sizes of this buffer are 65535 and 0,
|
||||
respectively. Values outside this range are rounded up or down
|
||||
appropriately. Values other than zero cause an EDNS query to be
|
||||
sent.
|
||||
|
||||
``+[no]cdflag``
|
||||
This option sets [or does not set] the CD (checking disabled) bit in the query. This
|
||||
@@ -297,9 +299,6 @@ abbreviation is unambiguous; for example, ``+cd`` is equivalent to
|
||||
``+[no]defname``
|
||||
This option, which is deprecated, is treated as a synonym for ``+[no]search``.
|
||||
|
||||
``+[no]dns64prefix``
|
||||
Lookup IPV4ONLY.ARPA AAAA and print any DNS64 prefixes found.
|
||||
|
||||
``+[no]dnssec``
|
||||
This option requests that DNSSEC records be sent by setting the DNSSEC OK (DO) bit in
|
||||
the OPT record in the additional section of the query.
|
||||
@@ -349,38 +348,11 @@ abbreviation is unambiguous; for example, ``+cd`` is equivalent to
|
||||
default is to add a question section. The query type and query name
|
||||
are ignored when this is set.
|
||||
|
||||
``+[no]https[=value]``
|
||||
This option indicates whether to use DNS-over-HTTPS (DoH) when querying
|
||||
name servers. When this option is in use, the port number defaults to 443.
|
||||
The HTTP POST request mode is used when sending the query.
|
||||
|
||||
If ``value`` is specified, it will be used as the HTTP endpoint in the
|
||||
query URI; the default is ``/dns-query``. So, for example, ``dig
|
||||
@example.com +https`` will use the URI ``https://example.com/dns-query``.
|
||||
|
||||
``+[no]https-get[=value]``
|
||||
Similar to ``+https``, except that the HTTP GET request mode is used
|
||||
when sending the query.
|
||||
|
||||
``+[no]https-post[=value]``
|
||||
Same as ``+https``.
|
||||
|
||||
``+[no]http-plain[=value]``
|
||||
Similar to ``+https``, except that HTTP queries will be sent over a
|
||||
non-encrypted channel. When this option is in use, the port number
|
||||
defaults to 80 and the HTTP request mode is POST.
|
||||
|
||||
``+[no]http-plain-get[=value]``
|
||||
Similar to ``+http-plain``, except that the HTTP request mode is GET.
|
||||
|
||||
``+[no]http-plain-post[=value]``
|
||||
Same as ``+http-plain``.
|
||||
|
||||
``+[no]identify``
|
||||
This option shows [or does not show] the IP address and port number that
|
||||
supplied the answer, when the ``+short`` option is enabled. If short
|
||||
form answers are requested, the default is not to show the source
|
||||
address and port number of the server that provided the answer.
|
||||
This option shows [or does not show] the IP address and port number that supplied
|
||||
the answer, when the ``+short`` option is enabled. If short form
|
||||
answers are requested, the default is not to show the source address
|
||||
and port number of the server that provided the answer.
|
||||
|
||||
``+[no]idnin``
|
||||
This option processes [or does not process] IDN domain names on input. This requires
|
||||
@@ -480,8 +452,8 @@ abbreviation is unambiguous; for example, ``+cd`` is equivalent to
|
||||
``+nssearch`` or ``+trace`` query option is used.
|
||||
|
||||
``+retry=T``
|
||||
This option sets the number of times to retry UDP and TCP queries to server to ``T``
|
||||
instead of the default, 2. Unlike ``+tries``, this does not include
|
||||
This option sets the number of times to retry UDP queries to server to ``T``
|
||||
instead of the default, 2. Unlike ``+tries``, this does not include
|
||||
the initial query.
|
||||
|
||||
``+[no]rrcomments``
|
||||
@@ -536,20 +508,14 @@ abbreviation is unambiguous; for example, ``+cd`` is equivalent to
|
||||
``+notcflag``. This bit is ignored by the server for QUERY.
|
||||
|
||||
``+[no]tcp``
|
||||
This option indicates whether to use TCP when querying name servers.
|
||||
The default behavior is to use UDP unless a type ``any`` or ``ixfr=N``
|
||||
query is requested, in which case the default is TCP. AXFR queries
|
||||
always use TCP.
|
||||
This option uses [or does not use] TCP when querying name servers. The default behavior
|
||||
is to use UDP unless a type ``any`` or ``ixfr=N`` query is requested,
|
||||
in which case the default is TCP. AXFR queries always use TCP.
|
||||
|
||||
``+timeout=T``
|
||||
This option sets the timeout for a query to ``T`` seconds. The default timeout is
|
||||
5 seconds. An attempt to set ``T`` to less than 1 is silently set to 1.
|
||||
|
||||
``+[no]tls``
|
||||
This option indicates whether to use DNS-over-TLS (DoT) when querying
|
||||
name servers. When this option is in use, the port number defaults
|
||||
to 853.
|
||||
|
||||
``+[no]topdown``
|
||||
This feature is related to ``dig +sigchase``, which is obsolete and
|
||||
has been removed. Use ``delv`` instead.
|
||||
@@ -569,7 +535,7 @@ abbreviation is unambiguous; for example, ``+cd`` is equivalent to
|
||||
default queries from a name server.
|
||||
|
||||
``+tries=T``
|
||||
This option sets the number of times to try UDP and TCP queries to server to ``T``
|
||||
This option sets the number of times to try UDP queries to server to ``T``
|
||||
instead of the default, 3. If ``T`` is less than or equal to zero,
|
||||
the number of tries is silently rounded up to 1.
|
||||
|
||||
@@ -585,6 +551,11 @@ abbreviation is unambiguous; for example, ``+cd`` is equivalent to
|
||||
units of ``s``, ``m``, ``h``, ``d``, and ``w``, representing seconds, minutes,
|
||||
hours, days, and weeks. This implies ``+ttlid``.
|
||||
|
||||
``+[no]unexpected``
|
||||
This option accepts [or does not accept] answers from unexpected sources. By default, ``dig``
|
||||
will not accept a reply from a source other than the one to which it sent the
|
||||
query.
|
||||
|
||||
``+[no]unknownformat``
|
||||
This option prints all RDATA in unknown RR type presentation format (:rfc:`3597`).
|
||||
The default is to print RDATA for known types in the type's
|
||||
|
||||
+1043
-923
File diff suppressed because it is too large
Load Diff
+39
-68
@@ -3,7 +3,7 @@
|
||||
*
|
||||
* This Source Code Form is subject to the terms of the Mozilla Public
|
||||
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
||||
* file, you can obtain one at https://mozilla.org/MPL/2.0/.
|
||||
* file, You can obtain one at http://mozilla.org/MPL/2.0/.
|
||||
*
|
||||
* See the COPYRIGHT file distributed with this work for additional
|
||||
* information regarding copyright ownership.
|
||||
@@ -19,14 +19,13 @@
|
||||
|
||||
#include <isc/attributes.h>
|
||||
#include <isc/buffer.h>
|
||||
#include <isc/bufferlist.h>
|
||||
#include <isc/formatcheck.h>
|
||||
#include <isc/lang.h>
|
||||
#include <isc/list.h>
|
||||
#include <isc/magic.h>
|
||||
#include <isc/mem.h>
|
||||
#include <isc/netmgr.h>
|
||||
#include <isc/print.h>
|
||||
#include <isc/refcount.h>
|
||||
#include <isc/sockaddr.h>
|
||||
#include <isc/socket.h>
|
||||
|
||||
@@ -72,13 +71,6 @@
|
||||
#define SERVER_TIMEOUT 1
|
||||
|
||||
#define LOOKUP_LIMIT 64
|
||||
|
||||
#define DEFAULT_EDNS_VERSION 0
|
||||
#define DEFAULT_EDNS_BUFSIZE 1232
|
||||
|
||||
#define DEFAULT_HTTPS_PATH "/dns-query"
|
||||
#define DEFAULT_HTTPS_QUERY "?dns="
|
||||
|
||||
/*%
|
||||
* Lookup_limit is just a limiter, keeping too many lookups from being
|
||||
* created. It's job is mainly to prevent the program from running away
|
||||
@@ -93,39 +85,37 @@ typedef struct dig_server dig_server_t;
|
||||
typedef ISC_LIST(dig_server_t) dig_serverlist_t;
|
||||
typedef struct dig_searchlist dig_searchlist_t;
|
||||
|
||||
#define DIG_LOOKUP_MAGIC ISC_MAGIC('D', 'i', 'g', 'l')
|
||||
|
||||
#define DIG_VALID_LOOKUP(x) ISC_MAGIC_VALID((x), DIG_LOOKUP_MAGIC)
|
||||
|
||||
#define DIG_QUERY_MAGIC ISC_MAGIC('D', 'i', 'g', 'q')
|
||||
|
||||
#define DIG_VALID_QUERY(x) ISC_MAGIC_VALID((x), DIG_QUERY_MAGIC)
|
||||
|
||||
/*% The dig_lookup structure */
|
||||
struct dig_lookup {
|
||||
unsigned int magic;
|
||||
isc_refcount_t references;
|
||||
bool aaonly, adflag, badcookie, besteffort, cdflag, comments,
|
||||
dns64prefix, dnssec, doing_xfr, done_as_is, ednsneg, expandaaaa,
|
||||
expire, header_only, identify, /*%< Append an "on server <foo>"
|
||||
message */
|
||||
identify_previous_line, /*% Prepend a "Nameserver <foo>:"
|
||||
message, with newline and tab */
|
||||
idnin, idnout, ignore, mapped, multiline, need_search,
|
||||
new_search, noclass, nocrypto, nottl,
|
||||
ns_search_only, /*%< dig +nssearch, host -C */
|
||||
nsid, /*% Name Server ID (RFC 5001) */
|
||||
onesoa, pending, /*%< Pending a successful answer */
|
||||
print_unknown_format, qr, raflag, recurse, section_additional,
|
||||
section_answer, section_authority, section_question,
|
||||
seenbadcookie, sendcookie, servfail_stops,
|
||||
setqid, /*% use a speciied query ID */
|
||||
stats, tcflag, tcp_keepalive, tcp_mode, tcp_mode_set,
|
||||
tls_mode, /*% connect using TLS */
|
||||
bool pending, /*%< Pending a successful answer */
|
||||
waiting_connect, doing_xfr, ns_search_only, /*%< dig
|
||||
* +nssearch,
|
||||
* host -C */
|
||||
identify, /*%< Append an "on server <foo>" message */
|
||||
identify_previous_line, /*% Prepend a "Nameserver <foo>:"
|
||||
* message, with newline and tab */
|
||||
ignore, recurse, aaonly, adflag, cdflag, raflag, tcflag, zflag,
|
||||
trace, /*% dig +trace */
|
||||
trace_root, /*% initial query for either +trace or +nssearch */
|
||||
ttlunits, use_usec, waiting_connect, zflag;
|
||||
char textname[MXNAME]; /*% Name we're going to be looking up */
|
||||
trace_root, /*% initial query for either +trace or +nssearch
|
||||
* */
|
||||
tcp_mode, tcp_mode_set, comments, stats, section_question,
|
||||
section_answer, section_authority, section_additional,
|
||||
servfail_stops, new_search, need_search, done_as_is, besteffort,
|
||||
dnssec, expire, sendcookie, seenbadcookie, badcookie,
|
||||
nsid, /*% Name Server ID (RFC 5001) */
|
||||
tcp_keepalive, header_only, ednsneg, mapped,
|
||||
print_unknown_format, multiline, nottl, noclass, onesoa,
|
||||
use_usec, nocrypto, ttlunits, idnin, idnout, expandaaaa, qr,
|
||||
accept_reply_unexpected_src, /*% print replies from
|
||||
* unexpected
|
||||
* sources. */
|
||||
setqid; /*% use a speciied query ID */
|
||||
char textname[MXNAME]; /*% Name we're going to be
|
||||
* looking up */
|
||||
char cmdline[MXNAME];
|
||||
dns_rdatatype_t rdtype;
|
||||
dns_rdatatype_t qrdtype;
|
||||
@@ -151,7 +141,7 @@ struct dig_lookup {
|
||||
dig_query_t *xfr_q;
|
||||
uint32_t retries;
|
||||
int nsfound;
|
||||
int16_t udpsize;
|
||||
uint16_t udpsize;
|
||||
int16_t edns;
|
||||
int16_t padding;
|
||||
uint32_t ixfr_serial;
|
||||
@@ -171,23 +161,15 @@ struct dig_lookup {
|
||||
int rrcomments;
|
||||
unsigned int eoferr;
|
||||
uint16_t qid;
|
||||
struct {
|
||||
bool http_plain;
|
||||
bool https_mode;
|
||||
bool https_get;
|
||||
char *https_path;
|
||||
};
|
||||
};
|
||||
|
||||
/*% The dig_query structure */
|
||||
struct dig_query {
|
||||
unsigned int magic;
|
||||
dig_lookup_t *lookup;
|
||||
bool first_pass;
|
||||
bool first_soa_rcvd;
|
||||
bool second_rr_rcvd;
|
||||
bool first_repeat_rcvd;
|
||||
bool warn_id;
|
||||
bool waiting_connect, pending_free, waiting_senddone, first_pass,
|
||||
first_soa_rcvd, second_rr_rcvd, first_repeat_rcvd, recv_made,
|
||||
warn_id, timedout;
|
||||
uint32_t first_rr_serial;
|
||||
uint32_t second_rr_serial;
|
||||
uint32_t msg_count;
|
||||
@@ -195,12 +177,9 @@ struct dig_query {
|
||||
bool ixfr_axfr;
|
||||
char *servname;
|
||||
char *userarg;
|
||||
isc_buffer_t sendbuf;
|
||||
isc_buffer_t recvbuf, lengthbuf, tmpsendbuf, sendbuf;
|
||||
char *recvspace, *tmpsendspace, lengthspace[4];
|
||||
isc_refcount_t references;
|
||||
isc_nmhandle_t *handle;
|
||||
isc_nmhandle_t *readhandle;
|
||||
isc_nmhandle_t *sendhandle;
|
||||
isc_socket_t *sock;
|
||||
ISC_LINK(dig_query_t) link;
|
||||
ISC_LINK(dig_query_t) clink;
|
||||
isc_sockaddr_t sockaddr;
|
||||
@@ -208,7 +187,6 @@ struct dig_query {
|
||||
isc_time_t time_recv;
|
||||
uint64_t byte_count;
|
||||
isc_timer_t *timer;
|
||||
isc_tlsctx_t *tlsctx;
|
||||
};
|
||||
|
||||
struct dig_server {
|
||||
@@ -237,14 +215,13 @@ extern unsigned int extrabytes;
|
||||
extern bool check_ra, have_ipv4, have_ipv6, specified_source, usesearch,
|
||||
showsearch, yaml;
|
||||
extern in_port_t port;
|
||||
extern bool port_set;
|
||||
extern unsigned int timeout;
|
||||
extern isc_mem_t *mctx;
|
||||
extern isc_refcount_t sendcount;
|
||||
extern int sendcount;
|
||||
extern int ndots;
|
||||
extern int lookup_counter;
|
||||
extern int exitcode;
|
||||
extern isc_sockaddr_t localaddr;
|
||||
extern isc_sockaddr_t bind_address;
|
||||
extern char keynametext[MXNAME];
|
||||
extern char keyfile[MXNAME];
|
||||
extern char keysecret[MXNAME];
|
||||
@@ -409,38 +386,32 @@ setup_text_key(void);
|
||||
* Routines exported from dig.c for use by dig for iOS
|
||||
*/
|
||||
|
||||
/*%
|
||||
/*%<
|
||||
* Call once only to set up libraries, parse global
|
||||
* parameters and initial command line query parameters
|
||||
*/
|
||||
void
|
||||
dig_setup(int argc, char **argv);
|
||||
|
||||
/*%
|
||||
/*%<
|
||||
* Call to supply new parameters for the next lookup
|
||||
*/
|
||||
void
|
||||
dig_query_setup(bool, bool, int argc, char **argv);
|
||||
|
||||
/*%
|
||||
/*%<
|
||||
* set the main application event cycle running
|
||||
*/
|
||||
void
|
||||
dig_startup(void);
|
||||
|
||||
/*%
|
||||
/*%<
|
||||
* Initiates the next lookup cycle
|
||||
*/
|
||||
void
|
||||
dig_query_start(void);
|
||||
|
||||
/*%
|
||||
* Activate/deactivate IDN filtering of output.
|
||||
*/
|
||||
void
|
||||
dig_idnsetup(dig_lookup_t *lookup, bool active);
|
||||
|
||||
/*%
|
||||
/*%<
|
||||
* Cleans up the application
|
||||
*/
|
||||
void
|
||||
|
||||
+4
-8
@@ -3,7 +3,7 @@
|
||||
*
|
||||
* This Source Code Form is subject to the terms of the Mozilla Public
|
||||
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
||||
* file, you can obtain one at https://mozilla.org/MPL/2.0/.
|
||||
* file, You can obtain one at http://mozilla.org/MPL/2.0/.
|
||||
*
|
||||
* See the COPYRIGHT file distributed with this work for additional
|
||||
* information regarding copyright ownership.
|
||||
@@ -151,11 +151,7 @@ received(unsigned int bytes, isc_sockaddr_t *from, dig_query_t *query) {
|
||||
if (!short_form) {
|
||||
char fromtext[ISC_SOCKADDR_FORMATSIZE];
|
||||
isc_sockaddr_format(from, fromtext, sizeof(fromtext));
|
||||
if (query->lookup->use_usec) {
|
||||
TIME_NOW_HIRES(&now);
|
||||
} else {
|
||||
TIME_NOW(&now);
|
||||
}
|
||||
TIME_NOW(&now);
|
||||
diff = (int)isc_time_microdiff(&now, &query->time_sent);
|
||||
printf("Received %u bytes from %s in %d ms\n", bytes, fromtext,
|
||||
diff / 1000);
|
||||
@@ -379,7 +375,7 @@ chase_cnamechain(dns_message_t *msg, dns_name_t *qname) {
|
||||
dns_rdataset_current(rdataset, &rdata);
|
||||
result = dns_rdata_tostruct(&rdata, &cname, NULL);
|
||||
check_result(result, "dns_rdata_tostruct");
|
||||
dns_name_copy(&cname.cname, qname);
|
||||
dns_name_copynf(&cname.cname, qname);
|
||||
dns_rdata_freestruct(&cname);
|
||||
}
|
||||
}
|
||||
@@ -442,7 +438,7 @@ printmessage(dig_query_t *query, const isc_buffer_t *msgbuf, dns_message_t *msg,
|
||||
|
||||
/* Add AAAA and MX lookups. */
|
||||
name = dns_fixedname_initname(&fixed);
|
||||
dns_name_copy(query->lookup->name, name);
|
||||
dns_name_copynf(query->lookup->name, name);
|
||||
chase_cnamechain(msg, name);
|
||||
dns_name_format(name, namestr, sizeof(namestr));
|
||||
lookup = clone_lookup(query->lookup, false);
|
||||
|
||||
+1
-1
@@ -3,7 +3,7 @@
|
||||
|
||||
This Source Code Form is subject to the terms of the Mozilla Public
|
||||
License, v. 2.0. If a copy of the MPL was not distributed with this
|
||||
file, you can obtain one at https://mozilla.org/MPL/2.0/.
|
||||
file, You can obtain one at http://mozilla.org/MPL/2.0/.
|
||||
|
||||
See the COPYRIGHT file distributed with this work for additional
|
||||
information regarding copyright ownership.
|
||||
|
||||
Symlink
+1
@@ -0,0 +1 @@
|
||||
../../../.clang-format.headers
|
||||
+82
-14
@@ -3,7 +3,7 @@
|
||||
*
|
||||
* This Source Code Form is subject to the terms of the Mozilla Public
|
||||
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
||||
* file, you can obtain one at https://mozilla.org/MPL/2.0/.
|
||||
* file, You can obtain one at http://mozilla.org/MPL/2.0/.
|
||||
*
|
||||
* See the COPYRIGHT file distributed with this work for additional
|
||||
* information regarding copyright ownership.
|
||||
@@ -37,7 +37,22 @@
|
||||
#include <dns/rdatatype.h>
|
||||
|
||||
#include "dighost.h"
|
||||
#include "readline.h"
|
||||
|
||||
#if defined(HAVE_READLINE)
|
||||
#if defined(HAVE_EDIT_READLINE_READLINE_H)
|
||||
#include <edit/readline/readline.h>
|
||||
#if defined(HAVE_EDIT_READLINE_HISTORY_H)
|
||||
#include <edit/readline/history.h>
|
||||
#endif /* if defined(HAVE_EDIT_READLINE_HISTORY_H) */
|
||||
#elif defined(HAVE_EDITLINE_READLINE_H)
|
||||
#include <editline/readline.h>
|
||||
#elif defined(HAVE_READLINE_READLINE_H)
|
||||
#include <readline/readline.h>
|
||||
#if defined(HAVE_READLINE_HISTORY_H)
|
||||
#include <readline/history.h>
|
||||
#endif /* if defined(HAVE_READLINE_HISTORY_H) */
|
||||
#endif /* if defined(HAVE_EDIT_READLINE_READLINE_H) */
|
||||
#endif /* if defined(HAVE_READLINE) */
|
||||
|
||||
static bool short_form = true, tcpmode = false, tcpmode_set = false,
|
||||
identify = false, stats = true, comments = true,
|
||||
@@ -110,6 +125,8 @@ static const char *rtypetext[] = {
|
||||
|
||||
#define N_KNOWN_RRTYPES (sizeof(rtypetext) / sizeof(rtypetext[0]))
|
||||
|
||||
static void
|
||||
flush_lookup_list(void);
|
||||
static void
|
||||
getinput(isc_task_t *task, isc_event_t *event);
|
||||
|
||||
@@ -134,6 +151,7 @@ static void
|
||||
query_finished(void) {
|
||||
isc_event_t *event = global_event;
|
||||
|
||||
flush_lookup_list();
|
||||
debug("dighost_shutdown()");
|
||||
|
||||
if (!in_use) {
|
||||
@@ -391,7 +409,7 @@ chase_cnamechain(dns_message_t *msg, dns_name_t *qname) {
|
||||
dns_rdataset_current(rdataset, &rdata);
|
||||
result = dns_rdata_tostruct(&rdata, &cname, NULL);
|
||||
check_result(result, "dns_rdata_tostruct");
|
||||
dns_name_copy(&cname.cname, qname);
|
||||
dns_name_copynf(&cname.cname, qname);
|
||||
dns_rdata_freestruct(&cname);
|
||||
}
|
||||
}
|
||||
@@ -448,7 +466,7 @@ printmessage(dig_query_t *query, const isc_buffer_t *msgbuf, dns_message_t *msg,
|
||||
|
||||
/* Add AAAA lookup. */
|
||||
name = dns_fixedname_initname(&fixed);
|
||||
dns_name_copy(query->lookup->name, name);
|
||||
dns_name_copynf(query->lookup->name, name);
|
||||
chase_cnamechain(msg, name);
|
||||
dns_name_format(name, namestr, sizeof(namestr));
|
||||
lookup = clone_lookup(query->lookup, false);
|
||||
@@ -619,8 +637,6 @@ static void
|
||||
setoption(char *opt) {
|
||||
size_t l = strlen(opt);
|
||||
|
||||
debugging = true;
|
||||
|
||||
#define CHECKOPT(A, N) \
|
||||
((l >= N) && (l < sizeof(A)) && (strncasecmp(opt, A, l) == 0))
|
||||
|
||||
@@ -771,6 +787,7 @@ addlookup(char *opt) {
|
||||
lookup->recurse = recurse;
|
||||
lookup->aaonly = aaonly;
|
||||
lookup->retries = tries;
|
||||
lookup->udpsize = 0;
|
||||
lookup->setqid = false;
|
||||
lookup->qid = 0;
|
||||
lookup->comments = comments;
|
||||
@@ -831,27 +848,38 @@ do_next_command(char *input) {
|
||||
|
||||
static void
|
||||
get_next_command(void) {
|
||||
char cmdlinebuf[COMMSIZE];
|
||||
char *cmdline, *ptr = NULL;
|
||||
char *buf;
|
||||
char *ptr;
|
||||
|
||||
fflush(stdout);
|
||||
buf = isc_mem_allocate(mctx, COMMSIZE);
|
||||
isc_app_block();
|
||||
if (interactive) {
|
||||
cmdline = ptr = readline("> ");
|
||||
if (ptr != NULL && *ptr != 0) {
|
||||
#ifdef HAVE_READLINE
|
||||
ptr = readline("> ");
|
||||
if (ptr != NULL) {
|
||||
add_history(ptr);
|
||||
}
|
||||
#else /* ifdef HAVE_READLINE */
|
||||
fprintf(stderr, "> ");
|
||||
fflush(stderr);
|
||||
ptr = fgets(buf, COMMSIZE, stdin);
|
||||
#endif /* ifdef HAVE_READLINE */
|
||||
} else {
|
||||
cmdline = fgets(cmdlinebuf, COMMSIZE, stdin);
|
||||
ptr = fgets(buf, COMMSIZE, stdin);
|
||||
}
|
||||
isc_app_unblock();
|
||||
if (cmdline == NULL) {
|
||||
if (ptr == NULL) {
|
||||
in_use = false;
|
||||
} else {
|
||||
do_next_command(cmdline);
|
||||
do_next_command(ptr);
|
||||
}
|
||||
if (ptr != NULL) {
|
||||
#ifdef HAVE_READLINE
|
||||
if (interactive) {
|
||||
free(ptr);
|
||||
}
|
||||
#endif /* ifdef HAVE_READLINE */
|
||||
isc_mem_free(mctx, buf);
|
||||
}
|
||||
|
||||
ISC_NORETURN static void
|
||||
@@ -903,6 +931,46 @@ parse_args(int argc, char **argv) {
|
||||
}
|
||||
}
|
||||
|
||||
static void
|
||||
flush_lookup_list(void) {
|
||||
dig_lookup_t *l, *lp;
|
||||
dig_query_t *q, *qp;
|
||||
dig_server_t *s, *sp;
|
||||
|
||||
lookup_counter = 0;
|
||||
l = ISC_LIST_HEAD(lookup_list);
|
||||
while (l != NULL) {
|
||||
q = ISC_LIST_HEAD(l->q);
|
||||
while (q != NULL) {
|
||||
if (q->sock != NULL) {
|
||||
isc_socket_cancel(q->sock, NULL,
|
||||
ISC_SOCKCANCEL_ALL);
|
||||
isc_socket_detach(&q->sock);
|
||||
}
|
||||
isc_buffer_invalidate(&q->recvbuf);
|
||||
isc_buffer_invalidate(&q->lengthbuf);
|
||||
qp = q;
|
||||
q = ISC_LIST_NEXT(q, link);
|
||||
ISC_LIST_DEQUEUE(l->q, qp, link);
|
||||
isc_mem_free(mctx, qp);
|
||||
}
|
||||
s = ISC_LIST_HEAD(l->my_server_list);
|
||||
while (s != NULL) {
|
||||
sp = s;
|
||||
s = ISC_LIST_NEXT(s, link);
|
||||
ISC_LIST_DEQUEUE(l->my_server_list, sp, link);
|
||||
isc_mem_free(mctx, sp);
|
||||
}
|
||||
if (l->sendmsg != NULL) {
|
||||
dns_message_destroy(&l->sendmsg);
|
||||
}
|
||||
lp = l;
|
||||
l = ISC_LIST_NEXT(l, link);
|
||||
ISC_LIST_DEQUEUE(lookup_list, lp, link);
|
||||
isc_mem_free(mctx, lp);
|
||||
}
|
||||
}
|
||||
|
||||
static void
|
||||
getinput(isc_task_t *task, isc_event_t *event) {
|
||||
UNUSED(task);
|
||||
|
||||
@@ -3,7 +3,7 @@
|
||||
|
||||
This Source Code Form is subject to the terms of the Mozilla Public
|
||||
License, v. 2.0. If a copy of the MPL was not distributed with this
|
||||
file, you can obtain one at https://mozilla.org/MPL/2.0/.
|
||||
file, You can obtain one at http://mozilla.org/MPL/2.0/.
|
||||
|
||||
See the COPYRIGHT file distributed with this work for additional
|
||||
information regarding copyright ownership.
|
||||
|
||||
@@ -1,56 +0,0 @@
|
||||
/*
|
||||
* Copyright (C) Internet Systems Consortium, Inc. ("ISC")
|
||||
*
|
||||
* This Source Code Form is subject to the terms of the Mozilla Public
|
||||
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
||||
* file, you can obtain one at https://mozilla.org/MPL/2.0/.
|
||||
*
|
||||
* See the COPYRIGHT file distributed with this work for additional
|
||||
* information regarding copyright ownership.
|
||||
*/
|
||||
|
||||
#pragma once
|
||||
|
||||
/*
|
||||
* A little wrapper around readline(), add_history() and free() to make using
|
||||
* the readline code simpler.
|
||||
*/
|
||||
|
||||
#if defined(HAVE_READLINE_LIBEDIT)
|
||||
#include <editline/readline.h>
|
||||
#elif defined(HAVE_READLINE_EDITLINE)
|
||||
#include <editline.h>
|
||||
#elif defined(HAVE_READLINE_READLINE)
|
||||
/* Prevent deprecated functions being declared. */
|
||||
#define _FUNCTION_DEF 1
|
||||
/* Ensure rl_message() gets prototype. */
|
||||
#define USE_VARARGS 1
|
||||
#define PREFER_STDARG 1
|
||||
#include <readline/history.h>
|
||||
#include <readline/readline.h>
|
||||
#endif
|
||||
|
||||
#if !defined(HAVE_READLINE_LIBEDIT) && !defined(HAVE_READLINE_EDITLINE) && \
|
||||
!defined(HAVE_READLINE_READLINE)
|
||||
|
||||
#include <stdio.h>
|
||||
#include <stdlib.h>
|
||||
|
||||
#define RL_MAXCMD (128 * 1024)
|
||||
|
||||
static inline char *
|
||||
readline(const char *prompt) {
|
||||
char *line, *buf = malloc(RL_MAXCMD);
|
||||
fprintf(stdout, "%s", prompt);
|
||||
fflush(stdout);
|
||||
line = fgets(buf, RL_MAXCMD, stdin);
|
||||
if (line == NULL) {
|
||||
free(buf);
|
||||
return (NULL);
|
||||
}
|
||||
return (buf);
|
||||
};
|
||||
|
||||
#define add_history(line)
|
||||
|
||||
#endif
|
||||
@@ -75,7 +75,7 @@
|
||||
<GenerateDebugInformation>true</GenerateDebugInformation>
|
||||
<OutputFile>..\..\..\Build\$(Configuration)\$(TargetName)$(TargetExt)</OutputFile>
|
||||
<AdditionalLibraryDirectories>$(Configuration);..\..\..\lib\isc\win32\$(Configuration);..\..\..\lib\isccfg\win32\$(Configuration);..\..\..\lib\irs\win32\$(Configuration);..\..\..\lib\dns\win32\$(Configuration);..\..\..\lib\bind9\win32\$(Configuration);%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>
|
||||
<AdditionalDependencies>@OPENSSL_LIBCRYPTO@@OPENSSL_LIBSSL@dighost.lib;libisc.lib;libisccfg.lib;libirs.lib;libdns.lib;libbind9.lib;@IDN_LIB@ws2_32.lib;%(AdditionalDependencies)</AdditionalDependencies>
|
||||
<AdditionalDependencies>@OPENSSL_LIB@dighost.lib;libisc.lib;libisccfg.lib;libirs.lib;libdns.lib;libbind9.lib;@IDN_LIB@ws2_32.lib;%(AdditionalDependencies)</AdditionalDependencies>
|
||||
</Link>
|
||||
</ItemDefinitionGroup>
|
||||
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|@PLATFORM@'">
|
||||
@@ -107,7 +107,7 @@
|
||||
<OutputFile>..\..\..\Build\$(Configuration)\$(TargetName)$(TargetExt)</OutputFile>
|
||||
<LinkTimeCodeGeneration>Default</LinkTimeCodeGeneration>
|
||||
<AdditionalLibraryDirectories>$(Configuration);..\..\..\lib\isc\win32\$(Configuration);..\..\..\lib\isccfg\win32\$(Configuration);..\..\..\lib\irs\win32\$(Configuration);..\..\..\lib\dns\win32\$(Configuration);..\..\..\lib\bind9\win32\$(Configuration);%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>
|
||||
<AdditionalDependencies>@OPENSSL_LIBCRYPTO@@OPENSSL_LIBSSL@dighost.lib;libisc.lib;libisccfg.lib;libirs.lib;libdns.lib;libbind9.lib;@IDN_LIB@ws2_32.lib;%(AdditionalDependencies)</AdditionalDependencies>
|
||||
<AdditionalDependencies>@OPENSSL_LIB@dighost.lib;libisc.lib;libisccfg.lib;libirs.lib;libdns.lib;libbind9.lib;@IDN_LIB@ws2_32.lib;%(AdditionalDependencies)</AdditionalDependencies>
|
||||
</Link>
|
||||
</ItemDefinitionGroup>
|
||||
<ItemGroup>
|
||||
|
||||
@@ -75,7 +75,7 @@
|
||||
<GenerateDebugInformation>true</GenerateDebugInformation>
|
||||
<OutputFile>..\..\..\Build\$(Configuration)\$(TargetName)$(TargetExt)</OutputFile>
|
||||
<AdditionalLibraryDirectories>$(Configuration);..\..\..\lib\isc\win32\$(Configuration);..\..\..\lib\isccfg\win32\$(Configuration);..\..\..\lib\irs\win32\$(Configuration);..\..\..\lib\dns\win32\$(Configuration);..\..\..\lib\bind9\win32\$(Configuration);%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>
|
||||
<AdditionalDependencies>@OPENSSL_LIBCRYPTO@@OPENSSL_LIBSSL@dighost.lib;@IDN_LIB@libisc.lib;libisccfg.lib;libirs.lib;libdns.lib;libbind9.lib;ws2_32.lib;%(AdditionalDependencies)</AdditionalDependencies>
|
||||
<AdditionalDependencies>@OPENSSL_LIB@dighost.lib;@IDN_LIB@libisc.lib;libisccfg.lib;libirs.lib;libdns.lib;libbind9.lib;ws2_32.lib;%(AdditionalDependencies)</AdditionalDependencies>
|
||||
</Link>
|
||||
</ItemDefinitionGroup>
|
||||
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|@PLATFORM@'">
|
||||
@@ -107,7 +107,7 @@
|
||||
<OutputFile>..\..\..\Build\$(Configuration)\$(TargetName)$(TargetExt)</OutputFile>
|
||||
<LinkTimeCodeGeneration>Default</LinkTimeCodeGeneration>
|
||||
<AdditionalLibraryDirectories>$(Configuration);..\..\..\lib\isc\win32\$(Configuration);..\..\..\lib\isccfg\win32\$(Configuration);..\..\..\lib\irs\win32\$(Configuration);..\..\..\lib\dns\win32\$(Configuration);..\..\..\lib\bind9\win32\$(Configuration);%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>
|
||||
<AdditionalDependencies>@OPENSSL_LIBCRYPTO@@OPENSSL_LIBSSL@dighost.lib;@IDN_LIB@libisc.lib;libisccfg.lib;libirs.lib;libdns.lib;libbind9.lib;ws2_32.lib;%(AdditionalDependencies)</AdditionalDependencies>
|
||||
<AdditionalDependencies>@OPENSSL_LIB@dighost.lib;@IDN_LIB@libisc.lib;libisccfg.lib;libirs.lib;libdns.lib;libbind9.lib;ws2_32.lib;%(AdditionalDependencies)</AdditionalDependencies>
|
||||
</Link>
|
||||
</ItemDefinitionGroup>
|
||||
<ItemGroup>
|
||||
|
||||
@@ -75,7 +75,7 @@
|
||||
<GenerateDebugInformation>true</GenerateDebugInformation>
|
||||
<OutputFile>..\..\..\Build\$(Configuration)\$(TargetName)$(TargetExt)</OutputFile>
|
||||
<AdditionalLibraryDirectories>..\..\..\lib\isc\win32\$(Configuration);..\..\..\lib\isccfg\win32\$(Configuration);..\..\..\lib\irs\win32\$(Configuration);..\..\..\lib\dns\win32\$(Configuration);..\..\..\lib\bind9\win32\$(Configuration);%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>
|
||||
<AdditionalDependencies>@OPENSSL_LIBCRYPTO@@OPENSSL_LIBSSL@@READLINE_LIBD@@IDN_LIB@libisc.lib;libisccfg.lib;libirs.lib;libdns.lib;libbind9.lib;ws2_32.lib;%(AdditionalDependencies)</AdditionalDependencies>
|
||||
<AdditionalDependencies>@OPENSSL_LIB@@READLINE_LIBD@@IDN_LIB@libisc.lib;libisccfg.lib;libirs.lib;libdns.lib;libbind9.lib;ws2_32.lib;%(AdditionalDependencies)</AdditionalDependencies>
|
||||
</Link>
|
||||
</ItemDefinitionGroup>
|
||||
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|@PLATFORM@'">
|
||||
@@ -107,7 +107,7 @@
|
||||
<OutputFile>..\..\..\Build\$(Configuration)\$(TargetName)$(TargetExt)</OutputFile>
|
||||
<LinkTimeCodeGeneration>Default</LinkTimeCodeGeneration>
|
||||
<AdditionalLibraryDirectories>..\..\..\lib\isc\win32\$(Configuration);..\..\..\lib\isccfg\win32\$(Configuration);..\..\..\lib\irs\win32\$(Configuration);..\..\..\lib\dns\win32\$(Configuration);..\..\..\lib\bind9\win32\$(Configuration);%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>
|
||||
<AdditionalDependencies>@OPENSSL_LIBCRYPTO@@OPENSSL_LIBSSL@@READLINE_LIB@@IDN_LIB@libisc.lib;libisccfg.lib;libirs.lib;libdns.lib;libbind9.lib;ws2_32.lib;%(AdditionalDependencies)</AdditionalDependencies>
|
||||
<AdditionalDependencies>@OPENSSL_LIB@@READLINE_LIB@@IDN_LIB@libisc.lib;libisccfg.lib;libirs.lib;libdns.lib;libbind9.lib;ws2_32.lib;%(AdditionalDependencies)</AdditionalDependencies>
|
||||
</Link>
|
||||
</ItemDefinitionGroup>
|
||||
<ItemGroup>
|
||||
|
||||
@@ -3,7 +3,7 @@
|
||||
*
|
||||
* This Source Code Form is subject to the terms of the Mozilla Public
|
||||
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
||||
* file, you can obtain one at https://mozilla.org/MPL/2.0/.
|
||||
* file, You can obtain one at http://mozilla.org/MPL/2.0/.
|
||||
*
|
||||
* See the COPYRIGHT file distributed with this work for additional
|
||||
* information regarding copyright ownership.
|
||||
|
||||
@@ -3,7 +3,7 @@
|
||||
|
||||
This Source Code Form is subject to the terms of the Mozilla Public
|
||||
License, v. 2.0. If a copy of the MPL was not distributed with this
|
||||
file, you can obtain one at https://mozilla.org/MPL/2.0/.
|
||||
file, You can obtain one at http://mozilla.org/MPL/2.0/.
|
||||
|
||||
See the COPYRIGHT file distributed with this work for additional
|
||||
information regarding copyright ownership.
|
||||
|
||||
@@ -3,7 +3,7 @@
|
||||
*
|
||||
* This Source Code Form is subject to the terms of the Mozilla Public
|
||||
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
||||
* file, you can obtain one at https://mozilla.org/MPL/2.0/.
|
||||
* file, You can obtain one at http://mozilla.org/MPL/2.0/.
|
||||
*
|
||||
* See the COPYRIGHT file distributed with this work for additional
|
||||
* information regarding copyright ownership.
|
||||
@@ -215,7 +215,7 @@ loadkey(char *filename, unsigned char *key_buf, unsigned int key_buf_size,
|
||||
rdclass = dst_key_class(key);
|
||||
|
||||
name = dns_fixedname_initname(&fixed);
|
||||
dns_name_copy(dst_key_name(key), name);
|
||||
dns_name_copynf(dst_key_name(key), name);
|
||||
|
||||
dst_key_free(&key);
|
||||
}
|
||||
|
||||
@@ -3,7 +3,7 @@
|
||||
|
||||
This Source Code Form is subject to the terms of the Mozilla Public
|
||||
License, v. 2.0. If a copy of the MPL was not distributed with this
|
||||
file, you can obtain one at https://mozilla.org/MPL/2.0/.
|
||||
file, You can obtain one at http://mozilla.org/MPL/2.0/.
|
||||
|
||||
See the COPYRIGHT file distributed with this work for additional
|
||||
information regarding copyright ownership.
|
||||
|
||||
@@ -3,7 +3,7 @@
|
||||
*
|
||||
* This Source Code Form is subject to the terms of the Mozilla Public
|
||||
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
||||
* file, you can obtain one at https://mozilla.org/MPL/2.0/.
|
||||
* file, You can obtain one at http://mozilla.org/MPL/2.0/.
|
||||
*
|
||||
* See the COPYRIGHT file distributed with this work for additional
|
||||
* information regarding copyright ownership.
|
||||
@@ -185,7 +185,7 @@ loadkey(char *filename, unsigned char *key_buf, unsigned int key_buf_size,
|
||||
rdclass = dst_key_class(key);
|
||||
|
||||
name = dns_fixedname_initname(&fixed);
|
||||
dns_name_copy(dst_key_name(key), name);
|
||||
dns_name_copynf(dst_key_name(key), name);
|
||||
|
||||
dst_key_free(&key);
|
||||
}
|
||||
|
||||
@@ -3,7 +3,7 @@
|
||||
|
||||
This Source Code Form is subject to the terms of the Mozilla Public
|
||||
License, v. 2.0. If a copy of the MPL was not distributed with this
|
||||
file, you can obtain one at https://mozilla.org/MPL/2.0/.
|
||||
file, You can obtain one at http://mozilla.org/MPL/2.0/.
|
||||
|
||||
See the COPYRIGHT file distributed with this work for additional
|
||||
information regarding copyright ownership.
|
||||
@@ -37,8 +37,8 @@ Description
|
||||
~~~~~~~~~~~
|
||||
|
||||
``dnssec-importkey`` reads a public DNSKEY record and generates a pair
|
||||
of .key/.private files. The DNSKEY record may be read from an
|
||||
existing .key file, in which case a corresponding .private file is
|
||||
of .key/.private files. The DNSKEY record may be read from an existing
|
||||
.key file, in which case a corresponding .private file is
|
||||
generated, or it may be read from any other file or from the standard
|
||||
input, in which case both .key and .private files are generated.
|
||||
|
||||
|
||||
@@ -3,7 +3,7 @@
|
||||
*
|
||||
* This Source Code Form is subject to the terms of the Mozilla Public
|
||||
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
||||
* file, you can obtain one at https://mozilla.org/MPL/2.0/.
|
||||
* file, You can obtain one at http://mozilla.org/MPL/2.0/.
|
||||
*
|
||||
* See the COPYRIGHT file distributed with this work for additional
|
||||
* information regarding copyright ownership.
|
||||
@@ -362,6 +362,7 @@ main(int argc, char **argv) {
|
||||
setup_logging(mctx, &log);
|
||||
|
||||
if (predecessor == NULL) {
|
||||
/* cppcheck-suppress nullPointerRedundantCheck */
|
||||
if (label == NULL) {
|
||||
fatal("the key label was not specified");
|
||||
}
|
||||
@@ -383,6 +384,7 @@ main(int argc, char **argv) {
|
||||
isc_result_totext(ret));
|
||||
}
|
||||
|
||||
/* cppcheck-suppress nullPointerRedundantCheck */
|
||||
if (strchr(label, ':') == NULL) {
|
||||
char *l;
|
||||
int len;
|
||||
@@ -394,11 +396,13 @@ main(int argc, char **argv) {
|
||||
label = l;
|
||||
}
|
||||
|
||||
/* cppcheck-suppress nullPointerRedundantCheck */
|
||||
if (algname == NULL) {
|
||||
fatal("no algorithm specified");
|
||||
}
|
||||
|
||||
r.base = algname;
|
||||
/* cppcheck-suppress nullPointerRedundantCheck */
|
||||
r.length = strlen(algname);
|
||||
ret = dns_secalg_fromtext(&alg, &r);
|
||||
if (ret != ISC_R_SUCCESS) {
|
||||
|
||||
@@ -3,7 +3,7 @@
|
||||
|
||||
This Source Code Form is subject to the terms of the Mozilla Public
|
||||
License, v. 2.0. If a copy of the MPL was not distributed with this
|
||||
file, you can obtain one at https://mozilla.org/MPL/2.0/.
|
||||
file, You can obtain one at http://mozilla.org/MPL/2.0/.
|
||||
|
||||
See the COPYRIGHT file distributed with this work for additional
|
||||
information regarding copyright ownership.
|
||||
@@ -76,9 +76,9 @@ Options
|
||||
``-E engine``
|
||||
This option specifies the cryptographic hardware to use.
|
||||
|
||||
When BIND 9 is built with OpenSSL, this needs to be set to the OpenSSL
|
||||
engine identifier that drives the cryptographic accelerator or
|
||||
hardware service module (usually ``pkcs11``). When BIND is
|
||||
When BIND 9 is built with OpenSSL PKCS#11 support, this defaults to the
|
||||
string ``pkcs11``, which identifies an OpenSSL engine that can drive a
|
||||
cryptographic accelerator or hardware service module. When BIND is
|
||||
built with native PKCS#11 cryptography (``--enable-native-pkcs11``), it
|
||||
defaults to the path of the PKCS#11 provider library specified via
|
||||
``--with-pkcs11``.
|
||||
|
||||
@@ -3,7 +3,7 @@
|
||||
*
|
||||
* This Source Code Form is subject to the terms of the Mozilla Public
|
||||
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
||||
* file, you can obtain one at https://mozilla.org/MPL/2.0/.
|
||||
* file, You can obtain one at http://mozilla.org/MPL/2.0/.
|
||||
*
|
||||
* See the COPYRIGHT file distributed with this work for additional
|
||||
* information regarding copyright ownership.
|
||||
@@ -269,8 +269,8 @@ kasp_from_conf(cfg_obj_t *config, isc_mem_t *mctx, const char *name,
|
||||
continue;
|
||||
}
|
||||
|
||||
result = cfg_kasp_fromconfig(kconfig, NULL, mctx, lctx,
|
||||
&kasplist, &kasp);
|
||||
result = cfg_kasp_fromconfig(kconfig, mctx, lctx, &kasplist,
|
||||
&kasp);
|
||||
if (result != ISC_R_SUCCESS) {
|
||||
fatal("failed to configure dnssec-policy '%s': %s",
|
||||
cfg_obj_asstring(cfg_tuple_get(kconfig, "name")),
|
||||
@@ -284,7 +284,7 @@ kasp_from_conf(cfg_obj_t *config, isc_mem_t *mctx, const char *name,
|
||||
*kaspp = kasp;
|
||||
|
||||
/*
|
||||
* Cleanup kasp list.
|
||||
* Same cleanup for kasp list.
|
||||
*/
|
||||
for (kasp = ISC_LIST_HEAD(kasplist); kasp != NULL; kasp = kasp_next) {
|
||||
kasp_next = ISC_LIST_NEXT(kasp, link);
|
||||
@@ -782,7 +782,7 @@ keygen(keygen_ctx_t *ctx, isc_mem_t *mctx, int argc, char **argv) {
|
||||
}
|
||||
|
||||
/* Set dnssec-policy related metadata */
|
||||
if (ctx->policy != NULL) {
|
||||
if (ctx->policy) {
|
||||
dst_key_setnum(key, DST_NUM_LIFETIME, ctx->lifetime);
|
||||
dst_key_setbool(key, DST_BOOL_KSK, ctx->ksk);
|
||||
dst_key_setbool(key, DST_BOOL_ZSK, ctx->zsk);
|
||||
@@ -1180,10 +1180,12 @@ main(int argc, char **argv) {
|
||||
}
|
||||
|
||||
if (ctx.predecessor == NULL && ctx.policy == NULL) {
|
||||
/* cppcheck-suppress nullPointerRedundantCheck */
|
||||
if (algname == NULL) {
|
||||
fatal("no algorithm specified");
|
||||
}
|
||||
r.base = algname;
|
||||
/* cppcheck-suppress nullPointerRedundantCheck */
|
||||
r.length = strlen(algname);
|
||||
ret = dns_secalg_fromtext(&ctx.alg, &r);
|
||||
if (ret != ISC_R_SUCCESS) {
|
||||
|
||||
@@ -3,7 +3,7 @@
|
||||
|
||||
This Source Code Form is subject to the terms of the Mozilla Public
|
||||
License, v. 2.0. If a copy of the MPL was not distributed with this
|
||||
file, you can obtain one at https://mozilla.org/MPL/2.0/.
|
||||
file, You can obtain one at http://mozilla.org/MPL/2.0/.
|
||||
|
||||
See the COPYRIGHT file distributed with this work for additional
|
||||
information regarding copyright ownership.
|
||||
@@ -103,9 +103,9 @@ Options
|
||||
``-E engine``
|
||||
This option specifies the cryptographic hardware to use, when applicable.
|
||||
|
||||
When BIND 9 is built with OpenSSL, this needs to be set to the OpenSSL
|
||||
engine identifier that drives the cryptographic accelerator or
|
||||
hardware service module (usually ``pkcs11``). When BIND is
|
||||
When BIND is built with OpenSSL PKCS#11 support, this defaults to the
|
||||
string ``pkcs11``, which identifies an OpenSSL engine that can drive a
|
||||
cryptographic accelerator or hardware service module. When BIND is
|
||||
built with native PKCS#11 cryptography (``--enable-native-pkcs11``), it
|
||||
defaults to the path of the PKCS#11 provider library specified via
|
||||
``--with-pkcs11``.
|
||||
|
||||
@@ -3,7 +3,7 @@
|
||||
*
|
||||
* This Source Code Form is subject to the terms of the Mozilla Public
|
||||
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
||||
* file, you can obtain one at https://mozilla.org/MPL/2.0/.
|
||||
* file, You can obtain one at http://mozilla.org/MPL/2.0/.
|
||||
*
|
||||
* See the COPYRIGHT file distributed with this work for additional
|
||||
* information regarding copyright ownership.
|
||||
|
||||
@@ -3,7 +3,7 @@
|
||||
|
||||
This Source Code Form is subject to the terms of the Mozilla Public
|
||||
License, v. 2.0. If a copy of the MPL was not distributed with this
|
||||
file, you can obtain one at https://mozilla.org/MPL/2.0/.
|
||||
file, You can obtain one at http://mozilla.org/MPL/2.0/.
|
||||
|
||||
See the COPYRIGHT file distributed with this work for additional
|
||||
information regarding copyright ownership.
|
||||
@@ -59,9 +59,9 @@ Options
|
||||
``-E engine``
|
||||
This option specifies the cryptographic hardware to use, when applicable.
|
||||
|
||||
When BIND 9 is built with OpenSSL, this needs to be set to the OpenSSL
|
||||
engine identifier that drives the cryptographic accelerator or
|
||||
hardware service module (usually ``pkcs11``). When BIND is
|
||||
When BIND 9 is built with OpenSSL PKCS#11 support, this defaults to the
|
||||
string ``pkcs11``, which identifies an OpenSSL engine that can drive a
|
||||
cryptographic accelerator or hardware service module. When BIND is
|
||||
built with native PKCS#11 cryptography (``--enable-native-pkcs11``), it
|
||||
defaults to the path of the PKCS#11 provider library specified via
|
||||
``--with-pkcs11``.
|
||||
|
||||
@@ -3,7 +3,7 @@
|
||||
*
|
||||
* This Source Code Form is subject to the terms of the Mozilla Public
|
||||
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
||||
* file, you can obtain one at https://mozilla.org/MPL/2.0/.
|
||||
* file, You can obtain one at http://mozilla.org/MPL/2.0/.
|
||||
*
|
||||
* See the COPYRIGHT file distributed with this work for additional
|
||||
* information regarding copyright ownership.
|
||||
@@ -75,8 +75,6 @@ usage(void) {
|
||||
fprintf(stderr, "Timing options:\n");
|
||||
fprintf(stderr, " -P date/[+-]offset/none: set/unset key "
|
||||
"publication date\n");
|
||||
fprintf(stderr, " -P ds date/[+-]offset/none: set/unset "
|
||||
"DS publication date\n");
|
||||
fprintf(stderr, " -P sync date/[+-]offset/none: set/unset "
|
||||
"CDS and CDNSKEY publication date\n");
|
||||
fprintf(stderr, " -A date/[+-]offset/none: set/unset key "
|
||||
@@ -87,8 +85,6 @@ usage(void) {
|
||||
"inactivation date\n");
|
||||
fprintf(stderr, " -D date/[+-]offset/none: set/unset key "
|
||||
"deletion date\n");
|
||||
fprintf(stderr, " -D ds date/[+-]offset/none: set/unset "
|
||||
"DS deletion date\n");
|
||||
fprintf(stderr, " -D sync date/[+-]offset/none: set/unset "
|
||||
"CDS and CDNSKEY deletion date\n");
|
||||
fprintf(stderr, " -S <key>: generate a successor to an existing "
|
||||
@@ -247,10 +243,6 @@ main(int argc, char **argv) {
|
||||
bool unsetsyncadd = false, setsyncadd = false;
|
||||
bool unsetsyncdel = false, setsyncdel = false;
|
||||
bool printsyncadd = false, printsyncdel = false;
|
||||
isc_stdtime_t dsadd = 0, dsdel = 0;
|
||||
bool unsetdsadd = false, setdsadd = false;
|
||||
bool unsetdsdel = false, setdsdel = false;
|
||||
bool printdsadd = false, printdsdel = false;
|
||||
|
||||
options = DST_TYPE_PUBLIC | DST_TYPE_PRIVATE | DST_TYPE_STATE;
|
||||
|
||||
@@ -298,18 +290,6 @@ main(int argc, char **argv) {
|
||||
unsetsyncdel = !setsyncdel;
|
||||
break;
|
||||
}
|
||||
/* -Dds ? */
|
||||
if (isoptarg("ds", argv, usage)) {
|
||||
if (unsetdsdel || setdsdel) {
|
||||
fatal("-D ds specified more than once");
|
||||
}
|
||||
|
||||
changed = true;
|
||||
dsdel = strtotime(isc_commandline_argument, now,
|
||||
now, &setdsdel);
|
||||
unsetdsdel = !setdsdel;
|
||||
break;
|
||||
}
|
||||
/* -Ddnskey ? */
|
||||
(void)isoptarg("dnskey", argv, usage);
|
||||
if (setdel || unsetdel) {
|
||||
@@ -414,19 +394,6 @@ main(int argc, char **argv) {
|
||||
unsetsyncadd = !setsyncadd;
|
||||
break;
|
||||
}
|
||||
/* -Pds ? */
|
||||
if (isoptarg("ds", argv, usage)) {
|
||||
if (unsetdsadd || setdsadd) {
|
||||
fatal("-P ds specified more than once");
|
||||
}
|
||||
|
||||
changed = true;
|
||||
dsadd = strtotime(isc_commandline_argument, now,
|
||||
now, &setdsadd);
|
||||
unsetdsadd = !setdsadd;
|
||||
break;
|
||||
}
|
||||
/* -Pdnskey ? */
|
||||
(void)isoptarg("dnskey", argv, usage);
|
||||
if (setpub || unsetpub) {
|
||||
fatal("-P specified more than once");
|
||||
@@ -448,8 +415,6 @@ main(int argc, char **argv) {
|
||||
printdel = true;
|
||||
printsyncadd = true;
|
||||
printsyncdel = true;
|
||||
printdsadd = true;
|
||||
printdsdel = true;
|
||||
break;
|
||||
}
|
||||
|
||||
@@ -467,11 +432,6 @@ main(int argc, char **argv) {
|
||||
printsyncdel = true;
|
||||
break;
|
||||
}
|
||||
if (!strncmp(p, "ds", 2)) {
|
||||
p += 2;
|
||||
printdsdel = true;
|
||||
break;
|
||||
}
|
||||
printdel = true;
|
||||
break;
|
||||
case 'I':
|
||||
@@ -483,11 +443,6 @@ main(int argc, char **argv) {
|
||||
printsyncadd = true;
|
||||
break;
|
||||
}
|
||||
if (!strncmp(p, "ds", 2)) {
|
||||
p += 2;
|
||||
printdsadd = true;
|
||||
break;
|
||||
}
|
||||
printpub = true;
|
||||
break;
|
||||
case 'R':
|
||||
@@ -822,18 +777,6 @@ main(int argc, char **argv) {
|
||||
dst_key_unsettime(key, DST_TIME_SYNCDELETE);
|
||||
}
|
||||
|
||||
if (setdsadd) {
|
||||
dst_key_settime(key, DST_TIME_DSPUBLISH, dsadd);
|
||||
} else if (unsetdsadd) {
|
||||
dst_key_unsettime(key, DST_TIME_DSPUBLISH);
|
||||
}
|
||||
|
||||
if (setdsdel) {
|
||||
dst_key_settime(key, DST_TIME_DSDELETE, dsdel);
|
||||
} else if (unsetdsdel) {
|
||||
dst_key_unsettime(key, DST_TIME_DSDELETE);
|
||||
}
|
||||
|
||||
if (setttl) {
|
||||
dst_key_setttl(key, ttl);
|
||||
}
|
||||
@@ -951,14 +894,6 @@ main(int argc, char **argv) {
|
||||
stdout);
|
||||
}
|
||||
|
||||
if (printdsadd) {
|
||||
printtime(key, DST_TIME_DSPUBLISH, "DS Publish", epoch, stdout);
|
||||
}
|
||||
|
||||
if (printdsdel) {
|
||||
printtime(key, DST_TIME_DSDELETE, "DS Delete", epoch, stdout);
|
||||
}
|
||||
|
||||
if (changed) {
|
||||
writekey(key, directory, write_state);
|
||||
if (predecessor != NULL && prevkey != NULL) {
|
||||
|
||||
@@ -3,7 +3,7 @@
|
||||
|
||||
This Source Code Form is subject to the terms of the Mozilla Public
|
||||
License, v. 2.0. If a copy of the MPL was not distributed with this
|
||||
file, you can obtain one at https://mozilla.org/MPL/2.0/.
|
||||
file, You can obtain one at http://mozilla.org/MPL/2.0/.
|
||||
|
||||
See the COPYRIGHT file distributed with this work for additional
|
||||
information regarding copyright ownership.
|
||||
@@ -29,7 +29,7 @@ dnssec-settime: set the key timing metadata for a DNSSEC key
|
||||
Synopsis
|
||||
~~~~~~~~
|
||||
|
||||
:program:`dnssec-settime` [**-f**] [**-K** directory] [**-L** ttl] [**-P** date/offset] [**-P** ds date/offset] [**-P** sync date/offset] [**-A** date/offset] [**-R** date/offset] [**-I** date/offset] [**-D** date/offset] [**-D** ds date/offset] [**-D** sync date/offset] [**-S** key] [**-i** interval] [**-h**] [**-V**] [**-v** level] [**-E** engine] {keyfile} [**-s**] [**-g** state] [**-d** state date/offset] [**-k** state date/offset] [**-r** state date/offset] [**-z** state date/offset]
|
||||
:program:`dnssec-settime` [**-f**] [**-K** directory] [**-L** ttl] [**-P** date/offset] [**-P** sync date/offset] [**-A** date/offset] [**-R** date/offset] [**-I** date/offset] [**-D** date/offset] [**-D** sync date/offset] [**-S** key] [**-i** interval] [**-h**] [**-V**] [**-v** level] [**-E** engine] {keyfile} [**-s**] [**-g** state] [**-d** state date/offset] [**-k** state date/offset] [**-r** state date/offset] [**-z** state date/offset]
|
||||
|
||||
Description
|
||||
~~~~~~~~~~~
|
||||
@@ -102,9 +102,9 @@ Options
|
||||
``-E engine``
|
||||
This option specifies the cryptographic hardware to use, when applicable.
|
||||
|
||||
When BIND 9 is built with OpenSSL, this needs to be set to the OpenSSL
|
||||
engine identifier that drives the cryptographic accelerator or
|
||||
hardware service module (usually ``pkcs11``). When BIND is
|
||||
When BIND is built with OpenSSL PKCS#11 support, this defaults to the
|
||||
string ``pkcs11``, which identifies an OpenSSL engine that can drive a
|
||||
cryptographic accelerator or hardware service module. When BIND is
|
||||
built with native PKCS#11 cryptography (``--enable-native-pkcs11``), it
|
||||
defaults to the path of the PKCS#11 provider library specified via
|
||||
``--with-pkcs11``.
|
||||
@@ -126,10 +126,6 @@ explicitly prevent a date from being set, use ``none`` or ``never``.
|
||||
that date, the key is included in the zone but is not used
|
||||
to sign it.
|
||||
|
||||
``-P ds date/offset``
|
||||
This option sets the date on which DS records that match this key have been
|
||||
seen in the parent zone.
|
||||
|
||||
``-P sync date/offset``
|
||||
This option sets the date on which CDS and CDNSKEY records that match this key
|
||||
are to be published to the zone.
|
||||
@@ -153,10 +149,6 @@ explicitly prevent a date from being set, use ``none`` or ``never``.
|
||||
key is no longer included in the zone. (However, it may remain in the key
|
||||
repository.)
|
||||
|
||||
``-D ds date/offset``
|
||||
This option sets the date on which the DS records that match this key have
|
||||
been seen removed from the parent zone.
|
||||
|
||||
``-D sync date/offset``
|
||||
This option sets the date on which the CDS and CDNSKEY records that match this
|
||||
key are to be deleted.
|
||||
@@ -223,16 +215,15 @@ associated with a key.
|
||||
``-u``
|
||||
This option indicates that times should be printed in Unix epoch format.
|
||||
|
||||
``-p C/P/Pds/Psync/A/R/I/D/Dds/Dsync/all``
|
||||
This option prints a specific metadata value or set of metadata values.
|
||||
The ``-p`` option may be followed by one or more of the following letters or
|
||||
``-p C/P/Psync/A/R/I/D/Dsync/all``
|
||||
This option prints a specific metadata value or set of metadata values. The ``-p``
|
||||
option may be followed by one or more of the following letters or
|
||||
strings to indicate which value or values to print: ``C`` for the
|
||||
creation date, ``P`` for the publication date, ``Pds` for the DS publication
|
||||
date, ``Psync`` for the CDS and CDNSKEY publication date, ``A`` for the
|
||||
activation date, ``R`` for the revocation date, ``I`` for the inactivation
|
||||
date, ``D`` for the deletion date, ``Dds`` for the DS deletion date,
|
||||
and ``Dsync`` for the CDS and CDNSKEY deletion date. To print all of the
|
||||
metadata, use ``all``.
|
||||
creation date, ``P`` for the publication date, ``Psync`` for the CDS
|
||||
and CDNSKEY publication date, ``A`` for the activation date, ``R``
|
||||
for the revocation date, ``I`` for the inactivation date, ``D`` for
|
||||
the deletion date, and ``Dsync`` for the CDS and CDNSKEY deletion
|
||||
date. To print all of the metadata, use ``all``.
|
||||
|
||||
See Also
|
||||
~~~~~~~~
|
||||
|
||||
@@ -3,7 +3,7 @@
|
||||
*
|
||||
* This Source Code Form is subject to the terms of the Mozilla Public
|
||||
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
||||
* file, you can obtain one at https://mozilla.org/MPL/2.0/.
|
||||
* file, You can obtain one at http://mozilla.org/MPL/2.0/.
|
||||
*
|
||||
* See the COPYRIGHT file distributed with this work for additional
|
||||
* information regarding copyright ownership.
|
||||
@@ -40,7 +40,6 @@
|
||||
#include <isc/file.h>
|
||||
#include <isc/hash.h>
|
||||
#include <isc/hex.h>
|
||||
#include <isc/managers.h>
|
||||
#include <isc/md.h>
|
||||
#include <isc/mem.h>
|
||||
#include <isc/mutex.h>
|
||||
@@ -145,7 +144,6 @@ static unsigned int nsigned = 0, nretained = 0, ndropped = 0;
|
||||
static unsigned int nverified = 0, nverifyfailed = 0;
|
||||
static const char *directory = NULL, *dsdir = NULL;
|
||||
static isc_mutex_t namelock, statslock;
|
||||
static isc_nm_t *netmgr = NULL;
|
||||
static isc_taskmgr_t *taskmgr = NULL;
|
||||
static dns_db_t *gdb; /* The database */
|
||||
static dns_dbversion_t *gversion; /* The database version */
|
||||
@@ -179,9 +177,8 @@ static bool remove_orphansigs = false;
|
||||
static bool remove_inactkeysigs = false;
|
||||
static bool output_dnssec_only = false;
|
||||
static bool output_stdout = false;
|
||||
static bool set_maxttl = false;
|
||||
bool set_maxttl = false;
|
||||
static dns_ttl_t maxttl = 0;
|
||||
static bool no_max_check = false;
|
||||
|
||||
#define INCSTAT(counter) \
|
||||
if (printstats) { \
|
||||
@@ -201,7 +198,7 @@ savezonecut(dns_fixedname_t *fzonecut, dns_name_t *name) {
|
||||
dns_name_t *result;
|
||||
|
||||
result = dns_fixedname_initname(fzonecut);
|
||||
dns_name_copy(name, result);
|
||||
dns_name_copynf(name, result);
|
||||
|
||||
return (result);
|
||||
}
|
||||
@@ -594,10 +591,10 @@ signset(dns_diff_t *del, dns_diff_t *add, dns_dbnode_t *node, dns_name_t *name,
|
||||
vbprintf(2, "\trrsig by %s dropped - %s\n",
|
||||
sigstr,
|
||||
expired ? "expired"
|
||||
: rrsig.originalttl != set->ttl
|
||||
? "ttl change"
|
||||
: "failed to "
|
||||
"verify");
|
||||
: rrsig.originalttl != set->ttl
|
||||
? "ttl change"
|
||||
: "failed to "
|
||||
"verify");
|
||||
resign = true;
|
||||
}
|
||||
} else if (!ispublishedkey(key) && remove_orphansigs) {
|
||||
@@ -615,10 +612,10 @@ signset(dns_diff_t *del, dns_diff_t *add, dns_dbnode_t *node, dns_name_t *name,
|
||||
vbprintf(2, "\trrsig by %s dropped - %s\n",
|
||||
sigstr,
|
||||
expired ? "expired"
|
||||
: rrsig.originalttl != set->ttl
|
||||
? "ttl change"
|
||||
: "failed to "
|
||||
"verify");
|
||||
: rrsig.originalttl != set->ttl
|
||||
? "ttl change"
|
||||
: "failed to "
|
||||
"verify");
|
||||
}
|
||||
} else if (!expired) {
|
||||
vbprintf(2, "\trrsig by %s retained\n", sigstr);
|
||||
@@ -1337,8 +1334,8 @@ get_soa_ttls(void) {
|
||||
result = dns_rdataset_first(&soaset);
|
||||
check_result(result, "dns_rdataset_first");
|
||||
dns_rdataset_current(&soaset, &rdata);
|
||||
zone_soa_min_ttl = dns_soa_getminimum(&rdata);
|
||||
soa_ttl = soaset.ttl;
|
||||
zone_soa_min_ttl = ISC_MIN(dns_soa_getminimum(&rdata), soa_ttl);
|
||||
if (set_maxttl) {
|
||||
zone_soa_min_ttl = ISC_MIN(zone_soa_min_ttl, maxttl);
|
||||
soa_ttl = ISC_MIN(soa_ttl, maxttl);
|
||||
@@ -1355,8 +1352,7 @@ setsoaserial(uint32_t serial, dns_updatemethod_t method) {
|
||||
dns_dbnode_t *node = NULL;
|
||||
dns_rdataset_t rdataset;
|
||||
dns_rdata_t rdata = DNS_RDATA_INIT;
|
||||
uint32_t old_serial, new_serial = 0;
|
||||
dns_updatemethod_t used = dns_updatemethod_none;
|
||||
uint32_t old_serial, new_serial;
|
||||
|
||||
result = dns_db_getoriginnode(gdb, &node);
|
||||
if (result != ISC_R_SUCCESS) {
|
||||
@@ -1380,20 +1376,16 @@ setsoaserial(uint32_t serial, dns_updatemethod_t method) {
|
||||
|
||||
if (method == dns_updatemethod_date ||
|
||||
method == dns_updatemethod_unixtime) {
|
||||
new_serial = dns_update_soaserial(old_serial, method, &used);
|
||||
new_serial = dns_update_soaserial(old_serial, method);
|
||||
} else if (serial != 0 || method == dns_updatemethod_none) {
|
||||
/* Set SOA serial to the value provided. */
|
||||
new_serial = serial;
|
||||
used = method;
|
||||
} else {
|
||||
new_serial = dns_update_soaserial(old_serial, method, &used);
|
||||
}
|
||||
|
||||
if (method != used) {
|
||||
fprintf(stderr,
|
||||
"%s: warning: Serial number would not advance, "
|
||||
"using increment method instead\n",
|
||||
program);
|
||||
/* Increment SOA serial using RFC 1982 arithmetic */
|
||||
new_serial = (old_serial + 1) & 0xFFFFFFFF;
|
||||
if (new_serial == 0) {
|
||||
new_serial = 1;
|
||||
}
|
||||
}
|
||||
|
||||
/* If the new serial is not likely to cause a zone transfer
|
||||
@@ -2397,7 +2389,7 @@ nsec3ify(unsigned int hashalg, dns_iterations_t iterations,
|
||||
break;
|
||||
}
|
||||
if (result == ISC_R_NOMORE) {
|
||||
dns_name_copy(gorigin, nextname);
|
||||
dns_name_copynf(gorigin, nextname);
|
||||
done = true;
|
||||
} else if (result != ISC_R_SUCCESS) {
|
||||
fatal("iterating through the database failed: %s",
|
||||
@@ -2534,7 +2526,7 @@ nsec3ify(unsigned int hashalg, dns_iterations_t iterations,
|
||||
break;
|
||||
}
|
||||
if (result == ISC_R_NOMORE) {
|
||||
dns_name_copy(gorigin, nextname);
|
||||
dns_name_copynf(gorigin, nextname);
|
||||
done = true;
|
||||
} else if (result != ISC_R_SUCCESS) {
|
||||
fatal("iterating through the database failed: %s",
|
||||
@@ -2731,13 +2723,10 @@ static void
|
||||
report(const char *format, ...) {
|
||||
if (!quiet) {
|
||||
FILE *out = output_stdout ? stderr : stdout;
|
||||
char buf[4096];
|
||||
va_list args;
|
||||
|
||||
va_start(args, format);
|
||||
vsnprintf(buf, sizeof(buf), format, args);
|
||||
vfprintf(out, format, args);
|
||||
va_end(args);
|
||||
fprintf(out, "%s\n", buf);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -3441,12 +3430,6 @@ main(int argc, char *argv[]) {
|
||||
|
||||
case 'H':
|
||||
set_iter = true;
|
||||
/* too-many is NOT DOCUMENTED */
|
||||
if (strcmp(isc_commandline_argument, "too-many") == 0) {
|
||||
nsec3iter = 151;
|
||||
no_max_check = true;
|
||||
break;
|
||||
}
|
||||
nsec3iter = strtoul(isc_commandline_argument, &endp, 0);
|
||||
if (*endp != '\0') {
|
||||
fatal("iterations must be numeric");
|
||||
@@ -3815,7 +3798,11 @@ main(int argc, char *argv[]) {
|
||||
* of keys rather early.
|
||||
*/
|
||||
ISC_LIST_INIT(keylist);
|
||||
isc_rwlock_init(&keylist_lock, 0, 0);
|
||||
result = isc_rwlock_init(&keylist_lock, 0, 0);
|
||||
if (result != ISC_R_SUCCESS) {
|
||||
fatal("could not initialize keylist_lock: %s",
|
||||
isc_result_totext(result));
|
||||
}
|
||||
|
||||
/*
|
||||
* Fill keylist with:
|
||||
@@ -3865,6 +3852,7 @@ main(int argc, char *argv[]) {
|
||||
warnifallksk(gdb);
|
||||
|
||||
if (IS_NSEC3) {
|
||||
unsigned int max;
|
||||
bool answer;
|
||||
|
||||
hash_length = dns_nsec3_hashlength(dns_hash_sha1);
|
||||
@@ -3883,15 +3871,12 @@ main(int argc, char *argv[]) {
|
||||
"NSEC-only DNSKEY");
|
||||
}
|
||||
|
||||
if (nsec3iter > dns_nsec3_maxiterations()) {
|
||||
if (no_max_check) {
|
||||
fprintf(stderr,
|
||||
"Ignoring max iterations check.\n");
|
||||
} else {
|
||||
fatal("NSEC3 iterations too big. Maximum "
|
||||
"iterations allowed %u.",
|
||||
dns_nsec3_maxiterations());
|
||||
}
|
||||
result = dns_nsec3_maxiterations(gdb, NULL, mctx, &max);
|
||||
check_result(result, "dns_nsec3_maxiterations()");
|
||||
if (nsec3iter > max) {
|
||||
fatal("NSEC3 iterations too big for weakest DNSKEY "
|
||||
"strength. Maximum iterations allowed %u.",
|
||||
max);
|
||||
}
|
||||
} else {
|
||||
hashlist_init(&hashlist, 0, 0); /* silence clang */
|
||||
@@ -3964,7 +3949,11 @@ main(int argc, char *argv[]) {
|
||||
print_time(outfp);
|
||||
print_version(outfp);
|
||||
|
||||
isc_managers_create(mctx, ntasks, 0, 0, &netmgr, &taskmgr, NULL, NULL);
|
||||
result = isc_taskmgr_create(mctx, ntasks, 0, NULL, &taskmgr);
|
||||
if (result != ISC_R_SUCCESS) {
|
||||
fatal("failed to create task manager: %s",
|
||||
isc_result_totext(result));
|
||||
}
|
||||
|
||||
master = NULL;
|
||||
result = isc_task_create(taskmgr, 0, &master);
|
||||
@@ -4015,7 +4004,7 @@ main(int argc, char *argv[]) {
|
||||
for (i = 0; i < (int)ntasks; i++) {
|
||||
isc_task_detach(&tasks[i]);
|
||||
}
|
||||
isc_managers_destroy(&netmgr, &taskmgr, NULL, NULL);
|
||||
isc_taskmgr_destroy(&taskmgr);
|
||||
isc_mem_put(mctx, tasks, ntasks * sizeof(isc_task_t *));
|
||||
postsign();
|
||||
TIME_NOW(&sign_finish);
|
||||
|
||||
@@ -3,7 +3,7 @@
|
||||
|
||||
This Source Code Form is subject to the terms of the Mozilla Public
|
||||
License, v. 2.0. If a copy of the MPL was not distributed with this
|
||||
file, you can obtain one at https://mozilla.org/MPL/2.0/.
|
||||
file, You can obtain one at http://mozilla.org/MPL/2.0/.
|
||||
|
||||
See the COPYRIGHT file distributed with this work for additional
|
||||
information regarding copyright ownership.
|
||||
@@ -69,9 +69,9 @@ Options
|
||||
This option specifies the hardware to use for cryptographic
|
||||
operations, such as a secure key store used for signing, when applicable.
|
||||
|
||||
When BIND 9 is built with OpenSSL, this needs to be set to the OpenSSL
|
||||
engine identifier that drives the cryptographic accelerator or
|
||||
hardware service module (usually ``pkcs11``). When BIND is
|
||||
When BIND is built with OpenSSL PKCS#11 support, this defaults to the
|
||||
string ``pkcs11``, which identifies an OpenSSL engine that can drive a
|
||||
cryptographic accelerator or hardware service module. When BIND is
|
||||
built with native PKCS#11 cryptography (``--enable-native-pkcs11``), it
|
||||
defaults to the path of the PKCS#11 provider library specified via
|
||||
``--with-pkcs11``.
|
||||
@@ -202,16 +202,10 @@ Options
|
||||
This format increments the SOA serial number using :rfc:`1982` arithmetic.
|
||||
|
||||
**unixtime**
|
||||
This format sets the SOA serial number to the number of seconds
|
||||
since the beginning of the Unix epoch, unless the serial
|
||||
number is already greater than or equal to that value, in
|
||||
which case it is simply incremented by one.
|
||||
This format sets the SOA serial number to the number of seconds since the beginning of the Unix epoch.
|
||||
|
||||
**date**
|
||||
This format sets the SOA serial number to today's date, in
|
||||
YYYYMMDDNN format, unless the serial number is already greater
|
||||
than or equal to that value, in which case it is simply
|
||||
incremented by one.
|
||||
This format sets the SOA serial number to today's date, in YYYYMMDDNN format.
|
||||
|
||||
``-o origin``
|
||||
This option sets the zone origin. If not specified, the name of the zone file is
|
||||
|
||||
@@ -3,7 +3,7 @@
|
||||
*
|
||||
* This Source Code Form is subject to the terms of the Mozilla Public
|
||||
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
||||
* file, you can obtain one at https://mozilla.org/MPL/2.0/.
|
||||
* file, You can obtain one at http://mozilla.org/MPL/2.0/.
|
||||
*
|
||||
* See the COPYRIGHT file distributed with this work for additional
|
||||
* information regarding copyright ownership.
|
||||
@@ -82,13 +82,10 @@ static bool keyset_kskonly = false;
|
||||
static void
|
||||
report(const char *format, ...) {
|
||||
if (!quiet) {
|
||||
char buf[4096];
|
||||
va_list args;
|
||||
|
||||
va_start(args, format);
|
||||
vsnprintf(buf, sizeof(buf), format, args);
|
||||
vfprintf(stdout, format, args);
|
||||
va_end(args);
|
||||
fprintf(stdout, "%s\n", buf);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -3,7 +3,7 @@
|
||||
|
||||
This Source Code Form is subject to the terms of the Mozilla Public
|
||||
License, v. 2.0. If a copy of the MPL was not distributed with this
|
||||
file, you can obtain one at https://mozilla.org/MPL/2.0/.
|
||||
file, You can obtain one at http://mozilla.org/MPL/2.0/.
|
||||
|
||||
See the COPYRIGHT file distributed with this work for additional
|
||||
information regarding copyright ownership.
|
||||
@@ -47,9 +47,9 @@ Options
|
||||
``-E engine``
|
||||
This option specifies the cryptographic hardware to use, when applicable.
|
||||
|
||||
When BIND 9 is built with OpenSSL, this needs to be set to the OpenSSL
|
||||
engine identifier that drives the cryptographic accelerator or
|
||||
hardware service module (usually ``pkcs11``). When BIND is
|
||||
When BIND is built with OpenSSL PKCS#11 support, this defaults to the
|
||||
string ``pkcs11``, which identifies an OpenSSL engine that can drive a
|
||||
cryptographic accelerator or hardware service module. When BIND is
|
||||
built with native PKCS#11 cryptography (``--enable-native-pkcs11``), it
|
||||
defaults to the path of the PKCS#11 provider library specified via
|
||||
``--with-pkcs11``.
|
||||
|
||||
@@ -3,7 +3,7 @@
|
||||
*
|
||||
* This Source Code Form is subject to the terms of the Mozilla Public
|
||||
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
||||
* file, you can obtain one at https://mozilla.org/MPL/2.0/.
|
||||
* file, You can obtain one at http://mozilla.org/MPL/2.0/.
|
||||
*
|
||||
* See the COPYRIGHT file distributed with this work for additional
|
||||
* information regarding copyright ownership.
|
||||
|
||||
@@ -3,7 +3,7 @@
|
||||
*
|
||||
* This Source Code Form is subject to the terms of the Mozilla Public
|
||||
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
||||
* file, you can obtain one at https://mozilla.org/MPL/2.0/.
|
||||
* file, You can obtain one at http://mozilla.org/MPL/2.0/.
|
||||
*
|
||||
* See the COPYRIGHT file distributed with this work for additional
|
||||
* information regarding copyright ownership.
|
||||
@@ -43,12 +43,8 @@ extern uint8_t dtype[8];
|
||||
|
||||
typedef void(fatalcallback_t)(void);
|
||||
|
||||
#ifndef CPPCHECK
|
||||
ISC_NORETURN void
|
||||
fatal(const char *format, ...) ISC_FORMAT_PRINTF(1, 2);
|
||||
#else /* CPPCHECK */
|
||||
#define fatal(...) exit(1)
|
||||
#endif
|
||||
|
||||
void
|
||||
setfatalcallback(fatalcallback_t *callback);
|
||||
|
||||
@@ -77,7 +77,7 @@
|
||||
<GenerateDebugInformation>true</GenerateDebugInformation>
|
||||
<OutputFile>..\..\..\Build\$(Configuration)\$(TargetName)$(TargetExt)</OutputFile>
|
||||
<AdditionalLibraryDirectories>$(Configuration);..\..\..\lib\isc\win32\$(Configuration);..\..\..\lib\dns\win32\$(Configuration);%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>
|
||||
<AdditionalDependencies>@OPENSSL_LIBCRYPTO@@OPENSSL_LIBSSL@dnssectool.lib;libisc.lib;libdns.lib;ws2_32.lib;%(AdditionalDependencies)</AdditionalDependencies>
|
||||
<AdditionalDependencies>@OPENSSL_LIB@dnssectool.lib;libisc.lib;libdns.lib;ws2_32.lib;%(AdditionalDependencies)</AdditionalDependencies>
|
||||
</Link>
|
||||
</ItemDefinitionGroup>
|
||||
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|@PLATFORM@'">
|
||||
@@ -109,7 +109,7 @@
|
||||
<OutputFile>..\..\..\Build\$(Configuration)\$(TargetName)$(TargetExt)</OutputFile>
|
||||
<LinkTimeCodeGeneration>Default</LinkTimeCodeGeneration>
|
||||
<AdditionalLibraryDirectories>$(Configuration);..\..\..\lib\isc\win32\$(Configuration);..\..\..\lib\dns\win32\$(Configuration);%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>
|
||||
<AdditionalDependencies>@OPENSSL_LIBCRYPTO@@OPENSSL_LIBSSL@dnssectool.lib;libisc.lib;libdns.lib;ws2_32.lib;%(AdditionalDependencies)</AdditionalDependencies>
|
||||
<AdditionalDependencies>@OPENSSL_LIB@dnssectool.lib;libisc.lib;libdns.lib;ws2_32.lib;%(AdditionalDependencies)</AdditionalDependencies>
|
||||
</Link>
|
||||
</ItemDefinitionGroup>
|
||||
<ItemGroup>
|
||||
|
||||
@@ -77,7 +77,7 @@
|
||||
<GenerateDebugInformation>true</GenerateDebugInformation>
|
||||
<OutputFile>..\..\..\Build\$(Configuration)\$(TargetName)$(TargetExt)</OutputFile>
|
||||
<AdditionalLibraryDirectories>$(Configuration);..\..\..\lib\isc\win32\$(Configuration);..\..\..\lib\dns\win32\$(Configuration);%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>
|
||||
<AdditionalDependencies>@OPENSSL_LIBCRYPTO@@OPENSSL_LIBSSL@dnssectool.lib;libisc.lib;libdns.lib;ws2_32.lib;%(AdditionalDependencies)</AdditionalDependencies>
|
||||
<AdditionalDependencies>@OPENSSL_LIB@dnssectool.lib;libisc.lib;libdns.lib;ws2_32.lib;%(AdditionalDependencies)</AdditionalDependencies>
|
||||
</Link>
|
||||
@IF PYTHON
|
||||
<PostBuildEvent>
|
||||
@@ -122,7 +122,7 @@ set PYTHONPATH=.
|
||||
<OutputFile>..\..\..\Build\$(Configuration)\$(TargetName)$(TargetExt)</OutputFile>
|
||||
<LinkTimeCodeGeneration>Default</LinkTimeCodeGeneration>
|
||||
<AdditionalLibraryDirectories>$(Configuration);..\..\..\lib\isc\win32\$(Configuration);..\..\..\lib\dns\win32\$(Configuration);%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>
|
||||
<AdditionalDependencies>@OPENSSL_LIBCRYPTO@@OPENSSL_LIBSSL@dnssectool.lib;libisc.lib;libdns.lib;ws2_32.lib;%(AdditionalDependencies)</AdditionalDependencies>
|
||||
<AdditionalDependencies>@OPENSSL_LIB@dnssectool.lib;libisc.lib;libdns.lib;ws2_32.lib;%(AdditionalDependencies)</AdditionalDependencies>
|
||||
</Link>
|
||||
@IF PYTHON
|
||||
<PostBuildEvent>
|
||||
|
||||
@@ -77,7 +77,7 @@
|
||||
<GenerateDebugInformation>true</GenerateDebugInformation>
|
||||
<OutputFile>..\..\..\Build\$(Configuration)\$(TargetName)$(TargetExt)</OutputFile>
|
||||
<AdditionalLibraryDirectories>$(Configuration);..\..\..\lib\isc\win32\$(Configuration);..\..\..\lib\dns\win32\$(Configuration);%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>
|
||||
<AdditionalDependencies>@OPENSSL_LIBCRYPTO@@OPENSSL_LIBSSL@dnssectool.lib;libisc.lib;libdns.lib;ws2_32.lib;%(AdditionalDependencies)</AdditionalDependencies>
|
||||
<AdditionalDependencies>@OPENSSL_LIB@dnssectool.lib;libisc.lib;libdns.lib;ws2_32.lib;%(AdditionalDependencies)</AdditionalDependencies>
|
||||
</Link>
|
||||
</ItemDefinitionGroup>
|
||||
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|@PLATFORM@'">
|
||||
@@ -109,7 +109,7 @@
|
||||
<OutputFile>..\..\..\Build\$(Configuration)\$(TargetName)$(TargetExt)</OutputFile>
|
||||
<LinkTimeCodeGeneration>Default</LinkTimeCodeGeneration>
|
||||
<AdditionalLibraryDirectories>$(Configuration);..\..\..\lib\isc\win32\$(Configuration);..\..\..\lib\dns\win32\$(Configuration);%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>
|
||||
<AdditionalDependencies>@OPENSSL_LIBCRYPTO@@OPENSSL_LIBSSL@dnssectool.lib;libisc.lib;libdns.lib;ws2_32.lib;%(AdditionalDependencies)</AdditionalDependencies>
|
||||
<AdditionalDependencies>@OPENSSL_LIB@dnssectool.lib;libisc.lib;libdns.lib;ws2_32.lib;%(AdditionalDependencies)</AdditionalDependencies>
|
||||
</Link>
|
||||
</ItemDefinitionGroup>
|
||||
<ItemGroup>
|
||||
|
||||
@@ -77,7 +77,7 @@
|
||||
<GenerateDebugInformation>true</GenerateDebugInformation>
|
||||
<OutputFile>..\..\..\Build\$(Configuration)\$(TargetName)$(TargetExt)</OutputFile>
|
||||
<AdditionalLibraryDirectories>$(Configuration);..\..\..\lib\isc\win32\$(Configuration);..\..\..\lib\dns\win32\$(Configuration);%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>
|
||||
<AdditionalDependencies>@OPENSSL_LIBCRYPTO@@OPENSSL_LIBSSL@dnssectool.lib;libisc.lib;libdns.lib;ws2_32.lib;%(AdditionalDependencies)</AdditionalDependencies>
|
||||
<AdditionalDependencies>@OPENSSL_LIB@dnssectool.lib;libisc.lib;libdns.lib;ws2_32.lib;%(AdditionalDependencies)</AdditionalDependencies>
|
||||
</Link>
|
||||
</ItemDefinitionGroup>
|
||||
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|@PLATFORM@'">
|
||||
@@ -109,7 +109,7 @@
|
||||
<OutputFile>..\..\..\Build\$(Configuration)\$(TargetName)$(TargetExt)</OutputFile>
|
||||
<LinkTimeCodeGeneration>Default</LinkTimeCodeGeneration>
|
||||
<AdditionalLibraryDirectories>$(Configuration);..\..\..\lib\isc\win32\$(Configuration);..\..\..\lib\dns\win32\$(Configuration);%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>
|
||||
<AdditionalDependencies>@OPENSSL_LIBCRYPTO@@OPENSSL_LIBSSL@dnssectool.lib;libisc.lib;libdns.lib;ws2_32.lib;%(AdditionalDependencies)</AdditionalDependencies>
|
||||
<AdditionalDependencies>@OPENSSL_LIB@dnssectool.lib;libisc.lib;libdns.lib;ws2_32.lib;%(AdditionalDependencies)</AdditionalDependencies>
|
||||
</Link>
|
||||
</ItemDefinitionGroup>
|
||||
<ItemGroup>
|
||||
|
||||
@@ -76,7 +76,7 @@
|
||||
<SubSystem>Console</SubSystem>
|
||||
<GenerateDebugInformation>true</GenerateDebugInformation>
|
||||
<OutputFile>..\..\..\Build\$(Configuration)\$(TargetName)$(TargetExt)</OutputFile>
|
||||
<AdditionalDependencies>@OPENSSL_LIBCRYPTO@@OPENSSL_LIBSSL@dnssectool.lib;libisc.lib;libisccfg.lib;libdns.lib;ws2_32.lib;%(AdditionalDependencies)</AdditionalDependencies>
|
||||
<AdditionalDependencies>@OPENSSL_LIB@dnssectool.lib;libisc.lib;libisccfg.lib;libdns.lib;ws2_32.lib;%(AdditionalDependencies)</AdditionalDependencies>
|
||||
<AdditionalLibraryDirectories>$(Configuration);..\..\..\lib\isc\win32\$(Configuration);..\..\..\lib\isccfg\win32\$(Configuration);..\..\..\lib\dns\win32\$(Configuration);%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>
|
||||
</Link>
|
||||
</ItemDefinitionGroup>
|
||||
@@ -108,7 +108,7 @@
|
||||
<OptimizeReferences>true</OptimizeReferences>
|
||||
<OutputFile>..\..\..\Build\$(Configuration)\$(TargetName)$(TargetExt)</OutputFile>
|
||||
<LinkTimeCodeGeneration>Default</LinkTimeCodeGeneration>
|
||||
<AdditionalDependencies>@OPENSSL_LIBCRYPTO@@OPENSSL_LIBSSL@dnssectool.lib;libisc.lib;libisccfg.lib;libdns.lib;ws2_32.lib;%(AdditionalDependencies)</AdditionalDependencies>
|
||||
<AdditionalDependencies>@OPENSSL_LIB@dnssectool.lib;libisc.lib;libisccfg.lib;libdns.lib;ws2_32.lib;%(AdditionalDependencies)</AdditionalDependencies>
|
||||
<AdditionalLibraryDirectories>$(Configuration);..\..\..\lib\isc\win32\$(Configuration);..\..\..\lib\isccfg\win32\$(Configuration);..\..\..\lib\dns\win32\$(Configuration);%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>
|
||||
</Link>
|
||||
</ItemDefinitionGroup>
|
||||
|
||||
@@ -77,7 +77,7 @@
|
||||
<GenerateDebugInformation>true</GenerateDebugInformation>
|
||||
<OutputFile>..\..\..\Build\$(Configuration)\$(TargetName)$(TargetExt)</OutputFile>
|
||||
<AdditionalLibraryDirectories>$(Configuration);..\..\..\lib\isc\win32\$(Configuration);..\..\..\lib\dns\win32\$(Configuration);%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>
|
||||
<AdditionalDependencies>@OPENSSL_LIBCRYPTO@@OPENSSL_LIBSSL@dnssectool.lib;libisc.lib;libdns.lib;ws2_32.lib;%(AdditionalDependencies)</AdditionalDependencies>
|
||||
<AdditionalDependencies>@OPENSSL_LIB@dnssectool.lib;libisc.lib;libdns.lib;ws2_32.lib;%(AdditionalDependencies)</AdditionalDependencies>
|
||||
</Link>
|
||||
</ItemDefinitionGroup>
|
||||
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|@PLATFORM@'">
|
||||
@@ -109,7 +109,7 @@
|
||||
<OutputFile>..\..\..\Build\$(Configuration)\$(TargetName)$(TargetExt)</OutputFile>
|
||||
<LinkTimeCodeGeneration>Default</LinkTimeCodeGeneration>
|
||||
<AdditionalLibraryDirectories>$(Configuration);..\..\..\lib\isc\win32\$(Configuration);..\..\..\lib\dns\win32\$(Configuration);%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>
|
||||
<AdditionalDependencies>@OPENSSL_LIBCRYPTO@@OPENSSL_LIBSSL@dnssectool.lib;libisc.lib;libdns.lib;ws2_32.lib;%(AdditionalDependencies)</AdditionalDependencies>
|
||||
<AdditionalDependencies>@OPENSSL_LIB@dnssectool.lib;libisc.lib;libdns.lib;ws2_32.lib;%(AdditionalDependencies)</AdditionalDependencies>
|
||||
</Link>
|
||||
</ItemDefinitionGroup>
|
||||
<ItemGroup>
|
||||
|
||||
@@ -76,7 +76,7 @@
|
||||
<SubSystem>Console</SubSystem>
|
||||
<GenerateDebugInformation>true</GenerateDebugInformation>
|
||||
<OutputFile>..\..\..\Build\$(Configuration)\$(TargetName)$(TargetExt)</OutputFile>
|
||||
<AdditionalDependencies>@OPENSSL_LIBCRYPTO@@OPENSSL_LIBSSL@dnssectool.lib;libisc.lib;libdns.lib;ws2_32.lib;%(AdditionalDependencies)</AdditionalDependencies>
|
||||
<AdditionalDependencies>@OPENSSL_LIB@dnssectool.lib;libisc.lib;libdns.lib;ws2_32.lib;%(AdditionalDependencies)</AdditionalDependencies>
|
||||
<AdditionalLibraryDirectories>$(Configuration);..\..\..\lib\isc\win32\$(Configuration);..\..\..\lib\dns\win32\$(Configuration);%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>
|
||||
</Link>
|
||||
</ItemDefinitionGroup>
|
||||
@@ -108,7 +108,7 @@
|
||||
<OptimizeReferences>true</OptimizeReferences>
|
||||
<OutputFile>..\..\..\Build\$(Configuration)\$(TargetName)$(TargetExt)</OutputFile>
|
||||
<LinkTimeCodeGeneration>Default</LinkTimeCodeGeneration>
|
||||
<AdditionalDependencies>@OPENSSL_LIBCRYPTO@@OPENSSL_LIBSSL@dnssectool.lib;libisc.lib;libdns.lib;ws2_32.lib;%(AdditionalDependencies)</AdditionalDependencies>
|
||||
<AdditionalDependencies>@OPENSSL_LIB@dnssectool.lib;libisc.lib;libdns.lib;ws2_32.lib;%(AdditionalDependencies)</AdditionalDependencies>
|
||||
<AdditionalLibraryDirectories>$(Configuration);..\..\..\lib\isc\win32\$(Configuration);..\..\..\lib\dns\win32\$(Configuration);%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>
|
||||
</Link>
|
||||
</ItemDefinitionGroup>
|
||||
|
||||
@@ -77,7 +77,7 @@
|
||||
<GenerateDebugInformation>true</GenerateDebugInformation>
|
||||
<OutputFile>..\..\..\Build\$(Configuration)\$(TargetName)$(TargetExt)</OutputFile>
|
||||
<AdditionalLibraryDirectories>$(Configuration);..\..\..\lib\isc\win32\$(Configuration);..\..\..\lib\dns\win32\$(Configuration);%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>
|
||||
<AdditionalDependencies>@OPENSSL_LIBCRYPTO@@OPENSSL_LIBSSL@dnssectool.lib;libisc.lib;libdns.lib;ws2_32.lib;%(AdditionalDependencies)</AdditionalDependencies>
|
||||
<AdditionalDependencies>@OPENSSL_LIB@dnssectool.lib;libisc.lib;libdns.lib;ws2_32.lib;%(AdditionalDependencies)</AdditionalDependencies>
|
||||
</Link>
|
||||
</ItemDefinitionGroup>
|
||||
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|@PLATFORM@'">
|
||||
@@ -109,7 +109,7 @@
|
||||
<OutputFile>..\..\..\Build\$(Configuration)\$(TargetName)$(TargetExt)</OutputFile>
|
||||
<LinkTimeCodeGeneration>Default</LinkTimeCodeGeneration>
|
||||
<AdditionalLibraryDirectories>$(Configuration);..\..\..\lib\isc\win32\$(Configuration);..\..\..\lib\dns\win32\$(Configuration);%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>
|
||||
<AdditionalDependencies>@OPENSSL_LIBCRYPTO@@OPENSSL_LIBSSL@dnssectool.lib;libisc.lib;libdns.lib;ws2_32.lib;%(AdditionalDependencies)</AdditionalDependencies>
|
||||
<AdditionalDependencies>@OPENSSL_LIB@dnssectool.lib;libisc.lib;libdns.lib;ws2_32.lib;%(AdditionalDependencies)</AdditionalDependencies>
|
||||
</Link>
|
||||
</ItemDefinitionGroup>
|
||||
<ItemGroup>
|
||||
|
||||
@@ -76,7 +76,7 @@
|
||||
<SubSystem>Console</SubSystem>
|
||||
<GenerateDebugInformation>true</GenerateDebugInformation>
|
||||
<OutputFile>..\..\..\Build\$(Configuration)\$(TargetName)$(TargetExt)</OutputFile>
|
||||
<AdditionalDependencies>@OPENSSL_LIBCRYPTO@@OPENSSL_LIBSSL@dnssectool.lib;libisc.lib;libdns.lib;ws2_32.lib;%(AdditionalDependencies)</AdditionalDependencies>
|
||||
<AdditionalDependencies>@OPENSSL_LIB@dnssectool.lib;libisc.lib;libdns.lib;ws2_32.lib;%(AdditionalDependencies)</AdditionalDependencies>
|
||||
<AdditionalLibraryDirectories>$(Configuration);..\..\..\lib\isc\win32\$(Configuration);..\..\..\lib\dns\win32\$(Configuration);%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>
|
||||
</Link>
|
||||
</ItemDefinitionGroup>
|
||||
@@ -108,7 +108,7 @@
|
||||
<OptimizeReferences>true</OptimizeReferences>
|
||||
<OutputFile>..\..\..\Build\$(Configuration)\$(TargetName)$(TargetExt)</OutputFile>
|
||||
<LinkTimeCodeGeneration>Default</LinkTimeCodeGeneration>
|
||||
<AdditionalDependencies>@OPENSSL_LIBCRYPTO@@OPENSSL_LIBSSL@dnssectool.lib;libisc.lib;libdns.lib;ws2_32.lib;%(AdditionalDependencies)</AdditionalDependencies>
|
||||
<AdditionalDependencies>@OPENSSL_LIB@dnssectool.lib;libisc.lib;libdns.lib;ws2_32.lib;%(AdditionalDependencies)</AdditionalDependencies>
|
||||
<AdditionalLibraryDirectories>$(Configuration);..\..\..\lib\isc\win32\$(Configuration);..\..\..\lib\dns\win32\$(Configuration);%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>
|
||||
</Link>
|
||||
</ItemDefinitionGroup>
|
||||
|
||||
@@ -9,12 +9,12 @@ AM_CPPFLAGS += \
|
||||
$(LIBISCCC_CFLAGS) \
|
||||
$(LIBISCCFG_CFLAGS) \
|
||||
$(LIBBIND9_CFLAGS) \
|
||||
$(LIBLTDL_CFLAGS) \
|
||||
$(OPENSSL_CFLAGS) \
|
||||
$(LIBCAP_CFLAGS) \
|
||||
$(LMDB_CFLAGS) \
|
||||
$(MAXMINDDB_CFLAGS) \
|
||||
$(DNSTAP_CFLAGS) \
|
||||
$(LIBUV_CFLAGS) \
|
||||
$(ZLIB_CFLAGS)
|
||||
|
||||
if HAVE_JSON_C
|
||||
@@ -59,7 +59,6 @@ named_SOURCES = \
|
||||
server.c \
|
||||
statschannel.c \
|
||||
tkeyconf.c \
|
||||
transportconf.c \
|
||||
tsigconf.c \
|
||||
zoneconf.c \
|
||||
unix/dlz_dlopen_driver.c \
|
||||
@@ -78,7 +77,6 @@ named_SOURCES = \
|
||||
include/named/smf_globals.h \
|
||||
include/named/statschannel.h \
|
||||
include/named/tkeyconf.h \
|
||||
include/named/transportconf.h \
|
||||
include/named/tsigconf.h \
|
||||
include/named/types.h \
|
||||
include/named/zoneconf.h \
|
||||
@@ -104,7 +102,6 @@ named_LDADD = \
|
||||
$(LMDB_LIBS) \
|
||||
$(MAXMINDDB_LIBS) \
|
||||
$(DNSTAP_LIBS) \
|
||||
$(LIBUV_LIBS) \
|
||||
$(LIBXML2_LIBS) \
|
||||
$(ZLIB_LIBS)
|
||||
|
||||
|
||||
+1
-1
@@ -4,7 +4,7 @@
|
||||
-
|
||||
- This Source Code Form is subject to the terms of the Mozilla Public
|
||||
- License, v. 2.0. If a copy of the MPL was not distributed with this
|
||||
- file, you can obtain one at https://mozilla.org/MPL/2.0/.
|
||||
- file, You can obtain one at http://mozilla.org/MPL/2.0/.
|
||||
-
|
||||
- See the COPYRIGHT file distributed with this work for additional
|
||||
- information regarding copyright ownership.
|
||||
|
||||
+26
-89
@@ -3,7 +3,7 @@
|
||||
*
|
||||
* This Source Code Form is subject to the terms of the Mozilla Public
|
||||
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
||||
* file, you can obtain one at https://mozilla.org/MPL/2.0/.
|
||||
* file, You can obtain one at http://mozilla.org/MPL/2.0/.
|
||||
*
|
||||
* See the COPYRIGHT file distributed with this work for additional
|
||||
* information regarding copyright ownership.
|
||||
@@ -33,21 +33,17 @@
|
||||
typedef struct builtin builtin_t;
|
||||
|
||||
static isc_result_t
|
||||
do_authors_lookup(dns_sdblookup_t *lookup);
|
||||
static isc_result_t
|
||||
do_dns64_lookup(dns_sdblookup_t *lookup);
|
||||
static isc_result_t
|
||||
do_empty_lookup(dns_sdblookup_t *lookup);
|
||||
do_version_lookup(dns_sdblookup_t *lookup);
|
||||
static isc_result_t
|
||||
do_hostname_lookup(dns_sdblookup_t *lookup);
|
||||
static isc_result_t
|
||||
do_authors_lookup(dns_sdblookup_t *lookup);
|
||||
static isc_result_t
|
||||
do_id_lookup(dns_sdblookup_t *lookup);
|
||||
static isc_result_t
|
||||
do_ipv4only_lookup(dns_sdblookup_t *lookup);
|
||||
do_empty_lookup(dns_sdblookup_t *lookup);
|
||||
static isc_result_t
|
||||
do_ipv4reverse_lookup(dns_sdblookup_t *lookup);
|
||||
static isc_result_t
|
||||
do_version_lookup(dns_sdblookup_t *lookup);
|
||||
do_dns64_lookup(dns_sdblookup_t *lookup);
|
||||
|
||||
/*
|
||||
* We can't use function pointers as the db_data directly
|
||||
@@ -61,14 +57,12 @@ struct builtin {
|
||||
char *contact;
|
||||
};
|
||||
|
||||
static builtin_t authors_builtin = { do_authors_lookup, NULL, NULL };
|
||||
static builtin_t dns64_builtin = { do_dns64_lookup, NULL, NULL };
|
||||
static builtin_t empty_builtin = { do_empty_lookup, NULL, NULL };
|
||||
static builtin_t hostname_builtin = { do_hostname_lookup, NULL, NULL };
|
||||
static builtin_t id_builtin = { do_id_lookup, NULL, NULL };
|
||||
static builtin_t ipv4only_builtin = { do_ipv4only_lookup, NULL, NULL };
|
||||
static builtin_t ipv4reverse_builtin = { do_ipv4reverse_lookup, NULL, NULL };
|
||||
static builtin_t version_builtin = { do_version_lookup, NULL, NULL };
|
||||
static builtin_t hostname_builtin = { do_hostname_lookup, NULL, NULL };
|
||||
static builtin_t authors_builtin = { do_authors_lookup, NULL, NULL };
|
||||
static builtin_t id_builtin = { do_id_lookup, NULL, NULL };
|
||||
static builtin_t empty_builtin = { do_empty_lookup, NULL, NULL };
|
||||
static builtin_t dns64_builtin = { do_dns64_lookup, NULL, NULL };
|
||||
|
||||
static dns_sdbimplementation_t *builtin_impl;
|
||||
static dns_sdbimplementation_t *dns64_impl;
|
||||
@@ -95,8 +89,7 @@ static const unsigned char hex16[256] = {
|
||||
1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1 /*F0*/
|
||||
};
|
||||
|
||||
static const unsigned char decimal[] = "0123456789";
|
||||
static const unsigned char ipv4only[] = "\010ipv4only\004arpa";
|
||||
const unsigned char decimal[] = "0123456789";
|
||||
|
||||
static size_t
|
||||
dns64_rdata(unsigned char *v, size_t start, unsigned char *rdata) {
|
||||
@@ -296,16 +289,6 @@ dns64_cname(const dns_name_t *zone, const dns_name_t *name,
|
||||
*/
|
||||
return (ISC_R_NOTFOUND);
|
||||
}
|
||||
|
||||
/*
|
||||
* Reverse of 192.0.0.170 or 192.0.0.171 maps to ipv4only.arpa.
|
||||
*/
|
||||
if ((v[0] == 170 || v[0] == 171) && v[1] == 0 && v[2] == 0 &&
|
||||
v[3] == 192) {
|
||||
return (dns_sdb_putrdata(lookup, dns_rdatatype_ptr, 3600,
|
||||
ipv4only, sizeof(ipv4only)));
|
||||
}
|
||||
|
||||
return (dns_sdb_putrdata(lookup, dns_rdatatype_cname, 600, rdata,
|
||||
(unsigned int)len));
|
||||
}
|
||||
@@ -446,30 +429,6 @@ do_empty_lookup(dns_sdblookup_t *lookup) {
|
||||
return (ISC_R_SUCCESS);
|
||||
}
|
||||
|
||||
static isc_result_t
|
||||
do_ipv4only_lookup(dns_sdblookup_t *lookup) {
|
||||
isc_result_t result;
|
||||
unsigned char data[2][4] = { { 192, 0, 0, 170 }, { 192, 0, 0, 171 } };
|
||||
|
||||
for (int i = 0; i < 2; i++) {
|
||||
result = dns_sdb_putrdata(lookup, dns_rdatatype_a, 3600,
|
||||
data[i], 4);
|
||||
if (result != ISC_R_SUCCESS) {
|
||||
return (result);
|
||||
}
|
||||
}
|
||||
return (ISC_R_SUCCESS);
|
||||
}
|
||||
|
||||
static isc_result_t
|
||||
do_ipv4reverse_lookup(dns_sdblookup_t *lookup) {
|
||||
isc_result_t result;
|
||||
|
||||
result = dns_sdb_putrdata(lookup, dns_rdatatype_ptr, 3600, ipv4only,
|
||||
sizeof(ipv4only));
|
||||
return (result);
|
||||
}
|
||||
|
||||
static isc_result_t
|
||||
builtin_authority(const char *zone, void *dbdata, dns_sdblookup_t *lookup) {
|
||||
isc_result_t result;
|
||||
@@ -513,10 +472,7 @@ builtin_create(const char *zone, int argc, char **argv, void *driverdata,
|
||||
UNUSED(zone);
|
||||
UNUSED(driverdata);
|
||||
|
||||
if (strcmp(argv[0], "dns64") == 0 || strcmp(argv[0], "empty") == 0 ||
|
||||
strcmp(argv[0], "ipv4only") == 0 ||
|
||||
strcmp(argv[0], "ipv4reverse") == 0)
|
||||
{
|
||||
if (strcmp(argv[0], "empty") == 0 || strcmp(argv[0], "dns64") == 0) {
|
||||
if (argc != 3) {
|
||||
return (DNS_R_SYNTAX);
|
||||
}
|
||||
@@ -524,27 +480,19 @@ builtin_create(const char *zone, int argc, char **argv, void *driverdata,
|
||||
return (DNS_R_SYNTAX);
|
||||
}
|
||||
|
||||
if (strcmp(argv[0], "authors") == 0) {
|
||||
*dbdata = &authors_builtin;
|
||||
if (strcmp(argv[0], "version") == 0) {
|
||||
*dbdata = &version_builtin;
|
||||
} else if (strcmp(argv[0], "hostname") == 0) {
|
||||
*dbdata = &hostname_builtin;
|
||||
} else if (strcmp(argv[0], "authors") == 0) {
|
||||
*dbdata = &authors_builtin;
|
||||
} else if (strcmp(argv[0], "id") == 0) {
|
||||
*dbdata = &id_builtin;
|
||||
} else if (strcmp(argv[0], "version") == 0) {
|
||||
*dbdata = &version_builtin;
|
||||
} else if (strcmp(argv[0], "dns64") == 0 ||
|
||||
strcmp(argv[0], "empty") == 0 ||
|
||||
strcmp(argv[0], "ipv4only") == 0 ||
|
||||
strcmp(argv[0], "ipv4reverse") == 0)
|
||||
{
|
||||
} else if (strcmp(argv[0], "empty") == 0 ||
|
||||
strcmp(argv[0], "dns64") == 0) {
|
||||
builtin_t *empty;
|
||||
char *server;
|
||||
char *contact;
|
||||
|
||||
if (argc != 3) {
|
||||
return (DNS_R_SYNTAX);
|
||||
}
|
||||
|
||||
/*
|
||||
* We don't want built-in zones to fail. Fallback to
|
||||
* the static configuration if memory allocation fails.
|
||||
@@ -553,14 +501,10 @@ builtin_create(const char *zone, int argc, char **argv, void *driverdata,
|
||||
server = isc_mem_strdup(named_g_mctx, argv[1]);
|
||||
contact = isc_mem_strdup(named_g_mctx, argv[2]);
|
||||
if (empty == NULL || server == NULL || contact == NULL) {
|
||||
if (strcmp(argv[0], "dns64") == 0) {
|
||||
*dbdata = &dns64_builtin;
|
||||
} else if (strcmp(argv[0], "empty") == 0) {
|
||||
if (strcmp(argv[0], "empty") == 0) {
|
||||
*dbdata = &empty_builtin;
|
||||
} else if (strcmp(argv[0], "ipv4only") == 0) {
|
||||
*dbdata = &ipv4only_builtin;
|
||||
} else {
|
||||
*dbdata = &ipv4reverse_builtin;
|
||||
*dbdata = &dns64_builtin;
|
||||
}
|
||||
if (server != NULL) {
|
||||
isc_mem_free(named_g_mctx, server);
|
||||
@@ -573,17 +517,11 @@ builtin_create(const char *zone, int argc, char **argv, void *driverdata,
|
||||
sizeof(*empty));
|
||||
}
|
||||
} else {
|
||||
if (strcmp(argv[0], "dns64") == 0) {
|
||||
memmove(empty, &dns64_builtin,
|
||||
sizeof(empty_builtin));
|
||||
} else if (strcmp(argv[0], "empty") == 0) {
|
||||
if (strcmp(argv[0], "empty") == 0) {
|
||||
memmove(empty, &empty_builtin,
|
||||
sizeof(empty_builtin));
|
||||
} else if (strcmp(argv[0], "ipv4only") == 0) {
|
||||
memmove(empty, &ipv4only_builtin,
|
||||
sizeof(empty_builtin));
|
||||
} else {
|
||||
memmove(empty, &ipv4reverse_builtin,
|
||||
memmove(empty, &dns64_builtin,
|
||||
sizeof(empty_builtin));
|
||||
}
|
||||
empty->server = server;
|
||||
@@ -606,10 +544,9 @@ builtin_destroy(const char *zone, void *driverdata, void **dbdata) {
|
||||
/*
|
||||
* Don't free the static versions.
|
||||
*/
|
||||
if (*dbdata == &authors_builtin || *dbdata == &dns64_builtin ||
|
||||
*dbdata == &empty_builtin || *dbdata == &hostname_builtin ||
|
||||
*dbdata == &id_builtin || *dbdata == &ipv4only_builtin ||
|
||||
*dbdata == &ipv4reverse_builtin || *dbdata == &version_builtin)
|
||||
if (*dbdata == &version_builtin || *dbdata == &hostname_builtin ||
|
||||
*dbdata == &authors_builtin || *dbdata == &id_builtin ||
|
||||
*dbdata == &empty_builtin || *dbdata == &dns64_builtin)
|
||||
{
|
||||
return;
|
||||
}
|
||||
|
||||
+153
-166
@@ -3,7 +3,7 @@
|
||||
*
|
||||
* This Source Code Form is subject to the terms of the Mozilla Public
|
||||
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
||||
* file, you can obtain one at https://mozilla.org/MPL/2.0/.
|
||||
* file, You can obtain one at http://mozilla.org/MPL/2.0/.
|
||||
*
|
||||
* See the COPYRIGHT file distributed with this work for additional
|
||||
* information regarding copyright ownership.
|
||||
@@ -59,7 +59,7 @@ options {\n\
|
||||
# directory <none>\n\
|
||||
dnssec-policy \"none\";\n\
|
||||
dump-file \"named_dump.db\";\n\
|
||||
edns-udp-size 1232;\n\
|
||||
edns-udp-size 4096;\n\
|
||||
# fake-iquery <obsolete>;\n"
|
||||
#ifndef WIN32
|
||||
" files unlimited;\n"
|
||||
@@ -83,7 +83,7 @@ options {\n\
|
||||
match-mapped-addresses no;\n\
|
||||
max-ixfr-ratio 100%;\n\
|
||||
max-rsa-exponent-size 0; /* no limit */\n\
|
||||
max-udp-size 1232;\n\
|
||||
max-udp-size 4096;\n\
|
||||
memstatistics-file \"named.memstats\";\n\
|
||||
# multiple-cnames <obsolete>;\n\
|
||||
# named-xfer <obsolete>;\n\
|
||||
@@ -93,9 +93,6 @@ options {\n\
|
||||
nta-recheck 300;\n\
|
||||
# pid-file \"" NAMED_LOCALSTATEDIR "/run/named/named.pid\"; \n\
|
||||
port 53;\n\
|
||||
tls-port 853;\n\
|
||||
http-port 80;\n\
|
||||
https-port 443;\n\
|
||||
prefetch 2 9;\n\
|
||||
recursing-file \"named.recursing\";\n\
|
||||
recursive-clients 1000;\n\
|
||||
@@ -123,8 +120,6 @@ options {\n\
|
||||
tcp-initial-timeout 300;\n\
|
||||
tcp-keepalive-timeout 300;\n\
|
||||
tcp-listen-queue 10;\n\
|
||||
tcp-receive-buffer 0;\n\
|
||||
tcp-send-buffer 0;\n\
|
||||
# tkey-dhkey <none>\n\
|
||||
# tkey-domain <none>\n\
|
||||
# tkey-gssapi-credential <none>\n\
|
||||
@@ -135,8 +130,7 @@ options {\n\
|
||||
# treat-cr-as-space <obsolete>;\n\
|
||||
trust-anchor-telemetry yes;\n\
|
||||
# use-id-pool <obsolete>;\n\
|
||||
udp-receive-buffer 0;\n\
|
||||
udp-send-buffer 0;\n\
|
||||
# use-ixfr <obsolete>;\n\
|
||||
\n\
|
||||
/* view */\n\
|
||||
allow-new-zones no;\n\
|
||||
@@ -146,6 +140,7 @@ options {\n\
|
||||
allow-recursion { localnets; localhost; };\n\
|
||||
allow-recursion-on { any; };\n\
|
||||
allow-update-forwarding {none;};\n\
|
||||
# allow-v6-synthesis <obsolete>;\n\
|
||||
auth-nxdomain false;\n\
|
||||
check-dup-records warn;\n\
|
||||
check-mx warn;\n\
|
||||
@@ -174,8 +169,8 @@ options {\n\
|
||||
max-clients-per-query 100;\n\
|
||||
max-ncache-ttl 10800; /* 3 hours */\n\
|
||||
max-recursion-depth 7;\n\
|
||||
max-recursion-queries 100;\n\
|
||||
max-stale-ttl 86400; /* 1 day */\n\
|
||||
max-recursion-queries 75;\n\
|
||||
max-stale-ttl 43200; /* 12 hours */\n\
|
||||
message-compression yes;\n\
|
||||
min-ncache-ttl 0; /* 0 hours */\n\
|
||||
min-cache-ttl 0; /* 0 seconds */\n\
|
||||
@@ -199,11 +194,8 @@ options {\n\
|
||||
root-key-sentinel yes;\n\
|
||||
servfail-ttl 1;\n\
|
||||
# sortlist <none>\n\
|
||||
stale-answer-client-timeout off;\n\
|
||||
stale-answer-enable false;\n\
|
||||
stale-answer-ttl 30; /* 30 seconds */\n\
|
||||
stale-cache-enable false;\n\
|
||||
stale-refresh-time 30; /* 30 seconds */\n\
|
||||
stale-answer-ttl 1; /* 1 second */\n\
|
||||
synth-from-dnssec no;\n\
|
||||
# topology <none>\n\
|
||||
transfer-format many-answers;\n\
|
||||
@@ -229,7 +221,7 @@ options {\n\
|
||||
dnssec-update-mode maintain;\n\
|
||||
# forward <none>\n\
|
||||
# forwarders <none>\n\
|
||||
# inline-signing no;\n\
|
||||
inline-signing no;\n\
|
||||
ixfr-from-differences false;\n\
|
||||
# maintain-ixfr-base <obsolete>;\n\
|
||||
# max-ixfr-log-size <obsolete>\n\
|
||||
@@ -504,7 +496,7 @@ named_config_getiplist(const cfg_obj_t *config, const cfg_obj_t *list,
|
||||
} else if (defport != 0) {
|
||||
port = defport;
|
||||
} else {
|
||||
result = named_config_getport(config, "port", &port);
|
||||
result = named_config_getport(config, &port);
|
||||
if (result != ISC_R_SUCCESS) {
|
||||
return (result);
|
||||
}
|
||||
@@ -614,76 +606,10 @@ named_config_getprimariesdef(const cfg_obj_t *cctx, const char *name,
|
||||
return (result);
|
||||
}
|
||||
|
||||
static isc_result_t
|
||||
named_config_getname(isc_mem_t *mctx, const cfg_obj_t *obj,
|
||||
dns_name_t **namep) {
|
||||
REQUIRE(namep != NULL && *namep == NULL);
|
||||
|
||||
const char *objstr;
|
||||
isc_result_t result;
|
||||
isc_buffer_t b;
|
||||
dns_fixedname_t fname;
|
||||
|
||||
if (!cfg_obj_isstring(obj)) {
|
||||
*namep = NULL;
|
||||
return (ISC_R_SUCCESS);
|
||||
}
|
||||
|
||||
*namep = isc_mem_get(mctx, sizeof(**namep));
|
||||
dns_name_init(*namep, NULL);
|
||||
|
||||
objstr = cfg_obj_asstring(obj);
|
||||
isc_buffer_constinit(&b, objstr, strlen(objstr));
|
||||
isc_buffer_add(&b, strlen(objstr));
|
||||
dns_fixedname_init(&fname);
|
||||
result = dns_name_fromtext(dns_fixedname_name(&fname), &b, dns_rootname,
|
||||
0, NULL);
|
||||
if (result != ISC_R_SUCCESS) {
|
||||
isc_mem_put(mctx, *namep, sizeof(**namep));
|
||||
*namep = NULL;
|
||||
return (result);
|
||||
}
|
||||
dns_name_dup(dns_fixedname_name(&fname), mctx, *namep);
|
||||
|
||||
return (ISC_R_SUCCESS);
|
||||
}
|
||||
|
||||
#define grow_array(mctx, array, newlen, oldlen) \
|
||||
if (newlen >= oldlen) { \
|
||||
size_t newsize = (newlen + 16) * sizeof(array[0]); \
|
||||
size_t oldsize = oldlen * sizeof(array[0]); \
|
||||
void *tmp = isc_mem_get(mctx, newsize); \
|
||||
memset(tmp, 0, newsize); \
|
||||
if (oldlen != 0) { \
|
||||
memmove(tmp, array, oldsize); \
|
||||
isc_mem_put(mctx, array, oldsize); \
|
||||
} \
|
||||
array = tmp; \
|
||||
oldlen = newlen + 16; \
|
||||
}
|
||||
|
||||
#define shrink_array(mctx, array, newlen, oldlen) \
|
||||
if (newlen < oldlen) { \
|
||||
void *tmp = NULL; \
|
||||
size_t newsize = newlen * sizeof(array[0]); \
|
||||
size_t oldsize = oldlen * sizeof(array[0]); \
|
||||
if (newlen != 0) { \
|
||||
tmp = isc_mem_get(mctx, newsize); \
|
||||
memset(tmp, 0, newsize); \
|
||||
memmove(tmp, array, newsize); \
|
||||
} else { \
|
||||
tmp = NULL; \
|
||||
} \
|
||||
isc_mem_put(mctx, array, oldsize); \
|
||||
array = tmp; \
|
||||
oldlen = newlen; \
|
||||
}
|
||||
|
||||
isc_result_t
|
||||
named_config_getipandkeylist(const cfg_obj_t *config, const cfg_obj_t *list,
|
||||
isc_mem_t *mctx, dns_ipkeylist_t *ipkl) {
|
||||
uint32_t addrcount = 0, dscpcount = 0, keycount = 0, tlscount = 0,
|
||||
i = 0;
|
||||
uint32_t addrcount = 0, dscpcount = 0, keycount = 0, i = 0;
|
||||
uint32_t listcount = 0, l = 0, j;
|
||||
uint32_t stackcount = 0, pushed = 0;
|
||||
isc_result_t result;
|
||||
@@ -691,14 +617,12 @@ named_config_getipandkeylist(const cfg_obj_t *config, const cfg_obj_t *list,
|
||||
const cfg_obj_t *addrlist;
|
||||
const cfg_obj_t *portobj;
|
||||
const cfg_obj_t *dscpobj;
|
||||
in_port_t port = (in_port_t)0;
|
||||
in_port_t def_port;
|
||||
in_port_t def_tlsport;
|
||||
in_port_t port;
|
||||
isc_dscp_t dscp = -1;
|
||||
dns_fixedname_t fname;
|
||||
isc_sockaddr_t *addrs = NULL;
|
||||
isc_dscp_t *dscps = NULL;
|
||||
dns_name_t **keys = NULL;
|
||||
dns_name_t **tlss = NULL;
|
||||
struct {
|
||||
const char *name;
|
||||
} *lists = NULL;
|
||||
@@ -712,7 +636,6 @@ named_config_getipandkeylist(const cfg_obj_t *config, const cfg_obj_t *list,
|
||||
REQUIRE(ipkl->count == 0);
|
||||
REQUIRE(ipkl->addrs == NULL);
|
||||
REQUIRE(ipkl->keys == NULL);
|
||||
REQUIRE(ipkl->tlss == NULL);
|
||||
REQUIRE(ipkl->dscps == NULL);
|
||||
REQUIRE(ipkl->labels == NULL);
|
||||
REQUIRE(ipkl->allocated == 0);
|
||||
@@ -720,12 +643,7 @@ named_config_getipandkeylist(const cfg_obj_t *config, const cfg_obj_t *list,
|
||||
/*
|
||||
* Get system defaults.
|
||||
*/
|
||||
result = named_config_getport(config, "port", &def_port);
|
||||
if (result != ISC_R_SUCCESS) {
|
||||
goto cleanup;
|
||||
}
|
||||
|
||||
result = named_config_getport(config, "tls-port", &def_tlsport);
|
||||
result = named_config_getport(config, &port);
|
||||
if (result != ISC_R_SUCCESS) {
|
||||
goto cleanup;
|
||||
}
|
||||
@@ -769,20 +687,33 @@ resume:
|
||||
for (; element != NULL; element = cfg_list_next(element)) {
|
||||
const cfg_obj_t *addr;
|
||||
const cfg_obj_t *key;
|
||||
const cfg_obj_t *tls;
|
||||
const char *keystr;
|
||||
isc_buffer_t b;
|
||||
|
||||
addr = cfg_tuple_get(cfg_listelt_value(element),
|
||||
"primarieselement");
|
||||
key = cfg_tuple_get(cfg_listelt_value(element), "key");
|
||||
tls = cfg_tuple_get(cfg_listelt_value(element), "tls");
|
||||
|
||||
if (!cfg_obj_issockaddr(addr)) {
|
||||
const char *listname = cfg_obj_asstring(addr);
|
||||
isc_result_t tresult;
|
||||
|
||||
/* Grow lists? */
|
||||
grow_array(mctx, lists, l, listcount);
|
||||
if (listcount == l) {
|
||||
void *tmp;
|
||||
uint32_t newlen = listcount + 16;
|
||||
size_t newsize, oldsize;
|
||||
|
||||
newsize = newlen * sizeof(*lists);
|
||||
oldsize = listcount * sizeof(*lists);
|
||||
tmp = isc_mem_get(mctx, newsize);
|
||||
if (listcount != 0) {
|
||||
memmove(tmp, lists, oldsize);
|
||||
isc_mem_put(mctx, lists, oldsize);
|
||||
}
|
||||
lists = tmp;
|
||||
listcount = newlen;
|
||||
}
|
||||
/* Seen? */
|
||||
for (j = 0; j < l; j++) {
|
||||
if (strcasecmp(lists[j].name, listname) == 0) {
|
||||
@@ -808,7 +739,21 @@ resume:
|
||||
}
|
||||
lists[l++].name = listname;
|
||||
/* Grow stack? */
|
||||
grow_array(mctx, stack, pushed, stackcount);
|
||||
if (stackcount == pushed) {
|
||||
void *tmp;
|
||||
uint32_t newlen = stackcount + 16;
|
||||
size_t newsize, oldsize;
|
||||
|
||||
newsize = newlen * sizeof(*stack);
|
||||
oldsize = stackcount * sizeof(*stack);
|
||||
tmp = isc_mem_get(mctx, newsize);
|
||||
if (stackcount != 0) {
|
||||
memmove(tmp, stack, oldsize);
|
||||
isc_mem_put(mctx, stack, oldsize);
|
||||
}
|
||||
stack = tmp;
|
||||
stackcount = newlen;
|
||||
}
|
||||
/*
|
||||
* We want to resume processing this list on the
|
||||
* next element.
|
||||
@@ -820,44 +765,68 @@ resume:
|
||||
goto newlist;
|
||||
}
|
||||
|
||||
grow_array(mctx, addrs, i, addrcount);
|
||||
grow_array(mctx, dscps, i, dscpcount);
|
||||
grow_array(mctx, keys, i, keycount);
|
||||
grow_array(mctx, tlss, i, tlscount);
|
||||
if (i == addrcount) {
|
||||
void *tmp;
|
||||
uint32_t newlen = addrcount + 16;
|
||||
size_t newsize, oldsize;
|
||||
|
||||
newsize = newlen * sizeof(isc_sockaddr_t);
|
||||
oldsize = addrcount * sizeof(isc_sockaddr_t);
|
||||
tmp = isc_mem_get(mctx, newsize);
|
||||
if (addrcount != 0) {
|
||||
memmove(tmp, addrs, oldsize);
|
||||
isc_mem_put(mctx, addrs, oldsize);
|
||||
}
|
||||
addrs = tmp;
|
||||
addrcount = newlen;
|
||||
|
||||
newsize = newlen * sizeof(isc_dscp_t);
|
||||
oldsize = dscpcount * sizeof(isc_dscp_t);
|
||||
tmp = isc_mem_get(mctx, newsize);
|
||||
if (dscpcount != 0) {
|
||||
memmove(tmp, dscps, oldsize);
|
||||
isc_mem_put(mctx, dscps, oldsize);
|
||||
}
|
||||
dscps = tmp;
|
||||
dscpcount = newlen;
|
||||
|
||||
newsize = newlen * sizeof(dns_name_t *);
|
||||
oldsize = keycount * sizeof(dns_name_t *);
|
||||
tmp = isc_mem_get(mctx, newsize);
|
||||
if (keycount != 0) {
|
||||
memmove(tmp, keys, oldsize);
|
||||
isc_mem_put(mctx, keys, oldsize);
|
||||
}
|
||||
keys = tmp;
|
||||
keycount = newlen;
|
||||
}
|
||||
|
||||
addrs[i] = *cfg_obj_assockaddr(addr);
|
||||
if (isc_sockaddr_getport(&addrs[i]) == 0) {
|
||||
isc_sockaddr_setport(&addrs[i], port);
|
||||
}
|
||||
dscps[i] = cfg_obj_getdscp(addr);
|
||||
if (dscps[i] == -1) {
|
||||
dscps[i] = dscp;
|
||||
}
|
||||
keys[i] = NULL;
|
||||
i++; /* Increment here so that cleanup on error works. */
|
||||
if (!cfg_obj_isstring(key)) {
|
||||
continue;
|
||||
}
|
||||
keys[i - 1] = isc_mem_get(mctx, sizeof(dns_name_t));
|
||||
dns_name_init(keys[i - 1], NULL);
|
||||
|
||||
result = named_config_getname(mctx, key, &keys[i]);
|
||||
keystr = cfg_obj_asstring(key);
|
||||
isc_buffer_constinit(&b, keystr, strlen(keystr));
|
||||
isc_buffer_add(&b, strlen(keystr));
|
||||
dns_fixedname_init(&fname);
|
||||
result = dns_name_fromtext(dns_fixedname_name(&fname), &b,
|
||||
dns_rootname, 0, NULL);
|
||||
if (result != ISC_R_SUCCESS) {
|
||||
i++; /* Increment here so that cleanup on error works.
|
||||
*/
|
||||
goto cleanup;
|
||||
}
|
||||
|
||||
result = named_config_getname(mctx, tls, &tlss[i]);
|
||||
if (result != ISC_R_SUCCESS) {
|
||||
i++; /* Increment here so that cleanup on error works.
|
||||
*/
|
||||
goto cleanup;
|
||||
}
|
||||
|
||||
/* Set the default port or tls-port */
|
||||
if (port == 0) {
|
||||
if (tlss[i] != NULL) {
|
||||
port = def_tlsport;
|
||||
} else {
|
||||
port = def_port;
|
||||
}
|
||||
}
|
||||
|
||||
if (isc_sockaddr_getport(&addrs[i]) == 0) {
|
||||
isc_sockaddr_setport(&addrs[i], port);
|
||||
}
|
||||
i++;
|
||||
dns_name_dup(dns_fixedname_name(&fname), mctx, keys[i - 1]);
|
||||
}
|
||||
if (pushed != 0) {
|
||||
pushed--;
|
||||
@@ -866,28 +835,61 @@ resume:
|
||||
dscp = stack[pushed].dscp;
|
||||
goto resume;
|
||||
}
|
||||
if (i < addrcount) {
|
||||
void *tmp;
|
||||
size_t newsize, oldsize;
|
||||
|
||||
shrink_array(mctx, addrs, i, addrcount);
|
||||
shrink_array(mctx, dscps, i, dscpcount);
|
||||
shrink_array(mctx, keys, i, keycount);
|
||||
shrink_array(mctx, tlss, i, tlscount);
|
||||
newsize = i * sizeof(isc_sockaddr_t);
|
||||
oldsize = addrcount * sizeof(isc_sockaddr_t);
|
||||
if (i != 0) {
|
||||
tmp = isc_mem_get(mctx, newsize);
|
||||
memmove(tmp, addrs, newsize);
|
||||
} else {
|
||||
tmp = NULL;
|
||||
}
|
||||
isc_mem_put(mctx, addrs, oldsize);
|
||||
addrs = tmp;
|
||||
addrcount = i;
|
||||
|
||||
newsize = i * sizeof(isc_dscp_t);
|
||||
oldsize = dscpcount * sizeof(isc_dscp_t);
|
||||
if (i != 0) {
|
||||
tmp = isc_mem_get(mctx, newsize);
|
||||
memmove(tmp, dscps, newsize);
|
||||
} else {
|
||||
tmp = NULL;
|
||||
}
|
||||
isc_mem_put(mctx, dscps, oldsize);
|
||||
dscps = tmp;
|
||||
dscpcount = i;
|
||||
|
||||
newsize = i * sizeof(dns_name_t *);
|
||||
oldsize = keycount * sizeof(dns_name_t *);
|
||||
if (i != 0) {
|
||||
tmp = isc_mem_get(mctx, newsize);
|
||||
memmove(tmp, keys, newsize);
|
||||
} else {
|
||||
tmp = NULL;
|
||||
}
|
||||
isc_mem_put(mctx, keys, oldsize);
|
||||
keys = tmp;
|
||||
keycount = i;
|
||||
}
|
||||
|
||||
if (lists != NULL) {
|
||||
isc_mem_put(mctx, lists, listcount * sizeof(lists[0]));
|
||||
isc_mem_put(mctx, lists, listcount * sizeof(*lists));
|
||||
}
|
||||
if (stack != NULL) {
|
||||
isc_mem_put(mctx, stack, stackcount * sizeof(stack[0]));
|
||||
isc_mem_put(mctx, stack, stackcount * sizeof(*stack));
|
||||
}
|
||||
|
||||
INSIST(dscpcount == addrcount);
|
||||
INSIST(keycount == addrcount);
|
||||
INSIST(tlscount == addrcount);
|
||||
INSIST(keycount == dscpcount);
|
||||
|
||||
ipkl->addrs = addrs;
|
||||
ipkl->dscps = dscps;
|
||||
ipkl->keys = keys;
|
||||
ipkl->tlss = tlss;
|
||||
ipkl->count = addrcount;
|
||||
ipkl->allocated = addrcount;
|
||||
|
||||
@@ -895,10 +897,10 @@ resume:
|
||||
|
||||
cleanup:
|
||||
if (addrs != NULL) {
|
||||
isc_mem_put(mctx, addrs, addrcount * sizeof(addrs[0]));
|
||||
isc_mem_put(mctx, addrs, addrcount * sizeof(isc_sockaddr_t));
|
||||
}
|
||||
if (dscps != NULL) {
|
||||
isc_mem_put(mctx, dscps, dscpcount * sizeof(dscps[0]));
|
||||
isc_mem_put(mctx, dscps, dscpcount * sizeof(isc_dscp_t));
|
||||
}
|
||||
if (keys != NULL) {
|
||||
for (j = 0; j < i; j++) {
|
||||
@@ -908,34 +910,21 @@ cleanup:
|
||||
if (dns_name_dynamic(keys[j])) {
|
||||
dns_name_free(keys[j], mctx);
|
||||
}
|
||||
isc_mem_put(mctx, keys[j], sizeof(*keys[j]));
|
||||
isc_mem_put(mctx, keys[j], sizeof(dns_name_t));
|
||||
}
|
||||
isc_mem_put(mctx, keys, keycount * sizeof(keys[0]));
|
||||
}
|
||||
if (tlss != NULL) {
|
||||
for (j = 0; j < i; j++) {
|
||||
if (tlss[j] == NULL) {
|
||||
continue;
|
||||
}
|
||||
if (dns_name_dynamic(tlss[j])) {
|
||||
dns_name_free(tlss[j], mctx);
|
||||
}
|
||||
isc_mem_put(mctx, tlss[j], sizeof(*tlss[j]));
|
||||
}
|
||||
isc_mem_put(mctx, tlss, tlscount * sizeof(tlss[0]));
|
||||
isc_mem_put(mctx, keys, keycount * sizeof(dns_name_t *));
|
||||
}
|
||||
if (lists != NULL) {
|
||||
isc_mem_put(mctx, lists, listcount * sizeof(lists[0]));
|
||||
isc_mem_put(mctx, lists, listcount * sizeof(*lists));
|
||||
}
|
||||
if (stack != NULL) {
|
||||
isc_mem_put(mctx, stack, stackcount * sizeof(stack[0]));
|
||||
isc_mem_put(mctx, stack, stackcount * sizeof(*stack));
|
||||
}
|
||||
return (result);
|
||||
}
|
||||
|
||||
isc_result_t
|
||||
named_config_getport(const cfg_obj_t *config, const char *type,
|
||||
in_port_t *portp) {
|
||||
named_config_getport(const cfg_obj_t *config, in_port_t *portp) {
|
||||
const cfg_obj_t *maps[3];
|
||||
const cfg_obj_t *options = NULL;
|
||||
const cfg_obj_t *portobj = NULL;
|
||||
@@ -950,7 +939,7 @@ named_config_getport(const cfg_obj_t *config, const char *type,
|
||||
maps[i++] = named_g_defaults;
|
||||
maps[i] = NULL;
|
||||
|
||||
result = named_config_get(maps, type, &portobj);
|
||||
result = named_config_get(maps, "port", &portobj);
|
||||
INSIST(result == ISC_R_SUCCESS);
|
||||
if (cfg_obj_asuint32(portobj) >= UINT16_MAX) {
|
||||
cfg_obj_log(portobj, named_g_lctx, ISC_LOG_ERROR,
|
||||
@@ -990,15 +979,13 @@ named_config_getdscp(const cfg_obj_t *config, isc_dscp_t *dscpp) {
|
||||
|
||||
struct keyalgorithms {
|
||||
const char *str;
|
||||
enum {
|
||||
hmacnone,
|
||||
hmacmd5,
|
||||
hmacsha1,
|
||||
hmacsha224,
|
||||
hmacsha256,
|
||||
hmacsha384,
|
||||
hmacsha512
|
||||
} hmac;
|
||||
enum { hmacnone,
|
||||
hmacmd5,
|
||||
hmacsha1,
|
||||
hmacsha224,
|
||||
hmacsha256,
|
||||
hmacsha384,
|
||||
hmacsha512 } hmac;
|
||||
unsigned int type;
|
||||
uint16_t size;
|
||||
} algorithms[] = { { "hmac-md5", hmacmd5, DST_ALG_HMACMD5, 128 },
|
||||
|
||||
+5
-3
@@ -3,7 +3,7 @@
|
||||
*
|
||||
* This Source Code Form is subject to the terms of the Mozilla Public
|
||||
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
||||
* file, you can obtain one at https://mozilla.org/MPL/2.0/.
|
||||
* file, You can obtain one at http://mozilla.org/MPL/2.0/.
|
||||
*
|
||||
* See the COPYRIGHT file distributed with this work for additional
|
||||
* information regarding copyright ownership.
|
||||
@@ -183,7 +183,8 @@ named_control_docommand(isccc_sexpr_t *message, bool readonly,
|
||||
/* Do not flush master files */
|
||||
named_server_flushonshutdown(named_g_server, false);
|
||||
named_os_shutdownmsg(cmdline, *text);
|
||||
result = ISC_R_SHUTTINGDOWN;
|
||||
isc_app_shutdown();
|
||||
result = ISC_R_SUCCESS;
|
||||
} else if (command_compare(command, NAMED_COMMAND_STOP)) {
|
||||
/*
|
||||
* "stop" is the same as "halt" except it does
|
||||
@@ -200,7 +201,8 @@ named_control_docommand(isccc_sexpr_t *message, bool readonly,
|
||||
#endif /* ifdef HAVE_LIBSCF */
|
||||
named_server_flushonshutdown(named_g_server, true);
|
||||
named_os_shutdownmsg(cmdline, *text);
|
||||
result = ISC_R_SHUTTINGDOWN;
|
||||
isc_app_shutdown();
|
||||
result = ISC_R_SUCCESS;
|
||||
} else if (command_compare(command, NAMED_COMMAND_ADDZONE) ||
|
||||
command_compare(command, NAMED_COMMAND_MODZONE))
|
||||
{
|
||||
|
||||
+527
-471
File diff suppressed because it is too large
Load Diff
+1
-1
@@ -3,7 +3,7 @@
|
||||
*
|
||||
* This Source Code Form is subject to the terms of the Mozilla Public
|
||||
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
||||
* file, you can obtain one at https://mozilla.org/MPL/2.0/.
|
||||
* file, You can obtain one at http://mozilla.org/MPL/2.0/.
|
||||
*
|
||||
* See the COPYRIGHT file distributed with this work for additional
|
||||
* information regarding copyright ownership.
|
||||
|
||||
+1
-1
@@ -3,7 +3,7 @@
|
||||
*
|
||||
* This Source Code Form is subject to the terms of the Mozilla Public
|
||||
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
||||
* file, you can obtain one at https://mozilla.org/MPL/2.0/.
|
||||
* file, You can obtain one at http://mozilla.org/MPL/2.0/.
|
||||
*
|
||||
* See the COPYRIGHT file distributed with this work for additional
|
||||
* information regarding copyright ownership.
|
||||
|
||||
@@ -3,7 +3,7 @@
|
||||
*
|
||||
* This Source Code Form is subject to the terms of the Mozilla Public
|
||||
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
||||
* file, you can obtain one at https://mozilla.org/MPL/2.0/.
|
||||
* file, You can obtain one at http://mozilla.org/MPL/2.0/.
|
||||
*
|
||||
* See the COPYRIGHT file distributed with this work for additional
|
||||
* information regarding copyright ownership.
|
||||
|
||||
@@ -3,7 +3,7 @@
|
||||
*
|
||||
* This Source Code Form is subject to the terms of the Mozilla Public
|
||||
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
||||
* file, you can obtain one at https://mozilla.org/MPL/2.0/.
|
||||
* file, You can obtain one at http://mozilla.org/MPL/2.0/.
|
||||
*
|
||||
* See the COPYRIGHT file distributed with this work for additional
|
||||
* information regarding copyright ownership.
|
||||
|
||||
@@ -3,7 +3,7 @@
|
||||
*
|
||||
* This Source Code Form is subject to the terms of the Mozilla Public
|
||||
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
||||
* file, you can obtain one at https://mozilla.org/MPL/2.0/.
|
||||
* file, You can obtain one at http://mozilla.org/MPL/2.0/.
|
||||
*
|
||||
* See the COPYRIGHT file distributed with this work for additional
|
||||
* information regarding copyright ownership.
|
||||
@@ -67,8 +67,7 @@ named_config_getipandkeylist(const cfg_obj_t *config, const cfg_obj_t *list,
|
||||
isc_mem_t *mctx, dns_ipkeylist_t *ipkl);
|
||||
|
||||
isc_result_t
|
||||
named_config_getport(const cfg_obj_t *config, const char *type,
|
||||
in_port_t *portp);
|
||||
named_config_getport(const cfg_obj_t *config, in_port_t *portp);
|
||||
|
||||
isc_result_t
|
||||
named_config_getkeyalgorithm(const char *str, const dns_name_t **name,
|
||||
|
||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user