Compare commits
1
Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
c65d26855e |
+29
-1
@@ -27,10 +27,38 @@ gen.dSYM/
|
|||||||
.deps/
|
.deps/
|
||||||
.dirstamp
|
.dirstamp
|
||||||
.libs/
|
.libs/
|
||||||
|
unit/atf-src/atf-c++/atf-c++.pc
|
||||||
|
unit/atf-src/atf-c/atf-c.pc
|
||||||
|
unit/atf-src/atf-c/defs.h
|
||||||
|
unit/atf-src/atf-c/detail/process_helpers
|
||||||
|
unit/atf-src/atf-config/atf-config
|
||||||
|
unit/atf-src/atf-report/atf-report
|
||||||
|
unit/atf-src/atf-report/fail_helper
|
||||||
|
unit/atf-src/atf-report/misc_helpers
|
||||||
|
unit/atf-src/atf-report/pass_helper
|
||||||
|
unit/atf-src/atf-run/atf-run
|
||||||
|
unit/atf-src/atf-run/bad_metadata_helper
|
||||||
|
unit/atf-src/atf-run/expect_helpers
|
||||||
|
unit/atf-src/atf-run/misc_helpers
|
||||||
|
unit/atf-src/atf-run/pass_helper
|
||||||
|
unit/atf-src/atf-run/several_tcs_helper
|
||||||
|
unit/atf-src/atf-run/zero_tcs_helper
|
||||||
|
unit/atf-src/atf-sh/atf-check
|
||||||
|
unit/atf-src/atf-sh/atf-sh
|
||||||
|
unit/atf-src/atf-sh/misc_helpers
|
||||||
|
unit/atf-src/atf-version/atf-version
|
||||||
|
unit/atf-src/atf-version/revision.h
|
||||||
|
unit/atf-src/atf-version/revision.h.stamp
|
||||||
|
unit/atf-src/bconfig.h
|
||||||
|
unit/atf-src/bootstrap/atconfig
|
||||||
|
unit/atf-src/doc/atf.7
|
||||||
|
unit/atf-src/stamp-h1
|
||||||
|
unit/atf-src/test-programs/c_helpers
|
||||||
|
unit/atf-src/test-programs/cpp_helpers
|
||||||
|
unit/atf-src/test-programs/sh_helpers
|
||||||
# ccc-analyzer store its results in .plist directories
|
# ccc-analyzer store its results in .plist directories
|
||||||
*.plist/
|
*.plist/
|
||||||
*~
|
*~
|
||||||
.project
|
.project
|
||||||
.cproject
|
.cproject
|
||||||
.settings
|
.settings
|
||||||
kyua.log
|
|
||||||
+47
-119
@@ -10,7 +10,6 @@ stages:
|
|||||||
- precheck
|
- precheck
|
||||||
- build
|
- build
|
||||||
- test
|
- test
|
||||||
- push
|
|
||||||
|
|
||||||
.centos-centos6-amd64: ¢os_centos6_amd64_image
|
.centos-centos6-amd64: ¢os_centos6_amd64_image
|
||||||
image: "$CI_REGISTRY_IMAGE:centos-centos6-amd64"
|
image: "$CI_REGISTRY_IMAGE:centos-centos6-amd64"
|
||||||
@@ -116,11 +115,9 @@ stages:
|
|||||||
- test -w "${CCACHE_DIR}" && export PATH="/usr/lib/ccache:${PATH}"
|
- test -w "${CCACHE_DIR}" && export PATH="/usr/lib/ccache:${PATH}"
|
||||||
# - ./autogen.sh
|
# - ./autogen.sh
|
||||||
script:
|
script:
|
||||||
- ./configure --enable-developer --with-libtool --disable-static --with-cmocka --prefix=$HOME/.local --without-make-clean $EXTRA_CONFIGURE || cat config.log
|
- ./configure --enable-developer --with-libtool --disable-static --with-atf=/usr --prefix=$HOME/.local --without-make-clean $EXTRA_CONFIGURE || cat config.log
|
||||||
- make -j${PARALLEL_JOBS_BUILD:-1} -k all V=1
|
- make -j${PARALLEL_JOBS_BUILD:-1} -k all V=1
|
||||||
artifacts:
|
artifacts:
|
||||||
paths:
|
|
||||||
- doc/
|
|
||||||
expire_in: '1 hour'
|
expire_in: '1 hour'
|
||||||
untracked: true
|
untracked: true
|
||||||
|
|
||||||
@@ -156,13 +153,14 @@ stages:
|
|||||||
- kyua report-html --force --results-file kyua.results --results-filter "" --output kyua_html
|
- kyua report-html --force --results-file kyua.results --results-filter "" --output kyua_html
|
||||||
artifacts:
|
artifacts:
|
||||||
paths:
|
paths:
|
||||||
|
- atf.out
|
||||||
- kyua.log
|
- kyua.log
|
||||||
- kyua.results
|
- kyua.results
|
||||||
- kyua_html/
|
- kyua_html/
|
||||||
expire_in: '1 week'
|
expire_in: '1 week'
|
||||||
when: on_failure
|
when: on_failure
|
||||||
|
|
||||||
sid:amd64:precheck:
|
precheck:debian:sid:amd64:
|
||||||
<<: *debian_sid_amd64_image
|
<<: *debian_sid_amd64_image
|
||||||
stage: precheck
|
stage: precheck
|
||||||
script:
|
script:
|
||||||
@@ -182,43 +180,15 @@ sid:amd64:precheck:
|
|||||||
expire_in: '1 week'
|
expire_in: '1 week'
|
||||||
when: on_failure
|
when: on_failure
|
||||||
|
|
||||||
🐞:sid:amd64:precheck:
|
#build:debian:jessie:amd64:
|
||||||
<<: *debian_sid_amd64_image
|
|
||||||
stage: precheck
|
|
||||||
script: util/check-cocci
|
|
||||||
|
|
||||||
docs:sid:amd64:
|
|
||||||
<<: *debian_sid_amd64_image
|
|
||||||
stage: test
|
|
||||||
dependencies:
|
|
||||||
- sid:amd64:build
|
|
||||||
script:
|
|
||||||
- make -C doc/misc docbook
|
|
||||||
- make -C doc/arm Bv9ARM.html
|
|
||||||
artifacts:
|
|
||||||
paths:
|
|
||||||
- doc/arm/
|
|
||||||
expire_in: '1 month'
|
|
||||||
|
|
||||||
docs:push:
|
|
||||||
<<: *debian_sid_amd64_image
|
|
||||||
stage: push
|
|
||||||
dependencies: []
|
|
||||||
script:
|
|
||||||
- curl -X POST -F token=$GITLAB_PAGES_DOCS_TRIGGER_TOKEN -F ref=master $GITLAB_PAGES_DOCS_TRIGGER_URL
|
|
||||||
only:
|
|
||||||
- master@isc-projects/bind9
|
|
||||||
- /^v9_.*$/@isc-projects/bind9
|
|
||||||
|
|
||||||
#jessie:amd64:build:
|
|
||||||
# <<: *debian_jessie_amd64_image
|
# <<: *debian_jessie_amd64_image
|
||||||
# <<: *build_job
|
# <<: *build_job
|
||||||
#
|
#
|
||||||
#build:jessie:i386:
|
#build:debian:jessie:i386:
|
||||||
# <<: *debian_jessie_i386_image
|
# <<: *debian_jessie_i386_image
|
||||||
# <<: *build_job
|
# <<: *build_job
|
||||||
#
|
#
|
||||||
#build:stretch:amd64:
|
#build:debian:stretch:amd64:
|
||||||
# <<: *debian_stretch_amd64_image
|
# <<: *debian_stretch_amd64_image
|
||||||
# <<: *build_job
|
# <<: *build_job
|
||||||
#
|
#
|
||||||
@@ -234,7 +204,7 @@ docs:push:
|
|||||||
# <<: *ubuntu_xenial_i386_image
|
# <<: *ubuntu_xenial_i386_image
|
||||||
# <<: *build_job
|
# <<: *build_job
|
||||||
|
|
||||||
centos6:amd64:build:
|
build:centos:centos6:amd64:
|
||||||
variables:
|
variables:
|
||||||
CC: gcc
|
CC: gcc
|
||||||
CFLAGS: "-Wall -Wextra -O2 -g"
|
CFLAGS: "-Wall -Wextra -O2 -g"
|
||||||
@@ -242,7 +212,7 @@ centos6:amd64:build:
|
|||||||
<<: *centos_centos6_amd64_image
|
<<: *centos_centos6_amd64_image
|
||||||
<<: *build_job
|
<<: *build_job
|
||||||
|
|
||||||
centos7:amd64:build:
|
build:centos:centos7:amd64:
|
||||||
variables:
|
variables:
|
||||||
CC: gcc
|
CC: gcc
|
||||||
CFLAGS: "-Wall -Wextra -O2 -g"
|
CFLAGS: "-Wall -Wextra -O2 -g"
|
||||||
@@ -250,29 +220,28 @@ centos7:amd64:build:
|
|||||||
<<: *centos_centos7_amd64_image
|
<<: *centos_centos7_amd64_image
|
||||||
<<: *build_job
|
<<: *build_job
|
||||||
|
|
||||||
clang:stretch:amd64:build:
|
build:clang:debian:stretch:amd64:
|
||||||
variables:
|
variables:
|
||||||
CC: clang
|
CC: clang
|
||||||
CFLAGS: "-Wall -Wextra -Wenum-conversion -O2 -g"
|
CFLAGS: "-Wall -Wextra -Wenum-conversion -O2 -g"
|
||||||
<<: *debian_stretch_amd64_image
|
<<: *debian_stretch_amd64_image
|
||||||
<<: *build_job
|
<<: *build_job
|
||||||
|
|
||||||
jessie:amd64:build:
|
build:debian:jessie:amd64:
|
||||||
variables:
|
variables:
|
||||||
CC: gcc
|
CC: gcc
|
||||||
CFLAGS: "-Wall -Wextra -O2 -g"
|
CFLAGS: "-Wall -Wextra -O2 -g"
|
||||||
EXTRA_CONFIGURE: --without-cmocka
|
|
||||||
<<: *debian_jessie_amd64_image
|
<<: *debian_jessie_amd64_image
|
||||||
<<: *build_job
|
<<: *build_job
|
||||||
|
|
||||||
stretch:amd64:build:
|
build:debian:stretch:amd64:
|
||||||
variables:
|
variables:
|
||||||
CC: gcc
|
CC: gcc
|
||||||
CFLAGS: "-Wall -Wextra -O2 -g"
|
CFLAGS: "-Wall -Wextra -O2 -g"
|
||||||
<<: *debian_stretch_amd64_image
|
<<: *debian_stretch_amd64_image
|
||||||
<<: *build_job
|
<<: *build_job
|
||||||
|
|
||||||
sid:amd64:build:
|
build:debian:sid:amd64:
|
||||||
variables:
|
variables:
|
||||||
CC: gcc
|
CC: gcc
|
||||||
CFLAGS: "-Wall -Wextra -O2 -g"
|
CFLAGS: "-Wall -Wextra -O2 -g"
|
||||||
@@ -280,23 +249,14 @@ sid:amd64:build:
|
|||||||
<<: *debian_sid_amd64_image
|
<<: *debian_sid_amd64_image
|
||||||
<<: *build_job
|
<<: *build_job
|
||||||
|
|
||||||
asan:sid:amd64:build:
|
build:clang:debian:stretch:i386:
|
||||||
variables:
|
|
||||||
CC: gcc
|
|
||||||
CFLAGS: "-Wall -Wextra -O2 -g -fsanitize=address,undefined -DISC_MEM_USE_INTERNAL_MALLOC=0"
|
|
||||||
LDFLAGS: "-fsanitize=address,undefined"
|
|
||||||
EXTRA_CONFIGURE: "--with-libidn2"
|
|
||||||
<<: *debian_sid_amd64_image
|
|
||||||
<<: *build_job
|
|
||||||
|
|
||||||
clang:stretch:i386:build:
|
|
||||||
variables:
|
variables:
|
||||||
CC: clang
|
CC: clang
|
||||||
CFLAGS: "-Wall -Wextra -Wenum-conversion -O2 -g"
|
CFLAGS: "-Wall -Wextra -Wenum-conversion -O2 -g"
|
||||||
<<: *debian_stretch_i386_image
|
<<: *debian_stretch_i386_image
|
||||||
<<: *build_job
|
<<: *build_job
|
||||||
|
|
||||||
sid:i386:build:
|
build:debian:sid:i386:
|
||||||
variables:
|
variables:
|
||||||
CC: gcc
|
CC: gcc
|
||||||
CFLAGS: "-Wall -Wextra -O2 -g"
|
CFLAGS: "-Wall -Wextra -O2 -g"
|
||||||
@@ -304,103 +264,91 @@ sid:i386:build:
|
|||||||
<<: *debian_sid_i386_image
|
<<: *debian_sid_i386_image
|
||||||
<<: *build_job
|
<<: *build_job
|
||||||
|
|
||||||
unit:centos6:amd64:
|
unittest:centos:centos6:amd64:
|
||||||
<<: *centos_centos6_amd64_image
|
<<: *centos_centos6_amd64_image
|
||||||
<<: *unit_test_job
|
<<: *unit_test_job
|
||||||
dependencies:
|
dependencies:
|
||||||
- centos6:amd64:build
|
- build:centos:centos6:amd64
|
||||||
|
|
||||||
unit:centos7:amd64:
|
unittest:centos:centos7:amd64:
|
||||||
<<: *centos_centos7_amd64_image
|
<<: *centos_centos7_amd64_image
|
||||||
<<: *unit_test_job
|
<<: *unit_test_job
|
||||||
dependencies:
|
dependencies:
|
||||||
- centos7:amd64:build
|
- build:centos:centos7:amd64
|
||||||
|
|
||||||
unit:jessie:amd64:
|
unittest:debian:jessie:amd64:
|
||||||
<<: *debian_jessie_amd64_image
|
<<: *debian_jessie_amd64_image
|
||||||
<<: *unit_test_job
|
<<: *unit_test_job
|
||||||
dependencies:
|
dependencies:
|
||||||
- jessie:amd64:build
|
- build:debian:jessie:amd64
|
||||||
|
|
||||||
unit:stretch:amd64:
|
unittest:debian:stretch:amd64:
|
||||||
<<: *debian_stretch_amd64_image
|
<<: *debian_stretch_amd64_image
|
||||||
<<: *unit_test_job
|
<<: *unit_test_job
|
||||||
dependencies:
|
dependencies:
|
||||||
- stretch:amd64:build
|
- build:debian:stretch:amd64
|
||||||
|
|
||||||
unit:sid:amd64:
|
unittest:debian:sid:amd64:
|
||||||
<<: *debian_sid_amd64_image
|
<<: *debian_sid_amd64_image
|
||||||
<<: *unit_test_job
|
<<: *unit_test_job
|
||||||
dependencies:
|
dependencies:
|
||||||
- sid:amd64:build
|
- build:debian:sid:amd64
|
||||||
|
|
||||||
unit:asan:sid:amd64:
|
unittest:clang:debian:stretch:amd64:
|
||||||
<<: *debian_sid_amd64_image
|
|
||||||
<<: *unit_test_job
|
|
||||||
dependencies:
|
|
||||||
- asan:sid:amd64:build
|
|
||||||
|
|
||||||
unit:clang:stretch:amd64:
|
|
||||||
<<: *debian_stretch_amd64_image
|
<<: *debian_stretch_amd64_image
|
||||||
<<: *unit_test_job
|
<<: *unit_test_job
|
||||||
dependencies:
|
dependencies:
|
||||||
- clang:stretch:amd64:build
|
- build:clang:debian:stretch:amd64
|
||||||
|
|
||||||
unit:sid:i386:
|
unittest:debian:sid:i386:
|
||||||
<<: *debian_sid_i386_image
|
<<: *debian_sid_i386_image
|
||||||
<<: *unit_test_job
|
<<: *unit_test_job
|
||||||
dependencies:
|
dependencies:
|
||||||
- sid:i386:build
|
- build:debian:sid:i386
|
||||||
|
|
||||||
system:centos6:amd64:
|
systemtest:centos:centos6:amd64:
|
||||||
<<: *centos_centos6_amd64_image
|
<<: *centos_centos6_amd64_image
|
||||||
<<: *system_test_job
|
<<: *system_test_job
|
||||||
dependencies:
|
dependencies:
|
||||||
- centos6:amd64:build
|
- build:centos:centos6:amd64
|
||||||
|
|
||||||
system:centos7:amd64:
|
systemtest:centos:centos7:amd64:
|
||||||
<<: *centos_centos7_amd64_image
|
<<: *centos_centos7_amd64_image
|
||||||
<<: *system_test_job
|
<<: *system_test_job
|
||||||
dependencies:
|
dependencies:
|
||||||
- centos7:amd64:build
|
- build:centos:centos7:amd64
|
||||||
|
|
||||||
system:jessie:amd64:
|
systemtest:debian:jessie:amd64:
|
||||||
<<: *debian_jessie_amd64_image
|
<<: *debian_jessie_amd64_image
|
||||||
<<: *system_test_job
|
<<: *system_test_job
|
||||||
dependencies:
|
dependencies:
|
||||||
- jessie:amd64:build
|
- build:debian:jessie:amd64
|
||||||
|
|
||||||
system:stretch:amd64:
|
systemtest:debian:stretch:amd64:
|
||||||
<<: *debian_stretch_amd64_image
|
<<: *debian_stretch_amd64_image
|
||||||
<<: *system_test_job
|
<<: *system_test_job
|
||||||
dependencies:
|
dependencies:
|
||||||
- stretch:amd64:build
|
- build:debian:stretch:amd64
|
||||||
|
|
||||||
system:sid:amd64:
|
systemtest:debian:sid:amd64:
|
||||||
<<: *debian_sid_amd64_image
|
<<: *debian_sid_amd64_image
|
||||||
<<: *system_test_job
|
<<: *system_test_job
|
||||||
dependencies:
|
dependencies:
|
||||||
- sid:amd64:build
|
- build:debian:sid:amd64
|
||||||
|
|
||||||
system:asan:sid:amd64:
|
systemtest:debian:sid:i386:
|
||||||
<<: *debian_sid_amd64_image
|
|
||||||
<<: *system_test_job
|
|
||||||
dependencies:
|
|
||||||
- asan:sid:amd64:build
|
|
||||||
|
|
||||||
system:sid:i386:
|
|
||||||
<<: *debian_sid_i386_image
|
<<: *debian_sid_i386_image
|
||||||
<<: *system_test_job
|
<<: *system_test_job
|
||||||
dependencies:
|
dependencies:
|
||||||
- sid:i386:build
|
- build:debian:sid:i386
|
||||||
|
|
||||||
install:sid:amd64:
|
install:debian:sid:amd64:
|
||||||
<<: *debian_sid_amd64_image
|
<<: *debian_sid_amd64_image
|
||||||
<<: *install_test_job
|
<<: *install_test_job
|
||||||
dependencies:
|
dependencies:
|
||||||
- sid:amd64:build
|
- build:debian:sid:amd64
|
||||||
|
|
||||||
pkcs11:sid:amd64:build:
|
pkcs11:build:debian:sid:amd64:
|
||||||
variables:
|
variables:
|
||||||
CC: gcc
|
CC: gcc
|
||||||
CFLAGS: "-Wall -Wextra -O2 -g"
|
CFLAGS: "-Wall -Wextra -O2 -g"
|
||||||
@@ -408,34 +356,14 @@ pkcs11:sid:amd64:build:
|
|||||||
<<: *debian_sid_amd64_image
|
<<: *debian_sid_amd64_image
|
||||||
<<: *build_job
|
<<: *build_job
|
||||||
|
|
||||||
pkcs11:unit:sid:amd64:
|
pkcs11:unittest:debian:sid:amd64:
|
||||||
<<: *debian_sid_amd64_image
|
<<: *debian_sid_amd64_image
|
||||||
<<: *unit_test_job
|
<<: *unit_test_job
|
||||||
dependencies:
|
dependencies:
|
||||||
- pkcs11:sid:amd64:build
|
- pkcs11:build:debian:sid:amd64
|
||||||
|
|
||||||
pkcs11:system:sid:amd64:
|
pkcs11:systemtest:debian:sid:amd64:
|
||||||
<<: *debian_sid_amd64_image
|
<<: *debian_sid_amd64_image
|
||||||
<<: *system_test_job
|
<<: *system_test_job
|
||||||
dependencies:
|
dependencies:
|
||||||
- pkcs11:sid:amd64:build
|
- pkcs11:build:debian:sid:amd64
|
||||||
|
|
||||||
noassert:sid:amd64:build:
|
|
||||||
variables:
|
|
||||||
CC: gcc
|
|
||||||
CFLAGS: "-Wall -Wextra -O2 -g -DISC_CHECK_NONE=1"
|
|
||||||
EXTRA_CONFIGURE: "--with-libidn2"
|
|
||||||
<<: *debian_sid_amd64_image
|
|
||||||
<<: *build_job
|
|
||||||
|
|
||||||
noassert:unit:sid:amd64:
|
|
||||||
<<: *debian_sid_amd64_image
|
|
||||||
<<: *unit_test_job
|
|
||||||
dependencies:
|
|
||||||
- noassert:sid:amd64:build
|
|
||||||
|
|
||||||
noassert:system:sid:amd64:
|
|
||||||
<<: *debian_sid_amd64_image
|
|
||||||
<<: *system_test_job
|
|
||||||
dependencies:
|
|
||||||
- noassert:sid:amd64:build
|
|
||||||
|
|||||||
@@ -0,0 +1,29 @@
|
|||||||
|
##Release Checklist
|
||||||
|
|
||||||
|
- [ ] Check for the presence of a milestone for the release
|
||||||
|
- If there is a milestone, are all the issues for the milestone resolved? (other than this checklist)
|
||||||
|
- [ ] Prepare the sources for tarball generation
|
||||||
|
- [ ] Change software version and library versions in configure.in
|
||||||
|
- [ ] Update CHANGES
|
||||||
|
- [ ] Ensure the release notes are correct for this release
|
||||||
|
- [ ] Ensure the metainformation is correct for this release
|
||||||
|
- [ ] Make sure the tests are passing
|
||||||
|
- [ ] Create a tag (name vX_Y_Z[-alphatag], content BIND X.Y.Z[-alphatag], signed with a developer's GPG key): git tag -u <DEVELOPER_KEYID> -a -s -m "BIND X.Y.Z" vX.Y.Z
|
||||||
|
- [ ] Push the changes and tag
|
||||||
|
- [ ] Create the tarball
|
||||||
|
- [ ] Create the Windows zips
|
||||||
|
- [ ] Ask QA to sanity check the tarball and zips
|
||||||
|
- [ ] Request the signature on the tarballs
|
||||||
|
- [ ] Make tarballs and signatures available to download
|
||||||
|
- [ ] Edit the release https://gitlab.isc.org/isc-projects/bind9/tags and the NEWS snippet + links to the tarballs
|
||||||
|
- [ ] Update DEB and RPM packages
|
||||||
|
|
||||||
|
##Communication
|
||||||
|
|
||||||
|
- [ ] Inform support to upload to the web site (nice to give them a heads-up in advance)
|
||||||
|
Write release e-mail to bind9-announce, bind-users in case of a major release
|
||||||
|
- [ ] Inform marketing to announce the release
|
||||||
|
Post short note to Twitter
|
||||||
|
Update http://en.wikipedia.org/wiki/BIND (mktg)
|
||||||
|
Blog post if a major release
|
||||||
|
|
||||||
@@ -9,10 +9,6 @@ email to [security-officer@isc.org](security-officer@isc.org).
|
|||||||
|
|
||||||
(Summarize the bug encountered concisely.)
|
(Summarize the bug encountered concisely.)
|
||||||
|
|
||||||
### BIND version used
|
|
||||||
|
|
||||||
(Paste the output of `named -V`.)
|
|
||||||
|
|
||||||
### Steps to reproduce
|
### Steps to reproduce
|
||||||
|
|
||||||
(How one can reproduce the issue - this is very important.)
|
(How one can reproduce the issue - this is very important.)
|
||||||
|
|||||||
@@ -1,44 +0,0 @@
|
|||||||
## Release Checklist
|
|
||||||
|
|
||||||
- [ ] (Manager) Check for the presence of a milestone for the release:
|
|
||||||
- If there is a milestone, are all the issues for the milestone resolved? (other than this checklist).
|
|
||||||
- [ ] (Manager) Inform Support/Marketing of impending release (and give estimated release dates).
|
|
||||||
- (SwEng) Prepare the sources for tarball generation:
|
|
||||||
- [ ] Check perflab to ensure there has been no unexplained drop in performance for the version being released.
|
|
||||||
- [ ] Ensure that there are no outstanding merge requests in the private repository (subscription version only).
|
|
||||||
- [ ] Update API files for libraries with new version information.
|
|
||||||
- [ ] Change software version and library versions in configure.in (new major release only).
|
|
||||||
- [ ] Rebuild configure using autoconf on docs.isc.org.
|
|
||||||
- [ ] Update CHANGES.
|
|
||||||
- [ ] Update CHANGES.SE (subscription branch only).
|
|
||||||
- [ ] Update "version".
|
|
||||||
- [ ] Update "readme.md".
|
|
||||||
- Check the release notes are correct:
|
|
||||||
- [ ] Compare content with merge requests for the release.
|
|
||||||
- [ ] Check formatting.
|
|
||||||
- [ ] Build documentation on docs.isc.org.
|
|
||||||
- [ ] Commit changes and make sure the gitlab-ci tests are passing.
|
|
||||||
- [ ] Push the changes and tag ("alphatag" is an optional string such as "b1", "rc1" etc.). (```git tag -u <DEVELOPER_KEYID> -a -s -m "BIND 9.X.Y[alphatag]" v9_X_Y[alphatag]```)
|
|
||||||
- [ ] If this is the first tag for a release (e.g. beta), create a release branch named `release_v9_X_Y` (this allows development to continue on the release branch whilst release engineering continues).
|
|
||||||
- [ ] (SwEng) Run the "make release" Jenkins job to produce the tarballs and zips.
|
|
||||||
- [ ] (SwEng) Ask QA to sanity check the tarball and zips (passing to them the number of the Jenkins job).
|
|
||||||
- [ ] (QA) Sanity check the tarballs.
|
|
||||||
- [ ] (QA) Request the signature on the tarballs.
|
|
||||||
- [ ] (QA) Check signatures on tarballs.
|
|
||||||
- [ ] (QA) Tell Support to handle notification of release.
|
|
||||||
- [ ] (Manager) Inform Marketing of the release
|
|
||||||
- [ ] (Manager) Update the internal [BIND release dates wiki page](https://wiki.isc.org/bin/view/Main/BindReleaseDates) when public announcement has been made.
|
|
||||||
|
|
||||||
- [ ] (SwEng) Update DEB and RPM packages
|
|
||||||
- [ ] (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`)
|
|
||||||
|
|
||||||
## Support
|
|
||||||
- [ ] Make tarballs and signatures available to download.
|
|
||||||
- [ ] Write release email to bind9-announce.
|
|
||||||
- [ ] Write email to bind9-users (if a major release).
|
|
||||||
- [ ] Update tickets in case of waiting support customers.
|
|
||||||
|
|
||||||
## Marketing
|
|
||||||
- [ ] Post short note to Twitter.
|
|
||||||
- [ ] Update [Wikipedia entry for BIND](http://en.wikipedia.org/wiki/BIND).
|
|
||||||
- [ ] Write blog article (if a major release).
|
|
||||||
-1434
File diff suppressed because it is too large
Load Diff
@@ -0,0 +1,5 @@
|
|||||||
|
Content-Type: application/X-atf-atffile; version="1"
|
||||||
|
|
||||||
|
prop: test-suite = bind9
|
||||||
|
|
||||||
|
tp: lib
|
||||||
@@ -1,260 +1,3 @@
|
|||||||
5100. [func] Pin resolver tasks to specific task queues. [GL !1117]
|
|
||||||
|
|
||||||
5099. [func] Failed mutex and conditional creations are always
|
|
||||||
fatal. [GL #674]
|
|
||||||
|
|
||||||
--- 9.13.4 released ---
|
|
||||||
|
|
||||||
5098. [func] Failed memory allocations are now fatal. [GL #674]
|
|
||||||
|
|
||||||
5097. [cleanup] Remove embedded ATF unit testing framework
|
|
||||||
from BIND source distribution. [GL !875]
|
|
||||||
|
|
||||||
5096. [func] Use multiple event loops in socket code, and
|
|
||||||
make network threads CPU-affinitive. This
|
|
||||||
significantly improves performance on large
|
|
||||||
systems. [GL #666]
|
|
||||||
|
|
||||||
5095. [test] Converted all unit tests from ATF to CMocka;
|
|
||||||
removed the source code for the ATF libraries.
|
|
||||||
Build with "configure --with-cmocka" to enable
|
|
||||||
unit testing. [GL #620]
|
|
||||||
|
|
||||||
5094. [func] Add 'dig -r' to disable reading of .digrc. [GL !970]
|
|
||||||
|
|
||||||
5093. [bug] Log lame qname-minimization servers only if they're
|
|
||||||
really lame. [GL #671]
|
|
||||||
|
|
||||||
5092. [bug] Address memory leak on SIGTERM in nsupdate when using
|
|
||||||
GSS-TSIG. [GL #558]
|
|
||||||
|
|
||||||
5091. [func] Two new global and per-view options min-cache-ttl
|
|
||||||
and min-ncache-ttl [GL #613]
|
|
||||||
|
|
||||||
5090. [bug] dig and mdig failed to properly preparse dash value
|
|
||||||
pairs when value was a seperate argument and started
|
|
||||||
with a dash. [GL #584]
|
|
||||||
|
|
||||||
5089. [bug] Restore localhost fallback in dig and host which is
|
|
||||||
used when no nameserver addresses present in
|
|
||||||
/etc/resolv.conf are usable due to the requested
|
|
||||||
address family restrictions. [GL #433]
|
|
||||||
|
|
||||||
5088. [bug] dig/host/nslookup could crash when interrupted close to
|
|
||||||
a query timeout. [GL #599]
|
|
||||||
|
|
||||||
5087. [test] Check that result tables are complete. [GL #676]
|
|
||||||
|
|
||||||
5086. [func] Log of RPZ now includes the QTYPE and QCLASS. [GL #623]
|
|
||||||
|
|
||||||
5085. [bug] win32: Restore looking up nameservers, search list,
|
|
||||||
etc. [GL #186]
|
|
||||||
|
|
||||||
5084. [placeholder]
|
|
||||||
|
|
||||||
5083. [func] Add autoconf macro AX_POSIX_SHELL, so we
|
|
||||||
can use POSIX-compatible shell features
|
|
||||||
in the scripts.
|
|
||||||
|
|
||||||
5082. [bug] Fixed a race that could cause a crash in
|
|
||||||
dig/host/nslookup. [GL #650]
|
|
||||||
|
|
||||||
5081. [func] Use per-worker queues in task manager, make task
|
|
||||||
runners CPU-affine. [GL #659]
|
|
||||||
|
|
||||||
5080. [func] Improvements to "rndc nta" user interface:
|
|
||||||
- catch and report invalid command line options
|
|
||||||
- when removing an NTA from all views, do not
|
|
||||||
abort with an error if the NTA was not found
|
|
||||||
in one of the views
|
|
||||||
- include the view name in "rndc nta -dump"
|
|
||||||
output, for consistency with the add and remove
|
|
||||||
actions
|
|
||||||
Thanks to Tony Finch. [GL !816]
|
|
||||||
|
|
||||||
5079. [func] Disable IDN processing in dig and nslookup
|
|
||||||
when not on a tty. [GL #653]
|
|
||||||
|
|
||||||
5078. [cleanup] Require python components to be explicitly disabled if
|
|
||||||
python is not available on unix platforms. [GL #601]
|
|
||||||
|
|
||||||
5077. [cleanup] Remove ip6.int support (-i) from dig and mdig.
|
|
||||||
[GL !969]
|
|
||||||
|
|
||||||
5076. [bug] "require-server-cookie" was not effective if
|
|
||||||
"rate-limit" was configured. [GL #617]
|
|
||||||
|
|
||||||
5075. [bug] Refresh nameservers from cache when sending final
|
|
||||||
query in qname minimization. [GL #16]
|
|
||||||
|
|
||||||
5074. [cleanup] Remove vector socket functions - isc_socket_recvv(),
|
|
||||||
isc_socket_sendtov(), isc_socket_sendtov2(),
|
|
||||||
isc_socket_sendv() - in order to simplify socket code.
|
|
||||||
[GL #645]
|
|
||||||
|
|
||||||
5073. [bug] Destroy a task first when destroying rpzs and catzs.
|
|
||||||
[GL #84]
|
|
||||||
|
|
||||||
5072. [bug] Add unit tests for isc_buffer_copyregion() and fix its
|
|
||||||
behavior for auto-reallocated buffers. [GL #644]
|
|
||||||
|
|
||||||
5071. [bug] Comparision of NXT records was broken. [GL #631]
|
|
||||||
|
|
||||||
5070. [bug] Record types which support a empty rdata field were
|
|
||||||
not handling the empty rdata field case. [GL #638]
|
|
||||||
|
|
||||||
5069. [bug] Fix a hang on in RPZ when named is shutdown during RPZ
|
|
||||||
zone update. [GL !907]
|
|
||||||
|
|
||||||
5068. [bug] Fix a race in RPZ with min-update-interval set to 0.
|
|
||||||
[GL #643]
|
|
||||||
|
|
||||||
5067. [bug] Don't minimize qname when sending the query
|
|
||||||
to a forwarder. [GL #361]
|
|
||||||
|
|
||||||
5066. [cleanup] Allow unquoted strings to be used as a zone names
|
|
||||||
in response-policy statements. [GL #641]
|
|
||||||
|
|
||||||
5065. [bug] Only set IPV6_USE_MIN_MTU on IPv6. [GL #553]
|
|
||||||
|
|
||||||
5064. [test] Initalize TZ environment variable before calling
|
|
||||||
dns_test_begin in dnstap_test. [GL #624]
|
|
||||||
|
|
||||||
5063. [test] In statschannel test try a few times before failing
|
|
||||||
when checking if the compressed output is the same as
|
|
||||||
uncompressed. [GL !909]
|
|
||||||
|
|
||||||
5062. [func] Use non-crypto-secure PRNG to generate nonces for
|
|
||||||
cookies. [GL !887]
|
|
||||||
|
|
||||||
5061. [protocol] Add support for EID and NIMLOC. [GL #626]
|
|
||||||
|
|
||||||
5060. [bug] GID, UID and UINFO could not be loaded using unknown
|
|
||||||
record format. [GL #627]
|
|
||||||
|
|
||||||
5059. [bug] Display a per-view list of zones in the web interface.
|
|
||||||
[GL #427]
|
|
||||||
|
|
||||||
5058. [func] Replace old message digest and hmac APIs with more
|
|
||||||
generic isc_md and isc_hmac APIs, and convert their
|
|
||||||
respective tests to cmocka. [GL #305]
|
|
||||||
|
|
||||||
5057. [protocol] Add support for ATMA. [GL #619]
|
|
||||||
|
|
||||||
5056. [placeholder]
|
|
||||||
|
|
||||||
5055. [func] A default list of primary servers for the root zone is
|
|
||||||
now built into named, allowing the "masters" statement
|
|
||||||
to be omitted when configuring an IANA root zone
|
|
||||||
mirror. [GL #564]
|
|
||||||
|
|
||||||
5054. [func] Attempts to use mirror zones with recursion disabled
|
|
||||||
are now considered a configuration error. [GL #564]
|
|
||||||
|
|
||||||
5053. [func] The only valid zone-level NOTIFY settings for mirror
|
|
||||||
zones are now "notify no;" and "notify explicit;".
|
|
||||||
[GL #564]
|
|
||||||
|
|
||||||
5052. [func] Mirror zones are now configured using "type mirror;"
|
|
||||||
rather than "mirror yes;". [GL #564]
|
|
||||||
|
|
||||||
5051. [doc] Documentation incorrectly stated that the
|
|
||||||
"server-addresses" static-stub zone option accepts
|
|
||||||
custom port numbers. [GL #582]
|
|
||||||
|
|
||||||
5050. [bug] The libirs version of getaddrinfo() was unable to parse
|
|
||||||
scoped IPv6 addresses present in /etc/resolv.conf.
|
|
||||||
[GL #187]
|
|
||||||
|
|
||||||
5049. [cleanup] QNAME minimization has been deeply refactored. [GL #16]
|
|
||||||
|
|
||||||
5048. [func] Add configure option to enable and enforce FIPS mode
|
|
||||||
in BIND 9. [GL #506]
|
|
||||||
|
|
||||||
5047. [bug] Messages logged for certain query processing failures
|
|
||||||
now include a more specific error description if it is
|
|
||||||
available. [GL #572]
|
|
||||||
|
|
||||||
5046. [bug] named could crash during shutdown if an RPZ
|
|
||||||
reload was in progress. [RT #46210]
|
|
||||||
|
|
||||||
5045. [func] Remove support for DNSSEC algorithms 3 (DSA)
|
|
||||||
and 6 (DSA-NSEC3-SHA1). [GL #22]
|
|
||||||
|
|
||||||
5044. [cleanup] If "dnssec-enable" is no, then "dnssec-validation"
|
|
||||||
now also defaults to no. [GL #388]
|
|
||||||
|
|
||||||
5043. [bug] Fix creating and validating EdDSA signatures. [GL #579]
|
|
||||||
|
|
||||||
5042. [test] Make the chained delegations in reclimit behave
|
|
||||||
like they would in a regular name server. [GL #578]
|
|
||||||
|
|
||||||
5041. [test] The chain test contains a incomplete delegation.
|
|
||||||
[GL #568]
|
|
||||||
|
|
||||||
5040. [func] Extended dnstap so that it can log UPDATE requests
|
|
||||||
and responses as separate message types. Thanks
|
|
||||||
to Greg Rabil. [GL #570]
|
|
||||||
|
|
||||||
5039. [bug] Named could fail to preserve owner name case of new
|
|
||||||
RRset. [GL #420]
|
|
||||||
|
|
||||||
5038. [bug] Chaosnet addresses were compared incorrectly.
|
|
||||||
[GL #562]
|
|
||||||
|
|
||||||
5037. [func] "allow-recursion-on" and "allow-query-cache-on"
|
|
||||||
each now default to the other if only one of them
|
|
||||||
is set, in order to be more consistent with the way
|
|
||||||
"allow-recursion" and "allow-query-cache" work.
|
|
||||||
Also we now ensure that both query-cache ACLs are
|
|
||||||
checked when determining cache access. [GL #319]
|
|
||||||
|
|
||||||
5036. [cleanup] Fixed a spacing/formatting error in some RPZ-related
|
|
||||||
error messages in the log. [GL !805]
|
|
||||||
|
|
||||||
5035. [test] Fixed errors that prevented the DNSRPS subtests
|
|
||||||
from running in the rpz and rpzrecurse system
|
|
||||||
tests. [GL #503]
|
|
||||||
|
|
||||||
5034. [bug] A race between threads could prevent zone maintenance
|
|
||||||
scheduled immediately after zone load from being
|
|
||||||
performed. [GL #542]
|
|
||||||
|
|
||||||
5033. [bug] When adding NTAs to multiple views using "rndc nta",
|
|
||||||
the text returned via rndc was incorrectly terminated
|
|
||||||
after the first line, making it look as if only one
|
|
||||||
NTA had been added. Also, it was not possible to
|
|
||||||
differentiate between views with the same name but
|
|
||||||
different classes; this has been corrected with the
|
|
||||||
addition of a "-class" option. [GL #105]
|
|
||||||
|
|
||||||
5032. [func] Add krb5-selfsub and ms-selfsub update policy rules.
|
|
||||||
[GL #511]
|
|
||||||
|
|
||||||
5031. [cleanup] Various defines in platform.h has been either dropped
|
|
||||||
if always or never triggered on supported platforms
|
|
||||||
or replaced with config.h equivalents if the defines
|
|
||||||
didn't have any impact on public headers. Workarounds
|
|
||||||
for LinuxThreads have been removed because NPTL is
|
|
||||||
available since Linux kernel 2.6.0. [GL #525]
|
|
||||||
|
|
||||||
5030. [bug] Align CMSG buffers to a 64-bit boundary, fixes crash
|
|
||||||
on architectures with strict alignment. [GL #521]
|
|
||||||
|
|
||||||
--- 9.13.3 released ---
|
|
||||||
|
|
||||||
5029. [func] Workarounds for servers that misbehave when queried
|
|
||||||
with EDNS have been removed, because these broken
|
|
||||||
servers and the workarounds for their noncompliance
|
|
||||||
cause unnecessary delays, increase code complexity,
|
|
||||||
and prevent deployment of new DNS features. See
|
|
||||||
https://dnsflagday.net for further details. [GL #150]
|
|
||||||
|
|
||||||
5028. [bug] Spread the initial RRSIG expiration times over the
|
|
||||||
entire working sig-validity-interval when signing a
|
|
||||||
zone in named to even out re-signing and transfer
|
|
||||||
loads. [GL #418]
|
|
||||||
|
|
||||||
5027. [func] Set SO_SNDBUF size on sockets. [GL #74]
|
5027. [func] Set SO_SNDBUF size on sockets. [GL #74]
|
||||||
|
|
||||||
5026. [bug] rndc reconfig should not touch already loaded zones.
|
5026. [bug] rndc reconfig should not touch already loaded zones.
|
||||||
@@ -345,7 +88,7 @@
|
|||||||
5000. [bug] named_server_servestale() could leave the server in
|
5000. [bug] named_server_servestale() could leave the server in
|
||||||
exclusive mode if an error occured. [GL #441]
|
exclusive mode if an error occured. [GL #441]
|
||||||
|
|
||||||
4999. [cleanup] Remove custom printf implementation in lib/isc/print.c.
|
4999. [cleanup] Remove custom printf implementaion in lib/isc/print.c.
|
||||||
[GL #261]
|
[GL #261]
|
||||||
|
|
||||||
4998. [test] Make resolver and cacheclean tests more civilized.
|
4998. [test] Make resolver and cacheclean tests more civilized.
|
||||||
|
|||||||
+1
-1
@@ -14,7 +14,7 @@ top_builddir = @top_builddir@
|
|||||||
|
|
||||||
VERSION=@BIND9_VERSION@
|
VERSION=@BIND9_VERSION@
|
||||||
|
|
||||||
SUBDIRS = make lib fuzz bin doc
|
SUBDIRS = make unit lib fuzz bin doc
|
||||||
TARGETS =
|
TARGETS =
|
||||||
PREREQS = bind.keys.h
|
PREREQS = bind.keys.h
|
||||||
|
|
||||||
|
|||||||
@@ -1,11 +1,9 @@
|
|||||||
Supported platforms
|
Supported platforms
|
||||||
|
|
||||||
In general, this version of BIND will build and run on any POSIX-compliant
|
In general, this version of BIND will build and run on any POSIX-compliant
|
||||||
system with a C99-compliant C compiler, BSD-style sockets with
|
system with a C99-compliant C compiler, BSD-style sockets, and the OpenSSL
|
||||||
RFC-compliant IPv6 support, POSIX-compliant threads, and the OpenSSL
|
cryptography library. To build with multiprocessing support, a
|
||||||
cryptography library. Atomic operations support from the compiler is
|
C11-compliant C compiler will be needed for standard atomics.
|
||||||
needed, either in the form of builtin operations, C11 atomics or the
|
|
||||||
Interlocked family of functions on Windows.
|
|
||||||
|
|
||||||
ISC regularly tests BIND on many operating systems and architectures, but
|
ISC regularly tests BIND on many operating systems and architectures, but
|
||||||
lacks the resources to test all of them. Consequently, ISC is only able to
|
lacks the resources to test all of them. Consequently, ISC is only able to
|
||||||
@@ -55,35 +53,4 @@ These are platforms on which BIND is known not to build or run:
|
|||||||
|
|
||||||
* Platforms without at least OpenSSL 1.0.2
|
* Platforms without at least OpenSSL 1.0.2
|
||||||
* Windows 10 / x86
|
* Windows 10 / x86
|
||||||
* Windows Server 2012 and older
|
* Windows Server 2012
|
||||||
* Platforms that don't support IPv6 Advanced Socket API (RFC 3542)
|
|
||||||
* Platforms that don't support atomic operations (via compiler or
|
|
||||||
library)
|
|
||||||
* Linux without NPTL (Native POSIX Thread Library)
|
|
||||||
|
|
||||||
Platform quirks
|
|
||||||
|
|
||||||
ARM
|
|
||||||
|
|
||||||
If the compilation ends with following error:
|
|
||||||
|
|
||||||
Error: selected processor does not support `yield' in ARM mode
|
|
||||||
|
|
||||||
You will need to set -march compiler option to native, so the compiler
|
|
||||||
recognizes yield assembler instruction. The proper way to set -march=
|
|
||||||
native would be to put it into CFLAGS, e.g. run ./configure like this:
|
|
||||||
CFLAGS="-march=native -Os -g" ./configure plus your usual options.
|
|
||||||
|
|
||||||
If that doesn't work, you can enforce the minimum CPU and FPU (taken from
|
|
||||||
Debian armhf documentation):
|
|
||||||
|
|
||||||
* The lowest worthwhile CPU implementation is Armv7-A, therefore the
|
|
||||||
recommended build option is -march=armv7-a.
|
|
||||||
|
|
||||||
* FPU should be set at VFPv3-D16 as they represent the miminum
|
|
||||||
specification of the processors to support here, therefore the
|
|
||||||
recommended build option is -mfpu=vfpv3-d16.
|
|
||||||
|
|
||||||
The configure command should look like this:
|
|
||||||
|
|
||||||
CFLAGS="-march=armv7-a -mfpu=vfpv3-d16 -Os -g" ./configure
|
|
||||||
|
|||||||
+4
-40
@@ -11,11 +11,9 @@
|
|||||||
## Supported platforms
|
## Supported platforms
|
||||||
|
|
||||||
In general, this version of BIND will build and run on any POSIX-compliant
|
In general, this version of BIND will build and run on any POSIX-compliant
|
||||||
system with a C99-compliant C compiler, BSD-style sockets with RFC-compliant
|
system with a C99-compliant C compiler, BSD-style sockets, and the OpenSSL
|
||||||
IPv6 support, POSIX-compliant threads, and the OpenSSL cryptography library.
|
cryptography library. To build with multiprocessing support, a
|
||||||
Atomic operations support from the compiler is needed, either in the form of
|
C11-compliant C compiler will be needed for standard atomics.
|
||||||
builtin operations, C11 atomics or the Interlocked family of functions on
|
|
||||||
Windows.
|
|
||||||
|
|
||||||
ISC regularly tests BIND on many operating systems and architectures, but
|
ISC regularly tests BIND on many operating systems and architectures, but
|
||||||
lacks the resources to test all of them. Consequently, ISC is only able to
|
lacks the resources to test all of them. Consequently, ISC is only able to
|
||||||
@@ -63,38 +61,4 @@ These are platforms on which BIND is known *not* to build or run:
|
|||||||
|
|
||||||
* Platforms without at least OpenSSL 1.0.2
|
* Platforms without at least OpenSSL 1.0.2
|
||||||
* Windows 10 / x86
|
* Windows 10 / x86
|
||||||
* Windows Server 2012 and older
|
* Windows Server 2012
|
||||||
* Platforms that don't support IPv6 Advanced Socket API (RFC 3542)
|
|
||||||
* Platforms that don't support atomic operations (via compiler or library)
|
|
||||||
* Linux without NPTL (Native POSIX Thread Library)
|
|
||||||
|
|
||||||
## Platform quirks
|
|
||||||
|
|
||||||
### ARM
|
|
||||||
|
|
||||||
If the compilation ends with following error:
|
|
||||||
|
|
||||||
```
|
|
||||||
Error: selected processor does not support `yield' in ARM mode
|
|
||||||
```
|
|
||||||
|
|
||||||
You will need to set `-march` compiler option to `native`, so the compiler
|
|
||||||
recognizes `yield` assembler instruction. The proper way to set `-march=native`
|
|
||||||
would be to put it into `CFLAGS`, e.g. run `./configure` like this:
|
|
||||||
`CFLAGS="-march=native -Os -g" ./configure` plus your usual options.
|
|
||||||
|
|
||||||
If that doesn't work, you can enforce the minimum CPU and FPU (taken from Debian
|
|
||||||
armhf documentation):
|
|
||||||
|
|
||||||
* The lowest worthwhile CPU implementation is Armv7-A, therefore the recommended
|
|
||||||
build option is `-march=armv7-a`.
|
|
||||||
|
|
||||||
* FPU should be set at VFPv3-D16 as they represent the miminum specification of
|
|
||||||
the processors to support here, therefore the recommended build option is
|
|
||||||
`-mfpu=vfpv3-d16`.
|
|
||||||
|
|
||||||
The configure command should look like this:
|
|
||||||
|
|
||||||
```
|
|
||||||
CFLAGS="-march=armv7-a -mfpu=vfpv3-d16 -Os -g" ./configure
|
|
||||||
```
|
|
||||||
|
|||||||
@@ -104,8 +104,8 @@ BIND 9.13 features
|
|||||||
BIND 9.13 is the newest development branch of BIND 9. It includes a number
|
BIND 9.13 is the newest development branch of BIND 9. It includes a number
|
||||||
of changes from BIND 9.12 and earlier releases. New features include:
|
of changes from BIND 9.12 and earlier releases. New features include:
|
||||||
|
|
||||||
* Socket and task code has been refactored to improve performance.
|
* The default value of "dnssec-validation" is now "auto".
|
||||||
* QNAME minimization, as described in RFC 7816, is now supported.
|
* Support for IDNA2008 when linking with libidn2.
|
||||||
* "Root key sentinel" support, enabling validating resolvers to indicate
|
* "Root key sentinel" support, enabling validating resolvers to indicate
|
||||||
via a special query which trust anchors are configured for the root
|
via a special query which trust anchors are configured for the root
|
||||||
zone.
|
zone.
|
||||||
@@ -114,24 +114,15 @@ of changes from BIND 9.12 and earlier releases. New features include:
|
|||||||
subject to DNSSEC validation and are not treated as authoritative data
|
subject to DNSSEC validation and are not treated as authoritative data
|
||||||
when answering. This makes it easier to configure a local copy of the
|
when answering. This makes it easier to configure a local copy of the
|
||||||
root zone as described in RFC 7706.
|
root zone as described in RFC 7706.
|
||||||
|
* QNAME minimization is now supported
|
||||||
* The "validate-except" option allows configuration of domains below
|
* The "validate-except" option allows configuration of domains below
|
||||||
which DNSSEC validation should not be performed.
|
which DNSSEC validation should not be performed.
|
||||||
* The default value of "dnssec-validation" is now "auto".
|
|
||||||
* IDNA2008 is now supported when linking with libidn2.
|
|
||||||
|
|
||||||
In addition, workarounds that were formerly in place to enable resolution
|
In addition, cryptographic support has been modernized. BIND now uses the
|
||||||
of domains whose authoritative servers did not respond to EDNS queries
|
best available pseudo-random number generator for the platform on which
|
||||||
have been removed. See https://dnsflagday.net for more details.
|
it's built. Very old versions of OpenSSL are no longer supported.
|
||||||
|
Cryptography is now mandatory; building BIND without DNSSEC is now longer
|
||||||
Cryptographic support has been modernized. BIND now uses the best
|
supported.
|
||||||
available pseudo-random number generator for the platform on which it's
|
|
||||||
built. Very old versions of OpenSSL are no longer supported. Cryptography
|
|
||||||
is now mandatory: building BIND without DNSSEC is now longer supported.
|
|
||||||
|
|
||||||
Special code to support certain legacy operating systems has also been
|
|
||||||
removed; see the file PLATFORMS.md for details of supported platforms. In
|
|
||||||
addition to OpenSSL, BIND now requires support for IPv6, threads, and
|
|
||||||
standard atomic operations provided by the C compiler.
|
|
||||||
|
|
||||||
Building BIND
|
Building BIND
|
||||||
|
|
||||||
@@ -139,7 +130,7 @@ Minimally, BIND requires a UNIX or Linux system with an ANSI C compiler,
|
|||||||
basic POSIX support, and a 64-bit integer type. Successful builds have
|
basic POSIX support, and a 64-bit integer type. Successful builds have
|
||||||
been observed on many versions of Linux and UNIX, including RedHat,
|
been observed on many versions of Linux and UNIX, including RedHat,
|
||||||
Fedora, Debian, Ubuntu, SuSE, Slackware, FreeBSD, NetBSD, OpenBSD, Mac OS
|
Fedora, Debian, Ubuntu, SuSE, Slackware, FreeBSD, NetBSD, OpenBSD, Mac OS
|
||||||
X, Solaris, HP-UX, and OpenWRT.
|
X, Solaris, HP-UX, AIX, SCO OpenServer, and OpenWRT.
|
||||||
|
|
||||||
BIND requires a cryptography provider library such as OpenSSL or a
|
BIND requires a cryptography provider library such as OpenSSL or a
|
||||||
hardware service module supporting PKCS#11. On Linux, BIND requires the
|
hardware service module supporting PKCS#11. On Linux, BIND requires the
|
||||||
@@ -265,6 +256,10 @@ specifying --enable-fixed-rrset or --disable-fixed-rrset on the configure
|
|||||||
command line. By default, fixed rrset-order is disabled to reduce memory
|
command line. By default, fixed rrset-order is disabled to reduce memory
|
||||||
footprint.
|
footprint.
|
||||||
|
|
||||||
|
If your operating system has integrated support for IPv6, it will be used
|
||||||
|
automatically. If you have installed KAME IPv6 separately, use --with-kame
|
||||||
|
[=PATH] to specify its location.
|
||||||
|
|
||||||
make install will install named and the various BIND 9 libraries. By
|
make install will install named and the various BIND 9 libraries. By
|
||||||
default, installation is into /usr/local, but this can be changed with the
|
default, installation is into /usr/local, but this can be changed with the
|
||||||
--prefix option when running configure.
|
--prefix option when running configure.
|
||||||
@@ -290,10 +285,8 @@ and will be skipped if these are not available. Some tests require Python
|
|||||||
and the 'dnspython' module and will be skipped if these are not available.
|
and the 'dnspython' module and will be skipped if these are not available.
|
||||||
See bin/tests/system/README for further details.
|
See bin/tests/system/README for further details.
|
||||||
|
|
||||||
Unit tests are implemented using the CMocka unit testing framework. To
|
Unit tests are implemented using Automated Testing Framework (ATF). To run
|
||||||
build them, use configure --with-cmocka. Execution of tests is done by the
|
them, use configure --with-atf, then run make test or make unit.
|
||||||
Kyua test execution engine; if the kyua command is available, then unit
|
|
||||||
tests can be run via make test or make unit.
|
|
||||||
|
|
||||||
Documentation
|
Documentation
|
||||||
|
|
||||||
|
|||||||
@@ -122,8 +122,8 @@ BIND 9.13 is the newest development branch of BIND 9. It includes a
|
|||||||
number of changes from BIND 9.12 and earlier releases. New features
|
number of changes from BIND 9.12 and earlier releases. New features
|
||||||
include:
|
include:
|
||||||
|
|
||||||
* Socket and task code has been refactored to improve performance.
|
* The default value of "dnssec-validation" is now "auto".
|
||||||
* QNAME minimization, as described in RFC 7816, is now supported.
|
* Support for IDNA2008 when linking with `libidn2`.
|
||||||
* "Root key sentinel" support, enabling validating resolvers to indicate
|
* "Root key sentinel" support, enabling validating resolvers to indicate
|
||||||
via a special query which trust anchors are configured for the root zone.
|
via a special query which trust anchors are configured for the root zone.
|
||||||
* Secondary zones can now be configured as "mirror" zones; their contents
|
* Secondary zones can now be configured as "mirror" zones; their contents
|
||||||
@@ -131,28 +131,16 @@ include:
|
|||||||
DNSSEC validation and are not treated as authoritative data when
|
DNSSEC validation and are not treated as authoritative data when
|
||||||
answering. This makes it easier to configure a local copy of the root
|
answering. This makes it easier to configure a local copy of the root
|
||||||
zone as described in RFC 7706.
|
zone as described in RFC 7706.
|
||||||
|
* QNAME minimization is now supported
|
||||||
* The "validate-except" option allows configuration of domains below which
|
* The "validate-except" option allows configuration of domains below which
|
||||||
DNSSEC validation should not be performed.
|
DNSSEC validation should not be performed.
|
||||||
* The default value of "dnssec-validation" is now "auto".
|
|
||||||
* IDNA2008 is now supported when linking with `libidn2`.
|
|
||||||
|
|
||||||
In addition, workarounds that were formerly in place to enable resolution
|
In addition, cryptographic support has been modernized. BIND now uses the
|
||||||
of domains whose authoritative servers did not respond to EDNS queries
|
|
||||||
have been removed. See [https://dnsflagday.net](https://dnsflagday.net)
|
|
||||||
for more details.
|
|
||||||
|
|
||||||
Cryptographic support has been modernized. BIND now uses the
|
|
||||||
best available pseudo-random number generator for the platform on which
|
best available pseudo-random number generator for the platform on which
|
||||||
it's built. Very old versions of OpenSSL are no longer supported.
|
it's built. Very old versions of OpenSSL are no longer supported.
|
||||||
Cryptography is now mandatory: building BIND without DNSSEC is now
|
Cryptography is now mandatory; building BIND without DNSSEC is now
|
||||||
longer supported.
|
longer supported.
|
||||||
|
|
||||||
Special code to support certain legacy operating systems has also
|
|
||||||
been removed; see the file [PLATFORMS.md](PLATFORMS.md) for details
|
|
||||||
of supported platforms. In addition to OpenSSL, BIND now requires
|
|
||||||
support for IPv6, threads, and standard atomic operations provided
|
|
||||||
by the C compiler.
|
|
||||||
|
|
||||||
### <a name="build"/> Building BIND
|
### <a name="build"/> Building BIND
|
||||||
|
|
||||||
Minimally, BIND requires a UNIX or Linux system with an ANSI C compiler,
|
Minimally, BIND requires a UNIX or Linux system with an ANSI C compiler,
|
||||||
@@ -308,10 +296,9 @@ and will be skipped if these are not available. Some tests require Python
|
|||||||
and the 'dnspython' module and will be skipped if these are not available.
|
and the 'dnspython' module and will be skipped if these are not available.
|
||||||
See bin/tests/system/README for further details.
|
See bin/tests/system/README for further details.
|
||||||
|
|
||||||
Unit tests are implemented using the CMocka unit testing framework.
|
Unit tests are implemented using Automated Testing Framework (ATF).
|
||||||
To build them, use `configure --with-cmocka`. Execution of tests is done
|
To run them, use `configure --with-atf`, then run `make test` or
|
||||||
by the Kyua test execution engine; if the `kyua` command is available,
|
`make unit`.
|
||||||
then unit tests can be run via `make test` or `make unit`.
|
|
||||||
|
|
||||||
### <a name="doc"/> Documentation
|
### <a name="doc"/> Documentation
|
||||||
|
|
||||||
|
|||||||
+81
@@ -0,0 +1,81 @@
|
|||||||
|
/*
|
||||||
|
* 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 http://mozilla.org/MPL/2.0/.
|
||||||
|
*
|
||||||
|
* See the COPYRIGHT file distributed with this work for additional
|
||||||
|
* information regarding copyright ownership.
|
||||||
|
*/
|
||||||
|
|
||||||
|
/*! \file */
|
||||||
|
|
||||||
|
/***
|
||||||
|
*** This file is not to be included by any public header files, because
|
||||||
|
*** it does not get installed.
|
||||||
|
***/
|
||||||
|
@TOP@
|
||||||
|
|
||||||
|
/** define if your system needs pthread_init() before using pthreads */
|
||||||
|
#undef NEED_PTHREAD_INIT
|
||||||
|
|
||||||
|
/** define if your system has sigwait() */
|
||||||
|
#undef HAVE_SIGWAIT
|
||||||
|
|
||||||
|
/** define if sigwait() is the UnixWare flavor */
|
||||||
|
#undef HAVE_UNIXWARE_SIGWAIT
|
||||||
|
|
||||||
|
/** define if LinuxThreads is in use */
|
||||||
|
#undef HAVE_LINUXTHREADS
|
||||||
|
|
||||||
|
/** define if sysconf() is available */
|
||||||
|
#undef HAVE_SYSCONF
|
||||||
|
|
||||||
|
/** define if sysctlbyname() is available */
|
||||||
|
#undef HAVE_SYSCTLBYNAME
|
||||||
|
|
||||||
|
/** define if catgets() is available */
|
||||||
|
#undef HAVE_CATGETS
|
||||||
|
|
||||||
|
/** define if getifaddrs() exists */
|
||||||
|
#undef HAVE_GETIFADDRS
|
||||||
|
|
||||||
|
/** define if you have the NET_RT_IFLIST sysctl variable and sys/sysctl.h */
|
||||||
|
#undef HAVE_IFLIST_SYSCTL
|
||||||
|
|
||||||
|
/** define if tzset() is available */
|
||||||
|
#undef HAVE_TZSET
|
||||||
|
|
||||||
|
/**
|
||||||
|
* define if pthread_setconcurrency() should be called to tell the
|
||||||
|
* OS how many threads we might want to run.
|
||||||
|
*/
|
||||||
|
#undef CALL_PTHREAD_SETCONCURRENCY
|
||||||
|
|
||||||
|
/** define if flockfile() is available */
|
||||||
|
#undef HAVE_FLOCKFILE
|
||||||
|
|
||||||
|
/** define if getc_unlocked() is available */
|
||||||
|
#undef HAVE_GETCUNLOCKED
|
||||||
|
|
||||||
|
/** define if the system has a random number generating device */
|
||||||
|
#undef PATH_RANDOMDEV
|
||||||
|
|
||||||
|
/** define if pthread_attr_getstacksize() is available */
|
||||||
|
#undef HAVE_PTHREAD_ATTR_GETSTACKSIZE
|
||||||
|
|
||||||
|
/** define if pthread_attr_setstacksize() is available */
|
||||||
|
#undef HAVE_PTHREAD_ATTR_SETSTACKSIZE
|
||||||
|
|
||||||
|
/** define if you have strerror in the C library. */
|
||||||
|
#undef HAVE_STRERROR
|
||||||
|
|
||||||
|
/* Define to the length type used by the socket API (socklen_t, size_t, int). */
|
||||||
|
#undef ISC_SOCKADDR_LEN_T
|
||||||
|
|
||||||
|
/* Define if threads need PTHREAD_SCOPE_SYSTEM */
|
||||||
|
#undef NEED_PTHREAD_SCOPE_SYSTEM
|
||||||
|
|
||||||
|
/* Define to 1 if you have the uname library function. */
|
||||||
|
#undef HAVE_UNAME
|
||||||
Vendored
-1
@@ -289,7 +289,6 @@ AS_VAR_IF([$1], [""], [$5], [$4])dnl
|
|||||||
])dnl PKG_CHECK_VAR
|
])dnl PKG_CHECK_VAR
|
||||||
|
|
||||||
m4_include([m4/ax_check_openssl.m4])
|
m4_include([m4/ax_check_openssl.m4])
|
||||||
m4_include([m4/ax_posix_shell.m4])
|
|
||||||
m4_include([m4/ax_pthread.m4])
|
m4_include([m4/ax_pthread.m4])
|
||||||
m4_include([m4/libtool.m4])
|
m4_include([m4/libtool.m4])
|
||||||
m4_include([m4/ltoptions.m4])
|
m4_include([m4/ltoptions.m4])
|
||||||
|
|||||||
@@ -88,12 +88,12 @@ install:: named-checkconf@EXEEXT@ named-checkzone@EXEEXT@ installdirs
|
|||||||
${LIBTOOL_MODE_INSTALL} ${INSTALL_PROGRAM} named-checkconf@EXEEXT@ ${DESTDIR}${sbindir}
|
${LIBTOOL_MODE_INSTALL} ${INSTALL_PROGRAM} named-checkconf@EXEEXT@ ${DESTDIR}${sbindir}
|
||||||
${LIBTOOL_MODE_INSTALL} ${INSTALL_PROGRAM} named-checkzone@EXEEXT@ ${DESTDIR}${sbindir}
|
${LIBTOOL_MODE_INSTALL} ${INSTALL_PROGRAM} named-checkzone@EXEEXT@ ${DESTDIR}${sbindir}
|
||||||
(cd ${DESTDIR}${sbindir}; rm -f named-compilezone@EXEEXT@; ${LINK_PROGRAM} named-checkzone@EXEEXT@ named-compilezone@EXEEXT@)
|
(cd ${DESTDIR}${sbindir}; rm -f named-compilezone@EXEEXT@; ${LINK_PROGRAM} named-checkzone@EXEEXT@ named-compilezone@EXEEXT@)
|
||||||
for m in ${MANPAGES}; do ${INSTALL_DATA} ${srcdir}/$$m ${DESTDIR}${mandir}/man8 || exit 1; done
|
for m in ${MANPAGES}; do ${INSTALL_DATA} ${srcdir}/$$m ${DESTDIR}${mandir}/man8; done
|
||||||
(cd ${DESTDIR}${mandir}/man8; rm -f named-compilezone.8; ${LINK_PROGRAM} named-checkzone.8 named-compilezone.8)
|
(cd ${DESTDIR}${mandir}/man8; rm -f named-compilezone.8; ${LINK_PROGRAM} named-checkzone.8 named-compilezone.8)
|
||||||
|
|
||||||
uninstall::
|
uninstall::
|
||||||
rm -f ${DESTDIR}${mandir}/man8/named-compilezone.8
|
rm -f ${DESTDIR}${mandir}/man8/named-compilezone.8
|
||||||
for m in ${MANPAGES}; do rm -f ${DESTDIR}${mandir}/man8/$$m || exit 1; done
|
for m in ${MANPAGES}; do rm -f ${DESTDIR}${mandir}/man8/$$m ; done
|
||||||
rm -f ${DESTDIR}${sbindir}/named-compilezone@EXEEXT@
|
rm -f ${DESTDIR}${sbindir}/named-compilezone@EXEEXT@
|
||||||
${LIBTOOL_MODE_UNINSTALL} rm -f ${DESTDIR}${sbindir}/named-checkconf@EXEEXT@
|
${LIBTOOL_MODE_UNINSTALL} rm -f ${DESTDIR}${sbindir}/named-checkconf@EXEEXT@
|
||||||
${LIBTOOL_MODE_UNINSTALL} rm -f ${DESTDIR}${sbindir}/named-checkzone@EXEEXT@
|
${LIBTOOL_MODE_UNINSTALL} rm -f ${DESTDIR}${sbindir}/named-checkzone@EXEEXT@
|
||||||
|
|||||||
+10
-24
@@ -282,10 +282,8 @@ configure_zone(const char *vclass, const char *view,
|
|||||||
} else if (strcasecmp(cfg_obj_asstring(obj), "ignore") == 0) {
|
} else if (strcasecmp(cfg_obj_asstring(obj), "ignore") == 0) {
|
||||||
zone_options &= ~DNS_ZONEOPT_CHECKDUPRR;
|
zone_options &= ~DNS_ZONEOPT_CHECKDUPRR;
|
||||||
zone_options &= ~DNS_ZONEOPT_CHECKDUPRRFAIL;
|
zone_options &= ~DNS_ZONEOPT_CHECKDUPRRFAIL;
|
||||||
} else {
|
} else
|
||||||
INSIST(0);
|
INSIST(0);
|
||||||
ISC_UNREACHABLE();
|
|
||||||
}
|
|
||||||
} else {
|
} else {
|
||||||
zone_options |= DNS_ZONEOPT_CHECKDUPRR;
|
zone_options |= DNS_ZONEOPT_CHECKDUPRR;
|
||||||
zone_options &= ~DNS_ZONEOPT_CHECKDUPRRFAIL;
|
zone_options &= ~DNS_ZONEOPT_CHECKDUPRRFAIL;
|
||||||
@@ -302,10 +300,8 @@ configure_zone(const char *vclass, const char *view,
|
|||||||
} else if (strcasecmp(cfg_obj_asstring(obj), "ignore") == 0) {
|
} else if (strcasecmp(cfg_obj_asstring(obj), "ignore") == 0) {
|
||||||
zone_options &= ~DNS_ZONEOPT_CHECKMX;
|
zone_options &= ~DNS_ZONEOPT_CHECKMX;
|
||||||
zone_options &= ~DNS_ZONEOPT_CHECKMXFAIL;
|
zone_options &= ~DNS_ZONEOPT_CHECKMXFAIL;
|
||||||
} else {
|
} else
|
||||||
INSIST(0);
|
INSIST(0);
|
||||||
ISC_UNREACHABLE();
|
|
||||||
}
|
|
||||||
} else {
|
} else {
|
||||||
zone_options |= DNS_ZONEOPT_CHECKMX;
|
zone_options |= DNS_ZONEOPT_CHECKMX;
|
||||||
zone_options &= ~DNS_ZONEOPT_CHECKMXFAIL;
|
zone_options &= ~DNS_ZONEOPT_CHECKMXFAIL;
|
||||||
@@ -331,10 +327,8 @@ configure_zone(const char *vclass, const char *view,
|
|||||||
} else if (strcasecmp(cfg_obj_asstring(obj), "ignore") == 0) {
|
} else if (strcasecmp(cfg_obj_asstring(obj), "ignore") == 0) {
|
||||||
zone_options |= DNS_ZONEOPT_WARNMXCNAME;
|
zone_options |= DNS_ZONEOPT_WARNMXCNAME;
|
||||||
zone_options |= DNS_ZONEOPT_IGNOREMXCNAME;
|
zone_options |= DNS_ZONEOPT_IGNOREMXCNAME;
|
||||||
} else {
|
} else
|
||||||
INSIST(0);
|
INSIST(0);
|
||||||
ISC_UNREACHABLE();
|
|
||||||
}
|
|
||||||
} else {
|
} else {
|
||||||
zone_options |= DNS_ZONEOPT_WARNMXCNAME;
|
zone_options |= DNS_ZONEOPT_WARNMXCNAME;
|
||||||
zone_options &= ~DNS_ZONEOPT_IGNOREMXCNAME;
|
zone_options &= ~DNS_ZONEOPT_IGNOREMXCNAME;
|
||||||
@@ -351,10 +345,8 @@ configure_zone(const char *vclass, const char *view,
|
|||||||
} else if (strcasecmp(cfg_obj_asstring(obj), "ignore") == 0) {
|
} else if (strcasecmp(cfg_obj_asstring(obj), "ignore") == 0) {
|
||||||
zone_options |= DNS_ZONEOPT_WARNSRVCNAME;
|
zone_options |= DNS_ZONEOPT_WARNSRVCNAME;
|
||||||
zone_options |= DNS_ZONEOPT_IGNORESRVCNAME;
|
zone_options |= DNS_ZONEOPT_IGNORESRVCNAME;
|
||||||
} else {
|
} else
|
||||||
INSIST(0);
|
INSIST(0);
|
||||||
ISC_UNREACHABLE();
|
|
||||||
}
|
|
||||||
} else {
|
} else {
|
||||||
zone_options |= DNS_ZONEOPT_WARNSRVCNAME;
|
zone_options |= DNS_ZONEOPT_WARNSRVCNAME;
|
||||||
zone_options &= ~DNS_ZONEOPT_IGNORESRVCNAME;
|
zone_options &= ~DNS_ZONEOPT_IGNORESRVCNAME;
|
||||||
@@ -374,10 +366,8 @@ configure_zone(const char *vclass, const char *view,
|
|||||||
zone_options |= DNS_ZONEOPT_CHECKSPF;
|
zone_options |= DNS_ZONEOPT_CHECKSPF;
|
||||||
} else if (strcasecmp(cfg_obj_asstring(obj), "ignore") == 0) {
|
} else if (strcasecmp(cfg_obj_asstring(obj), "ignore") == 0) {
|
||||||
zone_options &= ~DNS_ZONEOPT_CHECKSPF;
|
zone_options &= ~DNS_ZONEOPT_CHECKSPF;
|
||||||
} else {
|
} else
|
||||||
INSIST(0);
|
INSIST(0);
|
||||||
ISC_UNREACHABLE();
|
|
||||||
}
|
|
||||||
} else {
|
} else {
|
||||||
zone_options |= DNS_ZONEOPT_CHECKSPF;
|
zone_options |= DNS_ZONEOPT_CHECKSPF;
|
||||||
}
|
}
|
||||||
@@ -393,10 +383,8 @@ configure_zone(const char *vclass, const char *view,
|
|||||||
} else if (strcasecmp(cfg_obj_asstring(obj), "ignore") == 0) {
|
} else if (strcasecmp(cfg_obj_asstring(obj), "ignore") == 0) {
|
||||||
zone_options &= ~DNS_ZONEOPT_CHECKNAMES;
|
zone_options &= ~DNS_ZONEOPT_CHECKNAMES;
|
||||||
zone_options &= ~DNS_ZONEOPT_CHECKNAMESFAIL;
|
zone_options &= ~DNS_ZONEOPT_CHECKNAMESFAIL;
|
||||||
} else {
|
} else
|
||||||
INSIST(0);
|
INSIST(0);
|
||||||
ISC_UNREACHABLE();
|
|
||||||
}
|
|
||||||
} else {
|
} else {
|
||||||
zone_options |= DNS_ZONEOPT_CHECKNAMES;
|
zone_options |= DNS_ZONEOPT_CHECKNAMES;
|
||||||
zone_options |= DNS_ZONEOPT_CHECKNAMESFAIL;
|
zone_options |= DNS_ZONEOPT_CHECKNAMESFAIL;
|
||||||
@@ -406,16 +394,14 @@ configure_zone(const char *vclass, const char *view,
|
|||||||
fmtobj = NULL;
|
fmtobj = NULL;
|
||||||
if (get_maps(maps, "masterfile-format", &fmtobj)) {
|
if (get_maps(maps, "masterfile-format", &fmtobj)) {
|
||||||
const char *masterformatstr = cfg_obj_asstring(fmtobj);
|
const char *masterformatstr = cfg_obj_asstring(fmtobj);
|
||||||
if (strcasecmp(masterformatstr, "text") == 0) {
|
if (strcasecmp(masterformatstr, "text") == 0)
|
||||||
masterformat = dns_masterformat_text;
|
masterformat = dns_masterformat_text;
|
||||||
} else if (strcasecmp(masterformatstr, "raw") == 0) {
|
else if (strcasecmp(masterformatstr, "raw") == 0)
|
||||||
masterformat = dns_masterformat_raw;
|
masterformat = dns_masterformat_raw;
|
||||||
} else if (strcasecmp(masterformatstr, "map") == 0) {
|
else if (strcasecmp(masterformatstr, "map") == 0)
|
||||||
masterformat = dns_masterformat_map;
|
masterformat = dns_masterformat_map;
|
||||||
} else {
|
else
|
||||||
INSIST(0);
|
INSIST(0);
|
||||||
ISC_UNREACHABLE();
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
obj = NULL;
|
obj = NULL;
|
||||||
|
|||||||
@@ -139,14 +139,12 @@ main(int argc, char **argv) {
|
|||||||
#define PROGCMP(X) \
|
#define PROGCMP(X) \
|
||||||
(strcasecmp(prog_name, X) == 0 || strcasecmp(prog_name, X ".exe") == 0)
|
(strcasecmp(prog_name, X) == 0 || strcasecmp(prog_name, X ".exe") == 0)
|
||||||
|
|
||||||
if (PROGCMP("named-checkzone")) {
|
if (PROGCMP("named-checkzone"))
|
||||||
progmode = progmode_check;
|
progmode = progmode_check;
|
||||||
} else if (PROGCMP("named-compilezone")) {
|
else if (PROGCMP("named-compilezone"))
|
||||||
progmode = progmode_compile;
|
progmode = progmode_compile;
|
||||||
} else {
|
else
|
||||||
INSIST(0);
|
INSIST(0);
|
||||||
ISC_UNREACHABLE();
|
|
||||||
}
|
|
||||||
|
|
||||||
/* Compilation specific defaults */
|
/* Compilation specific defaults */
|
||||||
if (progmode == progmode_compile) {
|
if (progmode == progmode_compile) {
|
||||||
|
|||||||
@@ -125,12 +125,10 @@ main(int argc, char **argv) {
|
|||||||
if (PROGCMP("tsig-keygen")) {
|
if (PROGCMP("tsig-keygen")) {
|
||||||
progmode = progmode_keygen;
|
progmode = progmode_keygen;
|
||||||
quiet = true;
|
quiet = true;
|
||||||
} else if (PROGCMP("ddns-confgen")) {
|
} else if (PROGCMP("ddns-confgen"))
|
||||||
progmode = progmode_confgen;
|
progmode = progmode_confgen;
|
||||||
} else {
|
else
|
||||||
INSIST(0);
|
INSIST(0);
|
||||||
ISC_UNREACHABLE();
|
|
||||||
}
|
|
||||||
|
|
||||||
isc_commandline_errprint = false;
|
isc_commandline_errprint = false;
|
||||||
|
|
||||||
|
|||||||
+2
-35
@@ -765,14 +765,7 @@ setup_dnsseckeys(dns_client_t *client) {
|
|||||||
if (dlv_validation)
|
if (dlv_validation)
|
||||||
dns_client_setdlv(client, dns_rdataclass_in, dlv_anchor);
|
dns_client_setdlv(client, dns_rdataclass_in, dlv_anchor);
|
||||||
|
|
||||||
|
|
||||||
cleanup:
|
cleanup:
|
||||||
if (bindkeys != NULL) {
|
|
||||||
cfg_obj_destroy(parser, &bindkeys);
|
|
||||||
}
|
|
||||||
if (parser != NULL) {
|
|
||||||
cfg_parser_destroy(&parser);
|
|
||||||
}
|
|
||||||
if (result != ISC_R_SUCCESS)
|
if (result != ISC_R_SUCCESS)
|
||||||
delv_log(ISC_LOG_ERROR, "setup_dnsseckeys: %s",
|
delv_log(ISC_LOG_ERROR, "setup_dnsseckeys: %s",
|
||||||
isc_result_totext(result));
|
isc_result_totext(result));
|
||||||
@@ -1174,8 +1167,6 @@ plus_option(char *option) {
|
|||||||
* options: "46a:b:c:d:himp:q:t:vx:";
|
* options: "46a:b:c:d:himp:q:t:vx:";
|
||||||
*/
|
*/
|
||||||
static const char *single_dash_opts = "46himv";
|
static const char *single_dash_opts = "46himv";
|
||||||
static const char *dash_opts = "46abcdhimpqtvx";
|
|
||||||
|
|
||||||
static bool
|
static bool
|
||||||
dash_option(char *option, char *next, bool *open_type_class) {
|
dash_option(char *option, char *next, bool *open_type_class) {
|
||||||
char opt, *value;
|
char opt, *value;
|
||||||
@@ -1233,7 +1224,6 @@ dash_option(char *option, char *next, bool *open_type_class) {
|
|||||||
/* NOTREACHED */
|
/* NOTREACHED */
|
||||||
default:
|
default:
|
||||||
INSIST(0);
|
INSIST(0);
|
||||||
ISC_UNREACHABLE();
|
|
||||||
}
|
}
|
||||||
if (strlen(option) > 1U)
|
if (strlen(option) > 1U)
|
||||||
option = &option[1];
|
option = &option[1];
|
||||||
@@ -1377,10 +1367,8 @@ preparse_args(int argc, char **argv) {
|
|||||||
char *option;
|
char *option;
|
||||||
|
|
||||||
for (argc--, argv++; argc > 0; argc--, argv++) {
|
for (argc--, argv++; argc > 0; argc--, argv++) {
|
||||||
if (argv[0][0] != '-') {
|
if (argv[0][0] != '-')
|
||||||
continue;
|
continue;
|
||||||
}
|
|
||||||
|
|
||||||
option = &argv[0][1];
|
option = &argv[0][1];
|
||||||
while (strpbrk(option, single_dash_opts) == &option[0]) {
|
while (strpbrk(option, single_dash_opts) == &option[0]) {
|
||||||
switch (option[0]) {
|
switch (option[0]) {
|
||||||
@@ -1403,27 +1391,6 @@ preparse_args(int argc, char **argv) {
|
|||||||
}
|
}
|
||||||
option = &option[1];
|
option = &option[1];
|
||||||
}
|
}
|
||||||
|
|
||||||
if (strlen(option) == 0U) {
|
|
||||||
continue;
|
|
||||||
}
|
|
||||||
|
|
||||||
/* Look for dash value 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. */
|
|
||||||
argc--;
|
|
||||||
argv++;
|
|
||||||
|
|
||||||
/* Handle missing argument */
|
|
||||||
if (argc == 0) {
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -1623,7 +1590,7 @@ main(int argc, char *argv[]) {
|
|||||||
fatal("failed to create mctx");
|
fatal("failed to create mctx");
|
||||||
|
|
||||||
CHECK(isc_appctx_create(mctx, &actx));
|
CHECK(isc_appctx_create(mctx, &actx));
|
||||||
CHECK(isc_taskmgr_createinctx(mctx, actx, 1, &taskmgr));
|
CHECK(isc_taskmgr_createinctx(mctx, actx, 1, 0, &taskmgr));
|
||||||
CHECK(isc_socketmgr_createinctx(mctx, actx, &socketmgr));
|
CHECK(isc_socketmgr_createinctx(mctx, actx, &socketmgr));
|
||||||
CHECK(isc_timermgr_createinctx(mctx, actx, &timermgr));
|
CHECK(isc_timermgr_createinctx(mctx, actx, &timermgr));
|
||||||
|
|
||||||
|
|||||||
+3
-3
@@ -101,12 +101,12 @@ install:: dig@EXEEXT@ host@EXEEXT@ nslookup@EXEEXT@ installdirs
|
|||||||
${LIBTOOL_MODE_INSTALL} ${INSTALL_PROGRAM} \
|
${LIBTOOL_MODE_INSTALL} ${INSTALL_PROGRAM} \
|
||||||
nslookup@EXEEXT@ ${DESTDIR}${bindir}
|
nslookup@EXEEXT@ ${DESTDIR}${bindir}
|
||||||
for m in ${MANPAGES}; do \
|
for m in ${MANPAGES}; do \
|
||||||
${INSTALL_DATA} ${srcdir}/$$m ${DESTDIR}${mandir}/man1 || exit 1; \
|
${INSTALL_DATA} ${srcdir}/$$m ${DESTDIR}${mandir}/man1; \
|
||||||
done
|
done
|
||||||
|
|
||||||
uninstall::
|
uninstall::
|
||||||
for m in ${MANPAGES}; do \
|
for m in ${MANPAGES}; do \
|
||||||
rm -f ${DESTDIR}${mandir}/man1/$$m || exit 1; \
|
rm -f ${DESTDIR}${mandir}/man1/$$m ; \
|
||||||
done
|
done
|
||||||
${LIBTOOL_MODE_UNINSTALL} rm -f ${DESTDIR}${bindir}/nslookup@EXEEXT@
|
${LIBTOOL_MODE_UNINSTALL} rm -f ${DESTDIR}${bindir}/nslookup@EXEEXT@
|
||||||
${LIBTOOL_MODE_UNINSTALL} rm -f ${DESTDIR}${bindir}/host@EXEEXT@
|
${LIBTOOL_MODE_UNINSTALL} rm -f ${DESTDIR}${bindir}/host@EXEEXT@
|
||||||
|
|||||||
+12
-20
@@ -74,9 +74,7 @@ will perform an NS query for "\&." (the root)\&.
|
|||||||
It is possible to set per\-user defaults for
|
It is possible to set per\-user defaults for
|
||||||
\fBdig\fR
|
\fBdig\fR
|
||||||
via
|
via
|
||||||
${HOME}/\&.digrc\&. This file is read and any options in it are applied before the command line arguments\&. The
|
${HOME}/\&.digrc\&. This file is read and any options in it are applied before the command line arguments\&.
|
||||||
\fB\-r\fR
|
|
||||||
option disables this feature, for scripts that need predictable behaviour\&.
|
|
||||||
.PP
|
.PP
|
||||||
The IN and CH class names overlap with the IN and CH top level domain names\&. Either use the
|
The IN and CH class names overlap with the IN and CH top level domain names\&. Either use the
|
||||||
\fB\-t\fR
|
\fB\-t\fR
|
||||||
@@ -176,6 +174,11 @@ reads a list of lookup requests to process from the given
|
|||||||
using the command\-line interface\&.
|
using the command\-line interface\&.
|
||||||
.RE
|
.RE
|
||||||
.PP
|
.PP
|
||||||
|
\-i
|
||||||
|
.RS 4
|
||||||
|
Do reverse IPv6 lookups using the obsolete RFC 1886 IP6\&.INT domain, which is no longer in use\&. Obsolete bit string label queries (RFC 2874) are not attempted\&.
|
||||||
|
.RE
|
||||||
|
.PP
|
||||||
\-k \fIkeyfile\fR
|
\-k \fIkeyfile\fR
|
||||||
.RS 4
|
.RS 4
|
||||||
Sign queries using TSIG using a key read from the given file\&. Key files can be generated using
|
Sign queries using TSIG using a key read from the given file\&. Key files can be generated using
|
||||||
@@ -205,12 +208,6 @@ The domain name to query\&. This is useful to distinguish the
|
|||||||
from other arguments\&.
|
from other arguments\&.
|
||||||
.RE
|
.RE
|
||||||
.PP
|
.PP
|
||||||
\-r
|
|
||||||
.RS 4
|
|
||||||
Do not read options from
|
|
||||||
${HOME}/\&.digrc\&. This is useful for scripts that need predictable behaviour\&.
|
|
||||||
.RE
|
|
||||||
.PP
|
|
||||||
\-t \fItype\fR
|
\-t \fItype\fR
|
||||||
.RS 4
|
.RS 4
|
||||||
The resource record type to query\&. It can be any valid query type\&. If it is a resource record type supported in BIND 9, it can be given by the type mnemonic (such as "NS" or "AAAA")\&. The default query type is "A", unless the
|
The resource record type to query\&. It can be any valid query type\&. If it is a resource record type supported in BIND 9, it can be given by the type mnemonic (such as "NS" or "AAAA")\&. The default query type is "A", unless the
|
||||||
@@ -249,7 +246,9 @@ arguments\&.
|
|||||||
\fBdig\fR
|
\fBdig\fR
|
||||||
automatically performs a lookup for a name like
|
automatically performs a lookup for a name like
|
||||||
94\&.2\&.0\&.192\&.in\-addr\&.arpa
|
94\&.2\&.0\&.192\&.in\-addr\&.arpa
|
||||||
and sets the query type and class to PTR and IN respectively\&. IPv6 addresses are looked up using nibble format under the IP6\&.ARPA domain\&.
|
and sets the query type and class to PTR and IN respectively\&. IPv6 addresses are looked up using nibble format under the IP6\&.ARPA domain (but see also the
|
||||||
|
\fB\-i\fR
|
||||||
|
option)\&.
|
||||||
.RE
|
.RE
|
||||||
.PP
|
.PP
|
||||||
\-y \fI[hmac:]\fR\fIkeyname:secret\fR
|
\-y \fI[hmac:]\fR\fIkeyname:secret\fR
|
||||||
@@ -469,16 +468,12 @@ option is enabled\&. If short form answers are requested, the default is not to
|
|||||||
.PP
|
.PP
|
||||||
\fB+[no]idnin\fR
|
\fB+[no]idnin\fR
|
||||||
.RS 4
|
.RS 4
|
||||||
Process [do not process] IDN domain names on input\&. This requires IDN SUPPORT to have been enabled at compile time\&.
|
Process [do not process] IDN domain names on input\&. This requires IDN SUPPORT to have been enabled at compile time\&. The default is to process IDN input\&.
|
||||||
.sp
|
|
||||||
The default is to process IDN input when standard output is a tty\&. The IDN processing on input is disabled when dig output is redirected to files, pipes, and other non\-tty file descriptors\&.
|
|
||||||
.RE
|
.RE
|
||||||
.PP
|
.PP
|
||||||
\fB+[no]idnout\fR
|
\fB+[no]idnout\fR
|
||||||
.RS 4
|
.RS 4
|
||||||
Convert [do not convert] puny code on output\&. This requires IDN SUPPORT to have been enabled at compile time\&.
|
Convert [do not convert] puny code on output\&. This requires IDN SUPPORT to have been enabled at compile time\&. The default is to convert output\&.
|
||||||
.sp
|
|
||||||
The default is to process puny code on output when standard output is a tty\&. The puny code processing on output is disabled when dig output is redirected to files, pipes, and other non\-tty file descriptors\&.
|
|
||||||
.RE
|
.RE
|
||||||
.PP
|
.PP
|
||||||
\fB+[no]ignore\fR
|
\fB+[no]ignore\fR
|
||||||
@@ -800,10 +795,7 @@ has been built with IDN (internationalized domain name) support, it can accept a
|
|||||||
appropriately converts character encoding of domain name before sending a request to DNS server or displaying a reply from the server\&. If you\*(Aqd like to turn off the IDN support for some reason, use parameters
|
appropriately converts character encoding of domain name before sending a request to DNS server or displaying a reply from the server\&. If you\*(Aqd like to turn off the IDN support for some reason, use parameters
|
||||||
\fI+noidnin\fR
|
\fI+noidnin\fR
|
||||||
and
|
and
|
||||||
\fI+noidnout\fR
|
\fI+noidnout\fR\&.
|
||||||
or define the
|
|
||||||
\fBIDN_DISABLE\fR
|
|
||||||
environment variable\&.
|
|
||||||
.SH "FILES"
|
.SH "FILES"
|
||||||
.PP
|
.PP
|
||||||
/etc/resolv\&.conf
|
/etc/resolv\&.conf
|
||||||
|
|||||||
+11
-43
@@ -65,8 +65,8 @@ static char domainopt[DNS_NAME_MAXTEXT];
|
|||||||
static char hexcookie[81];
|
static char hexcookie[81];
|
||||||
|
|
||||||
static bool short_form = false, printcmd = true,
|
static bool short_form = false, printcmd = true,
|
||||||
plusquest = false, pluscomm = false,
|
ip6_int = false, plusquest = false, pluscomm = false,
|
||||||
ipv4only = false, ipv6only = false, digrc = true;
|
ipv4only = false, ipv6only = false;
|
||||||
static uint32_t splitwidth = 0xffffffff;
|
static uint32_t splitwidth = 0xffffffff;
|
||||||
|
|
||||||
/*% opcode text */
|
/*% opcode text */
|
||||||
@@ -153,11 +153,11 @@ help(void) {
|
|||||||
" -b address[#port] (bind to source address/port)\n"
|
" -b address[#port] (bind to source address/port)\n"
|
||||||
" -c class (specify query class)\n"
|
" -c class (specify query class)\n"
|
||||||
" -f filename (batch mode)\n"
|
" -f filename (batch mode)\n"
|
||||||
|
" -i (use IP6.INT for IPv6 reverse lookups)\n"
|
||||||
" -k keyfile (specify tsig key file)\n"
|
" -k keyfile (specify tsig key file)\n"
|
||||||
" -m (enable memory usage debugging)\n"
|
" -m (enable memory usage debugging)\n"
|
||||||
" -p port (specify port number)\n"
|
" -p port (specify port number)\n"
|
||||||
" -q name (specify query name)\n"
|
" -q name (specify query name)\n"
|
||||||
" -r (do not read ~/.digrc)\n"
|
|
||||||
" -t type (specify query type)\n"
|
" -t type (specify query type)\n"
|
||||||
" -u (display times in usec instead of msec)\n"
|
" -u (display times in usec instead of msec)\n"
|
||||||
" -x dot-notation (shortcut for reverse lookups)\n"
|
" -x dot-notation (shortcut for reverse lookups)\n"
|
||||||
@@ -193,10 +193,8 @@ help(void) {
|
|||||||
" +[no]fail (Don't try next server on SERVFAIL)\n"
|
" +[no]fail (Don't try next server on SERVFAIL)\n"
|
||||||
" +[no]header-only (Send query without a question section)\n"
|
" +[no]header-only (Send query without a question section)\n"
|
||||||
" +[no]identify (ID responders in short answers)\n"
|
" +[no]identify (ID responders in short answers)\n"
|
||||||
#ifdef HAVE_LIBIDN2
|
" +[no]idnin (Parse IDN names)\n"
|
||||||
" +[no]idnin (Parse IDN names [default=on on tty])\n"
|
" +[no]idnout (Convert IDN response)\n"
|
||||||
" +[no]idnout (Convert IDN response [default=on on tty])\n"
|
|
||||||
#endif
|
|
||||||
" +[no]ignore (Don't revert to TCP for TC responses.)\n"
|
" +[no]ignore (Don't revert to TCP for TC responses.)\n"
|
||||||
" +[no]keepalive (Request EDNS TCP keepalive)\n"
|
" +[no]keepalive (Request EDNS TCP keepalive)\n"
|
||||||
" +[no]keepopen (Keep the TCP socket open between queries)\n"
|
" +[no]keepopen (Keep the TCP socket open between queries)\n"
|
||||||
@@ -1544,8 +1542,8 @@ plus_option(char *option, bool is_batchfile,
|
|||||||
/*%
|
/*%
|
||||||
* #true returned if value was used
|
* #true returned if value was used
|
||||||
*/
|
*/
|
||||||
static const char *single_dash_opts = "46dhimnruv";
|
static const char *single_dash_opts = "46dhimnuv";
|
||||||
static const char *dash_opts = "46bcdfhikmnpqrtvyx";
|
static const char *dash_opts = "46bcdfhikmnptvyx";
|
||||||
static bool
|
static bool
|
||||||
dash_option(char *option, char *next, dig_lookup_t **lookup,
|
dash_option(char *option, char *next, dig_lookup_t **lookup,
|
||||||
bool *open_type_class, bool *need_clone,
|
bool *open_type_class, bool *need_clone,
|
||||||
@@ -1608,7 +1606,7 @@ dash_option(char *option, char *next, dig_lookup_t **lookup,
|
|||||||
exit(0);
|
exit(0);
|
||||||
break;
|
break;
|
||||||
case 'i':
|
case 'i':
|
||||||
/* deprecated */
|
ip6_int = true;
|
||||||
break;
|
break;
|
||||||
case 'm': /* memdebug */
|
case 'm': /* memdebug */
|
||||||
/* memdebug is handled in preparse_args() */
|
/* memdebug is handled in preparse_args() */
|
||||||
@@ -1616,10 +1614,6 @@ dash_option(char *option, char *next, dig_lookup_t **lookup,
|
|||||||
case 'n':
|
case 'n':
|
||||||
/* deprecated */
|
/* deprecated */
|
||||||
break;
|
break;
|
||||||
case 'r':
|
|
||||||
debug("digrc (late)");
|
|
||||||
digrc = false;
|
|
||||||
break;
|
|
||||||
case 'u':
|
case 'u':
|
||||||
(*lookup)->use_usec = true;
|
(*lookup)->use_usec = true;
|
||||||
break;
|
break;
|
||||||
@@ -1793,12 +1787,13 @@ dash_option(char *option, char *next, dig_lookup_t **lookup,
|
|||||||
*lookup = clone_lookup(default_lookup, true);
|
*lookup = clone_lookup(default_lookup, true);
|
||||||
*need_clone = true;
|
*need_clone = true;
|
||||||
if (get_reverse(textname, sizeof(textname), value,
|
if (get_reverse(textname, sizeof(textname), value,
|
||||||
false) == ISC_R_SUCCESS) {
|
ip6_int, false) == ISC_R_SUCCESS) {
|
||||||
strlcpy((*lookup)->textname, textname,
|
strlcpy((*lookup)->textname, textname,
|
||||||
sizeof((*lookup)->textname));
|
sizeof((*lookup)->textname));
|
||||||
debug("looking up %s", (*lookup)->textname);
|
debug("looking up %s", (*lookup)->textname);
|
||||||
(*lookup)->trace_root = ((*lookup)->trace ||
|
(*lookup)->trace_root = ((*lookup)->trace ||
|
||||||
(*lookup)->ns_search_only);
|
(*lookup)->ns_search_only);
|
||||||
|
(*lookup)->ip6_int = ip6_int;
|
||||||
if (!(*lookup)->rdtypeset)
|
if (!(*lookup)->rdtypeset)
|
||||||
(*lookup)->rdtype = dns_rdatatype_ptr;
|
(*lookup)->rdtype = dns_rdatatype_ptr;
|
||||||
if (!(*lookup)->rdclassset)
|
if (!(*lookup)->rdclassset)
|
||||||
@@ -1846,23 +1841,11 @@ preparse_args(int argc, char **argv) {
|
|||||||
option = &rv[0][1];
|
option = &rv[0][1];
|
||||||
while (strpbrk(option, single_dash_opts) == &option[0]) {
|
while (strpbrk(option, single_dash_opts) == &option[0]) {
|
||||||
switch (option[0]) {
|
switch (option[0]) {
|
||||||
case 'd':
|
|
||||||
/* For debugging early startup */
|
|
||||||
debugging = true;
|
|
||||||
break;
|
|
||||||
case 'm':
|
case 'm':
|
||||||
memdebugging = true;
|
memdebugging = true;
|
||||||
isc_mem_debugging = ISC_MEM_DEBUGTRACE |
|
isc_mem_debugging = ISC_MEM_DEBUGTRACE |
|
||||||
ISC_MEM_DEBUGRECORD;
|
ISC_MEM_DEBUGRECORD;
|
||||||
break;
|
break;
|
||||||
case 'r':
|
|
||||||
/*
|
|
||||||
* Must be done early, because ~/.digrc
|
|
||||||
* is read before command line parsing
|
|
||||||
*/
|
|
||||||
debug("digrc (early)");
|
|
||||||
digrc = false;
|
|
||||||
break;
|
|
||||||
case '4':
|
case '4':
|
||||||
if (ipv6only)
|
if (ipv6only)
|
||||||
fatal("only one of -4 and -6 allowed");
|
fatal("only one of -4 and -6 allowed");
|
||||||
@@ -1876,20 +1859,6 @@ preparse_args(int argc, char **argv) {
|
|||||||
}
|
}
|
||||||
option = &option[1];
|
option = &option[1];
|
||||||
}
|
}
|
||||||
if (strlen(option) == 0U) {
|
|
||||||
continue;
|
|
||||||
}
|
|
||||||
/* Look for dash value 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)
|
|
||||||
break;
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -1956,9 +1925,8 @@ parse_args(bool is_batchfile, bool config_only,
|
|||||||
*/
|
*/
|
||||||
INSIST(batchfp == NULL);
|
INSIST(batchfp == NULL);
|
||||||
homedir = getenv("HOME");
|
homedir = getenv("HOME");
|
||||||
if (homedir != NULL && digrc) {
|
if (homedir != NULL) {
|
||||||
unsigned int n;
|
unsigned int n;
|
||||||
debug("digrc (open)");
|
|
||||||
n = snprintf(rcfile, sizeof(rcfile), "%s/.digrc",
|
n = snprintf(rcfile, sizeof(rcfile), "%s/.digrc",
|
||||||
homedir);
|
homedir);
|
||||||
if (n < sizeof(rcfile)) {
|
if (n < sizeof(rcfile)) {
|
||||||
|
|||||||
+19
-32
@@ -131,10 +131,9 @@
|
|||||||
|
|
||||||
<para>
|
<para>
|
||||||
It is possible to set per-user defaults for <command>dig</command> via
|
It is possible to set per-user defaults for <command>dig</command> via
|
||||||
<filename>${HOME}/.digrc</filename>. This file is read and any
|
<filename>${HOME}/.digrc</filename>. This file is read and
|
||||||
options in it are applied before the command line arguments.
|
any options in it
|
||||||
The <option>-r</option> option disables this feature, for
|
are applied before the command line arguments.
|
||||||
scripts that need predictable behaviour.
|
|
||||||
</para>
|
</para>
|
||||||
|
|
||||||
<para>
|
<para>
|
||||||
@@ -272,6 +271,17 @@
|
|||||||
</listitem>
|
</listitem>
|
||||||
</varlistentry>
|
</varlistentry>
|
||||||
|
|
||||||
|
<varlistentry>
|
||||||
|
<term>-i</term>
|
||||||
|
<listitem>
|
||||||
|
<para>
|
||||||
|
Do reverse IPv6 lookups using the obsolete RFC 1886 IP6.INT
|
||||||
|
domain, which is no longer in use. Obsolete bit string
|
||||||
|
label queries (RFC 2874) are not attempted.
|
||||||
|
</para>
|
||||||
|
</listitem>
|
||||||
|
</varlistentry>
|
||||||
|
|
||||||
<varlistentry>
|
<varlistentry>
|
||||||
<term>-k <replaceable class="parameter">keyfile</replaceable></term>
|
<term>-k <replaceable class="parameter">keyfile</replaceable></term>
|
||||||
<listitem>
|
<listitem>
|
||||||
@@ -324,16 +334,6 @@
|
|||||||
</listitem>
|
</listitem>
|
||||||
</varlistentry>
|
</varlistentry>
|
||||||
|
|
||||||
<varlistentry>
|
|
||||||
<term>-r</term>
|
|
||||||
<listitem>
|
|
||||||
<para>
|
|
||||||
Do not read options from <filename>${HOME}/.digrc</filename>.
|
|
||||||
This is useful for scripts that need predictable behaviour.
|
|
||||||
</para>
|
|
||||||
</listitem>
|
|
||||||
</varlistentry>
|
|
||||||
|
|
||||||
<varlistentry>
|
<varlistentry>
|
||||||
<term>-t <replaceable class="parameter">type</replaceable></term>
|
<term>-t <replaceable class="parameter">type</replaceable></term>
|
||||||
<listitem>
|
<listitem>
|
||||||
@@ -394,7 +394,8 @@
|
|||||||
<literal>94.2.0.192.in-addr.arpa</literal> and sets the
|
<literal>94.2.0.192.in-addr.arpa</literal> and sets the
|
||||||
query type and class to PTR and IN respectively. IPv6
|
query type and class to PTR and IN respectively. IPv6
|
||||||
addresses are looked up using nibble format under the
|
addresses are looked up using nibble format under the
|
||||||
IP6.ARPA domain.
|
IP6.ARPA domain (but see also the <option>-i</option>
|
||||||
|
option).
|
||||||
</para>
|
</para>
|
||||||
</listitem>
|
</listitem>
|
||||||
</varlistentry>
|
</varlistentry>
|
||||||
@@ -788,13 +789,7 @@
|
|||||||
<para>
|
<para>
|
||||||
Process [do not process] IDN domain names on input.
|
Process [do not process] IDN domain names on input.
|
||||||
This requires IDN SUPPORT to have been enabled at
|
This requires IDN SUPPORT to have been enabled at
|
||||||
compile time.
|
compile time. The default is to process IDN input.
|
||||||
</para>
|
|
||||||
<para>
|
|
||||||
The default is to process IDN input when standard output
|
|
||||||
is a tty. The IDN processing on input is disabled when
|
|
||||||
dig output is redirected to files, pipes, and other
|
|
||||||
non-tty file descriptors.
|
|
||||||
</para>
|
</para>
|
||||||
</listitem>
|
</listitem>
|
||||||
</varlistentry>
|
</varlistentry>
|
||||||
@@ -805,13 +800,7 @@
|
|||||||
<para>
|
<para>
|
||||||
Convert [do not convert] puny code on output.
|
Convert [do not convert] puny code on output.
|
||||||
This requires IDN SUPPORT to have been enabled at
|
This requires IDN SUPPORT to have been enabled at
|
||||||
compile time.
|
compile time. The default is to convert output.
|
||||||
</para>
|
|
||||||
<para>
|
|
||||||
The default is to process puny code on output when
|
|
||||||
standard output is a tty. The puny code processing on
|
|
||||||
output is disabled when dig output is redirected to
|
|
||||||
files, pipes, and other non-tty file descriptors.
|
|
||||||
</para>
|
</para>
|
||||||
</listitem>
|
</listitem>
|
||||||
</varlistentry>
|
</varlistentry>
|
||||||
@@ -1341,9 +1330,7 @@ dig +qr www.isc.org any -x 127.0.0.1 isc.org ns +noqr
|
|||||||
reply from the server.
|
reply from the server.
|
||||||
If you'd like to turn off the IDN support for some reason, use
|
If you'd like to turn off the IDN support for some reason, use
|
||||||
parameters <parameter>+noidnin</parameter> and
|
parameters <parameter>+noidnin</parameter> and
|
||||||
<parameter>+noidnout</parameter> or define
|
<parameter>+noidnout</parameter>.
|
||||||
the <envar>IDN_DISABLE</envar> environment variable.
|
|
||||||
|
|
||||||
</para>
|
</para>
|
||||||
</refsection>
|
</refsection>
|
||||||
|
|
||||||
|
|||||||
+16
-29
@@ -106,10 +106,9 @@
|
|||||||
|
|
||||||
<p>
|
<p>
|
||||||
It is possible to set per-user defaults for <span class="command"><strong>dig</strong></span> via
|
It is possible to set per-user defaults for <span class="command"><strong>dig</strong></span> via
|
||||||
<code class="filename">${HOME}/.digrc</code>. This file is read and any
|
<code class="filename">${HOME}/.digrc</code>. This file is read and
|
||||||
options in it are applied before the command line arguments.
|
any options in it
|
||||||
The <code class="option">-r</code> option disables this feature, for
|
are applied before the command line arguments.
|
||||||
scripts that need predictable behaviour.
|
|
||||||
</p>
|
</p>
|
||||||
|
|
||||||
<p>
|
<p>
|
||||||
@@ -228,6 +227,14 @@
|
|||||||
<span class="command"><strong>dig</strong></span> using the command-line interface.
|
<span class="command"><strong>dig</strong></span> using the command-line interface.
|
||||||
</p>
|
</p>
|
||||||
</dd>
|
</dd>
|
||||||
|
<dt><span class="term">-i</span></dt>
|
||||||
|
<dd>
|
||||||
|
<p>
|
||||||
|
Do reverse IPv6 lookups using the obsolete RFC 1886 IP6.INT
|
||||||
|
domain, which is no longer in use. Obsolete bit string
|
||||||
|
label queries (RFC 2874) are not attempted.
|
||||||
|
</p>
|
||||||
|
</dd>
|
||||||
<dt><span class="term">-k <em class="replaceable"><code>keyfile</code></em></span></dt>
|
<dt><span class="term">-k <em class="replaceable"><code>keyfile</code></em></span></dt>
|
||||||
<dd>
|
<dd>
|
||||||
<p>
|
<p>
|
||||||
@@ -267,13 +274,6 @@
|
|||||||
the <em class="parameter"><code>name</code></em> from other arguments.
|
the <em class="parameter"><code>name</code></em> from other arguments.
|
||||||
</p>
|
</p>
|
||||||
</dd>
|
</dd>
|
||||||
<dt><span class="term">-r</span></dt>
|
|
||||||
<dd>
|
|
||||||
<p>
|
|
||||||
Do not read options from <code class="filename">${HOME}/.digrc</code>.
|
|
||||||
This is useful for scripts that need predictable behaviour.
|
|
||||||
</p>
|
|
||||||
</dd>
|
|
||||||
<dt><span class="term">-t <em class="replaceable"><code>type</code></em></span></dt>
|
<dt><span class="term">-t <em class="replaceable"><code>type</code></em></span></dt>
|
||||||
<dd>
|
<dd>
|
||||||
<p>
|
<p>
|
||||||
@@ -324,7 +324,8 @@
|
|||||||
<code class="literal">94.2.0.192.in-addr.arpa</code> and sets the
|
<code class="literal">94.2.0.192.in-addr.arpa</code> and sets the
|
||||||
query type and class to PTR and IN respectively. IPv6
|
query type and class to PTR and IN respectively. IPv6
|
||||||
addresses are looked up using nibble format under the
|
addresses are looked up using nibble format under the
|
||||||
IP6.ARPA domain.
|
IP6.ARPA domain (but see also the <code class="option">-i</code>
|
||||||
|
option).
|
||||||
</p>
|
</p>
|
||||||
</dd>
|
</dd>
|
||||||
<dt><span class="term">-y <em class="replaceable"><code>[<span class="optional">hmac:</span>]keyname:secret</code></em></span></dt>
|
<dt><span class="term">-y <em class="replaceable"><code>[<span class="optional">hmac:</span>]keyname:secret</code></em></span></dt>
|
||||||
@@ -630,13 +631,7 @@
|
|||||||
<p>
|
<p>
|
||||||
Process [do not process] IDN domain names on input.
|
Process [do not process] IDN domain names on input.
|
||||||
This requires IDN SUPPORT to have been enabled at
|
This requires IDN SUPPORT to have been enabled at
|
||||||
compile time.
|
compile time. The default is to process IDN input.
|
||||||
</p>
|
|
||||||
<p>
|
|
||||||
The default is to process IDN input when standard output
|
|
||||||
is a tty. The IDN processing on input is disabled when
|
|
||||||
dig output is redirected to files, pipes, and other
|
|
||||||
non-tty file descriptors.
|
|
||||||
</p>
|
</p>
|
||||||
</dd>
|
</dd>
|
||||||
<dt><span class="term"><code class="option">+[no]idnout</code></span></dt>
|
<dt><span class="term"><code class="option">+[no]idnout</code></span></dt>
|
||||||
@@ -644,13 +639,7 @@
|
|||||||
<p>
|
<p>
|
||||||
Convert [do not convert] puny code on output.
|
Convert [do not convert] puny code on output.
|
||||||
This requires IDN SUPPORT to have been enabled at
|
This requires IDN SUPPORT to have been enabled at
|
||||||
compile time.
|
compile time. The default is to convert output.
|
||||||
</p>
|
|
||||||
<p>
|
|
||||||
The default is to process puny code on output when
|
|
||||||
standard output is a tty. The puny code processing on
|
|
||||||
output is disabled when dig output is redirected to
|
|
||||||
files, pipes, and other non-tty file descriptors.
|
|
||||||
</p>
|
</p>
|
||||||
</dd>
|
</dd>
|
||||||
<dt><span class="term"><code class="option">+[no]ignore</code></span></dt>
|
<dt><span class="term"><code class="option">+[no]ignore</code></span></dt>
|
||||||
@@ -1072,9 +1061,7 @@ dig +qr www.isc.org any -x 127.0.0.1 isc.org ns +noqr
|
|||||||
reply from the server.
|
reply from the server.
|
||||||
If you'd like to turn off the IDN support for some reason, use
|
If you'd like to turn off the IDN support for some reason, use
|
||||||
parameters <em class="parameter"><code>+noidnin</code></em> and
|
parameters <em class="parameter"><code>+noidnin</code></em> and
|
||||||
<em class="parameter"><code>+noidnout</code></em> or define
|
<em class="parameter"><code>+noidnout</code></em>.
|
||||||
the <code class="envar">IDN_DISABLE</code> environment variable.
|
|
||||||
|
|
||||||
</p>
|
</p>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
|||||||
+122
-140
@@ -312,7 +312,8 @@ reverse_octets(const char *in, char **p, char *end) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
isc_result_t
|
isc_result_t
|
||||||
get_reverse(char *reverse, size_t len, char *value, bool strict)
|
get_reverse(char *reverse, size_t len, char *value, bool ip6_int,
|
||||||
|
bool strict)
|
||||||
{
|
{
|
||||||
int r;
|
int r;
|
||||||
isc_result_t result;
|
isc_result_t result;
|
||||||
@@ -326,6 +327,8 @@ get_reverse(char *reverse, size_t len, char *value, bool strict)
|
|||||||
dns_name_t *name;
|
dns_name_t *name;
|
||||||
unsigned int options = 0;
|
unsigned int options = 0;
|
||||||
|
|
||||||
|
if (ip6_int)
|
||||||
|
options |= DNS_BYADDROPT_IPV6INT;
|
||||||
name = dns_fixedname_initname(&fname);
|
name = dns_fixedname_initname(&fname);
|
||||||
result = dns_byaddr_createptrname(&addr, options, name);
|
result = dns_byaddr_createptrname(&addr, options, name);
|
||||||
if (result != ISC_R_SUCCESS)
|
if (result != ISC_R_SUCCESS)
|
||||||
@@ -625,8 +628,8 @@ make_empty_lookup(void) {
|
|||||||
looknew->ttlunits = false;
|
looknew->ttlunits = false;
|
||||||
looknew->qr = false;
|
looknew->qr = false;
|
||||||
#ifdef HAVE_LIBIDN2
|
#ifdef HAVE_LIBIDN2
|
||||||
looknew->idnin = isatty(1)?(getenv("IDN_DISABLE") == NULL):false;
|
looknew->idnin = true;
|
||||||
looknew->idnout = looknew->idnin;
|
looknew->idnout = true;
|
||||||
#else
|
#else
|
||||||
looknew->idnin = false;
|
looknew->idnin = false;
|
||||||
looknew->idnout = false;
|
looknew->idnout = false;
|
||||||
@@ -649,6 +652,7 @@ make_empty_lookup(void) {
|
|||||||
looknew->nsfound = 0;
|
looknew->nsfound = 0;
|
||||||
looknew->tcp_mode = false;
|
looknew->tcp_mode = false;
|
||||||
looknew->tcp_mode_set = false;
|
looknew->tcp_mode_set = false;
|
||||||
|
looknew->ip6_int = false;
|
||||||
looknew->comments = true;
|
looknew->comments = true;
|
||||||
looknew->stats = true;
|
looknew->stats = true;
|
||||||
looknew->section_question = true;
|
looknew->section_question = true;
|
||||||
@@ -1227,19 +1231,6 @@ create_search_list(irs_resconf_t *resconf) {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
/*%
|
|
||||||
* Append 'addr' to the list of servers to be queried. This function is only
|
|
||||||
* called when no server addresses are explicitly specified and either libirs
|
|
||||||
* returns an empty list of servers to use or none of the addresses returned by
|
|
||||||
* libirs are usable due to the specified address family restrictions.
|
|
||||||
*/
|
|
||||||
static void
|
|
||||||
add_fallback_nameserver(const char *addr) {
|
|
||||||
dig_server_t *server = make_server(addr, addr);
|
|
||||||
ISC_LINK_INIT(server, link);
|
|
||||||
ISC_LIST_APPEND(server_list, server, link);
|
|
||||||
}
|
|
||||||
|
|
||||||
/*%
|
/*%
|
||||||
* Setup the system as a whole, reading key information and resolv.conf
|
* Setup the system as a whole, reading key information and resolv.conf
|
||||||
* settings.
|
* settings.
|
||||||
@@ -1285,16 +1276,6 @@ setup_system(bool ipv4only, bool ipv6only) {
|
|||||||
get_server_list(resconf);
|
get_server_list(resconf);
|
||||||
}
|
}
|
||||||
|
|
||||||
/* If we don't find a nameserver fall back to localhost */
|
|
||||||
if (ISC_LIST_EMPTY(server_list)) {
|
|
||||||
if (have_ipv6) {
|
|
||||||
add_fallback_nameserver("::1");
|
|
||||||
}
|
|
||||||
if (have_ipv4) {
|
|
||||||
add_fallback_nameserver("127.0.0.1");
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
irs_resconf_destroy(&resconf);
|
irs_resconf_destroy(&resconf);
|
||||||
|
|
||||||
#ifdef HAVE_SETLOCALE
|
#ifdef HAVE_SETLOCALE
|
||||||
@@ -1363,7 +1344,7 @@ setup_libs(void) {
|
|||||||
|
|
||||||
isc_log_setdebuglevel(lctx, 0);
|
isc_log_setdebuglevel(lctx, 0);
|
||||||
|
|
||||||
result = isc_taskmgr_create(mctx, 1, &taskmgr);
|
result = isc_taskmgr_create(mctx, 1, 0, &taskmgr);
|
||||||
check_result(result, "isc_taskmgr_create");
|
check_result(result, "isc_taskmgr_create");
|
||||||
|
|
||||||
result = isc_task_create(taskmgr, 0, &global_task);
|
result = isc_task_create(taskmgr, 0, &global_task);
|
||||||
@@ -1390,7 +1371,8 @@ setup_libs(void) {
|
|||||||
isc_mempool_setfreemax(commctx, 6);
|
isc_mempool_setfreemax(commctx, 6);
|
||||||
isc_mempool_setfillcount(commctx, 2);
|
isc_mempool_setfillcount(commctx, 2);
|
||||||
|
|
||||||
isc_mutex_init(&lookup_lock);
|
result = isc_mutex_init(&lookup_lock);
|
||||||
|
check_result(result, "isc_mutex_init");
|
||||||
}
|
}
|
||||||
|
|
||||||
typedef struct dig_ednsoptname {
|
typedef struct dig_ednsoptname {
|
||||||
@@ -1541,21 +1523,23 @@ clear_query(dig_query_t *query) {
|
|||||||
|
|
||||||
debug("clear_query(%p)", query);
|
debug("clear_query(%p)", query);
|
||||||
|
|
||||||
if (query->timer != NULL) {
|
if (query->timer != NULL)
|
||||||
isc_timer_detach(&query->timer);
|
isc_timer_detach(&query->timer);
|
||||||
}
|
|
||||||
lookup = query->lookup;
|
lookup = query->lookup;
|
||||||
|
|
||||||
if (lookup->current_query == query) {
|
if (lookup->current_query == query)
|
||||||
lookup->current_query = NULL;
|
lookup->current_query = NULL;
|
||||||
}
|
|
||||||
|
|
||||||
if (ISC_LINK_LINKED(query, link)) {
|
if (ISC_LINK_LINKED(query, link))
|
||||||
ISC_LIST_UNLINK(lookup->q, query, link);
|
ISC_LIST_UNLINK(lookup->q, query, link);
|
||||||
}
|
if (ISC_LINK_LINKED(query, clink))
|
||||||
if (ISC_LINK_LINKED(query, clink)) {
|
|
||||||
ISC_LIST_UNLINK(lookup->connecting, query, clink);
|
ISC_LIST_UNLINK(lookup->connecting, query, clink);
|
||||||
}
|
if (ISC_LINK_LINKED(&query->recvbuf, link))
|
||||||
|
ISC_LIST_DEQUEUE(query->recvlist, &query->recvbuf,
|
||||||
|
link);
|
||||||
|
if (ISC_LINK_LINKED(&query->lengthbuf, link))
|
||||||
|
ISC_LIST_DEQUEUE(query->lengthlist, &query->lengthbuf,
|
||||||
|
link);
|
||||||
INSIST(query->recvspace != NULL);
|
INSIST(query->recvspace != NULL);
|
||||||
|
|
||||||
if (query->sock != NULL) {
|
if (query->sock != NULL) {
|
||||||
@@ -1564,16 +1548,12 @@ clear_query(dig_query_t *query) {
|
|||||||
debug("sockcount=%d", sockcount);
|
debug("sockcount=%d", sockcount);
|
||||||
}
|
}
|
||||||
isc_mempool_put(commctx, query->recvspace);
|
isc_mempool_put(commctx, query->recvspace);
|
||||||
isc_mempool_put(commctx, query->tmpsendspace);
|
|
||||||
isc_buffer_invalidate(&query->recvbuf);
|
isc_buffer_invalidate(&query->recvbuf);
|
||||||
isc_buffer_invalidate(&query->lengthbuf);
|
isc_buffer_invalidate(&query->lengthbuf);
|
||||||
|
if (query->waiting_senddone)
|
||||||
if (query->waiting_senddone) {
|
|
||||||
query->pending_free = true;
|
query->pending_free = true;
|
||||||
} else {
|
else
|
||||||
query->magic = 0;
|
|
||||||
isc_mem_free(mctx, query);
|
isc_mem_free(mctx, query);
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/*%
|
/*%
|
||||||
@@ -2313,7 +2293,7 @@ setup_lookup(dig_lookup_t *lookup) {
|
|||||||
|
|
||||||
if (lookup->ecs_addr != NULL) {
|
if (lookup->ecs_addr != NULL) {
|
||||||
uint8_t addr[16];
|
uint8_t addr[16];
|
||||||
uint16_t family = 0;
|
uint16_t family;
|
||||||
uint32_t plen;
|
uint32_t plen;
|
||||||
struct sockaddr *sa;
|
struct sockaddr *sa;
|
||||||
struct sockaddr_in *sin;
|
struct sockaddr_in *sin;
|
||||||
@@ -2370,7 +2350,6 @@ setup_lookup(dig_lookup_t *lookup) {
|
|||||||
break;
|
break;
|
||||||
default:
|
default:
|
||||||
INSIST(0);
|
INSIST(0);
|
||||||
ISC_UNREACHABLE();
|
|
||||||
}
|
}
|
||||||
|
|
||||||
isc_buffer_init(&b, ecsbuf, sizeof(ecsbuf));
|
isc_buffer_init(&b, ecsbuf, sizeof(ecsbuf));
|
||||||
@@ -2482,14 +2461,13 @@ setup_lookup(dig_lookup_t *lookup) {
|
|||||||
|
|
||||||
for (serv = ISC_LIST_HEAD(lookup->my_server_list);
|
for (serv = ISC_LIST_HEAD(lookup->my_server_list);
|
||||||
serv != NULL;
|
serv != NULL;
|
||||||
serv = ISC_LIST_NEXT(serv, link))
|
serv = ISC_LIST_NEXT(serv, link)) {
|
||||||
{
|
|
||||||
query = isc_mem_allocate(mctx, sizeof(dig_query_t));
|
query = isc_mem_allocate(mctx, sizeof(dig_query_t));
|
||||||
if (query == NULL) {
|
if (query == NULL)
|
||||||
fatal("memory allocation failure in %s:%d",
|
fatal("memory allocation failure in %s:%d",
|
||||||
__FILE__, __LINE__);
|
__FILE__, __LINE__);
|
||||||
}
|
debug("create query %p linked to lookup %p",
|
||||||
debug("create query %p linked to lookup %p", query, lookup);
|
query, lookup);
|
||||||
query->lookup = lookup;
|
query->lookup = lookup;
|
||||||
query->timer = NULL;
|
query->timer = NULL;
|
||||||
query->waiting_connect = false;
|
query->waiting_connect = false;
|
||||||
@@ -2510,24 +2488,20 @@ setup_lookup(dig_lookup_t *lookup) {
|
|||||||
query->msg_count = 0;
|
query->msg_count = 0;
|
||||||
query->byte_count = 0;
|
query->byte_count = 0;
|
||||||
query->ixfr_axfr = false;
|
query->ixfr_axfr = false;
|
||||||
|
ISC_LIST_INIT(query->recvlist);
|
||||||
|
ISC_LIST_INIT(query->lengthlist);
|
||||||
query->sock = NULL;
|
query->sock = NULL;
|
||||||
query->recvspace = isc_mempool_get(commctx);
|
query->recvspace = isc_mempool_get(commctx);
|
||||||
query->tmpsendspace = isc_mempool_get(commctx);
|
if (query->recvspace == NULL)
|
||||||
if (query->recvspace == NULL) {
|
|
||||||
fatal("memory allocation failure");
|
fatal("memory allocation failure");
|
||||||
}
|
|
||||||
|
|
||||||
isc_buffer_init(&query->recvbuf, query->recvspace, COMMSIZE);
|
isc_buffer_init(&query->recvbuf, query->recvspace, COMMSIZE);
|
||||||
isc_buffer_init(&query->lengthbuf, query->lengthspace, 2);
|
isc_buffer_init(&query->lengthbuf, query->lengthspace, 2);
|
||||||
isc_buffer_init(&query->tmpsendbuf, query->tmpsendspace,
|
isc_buffer_init(&query->slbuf, query->slspace, 2);
|
||||||
COMMSIZE);
|
|
||||||
query->sendbuf = lookup->renderbuf;
|
query->sendbuf = lookup->renderbuf;
|
||||||
|
|
||||||
ISC_LINK_INIT(query, clink);
|
ISC_LINK_INIT(query, clink);
|
||||||
ISC_LINK_INIT(query, link);
|
ISC_LINK_INIT(query, link);
|
||||||
|
|
||||||
query->magic = DIG_QUERY_MAGIC;
|
|
||||||
|
|
||||||
ISC_LIST_ENQUEUE(lookup->q, query, link);
|
ISC_LIST_ENQUEUE(lookup->q, query, link);
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -2536,10 +2510,9 @@ setup_lookup(dig_lookup_t *lookup) {
|
|||||||
extrabytes = 0;
|
extrabytes = 0;
|
||||||
dighost_printmessage(ISC_LIST_HEAD(lookup->q),
|
dighost_printmessage(ISC_LIST_HEAD(lookup->q),
|
||||||
lookup->sendmsg, true);
|
lookup->sendmsg, true);
|
||||||
if (lookup->stats) {
|
if (lookup->stats)
|
||||||
printf(";; QUERY SIZE: %u\n\n",
|
printf(";; QUERY SIZE: %u\n\n",
|
||||||
isc_buffer_usedlength(&lookup->renderbuf));
|
isc_buffer_usedlength(&lookup->renderbuf));
|
||||||
}
|
|
||||||
}
|
}
|
||||||
return (true);
|
return (true);
|
||||||
}
|
}
|
||||||
@@ -2550,6 +2523,8 @@ setup_lookup(dig_lookup_t *lookup) {
|
|||||||
*/
|
*/
|
||||||
static void
|
static void
|
||||||
send_done(isc_task_t *_task, isc_event_t *event) {
|
send_done(isc_task_t *_task, isc_event_t *event) {
|
||||||
|
isc_socketevent_t *sevent = (isc_socketevent_t *)event;
|
||||||
|
isc_buffer_t *b = NULL;
|
||||||
dig_query_t *query, *next;
|
dig_query_t *query, *next;
|
||||||
dig_lookup_t *l;
|
dig_lookup_t *l;
|
||||||
|
|
||||||
@@ -2564,27 +2539,28 @@ send_done(isc_task_t *_task, isc_event_t *event) {
|
|||||||
debug("sendcount=%d", sendcount);
|
debug("sendcount=%d", sendcount);
|
||||||
INSIST(sendcount >= 0);
|
INSIST(sendcount >= 0);
|
||||||
|
|
||||||
|
for (b = ISC_LIST_HEAD(sevent->bufferlist);
|
||||||
|
b != NULL;
|
||||||
|
b = ISC_LIST_HEAD(sevent->bufferlist)) {
|
||||||
|
ISC_LIST_DEQUEUE(sevent->bufferlist, b, link);
|
||||||
|
isc_mem_free(mctx, b);
|
||||||
|
}
|
||||||
|
|
||||||
query = event->ev_arg;
|
query = event->ev_arg;
|
||||||
REQUIRE(DIG_VALID_QUERY(query));
|
|
||||||
query->waiting_senddone = false;
|
query->waiting_senddone = false;
|
||||||
l = query->lookup;
|
l = query->lookup;
|
||||||
|
|
||||||
if (!query->pending_free && l->ns_search_only &&
|
if (l->ns_search_only && !l->trace_root && !l->tcp_mode) {
|
||||||
!l->trace_root && !l->tcp_mode)
|
|
||||||
{
|
|
||||||
debug("sending next, since searching");
|
debug("sending next, since searching");
|
||||||
next = ISC_LIST_NEXT(query, link);
|
next = ISC_LIST_NEXT(query, link);
|
||||||
if (next != NULL) {
|
if (next != NULL)
|
||||||
send_udp(next);
|
send_udp(next);
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
isc_event_free(&event);
|
isc_event_free(&event);
|
||||||
|
|
||||||
if (query->pending_free) {
|
if (query->pending_free)
|
||||||
query->magic = 0;
|
|
||||||
isc_mem_free(mctx, query);
|
isc_mem_free(mctx, query);
|
||||||
}
|
|
||||||
|
|
||||||
check_if_done();
|
check_if_done();
|
||||||
UNLOCK_LOOKUP;
|
UNLOCK_LOOKUP;
|
||||||
@@ -2602,7 +2578,6 @@ cancel_lookup(dig_lookup_t *lookup) {
|
|||||||
debug("cancel_lookup()");
|
debug("cancel_lookup()");
|
||||||
query = ISC_LIST_HEAD(lookup->q);
|
query = ISC_LIST_HEAD(lookup->q);
|
||||||
while (query != NULL) {
|
while (query != NULL) {
|
||||||
REQUIRE(DIG_VALID_QUERY(query));
|
|
||||||
next = ISC_LIST_NEXT(query, link);
|
next = ISC_LIST_NEXT(query, link);
|
||||||
if (query->sock != NULL) {
|
if (query->sock != NULL) {
|
||||||
isc_socket_cancel(query->sock, global_task,
|
isc_socket_cancel(query->sock, global_task,
|
||||||
@@ -2622,7 +2597,6 @@ bringup_timer(dig_query_t *query, unsigned int default_timeout) {
|
|||||||
dig_lookup_t *l;
|
dig_lookup_t *l;
|
||||||
unsigned int local_timeout;
|
unsigned int local_timeout;
|
||||||
isc_result_t result;
|
isc_result_t result;
|
||||||
REQUIRE(DIG_VALID_QUERY(query));
|
|
||||||
|
|
||||||
debug("bringup_timer()");
|
debug("bringup_timer()");
|
||||||
/*
|
/*
|
||||||
@@ -2687,7 +2661,6 @@ send_tcp_connect(dig_query_t *query) {
|
|||||||
isc_result_t result;
|
isc_result_t result;
|
||||||
dig_query_t *next;
|
dig_query_t *next;
|
||||||
dig_lookup_t *l;
|
dig_lookup_t *l;
|
||||||
REQUIRE(DIG_VALID_QUERY(query));
|
|
||||||
|
|
||||||
debug("send_tcp_connect(%p)", query);
|
debug("send_tcp_connect(%p)", query);
|
||||||
|
|
||||||
@@ -2804,6 +2777,17 @@ send_tcp_connect(dig_query_t *query) {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
static isc_buffer_t *
|
||||||
|
clone_buffer(isc_buffer_t *source) {
|
||||||
|
isc_buffer_t *buffer;
|
||||||
|
buffer = isc_mem_allocate(mctx, sizeof(*buffer));
|
||||||
|
if (buffer == NULL)
|
||||||
|
fatal("memory allocation failure in %s:%d",
|
||||||
|
__FILE__, __LINE__);
|
||||||
|
*buffer = *source;
|
||||||
|
return (buffer);
|
||||||
|
}
|
||||||
|
|
||||||
/*%
|
/*%
|
||||||
* Send a UDP packet to the remote nameserver, possible starting the
|
* Send a UDP packet to the remote nameserver, possible starting the
|
||||||
* recv action as well. Also make sure that the timer is running and
|
* recv action as well. Also make sure that the timer is running and
|
||||||
@@ -2813,10 +2797,8 @@ static void
|
|||||||
send_udp(dig_query_t *query) {
|
send_udp(dig_query_t *query) {
|
||||||
dig_lookup_t *l = NULL;
|
dig_lookup_t *l = NULL;
|
||||||
isc_result_t result;
|
isc_result_t result;
|
||||||
|
isc_buffer_t *sendbuf;
|
||||||
dig_query_t *next;
|
dig_query_t *next;
|
||||||
isc_region_t r;
|
|
||||||
isc_socketevent_t *sevent;
|
|
||||||
REQUIRE(DIG_VALID_QUERY(query));
|
|
||||||
|
|
||||||
debug("send_udp(%p)", query);
|
debug("send_udp(%p)", query);
|
||||||
|
|
||||||
@@ -2877,27 +2859,29 @@ send_udp(dig_query_t *query) {
|
|||||||
check_result(result, "isc_socket_bind");
|
check_result(result, "isc_socket_bind");
|
||||||
|
|
||||||
query->recv_made = true;
|
query->recv_made = true;
|
||||||
isc_buffer_availableregion(&query->recvbuf, &r);
|
ISC_LINK_INIT(&query->recvbuf, link);
|
||||||
|
ISC_LIST_ENQUEUE(query->recvlist, &query->recvbuf,
|
||||||
|
link);
|
||||||
debug("recving with lookup=%p, query=%p, sock=%p",
|
debug("recving with lookup=%p, query=%p, sock=%p",
|
||||||
query->lookup, query, query->sock);
|
query->lookup, query, query->sock);
|
||||||
result = isc_socket_recv(query->sock, &r, 1,
|
result = isc_socket_recvv(query->sock, &query->recvlist, 1,
|
||||||
global_task, recv_done, query);
|
global_task, recv_done, query);
|
||||||
check_result(result, "isc_socket_recv");
|
check_result(result, "isc_socket_recvv");
|
||||||
recvcount++;
|
recvcount++;
|
||||||
debug("recvcount=%d", recvcount);
|
debug("recvcount=%d", recvcount);
|
||||||
}
|
}
|
||||||
isc_buffer_usedregion(&query->sendbuf, &r);
|
ISC_LIST_INIT(query->sendlist);
|
||||||
|
sendbuf = clone_buffer(&query->sendbuf);
|
||||||
|
ISC_LIST_ENQUEUE(query->sendlist, sendbuf, link);
|
||||||
debug("sending a request");
|
debug("sending a request");
|
||||||
TIME_NOW(&query->time_sent);
|
TIME_NOW(&query->time_sent);
|
||||||
INSIST(query->sock != NULL);
|
INSIST(query->sock != NULL);
|
||||||
query->waiting_senddone = true;
|
query->waiting_senddone = true;
|
||||||
sevent = isc_socket_socketevent(mctx, query->sock,
|
result = isc_socket_sendtov2(query->sock, &query->sendlist,
|
||||||
ISC_SOCKEVENT_SENDDONE,
|
global_task, send_done, query,
|
||||||
send_done, query);
|
&query->sockaddr, NULL,
|
||||||
result = isc_socket_sendto2(query->sock, &r,
|
ISC_SOCKFLAG_NORETRY);
|
||||||
global_task, &query->sockaddr, NULL,
|
check_result(result, "isc_socket_sendtov");
|
||||||
sevent, ISC_SOCKFLAG_NORETRY);
|
|
||||||
check_result(result, "isc_socket_sendto2");
|
|
||||||
sendcount++;
|
sendcount++;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -2918,17 +2902,11 @@ connect_timeout(isc_task_t *task, isc_event_t *event) {
|
|||||||
|
|
||||||
LOCK_LOOKUP;
|
LOCK_LOOKUP;
|
||||||
query = event->ev_arg;
|
query = event->ev_arg;
|
||||||
REQUIRE(DIG_VALID_QUERY(query));
|
|
||||||
l = query->lookup;
|
l = query->lookup;
|
||||||
isc_event_free(&event);
|
isc_event_free(&event);
|
||||||
|
|
||||||
INSIST(!free_now);
|
INSIST(!free_now);
|
||||||
|
|
||||||
if (cancel_now) {
|
|
||||||
UNLOCK_LOOKUP;
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
|
|
||||||
if ((query != NULL) && (query->lookup->current_query != NULL) &&
|
if ((query != NULL) && (query->lookup->current_query != NULL) &&
|
||||||
ISC_LINK_LINKED(query->lookup->current_query, link) &&
|
ISC_LINK_LINKED(query->lookup->current_query, link) &&
|
||||||
(ISC_LIST_NEXT(query->lookup->current_query, link) != NULL)) {
|
(ISC_LIST_NEXT(query->lookup->current_query, link) != NULL)) {
|
||||||
@@ -2993,8 +2971,7 @@ connect_timeout(isc_task_t *task, isc_event_t *event) {
|
|||||||
static void
|
static void
|
||||||
tcp_length_done(isc_task_t *task, isc_event_t *event) {
|
tcp_length_done(isc_task_t *task, isc_event_t *event) {
|
||||||
isc_socketevent_t *sevent;
|
isc_socketevent_t *sevent;
|
||||||
isc_buffer_t b;
|
isc_buffer_t *b = NULL;
|
||||||
isc_region_t r;
|
|
||||||
isc_result_t result;
|
isc_result_t result;
|
||||||
dig_query_t *query = NULL;
|
dig_query_t *query = NULL;
|
||||||
dig_lookup_t *l, *n;
|
dig_lookup_t *l, *n;
|
||||||
@@ -3010,11 +2987,14 @@ tcp_length_done(isc_task_t *task, isc_event_t *event) {
|
|||||||
LOCK_LOOKUP;
|
LOCK_LOOKUP;
|
||||||
sevent = (isc_socketevent_t *)event;
|
sevent = (isc_socketevent_t *)event;
|
||||||
query = event->ev_arg;
|
query = event->ev_arg;
|
||||||
REQUIRE(DIG_VALID_QUERY(query));
|
|
||||||
|
|
||||||
recvcount--;
|
recvcount--;
|
||||||
INSIST(recvcount >= 0);
|
INSIST(recvcount >= 0);
|
||||||
|
|
||||||
|
b = ISC_LIST_HEAD(sevent->bufferlist);
|
||||||
|
INSIST(b == &query->lengthbuf);
|
||||||
|
ISC_LIST_DEQUEUE(sevent->bufferlist, b, link);
|
||||||
|
|
||||||
if (sevent->result == ISC_R_CANCELED) {
|
if (sevent->result == ISC_R_CANCELED) {
|
||||||
isc_event_free(&event);
|
isc_event_free(&event);
|
||||||
l = query->lookup;
|
l = query->lookup;
|
||||||
@@ -3047,10 +3027,7 @@ tcp_length_done(isc_task_t *task, isc_event_t *event) {
|
|||||||
UNLOCK_LOOKUP;
|
UNLOCK_LOOKUP;
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
isc_buffer_init(&b, sevent->region.base, sevent->n);
|
length = isc_buffer_getuint16(b);
|
||||||
isc_buffer_add(&b, sevent->n);
|
|
||||||
length = isc_buffer_getuint16(&b);
|
|
||||||
|
|
||||||
if (length == 0) {
|
if (length == 0) {
|
||||||
isc_event_free(&event);
|
isc_event_free(&event);
|
||||||
launch_next_query(query, false);
|
launch_next_query(query, false);
|
||||||
@@ -3064,11 +3041,13 @@ tcp_length_done(isc_task_t *task, isc_event_t *event) {
|
|||||||
*/
|
*/
|
||||||
isc_buffer_invalidate(&query->recvbuf);
|
isc_buffer_invalidate(&query->recvbuf);
|
||||||
isc_buffer_init(&query->recvbuf, query->recvspace, length);
|
isc_buffer_init(&query->recvbuf, query->recvspace, length);
|
||||||
isc_buffer_availableregion(&query->recvbuf, &r);
|
ENSURE(ISC_LIST_EMPTY(query->recvlist));
|
||||||
|
ISC_LINK_INIT(&query->recvbuf, link);
|
||||||
|
ISC_LIST_ENQUEUE(query->recvlist, &query->recvbuf, link);
|
||||||
debug("recving with lookup=%p, query=%p", query->lookup, query);
|
debug("recving with lookup=%p, query=%p", query->lookup, query);
|
||||||
result = isc_socket_recv(query->sock, &r, length, task,
|
result = isc_socket_recvv(query->sock, &query->recvlist, length, task,
|
||||||
recv_done, query);
|
recv_done, query);
|
||||||
check_result(result, "isc_socket_recv");
|
check_result(result, "isc_socket_recvv");
|
||||||
recvcount++;
|
recvcount++;
|
||||||
debug("resubmitted recv request with length %d, recvcount=%d",
|
debug("resubmitted recv request with length %d, recvcount=%d",
|
||||||
length, recvcount);
|
length, recvcount);
|
||||||
@@ -3084,8 +3063,7 @@ static void
|
|||||||
launch_next_query(dig_query_t *query, bool include_question) {
|
launch_next_query(dig_query_t *query, bool include_question) {
|
||||||
isc_result_t result;
|
isc_result_t result;
|
||||||
dig_lookup_t *l;
|
dig_lookup_t *l;
|
||||||
isc_region_t r;
|
isc_buffer_t *buffer;
|
||||||
REQUIRE(DIG_VALID_QUERY(query));
|
|
||||||
|
|
||||||
INSIST(!free_now);
|
INSIST(!free_now);
|
||||||
|
|
||||||
@@ -3104,28 +3082,35 @@ launch_next_query(dig_query_t *query, bool include_question) {
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
isc_buffer_clear(&query->slbuf);
|
||||||
isc_buffer_clear(&query->lengthbuf);
|
isc_buffer_clear(&query->lengthbuf);
|
||||||
isc_buffer_availableregion(&query->lengthbuf, &r);
|
isc_buffer_putuint16(&query->slbuf, (uint16_t) query->sendbuf.used);
|
||||||
result = isc_socket_recv(query->sock, &r, 0,
|
ISC_LIST_INIT(query->sendlist);
|
||||||
global_task, tcp_length_done, query);
|
ISC_LINK_INIT(&query->slbuf, link);
|
||||||
check_result(result, "isc_socket_recv");
|
if (!query->first_soa_rcvd) {
|
||||||
|
buffer = clone_buffer(&query->slbuf);
|
||||||
|
ISC_LIST_ENQUEUE(query->sendlist, buffer, link);
|
||||||
|
if (include_question) {
|
||||||
|
buffer = clone_buffer(&query->sendbuf);
|
||||||
|
ISC_LIST_ENQUEUE(query->sendlist, buffer, link);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
ISC_LINK_INIT(&query->lengthbuf, link);
|
||||||
|
ISC_LIST_ENQUEUE(query->lengthlist, &query->lengthbuf, link);
|
||||||
|
|
||||||
|
result = isc_socket_recvv(query->sock, &query->lengthlist, 0,
|
||||||
|
global_task, tcp_length_done, query);
|
||||||
|
check_result(result, "isc_socket_recvv");
|
||||||
recvcount++;
|
recvcount++;
|
||||||
debug("recvcount=%d", recvcount);
|
debug("recvcount=%d", recvcount);
|
||||||
if (!query->first_soa_rcvd) {
|
if (!query->first_soa_rcvd) {
|
||||||
debug("sending a request in launch_next_query");
|
debug("sending a request in launch_next_query");
|
||||||
TIME_NOW(&query->time_sent);
|
TIME_NOW(&query->time_sent);
|
||||||
query->waiting_senddone = true;
|
query->waiting_senddone = true;
|
||||||
isc_buffer_clear(&query->tmpsendbuf);
|
result = isc_socket_sendv(query->sock, &query->sendlist,
|
||||||
isc_buffer_putuint16(&query->tmpsendbuf,
|
global_task, send_done, query);
|
||||||
isc_buffer_usedlength(&query->sendbuf));
|
check_result(result, "isc_socket_sendv");
|
||||||
if (include_question) {
|
|
||||||
isc_buffer_usedregion(&query->sendbuf, &r);
|
|
||||||
isc_buffer_copyregion(&query->tmpsendbuf, &r);
|
|
||||||
}
|
|
||||||
isc_buffer_usedregion(&query->tmpsendbuf, &r);
|
|
||||||
result = isc_socket_send(query->sock, &r,
|
|
||||||
global_task, send_done, query);
|
|
||||||
check_result(result, "isc_socket_send");
|
|
||||||
sendcount++;
|
sendcount++;
|
||||||
debug("sendcount=%d", sendcount);
|
debug("sendcount=%d", sendcount);
|
||||||
}
|
}
|
||||||
@@ -3158,7 +3143,6 @@ connect_done(isc_task_t *task, isc_event_t *event) {
|
|||||||
LOCK_LOOKUP;
|
LOCK_LOOKUP;
|
||||||
sevent = (isc_socketevent_t *)event;
|
sevent = (isc_socketevent_t *)event;
|
||||||
query = sevent->ev_arg;
|
query = sevent->ev_arg;
|
||||||
REQUIRE(DIG_VALID_QUERY(query));
|
|
||||||
|
|
||||||
INSIST(query->waiting_connect);
|
INSIST(query->waiting_connect);
|
||||||
|
|
||||||
@@ -3476,9 +3460,8 @@ ednsvers(dns_rdataset_t *opt) {
|
|||||||
static void
|
static void
|
||||||
recv_done(isc_task_t *task, isc_event_t *event) {
|
recv_done(isc_task_t *task, isc_event_t *event) {
|
||||||
isc_socketevent_t *sevent = NULL;
|
isc_socketevent_t *sevent = NULL;
|
||||||
isc_region_t r;
|
|
||||||
dig_query_t *query = NULL;
|
dig_query_t *query = NULL;
|
||||||
isc_buffer_t b;
|
isc_buffer_t *b = NULL;
|
||||||
dns_message_t *msg = NULL;
|
dns_message_t *msg = NULL;
|
||||||
isc_result_t result;
|
isc_result_t result;
|
||||||
dig_lookup_t *n, *l;
|
dig_lookup_t *n, *l;
|
||||||
@@ -3508,8 +3491,9 @@ recv_done(isc_task_t *task, isc_event_t *event) {
|
|||||||
REQUIRE(event->ev_type == ISC_SOCKEVENT_RECVDONE);
|
REQUIRE(event->ev_type == ISC_SOCKEVENT_RECVDONE);
|
||||||
sevent = (isc_socketevent_t *)event;
|
sevent = (isc_socketevent_t *)event;
|
||||||
|
|
||||||
isc_buffer_init(&b, sevent->region.base, sevent->n);
|
b = ISC_LIST_HEAD(sevent->bufferlist);
|
||||||
isc_buffer_add(&b, sevent->n);
|
INSIST(b == &query->recvbuf);
|
||||||
|
ISC_LIST_DEQUEUE(sevent->bufferlist, &query->recvbuf, link);
|
||||||
|
|
||||||
if ((l->tcp_mode) && (query->timer != NULL))
|
if ((l->tcp_mode) && (query->timer != NULL))
|
||||||
isc_timer_touch(query->timer);
|
isc_timer_touch(query->timer);
|
||||||
@@ -3585,7 +3569,7 @@ recv_done(isc_task_t *task, isc_event_t *event) {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
result = dns_message_peekheader(&b, &id, &msgflags);
|
result = dns_message_peekheader(b, &id, &msgflags);
|
||||||
if (result != ISC_R_SUCCESS || l->sendmsg->id != id) {
|
if (result != ISC_R_SUCCESS || l->sendmsg->id != id) {
|
||||||
match = false;
|
match = false;
|
||||||
if (l->tcp_mode) {
|
if (l->tcp_mode) {
|
||||||
@@ -3654,7 +3638,7 @@ recv_done(isc_task_t *task, isc_event_t *event) {
|
|||||||
parseflags |= DNS_MESSAGEPARSE_BESTEFFORT;
|
parseflags |= DNS_MESSAGEPARSE_BESTEFFORT;
|
||||||
parseflags |= DNS_MESSAGEPARSE_IGNORETRUNCATION;
|
parseflags |= DNS_MESSAGEPARSE_IGNORETRUNCATION;
|
||||||
}
|
}
|
||||||
result = dns_message_parse(msg, &b, parseflags);
|
result = dns_message_parse(msg, b, parseflags);
|
||||||
if (result == DNS_R_RECOVERABLE) {
|
if (result == DNS_R_RECOVERABLE) {
|
||||||
printf(";; Warning: Message parser reports malformed "
|
printf(";; Warning: Message parser reports malformed "
|
||||||
"message packet.\n");
|
"message packet.\n");
|
||||||
@@ -3662,7 +3646,7 @@ recv_done(isc_task_t *task, isc_event_t *event) {
|
|||||||
}
|
}
|
||||||
if (result != ISC_R_SUCCESS) {
|
if (result != ISC_R_SUCCESS) {
|
||||||
printf(";; Got bad packet: %s\n", isc_result_totext(result));
|
printf(";; Got bad packet: %s\n", isc_result_totext(result));
|
||||||
hex_dump(&b);
|
hex_dump(b);
|
||||||
query->waiting_connect = false;
|
query->waiting_connect = false;
|
||||||
dns_message_destroy(&msg);
|
dns_message_destroy(&msg);
|
||||||
isc_event_free(&event);
|
isc_event_free(&event);
|
||||||
@@ -3816,7 +3800,7 @@ recv_done(isc_task_t *task, isc_event_t *event) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
if (tsigkey != NULL) {
|
if (tsigkey != NULL) {
|
||||||
result = dns_tsig_verify(&b, msg, NULL, NULL);
|
result = dns_tsig_verify(&query->recvbuf, msg, NULL, NULL);
|
||||||
if (result != ISC_R_SUCCESS) {
|
if (result != ISC_R_SUCCESS) {
|
||||||
printf(";; Couldn't verify signature: %s\n",
|
printf(";; Couldn't verify signature: %s\n",
|
||||||
isc_result_totext(result));
|
isc_result_totext(result));
|
||||||
@@ -3832,7 +3816,7 @@ recv_done(isc_task_t *task, isc_event_t *event) {
|
|||||||
check_result(result,"dns_message_getquerytsig");
|
check_result(result,"dns_message_getquerytsig");
|
||||||
}
|
}
|
||||||
|
|
||||||
extrabytes = isc_buffer_remaininglength(&b);
|
extrabytes = isc_buffer_remaininglength(b);
|
||||||
|
|
||||||
debug("after parse");
|
debug("after parse");
|
||||||
if (l->doing_xfr && l->xfr_q == NULL) {
|
if (l->doing_xfr && l->xfr_q == NULL) {
|
||||||
@@ -3879,8 +3863,8 @@ recv_done(isc_task_t *task, isc_event_t *event) {
|
|||||||
(l->origin != NULL || l->need_search)) {
|
(l->origin != NULL || l->need_search)) {
|
||||||
if (!next_origin(query->lookup) || showsearch) {
|
if (!next_origin(query->lookup) || showsearch) {
|
||||||
dighost_printmessage(query, msg, true);
|
dighost_printmessage(query, msg, true);
|
||||||
dighost_received(isc_buffer_usedlength(&b),
|
dighost_received(b->used, &sevent->address,
|
||||||
&sevent->address, query);
|
query);
|
||||||
}
|
}
|
||||||
} else if (!l->trace && !l->ns_search_only) {
|
} else if (!l->trace && !l->ns_search_only) {
|
||||||
dighost_printmessage(query, msg, true);
|
dighost_printmessage(query, msg, true);
|
||||||
@@ -3947,8 +3931,7 @@ recv_done(isc_task_t *task, isc_event_t *event) {
|
|||||||
} else {
|
} else {
|
||||||
|
|
||||||
if (msg->rcode == dns_rcode_noerror || l->origin == NULL) {
|
if (msg->rcode == dns_rcode_noerror || l->origin == NULL) {
|
||||||
dighost_received(isc_buffer_usedlength(&b),
|
dighost_received(b->used, &sevent->address, query);
|
||||||
&sevent->address, query);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
if (!query->lookup->ns_search_only)
|
if (!query->lookup->ns_search_only)
|
||||||
@@ -3972,10 +3955,10 @@ recv_done(isc_task_t *task, isc_event_t *event) {
|
|||||||
udp_mismatch:
|
udp_mismatch:
|
||||||
isc_buffer_invalidate(&query->recvbuf);
|
isc_buffer_invalidate(&query->recvbuf);
|
||||||
isc_buffer_init(&query->recvbuf, query->recvspace, COMMSIZE);
|
isc_buffer_init(&query->recvbuf, query->recvspace, COMMSIZE);
|
||||||
isc_buffer_availableregion(&query->recvbuf, &r);
|
ISC_LIST_ENQUEUE(query->recvlist, &query->recvbuf, link);
|
||||||
result = isc_socket_recv(query->sock, &r, 1,
|
result = isc_socket_recvv(query->sock, &query->recvlist, 1,
|
||||||
global_task, recv_done, query);
|
global_task, recv_done, query);
|
||||||
check_result(result, "isc_socket_recv");
|
check_result(result, "isc_socket_recvv");
|
||||||
recvcount++;
|
recvcount++;
|
||||||
isc_event_free(&event);
|
isc_event_free(&event);
|
||||||
UNLOCK_LOOKUP;
|
UNLOCK_LOOKUP;
|
||||||
@@ -4050,7 +4033,6 @@ do_lookup(dig_lookup_t *lookup) {
|
|||||||
lookup->pending = true;
|
lookup->pending = true;
|
||||||
query = ISC_LIST_HEAD(lookup->q);
|
query = ISC_LIST_HEAD(lookup->q);
|
||||||
if (query != NULL) {
|
if (query != NULL) {
|
||||||
REQUIRE(DIG_VALID_QUERY(query));
|
|
||||||
if (lookup->tcp_mode)
|
if (lookup->tcp_mode)
|
||||||
send_tcp_connect(query);
|
send_tcp_connect(query);
|
||||||
else
|
else
|
||||||
@@ -4198,7 +4180,7 @@ destroy_libs(void) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
UNLOCK_LOOKUP;
|
UNLOCK_LOOKUP;
|
||||||
isc_mutex_destroy(&lookup_lock);
|
DESTROYLOCK(&lookup_lock);
|
||||||
debug("Removing log context");
|
debug("Removing log context");
|
||||||
isc_log_destroy(&lctx);
|
isc_log_destroy(&lctx);
|
||||||
|
|
||||||
|
|||||||
+6
-1
@@ -112,6 +112,11 @@ Print debugging traces\&. Equivalent to the
|
|||||||
verbose option\&.
|
verbose option\&.
|
||||||
.RE
|
.RE
|
||||||
.PP
|
.PP
|
||||||
|
\-i
|
||||||
|
.RS 4
|
||||||
|
Obsolete\&. Use the IP6\&.INT domain for reverse lookups of IPv6 addresses as defined in RFC1886 and deprecated in RFC4159\&. The default is to use IP6\&.ARPA as specified in RFC3596\&.
|
||||||
|
.RE
|
||||||
|
.PP
|
||||||
\-l
|
\-l
|
||||||
.RS 4
|
.RS 4
|
||||||
List zone: The
|
List zone: The
|
||||||
@@ -252,7 +257,7 @@ If
|
|||||||
\fBhost\fR
|
\fBhost\fR
|
||||||
has been built with IDN (internationalized domain name) support, it can accept and display non\-ASCII domain names\&.
|
has been built with IDN (internationalized domain name) support, it can accept and display non\-ASCII domain names\&.
|
||||||
\fBhost\fR
|
\fBhost\fR
|
||||||
appropriately converts character encoding of domain name before sending a request to DNS server or displaying a reply from the server\&. If you\*(Aqd like to turn off the IDN support for some reason, define the
|
appropriately converts character encoding of domain name before sending a request to DNS server or displaying a reply from the server\&. If you\*(Aqd like to turn off the IDN support for some reason, defines the
|
||||||
\fBIDN_DISABLE\fR
|
\fBIDN_DISABLE\fR
|
||||||
environment variable\&. The IDN support is disabled if the variable is set when
|
environment variable\&. The IDN support is disabled if the variable is set when
|
||||||
\fBhost\fR
|
\fBhost\fR
|
||||||
|
|||||||
+4
-3
@@ -143,6 +143,7 @@ show_usage(void) {
|
|||||||
" -c specifies query class for non-IN data\n"
|
" -c specifies query class for non-IN data\n"
|
||||||
" -C compares SOA records on authoritative nameservers\n"
|
" -C compares SOA records on authoritative nameservers\n"
|
||||||
" -d is equivalent to -v\n"
|
" -d is equivalent to -v\n"
|
||||||
|
" -i IP6.INT reverse lookups\n"
|
||||||
" -l lists all hosts in a domain, using AXFR\n"
|
" -l lists all hosts in a domain, using AXFR\n"
|
||||||
" -m set memory debugging flag (trace|record|usage)\n"
|
" -m set memory debugging flag (trace|record|usage)\n"
|
||||||
" -N changes the number of dots allowed before root lookup is done\n"
|
" -N changes the number of dots allowed before root lookup is done\n"
|
||||||
@@ -761,7 +762,7 @@ parse_args(bool is_batchfile, int argc, char **argv) {
|
|||||||
default_lookups = false;
|
default_lookups = false;
|
||||||
break;
|
break;
|
||||||
case 'i':
|
case 'i':
|
||||||
/* deprecated */
|
lookup->ip6_int = true;
|
||||||
break;
|
break;
|
||||||
case 'n':
|
case 'n':
|
||||||
/* deprecated */
|
/* deprecated */
|
||||||
@@ -840,8 +841,8 @@ parse_args(bool is_batchfile, int argc, char **argv) {
|
|||||||
check_ra = true;
|
check_ra = true;
|
||||||
|
|
||||||
lookup->pending = false;
|
lookup->pending = false;
|
||||||
if (get_reverse(store, sizeof(store), hostname, true)
|
if (get_reverse(store, sizeof(store), hostname,
|
||||||
== ISC_R_SUCCESS) {
|
lookup->ip6_int, true) == ISC_R_SUCCESS) {
|
||||||
strlcpy(lookup->textname, store, sizeof(lookup->textname));
|
strlcpy(lookup->textname, store, sizeof(lookup->textname));
|
||||||
lookup->rdtype = dns_rdatatype_ptr;
|
lookup->rdtype = dns_rdatatype_ptr;
|
||||||
lookup->rdtypeset = true;
|
lookup->rdtypeset = true;
|
||||||
|
|||||||
+13
-1
@@ -179,6 +179,18 @@
|
|||||||
</listitem>
|
</listitem>
|
||||||
</varlistentry>
|
</varlistentry>
|
||||||
|
|
||||||
|
<varlistentry>
|
||||||
|
<term>-i</term>
|
||||||
|
<listitem>
|
||||||
|
<para>
|
||||||
|
Obsolete.
|
||||||
|
Use the IP6.INT domain for reverse lookups of IPv6
|
||||||
|
addresses as defined in RFC1886 and deprecated in RFC4159.
|
||||||
|
The default is to use IP6.ARPA as specified in RFC3596.
|
||||||
|
</para>
|
||||||
|
</listitem>
|
||||||
|
</varlistentry>
|
||||||
|
|
||||||
<varlistentry>
|
<varlistentry>
|
||||||
<term>-l</term>
|
<term>-l</term>
|
||||||
<listitem>
|
<listitem>
|
||||||
@@ -377,7 +389,7 @@
|
|||||||
<command>host</command> appropriately converts character encoding of
|
<command>host</command> appropriately converts character encoding of
|
||||||
domain name before sending a request to DNS server or displaying a
|
domain name before sending a request to DNS server or displaying a
|
||||||
reply from the server.
|
reply from the server.
|
||||||
If you'd like to turn off the IDN support for some reason, define
|
If you'd like to turn off the IDN support for some reason, defines
|
||||||
the <envar>IDN_DISABLE</envar> environment variable.
|
the <envar>IDN_DISABLE</envar> environment variable.
|
||||||
The IDN support is disabled if the variable is set when
|
The IDN support is disabled if the variable is set when
|
||||||
<command>host</command> runs.
|
<command>host</command> runs.
|
||||||
|
|||||||
+10
-1
@@ -138,6 +138,15 @@
|
|||||||
Equivalent to the <code class="option">-v</code> verbose option.
|
Equivalent to the <code class="option">-v</code> verbose option.
|
||||||
</p>
|
</p>
|
||||||
</dd>
|
</dd>
|
||||||
|
<dt><span class="term">-i</span></dt>
|
||||||
|
<dd>
|
||||||
|
<p>
|
||||||
|
Obsolete.
|
||||||
|
Use the IP6.INT domain for reverse lookups of IPv6
|
||||||
|
addresses as defined in RFC1886 and deprecated in RFC4159.
|
||||||
|
The default is to use IP6.ARPA as specified in RFC3596.
|
||||||
|
</p>
|
||||||
|
</dd>
|
||||||
<dt><span class="term">-l</span></dt>
|
<dt><span class="term">-l</span></dt>
|
||||||
<dd>
|
<dd>
|
||||||
<p>
|
<p>
|
||||||
@@ -302,7 +311,7 @@
|
|||||||
<span class="command"><strong>host</strong></span> appropriately converts character encoding of
|
<span class="command"><strong>host</strong></span> appropriately converts character encoding of
|
||||||
domain name before sending a request to DNS server or displaying a
|
domain name before sending a request to DNS server or displaying a
|
||||||
reply from the server.
|
reply from the server.
|
||||||
If you'd like to turn off the IDN support for some reason, define
|
If you'd like to turn off the IDN support for some reason, defines
|
||||||
the <code class="envar">IDN_DISABLE</code> environment variable.
|
the <code class="envar">IDN_DISABLE</code> environment variable.
|
||||||
The IDN support is disabled if the variable is set when
|
The IDN support is disabled if the variable is set when
|
||||||
<span class="command"><strong>host</strong></span> runs.
|
<span class="command"><strong>host</strong></span> runs.
|
||||||
|
|||||||
+11
-12
@@ -26,7 +26,6 @@
|
|||||||
#include <isc/formatcheck.h>
|
#include <isc/formatcheck.h>
|
||||||
#include <isc/lang.h>
|
#include <isc/lang.h>
|
||||||
#include <isc/list.h>
|
#include <isc/list.h>
|
||||||
#include <isc/magic.h>
|
|
||||||
#include <isc/mem.h>
|
#include <isc/mem.h>
|
||||||
#include <isc/print.h>
|
#include <isc/print.h>
|
||||||
#include <isc/sockaddr.h>
|
#include <isc/sockaddr.h>
|
||||||
@@ -82,11 +81,6 @@ typedef struct dig_server dig_server_t;
|
|||||||
typedef ISC_LIST(dig_server_t) dig_serverlist_t;
|
typedef ISC_LIST(dig_server_t) dig_serverlist_t;
|
||||||
typedef struct dig_searchlist dig_searchlist_t;
|
typedef struct dig_searchlist dig_searchlist_t;
|
||||||
|
|
||||||
#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 */
|
/*% The dig_lookup structure */
|
||||||
struct dig_lookup {
|
struct dig_lookup {
|
||||||
bool
|
bool
|
||||||
@@ -109,6 +103,7 @@ struct dig_lookup {
|
|||||||
trace_root, /*% initial query for either +trace or +nssearch */
|
trace_root, /*% initial query for either +trace or +nssearch */
|
||||||
tcp_mode,
|
tcp_mode,
|
||||||
tcp_mode_set,
|
tcp_mode_set,
|
||||||
|
ip6_int,
|
||||||
comments,
|
comments,
|
||||||
stats,
|
stats,
|
||||||
section_question,
|
section_question,
|
||||||
@@ -190,7 +185,6 @@ struct dig_lookup {
|
|||||||
|
|
||||||
/*% The dig_query structure */
|
/*% The dig_query structure */
|
||||||
struct dig_query {
|
struct dig_query {
|
||||||
unsigned int magic;
|
|
||||||
dig_lookup_t *lookup;
|
dig_lookup_t *lookup;
|
||||||
bool waiting_connect,
|
bool waiting_connect,
|
||||||
pending_free,
|
pending_free,
|
||||||
@@ -209,12 +203,15 @@ struct dig_query {
|
|||||||
bool ixfr_axfr;
|
bool ixfr_axfr;
|
||||||
char *servname;
|
char *servname;
|
||||||
char *userarg;
|
char *userarg;
|
||||||
|
isc_bufferlist_t sendlist,
|
||||||
|
recvlist,
|
||||||
|
lengthlist;
|
||||||
isc_buffer_t recvbuf,
|
isc_buffer_t recvbuf,
|
||||||
lengthbuf,
|
lengthbuf,
|
||||||
tmpsendbuf,
|
slbuf;
|
||||||
sendbuf;
|
char *recvspace,
|
||||||
char *recvspace, *tmpsendspace,
|
lengthspace[4],
|
||||||
lengthspace[4];
|
slspace[4];
|
||||||
isc_socket_t *sock;
|
isc_socket_t *sock;
|
||||||
ISC_LINK(dig_query_t) link;
|
ISC_LINK(dig_query_t) link;
|
||||||
ISC_LINK(dig_query_t) clink;
|
ISC_LINK(dig_query_t) clink;
|
||||||
@@ -222,6 +219,7 @@ struct dig_query {
|
|||||||
isc_time_t time_sent;
|
isc_time_t time_sent;
|
||||||
isc_time_t time_recv;
|
isc_time_t time_recv;
|
||||||
uint64_t byte_count;
|
uint64_t byte_count;
|
||||||
|
isc_buffer_t sendbuf;
|
||||||
isc_timer_t *timer;
|
isc_timer_t *timer;
|
||||||
};
|
};
|
||||||
|
|
||||||
@@ -286,7 +284,8 @@ int
|
|||||||
getaddresses(dig_lookup_t *lookup, const char *host, isc_result_t *resultp);
|
getaddresses(dig_lookup_t *lookup, const char *host, isc_result_t *resultp);
|
||||||
|
|
||||||
isc_result_t
|
isc_result_t
|
||||||
get_reverse(char *reverse, size_t len, char *value, bool strict);
|
get_reverse(char *reverse, size_t len, char *value, bool ip6_int,
|
||||||
|
bool strict);
|
||||||
|
|
||||||
ISC_PLATFORM_NORETURN_PRE void
|
ISC_PLATFORM_NORETURN_PRE void
|
||||||
fatal(const char *format, ...)
|
fatal(const char *format, ...)
|
||||||
|
|||||||
@@ -277,17 +277,6 @@ Try the next nameserver if a nameserver responds with SERVFAIL or a referral (no
|
|||||||
.PP
|
.PP
|
||||||
\fBnslookup\fR
|
\fBnslookup\fR
|
||||||
returns with an exit status of 1 if any query failed, and 0 otherwise\&.
|
returns with an exit status of 1 if any query failed, and 0 otherwise\&.
|
||||||
.SH "IDN SUPPORT"
|
|
||||||
.PP
|
|
||||||
If
|
|
||||||
\fBnslookup\fR
|
|
||||||
has been built with IDN (internationalized domain name) support, it can accept and display non\-ASCII domain names\&.
|
|
||||||
\fBnslookup\fR
|
|
||||||
appropriately converts character encoding of domain name before sending a request to DNS server or displaying a reply from the server\&. If you\*(Aqd like to turn off the IDN support for some reason, define the
|
|
||||||
\fBIDN_DISABLE\fR
|
|
||||||
environment variable\&. The IDN support is disabled if the variable is set when
|
|
||||||
\fBnslookup\fR
|
|
||||||
runs or when the standard output is not a tty\&.
|
|
||||||
.SH "FILES"
|
.SH "FILES"
|
||||||
.PP
|
.PP
|
||||||
/etc/resolv\&.conf
|
/etc/resolv\&.conf
|
||||||
|
|||||||
+7
-1
@@ -772,7 +772,7 @@ addlookup(char *opt) {
|
|||||||
rdclass = dns_rdataclass_in;
|
rdclass = dns_rdataclass_in;
|
||||||
}
|
}
|
||||||
lookup = make_empty_lookup();
|
lookup = make_empty_lookup();
|
||||||
if (get_reverse(store, sizeof(store), opt, true)
|
if (get_reverse(store, sizeof(store), opt, lookup->ip6_int, true)
|
||||||
== ISC_R_SUCCESS) {
|
== ISC_R_SUCCESS) {
|
||||||
strlcpy(lookup->textname, store, sizeof(lookup->textname));
|
strlcpy(lookup->textname, store, sizeof(lookup->textname));
|
||||||
lookup->rdtype = dns_rdatatype_ptr;
|
lookup->rdtype = dns_rdatatype_ptr;
|
||||||
@@ -923,6 +923,12 @@ flush_lookup_list(void) {
|
|||||||
ISC_SOCKCANCEL_ALL);
|
ISC_SOCKCANCEL_ALL);
|
||||||
isc_socket_detach(&q->sock);
|
isc_socket_detach(&q->sock);
|
||||||
}
|
}
|
||||||
|
if (ISC_LINK_LINKED(&q->recvbuf, link))
|
||||||
|
ISC_LIST_DEQUEUE(q->recvlist, &q->recvbuf,
|
||||||
|
link);
|
||||||
|
if (ISC_LINK_LINKED(&q->lengthbuf, link))
|
||||||
|
ISC_LIST_DEQUEUE(q->lengthlist, &q->lengthbuf,
|
||||||
|
link);
|
||||||
isc_buffer_invalidate(&q->recvbuf);
|
isc_buffer_invalidate(&q->recvbuf);
|
||||||
isc_buffer_invalidate(&q->lengthbuf);
|
isc_buffer_invalidate(&q->lengthbuf);
|
||||||
qp = q;
|
qp = q;
|
||||||
|
|||||||
@@ -478,22 +478,6 @@ nslookup -query=hinfo -timeout=10
|
|||||||
</para>
|
</para>
|
||||||
</refsection>
|
</refsection>
|
||||||
|
|
||||||
<refsection><info><title>IDN SUPPORT</title></info>
|
|
||||||
|
|
||||||
<para>
|
|
||||||
If <command>nslookup</command> has been built with IDN (internationalized
|
|
||||||
domain name) support, it can accept and display non-ASCII domain names.
|
|
||||||
<command>nslookup</command> appropriately converts character encoding of
|
|
||||||
domain name before sending a request to DNS server or displaying a
|
|
||||||
reply from the server.
|
|
||||||
If you'd like to turn off the IDN support for some reason, define
|
|
||||||
the <envar>IDN_DISABLE</envar> environment variable.
|
|
||||||
The IDN support is disabled if the variable is set when
|
|
||||||
<command>nslookup</command> runs or when the standard output is not
|
|
||||||
a tty.
|
|
||||||
</para>
|
|
||||||
</refsection>
|
|
||||||
|
|
||||||
<refsection><info><title>FILES</title></info>
|
<refsection><info><title>FILES</title></info>
|
||||||
|
|
||||||
<para><filename>/etc/resolv.conf</filename>
|
<para><filename>/etc/resolv.conf</filename>
|
||||||
|
|||||||
+2
-19
@@ -362,31 +362,14 @@ nslookup -query=hinfo -timeout=10
|
|||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div class="refsection">
|
<div class="refsection">
|
||||||
<a name="id-1.11"></a><h2>IDN SUPPORT</h2>
|
<a name="id-1.11"></a><h2>FILES</h2>
|
||||||
|
|
||||||
<p>
|
|
||||||
If <span class="command"><strong>nslookup</strong></span> has been built with IDN (internationalized
|
|
||||||
domain name) support, it can accept and display non-ASCII domain names.
|
|
||||||
<span class="command"><strong>nslookup</strong></span> appropriately converts character encoding of
|
|
||||||
domain name before sending a request to DNS server or displaying a
|
|
||||||
reply from the server.
|
|
||||||
If you'd like to turn off the IDN support for some reason, define
|
|
||||||
the <code class="envar">IDN_DISABLE</code> environment variable.
|
|
||||||
The IDN support is disabled if the variable is set when
|
|
||||||
<span class="command"><strong>nslookup</strong></span> runs or when the standard output is not
|
|
||||||
a tty.
|
|
||||||
</p>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<div class="refsection">
|
|
||||||
<a name="id-1.12"></a><h2>FILES</h2>
|
|
||||||
|
|
||||||
<p><code class="filename">/etc/resolv.conf</code>
|
<p><code class="filename">/etc/resolv.conf</code>
|
||||||
</p>
|
</p>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div class="refsection">
|
<div class="refsection">
|
||||||
<a name="id-1.13"></a><h2>SEE ALSO</h2>
|
<a name="id-1.12"></a><h2>SEE ALSO</h2>
|
||||||
|
|
||||||
<p><span class="citerefentry">
|
<p><span class="citerefentry">
|
||||||
<span class="refentrytitle">dig</span>(1)
|
<span class="refentrytitle">dig</span>(1)
|
||||||
|
|||||||
@@ -115,12 +115,12 @@ installdirs:
|
|||||||
$(SHELL) ${top_srcdir}/mkinstalldirs ${DESTDIR}${mandir}/man8
|
$(SHELL) ${top_srcdir}/mkinstalldirs ${DESTDIR}${mandir}/man8
|
||||||
|
|
||||||
install:: ${TARGETS} installdirs
|
install:: ${TARGETS} installdirs
|
||||||
for t in ${TARGETS}; do ${LIBTOOL_MODE_INSTALL} ${INSTALL_PROGRAM} $$t ${DESTDIR}${sbindir} || exit 1; done
|
for t in ${TARGETS}; do ${LIBTOOL_MODE_INSTALL} ${INSTALL_PROGRAM} $$t ${DESTDIR}${sbindir}; done
|
||||||
for m in ${MANPAGES}; do ${INSTALL_DATA} ${srcdir}/$$m ${DESTDIR}${mandir}/man8 || exit 1; done
|
for m in ${MANPAGES}; do ${INSTALL_DATA} ${srcdir}/$$m ${DESTDIR}${mandir}/man8; done
|
||||||
|
|
||||||
uninstall::
|
uninstall::
|
||||||
for m in ${MANPAGES}; do rm -f ${DESTDIR}${mandir}/man8/$$m || exit 1; done
|
for m in ${MANPAGES}; do rm -f ${DESTDIR}${mandir}/man8/$$m ; done
|
||||||
for t in ${TARGETS}; do ${LIBTOOL_MODE_UNINSTALL} rm -f ${DESTDIR}${sbindir}/$$t || exit 1; done
|
for t in ${TARGETS}; do ${LIBTOOL_MODE_UNINSTALL} rm -f ${DESTDIR}${sbindir}/$$t ; done
|
||||||
|
|
||||||
clean distclean::
|
clean distclean::
|
||||||
rm -f ${TARGETS}
|
rm -f ${TARGETS}
|
||||||
|
|||||||
@@ -163,8 +163,8 @@ verbose_time(int level, const char *msg, isc_stdtime_t time) {
|
|||||||
if (verbose < 3) {
|
if (verbose < 3) {
|
||||||
vbprintf(level, "%s %s\n", msg, timestr);
|
vbprintf(level, "%s %s\n", msg, timestr);
|
||||||
} else {
|
} else {
|
||||||
vbprintf(level, "%s %s (%" PRIu32 ")\n",
|
vbprintf(level, "%s %s (%lld)\n",
|
||||||
msg, timestr, time);
|
msg, timestr, (long long)time);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -55,7 +55,7 @@ of the key is specified on the command line\&. This must match the name of the z
|
|||||||
.RS 4
|
.RS 4
|
||||||
Selects the cryptographic algorithm\&. The value of
|
Selects the cryptographic algorithm\&. The value of
|
||||||
\fBalgorithm\fR
|
\fBalgorithm\fR
|
||||||
must be one of RSAMD5, RSASHA1, NSEC3RSASHA1, RSASHA256, RSASHA512, ECDSAP256SHA256, ECDSAP384SHA384, ED25519 or ED448\&.
|
must be one of RSAMD5, RSASHA1, DSA, NSEC3RSASHA1, NSEC3DSA, RSASHA256, RSASHA512, ECDSAP256SHA256, ECDSAP384SHA384, ED25519 or ED448\&.
|
||||||
.sp
|
.sp
|
||||||
If no algorithm is specified, then RSASHA1 will be used by default, unless the
|
If no algorithm is specified, then RSASHA1 will be used by default, unless the
|
||||||
\fB\-3\fR
|
\fB\-3\fR
|
||||||
@@ -63,9 +63,9 @@ option is specified, in which case NSEC3RSASHA1 will be used instead\&. (If
|
|||||||
\fB\-3\fR
|
\fB\-3\fR
|
||||||
is used and an algorithm is specified, that algorithm will be checked for compatibility with NSEC3\&.)
|
is used and an algorithm is specified, that algorithm will be checked for compatibility with NSEC3\&.)
|
||||||
.sp
|
.sp
|
||||||
These values are case insensitive\&. In some cases, abbreviations are supported, such as ECDSA256 for ECDSAP256SHA256 and ECDSA384 for ECDSAP384SHA384\&. If RSASHA1 is specified along with the
|
These values are case insensitive\&. In some cases, abbreviations are supported, such as ECDSA256 for ECDSAP256SHA256 and ECDSA384 for ECDSAP384SHA384\&. If RSASHA1 or DSA is specified along with the
|
||||||
\fB\-3\fR
|
\fB\-3\fR
|
||||||
option, then NSEC3RSASHA1 will be used instead\&.
|
option, then NSEC3RSASHA1 or NSEC3DSA will be used instead\&.
|
||||||
.sp
|
.sp
|
||||||
As of BIND 9\&.12\&.0, this option is mandatory except when using the
|
As of BIND 9\&.12\&.0, this option is mandatory except when using the
|
||||||
\fB\-S\fR
|
\fB\-S\fR
|
||||||
|
|||||||
@@ -64,8 +64,8 @@ usage(void) {
|
|||||||
fprintf(stderr, " name: owner of the key\n");
|
fprintf(stderr, " name: owner of the key\n");
|
||||||
fprintf(stderr, "Other options:\n");
|
fprintf(stderr, "Other options:\n");
|
||||||
fprintf(stderr, " -a algorithm: \n"
|
fprintf(stderr, " -a algorithm: \n"
|
||||||
" RSA | RSAMD5 | DH | RSASHA1 |\n"
|
" RSA | RSAMD5 | DH | DSA | RSASHA1 |\n"
|
||||||
" NSEC3RSASHA1 |\n"
|
" NSEC3DSA | NSEC3RSASHA1 |\n"
|
||||||
" RSASHA256 | RSASHA512 |\n"
|
" RSASHA256 | RSASHA512 |\n"
|
||||||
" ECDSAP256SHA256 | ECDSAP384SHA384\n");
|
" ECDSAP256SHA256 | ECDSAP384SHA384\n");
|
||||||
fprintf(stderr, " -3: use NSEC3-capable algorithm\n");
|
fprintf(stderr, " -3: use NSEC3-capable algorithm\n");
|
||||||
@@ -402,9 +402,13 @@ main(int argc, char **argv) {
|
|||||||
|
|
||||||
if (use_nsec3) {
|
if (use_nsec3) {
|
||||||
switch (alg) {
|
switch (alg) {
|
||||||
|
case DST_ALG_DSA:
|
||||||
|
alg = DST_ALG_NSEC3DSA;
|
||||||
|
break;
|
||||||
case DST_ALG_RSASHA1:
|
case DST_ALG_RSASHA1:
|
||||||
alg = DST_ALG_NSEC3RSASHA1;
|
alg = DST_ALG_NSEC3RSASHA1;
|
||||||
break;
|
break;
|
||||||
|
case DST_ALG_NSEC3DSA:
|
||||||
case DST_ALG_NSEC3RSASHA1:
|
case DST_ALG_NSEC3RSASHA1:
|
||||||
case DST_ALG_RSASHA256:
|
case DST_ALG_RSASHA256:
|
||||||
case DST_ALG_RSASHA512:
|
case DST_ALG_RSASHA512:
|
||||||
|
|||||||
@@ -106,7 +106,7 @@
|
|||||||
<para>
|
<para>
|
||||||
Selects the cryptographic algorithm. The value of
|
Selects the cryptographic algorithm. The value of
|
||||||
<option>algorithm</option> must be one of RSAMD5, RSASHA1,
|
<option>algorithm</option> must be one of RSAMD5, RSASHA1,
|
||||||
NSEC3RSASHA1, RSASHA256, RSASHA512,
|
DSA, NSEC3RSASHA1, NSEC3DSA, RSASHA256, RSASHA512,
|
||||||
ECDSAP256SHA256, ECDSAP384SHA384, ED25519 or ED448.
|
ECDSAP256SHA256, ECDSAP384SHA384, ED25519 or ED448.
|
||||||
</para>
|
</para>
|
||||||
<para>
|
<para>
|
||||||
@@ -119,9 +119,9 @@
|
|||||||
<para>
|
<para>
|
||||||
These values are case insensitive. In some cases, abbreviations
|
These values are case insensitive. In some cases, abbreviations
|
||||||
are supported, such as ECDSA256 for ECDSAP256SHA256 and
|
are supported, such as ECDSA256 for ECDSAP256SHA256 and
|
||||||
ECDSA384 for ECDSAP384SHA384. If RSASHA1 is specified
|
ECDSA384 for ECDSAP384SHA384. If RSASHA1 or DSA is specified
|
||||||
along with the <option>-3</option> option, then NSEC3RSASHA1
|
along with the <option>-3</option> option, then NSEC3RSASHA1
|
||||||
will be used instead.
|
or NSEC3DSA will be used instead.
|
||||||
</para>
|
</para>
|
||||||
<para>
|
<para>
|
||||||
As of BIND 9.12.0, this option is mandatory except when using
|
As of BIND 9.12.0, this option is mandatory except when using
|
||||||
|
|||||||
@@ -90,7 +90,7 @@
|
|||||||
<p>
|
<p>
|
||||||
Selects the cryptographic algorithm. The value of
|
Selects the cryptographic algorithm. The value of
|
||||||
<code class="option">algorithm</code> must be one of RSAMD5, RSASHA1,
|
<code class="option">algorithm</code> must be one of RSAMD5, RSASHA1,
|
||||||
NSEC3RSASHA1, RSASHA256, RSASHA512,
|
DSA, NSEC3RSASHA1, NSEC3DSA, RSASHA256, RSASHA512,
|
||||||
ECDSAP256SHA256, ECDSAP384SHA384, ED25519 or ED448.
|
ECDSAP256SHA256, ECDSAP384SHA384, ED25519 or ED448.
|
||||||
</p>
|
</p>
|
||||||
<p>
|
<p>
|
||||||
@@ -103,9 +103,9 @@
|
|||||||
<p>
|
<p>
|
||||||
These values are case insensitive. In some cases, abbreviations
|
These values are case insensitive. In some cases, abbreviations
|
||||||
are supported, such as ECDSA256 for ECDSAP256SHA256 and
|
are supported, such as ECDSA256 for ECDSAP256SHA256 and
|
||||||
ECDSA384 for ECDSAP384SHA384. If RSASHA1 is specified
|
ECDSA384 for ECDSAP384SHA384. If RSASHA1 or DSA is specified
|
||||||
along with the <code class="option">-3</code> option, then NSEC3RSASHA1
|
along with the <code class="option">-3</code> option, then NSEC3RSASHA1
|
||||||
will be used instead.
|
or NSEC3DSA will be used instead.
|
||||||
</p>
|
</p>
|
||||||
<p>
|
<p>
|
||||||
As of BIND 9.12.0, this option is mandatory except when using
|
As of BIND 9.12.0, this option is mandatory except when using
|
||||||
|
|||||||
@@ -62,13 +62,13 @@ may be preferable to direct use of
|
|||||||
.RS 4
|
.RS 4
|
||||||
Selects the cryptographic algorithm\&. For DNSSEC keys, the value of
|
Selects the cryptographic algorithm\&. For DNSSEC keys, the value of
|
||||||
\fBalgorithm\fR
|
\fBalgorithm\fR
|
||||||
must be one of RSAMD5, RSASHA1, NSEC3RSASHA1, RSASHA256, RSASHA512, ECDSAP256SHA256, ECDSAP384SHA384, ED25519 or ED448\&. For TKEY, the value must be DH (Diffie Hellman); specifying his value will automatically set the
|
must be one of RSAMD5, RSASHA1, DSA, NSEC3RSASHA1, NSEC3DSA, RSASHA256, RSASHA512, ECDSAP256SHA256, ECDSAP384SHA384, ED25519 or ED448\&. For TKEY, the value must be DH (Diffie Hellman); specifying his value will automatically set the
|
||||||
\fB\-T KEY\fR
|
\fB\-T KEY\fR
|
||||||
option as well\&.
|
option as well\&.
|
||||||
.sp
|
.sp
|
||||||
These values are case insensitive\&. In some cases, abbreviations are supported, such as ECDSA256 for ECDSAP256SHA256 and ECDSA384 for ECDSAP384SHA384\&. If RSASHA1 is specified along with the
|
These values are case insensitive\&. In some cases, abbreviations are supported, such as ECDSA256 for ECDSAP256SHA256 and ECDSA384 for ECDSAP384SHA384\&. If RSASHA1 or DSA is specified along with the
|
||||||
\fB\-3\fR
|
\fB\-3\fR
|
||||||
option, then NSEC3RSASHA1 will be used instead\&.
|
option, then NSEC3RSASHA1 or NSEC3DSA will be used instead\&.
|
||||||
.sp
|
.sp
|
||||||
This parameter
|
This parameter
|
||||||
\fImust\fR
|
\fImust\fR
|
||||||
|
|||||||
@@ -79,8 +79,8 @@ usage(void) {
|
|||||||
fprintf(stderr, "Options:\n");
|
fprintf(stderr, "Options:\n");
|
||||||
fprintf(stderr, " -K <directory>: write keys into directory\n");
|
fprintf(stderr, " -K <directory>: write keys into directory\n");
|
||||||
fprintf(stderr, " -a <algorithm>:\n");
|
fprintf(stderr, " -a <algorithm>:\n");
|
||||||
fprintf(stderr, " RSA | RSAMD5 | RSASHA1 | NSEC3RSASHA1"
|
fprintf(stderr, " RSA | RSAMD5 | DSA | RSASHA1 | NSEC3RSASHA1"
|
||||||
" |\n");
|
" | NSEC3DSA |\n");
|
||||||
fprintf(stderr, " RSASHA256 | RSASHA512 |\n");
|
fprintf(stderr, " RSASHA256 | RSASHA512 |\n");
|
||||||
fprintf(stderr, " ECDSAP256SHA256 | ECDSAP384SHA384 |\n");
|
fprintf(stderr, " ECDSAP256SHA256 | ECDSAP384SHA384 |\n");
|
||||||
fprintf(stderr, " ED25519 | ED448 | DH\n");
|
fprintf(stderr, " ED25519 | ED448 | DH\n");
|
||||||
@@ -92,6 +92,10 @@ usage(void) {
|
|||||||
fprintf(stderr, " RSASHA256:\t[1024..%d]\n", MAX_RSA);
|
fprintf(stderr, " RSASHA256:\t[1024..%d]\n", MAX_RSA);
|
||||||
fprintf(stderr, " RSASHA512:\t[1024..%d]\n", MAX_RSA);
|
fprintf(stderr, " RSASHA512:\t[1024..%d]\n", MAX_RSA);
|
||||||
fprintf(stderr, " DH:\t\t[128..4096]\n");
|
fprintf(stderr, " DH:\t\t[128..4096]\n");
|
||||||
|
fprintf(stderr, " DSA:\t\t[512..1024] and divisible by 64\n");
|
||||||
|
fprintf(stderr, " NSEC3DSA:\t[512..1024] and divisible "
|
||||||
|
"by 64\n");
|
||||||
|
fprintf(stderr, " ECCGOST:\tignored\n");
|
||||||
fprintf(stderr, " ECDSAP256SHA256:\tignored\n");
|
fprintf(stderr, " ECDSAP256SHA256:\tignored\n");
|
||||||
fprintf(stderr, " ECDSAP384SHA384:\tignored\n");
|
fprintf(stderr, " ECDSAP384SHA384:\tignored\n");
|
||||||
fprintf(stderr, " ED25519:\tignored\n");
|
fprintf(stderr, " ED25519:\tignored\n");
|
||||||
@@ -157,6 +161,11 @@ usage(void) {
|
|||||||
exit (-1);
|
exit (-1);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
static bool
|
||||||
|
dsa_size_ok(int size) {
|
||||||
|
return (size >= 512 && size <= 1024 && size % 64 == 0);
|
||||||
|
}
|
||||||
|
|
||||||
static void
|
static void
|
||||||
progress(int p)
|
progress(int p)
|
||||||
{
|
{
|
||||||
@@ -299,7 +308,7 @@ main(int argc, char **argv) {
|
|||||||
case 'e':
|
case 'e':
|
||||||
fprintf(stderr,
|
fprintf(stderr,
|
||||||
"phased-out option -e "
|
"phased-out option -e "
|
||||||
"(was 'use (RSA) large exponent')\n");
|
"(was 'use (RSA) large exponent)\n");
|
||||||
break;
|
break;
|
||||||
case 'f':
|
case 'f':
|
||||||
c = (unsigned char)(isc_commandline_argument[0]);
|
c = (unsigned char)(isc_commandline_argument[0]);
|
||||||
@@ -533,12 +542,17 @@ main(int argc, char **argv) {
|
|||||||
|
|
||||||
if (use_nsec3) {
|
if (use_nsec3) {
|
||||||
switch (alg) {
|
switch (alg) {
|
||||||
|
case DST_ALG_DSA:
|
||||||
|
alg = DST_ALG_NSEC3DSA;
|
||||||
|
break;
|
||||||
case DST_ALG_RSASHA1:
|
case DST_ALG_RSASHA1:
|
||||||
alg = DST_ALG_NSEC3RSASHA1;
|
alg = DST_ALG_NSEC3RSASHA1;
|
||||||
break;
|
break;
|
||||||
|
case DST_ALG_NSEC3DSA:
|
||||||
case DST_ALG_NSEC3RSASHA1:
|
case DST_ALG_NSEC3RSASHA1:
|
||||||
case DST_ALG_RSASHA256:
|
case DST_ALG_RSASHA256:
|
||||||
case DST_ALG_RSASHA512:
|
case DST_ALG_RSASHA512:
|
||||||
|
case DST_ALG_ECCGOST:
|
||||||
case DST_ALG_ECDSA256:
|
case DST_ALG_ECDSA256:
|
||||||
case DST_ALG_ECDSA384:
|
case DST_ALG_ECDSA384:
|
||||||
case DST_ALG_ED25519:
|
case DST_ALG_ED25519:
|
||||||
@@ -584,6 +598,7 @@ main(int argc, char **argv) {
|
|||||||
" to %d\n", size);
|
" to %d\n", size);
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
|
case DST_ALG_ECCGOST:
|
||||||
case DST_ALG_ECDSA256:
|
case DST_ALG_ECDSA256:
|
||||||
case DST_ALG_ECDSA384:
|
case DST_ALG_ECDSA384:
|
||||||
case DST_ALG_ED25519:
|
case DST_ALG_ED25519:
|
||||||
@@ -713,6 +728,14 @@ main(int argc, char **argv) {
|
|||||||
if (size != 0 && (size < 128 || size > 4096))
|
if (size != 0 && (size < 128 || size > 4096))
|
||||||
fatal("DH key size %d out of range", size);
|
fatal("DH key size %d out of range", size);
|
||||||
break;
|
break;
|
||||||
|
case DNS_KEYALG_DSA:
|
||||||
|
case DNS_KEYALG_NSEC3DSA:
|
||||||
|
if (size != 0 && !dsa_size_ok(size))
|
||||||
|
fatal("invalid DSS key size: %d", size);
|
||||||
|
break;
|
||||||
|
case DST_ALG_ECCGOST:
|
||||||
|
size = 256;
|
||||||
|
break;
|
||||||
case DST_ALG_ECDSA256:
|
case DST_ALG_ECDSA256:
|
||||||
size = 256;
|
size = 256;
|
||||||
break;
|
break;
|
||||||
@@ -792,6 +815,9 @@ main(int argc, char **argv) {
|
|||||||
param = generator;
|
param = generator;
|
||||||
break;
|
break;
|
||||||
|
|
||||||
|
case DNS_KEYALG_DSA:
|
||||||
|
case DNS_KEYALG_NSEC3DSA:
|
||||||
|
case DST_ALG_ECCGOST:
|
||||||
case DST_ALG_ECDSA256:
|
case DST_ALG_ECDSA256:
|
||||||
case DST_ALG_ECDSA384:
|
case DST_ALG_ECDSA384:
|
||||||
case DST_ALG_ED25519:
|
case DST_ALG_ED25519:
|
||||||
|
|||||||
@@ -123,7 +123,7 @@
|
|||||||
<para>
|
<para>
|
||||||
Selects the cryptographic algorithm. For DNSSEC keys, the value
|
Selects the cryptographic algorithm. For DNSSEC keys, the value
|
||||||
of <option>algorithm</option> must be one of RSAMD5, RSASHA1,
|
of <option>algorithm</option> must be one of RSAMD5, RSASHA1,
|
||||||
NSEC3RSASHA1, RSASHA256, RSASHA512,
|
DSA, NSEC3RSASHA1, NSEC3DSA, RSASHA256, RSASHA512,
|
||||||
ECDSAP256SHA256, ECDSAP384SHA384, ED25519 or ED448. For
|
ECDSAP256SHA256, ECDSAP384SHA384, ED25519 or ED448. For
|
||||||
TKEY, the value must be DH (Diffie Hellman); specifying
|
TKEY, the value must be DH (Diffie Hellman); specifying
|
||||||
his value will automatically set the <option>-T KEY</option>
|
his value will automatically set the <option>-T KEY</option>
|
||||||
@@ -132,9 +132,9 @@
|
|||||||
<para>
|
<para>
|
||||||
These values are case insensitive. In some cases, abbreviations
|
These values are case insensitive. In some cases, abbreviations
|
||||||
are supported, such as ECDSA256 for ECDSAP256SHA256 and
|
are supported, such as ECDSA256 for ECDSAP256SHA256 and
|
||||||
ECDSA384 for ECDSAP384SHA384. If RSASHA1 is specified
|
ECDSA384 for ECDSAP384SHA384. If RSASHA1 or DSA is specified
|
||||||
along with the <option>-3</option> option, then NSEC3RSASHA1
|
along with the <option>-3</option> option, then NSEC3RSASHA1
|
||||||
will be used instead.
|
or NSEC3DSA will be used instead.
|
||||||
</para>
|
</para>
|
||||||
<para>
|
<para>
|
||||||
This parameter <emphasis>must</emphasis> be specified except
|
This parameter <emphasis>must</emphasis> be specified except
|
||||||
|
|||||||
@@ -100,7 +100,7 @@
|
|||||||
<p>
|
<p>
|
||||||
Selects the cryptographic algorithm. For DNSSEC keys, the value
|
Selects the cryptographic algorithm. For DNSSEC keys, the value
|
||||||
of <code class="option">algorithm</code> must be one of RSAMD5, RSASHA1,
|
of <code class="option">algorithm</code> must be one of RSAMD5, RSASHA1,
|
||||||
NSEC3RSASHA1, RSASHA256, RSASHA512,
|
DSA, NSEC3RSASHA1, NSEC3DSA, RSASHA256, RSASHA512,
|
||||||
ECDSAP256SHA256, ECDSAP384SHA384, ED25519 or ED448. For
|
ECDSAP256SHA256, ECDSAP384SHA384, ED25519 or ED448. For
|
||||||
TKEY, the value must be DH (Diffie Hellman); specifying
|
TKEY, the value must be DH (Diffie Hellman); specifying
|
||||||
his value will automatically set the <code class="option">-T KEY</code>
|
his value will automatically set the <code class="option">-T KEY</code>
|
||||||
@@ -109,9 +109,9 @@
|
|||||||
<p>
|
<p>
|
||||||
These values are case insensitive. In some cases, abbreviations
|
These values are case insensitive. In some cases, abbreviations
|
||||||
are supported, such as ECDSA256 for ECDSAP256SHA256 and
|
are supported, such as ECDSA256 for ECDSAP256SHA256 and
|
||||||
ECDSA384 for ECDSAP384SHA384. If RSASHA1 is specified
|
ECDSA384 for ECDSAP384SHA384. If RSASHA1 or DSA is specified
|
||||||
along with the <code class="option">-3</code> option, then NSEC3RSASHA1
|
along with the <code class="option">-3</code> option, then NSEC3RSASHA1
|
||||||
will be used instead.
|
or NSEC3DSA will be used instead.
|
||||||
</p>
|
</p>
|
||||||
<p>
|
<p>
|
||||||
This parameter <span class="emphasis"><em>must</em></span> be specified except
|
This parameter <span class="emphasis"><em>must</em></span> be specified except
|
||||||
|
|||||||
@@ -40,7 +40,6 @@
|
|||||||
#include <isc/file.h>
|
#include <isc/file.h>
|
||||||
#include <isc/hash.h>
|
#include <isc/hash.h>
|
||||||
#include <isc/hex.h>
|
#include <isc/hex.h>
|
||||||
#include <isc/md.h>
|
|
||||||
#include <isc/mem.h>
|
#include <isc/mem.h>
|
||||||
#include <isc/mutex.h>
|
#include <isc/mutex.h>
|
||||||
#include <isc/os.h>
|
#include <isc/os.h>
|
||||||
@@ -533,6 +532,8 @@ signset(dns_diff_t *del, dns_diff_t *add, dns_dbnode_t *node, dns_name_t *name,
|
|||||||
arraysize += dns_rdataset_count(&sigset);
|
arraysize += dns_rdataset_count(&sigset);
|
||||||
wassignedby = isc_mem_get(mctx, arraysize * sizeof(bool));
|
wassignedby = isc_mem_get(mctx, arraysize * sizeof(bool));
|
||||||
nowsignedby = isc_mem_get(mctx, arraysize * sizeof(bool));
|
nowsignedby = isc_mem_get(mctx, arraysize * sizeof(bool));
|
||||||
|
if (wassignedby == NULL || nowsignedby == NULL)
|
||||||
|
fatal("out of memory");
|
||||||
|
|
||||||
for (i = 0; i < arraysize; i++)
|
for (i = 0; i < arraysize; i++)
|
||||||
wassignedby[i] = nowsignedby[i] = false;
|
wassignedby[i] = nowsignedby[i] = false;
|
||||||
@@ -3853,7 +3854,7 @@ main(int argc, char *argv[]) {
|
|||||||
print_time(outfp);
|
print_time(outfp);
|
||||||
print_version(outfp);
|
print_version(outfp);
|
||||||
|
|
||||||
result = isc_taskmgr_create(mctx, ntasks, &taskmgr);
|
result = isc_taskmgr_create(mctx, ntasks, 0, &taskmgr);
|
||||||
if (result != ISC_R_SUCCESS)
|
if (result != ISC_R_SUCCESS)
|
||||||
fatal("failed to create task manager: %s",
|
fatal("failed to create task manager: %s",
|
||||||
isc_result_totext(result));
|
isc_result_totext(result));
|
||||||
@@ -3874,11 +3875,9 @@ main(int argc, char *argv[]) {
|
|||||||
isc_result_totext(result));
|
isc_result_totext(result));
|
||||||
}
|
}
|
||||||
|
|
||||||
isc_mutex_init(&namelock);
|
RUNTIME_CHECK(isc_mutex_init(&namelock) == ISC_R_SUCCESS);
|
||||||
|
if (printstats)
|
||||||
if (printstats) {
|
RUNTIME_CHECK(isc_mutex_init(&statslock) == ISC_R_SUCCESS);
|
||||||
isc_mutex_init(&statslock);
|
|
||||||
}
|
|
||||||
|
|
||||||
presign();
|
presign();
|
||||||
TIME_NOW(&sign_start);
|
TIME_NOW(&sign_start);
|
||||||
@@ -3936,9 +3935,9 @@ main(int argc, char *argv[]) {
|
|||||||
check_result(result, "dns_master_dumptostream3");
|
check_result(result, "dns_master_dumptostream3");
|
||||||
}
|
}
|
||||||
|
|
||||||
isc_mutex_destroy(&namelock);
|
DESTROYLOCK(&namelock);
|
||||||
if (printstats)
|
if (printstats)
|
||||||
isc_mutex_destroy(&statslock);
|
DESTROYLOCK(&statslock);
|
||||||
|
|
||||||
if (!output_stdout) {
|
if (!output_stdout) {
|
||||||
result = isc_stdio_close(outfp);
|
result = isc_stdio_close(outfp);
|
||||||
|
|||||||
@@ -198,25 +198,6 @@
|
|||||||
background-color: #99ddff;
|
background-color: #99ddff;
|
||||||
}
|
}
|
||||||
|
|
||||||
table.zones {
|
|
||||||
border: 1px solid grey;
|
|
||||||
width: 500px;
|
|
||||||
}
|
|
||||||
table.zones th {
|
|
||||||
text-align: center;
|
|
||||||
border: 1px solid grey;
|
|
||||||
}
|
|
||||||
table.zones td {
|
|
||||||
text-align: center;
|
|
||||||
font-family: monospace;
|
|
||||||
}
|
|
||||||
table.zones td:nth-child(1) {
|
|
||||||
text-align: right;
|
|
||||||
}
|
|
||||||
table.zones td:nth-child(4) {
|
|
||||||
text-align: right;
|
|
||||||
}
|
|
||||||
|
|
||||||
.totals {
|
.totals {
|
||||||
background-color: rgb(1,169,206);
|
background-color: rgb(1,169,206);
|
||||||
color: #ffffff;
|
color: #ffffff;
|
||||||
@@ -724,35 +705,6 @@
|
|||||||
</table>
|
</table>
|
||||||
<br/>
|
<br/>
|
||||||
</xsl:if>
|
</xsl:if>
|
||||||
<xsl:for-each select="views/view">
|
|
||||||
<xsl:if test="zones/zone">
|
|
||||||
<h3>Zones for View <xsl:value-of select="@name"/></h3>
|
|
||||||
<table class="zones">
|
|
||||||
<tr>
|
|
||||||
<th>Name</th>
|
|
||||||
<th>Class</th>
|
|
||||||
<th>Type</th>
|
|
||||||
<th>Serial</th>
|
|
||||||
</tr>
|
|
||||||
<xsl:for-each select="zones/zone">
|
|
||||||
<tr>
|
|
||||||
<td>
|
|
||||||
<xsl:value-of select="@name"/>
|
|
||||||
</td>
|
|
||||||
<td>
|
|
||||||
<xsl:value-of select="@rdataclass"/>
|
|
||||||
</td>
|
|
||||||
<td>
|
|
||||||
<xsl:value-of select="type"/>
|
|
||||||
</td>
|
|
||||||
<td>
|
|
||||||
<xsl:value-of select="serial"/>
|
|
||||||
</td>
|
|
||||||
</tr>
|
|
||||||
</xsl:for-each>
|
|
||||||
</table>
|
|
||||||
</xsl:if>
|
|
||||||
</xsl:for-each>
|
|
||||||
<xsl:if test="views/view[zones/zone/counters[@type="qtype"]/counter >0]">
|
<xsl:if test="views/view[zones/zone/counters[@type="qtype"]/counter >0]">
|
||||||
<h2>Received QTYPES per view/zone</h2>
|
<h2>Received QTYPES per view/zone</h2>
|
||||||
<xsl:for-each select="views/view[zones/zone/counters[@type="qtype"]/counter >0]">
|
<xsl:for-each select="views/view[zones/zone/counters[@type="qtype"]/counter >0]">
|
||||||
|
|||||||
@@ -203,25 +203,6 @@ static char xslmsg[] =
|
|||||||
" background-color: #99ddff;\n"
|
" background-color: #99ddff;\n"
|
||||||
" }\n"
|
" }\n"
|
||||||
"\n"
|
"\n"
|
||||||
" table.zones {\n"
|
|
||||||
" border: 1px solid grey;\n"
|
|
||||||
" width: 500px;\n"
|
|
||||||
" }\n"
|
|
||||||
" table.zones th {\n"
|
|
||||||
" text-align: center;\n"
|
|
||||||
" border: 1px solid grey;\n"
|
|
||||||
" }\n"
|
|
||||||
" table.zones td {\n"
|
|
||||||
" text-align: center;\n"
|
|
||||||
" font-family: monospace;\n"
|
|
||||||
" }\n"
|
|
||||||
" table.zones td:nth-child(1) {\n"
|
|
||||||
" text-align: right;\n"
|
|
||||||
" }\n"
|
|
||||||
" table.zones td:nth-child(4) {\n"
|
|
||||||
" text-align: right;\n"
|
|
||||||
" }\n"
|
|
||||||
"\n"
|
|
||||||
" .totals {\n"
|
" .totals {\n"
|
||||||
" background-color: rgb(1,169,206);\n"
|
" background-color: rgb(1,169,206);\n"
|
||||||
" color: #ffffff;\n"
|
" color: #ffffff;\n"
|
||||||
@@ -729,35 +710,6 @@ static char xslmsg[] =
|
|||||||
" </table>\n"
|
" </table>\n"
|
||||||
" <br/>\n"
|
" <br/>\n"
|
||||||
" </xsl:if>\n"
|
" </xsl:if>\n"
|
||||||
" <xsl:for-each select=\"views/view\">\n"
|
|
||||||
" <xsl:if test=\"zones/zone\">\n"
|
|
||||||
" <h3>Zones for View <xsl:value-of select=\"@name\"/></h3>\n"
|
|
||||||
" <table class=\"zones\">\n"
|
|
||||||
" <tr>\n"
|
|
||||||
" <th>Name</th>\n"
|
|
||||||
" <th>Class</th>\n"
|
|
||||||
" <th>Type</th>\n"
|
|
||||||
" <th>Serial</th>\n"
|
|
||||||
" </tr>\n"
|
|
||||||
" <xsl:for-each select=\"zones/zone\">\n"
|
|
||||||
" <tr>\n"
|
|
||||||
" <td>\n"
|
|
||||||
" <xsl:value-of select=\"@name\"/>\n"
|
|
||||||
" </td>\n"
|
|
||||||
" <td>\n"
|
|
||||||
" <xsl:value-of select=\"@rdataclass\"/>\n"
|
|
||||||
" </td>\n"
|
|
||||||
" <td>\n"
|
|
||||||
" <xsl:value-of select=\"type\"/>\n"
|
|
||||||
" </td>\n"
|
|
||||||
" <td>\n"
|
|
||||||
" <xsl:value-of select=\"serial\"/>\n"
|
|
||||||
" </td>\n"
|
|
||||||
" </tr>\n"
|
|
||||||
" </xsl:for-each>\n"
|
|
||||||
" </table>\n"
|
|
||||||
" </xsl:if>\n"
|
|
||||||
" </xsl:for-each>\n"
|
|
||||||
" <xsl:if test=\"views/view[zones/zone/counters[@type="qtype"]/counter >0]\">\n"
|
" <xsl:if test=\"views/view[zones/zone/counters[@type="qtype"]/counter >0]\">\n"
|
||||||
" <h2>Received QTYPES per view/zone</h2>\n"
|
" <h2>Received QTYPES per view/zone</h2>\n"
|
||||||
" <xsl:for-each select=\"views/view[zones/zone/counters[@type="qtype"]/counter >0]\">\n"
|
" <xsl:for-each select=\"views/view[zones/zone/counters[@type="qtype"]/counter >0]\">\n"
|
||||||
|
|||||||
+4
-26
@@ -174,8 +174,6 @@ options {\n\
|
|||||||
max-recursion-queries 75;\n\
|
max-recursion-queries 75;\n\
|
||||||
max-stale-ttl 604800; /* 1 week */\n\
|
max-stale-ttl 604800; /* 1 week */\n\
|
||||||
message-compression yes;\n\
|
message-compression yes;\n\
|
||||||
min-ncache-ttl 0; /* 0 hours */\n\
|
|
||||||
min-cache-ttl 0; /* 0 seconds */\n\
|
|
||||||
# min-roots <obsolete>;\n\
|
# min-roots <obsolete>;\n\
|
||||||
minimal-any false;\n\
|
minimal-any false;\n\
|
||||||
minimal-responses no-auth-recursive;\n\
|
minimal-responses no-auth-recursive;\n\
|
||||||
@@ -303,21 +301,6 @@ view \"_bind\" chaos {\n\
|
|||||||
MANAGED_KEYS
|
MANAGED_KEYS
|
||||||
|
|
||||||
"# END MANAGED KEYS\n\
|
"# END MANAGED KEYS\n\
|
||||||
\n\
|
|
||||||
masters " DEFAULT_IANA_ROOT_ZONE_MASTERS " {\n\
|
|
||||||
2001:500:84::b; # b.root-servers.net\n\
|
|
||||||
2001:500:2f::f; # f.root-servers.net\n\
|
|
||||||
2001:7fd::1; # k.root-servers.net\n\
|
|
||||||
2620:0:2830:202::132; # xfr.cjr.dns.icann.org\n\
|
|
||||||
2620:0:2d0:202::132; # xfr.lax.dns.icann.org\n\
|
|
||||||
192.228.79.201; # b.root-servers.net\n\
|
|
||||||
192.33.4.12; # c.root-servers.net\n\
|
|
||||||
192.5.5.241; # f.root-servers.net\n\
|
|
||||||
192.112.36.4; # g.root-servers.net\n\
|
|
||||||
193.0.14.129; # k.root-servers.net\n\
|
|
||||||
192.0.47.132; # xfr.cjr.dns.icann.org\n\
|
|
||||||
192.0.32.132; # xfr.lax.dns.icann.org\n\
|
|
||||||
};\n\
|
|
||||||
";
|
";
|
||||||
|
|
||||||
isc_result_t
|
isc_result_t
|
||||||
@@ -449,8 +432,6 @@ named_config_getzonetype(const cfg_obj_t *zonetypeobj) {
|
|||||||
strcasecmp(str, "slave") == 0)
|
strcasecmp(str, "slave") == 0)
|
||||||
{
|
{
|
||||||
ztype = dns_zone_slave;
|
ztype = dns_zone_slave;
|
||||||
} else if (strcasecmp(str, "mirror") == 0) {
|
|
||||||
ztype = dns_zone_mirror;
|
|
||||||
} else if (strcasecmp(str, "stub") == 0) {
|
} else if (strcasecmp(str, "stub") == 0) {
|
||||||
ztype = dns_zone_stub;
|
ztype = dns_zone_stub;
|
||||||
} else if (strcasecmp(str, "static-stub") == 0) {
|
} else if (strcasecmp(str, "static-stub") == 0) {
|
||||||
@@ -459,7 +440,6 @@ named_config_getzonetype(const cfg_obj_t *zonetypeobj) {
|
|||||||
ztype = dns_zone_redirect;
|
ztype = dns_zone_redirect;
|
||||||
} else {
|
} else {
|
||||||
INSIST(0);
|
INSIST(0);
|
||||||
ISC_UNREACHABLE();
|
|
||||||
}
|
}
|
||||||
return (ztype);
|
return (ztype);
|
||||||
}
|
}
|
||||||
@@ -573,9 +553,9 @@ named_config_putiplist(isc_mem_t *mctx, isc_sockaddr_t **addrsp,
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
isc_result_t
|
static isc_result_t
|
||||||
named_config_getmastersdef(const cfg_obj_t *cctx, const char *name,
|
get_masters_def(const cfg_obj_t *cctx, const char *name,
|
||||||
const cfg_obj_t **ret)
|
const cfg_obj_t **ret)
|
||||||
{
|
{
|
||||||
isc_result_t result;
|
isc_result_t result;
|
||||||
const cfg_obj_t *masters = NULL;
|
const cfg_obj_t *masters = NULL;
|
||||||
@@ -717,8 +697,7 @@ named_config_getipandkeylist(const cfg_obj_t *config, const cfg_obj_t *list,
|
|||||||
break;
|
break;
|
||||||
if (j < l)
|
if (j < l)
|
||||||
continue;
|
continue;
|
||||||
tresult = named_config_getmastersdef(config, listname,
|
tresult = get_masters_def(config, listname, &list);
|
||||||
&list);
|
|
||||||
if (tresult == ISC_R_NOTFOUND) {
|
if (tresult == ISC_R_NOTFOUND) {
|
||||||
cfg_obj_log(addr, named_g_lctx, ISC_LOG_ERROR,
|
cfg_obj_log(addr, named_g_lctx, ISC_LOG_ERROR,
|
||||||
"masters \"%s\" not found", listname);
|
"masters \"%s\" not found", listname);
|
||||||
@@ -1032,7 +1011,6 @@ named_config_getkeyalgorithm2(const char *str, const dns_name_t **name,
|
|||||||
case hmacsha512: *name = dns_tsig_hmacsha512_name; break;
|
case hmacsha512: *name = dns_tsig_hmacsha512_name; break;
|
||||||
default:
|
default:
|
||||||
INSIST(0);
|
INSIST(0);
|
||||||
ISC_UNREACHABLE();
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if (typep != NULL)
|
if (typep != NULL)
|
||||||
|
|||||||
@@ -22,8 +22,6 @@
|
|||||||
#include <dns/types.h>
|
#include <dns/types.h>
|
||||||
#include <dns/zone.h>
|
#include <dns/zone.h>
|
||||||
|
|
||||||
#define DEFAULT_IANA_ROOT_ZONE_MASTERS "_default_iana_root_zone_masters"
|
|
||||||
|
|
||||||
isc_result_t
|
isc_result_t
|
||||||
named_config_parsedefaults(cfg_parser_t *parser, cfg_obj_t **conf);
|
named_config_parsedefaults(cfg_parser_t *parser, cfg_obj_t **conf);
|
||||||
|
|
||||||
@@ -59,10 +57,6 @@ void
|
|||||||
named_config_putiplist(isc_mem_t *mctx, isc_sockaddr_t **addrsp,
|
named_config_putiplist(isc_mem_t *mctx, isc_sockaddr_t **addrsp,
|
||||||
isc_dscp_t **dscpsp, uint32_t count);
|
isc_dscp_t **dscpsp, uint32_t count);
|
||||||
|
|
||||||
isc_result_t
|
|
||||||
named_config_getmastersdef(const cfg_obj_t *cctx, const char *name,
|
|
||||||
const cfg_obj_t **ret);
|
|
||||||
|
|
||||||
isc_result_t
|
isc_result_t
|
||||||
named_config_getipandkeylist(const cfg_obj_t *config, const cfg_obj_t *list,
|
named_config_getipandkeylist(const cfg_obj_t *config, const cfg_obj_t *list,
|
||||||
isc_mem_t *mctx, dns_ipkeylist_t *ipkl);
|
isc_mem_t *mctx, dns_ipkeylist_t *ipkl);
|
||||||
|
|||||||
@@ -157,7 +157,6 @@ channel_fromconf(const cfg_obj_t *channel, isc_logconfig_t *logconfig) {
|
|||||||
break;
|
break;
|
||||||
default:
|
default:
|
||||||
INSIST(0);
|
INSIST(0);
|
||||||
ISC_UNREACHABLE();
|
|
||||||
}
|
}
|
||||||
|
|
||||||
type = ISC_LOG_TOFILE;
|
type = ISC_LOG_TOFILE;
|
||||||
|
|||||||
+50
-56
@@ -122,17 +122,14 @@ static int maxudp = 0;
|
|||||||
*/
|
*/
|
||||||
static bool clienttest = false;
|
static bool clienttest = false;
|
||||||
static bool dropedns = false;
|
static bool dropedns = false;
|
||||||
static bool ednsformerr = false;
|
|
||||||
static bool ednsnotimp = false;
|
|
||||||
static bool ednsrefused = false;
|
|
||||||
static bool fixedlocal = false;
|
|
||||||
static bool noaa = false;
|
|
||||||
static bool noedns = false;
|
static bool noedns = false;
|
||||||
static bool nonearest = false;
|
|
||||||
static bool nosoa = false;
|
static bool nosoa = false;
|
||||||
static bool notcp = false;
|
static bool noaa = false;
|
||||||
static bool sigvalinsecs = false;
|
|
||||||
static unsigned int delay = 0;
|
static unsigned int delay = 0;
|
||||||
|
static bool nonearest = false;
|
||||||
|
static bool notcp = false;
|
||||||
|
static bool fixedlocal = false;
|
||||||
|
static bool sigvalinsecs = false;
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* -4 and -6
|
* -4 and -6
|
||||||
@@ -491,12 +488,6 @@ parse_T_opt(char *option) {
|
|||||||
dropedns = true;
|
dropedns = true;
|
||||||
} else if (!strncmp(option, "dscp=", 5)) {
|
} else if (!strncmp(option, "dscp=", 5)) {
|
||||||
isc_dscp_check_value = atoi(option + 5);
|
isc_dscp_check_value = atoi(option + 5);
|
||||||
} else if (!strcmp(option, "ednsformerr")) {
|
|
||||||
ednsformerr = true;
|
|
||||||
} else if (!strcmp(option, "ednsnotimp")) {
|
|
||||||
ednsnotimp = true;
|
|
||||||
} else if (!strcmp(option, "ednsrefused")) {
|
|
||||||
ednsrefused = true;
|
|
||||||
} else if (!strcmp(option, "fixedlocal")) {
|
} else if (!strcmp(option, "fixedlocal")) {
|
||||||
fixedlocal = true;
|
fixedlocal = true;
|
||||||
} else if (!strcmp(option, "keepstderr")) {
|
} else if (!strcmp(option, "keepstderr")) {
|
||||||
@@ -556,7 +547,7 @@ parse_T_opt(char *option) {
|
|||||||
} else if (!strncmp(option, "tat=", 4)) {
|
} else if (!strncmp(option, "tat=", 4)) {
|
||||||
named_g_tat_interval = atoi(option + 4);
|
named_g_tat_interval = atoi(option + 4);
|
||||||
} else {
|
} else {
|
||||||
fprintf(stderr, "unknown -T flag '%s'\n", option);
|
fprintf(stderr, "unknown -T flag '%s\n", option);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -793,7 +784,10 @@ create_managers(void) {
|
|||||||
named_g_udpdisp = 1;
|
named_g_udpdisp = 1;
|
||||||
#else
|
#else
|
||||||
if (named_g_udpdisp == 0) {
|
if (named_g_udpdisp == 0) {
|
||||||
named_g_udpdisp = named_g_cpus_detected;
|
if (named_g_cpus_detected == 1)
|
||||||
|
named_g_udpdisp = 1;
|
||||||
|
else
|
||||||
|
named_g_udpdisp = named_g_cpus_detected - 1;
|
||||||
}
|
}
|
||||||
if (named_g_udpdisp > named_g_cpus)
|
if (named_g_udpdisp > named_g_cpus)
|
||||||
named_g_udpdisp = named_g_cpus;
|
named_g_udpdisp = named_g_cpus;
|
||||||
@@ -803,7 +797,7 @@ create_managers(void) {
|
|||||||
"using %u UDP listener%s per interface",
|
"using %u UDP listener%s per interface",
|
||||||
named_g_udpdisp, named_g_udpdisp == 1 ? "" : "s");
|
named_g_udpdisp, named_g_udpdisp == 1 ? "" : "s");
|
||||||
|
|
||||||
result = isc_taskmgr_create(named_g_mctx, named_g_cpus,
|
result = isc_taskmgr_create(named_g_mctx, named_g_cpus, 0,
|
||||||
&named_g_taskmgr);
|
&named_g_taskmgr);
|
||||||
if (result != ISC_R_SUCCESS) {
|
if (result != ISC_R_SUCCESS) {
|
||||||
UNEXPECTED_ERROR(__FILE__, __LINE__,
|
UNEXPECTED_ERROR(__FILE__, __LINE__,
|
||||||
@@ -821,14 +815,14 @@ create_managers(void) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
result = isc_socketmgr_create2(named_g_mctx, &named_g_socketmgr,
|
result = isc_socketmgr_create2(named_g_mctx, &named_g_socketmgr,
|
||||||
maxsocks, named_g_cpus);
|
maxsocks);
|
||||||
if (result != ISC_R_SUCCESS) {
|
if (result != ISC_R_SUCCESS) {
|
||||||
UNEXPECTED_ERROR(__FILE__, __LINE__,
|
UNEXPECTED_ERROR(__FILE__, __LINE__,
|
||||||
"isc_socketmgr_create() failed: %s",
|
"isc_socketmgr_create() failed: %s",
|
||||||
isc_result_totext(result));
|
isc_result_totext(result));
|
||||||
return (ISC_R_UNEXPECTED);
|
return (ISC_R_UNEXPECTED);
|
||||||
}
|
}
|
||||||
isc_socketmgr_maxudp(named_g_socketmgr, maxudp);
|
isc__socketmgr_maxudp(named_g_socketmgr, maxudp);
|
||||||
result = isc_socketmgr_getmaxsockets(named_g_socketmgr, &socks);
|
result = isc_socketmgr_getmaxsockets(named_g_socketmgr, &socks);
|
||||||
if (result == ISC_R_SUCCESS) {
|
if (result == ISC_R_SUCCESS) {
|
||||||
isc_log_write(named_g_lctx, NAMED_LOGCATEGORY_GENERAL,
|
isc_log_write(named_g_lctx, NAMED_LOGCATEGORY_GENERAL,
|
||||||
@@ -1041,6 +1035,16 @@ setup(void) {
|
|||||||
NAMED_LOGMODULE_MAIN, ISC_LOG_NOTICE,
|
NAMED_LOGMODULE_MAIN, ISC_LOG_NOTICE,
|
||||||
"linked to zlib version: %s", zlibVersion());
|
"linked to zlib version: %s", zlibVersion());
|
||||||
#endif
|
#endif
|
||||||
|
#ifdef ISC_PLATFORM_USETHREADS
|
||||||
|
isc_log_write(named_g_lctx, NAMED_LOGCATEGORY_GENERAL,
|
||||||
|
NAMED_LOGMODULE_MAIN, ISC_LOG_NOTICE,
|
||||||
|
"threads support is enabled");
|
||||||
|
#else
|
||||||
|
isc_log_write(named_g_lctx, NAMED_LOGCATEGORY_GENERAL,
|
||||||
|
NAMED_LOGMODULE_MAIN, ISC_LOG_NOTICE,
|
||||||
|
"threads support is disabled");
|
||||||
|
#endif
|
||||||
|
|
||||||
isc_log_write(named_g_lctx, NAMED_LOGCATEGORY_GENERAL,
|
isc_log_write(named_g_lctx, NAMED_LOGCATEGORY_GENERAL,
|
||||||
NAMED_LOGMODULE_MAIN, ISC_LOG_NOTICE,
|
NAMED_LOGMODULE_MAIN, ISC_LOG_NOTICE,
|
||||||
"----------------------------------------------------");
|
"----------------------------------------------------");
|
||||||
@@ -1065,20 +1069,14 @@ setup(void) {
|
|||||||
/*
|
/*
|
||||||
* Get the initial resource limits.
|
* Get the initial resource limits.
|
||||||
*/
|
*/
|
||||||
#ifndef WIN32
|
(void)isc_resource_getlimit(isc_resource_stacksize,
|
||||||
RUNTIME_CHECK(isc_resource_getlimit(isc_resource_stacksize,
|
&named_g_initstacksize);
|
||||||
&named_g_initstacksize)
|
(void)isc_resource_getlimit(isc_resource_datasize,
|
||||||
== ISC_R_SUCCESS);
|
&named_g_initdatasize);
|
||||||
RUNTIME_CHECK(isc_resource_getlimit(isc_resource_datasize,
|
(void)isc_resource_getlimit(isc_resource_coresize,
|
||||||
&named_g_initdatasize)
|
&named_g_initcoresize);
|
||||||
== ISC_R_SUCCESS);
|
(void)isc_resource_getlimit(isc_resource_openfiles,
|
||||||
RUNTIME_CHECK(isc_resource_getlimit(isc_resource_coresize,
|
&named_g_initopenfiles);
|
||||||
&named_g_initcoresize)
|
|
||||||
== ISC_R_SUCCESS);
|
|
||||||
#endif
|
|
||||||
RUNTIME_CHECK(isc_resource_getlimit(isc_resource_openfiles,
|
|
||||||
&named_g_initopenfiles)
|
|
||||||
== ISC_R_SUCCESS);
|
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* System resources cannot effectively be tuned on some systems.
|
* System resources cannot effectively be tuned on some systems.
|
||||||
@@ -1086,9 +1084,8 @@ setup(void) {
|
|||||||
*/
|
*/
|
||||||
old_openfiles = named_g_initopenfiles;
|
old_openfiles = named_g_initopenfiles;
|
||||||
named_os_adjustnofile();
|
named_os_adjustnofile();
|
||||||
RUNTIME_CHECK(isc_resource_getlimit(isc_resource_openfiles,
|
(void)isc_resource_getlimit(isc_resource_openfiles,
|
||||||
&named_g_initopenfiles)
|
&named_g_initopenfiles);
|
||||||
== ISC_R_SUCCESS);
|
|
||||||
if (old_openfiles != named_g_initopenfiles) {
|
if (old_openfiles != named_g_initopenfiles) {
|
||||||
isc_log_write(named_g_lctx, NAMED_LOGCATEGORY_GENERAL,
|
isc_log_write(named_g_lctx, NAMED_LOGCATEGORY_GENERAL,
|
||||||
NAMED_LOGMODULE_MAIN, ISC_LOG_NOTICE,
|
NAMED_LOGMODULE_MAIN, ISC_LOG_NOTICE,
|
||||||
@@ -1162,30 +1159,24 @@ setup(void) {
|
|||||||
*/
|
*/
|
||||||
if (clienttest)
|
if (clienttest)
|
||||||
ns_server_setoption(sctx, NS_SERVER_CLIENTTEST, true);
|
ns_server_setoption(sctx, NS_SERVER_CLIENTTEST, true);
|
||||||
|
if (dropedns)
|
||||||
|
ns_server_setoption(sctx, NS_SERVER_DROPEDNS, true);
|
||||||
|
if (noedns)
|
||||||
|
ns_server_setoption(sctx, NS_SERVER_NOEDNS, true);
|
||||||
|
if (nosoa)
|
||||||
|
ns_server_setoption(sctx, NS_SERVER_NOSOA, true);
|
||||||
|
if (noaa)
|
||||||
|
ns_server_setoption(sctx, NS_SERVER_NOAA, true);
|
||||||
|
if (nonearest)
|
||||||
|
ns_server_setoption(sctx, NS_SERVER_NONEAREST, true);
|
||||||
|
if (notcp)
|
||||||
|
ns_server_setoption(sctx, NS_SERVER_NOTCP, true);
|
||||||
|
if (fixedlocal)
|
||||||
|
ns_server_setoption(sctx, NS_SERVER_FIXEDLOCAL, true);
|
||||||
if (disable4)
|
if (disable4)
|
||||||
ns_server_setoption(sctx, NS_SERVER_DISABLE4, true);
|
ns_server_setoption(sctx, NS_SERVER_DISABLE4, true);
|
||||||
if (disable6)
|
if (disable6)
|
||||||
ns_server_setoption(sctx, NS_SERVER_DISABLE6, true);
|
ns_server_setoption(sctx, NS_SERVER_DISABLE6, true);
|
||||||
if (dropedns)
|
|
||||||
ns_server_setoption(sctx, NS_SERVER_DROPEDNS, true);
|
|
||||||
if (ednsformerr) /* STD13 server */
|
|
||||||
ns_server_setoption(sctx, NS_SERVER_EDNSFORMERR, true);
|
|
||||||
if (ednsnotimp)
|
|
||||||
ns_server_setoption(sctx, NS_SERVER_EDNSNOTIMP, true);
|
|
||||||
if (ednsrefused)
|
|
||||||
ns_server_setoption(sctx, NS_SERVER_EDNSREFUSED, true);
|
|
||||||
if (fixedlocal)
|
|
||||||
ns_server_setoption(sctx, NS_SERVER_FIXEDLOCAL, true);
|
|
||||||
if (noaa)
|
|
||||||
ns_server_setoption(sctx, NS_SERVER_NOAA, true);
|
|
||||||
if (noedns)
|
|
||||||
ns_server_setoption(sctx, NS_SERVER_NOEDNS, true);
|
|
||||||
if (nonearest)
|
|
||||||
ns_server_setoption(sctx, NS_SERVER_NONEAREST, true);
|
|
||||||
if (nosoa)
|
|
||||||
ns_server_setoption(sctx, NS_SERVER_NOSOA, true);
|
|
||||||
if (notcp)
|
|
||||||
ns_server_setoption(sctx, NS_SERVER_NOTCP, true);
|
|
||||||
if (sigvalinsecs)
|
if (sigvalinsecs)
|
||||||
ns_server_setoption(sctx, NS_SERVER_SIGVALINSECS, true);
|
ns_server_setoption(sctx, NS_SERVER_SIGVALINSECS, true);
|
||||||
|
|
||||||
@@ -1339,6 +1330,9 @@ main(int argc, char *argv[]) {
|
|||||||
if (result != ISC_R_SUCCESS)
|
if (result != ISC_R_SUCCESS)
|
||||||
named_main_earlyfatal("program name too long");
|
named_main_earlyfatal("program name too long");
|
||||||
|
|
||||||
|
if (result != ISC_R_SUCCESS)
|
||||||
|
named_main_earlyfatal("failed to build internal symbol table");
|
||||||
|
|
||||||
isc_assertion_setcallback(assertion_failed);
|
isc_assertion_setcallback(assertion_failed);
|
||||||
isc_error_setfatal(library_fatal_error);
|
isc_error_setfatal(library_fatal_error);
|
||||||
isc_error_setunexpected(library_unexpected_error);
|
isc_error_setunexpected(library_unexpected_error);
|
||||||
|
|||||||
+40
-41
@@ -10,12 +10,12 @@
|
|||||||
.\" Title: named.conf
|
.\" Title: named.conf
|
||||||
.\" Author:
|
.\" Author:
|
||||||
.\" Generator: DocBook XSL Stylesheets v1.78.1 <http://docbook.sf.net/>
|
.\" Generator: DocBook XSL Stylesheets v1.78.1 <http://docbook.sf.net/>
|
||||||
.\" Date: 2018-10-23
|
.\" Date: 2018-05-29
|
||||||
.\" Manual: BIND9
|
.\" Manual: BIND9
|
||||||
.\" Source: ISC
|
.\" Source: ISC
|
||||||
.\" Language: English
|
.\" Language: English
|
||||||
.\"
|
.\"
|
||||||
.TH "NAMED\&.CONF" "5" "2018\-10\-23" "ISC" "BIND9"
|
.TH "NAMED\&.CONF" "5" "2018\-05\-29" "ISC" "BIND9"
|
||||||
.\" -----------------------------------------------------------------
|
.\" -----------------------------------------------------------------
|
||||||
.\" * Define some portability stuff
|
.\" * Define some portability stuff
|
||||||
.\" -----------------------------------------------------------------
|
.\" -----------------------------------------------------------------
|
||||||
@@ -199,7 +199,6 @@ options {
|
|||||||
] [ dscp \fIinteger\fR ];
|
] [ dscp \fIinteger\fR ];
|
||||||
alt\-transfer\-source\-v6 ( \fIipv6_address\fR | * ) [ port ( \fIinteger\fR |
|
alt\-transfer\-source\-v6 ( \fIipv6_address\fR | * ) [ port ( \fIinteger\fR |
|
||||||
* ) ] [ dscp \fIinteger\fR ];
|
* ) ] [ dscp \fIinteger\fR ];
|
||||||
answer\-cookie \fIboolean\fR;
|
|
||||||
attach\-cache \fIstring\fR;
|
attach\-cache \fIstring\fR;
|
||||||
auth\-nxdomain \fIboolean\fR; // default changed
|
auth\-nxdomain \fIboolean\fR; // default changed
|
||||||
auto\-dnssec ( allow | maintain | off );
|
auto\-dnssec ( allow | maintain | off );
|
||||||
@@ -232,9 +231,9 @@ options {
|
|||||||
coresize ( default | unlimited | \fIsizeval\fR );
|
coresize ( default | unlimited | \fIsizeval\fR );
|
||||||
datasize ( default | unlimited | \fIsizeval\fR );
|
datasize ( default | unlimited | \fIsizeval\fR );
|
||||||
deny\-answer\-addresses { \fIaddress_match_element\fR; \&.\&.\&. } [
|
deny\-answer\-addresses { \fIaddress_match_element\fR; \&.\&.\&. } [
|
||||||
except\-from { \fIstring\fR; \&.\&.\&. } ];
|
except\-from { \fIquoted_string\fR; \&.\&.\&. } ];
|
||||||
deny\-answer\-aliases { \fIstring\fR; \&.\&.\&. } [ except\-from { \fIstring\fR; \&.\&.\&.
|
deny\-answer\-aliases { \fIquoted_string\fR; \&.\&.\&. } [ except\-from {
|
||||||
} ];
|
\fIquoted_string\fR; \&.\&.\&. } ];
|
||||||
dialup ( notify | notify\-passive | passive | refresh | \fIboolean\fR );
|
dialup ( notify | notify\-passive | passive | refresh | \fIboolean\fR );
|
||||||
directory \fIquoted_string\fR;
|
directory \fIquoted_string\fR;
|
||||||
disable\-algorithms \fIstring\fR { \fIstring\fR;
|
disable\-algorithms \fIstring\fR { \fIstring\fR;
|
||||||
@@ -265,12 +264,14 @@ options {
|
|||||||
dnssec\-secure\-to\-insecure \fIboolean\fR;
|
dnssec\-secure\-to\-insecure \fIboolean\fR;
|
||||||
dnssec\-update\-mode ( maintain | no\-resign );
|
dnssec\-update\-mode ( maintain | no\-resign );
|
||||||
dnssec\-validation ( yes | no | auto );
|
dnssec\-validation ( yes | no | auto );
|
||||||
dnstap { ( all | auth | client | forwarder | resolver | update ) [
|
dnstap { ( all | auth | client | forwarder |
|
||||||
( query | response ) ]; \&.\&.\&. };
|
resolver ) [ ( query | response ) ]; \&.\&.\&. };
|
||||||
dnstap\-identity ( \fIquoted_string\fR | none | hostname );
|
dnstap\-identity ( \fIquoted_string\fR | none |
|
||||||
dnstap\-output ( file | unix ) \fIquoted_string\fR [ size ( unlimited |
|
hostname );
|
||||||
\fIsize\fR ) ] [ versions ( unlimited | \fIinteger\fR ) ] [ suffix (
|
dnstap\-output ( file | unix ) \fIquoted_string\fR [
|
||||||
increment | timestamp ) ];
|
size ( unlimited | \fIsize\fR ) ] [ versions (
|
||||||
|
unlimited | \fIinteger\fR ) ] [ suffix ( increment
|
||||||
|
| timestamp ) ];
|
||||||
dnstap\-version ( \fIquoted_string\fR | none );
|
dnstap\-version ( \fIquoted_string\fR | none );
|
||||||
dscp \fIinteger\fR;
|
dscp \fIinteger\fR;
|
||||||
dual\-stack\-servers [ port \fIinteger\fR ] { ( \fIquoted_string\fR [ port
|
dual\-stack\-servers [ port \fIinteger\fR ] { ( \fIquoted_string\fR [ port
|
||||||
@@ -344,8 +345,6 @@ options {
|
|||||||
memstatistics \fIboolean\fR;
|
memstatistics \fIboolean\fR;
|
||||||
memstatistics\-file \fIquoted_string\fR;
|
memstatistics\-file \fIquoted_string\fR;
|
||||||
message\-compression \fIboolean\fR;
|
message\-compression \fIboolean\fR;
|
||||||
min\-cache\-ttl \fIttlval\fR;
|
|
||||||
min\-ncache\-ttl \fIttlval\fR;
|
|
||||||
min\-refresh\-time \fIinteger\fR;
|
min\-refresh\-time \fIinteger\fR;
|
||||||
min\-retry\-time \fIinteger\fR;
|
min\-retry\-time \fIinteger\fR;
|
||||||
minimal\-any \fIboolean\fR;
|
minimal\-any \fIboolean\fR;
|
||||||
@@ -370,7 +369,7 @@ options {
|
|||||||
preferred\-glue \fIstring\fR;
|
preferred\-glue \fIstring\fR;
|
||||||
prefetch \fIinteger\fR [ \fIinteger\fR ];
|
prefetch \fIinteger\fR [ \fIinteger\fR ];
|
||||||
provide\-ixfr \fIboolean\fR;
|
provide\-ixfr \fIboolean\fR;
|
||||||
qname\-minimization ( strict | relaxed | disabled | off );
|
qname\-minimization ( strict | relaxed | disabled );
|
||||||
query\-source ( ( [ address ] ( \fIipv4_address\fR | * ) [ port (
|
query\-source ( ( [ address ] ( \fIipv4_address\fR | * ) [ port (
|
||||||
\fIinteger\fR | * ) ] ) | ( [ [ address ] ( \fIipv4_address\fR | * ) ]
|
\fIinteger\fR | * ) ] ) | ( [ [ address ] ( \fIipv4_address\fR | * ) ]
|
||||||
port ( \fIinteger\fR | * ) ) ) [ dscp \fIinteger\fR ];
|
port ( \fIinteger\fR | * ) ) ) [ dscp \fIinteger\fR ];
|
||||||
@@ -421,7 +420,7 @@ options {
|
|||||||
nsip\-enable \fIboolean\fR ] [ nsdname\-enable \fIboolean\fR ] [
|
nsip\-enable \fIboolean\fR ] [ nsdname\-enable \fIboolean\fR ] [
|
||||||
dnsrps\-enable \fIboolean\fR ] [ dnsrps\-options { \fIunspecified\-text\fR
|
dnsrps\-enable \fIboolean\fR ] [ dnsrps\-options { \fIunspecified\-text\fR
|
||||||
} ];
|
} ];
|
||||||
root\-delegation\-only [ exclude { \fIstring\fR; \&.\&.\&. } ];
|
root\-delegation\-only [ exclude { \fIquoted_string\fR; \&.\&.\&. } ];
|
||||||
root\-key\-sentinel \fIboolean\fR;
|
root\-key\-sentinel \fIboolean\fR;
|
||||||
rrset\-order { [ class \fIstring\fR ] [ type \fIstring\fR ] [ name
|
rrset\-order { [ class \fIstring\fR ] [ type \fIstring\fR ] [ name
|
||||||
\fIquoted_string\fR ] \fIstring\fR \fIstring\fR; \&.\&.\&. };
|
\fIquoted_string\fR ] \fIstring\fR \fIstring\fR; \&.\&.\&. };
|
||||||
@@ -471,7 +470,6 @@ options {
|
|||||||
use\-v4\-udp\-ports { \fIportrange\fR; \&.\&.\&. };
|
use\-v4\-udp\-ports { \fIportrange\fR; \&.\&.\&. };
|
||||||
use\-v6\-udp\-ports { \fIportrange\fR; \&.\&.\&. };
|
use\-v6\-udp\-ports { \fIportrange\fR; \&.\&.\&. };
|
||||||
v6\-bias \fIinteger\fR;
|
v6\-bias \fIinteger\fR;
|
||||||
validate\-except { \fIstring\fR; \&.\&.\&. };
|
|
||||||
version ( \fIquoted_string\fR | none );
|
version ( \fIquoted_string\fR | none );
|
||||||
zero\-no\-soa\-ttl \fIboolean\fR;
|
zero\-no\-soa\-ttl \fIboolean\fR;
|
||||||
zero\-no\-soa\-ttl\-cache \fIboolean\fR;
|
zero\-no\-soa\-ttl\-cache \fIboolean\fR;
|
||||||
@@ -599,9 +597,9 @@ view \fIstring\fR [ \fIclass\fR ] {
|
|||||||
cleaning\-interval \fIinteger\fR;
|
cleaning\-interval \fIinteger\fR;
|
||||||
clients\-per\-query \fIinteger\fR;
|
clients\-per\-query \fIinteger\fR;
|
||||||
deny\-answer\-addresses { \fIaddress_match_element\fR; \&.\&.\&. } [
|
deny\-answer\-addresses { \fIaddress_match_element\fR; \&.\&.\&. } [
|
||||||
except\-from { \fIstring\fR; \&.\&.\&. } ];
|
except\-from { \fIquoted_string\fR; \&.\&.\&. } ];
|
||||||
deny\-answer\-aliases { \fIstring\fR; \&.\&.\&. } [ except\-from { \fIstring\fR; \&.\&.\&.
|
deny\-answer\-aliases { \fIquoted_string\fR; \&.\&.\&. } [ except\-from {
|
||||||
} ];
|
\fIquoted_string\fR; \&.\&.\&. } ];
|
||||||
dialup ( notify | notify\-passive | passive | refresh | \fIboolean\fR );
|
dialup ( notify | notify\-passive | passive | refresh | \fIboolean\fR );
|
||||||
disable\-algorithms \fIstring\fR { \fIstring\fR;
|
disable\-algorithms \fIstring\fR { \fIstring\fR;
|
||||||
\&.\&.\&. };
|
\&.\&.\&. };
|
||||||
@@ -635,8 +633,8 @@ view \fIstring\fR [ \fIclass\fR ] {
|
|||||||
dnssec\-secure\-to\-insecure \fIboolean\fR;
|
dnssec\-secure\-to\-insecure \fIboolean\fR;
|
||||||
dnssec\-update\-mode ( maintain | no\-resign );
|
dnssec\-update\-mode ( maintain | no\-resign );
|
||||||
dnssec\-validation ( yes | no | auto );
|
dnssec\-validation ( yes | no | auto );
|
||||||
dnstap { ( all | auth | client | forwarder | resolver | update ) [
|
dnstap { ( all | auth | client | forwarder |
|
||||||
( query | response ) ]; \&.\&.\&. };
|
resolver ) [ ( query | response ) ]; \&.\&.\&. };
|
||||||
dual\-stack\-servers [ port \fIinteger\fR ] { ( \fIquoted_string\fR [ port
|
dual\-stack\-servers [ port \fIinteger\fR ] { ( \fIquoted_string\fR [ port
|
||||||
\fIinteger\fR ] [ dscp \fIinteger\fR ] | \fIipv4_address\fR [ port
|
\fIinteger\fR ] [ dscp \fIinteger\fR ] | \fIipv4_address\fR [ port
|
||||||
\fIinteger\fR ] [ dscp \fIinteger\fR ] | \fIipv6_address\fR [ port
|
\fIinteger\fR ] [ dscp \fIinteger\fR ] | \fIipv6_address\fR [ port
|
||||||
@@ -714,7 +712,7 @@ view \fIstring\fR [ \fIclass\fR ] {
|
|||||||
preferred\-glue \fIstring\fR;
|
preferred\-glue \fIstring\fR;
|
||||||
prefetch \fIinteger\fR [ \fIinteger\fR ];
|
prefetch \fIinteger\fR [ \fIinteger\fR ];
|
||||||
provide\-ixfr \fIboolean\fR;
|
provide\-ixfr \fIboolean\fR;
|
||||||
qname\-minimization ( strict | relaxed | disabled | off );
|
qname\-minimization ( strict | relaxed | disabled );
|
||||||
query\-source ( ( [ address ] ( \fIipv4_address\fR | * ) [ port (
|
query\-source ( ( [ address ] ( \fIipv4_address\fR | * ) [ port (
|
||||||
\fIinteger\fR | * ) ] ) | ( [ [ address ] ( \fIipv4_address\fR | * ) ]
|
\fIinteger\fR | * ) ] ) | ( [ [ address ] ( \fIipv4_address\fR | * ) ]
|
||||||
port ( \fIinteger\fR | * ) ) ) [ dscp \fIinteger\fR ];
|
port ( \fIinteger\fR | * ) ) ) [ dscp \fIinteger\fR ];
|
||||||
@@ -760,7 +758,7 @@ view \fIstring\fR [ \fIclass\fR ] {
|
|||||||
nsip\-enable \fIboolean\fR ] [ nsdname\-enable \fIboolean\fR ] [
|
nsip\-enable \fIboolean\fR ] [ nsdname\-enable \fIboolean\fR ] [
|
||||||
dnsrps\-enable \fIboolean\fR ] [ dnsrps\-options { \fIunspecified\-text\fR
|
dnsrps\-enable \fIboolean\fR ] [ dnsrps\-options { \fIunspecified\-text\fR
|
||||||
} ];
|
} ];
|
||||||
root\-delegation\-only [ exclude { \fIstring\fR; \&.\&.\&. } ];
|
root\-delegation\-only [ exclude { \fIquoted_string\fR; \&.\&.\&. } ];
|
||||||
root\-key\-sentinel \fIboolean\fR;
|
root\-key\-sentinel \fIboolean\fR;
|
||||||
rrset\-order { [ class \fIstring\fR ] [ type \fIstring\fR ] [ name
|
rrset\-order { [ class \fIstring\fR ] [ type \fIstring\fR ] [ name
|
||||||
\fIquoted_string\fR ] \fIstring\fR \fIstring\fR; \&.\&.\&. };
|
\fIquoted_string\fR ] \fIstring\fR \fIstring\fR; \&.\&.\&. };
|
||||||
@@ -822,7 +820,6 @@ view \fIstring\fR [ \fIclass\fR ] {
|
|||||||
update\-check\-ksk \fIboolean\fR;
|
update\-check\-ksk \fIboolean\fR;
|
||||||
use\-alt\-transfer\-source \fIboolean\fR;
|
use\-alt\-transfer\-source \fIboolean\fR;
|
||||||
v6\-bias \fIinteger\fR;
|
v6\-bias \fIinteger\fR;
|
||||||
validate\-except { \fIstring\fR; \&.\&.\&. };
|
|
||||||
zero\-no\-soa\-ttl \fIboolean\fR;
|
zero\-no\-soa\-ttl \fIboolean\fR;
|
||||||
zero\-no\-soa\-ttl\-cache \fIboolean\fR;
|
zero\-no\-soa\-ttl\-cache \fIboolean\fR;
|
||||||
zone \fIstring\fR [ \fIclass\fR ] {
|
zone \fIstring\fR [ \fIclass\fR ] {
|
||||||
@@ -887,6 +884,7 @@ view \fIstring\fR [ \fIclass\fR ] {
|
|||||||
max\-zone\-ttl ( unlimited | \fIttlval\fR );
|
max\-zone\-ttl ( unlimited | \fIttlval\fR );
|
||||||
min\-refresh\-time \fIinteger\fR;
|
min\-refresh\-time \fIinteger\fR;
|
||||||
min\-retry\-time \fIinteger\fR;
|
min\-retry\-time \fIinteger\fR;
|
||||||
|
mirror \fIboolean\fR;
|
||||||
multi\-master \fIboolean\fR;
|
multi\-master \fIboolean\fR;
|
||||||
notify ( explicit | master\-only | \fIboolean\fR );
|
notify ( explicit | master\-only | \fIboolean\fR );
|
||||||
notify\-delay \fIinteger\fR;
|
notify\-delay \fIinteger\fR;
|
||||||
@@ -901,8 +899,9 @@ view \fIstring\fR [ \fIclass\fR ] {
|
|||||||
request\-expire \fIboolean\fR;
|
request\-expire \fIboolean\fR;
|
||||||
request\-ixfr \fIboolean\fR;
|
request\-ixfr \fIboolean\fR;
|
||||||
serial\-update\-method ( date | increment | unixtime );
|
serial\-update\-method ( date | increment | unixtime );
|
||||||
server\-addresses { ( \fIipv4_address\fR | \fIipv6_address\fR ); \&.\&.\&. };
|
server\-addresses { ( \fIipv4_address\fR | \fIipv6_address\fR ) [
|
||||||
server\-names { \fIstring\fR; \&.\&.\&. };
|
port \fIinteger\fR ]; \&.\&.\&. };
|
||||||
|
server\-names { \fIquoted_string\fR; \&.\&.\&. };
|
||||||
sig\-signing\-nodes \fIinteger\fR;
|
sig\-signing\-nodes \fIinteger\fR;
|
||||||
sig\-signing\-signatures \fIinteger\fR;
|
sig\-signing\-signatures \fIinteger\fR;
|
||||||
sig\-signing\-type \fIinteger\fR;
|
sig\-signing\-type \fIinteger\fR;
|
||||||
@@ -912,15 +911,15 @@ view \fIstring\fR [ \fIclass\fR ] {
|
|||||||
transfer\-source\-v6 ( \fIipv6_address\fR | * ) [ port (
|
transfer\-source\-v6 ( \fIipv6_address\fR | * ) [ port (
|
||||||
\fIinteger\fR | * ) ] [ dscp \fIinteger\fR ];
|
\fIinteger\fR | * ) ] [ dscp \fIinteger\fR ];
|
||||||
try\-tcp\-refresh \fIboolean\fR;
|
try\-tcp\-refresh \fIboolean\fR;
|
||||||
type ( primary | master | secondary | slave | mirror |
|
type ( primary | master | secondary | slave |
|
||||||
delegation\-only | forward | hint | redirect |
|
delegation\-only | forward | hint | redirect |
|
||||||
static\-stub | stub );
|
static\-stub | stub );
|
||||||
update\-check\-ksk \fIboolean\fR;
|
update\-check\-ksk \fIboolean\fR;
|
||||||
update\-policy ( local | { ( deny | grant ) \fIstring\fR (
|
update\-policy ( local | { ( deny | grant ) \fIstring\fR (
|
||||||
6to4\-self | external | krb5\-self | krb5\-selfsub |
|
6to4\-self | external | krb5\-self | krb5\-subdomain |
|
||||||
krb5\-subdomain | ms\-self | ms\-selfsub | ms\-subdomain |
|
ms\-self | ms\-subdomain | name | self | selfsub |
|
||||||
name | self | selfsub | selfwild | subdomain | tcp\-self
|
selfwild | subdomain | tcp\-self | wildcard | zonesub )
|
||||||
| wildcard | zonesub ) [ \fIstring\fR ] \fIrrtypelist\fR; \&.\&.\&. };
|
[ \fIstring\fR ] \fIrrtypelist\fR; \&.\&.\&. };
|
||||||
use\-alt\-transfer\-source \fIboolean\fR;
|
use\-alt\-transfer\-source \fIboolean\fR;
|
||||||
zero\-no\-soa\-ttl \fIboolean\fR;
|
zero\-no\-soa\-ttl \fIboolean\fR;
|
||||||
zone\-statistics ( full | terse | none | \fIboolean\fR );
|
zone\-statistics ( full | terse | none | \fIboolean\fR );
|
||||||
@@ -995,6 +994,7 @@ zone \fIstring\fR [ \fIclass\fR ] {
|
|||||||
max\-zone\-ttl ( unlimited | \fIttlval\fR );
|
max\-zone\-ttl ( unlimited | \fIttlval\fR );
|
||||||
min\-refresh\-time \fIinteger\fR;
|
min\-refresh\-time \fIinteger\fR;
|
||||||
min\-retry\-time \fIinteger\fR;
|
min\-retry\-time \fIinteger\fR;
|
||||||
|
mirror \fIboolean\fR;
|
||||||
multi\-master \fIboolean\fR;
|
multi\-master \fIboolean\fR;
|
||||||
notify ( explicit | master\-only | \fIboolean\fR );
|
notify ( explicit | master\-only | \fIboolean\fR );
|
||||||
notify\-delay \fIinteger\fR;
|
notify\-delay \fIinteger\fR;
|
||||||
@@ -1007,8 +1007,9 @@ zone \fIstring\fR [ \fIclass\fR ] {
|
|||||||
request\-expire \fIboolean\fR;
|
request\-expire \fIboolean\fR;
|
||||||
request\-ixfr \fIboolean\fR;
|
request\-ixfr \fIboolean\fR;
|
||||||
serial\-update\-method ( date | increment | unixtime );
|
serial\-update\-method ( date | increment | unixtime );
|
||||||
server\-addresses { ( \fIipv4_address\fR | \fIipv6_address\fR ); \&.\&.\&. };
|
server\-addresses { ( \fIipv4_address\fR | \fIipv6_address\fR ) [ port
|
||||||
server\-names { \fIstring\fR; \&.\&.\&. };
|
\fIinteger\fR ]; \&.\&.\&. };
|
||||||
|
server\-names { \fIquoted_string\fR; \&.\&.\&. };
|
||||||
sig\-signing\-nodes \fIinteger\fR;
|
sig\-signing\-nodes \fIinteger\fR;
|
||||||
sig\-signing\-signatures \fIinteger\fR;
|
sig\-signing\-signatures \fIinteger\fR;
|
||||||
sig\-signing\-type \fIinteger\fR;
|
sig\-signing\-type \fIinteger\fR;
|
||||||
@@ -1018,15 +1019,13 @@ zone \fIstring\fR [ \fIclass\fR ] {
|
|||||||
transfer\-source\-v6 ( \fIipv6_address\fR | * ) [ port ( \fIinteger\fR | * )
|
transfer\-source\-v6 ( \fIipv6_address\fR | * ) [ port ( \fIinteger\fR | * )
|
||||||
] [ dscp \fIinteger\fR ];
|
] [ dscp \fIinteger\fR ];
|
||||||
try\-tcp\-refresh \fIboolean\fR;
|
try\-tcp\-refresh \fIboolean\fR;
|
||||||
type ( primary | master | secondary | slave | mirror |
|
type ( primary | master | secondary | slave | delegation\-only |
|
||||||
delegation\-only | forward | hint | redirect | static\-stub |
|
forward | hint | redirect | static\-stub | stub );
|
||||||
stub );
|
|
||||||
update\-check\-ksk \fIboolean\fR;
|
update\-check\-ksk \fIboolean\fR;
|
||||||
update\-policy ( local | { ( deny | grant ) \fIstring\fR ( 6to4\-self |
|
update\-policy ( local | { ( deny | grant ) \fIstring\fR ( 6to4\-self |
|
||||||
external | krb5\-self | krb5\-selfsub | krb5\-subdomain | ms\-self
|
external | krb5\-self | krb5\-subdomain | ms\-self | ms\-subdomain
|
||||||
| ms\-selfsub | ms\-subdomain | name | self | selfsub | selfwild
|
| name | self | selfsub | selfwild | subdomain | tcp\-self |
|
||||||
| subdomain | tcp\-self | wildcard | zonesub ) [ \fIstring\fR ]
|
wildcard | zonesub ) [ \fIstring\fR ] \fIrrtypelist\fR; \&.\&.\&. };
|
||||||
\fIrrtypelist\fR; \&.\&.\&. };
|
|
||||||
use\-alt\-transfer\-source \fIboolean\fR;
|
use\-alt\-transfer\-source \fIboolean\fR;
|
||||||
zero\-no\-soa\-ttl \fIboolean\fR;
|
zero\-no\-soa\-ttl \fIboolean\fR;
|
||||||
zone\-statistics ( full | terse | none | \fIboolean\fR );
|
zone\-statistics ( full | terse | none | \fIboolean\fR );
|
||||||
|
|||||||
@@ -13,7 +13,7 @@
|
|||||||
|
|
||||||
<refentry xmlns:db="http://docbook.org/ns/docbook" version="5.0" xml:id="man.named.conf">
|
<refentry xmlns:db="http://docbook.org/ns/docbook" version="5.0" xml:id="man.named.conf">
|
||||||
<info>
|
<info>
|
||||||
<date>2018-10-23</date>
|
<date>2018-06-21</date>
|
||||||
</info>
|
</info>
|
||||||
<refentryinfo>
|
<refentryinfo>
|
||||||
<corpname>ISC</corpname>
|
<corpname>ISC</corpname>
|
||||||
@@ -192,7 +192,6 @@ options {
|
|||||||
] [ dscp <replaceable>integer</replaceable> ];
|
] [ dscp <replaceable>integer</replaceable> ];
|
||||||
alt-transfer-source-v6 ( <replaceable>ipv6_address</replaceable> | * ) [ port ( <replaceable>integer</replaceable> |
|
alt-transfer-source-v6 ( <replaceable>ipv6_address</replaceable> | * ) [ port ( <replaceable>integer</replaceable> |
|
||||||
* ) ] [ dscp <replaceable>integer</replaceable> ];
|
* ) ] [ dscp <replaceable>integer</replaceable> ];
|
||||||
answer-cookie <replaceable>boolean</replaceable>;
|
|
||||||
attach-cache <replaceable>string</replaceable>;
|
attach-cache <replaceable>string</replaceable>;
|
||||||
auth-nxdomain <replaceable>boolean</replaceable>; // default changed
|
auth-nxdomain <replaceable>boolean</replaceable>; // default changed
|
||||||
auto-dnssec ( allow | maintain | off );
|
auto-dnssec ( allow | maintain | off );
|
||||||
@@ -258,8 +257,8 @@ options {
|
|||||||
dnssec-secure-to-insecure <replaceable>boolean</replaceable>;
|
dnssec-secure-to-insecure <replaceable>boolean</replaceable>;
|
||||||
dnssec-update-mode ( maintain | no-resign );
|
dnssec-update-mode ( maintain | no-resign );
|
||||||
dnssec-validation ( yes | no | auto );
|
dnssec-validation ( yes | no | auto );
|
||||||
dnstap { ( all | auth | client | forwarder | resolver | update ) [
|
dnstap { ( all | auth | client | forwarder | resolver ) [ ( query |
|
||||||
( query | response ) ]; ... };
|
response ) ]; ... };
|
||||||
dnstap-identity ( <replaceable>quoted_string</replaceable> | none | hostname );
|
dnstap-identity ( <replaceable>quoted_string</replaceable> | none | hostname );
|
||||||
dnstap-output ( file | unix ) <replaceable>quoted_string</replaceable> [ size ( unlimited |
|
dnstap-output ( file | unix ) <replaceable>quoted_string</replaceable> [ size ( unlimited |
|
||||||
<replaceable>size</replaceable> ) ] [ versions ( unlimited | <replaceable>integer</replaceable> ) ] [ suffix (
|
<replaceable>size</replaceable> ) ] [ versions ( unlimited | <replaceable>integer</replaceable> ) ] [ suffix (
|
||||||
@@ -337,8 +336,6 @@ options {
|
|||||||
memstatistics <replaceable>boolean</replaceable>;
|
memstatistics <replaceable>boolean</replaceable>;
|
||||||
memstatistics-file <replaceable>quoted_string</replaceable>;
|
memstatistics-file <replaceable>quoted_string</replaceable>;
|
||||||
message-compression <replaceable>boolean</replaceable>;
|
message-compression <replaceable>boolean</replaceable>;
|
||||||
min-cache-ttl <replaceable>ttlval</replaceable>;
|
|
||||||
min-ncache-ttl <replaceable>ttlval</replaceable>;
|
|
||||||
min-refresh-time <replaceable>integer</replaceable>;
|
min-refresh-time <replaceable>integer</replaceable>;
|
||||||
min-retry-time <replaceable>integer</replaceable>;
|
min-retry-time <replaceable>integer</replaceable>;
|
||||||
minimal-any <replaceable>boolean</replaceable>;
|
minimal-any <replaceable>boolean</replaceable>;
|
||||||
@@ -612,8 +609,8 @@ view <replaceable>string</replaceable> [ <replaceable>class</replaceable> ] {
|
|||||||
dnssec-secure-to-insecure <replaceable>boolean</replaceable>;
|
dnssec-secure-to-insecure <replaceable>boolean</replaceable>;
|
||||||
dnssec-update-mode ( maintain | no-resign );
|
dnssec-update-mode ( maintain | no-resign );
|
||||||
dnssec-validation ( yes | no | auto );
|
dnssec-validation ( yes | no | auto );
|
||||||
dnstap { ( all | auth | client | forwarder | resolver | update ) [
|
dnstap { ( all | auth | client | forwarder | resolver ) [ ( query |
|
||||||
( query | response ) ]; ... };
|
response ) ]; ... };
|
||||||
dual-stack-servers [ port <replaceable>integer</replaceable> ] { ( <replaceable>quoted_string</replaceable> [ port
|
dual-stack-servers [ port <replaceable>integer</replaceable> ] { ( <replaceable>quoted_string</replaceable> [ port
|
||||||
<replaceable>integer</replaceable> ] [ dscp <replaceable>integer</replaceable> ] | <replaceable>ipv4_address</replaceable> [ port
|
<replaceable>integer</replaceable> ] [ dscp <replaceable>integer</replaceable> ] | <replaceable>ipv4_address</replaceable> [ port
|
||||||
<replaceable>integer</replaceable> ] [ dscp <replaceable>integer</replaceable> ] | <replaceable>ipv6_address</replaceable> [ port
|
<replaceable>integer</replaceable> ] [ dscp <replaceable>integer</replaceable> ] | <replaceable>ipv6_address</replaceable> [ port
|
||||||
@@ -864,6 +861,7 @@ view <replaceable>string</replaceable> [ <replaceable>class</replaceable> ] {
|
|||||||
max-zone-ttl ( unlimited | <replaceable>ttlval</replaceable> );
|
max-zone-ttl ( unlimited | <replaceable>ttlval</replaceable> );
|
||||||
min-refresh-time <replaceable>integer</replaceable>;
|
min-refresh-time <replaceable>integer</replaceable>;
|
||||||
min-retry-time <replaceable>integer</replaceable>;
|
min-retry-time <replaceable>integer</replaceable>;
|
||||||
|
mirror <replaceable>boolean</replaceable>;
|
||||||
multi-master <replaceable>boolean</replaceable>;
|
multi-master <replaceable>boolean</replaceable>;
|
||||||
notify ( explicit | master-only | <replaceable>boolean</replaceable> );
|
notify ( explicit | master-only | <replaceable>boolean</replaceable> );
|
||||||
notify-delay <replaceable>integer</replaceable>;
|
notify-delay <replaceable>integer</replaceable>;
|
||||||
@@ -878,7 +876,8 @@ view <replaceable>string</replaceable> [ <replaceable>class</replaceable> ] {
|
|||||||
request-expire <replaceable>boolean</replaceable>;
|
request-expire <replaceable>boolean</replaceable>;
|
||||||
request-ixfr <replaceable>boolean</replaceable>;
|
request-ixfr <replaceable>boolean</replaceable>;
|
||||||
serial-update-method ( date | increment | unixtime );
|
serial-update-method ( date | increment | unixtime );
|
||||||
server-addresses { ( <replaceable>ipv4_address</replaceable> | <replaceable>ipv6_address</replaceable> ); ... };
|
server-addresses { ( <replaceable>ipv4_address</replaceable> | <replaceable>ipv6_address</replaceable> ) [
|
||||||
|
port <replaceable>integer</replaceable> ]; ... };
|
||||||
server-names { <replaceable>string</replaceable>; ... };
|
server-names { <replaceable>string</replaceable>; ... };
|
||||||
sig-signing-nodes <replaceable>integer</replaceable>;
|
sig-signing-nodes <replaceable>integer</replaceable>;
|
||||||
sig-signing-signatures <replaceable>integer</replaceable>;
|
sig-signing-signatures <replaceable>integer</replaceable>;
|
||||||
@@ -889,15 +888,15 @@ view <replaceable>string</replaceable> [ <replaceable>class</replaceable> ] {
|
|||||||
transfer-source-v6 ( <replaceable>ipv6_address</replaceable> | * ) [ port (
|
transfer-source-v6 ( <replaceable>ipv6_address</replaceable> | * ) [ port (
|
||||||
<replaceable>integer</replaceable> | * ) ] [ dscp <replaceable>integer</replaceable> ];
|
<replaceable>integer</replaceable> | * ) ] [ dscp <replaceable>integer</replaceable> ];
|
||||||
try-tcp-refresh <replaceable>boolean</replaceable>;
|
try-tcp-refresh <replaceable>boolean</replaceable>;
|
||||||
type ( primary | master | secondary | slave | mirror |
|
type ( primary | master | secondary | slave |
|
||||||
delegation-only | forward | hint | redirect |
|
delegation-only | forward | hint | redirect |
|
||||||
static-stub | stub );
|
static-stub | stub );
|
||||||
update-check-ksk <replaceable>boolean</replaceable>;
|
update-check-ksk <replaceable>boolean</replaceable>;
|
||||||
update-policy ( local | { ( deny | grant ) <replaceable>string</replaceable> (
|
update-policy ( local | { ( deny | grant ) <replaceable>string</replaceable> (
|
||||||
6to4-self | external | krb5-self | krb5-selfsub |
|
6to4-self | external | krb5-self | krb5-subdomain |
|
||||||
krb5-subdomain | ms-self | ms-selfsub | ms-subdomain |
|
ms-self | ms-subdomain | name | self | selfsub |
|
||||||
name | self | selfsub | selfwild | subdomain | tcp-self
|
selfwild | subdomain | tcp-self | wildcard | zonesub )
|
||||||
| wildcard | zonesub ) [ <replaceable>string</replaceable> ] <replaceable>rrtypelist</replaceable>; ... };
|
[ <replaceable>string</replaceable> ] <replaceable>rrtypelist</replaceable>; ... };
|
||||||
use-alt-transfer-source <replaceable>boolean</replaceable>;
|
use-alt-transfer-source <replaceable>boolean</replaceable>;
|
||||||
zero-no-soa-ttl <replaceable>boolean</replaceable>;
|
zero-no-soa-ttl <replaceable>boolean</replaceable>;
|
||||||
zone-statistics ( full | terse | none | <replaceable>boolean</replaceable> );
|
zone-statistics ( full | terse | none | <replaceable>boolean</replaceable> );
|
||||||
@@ -968,6 +967,7 @@ zone <replaceable>string</replaceable> [ <replaceable>class</replaceable> ] {
|
|||||||
max-zone-ttl ( unlimited | <replaceable>ttlval</replaceable> );
|
max-zone-ttl ( unlimited | <replaceable>ttlval</replaceable> );
|
||||||
min-refresh-time <replaceable>integer</replaceable>;
|
min-refresh-time <replaceable>integer</replaceable>;
|
||||||
min-retry-time <replaceable>integer</replaceable>;
|
min-retry-time <replaceable>integer</replaceable>;
|
||||||
|
mirror <replaceable>boolean</replaceable>;
|
||||||
multi-master <replaceable>boolean</replaceable>;
|
multi-master <replaceable>boolean</replaceable>;
|
||||||
notify ( explicit | master-only | <replaceable>boolean</replaceable> );
|
notify ( explicit | master-only | <replaceable>boolean</replaceable> );
|
||||||
notify-delay <replaceable>integer</replaceable>;
|
notify-delay <replaceable>integer</replaceable>;
|
||||||
@@ -980,7 +980,8 @@ zone <replaceable>string</replaceable> [ <replaceable>class</replaceable> ] {
|
|||||||
request-expire <replaceable>boolean</replaceable>;
|
request-expire <replaceable>boolean</replaceable>;
|
||||||
request-ixfr <replaceable>boolean</replaceable>;
|
request-ixfr <replaceable>boolean</replaceable>;
|
||||||
serial-update-method ( date | increment | unixtime );
|
serial-update-method ( date | increment | unixtime );
|
||||||
server-addresses { ( <replaceable>ipv4_address</replaceable> | <replaceable>ipv6_address</replaceable> ); ... };
|
server-addresses { ( <replaceable>ipv4_address</replaceable> | <replaceable>ipv6_address</replaceable> ) [ port
|
||||||
|
<replaceable>integer</replaceable> ]; ... };
|
||||||
server-names { <replaceable>string</replaceable>; ... };
|
server-names { <replaceable>string</replaceable>; ... };
|
||||||
sig-signing-nodes <replaceable>integer</replaceable>;
|
sig-signing-nodes <replaceable>integer</replaceable>;
|
||||||
sig-signing-signatures <replaceable>integer</replaceable>;
|
sig-signing-signatures <replaceable>integer</replaceable>;
|
||||||
@@ -991,15 +992,13 @@ zone <replaceable>string</replaceable> [ <replaceable>class</replaceable> ] {
|
|||||||
transfer-source-v6 ( <replaceable>ipv6_address</replaceable> | * ) [ port ( <replaceable>integer</replaceable> | * )
|
transfer-source-v6 ( <replaceable>ipv6_address</replaceable> | * ) [ port ( <replaceable>integer</replaceable> | * )
|
||||||
] [ dscp <replaceable>integer</replaceable> ];
|
] [ dscp <replaceable>integer</replaceable> ];
|
||||||
try-tcp-refresh <replaceable>boolean</replaceable>;
|
try-tcp-refresh <replaceable>boolean</replaceable>;
|
||||||
type ( primary | master | secondary | slave | mirror |
|
type ( primary | master | secondary | slave | delegation-only |
|
||||||
delegation-only | forward | hint | redirect | static-stub |
|
forward | hint | redirect | static-stub | stub );
|
||||||
stub );
|
|
||||||
update-check-ksk <replaceable>boolean</replaceable>;
|
update-check-ksk <replaceable>boolean</replaceable>;
|
||||||
update-policy ( local | { ( deny | grant ) <replaceable>string</replaceable> ( 6to4-self |
|
update-policy ( local | { ( deny | grant ) <replaceable>string</replaceable> ( 6to4-self |
|
||||||
external | krb5-self | krb5-selfsub | krb5-subdomain | ms-self
|
external | krb5-self | krb5-subdomain | ms-self | ms-subdomain
|
||||||
| ms-selfsub | ms-subdomain | name | self | selfsub | selfwild
|
| name | self | selfsub | selfwild | subdomain | tcp-self |
|
||||||
| subdomain | tcp-self | wildcard | zonesub ) [ <replaceable>string</replaceable> ]
|
wildcard | zonesub ) [ <replaceable>string</replaceable> ] <replaceable>rrtypelist</replaceable>; ... };
|
||||||
<replaceable>rrtypelist</replaceable>; ... };
|
|
||||||
use-alt-transfer-source <replaceable>boolean</replaceable>;
|
use-alt-transfer-source <replaceable>boolean</replaceable>;
|
||||||
zero-no-soa-ttl <replaceable>boolean</replaceable>;
|
zero-no-soa-ttl <replaceable>boolean</replaceable>;
|
||||||
zone-statistics ( full | terse | none | <replaceable>boolean</replaceable> );
|
zone-statistics ( full | terse | none | <replaceable>boolean</replaceable> );
|
||||||
|
|||||||
+38
-39
@@ -180,7 +180,6 @@ options
|
|||||||
] [ dscp <em class="replaceable"><code>integer</code></em> ];<br>
|
] [ dscp <em class="replaceable"><code>integer</code></em> ];<br>
|
||||||
alt-transfer-source-v6 ( <em class="replaceable"><code>ipv6_address</code></em> | * ) [ port ( <em class="replaceable"><code>integer</code></em> |<br>
|
alt-transfer-source-v6 ( <em class="replaceable"><code>ipv6_address</code></em> | * ) [ port ( <em class="replaceable"><code>integer</code></em> |<br>
|
||||||
* ) ] [ dscp <em class="replaceable"><code>integer</code></em> ];<br>
|
* ) ] [ dscp <em class="replaceable"><code>integer</code></em> ];<br>
|
||||||
answer-cookie <em class="replaceable"><code>boolean</code></em>;<br>
|
|
||||||
attach-cache <em class="replaceable"><code>string</code></em>;<br>
|
attach-cache <em class="replaceable"><code>string</code></em>;<br>
|
||||||
auth-nxdomain <em class="replaceable"><code>boolean</code></em>; // default changed<br>
|
auth-nxdomain <em class="replaceable"><code>boolean</code></em>; // default changed<br>
|
||||||
auto-dnssec ( allow | maintain | off );<br>
|
auto-dnssec ( allow | maintain | off );<br>
|
||||||
@@ -213,9 +212,9 @@ options
|
|||||||
coresize ( default | unlimited | <em class="replaceable"><code>sizeval</code></em> );<br>
|
coresize ( default | unlimited | <em class="replaceable"><code>sizeval</code></em> );<br>
|
||||||
datasize ( default | unlimited | <em class="replaceable"><code>sizeval</code></em> );<br>
|
datasize ( default | unlimited | <em class="replaceable"><code>sizeval</code></em> );<br>
|
||||||
deny-answer-addresses { <em class="replaceable"><code>address_match_element</code></em>; ... } [<br>
|
deny-answer-addresses { <em class="replaceable"><code>address_match_element</code></em>; ... } [<br>
|
||||||
except-from { <em class="replaceable"><code>string</code></em>; ... } ];<br>
|
except-from { <em class="replaceable"><code>quoted_string</code></em>; ... } ];<br>
|
||||||
deny-answer-aliases { <em class="replaceable"><code>string</code></em>; ... } [ except-from { <em class="replaceable"><code>string</code></em>; ...<br>
|
deny-answer-aliases { <em class="replaceable"><code>quoted_string</code></em>; ... } [ except-from {<br>
|
||||||
} ];<br>
|
<em class="replaceable"><code>quoted_string</code></em>; ... } ];<br>
|
||||||
dialup ( notify | notify-passive | passive | refresh | <em class="replaceable"><code>boolean</code></em> );<br>
|
dialup ( notify | notify-passive | passive | refresh | <em class="replaceable"><code>boolean</code></em> );<br>
|
||||||
directory <em class="replaceable"><code>quoted_string</code></em>;<br>
|
directory <em class="replaceable"><code>quoted_string</code></em>;<br>
|
||||||
disable-algorithms <em class="replaceable"><code>string</code></em> { <em class="replaceable"><code>string</code></em>;<br>
|
disable-algorithms <em class="replaceable"><code>string</code></em> { <em class="replaceable"><code>string</code></em>;<br>
|
||||||
@@ -246,12 +245,14 @@ options
|
|||||||
dnssec-secure-to-insecure <em class="replaceable"><code>boolean</code></em>;<br>
|
dnssec-secure-to-insecure <em class="replaceable"><code>boolean</code></em>;<br>
|
||||||
dnssec-update-mode ( maintain | no-resign );<br>
|
dnssec-update-mode ( maintain | no-resign );<br>
|
||||||
dnssec-validation ( yes | no | auto );<br>
|
dnssec-validation ( yes | no | auto );<br>
|
||||||
dnstap { ( all | auth | client | forwarder | resolver | update ) [<br>
|
dnstap { ( all | auth | client | forwarder |<br>
|
||||||
( query | response ) ]; ... };<br>
|
resolver ) [ ( query | response ) ]; ... };<br>
|
||||||
dnstap-identity ( <em class="replaceable"><code>quoted_string</code></em> | none | hostname );<br>
|
dnstap-identity ( <em class="replaceable"><code>quoted_string</code></em> | none |<br>
|
||||||
dnstap-output ( file | unix ) <em class="replaceable"><code>quoted_string</code></em> [ size ( unlimited |<br>
|
hostname );<br>
|
||||||
<em class="replaceable"><code>size</code></em> ) ] [ versions ( unlimited | <em class="replaceable"><code>integer</code></em> ) ] [ suffix (<br>
|
dnstap-output ( file | unix ) <em class="replaceable"><code>quoted_string</code></em> [<br>
|
||||||
increment | timestamp ) ];<br>
|
size ( unlimited | <em class="replaceable"><code>size</code></em> ) ] [ versions (<br>
|
||||||
|
unlimited | <em class="replaceable"><code>integer</code></em> ) ] [ suffix ( increment<br>
|
||||||
|
| timestamp ) ];<br>
|
||||||
dnstap-version ( <em class="replaceable"><code>quoted_string</code></em> | none );<br>
|
dnstap-version ( <em class="replaceable"><code>quoted_string</code></em> | none );<br>
|
||||||
dscp <em class="replaceable"><code>integer</code></em>;<br>
|
dscp <em class="replaceable"><code>integer</code></em>;<br>
|
||||||
dual-stack-servers [ port <em class="replaceable"><code>integer</code></em> ] { ( <em class="replaceable"><code>quoted_string</code></em> [ port<br>
|
dual-stack-servers [ port <em class="replaceable"><code>integer</code></em> ] { ( <em class="replaceable"><code>quoted_string</code></em> [ port<br>
|
||||||
@@ -325,8 +326,6 @@ options
|
|||||||
memstatistics <em class="replaceable"><code>boolean</code></em>;<br>
|
memstatistics <em class="replaceable"><code>boolean</code></em>;<br>
|
||||||
memstatistics-file <em class="replaceable"><code>quoted_string</code></em>;<br>
|
memstatistics-file <em class="replaceable"><code>quoted_string</code></em>;<br>
|
||||||
message-compression <em class="replaceable"><code>boolean</code></em>;<br>
|
message-compression <em class="replaceable"><code>boolean</code></em>;<br>
|
||||||
min-cache-ttl <em class="replaceable"><code>ttlval</code></em>;<br>
|
|
||||||
min-ncache-ttl <em class="replaceable"><code>ttlval</code></em>;<br>
|
|
||||||
min-refresh-time <em class="replaceable"><code>integer</code></em>;<br>
|
min-refresh-time <em class="replaceable"><code>integer</code></em>;<br>
|
||||||
min-retry-time <em class="replaceable"><code>integer</code></em>;<br>
|
min-retry-time <em class="replaceable"><code>integer</code></em>;<br>
|
||||||
minimal-any <em class="replaceable"><code>boolean</code></em>;<br>
|
minimal-any <em class="replaceable"><code>boolean</code></em>;<br>
|
||||||
@@ -351,7 +350,7 @@ options
|
|||||||
preferred-glue <em class="replaceable"><code>string</code></em>;<br>
|
preferred-glue <em class="replaceable"><code>string</code></em>;<br>
|
||||||
prefetch <em class="replaceable"><code>integer</code></em> [ <em class="replaceable"><code>integer</code></em> ];<br>
|
prefetch <em class="replaceable"><code>integer</code></em> [ <em class="replaceable"><code>integer</code></em> ];<br>
|
||||||
provide-ixfr <em class="replaceable"><code>boolean</code></em>;<br>
|
provide-ixfr <em class="replaceable"><code>boolean</code></em>;<br>
|
||||||
qname-minimization ( strict | relaxed | disabled | off );<br>
|
qname-minimization ( strict | relaxed | disabled );<br>
|
||||||
query-source ( ( [ address ] ( <em class="replaceable"><code>ipv4_address</code></em> | * ) [ port (<br>
|
query-source ( ( [ address ] ( <em class="replaceable"><code>ipv4_address</code></em> | * ) [ port (<br>
|
||||||
<em class="replaceable"><code>integer</code></em> | * ) ] ) | ( [ [ address ] ( <em class="replaceable"><code>ipv4_address</code></em> | * ) ]<br>
|
<em class="replaceable"><code>integer</code></em> | * ) ] ) | ( [ [ address ] ( <em class="replaceable"><code>ipv4_address</code></em> | * ) ]<br>
|
||||||
port ( <em class="replaceable"><code>integer</code></em> | * ) ) ) [ dscp <em class="replaceable"><code>integer</code></em> ];<br>
|
port ( <em class="replaceable"><code>integer</code></em> | * ) ) ) [ dscp <em class="replaceable"><code>integer</code></em> ];<br>
|
||||||
@@ -402,7 +401,7 @@ options
|
|||||||
nsip-enable <em class="replaceable"><code>boolean</code></em> ] [ nsdname-enable <em class="replaceable"><code>boolean</code></em> ] [<br>
|
nsip-enable <em class="replaceable"><code>boolean</code></em> ] [ nsdname-enable <em class="replaceable"><code>boolean</code></em> ] [<br>
|
||||||
dnsrps-enable <em class="replaceable"><code>boolean</code></em> ] [ dnsrps-options { <em class="replaceable"><code>unspecified-text</code></em><br>
|
dnsrps-enable <em class="replaceable"><code>boolean</code></em> ] [ dnsrps-options { <em class="replaceable"><code>unspecified-text</code></em><br>
|
||||||
} ];<br>
|
} ];<br>
|
||||||
root-delegation-only [ exclude { <em class="replaceable"><code>string</code></em>; ... } ];<br>
|
root-delegation-only [ exclude { <em class="replaceable"><code>quoted_string</code></em>; ... } ];<br>
|
||||||
root-key-sentinel <em class="replaceable"><code>boolean</code></em>;<br>
|
root-key-sentinel <em class="replaceable"><code>boolean</code></em>;<br>
|
||||||
rrset-order { [ class <em class="replaceable"><code>string</code></em> ] [ type <em class="replaceable"><code>string</code></em> ] [ name<br>
|
rrset-order { [ class <em class="replaceable"><code>string</code></em> ] [ type <em class="replaceable"><code>string</code></em> ] [ name<br>
|
||||||
<em class="replaceable"><code>quoted_string</code></em> ] <em class="replaceable"><code>string</code></em> <em class="replaceable"><code>string</code></em>; ... };<br>
|
<em class="replaceable"><code>quoted_string</code></em> ] <em class="replaceable"><code>string</code></em> <em class="replaceable"><code>string</code></em>; ... };<br>
|
||||||
@@ -452,7 +451,6 @@ options
|
|||||||
use-v4-udp-ports { <em class="replaceable"><code>portrange</code></em>; ... };<br>
|
use-v4-udp-ports { <em class="replaceable"><code>portrange</code></em>; ... };<br>
|
||||||
use-v6-udp-ports { <em class="replaceable"><code>portrange</code></em>; ... };<br>
|
use-v6-udp-ports { <em class="replaceable"><code>portrange</code></em>; ... };<br>
|
||||||
v6-bias <em class="replaceable"><code>integer</code></em>;<br>
|
v6-bias <em class="replaceable"><code>integer</code></em>;<br>
|
||||||
validate-except { <em class="replaceable"><code>string</code></em>; ... };<br>
|
|
||||||
version ( <em class="replaceable"><code>quoted_string</code></em> | none );<br>
|
version ( <em class="replaceable"><code>quoted_string</code></em> | none );<br>
|
||||||
zero-no-soa-ttl <em class="replaceable"><code>boolean</code></em>;<br>
|
zero-no-soa-ttl <em class="replaceable"><code>boolean</code></em>;<br>
|
||||||
zero-no-soa-ttl-cache <em class="replaceable"><code>boolean</code></em>;<br>
|
zero-no-soa-ttl-cache <em class="replaceable"><code>boolean</code></em>;<br>
|
||||||
@@ -568,9 +566,9 @@ view
|
|||||||
cleaning-interval <em class="replaceable"><code>integer</code></em>;<br>
|
cleaning-interval <em class="replaceable"><code>integer</code></em>;<br>
|
||||||
clients-per-query <em class="replaceable"><code>integer</code></em>;<br>
|
clients-per-query <em class="replaceable"><code>integer</code></em>;<br>
|
||||||
deny-answer-addresses { <em class="replaceable"><code>address_match_element</code></em>; ... } [<br>
|
deny-answer-addresses { <em class="replaceable"><code>address_match_element</code></em>; ... } [<br>
|
||||||
except-from { <em class="replaceable"><code>string</code></em>; ... } ];<br>
|
except-from { <em class="replaceable"><code>quoted_string</code></em>; ... } ];<br>
|
||||||
deny-answer-aliases { <em class="replaceable"><code>string</code></em>; ... } [ except-from { <em class="replaceable"><code>string</code></em>; ...<br>
|
deny-answer-aliases { <em class="replaceable"><code>quoted_string</code></em>; ... } [ except-from {<br>
|
||||||
} ];<br>
|
<em class="replaceable"><code>quoted_string</code></em>; ... } ];<br>
|
||||||
dialup ( notify | notify-passive | passive | refresh | <em class="replaceable"><code>boolean</code></em> );<br>
|
dialup ( notify | notify-passive | passive | refresh | <em class="replaceable"><code>boolean</code></em> );<br>
|
||||||
disable-algorithms <em class="replaceable"><code>string</code></em> { <em class="replaceable"><code>string</code></em>;<br>
|
disable-algorithms <em class="replaceable"><code>string</code></em> { <em class="replaceable"><code>string</code></em>;<br>
|
||||||
... };<br>
|
... };<br>
|
||||||
@@ -604,8 +602,8 @@ view
|
|||||||
dnssec-secure-to-insecure <em class="replaceable"><code>boolean</code></em>;<br>
|
dnssec-secure-to-insecure <em class="replaceable"><code>boolean</code></em>;<br>
|
||||||
dnssec-update-mode ( maintain | no-resign );<br>
|
dnssec-update-mode ( maintain | no-resign );<br>
|
||||||
dnssec-validation ( yes | no | auto );<br>
|
dnssec-validation ( yes | no | auto );<br>
|
||||||
dnstap { ( all | auth | client | forwarder | resolver | update ) [<br>
|
dnstap { ( all | auth | client | forwarder |<br>
|
||||||
( query | response ) ]; ... };<br>
|
resolver ) [ ( query | response ) ]; ... };<br>
|
||||||
dual-stack-servers [ port <em class="replaceable"><code>integer</code></em> ] { ( <em class="replaceable"><code>quoted_string</code></em> [ port<br>
|
dual-stack-servers [ port <em class="replaceable"><code>integer</code></em> ] { ( <em class="replaceable"><code>quoted_string</code></em> [ port<br>
|
||||||
<em class="replaceable"><code>integer</code></em> ] [ dscp <em class="replaceable"><code>integer</code></em> ] | <em class="replaceable"><code>ipv4_address</code></em> [ port<br>
|
<em class="replaceable"><code>integer</code></em> ] [ dscp <em class="replaceable"><code>integer</code></em> ] | <em class="replaceable"><code>ipv4_address</code></em> [ port<br>
|
||||||
<em class="replaceable"><code>integer</code></em> ] [ dscp <em class="replaceable"><code>integer</code></em> ] | <em class="replaceable"><code>ipv6_address</code></em> [ port<br>
|
<em class="replaceable"><code>integer</code></em> ] [ dscp <em class="replaceable"><code>integer</code></em> ] | <em class="replaceable"><code>ipv6_address</code></em> [ port<br>
|
||||||
@@ -683,7 +681,7 @@ view
|
|||||||
preferred-glue <em class="replaceable"><code>string</code></em>;<br>
|
preferred-glue <em class="replaceable"><code>string</code></em>;<br>
|
||||||
prefetch <em class="replaceable"><code>integer</code></em> [ <em class="replaceable"><code>integer</code></em> ];<br>
|
prefetch <em class="replaceable"><code>integer</code></em> [ <em class="replaceable"><code>integer</code></em> ];<br>
|
||||||
provide-ixfr <em class="replaceable"><code>boolean</code></em>;<br>
|
provide-ixfr <em class="replaceable"><code>boolean</code></em>;<br>
|
||||||
qname-minimization ( strict | relaxed | disabled | off );<br>
|
qname-minimization ( strict | relaxed | disabled );<br>
|
||||||
query-source ( ( [ address ] ( <em class="replaceable"><code>ipv4_address</code></em> | * ) [ port (<br>
|
query-source ( ( [ address ] ( <em class="replaceable"><code>ipv4_address</code></em> | * ) [ port (<br>
|
||||||
<em class="replaceable"><code>integer</code></em> | * ) ] ) | ( [ [ address ] ( <em class="replaceable"><code>ipv4_address</code></em> | * ) ]<br>
|
<em class="replaceable"><code>integer</code></em> | * ) ] ) | ( [ [ address ] ( <em class="replaceable"><code>ipv4_address</code></em> | * ) ]<br>
|
||||||
port ( <em class="replaceable"><code>integer</code></em> | * ) ) ) [ dscp <em class="replaceable"><code>integer</code></em> ];<br>
|
port ( <em class="replaceable"><code>integer</code></em> | * ) ) ) [ dscp <em class="replaceable"><code>integer</code></em> ];<br>
|
||||||
@@ -729,7 +727,7 @@ view
|
|||||||
nsip-enable <em class="replaceable"><code>boolean</code></em> ] [ nsdname-enable <em class="replaceable"><code>boolean</code></em> ] [<br>
|
nsip-enable <em class="replaceable"><code>boolean</code></em> ] [ nsdname-enable <em class="replaceable"><code>boolean</code></em> ] [<br>
|
||||||
dnsrps-enable <em class="replaceable"><code>boolean</code></em> ] [ dnsrps-options { <em class="replaceable"><code>unspecified-text</code></em><br>
|
dnsrps-enable <em class="replaceable"><code>boolean</code></em> ] [ dnsrps-options { <em class="replaceable"><code>unspecified-text</code></em><br>
|
||||||
} ];<br>
|
} ];<br>
|
||||||
root-delegation-only [ exclude { <em class="replaceable"><code>string</code></em>; ... } ];<br>
|
root-delegation-only [ exclude { <em class="replaceable"><code>quoted_string</code></em>; ... } ];<br>
|
||||||
root-key-sentinel <em class="replaceable"><code>boolean</code></em>;<br>
|
root-key-sentinel <em class="replaceable"><code>boolean</code></em>;<br>
|
||||||
rrset-order { [ class <em class="replaceable"><code>string</code></em> ] [ type <em class="replaceable"><code>string</code></em> ] [ name<br>
|
rrset-order { [ class <em class="replaceable"><code>string</code></em> ] [ type <em class="replaceable"><code>string</code></em> ] [ name<br>
|
||||||
<em class="replaceable"><code>quoted_string</code></em> ] <em class="replaceable"><code>string</code></em> <em class="replaceable"><code>string</code></em>; ... };<br>
|
<em class="replaceable"><code>quoted_string</code></em> ] <em class="replaceable"><code>string</code></em> <em class="replaceable"><code>string</code></em>; ... };<br>
|
||||||
@@ -791,7 +789,6 @@ view
|
|||||||
update-check-ksk <em class="replaceable"><code>boolean</code></em>;<br>
|
update-check-ksk <em class="replaceable"><code>boolean</code></em>;<br>
|
||||||
use-alt-transfer-source <em class="replaceable"><code>boolean</code></em>;<br>
|
use-alt-transfer-source <em class="replaceable"><code>boolean</code></em>;<br>
|
||||||
v6-bias <em class="replaceable"><code>integer</code></em>;<br>
|
v6-bias <em class="replaceable"><code>integer</code></em>;<br>
|
||||||
validate-except { <em class="replaceable"><code>string</code></em>; ... };<br>
|
|
||||||
zero-no-soa-ttl <em class="replaceable"><code>boolean</code></em>;<br>
|
zero-no-soa-ttl <em class="replaceable"><code>boolean</code></em>;<br>
|
||||||
zero-no-soa-ttl-cache <em class="replaceable"><code>boolean</code></em>;<br>
|
zero-no-soa-ttl-cache <em class="replaceable"><code>boolean</code></em>;<br>
|
||||||
zone <em class="replaceable"><code>string</code></em> [ <em class="replaceable"><code>class</code></em> ] {<br>
|
zone <em class="replaceable"><code>string</code></em> [ <em class="replaceable"><code>class</code></em> ] {<br>
|
||||||
@@ -856,6 +853,7 @@ view
|
|||||||
max-zone-ttl ( unlimited | <em class="replaceable"><code>ttlval</code></em> );<br>
|
max-zone-ttl ( unlimited | <em class="replaceable"><code>ttlval</code></em> );<br>
|
||||||
min-refresh-time <em class="replaceable"><code>integer</code></em>;<br>
|
min-refresh-time <em class="replaceable"><code>integer</code></em>;<br>
|
||||||
min-retry-time <em class="replaceable"><code>integer</code></em>;<br>
|
min-retry-time <em class="replaceable"><code>integer</code></em>;<br>
|
||||||
|
mirror <em class="replaceable"><code>boolean</code></em>;<br>
|
||||||
multi-master <em class="replaceable"><code>boolean</code></em>;<br>
|
multi-master <em class="replaceable"><code>boolean</code></em>;<br>
|
||||||
notify ( explicit | master-only | <em class="replaceable"><code>boolean</code></em> );<br>
|
notify ( explicit | master-only | <em class="replaceable"><code>boolean</code></em> );<br>
|
||||||
notify-delay <em class="replaceable"><code>integer</code></em>;<br>
|
notify-delay <em class="replaceable"><code>integer</code></em>;<br>
|
||||||
@@ -870,8 +868,9 @@ view
|
|||||||
request-expire <em class="replaceable"><code>boolean</code></em>;<br>
|
request-expire <em class="replaceable"><code>boolean</code></em>;<br>
|
||||||
request-ixfr <em class="replaceable"><code>boolean</code></em>;<br>
|
request-ixfr <em class="replaceable"><code>boolean</code></em>;<br>
|
||||||
serial-update-method ( date | increment | unixtime );<br>
|
serial-update-method ( date | increment | unixtime );<br>
|
||||||
server-addresses { ( <em class="replaceable"><code>ipv4_address</code></em> | <em class="replaceable"><code>ipv6_address</code></em> ); ... };<br>
|
server-addresses { ( <em class="replaceable"><code>ipv4_address</code></em> | <em class="replaceable"><code>ipv6_address</code></em> ) [<br>
|
||||||
server-names { <em class="replaceable"><code>string</code></em>; ... };<br>
|
port <em class="replaceable"><code>integer</code></em> ]; ... };<br>
|
||||||
|
server-names { <em class="replaceable"><code>quoted_string</code></em>; ... };<br>
|
||||||
sig-signing-nodes <em class="replaceable"><code>integer</code></em>;<br>
|
sig-signing-nodes <em class="replaceable"><code>integer</code></em>;<br>
|
||||||
sig-signing-signatures <em class="replaceable"><code>integer</code></em>;<br>
|
sig-signing-signatures <em class="replaceable"><code>integer</code></em>;<br>
|
||||||
sig-signing-type <em class="replaceable"><code>integer</code></em>;<br>
|
sig-signing-type <em class="replaceable"><code>integer</code></em>;<br>
|
||||||
@@ -881,15 +880,15 @@ view
|
|||||||
transfer-source-v6 ( <em class="replaceable"><code>ipv6_address</code></em> | * ) [ port (<br>
|
transfer-source-v6 ( <em class="replaceable"><code>ipv6_address</code></em> | * ) [ port (<br>
|
||||||
<em class="replaceable"><code>integer</code></em> | * ) ] [ dscp <em class="replaceable"><code>integer</code></em> ];<br>
|
<em class="replaceable"><code>integer</code></em> | * ) ] [ dscp <em class="replaceable"><code>integer</code></em> ];<br>
|
||||||
try-tcp-refresh <em class="replaceable"><code>boolean</code></em>;<br>
|
try-tcp-refresh <em class="replaceable"><code>boolean</code></em>;<br>
|
||||||
type ( primary | master | secondary | slave | mirror |<br>
|
type ( primary | master | secondary | slave |<br>
|
||||||
delegation-only | forward | hint | redirect |<br>
|
delegation-only | forward | hint | redirect |<br>
|
||||||
static-stub | stub );<br>
|
static-stub | stub );<br>
|
||||||
update-check-ksk <em class="replaceable"><code>boolean</code></em>;<br>
|
update-check-ksk <em class="replaceable"><code>boolean</code></em>;<br>
|
||||||
update-policy ( local | { ( deny | grant ) <em class="replaceable"><code>string</code></em> (<br>
|
update-policy ( local | { ( deny | grant ) <em class="replaceable"><code>string</code></em> (<br>
|
||||||
6to4-self | external | krb5-self | krb5-selfsub |<br>
|
6to4-self | external | krb5-self | krb5-subdomain |<br>
|
||||||
krb5-subdomain | ms-self | ms-selfsub | ms-subdomain |<br>
|
ms-self | ms-subdomain | name | self | selfsub |<br>
|
||||||
name | self | selfsub | selfwild | subdomain | tcp-self<br>
|
selfwild | subdomain | tcp-self | wildcard | zonesub )<br>
|
||||||
| wildcard | zonesub ) [ <em class="replaceable"><code>string</code></em> ] <em class="replaceable"><code>rrtypelist</code></em>; ... };<br>
|
[ <em class="replaceable"><code>string</code></em> ] <em class="replaceable"><code>rrtypelist</code></em>; ... };<br>
|
||||||
use-alt-transfer-source <em class="replaceable"><code>boolean</code></em>;<br>
|
use-alt-transfer-source <em class="replaceable"><code>boolean</code></em>;<br>
|
||||||
zero-no-soa-ttl <em class="replaceable"><code>boolean</code></em>;<br>
|
zero-no-soa-ttl <em class="replaceable"><code>boolean</code></em>;<br>
|
||||||
zone-statistics ( full | terse | none | <em class="replaceable"><code>boolean</code></em> );<br>
|
zone-statistics ( full | terse | none | <em class="replaceable"><code>boolean</code></em> );<br>
|
||||||
@@ -961,6 +960,7 @@ zone
|
|||||||
max-zone-ttl ( unlimited | <em class="replaceable"><code>ttlval</code></em> );<br>
|
max-zone-ttl ( unlimited | <em class="replaceable"><code>ttlval</code></em> );<br>
|
||||||
min-refresh-time <em class="replaceable"><code>integer</code></em>;<br>
|
min-refresh-time <em class="replaceable"><code>integer</code></em>;<br>
|
||||||
min-retry-time <em class="replaceable"><code>integer</code></em>;<br>
|
min-retry-time <em class="replaceable"><code>integer</code></em>;<br>
|
||||||
|
mirror <em class="replaceable"><code>boolean</code></em>;<br>
|
||||||
multi-master <em class="replaceable"><code>boolean</code></em>;<br>
|
multi-master <em class="replaceable"><code>boolean</code></em>;<br>
|
||||||
notify ( explicit | master-only | <em class="replaceable"><code>boolean</code></em> );<br>
|
notify ( explicit | master-only | <em class="replaceable"><code>boolean</code></em> );<br>
|
||||||
notify-delay <em class="replaceable"><code>integer</code></em>;<br>
|
notify-delay <em class="replaceable"><code>integer</code></em>;<br>
|
||||||
@@ -973,8 +973,9 @@ zone
|
|||||||
request-expire <em class="replaceable"><code>boolean</code></em>;<br>
|
request-expire <em class="replaceable"><code>boolean</code></em>;<br>
|
||||||
request-ixfr <em class="replaceable"><code>boolean</code></em>;<br>
|
request-ixfr <em class="replaceable"><code>boolean</code></em>;<br>
|
||||||
serial-update-method ( date | increment | unixtime );<br>
|
serial-update-method ( date | increment | unixtime );<br>
|
||||||
server-addresses { ( <em class="replaceable"><code>ipv4_address</code></em> | <em class="replaceable"><code>ipv6_address</code></em> ); ... };<br>
|
server-addresses { ( <em class="replaceable"><code>ipv4_address</code></em> | <em class="replaceable"><code>ipv6_address</code></em> ) [ port<br>
|
||||||
server-names { <em class="replaceable"><code>string</code></em>; ... };<br>
|
<em class="replaceable"><code>integer</code></em> ]; ... };<br>
|
||||||
|
server-names { <em class="replaceable"><code>quoted_string</code></em>; ... };<br>
|
||||||
sig-signing-nodes <em class="replaceable"><code>integer</code></em>;<br>
|
sig-signing-nodes <em class="replaceable"><code>integer</code></em>;<br>
|
||||||
sig-signing-signatures <em class="replaceable"><code>integer</code></em>;<br>
|
sig-signing-signatures <em class="replaceable"><code>integer</code></em>;<br>
|
||||||
sig-signing-type <em class="replaceable"><code>integer</code></em>;<br>
|
sig-signing-type <em class="replaceable"><code>integer</code></em>;<br>
|
||||||
@@ -984,15 +985,13 @@ zone
|
|||||||
transfer-source-v6 ( <em class="replaceable"><code>ipv6_address</code></em> | * ) [ port ( <em class="replaceable"><code>integer</code></em> | * )<br>
|
transfer-source-v6 ( <em class="replaceable"><code>ipv6_address</code></em> | * ) [ port ( <em class="replaceable"><code>integer</code></em> | * )<br>
|
||||||
] [ dscp <em class="replaceable"><code>integer</code></em> ];<br>
|
] [ dscp <em class="replaceable"><code>integer</code></em> ];<br>
|
||||||
try-tcp-refresh <em class="replaceable"><code>boolean</code></em>;<br>
|
try-tcp-refresh <em class="replaceable"><code>boolean</code></em>;<br>
|
||||||
type ( primary | master | secondary | slave | mirror |<br>
|
type ( primary | master | secondary | slave | delegation-only |<br>
|
||||||
delegation-only | forward | hint | redirect | static-stub |<br>
|
forward | hint | redirect | static-stub | stub );<br>
|
||||||
stub );<br>
|
|
||||||
update-check-ksk <em class="replaceable"><code>boolean</code></em>;<br>
|
update-check-ksk <em class="replaceable"><code>boolean</code></em>;<br>
|
||||||
update-policy ( local | { ( deny | grant ) <em class="replaceable"><code>string</code></em> ( 6to4-self |<br>
|
update-policy ( local | { ( deny | grant ) <em class="replaceable"><code>string</code></em> ( 6to4-self |<br>
|
||||||
external | krb5-self | krb5-selfsub | krb5-subdomain | ms-self<br>
|
external | krb5-self | krb5-subdomain | ms-self | ms-subdomain<br>
|
||||||
| ms-selfsub | ms-subdomain | name | self | selfsub | selfwild<br>
|
| name | self | selfsub | selfwild | subdomain | tcp-self |<br>
|
||||||
| subdomain | tcp-self | wildcard | zonesub ) [ <em class="replaceable"><code>string</code></em> ]<br>
|
wildcard | zonesub ) [ <em class="replaceable"><code>string</code></em> ] <em class="replaceable"><code>rrtypelist</code></em>; ... };<br>
|
||||||
<em class="replaceable"><code>rrtypelist</code></em>; ... };<br>
|
|
||||||
use-alt-transfer-source <em class="replaceable"><code>boolean</code></em>;<br>
|
use-alt-transfer-source <em class="replaceable"><code>boolean</code></em>;<br>
|
||||||
zero-no-soa-ttl <em class="replaceable"><code>boolean</code></em>;<br>
|
zero-no-soa-ttl <em class="replaceable"><code>boolean</code></em>;<br>
|
||||||
zone-statistics ( full | terse | none | <em class="replaceable"><code>boolean</code></em> );<br>
|
zone-statistics ( full | terse | none | <em class="replaceable"><code>boolean</code></em> );<br>
|
||||||
|
|||||||
+143
-408
File diff suppressed because it is too large
Load Diff
@@ -94,7 +94,6 @@ user_zonetype( dns_zone_t *zone ) {
|
|||||||
{ dns_zone_none, "none" },
|
{ dns_zone_none, "none" },
|
||||||
{ dns_zone_master, "master" },
|
{ dns_zone_master, "master" },
|
||||||
{ dns_zone_slave, "slave" },
|
{ dns_zone_slave, "slave" },
|
||||||
{ dns_zone_mirror, "mirror" },
|
|
||||||
{ dns_zone_stub, "stub" },
|
{ dns_zone_stub, "stub" },
|
||||||
{ dns_zone_staticstub, "static-stub" },
|
{ dns_zone_staticstub, "static-stub" },
|
||||||
{ dns_zone_key, "key" },
|
{ dns_zone_key, "key" },
|
||||||
@@ -3226,7 +3225,7 @@ destroy_listener(void *arg) {
|
|||||||
/* We don't have to acquire the lock here since it's already unlinked */
|
/* We don't have to acquire the lock here since it's already unlinked */
|
||||||
dns_acl_detach(&listener->acl);
|
dns_acl_detach(&listener->acl);
|
||||||
|
|
||||||
isc_mutex_destroy(&listener->lock);
|
DESTROYLOCK(&listener->lock);
|
||||||
isc_mem_putanddetach(&listener->mctx, listener, sizeof(*listener));
|
isc_mem_putanddetach(&listener->mctx, listener, sizeof(*listener));
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -3253,7 +3252,11 @@ add_listener(named_server_t *server, named_statschannel_t **listenerp,
|
|||||||
listener->mctx = NULL;
|
listener->mctx = NULL;
|
||||||
ISC_LINK_INIT(listener, link);
|
ISC_LINK_INIT(listener, link);
|
||||||
|
|
||||||
isc_mutex_init(&listener->lock);
|
result = isc_mutex_init(&listener->lock);
|
||||||
|
if (result != ISC_R_SUCCESS) {
|
||||||
|
isc_mem_put(server->mctx, listener, sizeof(*listener));
|
||||||
|
return (ISC_R_FAILURE);
|
||||||
|
}
|
||||||
|
|
||||||
isc_mem_attach(server->mctx, &listener->mctx);
|
isc_mem_attach(server->mctx, &listener->mctx);
|
||||||
|
|
||||||
@@ -3348,7 +3351,7 @@ cleanup:
|
|||||||
if (result != ISC_R_SUCCESS) {
|
if (result != ISC_R_SUCCESS) {
|
||||||
if (listener->acl != NULL)
|
if (listener->acl != NULL)
|
||||||
dns_acl_detach(&listener->acl);
|
dns_acl_detach(&listener->acl);
|
||||||
isc_mutex_destroy(&listener->lock);
|
DESTROYLOCK(&listener->lock);
|
||||||
isc_mem_putanddetach(&listener->mctx, listener,
|
isc_mem_putanddetach(&listener->mctx, listener,
|
||||||
sizeof(*listener));
|
sizeof(*listener));
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -252,7 +252,9 @@ dlopen_dlz_create(const char *dlzname, unsigned int argc, char *argv[],
|
|||||||
}
|
}
|
||||||
|
|
||||||
/* Initialize the lock */
|
/* Initialize the lock */
|
||||||
isc_mutex_init(&cd->lock);
|
result = isc_mutex_init(&cd->lock);
|
||||||
|
if (result != ISC_R_SUCCESS)
|
||||||
|
goto failed;
|
||||||
|
|
||||||
/* Open the library */
|
/* Open the library */
|
||||||
dlopen_flags = RTLD_NOW|RTLD_GLOBAL;
|
dlopen_flags = RTLD_NOW|RTLD_GLOBAL;
|
||||||
@@ -362,19 +364,15 @@ dlopen_dlz_create(const char *dlzname, unsigned int argc, char *argv[],
|
|||||||
|
|
||||||
failed:
|
failed:
|
||||||
dlopen_log(ISC_LOG_ERROR, "dlz_dlopen of '%s' failed", dlzname);
|
dlopen_log(ISC_LOG_ERROR, "dlz_dlopen of '%s' failed", dlzname);
|
||||||
if (cd->dl_path != NULL) {
|
if (cd->dl_path != NULL)
|
||||||
isc_mem_free(mctx, cd->dl_path);
|
isc_mem_free(mctx, cd->dl_path);
|
||||||
}
|
if (cd->dlzname != NULL)
|
||||||
if (cd->dlzname != NULL) {
|
|
||||||
isc_mem_free(mctx, cd->dlzname);
|
isc_mem_free(mctx, cd->dlzname);
|
||||||
}
|
if (dlopen_flags != 0)
|
||||||
if (dlopen_flags != 0) {
|
(void) isc_mutex_destroy(&cd->lock);
|
||||||
isc_mutex_destroy(&cd->lock);
|
|
||||||
}
|
|
||||||
#ifdef HAVE_DLCLOSE
|
#ifdef HAVE_DLCLOSE
|
||||||
if (cd->dl_handle) {
|
if (cd->dl_handle)
|
||||||
dlclose(cd->dl_handle);
|
dlclose(cd->dl_handle);
|
||||||
}
|
|
||||||
#endif
|
#endif
|
||||||
isc_mem_put(mctx, cd, sizeof(*cd));
|
isc_mem_put(mctx, cd, sizeof(*cd));
|
||||||
isc_mem_destroy(&mctx);
|
isc_mem_destroy(&mctx);
|
||||||
@@ -397,20 +395,17 @@ dlopen_dlz_destroy(void *driverarg, void *dbdata) {
|
|||||||
MAYBE_UNLOCK(cd);
|
MAYBE_UNLOCK(cd);
|
||||||
}
|
}
|
||||||
|
|
||||||
if (cd->dl_path) {
|
if (cd->dl_path)
|
||||||
isc_mem_free(cd->mctx, cd->dl_path);
|
isc_mem_free(cd->mctx, cd->dl_path);
|
||||||
}
|
if (cd->dlzname)
|
||||||
if (cd->dlzname) {
|
|
||||||
isc_mem_free(cd->mctx, cd->dlzname);
|
isc_mem_free(cd->mctx, cd->dlzname);
|
||||||
}
|
|
||||||
|
|
||||||
#ifdef HAVE_DLCLOSE
|
#ifdef HAVE_DLCLOSE
|
||||||
if (cd->dl_handle) {
|
if (cd->dl_handle)
|
||||||
dlclose(cd->dl_handle);
|
dlclose(cd->dl_handle);
|
||||||
}
|
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
isc_mutex_destroy(&cd->lock);
|
(void) isc_mutex_destroy(&cd->lock);
|
||||||
|
|
||||||
mctx = cd->mctx;
|
mctx = cd->mctx;
|
||||||
isc_mem_put(mctx, cd, sizeof(*cd));
|
isc_mem_put(mctx, cd, sizeof(*cd));
|
||||||
|
|||||||
+114
-8
@@ -59,6 +59,54 @@ static int singletonfd = -1;
|
|||||||
#define ISC_FACILITY LOG_DAEMON
|
#define ISC_FACILITY LOG_DAEMON
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
/*
|
||||||
|
* If there's no <sys/capability.h>, we don't care about <sys/prctl.h>
|
||||||
|
*/
|
||||||
|
#ifndef HAVE_SYS_CAPABILITY_H
|
||||||
|
#undef HAVE_SYS_PRCTL_H
|
||||||
|
#endif
|
||||||
|
|
||||||
|
/*
|
||||||
|
* Linux defines:
|
||||||
|
* (T) HAVE_LINUXTHREADS
|
||||||
|
* (C) HAVE_SYS_CAPABILITY_H
|
||||||
|
* (P) HAVE_SYS_PRCTL_H
|
||||||
|
* The possible cases are:
|
||||||
|
* none: setuid() normally
|
||||||
|
* T: no setuid()
|
||||||
|
* C: setuid() normally, drop caps (keep CAP_SETUID)
|
||||||
|
* T+C: no setuid(), drop caps (don't keep CAP_SETUID)
|
||||||
|
* T+C+P: setuid() early, drop caps (keep CAP_SETUID)
|
||||||
|
* C+P: setuid() normally, drop caps (keep CAP_SETUID)
|
||||||
|
* P: not possible
|
||||||
|
* T+P: not possible
|
||||||
|
*
|
||||||
|
* if (C)
|
||||||
|
* caps = BIND_SERVICE + CHROOT + SETGID
|
||||||
|
* if ((T && C && P) || !T)
|
||||||
|
* caps += SETUID
|
||||||
|
* endif
|
||||||
|
* capset(caps)
|
||||||
|
* endif
|
||||||
|
* if (T && C && P && -u)
|
||||||
|
* setuid()
|
||||||
|
* else if (T && -u)
|
||||||
|
* fail
|
||||||
|
* --> start threads
|
||||||
|
* if (!T && -u)
|
||||||
|
* setuid()
|
||||||
|
* if (C && (P || !-u))
|
||||||
|
* caps = BIND_SERVICE
|
||||||
|
* capset(caps)
|
||||||
|
* endif
|
||||||
|
*
|
||||||
|
* It will be nice when Linux threads work properly with setuid().
|
||||||
|
*/
|
||||||
|
|
||||||
|
#ifdef HAVE_LINUXTHREADS
|
||||||
|
static pid_t mainpid = 0;
|
||||||
|
#endif
|
||||||
|
|
||||||
static struct passwd *runas_pw = NULL;
|
static struct passwd *runas_pw = NULL;
|
||||||
static bool done_setuid = false;
|
static bool done_setuid = false;
|
||||||
static int dfd[2] = { -1, -1 };
|
static int dfd[2] = { -1, -1 };
|
||||||
@@ -69,7 +117,10 @@ static bool non_root = false;
|
|||||||
static bool non_root_caps = false;
|
static bool non_root_caps = false;
|
||||||
|
|
||||||
#include <sys/capability.h>
|
#include <sys/capability.h>
|
||||||
#include <sys/prctl.h>
|
|
||||||
|
#ifdef HAVE_SYS_PRCTL_H
|
||||||
|
#include <sys/prctl.h> /* Required for prctl(). */
|
||||||
|
#endif /* HAVE_SYS_PRCTL_H */
|
||||||
|
|
||||||
static void
|
static void
|
||||||
linux_setcaps(cap_t caps) {
|
linux_setcaps(cap_t caps) {
|
||||||
@@ -150,11 +201,15 @@ linux_initialprivs(void) {
|
|||||||
*/
|
*/
|
||||||
SET_CAP(CAP_SYS_CHROOT);
|
SET_CAP(CAP_SYS_CHROOT);
|
||||||
|
|
||||||
|
#if defined(HAVE_SYS_PRCTL_H) || !defined(HAVE_LINUXTHREADS)
|
||||||
/*
|
/*
|
||||||
* We need setuid() as the kernel supports keeping capabilities after
|
* We can setuid() only if either the kernel supports keeping
|
||||||
* setuid().
|
* capabilities after setuid() (which we don't know until we've
|
||||||
|
* tried) or we're not using threads. If either of these is
|
||||||
|
* true, we want the setuid capability.
|
||||||
*/
|
*/
|
||||||
SET_CAP(CAP_SETUID);
|
SET_CAP(CAP_SETUID);
|
||||||
|
#endif
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* Since we call initgroups, we need this.
|
* Since we call initgroups, we need this.
|
||||||
@@ -220,6 +275,7 @@ linux_minprivs(void) {
|
|||||||
FREE_CAP;
|
FREE_CAP;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#ifdef HAVE_SYS_PRCTL_H
|
||||||
static void
|
static void
|
||||||
linux_keepcaps(void) {
|
linux_keepcaps(void) {
|
||||||
char strbuf[ISC_STRERRORSIZE];
|
char strbuf[ISC_STRERRORSIZE];
|
||||||
@@ -239,9 +295,11 @@ linux_keepcaps(void) {
|
|||||||
non_root = true;
|
non_root = true;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
#endif
|
||||||
|
|
||||||
#endif /* HAVE_SYS_CAPABILITY_H */
|
#endif /* HAVE_SYS_CAPABILITY_H */
|
||||||
|
|
||||||
|
|
||||||
static void
|
static void
|
||||||
setup_syslog(const char *progname) {
|
setup_syslog(const char *progname) {
|
||||||
int options;
|
int options;
|
||||||
@@ -259,6 +317,9 @@ named_os_init(const char *progname) {
|
|||||||
#ifdef HAVE_SYS_CAPABILITY_H
|
#ifdef HAVE_SYS_CAPABILITY_H
|
||||||
linux_initialprivs();
|
linux_initialprivs();
|
||||||
#endif
|
#endif
|
||||||
|
#ifdef HAVE_LINUXTHREADS
|
||||||
|
mainpid = getpid();
|
||||||
|
#endif
|
||||||
#ifdef SIGXFSZ
|
#ifdef SIGXFSZ
|
||||||
signal(SIGXFSZ, SIG_IGN);
|
signal(SIGXFSZ, SIG_IGN);
|
||||||
#endif
|
#endif
|
||||||
@@ -301,6 +362,10 @@ named_os_daemonize(void) {
|
|||||||
* We're the child.
|
* We're the child.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
#ifdef HAVE_LINUXTHREADS
|
||||||
|
mainpid = getpid();
|
||||||
|
#endif
|
||||||
|
|
||||||
if (setsid() == -1) {
|
if (setsid() == -1) {
|
||||||
strerror_r(errno, strbuf, sizeof(strbuf));
|
strerror_r(errno, strbuf, sizeof(strbuf));
|
||||||
named_main_earlyfatal("setsid(): %s", strbuf);
|
named_main_earlyfatal("setsid(): %s", strbuf);
|
||||||
@@ -434,6 +499,20 @@ named_os_changeuser(void) {
|
|||||||
|
|
||||||
done_setuid = true;
|
done_setuid = true;
|
||||||
|
|
||||||
|
#ifdef HAVE_LINUXTHREADS
|
||||||
|
#ifdef HAVE_SYS_CAPABILITY_H
|
||||||
|
if (!non_root_caps) {
|
||||||
|
named_main_earlyfatal("-u with Linux threads not supported: "
|
||||||
|
"requires kernel support for "
|
||||||
|
"prctl(PR_SET_KEEPCAPS)");
|
||||||
|
}
|
||||||
|
#else
|
||||||
|
named_main_earlyfatal("-u with Linux threads not supported: "
|
||||||
|
"no capabilities support or capabilities "
|
||||||
|
"disabled at build time");
|
||||||
|
#endif
|
||||||
|
#endif
|
||||||
|
|
||||||
if (setgid(runas_pw->pw_gid) < 0) {
|
if (setgid(runas_pw->pw_gid) < 0) {
|
||||||
strerror_r(errno, strbuf, sizeof(strbuf));
|
strerror_r(errno, strbuf, sizeof(strbuf));
|
||||||
named_main_earlyfatal("setgid(): %s", strbuf);
|
named_main_earlyfatal("setgid(): %s", strbuf);
|
||||||
@@ -444,7 +523,7 @@ named_os_changeuser(void) {
|
|||||||
named_main_earlyfatal("setuid(): %s", strbuf);
|
named_main_earlyfatal("setuid(): %s", strbuf);
|
||||||
}
|
}
|
||||||
|
|
||||||
#if defined(HAVE_SYS_CAPABILITY_H)
|
#if defined(HAVE_SYS_PRCTL_H) && defined(PR_SET_DUMPABLE)
|
||||||
/*
|
/*
|
||||||
* Restore the ability of named to drop core after the setuid()
|
* Restore the ability of named to drop core after the setuid()
|
||||||
* call has disabled it.
|
* call has disabled it.
|
||||||
@@ -454,7 +533,8 @@ named_os_changeuser(void) {
|
|||||||
named_main_earlywarning("prctl(PR_SET_DUMPABLE) failed: %s",
|
named_main_earlywarning("prctl(PR_SET_DUMPABLE) failed: %s",
|
||||||
strbuf);
|
strbuf);
|
||||||
}
|
}
|
||||||
|
#endif
|
||||||
|
#if defined(HAVE_SYS_CAPABILITY_H) && !defined(HAVE_LINUXTHREADS)
|
||||||
linux_minprivs();
|
linux_minprivs();
|
||||||
#endif
|
#endif
|
||||||
}
|
}
|
||||||
@@ -468,7 +548,7 @@ ns_os_uid(void) {
|
|||||||
|
|
||||||
void
|
void
|
||||||
named_os_adjustnofile(void) {
|
named_os_adjustnofile(void) {
|
||||||
#if defined(__linux__)
|
#ifdef HAVE_LINUXTHREADS
|
||||||
isc_result_t result;
|
isc_result_t result;
|
||||||
isc_resourcevalue_t newvalue;
|
isc_resourcevalue_t newvalue;
|
||||||
|
|
||||||
@@ -486,9 +566,15 @@ named_os_adjustnofile(void) {
|
|||||||
|
|
||||||
void
|
void
|
||||||
named_os_minprivs(void) {
|
named_os_minprivs(void) {
|
||||||
#if defined(HAVE_SYS_CAPABILITY_H)
|
#ifdef HAVE_SYS_PRCTL_H
|
||||||
linux_keepcaps();
|
linux_keepcaps();
|
||||||
named_os_changeuser();
|
#endif
|
||||||
|
|
||||||
|
#ifdef HAVE_LINUXTHREADS
|
||||||
|
named_os_changeuser(); /* Call setuid() before threads are started */
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#if defined(HAVE_SYS_CAPABILITY_H) && defined(HAVE_LINUXTHREADS)
|
||||||
linux_minprivs();
|
linux_minprivs();
|
||||||
#endif
|
#endif
|
||||||
}
|
}
|
||||||
@@ -673,16 +759,21 @@ named_os_openfile(const char *filename, mode_t mode, bool switch_user) {
|
|||||||
free(f);
|
free(f);
|
||||||
|
|
||||||
if (switch_user && runas_pw != NULL) {
|
if (switch_user && runas_pw != NULL) {
|
||||||
|
#ifndef HAVE_LINUXTHREADS
|
||||||
gid_t oldgid = getgid();
|
gid_t oldgid = getgid();
|
||||||
|
#endif
|
||||||
/* Set UID/GID to the one we'll be running with eventually */
|
/* Set UID/GID to the one we'll be running with eventually */
|
||||||
setperms(runas_pw->pw_uid, runas_pw->pw_gid);
|
setperms(runas_pw->pw_uid, runas_pw->pw_gid);
|
||||||
|
|
||||||
fd = safe_open(filename, mode, false);
|
fd = safe_open(filename, mode, false);
|
||||||
|
|
||||||
|
#ifndef HAVE_LINUXTHREADS
|
||||||
/* Restore UID/GID to root */
|
/* Restore UID/GID to root */
|
||||||
setperms(0, oldgid);
|
setperms(0, oldgid);
|
||||||
|
#endif /* HAVE_LINUXTHREADS */
|
||||||
|
|
||||||
if (fd == -1) {
|
if (fd == -1) {
|
||||||
|
#ifndef HAVE_LINUXTHREADS
|
||||||
fd = safe_open(filename, mode, false);
|
fd = safe_open(filename, mode, false);
|
||||||
if (fd != -1) {
|
if (fd != -1) {
|
||||||
named_main_earlywarning("Required root "
|
named_main_earlywarning("Required root "
|
||||||
@@ -695,6 +786,13 @@ named_os_openfile(const char *filename, mode_t mode, bool switch_user) {
|
|||||||
named_main_earlywarning("Please check file and "
|
named_main_earlywarning("Please check file and "
|
||||||
"directory permissions "
|
"directory permissions "
|
||||||
"or reconfigure the filename.");
|
"or reconfigure the filename.");
|
||||||
|
#else /* HAVE_LINUXTHREADS */
|
||||||
|
named_main_earlywarning("Could not open "
|
||||||
|
"'%s'.", filename);
|
||||||
|
named_main_earlywarning("Please check file and "
|
||||||
|
"directory permissions "
|
||||||
|
"or reconfigure the filename.");
|
||||||
|
#endif /* HAVE_LINUXTHREADS */
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
fd = safe_open(filename, mode, false);
|
fd = safe_open(filename, mode, false);
|
||||||
@@ -748,7 +846,11 @@ named_os_writepidfile(const char *filename, bool first_time) {
|
|||||||
cleanup_pidfile();
|
cleanup_pidfile();
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
#ifdef HAVE_LINUXTHREADS
|
||||||
|
pid = mainpid;
|
||||||
|
#else
|
||||||
pid = getpid();
|
pid = getpid();
|
||||||
|
#endif
|
||||||
if (fprintf(fh, "%ld\n", (long)pid) < 0) {
|
if (fprintf(fh, "%ld\n", (long)pid) < 0) {
|
||||||
(*report)("fprintf() to pid file '%s' failed", filename);
|
(*report)("fprintf() to pid file '%s' failed", filename);
|
||||||
(void)fclose(fh);
|
(void)fclose(fh);
|
||||||
@@ -854,7 +956,11 @@ named_os_shutdownmsg(char *command, isc_buffer_t *text) {
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#ifdef HAVE_LINUXTHREADS
|
||||||
|
pid = mainpid;
|
||||||
|
#else
|
||||||
pid = getpid();
|
pid = getpid();
|
||||||
|
#endif
|
||||||
|
|
||||||
(void)isc_buffer_printf(text, "pid: %ld", (long)pid);
|
(void)isc_buffer_printf(text, "pid: %ld", (long)pid);
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -253,7 +253,9 @@ dlopen_dlz_create(const char *dlzname, unsigned int argc, char *argv[],
|
|||||||
triedload = true;
|
triedload = true;
|
||||||
|
|
||||||
/* Initialize the lock */
|
/* Initialize the lock */
|
||||||
isc_mutex_init(&cd->lock);
|
result = isc_mutex_init(&cd->lock);
|
||||||
|
if (result != ISC_R_SUCCESS)
|
||||||
|
goto failed;
|
||||||
|
|
||||||
/* Open the library */
|
/* Open the library */
|
||||||
cd->dl_handle = LoadLibraryA(cd->dl_path);
|
cd->dl_handle = LoadLibraryA(cd->dl_path);
|
||||||
@@ -347,21 +349,17 @@ dlopen_dlz_create(const char *dlzname, unsigned int argc, char *argv[],
|
|||||||
return (ISC_R_SUCCESS);
|
return (ISC_R_SUCCESS);
|
||||||
|
|
||||||
cleanup_lock:
|
cleanup_lock:
|
||||||
isc_mutex_destroy(&cd->lock);
|
DESTROYLOCK(&cd->lock);
|
||||||
failed:
|
failed:
|
||||||
dlopen_log(ISC_LOG_ERROR, "dlz_dlopen of '%s' failed", dlzname);
|
dlopen_log(ISC_LOG_ERROR, "dlz_dlopen of '%s' failed", dlzname);
|
||||||
if (cd->dl_path) {
|
if (cd->dl_path)
|
||||||
isc_mem_free(mctx, cd->dl_path);
|
isc_mem_free(mctx, cd->dl_path);
|
||||||
}
|
if (cd->dlzname)
|
||||||
if (cd->dlzname) {
|
|
||||||
isc_mem_free(mctx, cd->dlzname);
|
isc_mem_free(mctx, cd->dlzname);
|
||||||
}
|
if (triedload)
|
||||||
if (triedload) {
|
(void) isc_mutex_destroy(&cd->lock);
|
||||||
isc_mutex_destroy(&cd->lock);
|
if (cd->dl_handle)
|
||||||
}
|
|
||||||
if (cd->dl_handle) {
|
|
||||||
FreeLibrary(cd->dl_handle);
|
FreeLibrary(cd->dl_handle);
|
||||||
}
|
|
||||||
isc_mem_put(mctx, cd, sizeof(*cd));
|
isc_mem_put(mctx, cd, sizeof(*cd));
|
||||||
isc_mem_destroy(&mctx);
|
isc_mem_destroy(&mctx);
|
||||||
return (result);
|
return (result);
|
||||||
@@ -392,7 +390,7 @@ dlopen_dlz_destroy(void *driverarg, void *dbdata) {
|
|||||||
if (cd->dl_handle)
|
if (cd->dl_handle)
|
||||||
FreeLibrary(cd->dl_handle);
|
FreeLibrary(cd->dl_handle);
|
||||||
|
|
||||||
isc_mutex_destroy(&cd->lock);
|
DESTROYLOCK(&cd->lock);
|
||||||
|
|
||||||
mctx = cd->mctx;
|
mctx = cd->mctx;
|
||||||
isc_mem_put(mctx, cd, sizeof(*cd));
|
isc_mem_put(mctx, cd, sizeof(*cd));
|
||||||
|
|||||||
+88
-137
@@ -125,7 +125,7 @@ configure_zone_acl(const cfg_obj_t *zconfig, const cfg_obj_t *vconfig,
|
|||||||
break;
|
break;
|
||||||
default:
|
default:
|
||||||
INSIST(0);
|
INSIST(0);
|
||||||
ISC_UNREACHABLE();
|
return (ISC_R_FAILURE);
|
||||||
}
|
}
|
||||||
|
|
||||||
/* First check to see if ACL is defined within the zone */
|
/* First check to see if ACL is defined within the zone */
|
||||||
@@ -224,21 +224,19 @@ configure_zone_ssutable(const cfg_obj_t *zconfig, dns_zone_t *zone,
|
|||||||
const char *str;
|
const char *str;
|
||||||
bool grant = false;
|
bool grant = false;
|
||||||
bool usezone = false;
|
bool usezone = false;
|
||||||
dns_ssumatchtype_t mtype = dns_ssumatchtype_name;
|
unsigned int mtype = dns_ssumatchtype_name;
|
||||||
dns_fixedname_t fname, fident;
|
dns_fixedname_t fname, fident;
|
||||||
isc_buffer_t b;
|
isc_buffer_t b;
|
||||||
dns_rdatatype_t *types;
|
dns_rdatatype_t *types;
|
||||||
unsigned int i, n;
|
unsigned int i, n;
|
||||||
|
|
||||||
str = cfg_obj_asstring(mode);
|
str = cfg_obj_asstring(mode);
|
||||||
if (strcasecmp(str, "grant") == 0) {
|
if (strcasecmp(str, "grant") == 0)
|
||||||
grant = true;
|
grant = true;
|
||||||
} else if (strcasecmp(str, "deny") == 0) {
|
else if (strcasecmp(str, "deny") == 0)
|
||||||
grant = false;
|
grant = false;
|
||||||
} else {
|
else
|
||||||
INSIST(0);
|
INSIST(0);
|
||||||
ISC_UNREACHABLE();
|
|
||||||
}
|
|
||||||
|
|
||||||
str = cfg_obj_asstring(matchtype);
|
str = cfg_obj_asstring(matchtype);
|
||||||
CHECK(dns_ssu_mtypefromstring(str, &mtype));
|
CHECK(dns_ssu_mtypefromstring(str, &mtype));
|
||||||
@@ -757,16 +755,10 @@ checknames(dns_zonetype_t ztype, const cfg_obj_t **maps,
|
|||||||
isc_result_t result;
|
isc_result_t result;
|
||||||
|
|
||||||
switch (ztype) {
|
switch (ztype) {
|
||||||
case dns_zone_slave:
|
case dns_zone_slave: zone = "slave"; break;
|
||||||
case dns_zone_mirror:
|
case dns_zone_master: zone = "master"; break;
|
||||||
zone = "slave";
|
|
||||||
break;
|
|
||||||
case dns_zone_master:
|
|
||||||
zone = "master";
|
|
||||||
break;
|
|
||||||
default:
|
default:
|
||||||
INSIST(0);
|
INSIST(0);
|
||||||
ISC_UNREACHABLE();
|
|
||||||
}
|
}
|
||||||
result = named_checknames_get(maps, zone, objp);
|
result = named_checknames_get(maps, zone, objp);
|
||||||
INSIST(result == ISC_R_SUCCESS && objp != NULL && *objp != NULL);
|
INSIST(result == ISC_R_SUCCESS && objp != NULL && *objp != NULL);
|
||||||
@@ -836,37 +828,6 @@ isself(dns_view_t *myview, dns_tsigkey_t *mykey,
|
|||||||
return (view == myview);
|
return (view == myview);
|
||||||
}
|
}
|
||||||
|
|
||||||
/*%
|
|
||||||
* For mirror zones, change "notify yes;" to "notify explicit;", informing the
|
|
||||||
* user only if "notify" was explicitly configured rather than inherited from
|
|
||||||
* default configuration.
|
|
||||||
*/
|
|
||||||
static dns_notifytype_t
|
|
||||||
process_notifytype(dns_notifytype_t ntype, dns_zonetype_t ztype,
|
|
||||||
const char *zname, const cfg_obj_t **maps)
|
|
||||||
{
|
|
||||||
const cfg_obj_t *obj = NULL;
|
|
||||||
|
|
||||||
/*
|
|
||||||
* Return the original setting if this is not a mirror zone or if the
|
|
||||||
* zone is configured with something else than "notify yes;".
|
|
||||||
*/
|
|
||||||
if (ztype != dns_zone_mirror || ntype != dns_notifytype_yes) {
|
|
||||||
return (ntype);
|
|
||||||
}
|
|
||||||
|
|
||||||
/*
|
|
||||||
* Only log a message if "notify" was set in the configuration
|
|
||||||
* hierarchy supplied in 'maps'.
|
|
||||||
*/
|
|
||||||
if (named_config_get(maps, "notify", &obj) == ISC_R_SUCCESS) {
|
|
||||||
cfg_obj_log(obj, named_g_lctx, ISC_LOG_INFO,
|
|
||||||
"'notify explicit;' will be used for mirror zone "
|
|
||||||
"'%s'", zname);
|
|
||||||
}
|
|
||||||
|
|
||||||
return (dns_notifytype_explicit);
|
|
||||||
}
|
|
||||||
|
|
||||||
isc_result_t
|
isc_result_t
|
||||||
named_zone_configure(const cfg_obj_t *config, const cfg_obj_t *vconfig,
|
named_zone_configure(const cfg_obj_t *config, const cfg_obj_t *vconfig,
|
||||||
@@ -906,7 +867,7 @@ named_zone_configure(const cfg_obj_t *config, const cfg_obj_t *vconfig,
|
|||||||
const dns_master_style_t *masterstyle = &dns_master_style_default;
|
const dns_master_style_t *masterstyle = &dns_master_style_default;
|
||||||
isc_stats_t *zoneqrystats;
|
isc_stats_t *zoneqrystats;
|
||||||
dns_stats_t *rcvquerystats;
|
dns_stats_t *rcvquerystats;
|
||||||
dns_zonestat_level_t statlevel = dns_zonestat_none;
|
dns_zonestat_level_t statlevel;
|
||||||
int seconds;
|
int seconds;
|
||||||
dns_zone_t *mayberaw = (raw != NULL) ? raw : zone;
|
dns_zone_t *mayberaw = (raw != NULL) ? raw : zone;
|
||||||
isc_dscp_t dscp;
|
isc_dscp_t dscp;
|
||||||
@@ -1021,7 +982,7 @@ named_zone_configure(const cfg_obj_t *config, const cfg_obj_t *vconfig,
|
|||||||
return (ISC_R_FAILURE);
|
return (ISC_R_FAILURE);
|
||||||
}
|
}
|
||||||
|
|
||||||
if (ztype == dns_zone_slave || ztype == dns_zone_mirror)
|
if (ztype == dns_zone_slave)
|
||||||
masterformat = dns_masterformat_raw;
|
masterformat = dns_masterformat_raw;
|
||||||
else
|
else
|
||||||
masterformat = dns_masterformat_text;
|
masterformat = dns_masterformat_text;
|
||||||
@@ -1030,16 +991,14 @@ named_zone_configure(const cfg_obj_t *config, const cfg_obj_t *vconfig,
|
|||||||
if (result == ISC_R_SUCCESS) {
|
if (result == ISC_R_SUCCESS) {
|
||||||
const char *masterformatstr = cfg_obj_asstring(obj);
|
const char *masterformatstr = cfg_obj_asstring(obj);
|
||||||
|
|
||||||
if (strcasecmp(masterformatstr, "text") == 0) {
|
if (strcasecmp(masterformatstr, "text") == 0)
|
||||||
masterformat = dns_masterformat_text;
|
masterformat = dns_masterformat_text;
|
||||||
} else if (strcasecmp(masterformatstr, "raw") == 0) {
|
else if (strcasecmp(masterformatstr, "raw") == 0)
|
||||||
masterformat = dns_masterformat_raw;
|
masterformat = dns_masterformat_raw;
|
||||||
} else if (strcasecmp(masterformatstr, "map") == 0) {
|
else if (strcasecmp(masterformatstr, "map") == 0)
|
||||||
masterformat = dns_masterformat_map;
|
masterformat = dns_masterformat_map;
|
||||||
} else {
|
else
|
||||||
INSIST(0);
|
INSIST(0);
|
||||||
ISC_UNREACHABLE();
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
obj = NULL;
|
obj = NULL;
|
||||||
@@ -1055,14 +1014,12 @@ named_zone_configure(const cfg_obj_t *config, const cfg_obj_t *vconfig,
|
|||||||
return (ISC_R_FAILURE);
|
return (ISC_R_FAILURE);
|
||||||
}
|
}
|
||||||
|
|
||||||
if (strcasecmp(masterstylestr, "full") == 0) {
|
if (strcasecmp(masterstylestr, "full") == 0)
|
||||||
masterstyle = &dns_master_style_full;
|
masterstyle = &dns_master_style_full;
|
||||||
} else if (strcasecmp(masterstylestr, "relative") == 0) {
|
else if (strcasecmp(masterstylestr, "relative") == 0)
|
||||||
masterstyle = &dns_master_style_default;
|
masterstyle = &dns_master_style_default;
|
||||||
} else {
|
else
|
||||||
INSIST(0);
|
INSIST(0);
|
||||||
ISC_UNREACHABLE();
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
obj = NULL;
|
obj = NULL;
|
||||||
@@ -1119,7 +1076,7 @@ named_zone_configure(const cfg_obj_t *config, const cfg_obj_t *vconfig,
|
|||||||
/*
|
/*
|
||||||
* Notify messages are processed by the raw zone if it exists.
|
* Notify messages are processed by the raw zone if it exists.
|
||||||
*/
|
*/
|
||||||
if (ztype == dns_zone_slave || ztype == dns_zone_mirror)
|
if (ztype == dns_zone_slave)
|
||||||
RETERR(configure_zone_acl(zconfig, vconfig, config,
|
RETERR(configure_zone_acl(zconfig, vconfig, config,
|
||||||
allow_notify, ac, mayberaw,
|
allow_notify, ac, mayberaw,
|
||||||
dns_zone_setnotifyacl,
|
dns_zone_setnotifyacl,
|
||||||
@@ -1148,18 +1105,16 @@ named_zone_configure(const cfg_obj_t *config, const cfg_obj_t *vconfig,
|
|||||||
dialup = dns_dialuptype_no;
|
dialup = dns_dialuptype_no;
|
||||||
} else {
|
} else {
|
||||||
const char *dialupstr = cfg_obj_asstring(obj);
|
const char *dialupstr = cfg_obj_asstring(obj);
|
||||||
if (strcasecmp(dialupstr, "notify") == 0) {
|
if (strcasecmp(dialupstr, "notify") == 0)
|
||||||
dialup = dns_dialuptype_notify;
|
dialup = dns_dialuptype_notify;
|
||||||
} else if (strcasecmp(dialupstr, "notify-passive") == 0) {
|
else if (strcasecmp(dialupstr, "notify-passive") == 0)
|
||||||
dialup = dns_dialuptype_notifypassive;
|
dialup = dns_dialuptype_notifypassive;
|
||||||
} else if (strcasecmp(dialupstr, "refresh") == 0) {
|
else if (strcasecmp(dialupstr, "refresh") == 0)
|
||||||
dialup = dns_dialuptype_refresh;
|
dialup = dns_dialuptype_refresh;
|
||||||
} else if (strcasecmp(dialupstr, "passive") == 0) {
|
else if (strcasecmp(dialupstr, "passive") == 0)
|
||||||
dialup = dns_dialuptype_passive;
|
dialup = dns_dialuptype_passive;
|
||||||
} else {
|
else
|
||||||
INSIST(0);
|
INSIST(0);
|
||||||
ISC_UNREACHABLE();
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
if (raw != NULL)
|
if (raw != NULL)
|
||||||
dns_zone_setdialup(raw, dialup);
|
dns_zone_setdialup(raw, dialup);
|
||||||
@@ -1175,16 +1130,14 @@ named_zone_configure(const cfg_obj_t *config, const cfg_obj_t *vconfig,
|
|||||||
statlevel = dns_zonestat_none;
|
statlevel = dns_zonestat_none;
|
||||||
} else {
|
} else {
|
||||||
const char *levelstr = cfg_obj_asstring(obj);
|
const char *levelstr = cfg_obj_asstring(obj);
|
||||||
if (strcasecmp(levelstr, "full") == 0) {
|
if (strcasecmp(levelstr, "full") == 0)
|
||||||
statlevel = dns_zonestat_full;
|
statlevel = dns_zonestat_full;
|
||||||
} else if (strcasecmp(levelstr, "terse") == 0) {
|
else if (strcasecmp(levelstr, "terse") == 0)
|
||||||
statlevel = dns_zonestat_terse;
|
statlevel = dns_zonestat_terse;
|
||||||
} else if (strcasecmp(levelstr, "none") == 0) {
|
else if (strcasecmp(levelstr, "none") == 0)
|
||||||
statlevel = dns_zonestat_none;
|
statlevel = dns_zonestat_none;
|
||||||
} else {
|
else
|
||||||
INSIST(0);
|
INSIST(0);
|
||||||
ISC_UNREACHABLE();
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
dns_zone_setstatlevel(zone, statlevel);
|
dns_zone_setstatlevel(zone, statlevel);
|
||||||
|
|
||||||
@@ -1222,17 +1175,13 @@ named_zone_configure(const cfg_obj_t *config, const cfg_obj_t *vconfig,
|
|||||||
notifytype = dns_notifytype_no;
|
notifytype = dns_notifytype_no;
|
||||||
} else {
|
} else {
|
||||||
const char *notifystr = cfg_obj_asstring(obj);
|
const char *notifystr = cfg_obj_asstring(obj);
|
||||||
if (strcasecmp(notifystr, "explicit") == 0) {
|
if (strcasecmp(notifystr, "explicit") == 0)
|
||||||
notifytype = dns_notifytype_explicit;
|
notifytype = dns_notifytype_explicit;
|
||||||
} else if (strcasecmp(notifystr, "master-only") == 0) {
|
else if (strcasecmp(notifystr, "master-only") == 0)
|
||||||
notifytype = dns_notifytype_masteronly;
|
notifytype = dns_notifytype_masteronly;
|
||||||
} else {
|
else
|
||||||
INSIST(0);
|
INSIST(0);
|
||||||
ISC_UNREACHABLE();
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
notifytype = process_notifytype(notifytype, ztype, zname,
|
|
||||||
nodefault);
|
|
||||||
if (raw != NULL)
|
if (raw != NULL)
|
||||||
dns_zone_setnotifytype(raw, dns_notifytype_no);
|
dns_zone_setnotifytype(raw, dns_notifytype_no);
|
||||||
dns_zone_setnotifytype(zone, notifytype);
|
dns_zone_setnotifytype(zone, notifytype);
|
||||||
@@ -1387,10 +1336,8 @@ named_zone_configure(const cfg_obj_t *config, const cfg_obj_t *vconfig,
|
|||||||
fail = check = true;
|
fail = check = true;
|
||||||
} else if (strcasecmp(cfg_obj_asstring(obj), "ignore") == 0) {
|
} else if (strcasecmp(cfg_obj_asstring(obj), "ignore") == 0) {
|
||||||
fail = check = false;
|
fail = check = false;
|
||||||
} else {
|
} else
|
||||||
INSIST(0);
|
INSIST(0);
|
||||||
ISC_UNREACHABLE();
|
|
||||||
}
|
|
||||||
if (raw != NULL) {
|
if (raw != NULL) {
|
||||||
dns_zone_setoption(raw, DNS_ZONEOPT_CHECKNAMES,
|
dns_zone_setoption(raw, DNS_ZONEOPT_CHECKNAMES,
|
||||||
check);
|
check);
|
||||||
@@ -1425,10 +1372,8 @@ named_zone_configure(const cfg_obj_t *config, const cfg_obj_t *vconfig,
|
|||||||
check = true;
|
check = true;
|
||||||
} else if (strcasecmp(cfg_obj_asstring(obj), "ignore") == 0) {
|
} else if (strcasecmp(cfg_obj_asstring(obj), "ignore") == 0) {
|
||||||
check = false;
|
check = false;
|
||||||
} else {
|
} else
|
||||||
INSIST(0);
|
INSIST(0);
|
||||||
ISC_UNREACHABLE();
|
|
||||||
}
|
|
||||||
dns_zone_setoption(zone, DNS_ZONEOPT_CHECKSPF, check);
|
dns_zone_setoption(zone, DNS_ZONEOPT_CHECKSPF, check);
|
||||||
|
|
||||||
obj = NULL;
|
obj = NULL;
|
||||||
@@ -1579,22 +1524,20 @@ named_zone_configure(const cfg_obj_t *config, const cfg_obj_t *vconfig,
|
|||||||
result = cfg_map_get(zoptions, "auto-dnssec", &obj);
|
result = cfg_map_get(zoptions, "auto-dnssec", &obj);
|
||||||
if (result == ISC_R_SUCCESS) {
|
if (result == ISC_R_SUCCESS) {
|
||||||
const char *arg = cfg_obj_asstring(obj);
|
const char *arg = cfg_obj_asstring(obj);
|
||||||
if (strcasecmp(arg, "allow") == 0) {
|
if (strcasecmp(arg, "allow") == 0)
|
||||||
allow = true;
|
allow = true;
|
||||||
} else if (strcasecmp(arg, "maintain") == 0) {
|
else if (strcasecmp(arg, "maintain") == 0)
|
||||||
allow = maint = true;
|
allow = maint = true;
|
||||||
} else if (strcasecmp(arg, "off") == 0) {
|
else if (strcasecmp(arg, "off") == 0)
|
||||||
;
|
;
|
||||||
} else {
|
else
|
||||||
INSIST(0);
|
INSIST(0);
|
||||||
ISC_UNREACHABLE();
|
|
||||||
}
|
|
||||||
dns_zone_setkeyopt(zone, DNS_ZONEKEY_ALLOW, allow);
|
dns_zone_setkeyopt(zone, DNS_ZONEKEY_ALLOW, allow);
|
||||||
dns_zone_setkeyopt(zone, DNS_ZONEKEY_MAINTAIN, maint);
|
dns_zone_setkeyopt(zone, DNS_ZONEKEY_MAINTAIN, maint);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if (ztype == dns_zone_slave || ztype == dns_zone_mirror) {
|
if (ztype == dns_zone_slave) {
|
||||||
RETERR(configure_zone_acl(zconfig, vconfig, config,
|
RETERR(configure_zone_acl(zconfig, vconfig, config,
|
||||||
allow_update_forwarding, ac,
|
allow_update_forwarding, ac,
|
||||||
mayberaw, dns_zone_setforwardacl,
|
mayberaw, dns_zone_setforwardacl,
|
||||||
@@ -1641,10 +1584,8 @@ named_zone_configure(const cfg_obj_t *config, const cfg_obj_t *vconfig,
|
|||||||
fail = check = true;
|
fail = check = true;
|
||||||
} else if (strcasecmp(dupcheck, "ignore") == 0) {
|
} else if (strcasecmp(dupcheck, "ignore") == 0) {
|
||||||
fail = check = false;
|
fail = check = false;
|
||||||
} else {
|
} else
|
||||||
INSIST(0);
|
INSIST(0);
|
||||||
ISC_UNREACHABLE();
|
|
||||||
}
|
|
||||||
dns_zone_setoption(mayberaw, DNS_ZONEOPT_CHECKDUPRR, check);
|
dns_zone_setoption(mayberaw, DNS_ZONEOPT_CHECKDUPRR, check);
|
||||||
dns_zone_setoption(mayberaw, DNS_ZONEOPT_CHECKDUPRRFAIL, fail);
|
dns_zone_setoption(mayberaw, DNS_ZONEOPT_CHECKDUPRRFAIL, fail);
|
||||||
|
|
||||||
@@ -1658,10 +1599,8 @@ named_zone_configure(const cfg_obj_t *config, const cfg_obj_t *vconfig,
|
|||||||
fail = check = true;
|
fail = check = true;
|
||||||
} else if (strcasecmp(cfg_obj_asstring(obj), "ignore") == 0) {
|
} else if (strcasecmp(cfg_obj_asstring(obj), "ignore") == 0) {
|
||||||
fail = check = false;
|
fail = check = false;
|
||||||
} else {
|
} else
|
||||||
INSIST(0);
|
INSIST(0);
|
||||||
ISC_UNREACHABLE();
|
|
||||||
}
|
|
||||||
dns_zone_setoption(mayberaw, DNS_ZONEOPT_CHECKMX, check);
|
dns_zone_setoption(mayberaw, DNS_ZONEOPT_CHECKMX, check);
|
||||||
dns_zone_setoption(mayberaw, DNS_ZONEOPT_CHECKMXFAIL, fail);
|
dns_zone_setoption(mayberaw, DNS_ZONEOPT_CHECKMXFAIL, fail);
|
||||||
|
|
||||||
@@ -1697,10 +1636,8 @@ named_zone_configure(const cfg_obj_t *config, const cfg_obj_t *vconfig,
|
|||||||
warn = ignore = false;
|
warn = ignore = false;
|
||||||
} else if (strcasecmp(cfg_obj_asstring(obj), "ignore") == 0) {
|
} else if (strcasecmp(cfg_obj_asstring(obj), "ignore") == 0) {
|
||||||
warn = ignore = true;
|
warn = ignore = true;
|
||||||
} else {
|
} else
|
||||||
INSIST(0);
|
INSIST(0);
|
||||||
ISC_UNREACHABLE();
|
|
||||||
}
|
|
||||||
dns_zone_setoption(mayberaw, DNS_ZONEOPT_WARNMXCNAME, warn);
|
dns_zone_setoption(mayberaw, DNS_ZONEOPT_WARNMXCNAME, warn);
|
||||||
dns_zone_setoption(mayberaw, DNS_ZONEOPT_IGNOREMXCNAME, ignore);
|
dns_zone_setoption(mayberaw, DNS_ZONEOPT_IGNOREMXCNAME, ignore);
|
||||||
|
|
||||||
@@ -1714,10 +1651,8 @@ named_zone_configure(const cfg_obj_t *config, const cfg_obj_t *vconfig,
|
|||||||
warn = ignore = false;
|
warn = ignore = false;
|
||||||
} else if (strcasecmp(cfg_obj_asstring(obj), "ignore") == 0) {
|
} else if (strcasecmp(cfg_obj_asstring(obj), "ignore") == 0) {
|
||||||
warn = ignore = true;
|
warn = ignore = true;
|
||||||
} else {
|
} else
|
||||||
INSIST(0);
|
INSIST(0);
|
||||||
ISC_UNREACHABLE();
|
|
||||||
}
|
|
||||||
dns_zone_setoption(mayberaw, DNS_ZONEOPT_WARNSRVCNAME, warn);
|
dns_zone_setoption(mayberaw, DNS_ZONEOPT_WARNSRVCNAME, warn);
|
||||||
dns_zone_setoption(mayberaw, DNS_ZONEOPT_IGNORESRVCNAME,
|
dns_zone_setoption(mayberaw, DNS_ZONEOPT_IGNORESRVCNAME,
|
||||||
ignore);
|
ignore);
|
||||||
@@ -1733,15 +1668,13 @@ named_zone_configure(const cfg_obj_t *config, const cfg_obj_t *vconfig,
|
|||||||
result = cfg_map_get(zoptions, "dnssec-update-mode", &obj);
|
result = cfg_map_get(zoptions, "dnssec-update-mode", &obj);
|
||||||
if (result == ISC_R_SUCCESS) {
|
if (result == ISC_R_SUCCESS) {
|
||||||
const char *arg = cfg_obj_asstring(obj);
|
const char *arg = cfg_obj_asstring(obj);
|
||||||
if (strcasecmp(arg, "no-resign") == 0) {
|
if (strcasecmp(arg, "no-resign") == 0)
|
||||||
dns_zone_setkeyopt(zone, DNS_ZONEKEY_NORESIGN,
|
dns_zone_setkeyopt(zone, DNS_ZONEKEY_NORESIGN,
|
||||||
true);
|
true);
|
||||||
} else if (strcasecmp(arg, "maintain") == 0) {
|
else if (strcasecmp(arg, "maintain") == 0)
|
||||||
;
|
;
|
||||||
} else {
|
else
|
||||||
INSIST(0);
|
INSIST(0);
|
||||||
ISC_UNREACHABLE();
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
obj = NULL;
|
obj = NULL;
|
||||||
@@ -1762,38 +1695,12 @@ named_zone_configure(const cfg_obj_t *config, const cfg_obj_t *vconfig,
|
|||||||
* Configure slave functionality.
|
* Configure slave functionality.
|
||||||
*/
|
*/
|
||||||
switch (ztype) {
|
switch (ztype) {
|
||||||
case dns_zone_mirror:
|
|
||||||
/*
|
|
||||||
* Disable outgoing zone transfers for mirror zones unless they
|
|
||||||
* are explicitly enabled by zone configuration.
|
|
||||||
*/
|
|
||||||
obj = NULL;
|
|
||||||
(void)cfg_map_get(zoptions, "allow-transfer", &obj);
|
|
||||||
if (obj == NULL) {
|
|
||||||
dns_acl_t *none;
|
|
||||||
RETERR(dns_acl_none(mctx, &none));
|
|
||||||
dns_zone_setxfracl(zone, none);
|
|
||||||
dns_acl_detach(&none);
|
|
||||||
}
|
|
||||||
/* FALLTHROUGH */
|
|
||||||
case dns_zone_slave:
|
case dns_zone_slave:
|
||||||
case dns_zone_stub:
|
case dns_zone_stub:
|
||||||
case dns_zone_redirect:
|
case dns_zone_redirect:
|
||||||
count = 0;
|
count = 0;
|
||||||
obj = NULL;
|
obj = NULL;
|
||||||
(void)cfg_map_get(zoptions, "masters", &obj);
|
(void)cfg_map_get(zoptions, "masters", &obj);
|
||||||
/*
|
|
||||||
* Use the built-in master server list if one was not
|
|
||||||
* explicitly specified and this is a root zone mirror.
|
|
||||||
*/
|
|
||||||
if (obj == NULL && ztype == dns_zone_mirror &&
|
|
||||||
dns_name_equal(dns_zone_getorigin(zone), dns_rootname))
|
|
||||||
{
|
|
||||||
result = named_config_getmastersdef(named_g_config,
|
|
||||||
DEFAULT_IANA_ROOT_ZONE_MASTERS,
|
|
||||||
&obj);
|
|
||||||
RETERR(result);
|
|
||||||
}
|
|
||||||
if (obj != NULL) {
|
if (obj != NULL) {
|
||||||
dns_ipkeylist_t ipkl;
|
dns_ipkeylist_t ipkl;
|
||||||
dns_ipkeylist_init(&ipkl);
|
dns_ipkeylist_init(&ipkl);
|
||||||
@@ -1820,6 +1727,35 @@ named_zone_configure(const cfg_obj_t *config, const cfg_obj_t *vconfig,
|
|||||||
}
|
}
|
||||||
dns_zone_setoption(mayberaw, DNS_ZONEOPT_MULTIMASTER, multi);
|
dns_zone_setoption(mayberaw, DNS_ZONEOPT_MULTIMASTER, multi);
|
||||||
|
|
||||||
|
obj = NULL;
|
||||||
|
(void)cfg_map_get(zoptions, "mirror", &obj);
|
||||||
|
if (obj != NULL) {
|
||||||
|
bool mirror = cfg_obj_asboolean(obj);
|
||||||
|
dns_zone_setoption(mayberaw, DNS_ZONEOPT_MIRROR,
|
||||||
|
mirror);
|
||||||
|
if (mirror) {
|
||||||
|
/*
|
||||||
|
* Disable outgoing zone transfers unless they
|
||||||
|
* are explicitly enabled by zone
|
||||||
|
* configuration.
|
||||||
|
*/
|
||||||
|
obj = NULL;
|
||||||
|
(void)cfg_map_get(zoptions, "allow-transfer",
|
||||||
|
&obj);
|
||||||
|
if (obj == NULL) {
|
||||||
|
dns_acl_t *none;
|
||||||
|
RETERR(dns_acl_none(mctx, &none));
|
||||||
|
dns_zone_setxfracl(zone, none);
|
||||||
|
dns_acl_detach(&none);
|
||||||
|
}
|
||||||
|
/*
|
||||||
|
* Only allow "also-notify".
|
||||||
|
*/
|
||||||
|
notifytype = dns_notifytype_explicit;
|
||||||
|
dns_zone_setnotifytype(zone, notifytype);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
obj = NULL;
|
obj = NULL;
|
||||||
result = named_config_get(maps, "max-transfer-time-in", &obj);
|
result = named_config_get(maps, "max-transfer-time-in", &obj);
|
||||||
INSIST(result == ISC_R_SUCCESS && obj != NULL);
|
INSIST(result == ISC_R_SUCCESS && obj != NULL);
|
||||||
@@ -1959,7 +1895,7 @@ named_zone_reusable(dns_zone_t *zone, const cfg_obj_t *zconfig) {
|
|||||||
const char *cfilename;
|
const char *cfilename;
|
||||||
const char *zfilename;
|
const char *zfilename;
|
||||||
dns_zone_t *raw = NULL;
|
dns_zone_t *raw = NULL;
|
||||||
bool has_raw;
|
bool has_raw, mirror;
|
||||||
dns_zonetype_t ztype;
|
dns_zonetype_t ztype;
|
||||||
|
|
||||||
zoptions = cfg_tuple_get(zconfig, "options");
|
zoptions = cfg_tuple_get(zconfig, "options");
|
||||||
@@ -1999,6 +1935,21 @@ named_zone_reusable(dns_zone_t *zone, const cfg_obj_t *zconfig) {
|
|||||||
return (false);
|
return (false);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/*
|
||||||
|
* Do not reuse a zone whose "mirror" setting was changed.
|
||||||
|
*/
|
||||||
|
obj = NULL;
|
||||||
|
mirror = false;
|
||||||
|
(void)cfg_map_get(zoptions, "mirror", &obj);
|
||||||
|
if (obj != NULL) {
|
||||||
|
mirror = cfg_obj_asboolean(obj);
|
||||||
|
}
|
||||||
|
if (dns_zone_ismirror(zone) != mirror) {
|
||||||
|
dns_zone_log(zone, ISC_LOG_DEBUG(1),
|
||||||
|
"not reusable: mirror setting changed");
|
||||||
|
return (false);
|
||||||
|
}
|
||||||
|
|
||||||
if (zonetype_fromconfig(zoptions) != ztype) {
|
if (zonetype_fromconfig(zoptions) != ztype) {
|
||||||
dns_zone_log(zone, ISC_LOG_DEBUG(1),
|
dns_zone_log(zone, ISC_LOG_DEBUG(1),
|
||||||
"not reusable: type mismatch");
|
"not reusable: type mismatch");
|
||||||
|
|||||||
+3
-13
@@ -144,8 +144,8 @@ static dns_fixedname_t fuserzone;
|
|||||||
static dns_fixedname_t fzname;
|
static dns_fixedname_t fzname;
|
||||||
static dns_name_t *userzone = NULL;
|
static dns_name_t *userzone = NULL;
|
||||||
static dns_name_t *zname = NULL;
|
static dns_name_t *zname = NULL;
|
||||||
static dns_name_t tmpzonename = DNS_NAME_INITEMPTY;
|
static dns_name_t tmpzonename;
|
||||||
static dns_name_t restart_master = DNS_NAME_INITEMPTY;
|
static dns_name_t restart_master;
|
||||||
static dns_tsig_keyring_t *gssring = NULL;
|
static dns_tsig_keyring_t *gssring = NULL;
|
||||||
static dns_tsigkey_t *tsigkey = NULL;
|
static dns_tsigkey_t *tsigkey = NULL;
|
||||||
static dst_key_t *sig0key = NULL;
|
static dst_key_t *sig0key = NULL;
|
||||||
@@ -885,7 +885,7 @@ setup_system(void) {
|
|||||||
result = isc_timermgr_create(gmctx, &timermgr);
|
result = isc_timermgr_create(gmctx, &timermgr);
|
||||||
check_result(result, "dns_timermgr_create");
|
check_result(result, "dns_timermgr_create");
|
||||||
|
|
||||||
result = isc_taskmgr_create(gmctx, 1, &taskmgr);
|
result = isc_taskmgr_create(gmctx, 1, 0, &taskmgr);
|
||||||
check_result(result, "isc_taskmgr_create");
|
check_result(result, "isc_taskmgr_create");
|
||||||
|
|
||||||
result = isc_task_create(taskmgr, 0, &global_task);
|
result = isc_task_create(taskmgr, 0, &global_task);
|
||||||
@@ -2354,8 +2354,6 @@ update_completed(isc_task_t *task, isc_event_t *event) {
|
|||||||
if (usegsstsig) {
|
if (usegsstsig) {
|
||||||
dns_name_free(&tmpzonename, gmctx);
|
dns_name_free(&tmpzonename, gmctx);
|
||||||
dns_name_free(&restart_master, gmctx);
|
dns_name_free(&restart_master, gmctx);
|
||||||
dns_name_init(&tmpzonename, 0);
|
|
||||||
dns_name_init(&restart_master, 0);
|
|
||||||
}
|
}
|
||||||
isc_event_free(&event);
|
isc_event_free(&event);
|
||||||
done_update();
|
done_update();
|
||||||
@@ -2771,8 +2769,6 @@ failed_gssrequest() {
|
|||||||
|
|
||||||
dns_name_free(&tmpzonename, gmctx);
|
dns_name_free(&tmpzonename, gmctx);
|
||||||
dns_name_free(&restart_master, gmctx);
|
dns_name_free(&restart_master, gmctx);
|
||||||
dns_name_init(&tmpzonename, NULL);
|
|
||||||
dns_name_init(&restart_master, NULL);
|
|
||||||
|
|
||||||
done_update();
|
done_update();
|
||||||
}
|
}
|
||||||
@@ -3182,12 +3178,6 @@ cleanup(void) {
|
|||||||
isc_mem_free(gmctx, realm);
|
isc_mem_free(gmctx, realm);
|
||||||
realm = NULL;
|
realm = NULL;
|
||||||
}
|
}
|
||||||
if (dns_name_dynamic(&tmpzonename)) {
|
|
||||||
dns_name_free(&tmpzonename, gmctx);
|
|
||||||
}
|
|
||||||
if (dns_name_dynamic(&restart_master)) {
|
|
||||||
dns_name_free(&restart_master, gmctx);
|
|
||||||
}
|
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
if (sig0key != NULL)
|
if (sig0key != NULL)
|
||||||
|
|||||||
+239
-8
@@ -43,7 +43,7 @@
|
|||||||
* Create a key in the keystore of an HSM
|
* Create a key in the keystore of an HSM
|
||||||
*
|
*
|
||||||
* The calculation of key tag is left to the script
|
* The calculation of key tag is left to the script
|
||||||
* that converts the key into a DNSKEY RR and inserts
|
* that converts the key into a DNSKEY RR and inserts
|
||||||
* it into a zone file.
|
* it into a zone file.
|
||||||
*
|
*
|
||||||
* usage:
|
* usage:
|
||||||
@@ -71,6 +71,7 @@
|
|||||||
|
|
||||||
#include <pk11/pk11.h>
|
#include <pk11/pk11.h>
|
||||||
#include <pk11/result.h>
|
#include <pk11/result.h>
|
||||||
|
#define WANT_DH_PRIMES
|
||||||
#include <pk11/constants.h>
|
#include <pk11/constants.h>
|
||||||
#include <pkcs11/eddsa.h>
|
#include <pkcs11/eddsa.h>
|
||||||
|
|
||||||
@@ -78,10 +79,12 @@
|
|||||||
static CK_BBOOL truevalue = TRUE;
|
static CK_BBOOL truevalue = TRUE;
|
||||||
static CK_BBOOL falsevalue = FALSE;
|
static CK_BBOOL falsevalue = FALSE;
|
||||||
|
|
||||||
/* Key class: RSA, ECC, ECX, or unknown */
|
/* Key class: RSA, ECC, ECX, DSA, DH, or unknown */
|
||||||
typedef enum {
|
typedef enum {
|
||||||
key_unknown,
|
key_unknown,
|
||||||
key_rsa,
|
key_rsa,
|
||||||
|
key_dsa,
|
||||||
|
key_dh,
|
||||||
key_ecc,
|
key_ecc,
|
||||||
key_ecx
|
key_ecx
|
||||||
} key_class_t;
|
} key_class_t;
|
||||||
@@ -149,6 +152,78 @@ static CK_ATTRIBUTE ecc_template[] = {
|
|||||||
{CKA_ID, NULL_PTR, 0}
|
{CKA_ID, NULL_PTR, 0}
|
||||||
};
|
};
|
||||||
|
|
||||||
|
/*
|
||||||
|
* Public key template for DSA keys
|
||||||
|
*/
|
||||||
|
#define DSA_LABEL 0
|
||||||
|
#define DSA_VERIFY 1
|
||||||
|
#define DSA_TOKEN 2
|
||||||
|
#define DSA_PRIVATE 3
|
||||||
|
#define DSA_PRIME 4
|
||||||
|
#define DSA_SUBPRIME 5
|
||||||
|
#define DSA_BASE 6
|
||||||
|
#define DSA_ID 7
|
||||||
|
#define DSA_ATTRS 8
|
||||||
|
static CK_ATTRIBUTE dsa_template[] = {
|
||||||
|
{CKA_LABEL, NULL_PTR, 0},
|
||||||
|
{CKA_VERIFY, &truevalue, sizeof(truevalue)},
|
||||||
|
{CKA_TOKEN, &truevalue, sizeof(truevalue)},
|
||||||
|
{CKA_PRIVATE, &falsevalue, sizeof(falsevalue)},
|
||||||
|
{CKA_PRIME, NULL_PTR, 0},
|
||||||
|
{CKA_SUBPRIME, NULL_PTR, 0},
|
||||||
|
{CKA_BASE, NULL_PTR, 0},
|
||||||
|
{CKA_ID, NULL_PTR, 0}
|
||||||
|
};
|
||||||
|
#define DSA_PARAM_PRIME 0
|
||||||
|
#define DSA_PARAM_SUBPRIME 1
|
||||||
|
#define DSA_PARAM_BASE 2
|
||||||
|
#define DSA_PARAM_ATTRS 3
|
||||||
|
static CK_ATTRIBUTE dsa_param_template[] = {
|
||||||
|
{CKA_PRIME, NULL_PTR, 0},
|
||||||
|
{CKA_SUBPRIME, NULL_PTR, 0},
|
||||||
|
{CKA_BASE, NULL_PTR, 0},
|
||||||
|
};
|
||||||
|
#define DSA_DOMAIN_PRIMEBITS 0
|
||||||
|
#define DSA_DOMAIN_PRIVATE 1
|
||||||
|
#define DSA_DOMAIN_ATTRS 2
|
||||||
|
static CK_ATTRIBUTE dsa_domain_template[] = {
|
||||||
|
{CKA_PRIME_BITS, NULL_PTR, 0},
|
||||||
|
{CKA_PRIVATE, &falsevalue, sizeof(falsevalue)},
|
||||||
|
};
|
||||||
|
|
||||||
|
/*
|
||||||
|
* Public key template for DH keys
|
||||||
|
*/
|
||||||
|
#define DH_LABEL 0
|
||||||
|
#define DH_VERIFY 1
|
||||||
|
#define DH_TOKEN 2
|
||||||
|
#define DH_PRIVATE 3
|
||||||
|
#define DH_PRIME 4
|
||||||
|
#define DH_BASE 5
|
||||||
|
#define DH_ID 6
|
||||||
|
#define DH_ATTRS 7
|
||||||
|
static CK_ATTRIBUTE dh_template[] = {
|
||||||
|
{CKA_LABEL, NULL_PTR, 0},
|
||||||
|
{CKA_VERIFY, &truevalue, sizeof(truevalue)},
|
||||||
|
{CKA_TOKEN, &truevalue, sizeof(truevalue)},
|
||||||
|
{CKA_PRIVATE, &falsevalue, sizeof(falsevalue)},
|
||||||
|
{CKA_PRIME, NULL_PTR, 0},
|
||||||
|
{CKA_BASE, NULL_PTR, 0},
|
||||||
|
{CKA_ID, NULL_PTR, 0}
|
||||||
|
};
|
||||||
|
#define DH_PARAM_PRIME 0
|
||||||
|
#define DH_PARAM_BASE 1
|
||||||
|
#define DH_PARAM_ATTRS 2
|
||||||
|
static CK_ATTRIBUTE dh_param_template[] = {
|
||||||
|
{CKA_PRIME, NULL_PTR, 0},
|
||||||
|
{CKA_BASE, NULL_PTR, 0},
|
||||||
|
};
|
||||||
|
#define DH_DOMAIN_PRIMEBITS 0
|
||||||
|
#define DH_DOMAIN_ATTRS 1
|
||||||
|
static CK_ATTRIBUTE dh_domain_template[] = {
|
||||||
|
{CKA_PRIME_BITS, NULL_PTR, 0},
|
||||||
|
};
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* Convert from text to key class. Accepts the names of DNSSEC
|
* Convert from text to key class. Accepts the names of DNSSEC
|
||||||
* signing algorithms, so e.g., ECDSAP256SHA256 maps to ECC and
|
* signing algorithms, so e.g., ECDSAP256SHA256 maps to ECC and
|
||||||
@@ -162,6 +237,11 @@ keyclass_fromtext(const char *name) {
|
|||||||
if (strncasecmp(name, "rsa", 3) == 0 ||
|
if (strncasecmp(name, "rsa", 3) == 0 ||
|
||||||
strncasecmp(name, "nsec3rsa", 8) == 0)
|
strncasecmp(name, "nsec3rsa", 8) == 0)
|
||||||
return (key_rsa);
|
return (key_rsa);
|
||||||
|
else if (strncasecmp(name, "dsa", 3) == 0 ||
|
||||||
|
strncasecmp(name, "nsec3dsa", 8) == 0)
|
||||||
|
return (key_dsa);
|
||||||
|
else if (strcasecmp(name, "dh") == 0)
|
||||||
|
return (key_dh);
|
||||||
else if (strncasecmp(name, "ecc", 3) == 0 ||
|
else if (strncasecmp(name, "ecc", 3) == 0 ||
|
||||||
strncasecmp(name, "ecdsa", 5) == 0)
|
strncasecmp(name, "ecdsa", 5) == 0)
|
||||||
return (key_ecc);
|
return (key_ecc);
|
||||||
@@ -199,7 +279,7 @@ main(int argc, char *argv[]) {
|
|||||||
pk11_context_t pctx;
|
pk11_context_t pctx;
|
||||||
int error = 0;
|
int error = 0;
|
||||||
int c, errflg = 0;
|
int c, errflg = 0;
|
||||||
int hide = 1, quiet = 0;
|
int hide = 1, special = 0, quiet = 0;
|
||||||
int idlen = 0, id_offset = 0;
|
int idlen = 0, id_offset = 0;
|
||||||
unsigned int i;
|
unsigned int i;
|
||||||
unsigned long id = 0;
|
unsigned long id = 0;
|
||||||
@@ -251,6 +331,9 @@ main(int argc, char *argv[]) {
|
|||||||
case 'q':
|
case 'q':
|
||||||
quiet = 1;
|
quiet = 1;
|
||||||
break;
|
break;
|
||||||
|
case 'S':
|
||||||
|
special = 1;
|
||||||
|
break;
|
||||||
case ':':
|
case ':':
|
||||||
fprintf(stderr,
|
fprintf(stderr,
|
||||||
"Option -%c requires an operand\n",
|
"Option -%c requires an operand\n",
|
||||||
@@ -277,6 +360,12 @@ main(int argc, char *argv[]) {
|
|||||||
exit(2);
|
exit(2);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (special != 0 && keyclass != key_dh) {
|
||||||
|
fprintf(stderr, "The -S option is only compatible "
|
||||||
|
"with Diffie-Hellman key generation\n");
|
||||||
|
exit(2);
|
||||||
|
}
|
||||||
|
|
||||||
switch (keyclass) {
|
switch (keyclass) {
|
||||||
case key_rsa:
|
case key_rsa:
|
||||||
op_type = OP_RSA;
|
op_type = OP_RSA;
|
||||||
@@ -372,10 +461,70 @@ main(int argc, char *argv[]) {
|
|||||||
|
|
||||||
#endif
|
#endif
|
||||||
break;
|
break;
|
||||||
|
case key_dsa:
|
||||||
|
op_type = OP_DSA;
|
||||||
|
if (bits == 0)
|
||||||
|
usage();
|
||||||
|
|
||||||
|
dpmech.mechanism = CKM_DSA_PARAMETER_GEN;
|
||||||
|
dpmech.pParameter = NULL;
|
||||||
|
dpmech.ulParameterLen = 0;
|
||||||
|
mech.mechanism = CKM_DSA_KEY_PAIR_GEN;
|
||||||
|
mech.pParameter = NULL;
|
||||||
|
mech.ulParameterLen = 0;
|
||||||
|
|
||||||
|
public_template = dsa_template;
|
||||||
|
public_attrcnt = DSA_ATTRS;
|
||||||
|
id_offset = DSA_ID;
|
||||||
|
|
||||||
|
domain_template = dsa_domain_template;
|
||||||
|
domain_attrcnt = DSA_DOMAIN_ATTRS;
|
||||||
|
param_template = dsa_param_template;
|
||||||
|
param_attrcnt = DSA_PARAM_ATTRS;
|
||||||
|
|
||||||
|
domain_template[DSA_DOMAIN_PRIMEBITS].pValue = &bits;
|
||||||
|
domain_template[DSA_DOMAIN_PRIMEBITS].ulValueLen = sizeof(bits);
|
||||||
|
break;
|
||||||
|
case key_dh:
|
||||||
|
op_type = OP_DH;
|
||||||
|
if (special && bits == 0)
|
||||||
|
bits = 1024;
|
||||||
|
else if (special &&
|
||||||
|
bits != 768 && bits != 1024 && bits != 1536)
|
||||||
|
{
|
||||||
|
fprintf(stderr, "When using the special prime (-S) "
|
||||||
|
"option, only key sizes of\n"
|
||||||
|
"768, 1024 or 1536 are supported.\n");
|
||||||
|
exit(2);
|
||||||
|
} else if (bits == 0)
|
||||||
|
usage();
|
||||||
|
|
||||||
|
dpmech.mechanism = CKM_DH_PKCS_PARAMETER_GEN;
|
||||||
|
dpmech.pParameter = NULL;
|
||||||
|
dpmech.ulParameterLen = 0;
|
||||||
|
mech.mechanism = CKM_DH_PKCS_KEY_PAIR_GEN;
|
||||||
|
mech.pParameter = NULL;
|
||||||
|
mech.ulParameterLen = 0;
|
||||||
|
|
||||||
|
/* Override CKA_SIGN attribute */
|
||||||
|
private_template[PRIVATE_DERIVE].type = CKA_DERIVE;
|
||||||
|
|
||||||
|
public_template = dh_template;
|
||||||
|
public_attrcnt = DH_ATTRS;
|
||||||
|
id_offset = DH_ID;
|
||||||
|
|
||||||
|
domain_template = dh_domain_template;
|
||||||
|
domain_attrcnt = DH_DOMAIN_ATTRS;
|
||||||
|
param_template = dh_param_template;
|
||||||
|
param_attrcnt = DH_PARAM_ATTRS;
|
||||||
|
|
||||||
|
domain_template[DH_DOMAIN_PRIMEBITS].pValue = &bits;
|
||||||
|
domain_template[DH_DOMAIN_PRIMEBITS].ulValueLen = sizeof(bits);
|
||||||
|
break;
|
||||||
case key_unknown:
|
case key_unknown:
|
||||||
usage();
|
usage();
|
||||||
}
|
}
|
||||||
|
|
||||||
search_template[0].pValue = label;
|
search_template[0].pValue = label;
|
||||||
search_template[0].ulValueLen = strlen((char *)label);
|
search_template[0].ulValueLen = strlen((char *)label);
|
||||||
public_template[0].pValue = label;
|
public_template[0].pValue = label;
|
||||||
@@ -433,7 +582,7 @@ main(int argc, char *argv[]) {
|
|||||||
hSession = pctx.session;
|
hSession = pctx.session;
|
||||||
|
|
||||||
/* check if a key with the same id already exists */
|
/* check if a key with the same id already exists */
|
||||||
rv = pkcs_C_FindObjectsInit(hSession, search_template, 1);
|
rv = pkcs_C_FindObjectsInit(hSession, search_template, 1);
|
||||||
if (rv != CKR_OK) {
|
if (rv != CKR_OK) {
|
||||||
fprintf(stderr, "C_FindObjectsInit: Error = 0x%.8lX\n", rv);
|
fprintf(stderr, "C_FindObjectsInit: Error = 0x%.8lX\n", rv);
|
||||||
error = 1;
|
error = 1;
|
||||||
@@ -460,6 +609,29 @@ main(int argc, char *argv[]) {
|
|||||||
if (keyclass == key_rsa || keyclass == key_ecc || keyclass == key_ecx)
|
if (keyclass == key_rsa || keyclass == key_ecc || keyclass == key_ecx)
|
||||||
goto generate_keys;
|
goto generate_keys;
|
||||||
|
|
||||||
|
/*
|
||||||
|
* Special setup for Diffie-Hellman keys
|
||||||
|
*/
|
||||||
|
if (special != 0) {
|
||||||
|
public_template[DH_BASE].pValue = pk11_dh_bn2;
|
||||||
|
public_template[DH_BASE].ulValueLen = sizeof(pk11_dh_bn2);
|
||||||
|
if (bits == 768) {
|
||||||
|
public_template[DH_PRIME].pValue = pk11_dh_bn768;
|
||||||
|
public_template[DH_PRIME].ulValueLen =
|
||||||
|
sizeof(pk11_dh_bn768);
|
||||||
|
} else if (bits == 1024) {
|
||||||
|
public_template[DH_PRIME].pValue = pk11_dh_bn1024;
|
||||||
|
public_template[DH_PRIME].ulValueLen =
|
||||||
|
sizeof(pk11_dh_bn1024);
|
||||||
|
} else {
|
||||||
|
public_template[DH_PRIME].pValue = pk11_dh_bn1536;
|
||||||
|
public_template[DH_PRIME].ulValueLen =
|
||||||
|
sizeof(pk11_dh_bn1536);
|
||||||
|
}
|
||||||
|
param_attrcnt = 0;
|
||||||
|
goto generate_keys;
|
||||||
|
}
|
||||||
|
|
||||||
/* Generate Domain parameters */
|
/* Generate Domain parameters */
|
||||||
rv = pkcs_C_GenerateKey(hSession, &dpmech, domain_template,
|
rv = pkcs_C_GenerateKey(hSession, &dpmech, domain_template,
|
||||||
domain_attrcnt, &domainparams);
|
domain_attrcnt, &domainparams);
|
||||||
@@ -479,7 +651,7 @@ main(int argc, char *argv[]) {
|
|||||||
fprintf(stderr,
|
fprintf(stderr,
|
||||||
"C_GetAttributeValue0: Error = 0x%.8lX\n", rv);
|
"C_GetAttributeValue0: Error = 0x%.8lX\n", rv);
|
||||||
error = 1;
|
error = 1;
|
||||||
goto exit_search;
|
goto exit_domain;
|
||||||
}
|
}
|
||||||
|
|
||||||
/* Allocate space for parameter attributes */
|
/* Allocate space for parameter attributes */
|
||||||
@@ -492,22 +664,81 @@ main(int argc, char *argv[]) {
|
|||||||
if (param_template[i].pValue == NULL) {
|
if (param_template[i].pValue == NULL) {
|
||||||
fprintf(stderr, "malloc failed\n");
|
fprintf(stderr, "malloc failed\n");
|
||||||
error = 1;
|
error = 1;
|
||||||
goto exit_search;
|
goto exit_params;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
rv = pkcs_C_GetAttributeValue(hSession, domainparams,
|
||||||
|
dsa_param_template, DSA_PARAM_ATTRS);
|
||||||
|
|
||||||
|
if (rv != CKR_OK) {
|
||||||
|
fprintf(stderr,
|
||||||
|
"C_GetAttributeValue1: Error = 0x%.8lX\n", rv);
|
||||||
|
error = 1;
|
||||||
|
goto exit_params;
|
||||||
|
}
|
||||||
|
|
||||||
|
switch (keyclass) {
|
||||||
|
case key_dsa:
|
||||||
|
public_template[DSA_PRIME].pValue =
|
||||||
|
param_template[DSA_PARAM_PRIME].pValue;
|
||||||
|
public_template[DSA_PRIME].ulValueLen =
|
||||||
|
param_template[DSA_PARAM_PRIME].ulValueLen;
|
||||||
|
public_template[DSA_SUBPRIME].pValue =
|
||||||
|
param_template[DSA_PARAM_SUBPRIME].pValue;
|
||||||
|
public_template[DSA_SUBPRIME].ulValueLen =
|
||||||
|
param_template[DSA_PARAM_SUBPRIME].ulValueLen;
|
||||||
|
public_template[DSA_BASE].pValue =
|
||||||
|
param_template[DSA_PARAM_BASE].pValue;
|
||||||
|
public_template[DSA_BASE].ulValueLen =
|
||||||
|
param_template[DSA_PARAM_BASE].ulValueLen;
|
||||||
|
break;
|
||||||
|
case key_dh:
|
||||||
|
public_template[DH_PRIME].pValue =
|
||||||
|
param_template[DH_PARAM_PRIME].pValue;
|
||||||
|
public_template[DH_PRIME].ulValueLen =
|
||||||
|
param_template[DH_PARAM_PRIME].ulValueLen;
|
||||||
|
public_template[DH_BASE].pValue =
|
||||||
|
param_template[DH_PARAM_BASE].pValue;
|
||||||
|
public_template[DH_BASE].ulValueLen =
|
||||||
|
param_template[DH_PARAM_BASE].ulValueLen;
|
||||||
|
default:
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
|
||||||
generate_keys:
|
generate_keys:
|
||||||
/* Generate Key pair for signing/verifying */
|
/* Generate Key pair for signing/verifying */
|
||||||
rv = pkcs_C_GenerateKeyPair(hSession, &mech,
|
rv = pkcs_C_GenerateKeyPair(hSession, &mech,
|
||||||
public_template, public_attrcnt,
|
public_template, public_attrcnt,
|
||||||
private_template, private_attrcnt,
|
private_template, private_attrcnt,
|
||||||
&publickey, &privatekey);
|
&publickey, &privatekey);
|
||||||
|
|
||||||
if (rv != CKR_OK) {
|
if (rv != CKR_OK) {
|
||||||
fprintf(stderr, "C_GenerateKeyPair: Error = 0x%.8lX\n", rv);
|
fprintf(stderr, "C_GenerateKeyPair: Error = 0x%.8lX\n", rv);
|
||||||
error = 1;
|
error = 1;
|
||||||
} else if (!quiet)
|
} else if (!quiet)
|
||||||
printf("Key pair generation complete.\n");
|
printf("Key pair generation complete.\n");
|
||||||
|
|
||||||
|
exit_params:
|
||||||
|
/* Free parameter attributes */
|
||||||
|
if (keyclass == key_dsa || keyclass == key_dh) {
|
||||||
|
for (i = 0; i < param_attrcnt; i++) {
|
||||||
|
if (param_template[i].pValue != NULL) {
|
||||||
|
free(param_template[i].pValue);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
exit_domain:
|
||||||
|
/* Destroy domain parameters */
|
||||||
|
if (keyclass == key_dsa || (keyclass == key_dh && !special)) {
|
||||||
|
rv = pkcs_C_DestroyObject(hSession, domainparams);
|
||||||
|
if (rv != CKR_OK) {
|
||||||
|
fprintf(stderr,
|
||||||
|
"C_DestroyObject: Error = 0x%.8lX\n", rv);
|
||||||
|
error = 1;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
exit_search:
|
exit_search:
|
||||||
rv = pkcs_C_FindObjectsFinal(hSession);
|
rv = pkcs_C_FindObjectsFinal(hSession);
|
||||||
|
|||||||
@@ -215,7 +215,7 @@ Specifies the directory in which keys should be stored\&.
|
|||||||
.PP
|
.PP
|
||||||
\fBkey\-size\fR
|
\fBkey\-size\fR
|
||||||
.RS 4
|
.RS 4
|
||||||
Specifies the number of bits to use in creating keys\&. Takes two arguments: keytype (eihter "zsk" or "ksk") and size\&. A default value for this option can be set in algorithm policies as well as in policy classes or zone policies\&. If no policy is configured, the default is 2048 bits for RSA keys\&.
|
Specifies the number of bits to use in creating keys\&. Takes two arguments: keytype (eihter "zsk" or "ksk") and size\&. A default value for this option can be set in algorithm policies as well as in policy classes or zone policies\&. If no policy is configured, the default is 1024 bits for DSA keys and 2048 for RSA\&.
|
||||||
.RE
|
.RE
|
||||||
.PP
|
.PP
|
||||||
\fBkeyttl\fR
|
\fBkeyttl\fR
|
||||||
|
|||||||
@@ -299,7 +299,8 @@
|
|||||||
Takes two arguments: keytype (eihter "zsk" or "ksk") and size.
|
Takes two arguments: keytype (eihter "zsk" or "ksk") and size.
|
||||||
A default value for this option can be set in algorithm policies
|
A default value for this option can be set in algorithm policies
|
||||||
as well as in policy classes or zone policies. If no policy is
|
as well as in policy classes or zone policies. If no policy is
|
||||||
configured, the default is 2048 bits for RSA keys.
|
configured, the default is 1024 bits for DSA keys and 2048 for
|
||||||
|
RSA.
|
||||||
</para>
|
</para>
|
||||||
</listitem>
|
</listitem>
|
||||||
</varlistentry>
|
</varlistentry>
|
||||||
|
|||||||
@@ -258,7 +258,8 @@
|
|||||||
Takes two arguments: keytype (eihter "zsk" or "ksk") and size.
|
Takes two arguments: keytype (eihter "zsk" or "ksk") and size.
|
||||||
A default value for this option can be set in algorithm policies
|
A default value for this option can be set in algorithm policies
|
||||||
as well as in policy classes or zone policies. If no policy is
|
as well as in policy classes or zone policies. If no policy is
|
||||||
configured, the default is 2048 bits for RSA keys.
|
configured, the default is 1024 bits for DSA keys and 2048 for
|
||||||
|
RSA.
|
||||||
</p>
|
</p>
|
||||||
</dd>
|
</dd>
|
||||||
<dt><span class="term"><span class="command"><strong>keyttl</strong></span></span></dt>
|
<dt><span class="term"><span class="command"><strong>keyttl</strong></span></span></dt>
|
||||||
|
|||||||
@@ -30,9 +30,9 @@ class dnskey:
|
|||||||
'Revoke', 'DSPublish', 'SyncPublish', 'SyncDelete')
|
'Revoke', 'DSPublish', 'SyncPublish', 'SyncDelete')
|
||||||
_OPTS = (None, '-P', '-A', '-I', '-D', '-R', None, '-Psync', '-Dsync')
|
_OPTS = (None, '-P', '-A', '-I', '-D', '-R', None, '-Psync', '-Dsync')
|
||||||
|
|
||||||
_ALGNAMES = (None, 'RSAMD5', 'DH', 'DSA', None, 'RSASHA1',
|
_ALGNAMES = (None, 'RSAMD5', 'DH', 'DSA', 'ECC', 'RSASHA1',
|
||||||
'NSEC3DSA', 'NSEC3RSASHA1', 'RSASHA256', None,
|
'NSEC3DSA', 'NSEC3RSASHA1', 'RSASHA256', None,
|
||||||
'RSASHA512', None, 'ECCGOST', 'ECDSAP256SHA256',
|
'RSASHA512', None, None, 'ECDSAP256SHA256',
|
||||||
'ECDSAP384SHA384', 'ED25519', 'ED448')
|
'ECDSAP384SHA384', 'ED25519', 'ED448')
|
||||||
|
|
||||||
def __init__(self, key, directory=None, keyttl=None):
|
def __init__(self, key, directory=None, keyttl=None):
|
||||||
|
|||||||
@@ -71,7 +71,7 @@ class PolicyLex:
|
|||||||
return t
|
return t
|
||||||
|
|
||||||
def t_ALGNAME(self, t):
|
def t_ALGNAME(self, t):
|
||||||
r'(?i)\b(RSAMD5|DH|ECC|RSASHA1|NSEC3RSASHA1|RSASHA256|RSASHA512|ECDSAP256SHA256|ECDSAP384SHA384|ED25519|ED448)\b'
|
r'(?i)\b(RSAMD5|DH|DSA|NSEC3DSA|ECC|RSASHA1|NSEC3RSASHA1|RSASHA256|RSASHA512|ECDSAP256SHA256|ECDSAP384SHA384|ED25519|ED448)\b'
|
||||||
t.value = t.value.upper()
|
t.value = t.value.upper()
|
||||||
return t
|
return t
|
||||||
|
|
||||||
@@ -132,7 +132,9 @@ class Policy:
|
|||||||
keyttl = None
|
keyttl = None
|
||||||
coverage = None
|
coverage = None
|
||||||
directory = None
|
directory = None
|
||||||
valid_key_sz_per_algo = {'RSAMD5': [1024, 4096],
|
valid_key_sz_per_algo = {'DSA': [512, 1024],
|
||||||
|
'NSEC3DSA': [512, 1024],
|
||||||
|
'RSAMD5': [1024, 4096],
|
||||||
'RSASHA1': [1024, 4096],
|
'RSASHA1': [1024, 4096],
|
||||||
'NSEC3RSASHA1': [512, 4096],
|
'NSEC3RSASHA1': [512, 4096],
|
||||||
'RSASHA256': [1024, 4096],
|
'RSASHA256': [1024, 4096],
|
||||||
@@ -262,6 +264,19 @@ class Policy:
|
|||||||
return False, 'ZSK key size %d outside valid range %s' \
|
return False, 'ZSK key size %d outside valid range %s' \
|
||||||
% (self.zsk_keysize, key_sz_range)
|
% (self.zsk_keysize, key_sz_range)
|
||||||
|
|
||||||
|
# Specific check for DSA keys
|
||||||
|
if self.algorithm in ['DSA', 'NSEC3DSA'] and \
|
||||||
|
self.ksk_keysize % 64 != 0:
|
||||||
|
return False, \
|
||||||
|
('KSK key size %d not divisible by 64 ' +
|
||||||
|
'as required for DSA') % self.ksk_keysize
|
||||||
|
|
||||||
|
if self.algorithm in ['DSA', 'NSEC3DSA'] and \
|
||||||
|
self.zsk_keysize % 64 != 0:
|
||||||
|
return False, \
|
||||||
|
('ZSK key size %d not divisible by 64 ' +
|
||||||
|
'as required for DSA') % self.zsk_keysize
|
||||||
|
|
||||||
if self.algorithm in ['ECDSAP256SHA256', \
|
if self.algorithm in ['ECDSAP256SHA256', \
|
||||||
'ECDSAP384SHA384', \
|
'ECDSAP384SHA384', \
|
||||||
'ED25519', \
|
'ED25519', \
|
||||||
@@ -320,6 +335,16 @@ class dnssec_policy:
|
|||||||
p.zsk_keysize = 2048;
|
p.zsk_keysize = 2048;
|
||||||
|
|
||||||
# set default algorithm policies
|
# set default algorithm policies
|
||||||
|
# these need a lower default key size:
|
||||||
|
self.alg_policy['DSA'] = copy(p)
|
||||||
|
self.alg_policy['DSA'].algorithm = "DSA"
|
||||||
|
self.alg_policy['DSA'].name = "DSA"
|
||||||
|
self.alg_policy['DSA'].ksk_keysize = 1024;
|
||||||
|
|
||||||
|
self.alg_policy['NSEC3DSA'] = copy(p)
|
||||||
|
self.alg_policy['NSEC3DSA'].algorithm = "NSEC3DSA"
|
||||||
|
self.alg_policy['NSEC3DSA'].name = "NSEC3DSA"
|
||||||
|
self.alg_policy['NSEC3DSA'].ksk_keysize = 1024;
|
||||||
|
|
||||||
# these can use default settings
|
# these can use default settings
|
||||||
self.alg_policy['RSAMD5'] = copy(p)
|
self.alg_policy['RSAMD5'] = copy(p)
|
||||||
|
|||||||
@@ -25,6 +25,15 @@ class PolicyTest(unittest.TestCase):
|
|||||||
self.assertEqual(p.constructed(), False)
|
self.assertEqual(p.constructed(), False)
|
||||||
self.assertEqual(p.validate(), (True, ""))
|
self.assertEqual(p.validate(), (True, ""))
|
||||||
|
|
||||||
|
p = pol.policy('good_dsa.test', novalidate=True)
|
||||||
|
self.assertEqual(p.get_name(), "good_dsa.test")
|
||||||
|
self.assertEqual(p.constructed(), False)
|
||||||
|
self.assertEqual(p.validate(), (True, ""))
|
||||||
|
|
||||||
|
p = pol.policy('bad_dsa.test', novalidate=True)
|
||||||
|
self.assertEqual(p.validate(),
|
||||||
|
(False, 'ZSK key size 769 not divisible by 64 as required for DSA'))
|
||||||
|
|
||||||
def test_prepublish(self):
|
def test_prepublish(self):
|
||||||
pol = policy.dnssec_policy()
|
pol = policy.dnssec_policy()
|
||||||
pol.load('test-policies/02-prepublish.pol')
|
pol.load('test-policies/02-prepublish.pol')
|
||||||
|
|||||||
+9
-17
@@ -386,7 +386,7 @@ See also
|
|||||||
\fBrndc trace\fR\&.
|
\fBrndc trace\fR\&.
|
||||||
.RE
|
.RE
|
||||||
.PP
|
.PP
|
||||||
\fBnta \fR\fB[( \-class \fIclass\fR | \-dump | \-force | \-remove | \-lifetime \fIduration\fR)]\fR\fB \fR\fB\fIdomain\fR\fR\fB \fR\fB[\fIview\fR]\fR\fB \fR
|
\fBnta \fR\fB[( \-d | \-f | \-r | \-l \fIduration\fR)]\fR\fB \fR\fB\fIdomain\fR\fR\fB \fR\fB[\fIview\fR]\fR\fB \fR
|
||||||
.RS 4
|
.RS 4
|
||||||
Sets a DNSSEC negative trust anchor (NTA) for
|
Sets a DNSSEC negative trust anchor (NTA) for
|
||||||
\fBdomain\fR, with a lifetime of
|
\fBdomain\fR, with a lifetime of
|
||||||
@@ -418,7 +418,7 @@ option\&. TTL\-style suffixes can be used to specify the lifetime in seconds, mi
|
|||||||
to zero is equivalent to
|
to zero is equivalent to
|
||||||
\fB\-remove\fR\&.
|
\fB\-remove\fR\&.
|
||||||
.sp
|
.sp
|
||||||
If the
|
If
|
||||||
\fB\-dump\fR
|
\fB\-dump\fR
|
||||||
is used, any other arguments are ignored, and a list of existing NTAs is printed (note that this may include NTAs that are expired but have not yet been cleaned up)\&.
|
is used, any other arguments are ignored, and a list of existing NTAs is printed (note that this may include NTAs that are expired but have not yet been cleaned up)\&.
|
||||||
.sp
|
.sp
|
||||||
@@ -430,18 +430,11 @@ option in the Administrator Reference Manual for details)\&. If data can be vali
|
|||||||
\fB\-force\fR
|
\fB\-force\fR
|
||||||
overrides this behavior and forces an NTA to persist for its entire lifetime, regardless of whether data could be validated if the NTA were not present\&.
|
overrides this behavior and forces an NTA to persist for its entire lifetime, regardless of whether data could be validated if the NTA were not present\&.
|
||||||
.sp
|
.sp
|
||||||
The view class can be specified with
|
|
||||||
\fB\-class\fR\&. The default is class
|
|
||||||
\fBIN\fR, which is the only class for which DNSSEC is currently supported\&.
|
|
||||||
.sp
|
|
||||||
All of these options can be shortened, i\&.e\&., to
|
All of these options can be shortened, i\&.e\&., to
|
||||||
\fB\-l\fR,
|
\fB\-l\fR,
|
||||||
\fB\-r\fR,
|
\fB\-r\fR,
|
||||||
\fB\-d\fR,
|
\fB\-d\fR, and
|
||||||
\fB\-f\fR, and
|
\fB\-f\fR\&.
|
||||||
\fB\-c\fR\&.
|
|
||||||
.sp
|
|
||||||
Unrecognized options are treated as errors\&. To reference a domain or view name that begins with a hyphen, use a double\-hyphen on the command line to indicate the end of options\&.
|
|
||||||
.RE
|
.RE
|
||||||
.PP
|
.PP
|
||||||
\fBquerylog\fR [ on | off ]
|
\fBquerylog\fR [ on | off ]
|
||||||
@@ -702,14 +695,13 @@ in each view\&. The list both statically configured keys and dynamic TKEY\-negot
|
|||||||
.PP
|
.PP
|
||||||
\fBvalidation ( on | off | status ) \fR\fB[\fIview \&.\&.\&.\fR]\fR\fB \fR
|
\fBvalidation ( on | off | status ) \fR\fB[\fIview \&.\&.\&.\fR]\fR\fB \fR
|
||||||
.RS 4
|
.RS 4
|
||||||
Enable, disable, or check the current status of DNSSEC validation\&. By default, validation is enabled\&. (Note that
|
Enable, disable, or check the current status of DNSSEC validation\&. Note
|
||||||
\fBdnssec\-enable\fR
|
\fBdnssec\-enable\fR
|
||||||
must also be
|
also needs to be set to
|
||||||
\fByes\fR
|
\fByes\fR
|
||||||
(the default value) for signatures to be returned along with validated data\&. If validation is enabled while
|
or
|
||||||
\fBdnssec\-enable\fR
|
\fBauto\fR
|
||||||
is set to
|
to be effective\&. It defaults to enabled\&.
|
||||||
\fBno\fR, the server will validate internally, but will not supply clients with the necessary records to allow validity to be confirmed\&.)
|
|
||||||
.RE
|
.RE
|
||||||
.PP
|
.PP
|
||||||
\fBzonestatus \fR\fB\fIzone\fR\fR\fB \fR\fB[\fIclass\fR [\fIview\fR]]\fR
|
\fBzonestatus \fR\fB\fIzone\fR\fR\fB \fR\fB[\fIclass\fR [\fIview\fR]]\fR
|
||||||
|
|||||||
+1
-1
@@ -934,7 +934,7 @@ main(int argc, char **argv) {
|
|||||||
|
|
||||||
DO("create memory context", isc_mem_create(0, 0, &rndc_mctx));
|
DO("create memory context", isc_mem_create(0, 0, &rndc_mctx));
|
||||||
DO("create socket manager", isc_socketmgr_create(rndc_mctx, &socketmgr));
|
DO("create socket manager", isc_socketmgr_create(rndc_mctx, &socketmgr));
|
||||||
DO("create task manager", isc_taskmgr_create(rndc_mctx, 1, &taskmgr));
|
DO("create task manager", isc_taskmgr_create(rndc_mctx, 1, 0, &taskmgr));
|
||||||
DO("create task", isc_task_create(taskmgr, 0, &task));
|
DO("create task", isc_task_create(taskmgr, 0, &task));
|
||||||
|
|
||||||
DO("create logging context", isc_log_create(rndc_mctx, &log, &logconfig));
|
DO("create logging context", isc_log_create(rndc_mctx, &log, &logconfig));
|
||||||
|
|||||||
+8
-22
@@ -575,7 +575,7 @@
|
|||||||
|
|
||||||
<varlistentry>
|
<varlistentry>
|
||||||
<term><userinput>nta
|
<term><userinput>nta
|
||||||
<optional>( -class <replaceable>class</replaceable> | -dump | -force | -remove | -lifetime <replaceable>duration</replaceable>)</optional>
|
<optional>( -d | -f | -r | -l <replaceable>duration</replaceable>)</optional>
|
||||||
<replaceable>domain</replaceable>
|
<replaceable>domain</replaceable>
|
||||||
<optional><replaceable>view</replaceable></optional>
|
<optional><replaceable>view</replaceable></optional>
|
||||||
</userinput></term>
|
</userinput></term>
|
||||||
@@ -623,7 +623,7 @@
|
|||||||
is equivalent to <option>-remove</option>.
|
is equivalent to <option>-remove</option>.
|
||||||
</para>
|
</para>
|
||||||
<para>
|
<para>
|
||||||
If the <option>-dump</option> is used, any other arguments
|
If <option>-dump</option> is used, any other arguments
|
||||||
are ignored, and a list of existing NTAs is printed
|
are ignored, and a list of existing NTAs is printed
|
||||||
(note that this may include NTAs that are expired but
|
(note that this may include NTAs that are expired but
|
||||||
have not yet been cleaned up).
|
have not yet been cleaned up).
|
||||||
@@ -640,21 +640,10 @@
|
|||||||
lifetime, regardless of whether data could be
|
lifetime, regardless of whether data could be
|
||||||
validated if the NTA were not present.
|
validated if the NTA were not present.
|
||||||
</para>
|
</para>
|
||||||
<para>
|
|
||||||
The view class can be specified with <option>-class</option>.
|
|
||||||
The default is class <userinput>IN</userinput>, which is
|
|
||||||
the only class for which DNSSEC is currently supported.
|
|
||||||
</para>
|
|
||||||
<para>
|
<para>
|
||||||
All of these options can be shortened, i.e., to
|
All of these options can be shortened, i.e., to
|
||||||
<option>-l</option>, <option>-r</option>, <option>-d</option>,
|
<option>-l</option>, <option>-r</option>, <option>-d</option>,
|
||||||
<option>-f</option>, and <option>-c</option>.
|
and <option>-f</option>.
|
||||||
</para>
|
|
||||||
<para>
|
|
||||||
Unrecognized options are treated as errors. To reference
|
|
||||||
a domain or view name that begins with a hyphen,
|
|
||||||
use a double-hyphen on the command line to indicate the
|
|
||||||
end of options.
|
|
||||||
</para>
|
</para>
|
||||||
</listitem>
|
</listitem>
|
||||||
</varlistentry>
|
</varlistentry>
|
||||||
@@ -1076,14 +1065,11 @@
|
|||||||
<listitem>
|
<listitem>
|
||||||
<para>
|
<para>
|
||||||
Enable, disable, or check the current status of
|
Enable, disable, or check the current status of
|
||||||
DNSSEC validation. By default, validation is enabled.
|
DNSSEC validation.
|
||||||
(Note that <command>dnssec-enable</command> must also be
|
Note <command>dnssec-enable</command> also needs to be
|
||||||
<userinput>yes</userinput> (the default value) for signatures
|
set to <userinput>yes</userinput> or
|
||||||
to be returned along with validated data. If validation is
|
<userinput>auto</userinput> to be effective.
|
||||||
enabled while <command>dnssec-enable</command> is set to
|
It defaults to enabled.
|
||||||
<userinput>no</userinput>, the server will validate internally,
|
|
||||||
but will not supply clients with the necessary records to allow
|
|
||||||
validity to be confirmed.)
|
|
||||||
</para>
|
</para>
|
||||||
</listitem>
|
</listitem>
|
||||||
</varlistentry>
|
</varlistentry>
|
||||||
|
|||||||
+8
-22
@@ -484,7 +484,7 @@
|
|||||||
</p>
|
</p>
|
||||||
</dd>
|
</dd>
|
||||||
<dt><span class="term"><strong class="userinput"><code>nta
|
<dt><span class="term"><strong class="userinput"><code>nta
|
||||||
[<span class="optional">( -class <em class="replaceable"><code>class</code></em> | -dump | -force | -remove | -lifetime <em class="replaceable"><code>duration</code></em>)</span>]
|
[<span class="optional">( -d | -f | -r | -l <em class="replaceable"><code>duration</code></em>)</span>]
|
||||||
<em class="replaceable"><code>domain</code></em>
|
<em class="replaceable"><code>domain</code></em>
|
||||||
[<span class="optional"><em class="replaceable"><code>view</code></em></span>]
|
[<span class="optional"><em class="replaceable"><code>view</code></em></span>]
|
||||||
</code></strong></span></dt>
|
</code></strong></span></dt>
|
||||||
@@ -532,7 +532,7 @@
|
|||||||
is equivalent to <code class="option">-remove</code>.
|
is equivalent to <code class="option">-remove</code>.
|
||||||
</p>
|
</p>
|
||||||
<p>
|
<p>
|
||||||
If the <code class="option">-dump</code> is used, any other arguments
|
If <code class="option">-dump</code> is used, any other arguments
|
||||||
are ignored, and a list of existing NTAs is printed
|
are ignored, and a list of existing NTAs is printed
|
||||||
(note that this may include NTAs that are expired but
|
(note that this may include NTAs that are expired but
|
||||||
have not yet been cleaned up).
|
have not yet been cleaned up).
|
||||||
@@ -549,21 +549,10 @@
|
|||||||
lifetime, regardless of whether data could be
|
lifetime, regardless of whether data could be
|
||||||
validated if the NTA were not present.
|
validated if the NTA were not present.
|
||||||
</p>
|
</p>
|
||||||
<p>
|
|
||||||
The view class can be specified with <code class="option">-class</code>.
|
|
||||||
The default is class <strong class="userinput"><code>IN</code></strong>, which is
|
|
||||||
the only class for which DNSSEC is currently supported.
|
|
||||||
</p>
|
|
||||||
<p>
|
<p>
|
||||||
All of these options can be shortened, i.e., to
|
All of these options can be shortened, i.e., to
|
||||||
<code class="option">-l</code>, <code class="option">-r</code>, <code class="option">-d</code>,
|
<code class="option">-l</code>, <code class="option">-r</code>, <code class="option">-d</code>,
|
||||||
<code class="option">-f</code>, and <code class="option">-c</code>.
|
and <code class="option">-f</code>.
|
||||||
</p>
|
|
||||||
<p>
|
|
||||||
Unrecognized options are treated as errors. To reference
|
|
||||||
a domain or view name that begins with a hyphen,
|
|
||||||
use a double-hyphen on the command line to indicate the
|
|
||||||
end of options.
|
|
||||||
</p>
|
</p>
|
||||||
</dd>
|
</dd>
|
||||||
<dt><span class="term"><strong class="userinput"><code>querylog</code></strong> [<span class="optional"> on | off </span>] </span></dt>
|
<dt><span class="term"><strong class="userinput"><code>querylog</code></strong> [<span class="optional"> on | off </span>] </span></dt>
|
||||||
@@ -913,14 +902,11 @@
|
|||||||
<dd>
|
<dd>
|
||||||
<p>
|
<p>
|
||||||
Enable, disable, or check the current status of
|
Enable, disable, or check the current status of
|
||||||
DNSSEC validation. By default, validation is enabled.
|
DNSSEC validation.
|
||||||
(Note that <span class="command"><strong>dnssec-enable</strong></span> must also be
|
Note <span class="command"><strong>dnssec-enable</strong></span> also needs to be
|
||||||
<strong class="userinput"><code>yes</code></strong> (the default value) for signatures
|
set to <strong class="userinput"><code>yes</code></strong> or
|
||||||
to be returned along with validated data. If validation is
|
<strong class="userinput"><code>auto</code></strong> to be effective.
|
||||||
enabled while <span class="command"><strong>dnssec-enable</strong></span> is set to
|
It defaults to enabled.
|
||||||
<strong class="userinput"><code>no</code></strong>, the server will validate internally,
|
|
||||||
but will not supply clients with the necessary records to allow
|
|
||||||
validity to be confirmed.)
|
|
||||||
</p>
|
</p>
|
||||||
</dd>
|
</dd>
|
||||||
<dt><span class="term"><strong class="userinput"><code>zonestatus <em class="replaceable"><code>zone</code></em> [<span class="optional"><em class="replaceable"><code>class</code></em> [<span class="optional"><em class="replaceable"><code>view</code></em></span>]</span>]</code></strong></span></dt>
|
<dt><span class="term"><strong class="userinput"><code>zonestatus <em class="replaceable"><code>zone</code></em> [<span class="optional"><em class="replaceable"><code>class</code></em> [<span class="optional"><em class="replaceable"><code>view</code></em></span>]</span>]</code></strong></span></dt>
|
||||||
|
|||||||
@@ -115,8 +115,6 @@ main(int argc, char **argv) {
|
|||||||
strcmp(argv[1], "seconary") == 0)
|
strcmp(argv[1], "seconary") == 0)
|
||||||
{
|
{
|
||||||
zonetype = CFG_ZONE_SLAVE;
|
zonetype = CFG_ZONE_SLAVE;
|
||||||
} else if (strcmp(argv[1], "mirror") == 0) {
|
|
||||||
zonetype = CFG_ZONE_MIRROR;
|
|
||||||
} else if (strcmp(argv[1], "stub") == 0) {
|
} else if (strcmp(argv[1], "stub") == 0) {
|
||||||
zonetype = CFG_ZONE_STUB;
|
zonetype = CFG_ZONE_STUB;
|
||||||
} else if (strcmp(argv[1], "static-stub") == 0) {
|
} else if (strcmp(argv[1], "static-stub") == 0) {
|
||||||
|
|||||||
@@ -46,7 +46,6 @@ options {
|
|||||||
memstatistics-file "named.memstats"; // _PATH_MEMSTATS
|
memstatistics-file "named.memstats"; // _PATH_MEMSTATS
|
||||||
|
|
||||||
max-cache-ttl 999;
|
max-cache-ttl 999;
|
||||||
min-cache-ttl 66;
|
|
||||||
auth-nxdomain yes; // always set AA on NXDOMAIN.
|
auth-nxdomain yes; // always set AA on NXDOMAIN.
|
||||||
// don't set this to 'no' unless
|
// don't set this to 'no' unless
|
||||||
// you know what you're doing -- older
|
// you know what you're doing -- older
|
||||||
@@ -149,7 +148,6 @@ options {
|
|||||||
min-refresh-time 777;
|
min-refresh-time 777;
|
||||||
|
|
||||||
max-ncache-ttl 333;
|
max-ncache-ttl 333;
|
||||||
min-ncache-ttl 22;
|
|
||||||
min-roots 15;
|
min-roots 15;
|
||||||
serial-queries 34;
|
serial-queries 34;
|
||||||
|
|
||||||
|
|||||||
@@ -0,0 +1 @@
|
|||||||
|
child.example. IN KEY 256 3 3 ALeiYGFXbil6PgHnkm5ZE67ygEVDvGT/gqZmLH7tGboofcPSfyhh1hpw dxZgJ26d/gynWMGVSYzaXfzsxpPoNeYn+qeevQoJOaxXXlfcy8Ik52Rm eW0J9mWlf9hsD7ShIhh1+0kRYGCOCaU25wIe3SLVkN3HgqiCBDYnBY0u nMkqRadiUnoEa3Tcvc9kJx9r9gDstR2A9A5sBhFLI/XQ0gViHHLVpQ4x hz+rTLb/xrBoAb5sQJT3xUjhhdNo9HuL6kwdLdSu//PCl1QnY9NpYPVV SKUo
|
||||||
@@ -0,0 +1,7 @@
|
|||||||
|
Private-key-format: v1.2
|
||||||
|
Algorithm: 3 (DSA)
|
||||||
|
Prime(p): vGT/gqZmLH7tGboofcPSfyhh1hpwdxZgJ26d/gynWMGVSYzaXfzsxpPoNeYn+qeevQoJOaxXXlfcy8Ik52RmeQ==
|
||||||
|
Subprime(q): t6JgYVduKXo+AeeSblkTrvKARUM=
|
||||||
|
Base(g): bQn2ZaV/2GwPtKEiGHX7SRFgYI4JpTbnAh7dItWQ3ceCqIIENicFjS6cySpFp2JSegRrdNy9z2QnH2v2AOy1HQ==
|
||||||
|
Private_value(x): J1Ctez8+w1PTR56Hze3pGoe0Wag=
|
||||||
|
Public_value(y): gPQObAYRSyP10NIFYhxy1aUOMYc/q0y2/8awaAG+bECU98VI4YXTaPR7i+pMHS3Urv/zwpdUJ2PTaWD1VUilKA==
|
||||||
@@ -1,5 +0,0 @@
|
|||||||
; This is a zone-signing key, keyid 33180, for child.example.
|
|
||||||
; Created: 20181025104746 (Thu Oct 25 12:47:46 2018)
|
|
||||||
; Publish: 20181025104746 (Thu Oct 25 12:47:46 2018)
|
|
||||||
; Activate: 20181025104746 (Thu Oct 25 12:47:46 2018)
|
|
||||||
child.example. IN DNSKEY 256 3 5 AwEAAb9eatC8ASzDnRApcZuxyBrvJRANRQjCXQ1FWK+8vEyXV5NIE9Km hKIV2wbq2tLBPfjNQz4BTJ9RmDINf1RayDlt6L+IQV1JCaDaMjd1zU3n SQK18Y7fMu0ww4AMKOnoVRbkIxa3zlA0chImXcfPE0q2AvKBYLzPfkPO cfplAuRkLcGUxdADCipNzCOakpcd5gfm9Sa2HlaXcw3gyI1WcE8=
|
|
||||||
@@ -1,13 +0,0 @@
|
|||||||
Private-key-format: v1.3
|
|
||||||
Algorithm: 5 (RSASHA1)
|
|
||||||
Modulus: v15q0LwBLMOdEClxm7HIGu8lEA1FCMJdDUVYr7y8TJdXk0gT0qaEohXbBura0sE9+M1DPgFMn1GYMg1/VFrIOW3ov4hBXUkJoNoyN3XNTedJArXxjt8y7TDDgAwo6ehVFuQjFrfOUDRyEiZdx88TSrYC8oFgvM9+Q85x+mUC5GQtwZTF0AMKKk3MI5qSlx3mB+b1JrYeVpdzDeDIjVZwTw==
|
|
||||||
PublicExponent: AQAB
|
|
||||||
PrivateExponent: WDsn9GU6BXGLENCK2MX3BLQN2oDDu24hiOTYJu5VwtpkPjuVKCIuNKzu9xmBGnqOIBBDWGsw8KOmEC247yOL/S53iRdBS8lI7yiqznc52RhlmrdPKXbNpVnPwil8wocw+oQYa7uvdPYxI2Yy3B/tRgUxlxSlc/LW/dr0BX2L7qr/aeOBeGSRUlCpc7tYU9a2RUaLpVxF6SlqicCpC91MAQ==
|
|
||||||
Prime1: 466f+JL66Bl4qYnkj0s9+1N3pYmdcM9Ja1AN66X4VLslA9Cm1JEaC5V9HOptfcXUk0XYEVnKeKM2lIQnvcLG0yuQHIa+pGi7P8vgQfdaRUE=
|
|
||||||
Prime2: 1yuUkTVRSbUWeUreEcHgeeBBJ61UshX7t07gnGgIr3artGdo2CVEb5//+2Mvj5bgjCQBvjBbmHNZrR0jKDRBTIGtqbBerOuhEN4AXdAEgY8=
|
|
||||||
Exponent1: KzUXbJ/P973ltR7S/hKEV66WVRbRhvf/cdsGWULs5n+BXcD59/r1W19qF9OxJZ4mYjBt+ZT1pIEsuXB+7jcJbkelGJTFlwO9DTVOgJZFTkE=
|
|
||||||
Exponent2: FTPsLertGbBIiKdB/sn2Dsx0Xy6LXAkihsu1AnSV9oRhIyPVhwcVGVLQ7Lq3YxThB648pbsqK3miapamcj3D+YAF1uTUT4Hgm0LlEll/OC0=
|
|
||||||
Coefficient: Vulw9kmmjKc+wmOukLdzheoA2hNPDVtgiynfzHybyXdqvapCoK+ZVmNFzjO0M41ATcpvya3iX0bekMQqYnBhLURNZUIyqz2nGskOjV8I5Jg=
|
|
||||||
Created: 20181025104746
|
|
||||||
Publish: 20181025104746
|
|
||||||
Activate: 20181025104746
|
|
||||||
@@ -49,6 +49,7 @@ XTARGETS = adb_test@EXEEXT@ \
|
|||||||
db_test@EXEEXT@ \
|
db_test@EXEEXT@ \
|
||||||
dst_test@EXEEXT@ \
|
dst_test@EXEEXT@ \
|
||||||
gsstest@EXEEXT@ \
|
gsstest@EXEEXT@ \
|
||||||
|
hash_test@EXEEXT@ \
|
||||||
fsaccess_test@EXEEXT@ \
|
fsaccess_test@EXEEXT@ \
|
||||||
inter_test@EXEEXT@ \
|
inter_test@EXEEXT@ \
|
||||||
lex_test@EXEEXT@ \
|
lex_test@EXEEXT@ \
|
||||||
@@ -77,6 +78,7 @@ XSRCS = adb_test.c \
|
|||||||
byname_test.c \
|
byname_test.c \
|
||||||
db_test.c \
|
db_test.c \
|
||||||
dst_test.c \
|
dst_test.c \
|
||||||
|
hash_test.c \
|
||||||
fsaccess_test.c \
|
fsaccess_test.c \
|
||||||
gsstest.c \
|
gsstest.c \
|
||||||
inter_test.c \
|
inter_test.c \
|
||||||
@@ -165,6 +167,10 @@ name_test@EXEEXT@: name_test.@O@ ${ISCDEPLIBS} ${DNSDEPLIBS}
|
|||||||
${LIBTOOL_MODE_LINK} ${PURIFY} ${CC} ${CFLAGS} ${LDFLAGS} -o $@ name_test.@O@ \
|
${LIBTOOL_MODE_LINK} ${PURIFY} ${CC} ${CFLAGS} ${LDFLAGS} -o $@ name_test.@O@ \
|
||||||
${DNSLIBS} ${ISCLIBS} ${LIBS}
|
${DNSLIBS} ${ISCLIBS} ${LIBS}
|
||||||
|
|
||||||
|
hash_test@EXEEXT@: hash_test.@O@ ${ISCDEPLIBS}
|
||||||
|
${LIBTOOL_MODE_LINK} ${PURIFY} ${CC} ${CFLAGS} ${LDFLAGS} -o $@ hash_test.@O@ \
|
||||||
|
${ISCLIBS} ${LIBS}
|
||||||
|
|
||||||
entropy_test@EXEEXT@: entropy_test.@O@ ${ISCDEPLIBS}
|
entropy_test@EXEEXT@: entropy_test.@O@ ${ISCDEPLIBS}
|
||||||
${LIBTOOL_MODE_LINK} ${PURIFY} ${CC} ${CFLAGS} ${LDFLAGS} -o $@ entropy_test.@O@ \
|
${LIBTOOL_MODE_LINK} ${PURIFY} ${CC} ${CFLAGS} ${LDFLAGS} -o $@ entropy_test.@O@ \
|
||||||
${ISCLIBS} ${LIBS}
|
${ISCLIBS} ${LIBS}
|
||||||
|
|||||||
@@ -146,7 +146,7 @@ create_managers(void) {
|
|||||||
isc_result_t result;
|
isc_result_t result;
|
||||||
|
|
||||||
taskmgr = NULL;
|
taskmgr = NULL;
|
||||||
result = isc_taskmgr_create(mctx, 5, &taskmgr);
|
result = isc_taskmgr_create(mctx, 5, 0, &taskmgr);
|
||||||
check_result(result, "isc_taskmgr_create");
|
check_result(result, "isc_taskmgr_create");
|
||||||
|
|
||||||
timermgr = NULL;
|
timermgr = NULL;
|
||||||
@@ -290,8 +290,8 @@ main(int argc, char **argv) {
|
|||||||
|
|
||||||
isc_stdtime_get(&now);
|
isc_stdtime_get(&now);
|
||||||
|
|
||||||
isc_mutex_init(&client_lock);
|
result = isc_mutex_init(&client_lock);
|
||||||
|
check_result(result, "isc_mutex_init(&client_lock)");
|
||||||
ISC_LIST_INIT(clients);
|
ISC_LIST_INIT(clients);
|
||||||
|
|
||||||
/*
|
/*
|
||||||
|
|||||||
@@ -114,7 +114,7 @@ main(int argc, char *argv[]) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
taskmgr = NULL;
|
taskmgr = NULL;
|
||||||
RUNTIME_CHECK(isc_taskmgr_create(mctx, workers, &taskmgr)
|
RUNTIME_CHECK(isc_taskmgr_create(mctx, workers, 0, &taskmgr)
|
||||||
== ISC_R_SUCCESS);
|
== ISC_R_SUCCESS);
|
||||||
task = NULL;
|
task = NULL;
|
||||||
RUNTIME_CHECK(isc_task_create(taskmgr, 0, &task)
|
RUNTIME_CHECK(isc_task_create(taskmgr, 0, &task)
|
||||||
|
|||||||
@@ -228,7 +228,7 @@ main(int argc, char *argv[]) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
taskmgr = NULL;
|
taskmgr = NULL;
|
||||||
RUNTIME_CHECK(isc_taskmgr_create(mctx, workers, &taskmgr) ==
|
RUNTIME_CHECK(isc_taskmgr_create(mctx, workers, 0, &taskmgr) ==
|
||||||
ISC_R_SUCCESS);
|
ISC_R_SUCCESS);
|
||||||
task = NULL;
|
task = NULL;
|
||||||
RUNTIME_CHECK(isc_task_create(taskmgr, 0, &task) ==
|
RUNTIME_CHECK(isc_task_create(taskmgr, 0, &task) ==
|
||||||
|
|||||||
@@ -359,6 +359,7 @@ main(int argc, char *argv[]) {
|
|||||||
dbinfo *dbi;
|
dbinfo *dbi;
|
||||||
dns_dbversion_t *version;
|
dns_dbversion_t *version;
|
||||||
const dns_name_t *origin;
|
const dns_name_t *origin;
|
||||||
|
size_t memory_quota = 0;
|
||||||
dns_trust_t trust = 0;
|
dns_trust_t trust = 0;
|
||||||
unsigned int addopts;
|
unsigned int addopts;
|
||||||
isc_log_t *lctx = NULL;
|
isc_log_t *lctx = NULL;
|
||||||
@@ -410,6 +411,10 @@ main(int argc, char *argv[]) {
|
|||||||
case 'P':
|
case 'P':
|
||||||
pause_every = atoi(isc_commandline_argument);
|
pause_every = atoi(isc_commandline_argument);
|
||||||
break;
|
break;
|
||||||
|
case 'Q':
|
||||||
|
memory_quota = atoi(isc_commandline_argument);
|
||||||
|
isc_mem_setquota(mctx, memory_quota);
|
||||||
|
break;
|
||||||
case 't':
|
case 't':
|
||||||
type = atoi(isc_commandline_argument);
|
type = atoi(isc_commandline_argument);
|
||||||
break;
|
break;
|
||||||
@@ -766,7 +771,7 @@ main(int argc, char *argv[]) {
|
|||||||
if (noexact_zonecut)
|
if (noexact_zonecut)
|
||||||
zcoptions |= DNS_DBFIND_NOEXACT;
|
zcoptions |= DNS_DBFIND_NOEXACT;
|
||||||
result = dns_db_findzonecut(db, &name, zcoptions,
|
result = dns_db_findzonecut(db, &name, zcoptions,
|
||||||
0, &node, fname, NULL,
|
0, &node, fname,
|
||||||
&rdataset, &sigrdataset);
|
&rdataset, &sigrdataset);
|
||||||
} else {
|
} else {
|
||||||
result = dns_db_find(db, &name, version, type,
|
result = dns_db_find(db, &name, version, type,
|
||||||
|
|||||||
@@ -254,9 +254,11 @@ main(void) {
|
|||||||
result = dns_name_fromtext(name, &b, NULL, 0, NULL);
|
result = dns_name_fromtext(name, &b, NULL, 0, NULL);
|
||||||
if (result != ISC_R_SUCCESS)
|
if (result != ISC_R_SUCCESS)
|
||||||
return (1);
|
return (1);
|
||||||
|
io(name, 23616, DST_ALG_DSA, DST_TYPE_PRIVATE|DST_TYPE_PUBLIC, mctx);
|
||||||
io(name, 54622, DST_ALG_RSAMD5, DST_TYPE_PRIVATE|DST_TYPE_PUBLIC,
|
io(name, 54622, DST_ALG_RSAMD5, DST_TYPE_PRIVATE|DST_TYPE_PUBLIC,
|
||||||
mctx);
|
mctx);
|
||||||
|
|
||||||
|
io(name, 49667, DST_ALG_DSA, DST_TYPE_PRIVATE|DST_TYPE_PUBLIC, mctx);
|
||||||
io(name, 2, DST_ALG_RSAMD5, DST_TYPE_PRIVATE|DST_TYPE_PUBLIC, mctx);
|
io(name, 2, DST_ALG_RSAMD5, DST_TYPE_PRIVATE|DST_TYPE_PUBLIC, mctx);
|
||||||
|
|
||||||
isc_buffer_constinit(&b, "dh.", 3);
|
isc_buffer_constinit(&b, "dh.", 3);
|
||||||
@@ -268,6 +270,7 @@ main(void) {
|
|||||||
|
|
||||||
generate(DST_ALG_RSAMD5, mctx);
|
generate(DST_ALG_RSAMD5, mctx);
|
||||||
generate(DST_ALG_DH, mctx);
|
generate(DST_ALG_DH, mctx);
|
||||||
|
generate(DST_ALG_DSA, mctx);
|
||||||
generate(DST_ALG_HMACMD5, mctx);
|
generate(DST_ALG_HMACMD5, mctx);
|
||||||
|
|
||||||
dst_lib_destroy();
|
dst_lib_destroy();
|
||||||
|
|||||||
@@ -472,7 +472,7 @@ main(int argc, char *argv[]) {
|
|||||||
RUNCHECK(dst_lib_init(mctx, NULL));
|
RUNCHECK(dst_lib_init(mctx, NULL));
|
||||||
|
|
||||||
taskmgr = NULL;
|
taskmgr = NULL;
|
||||||
RUNCHECK(isc_taskmgr_create(mctx, 1, &taskmgr));
|
RUNCHECK(isc_taskmgr_create(mctx, 1, 0, &taskmgr));
|
||||||
task = NULL;
|
task = NULL;
|
||||||
RUNCHECK(isc_task_create(taskmgr, 0, &task));
|
RUNCHECK(isc_task_create(taskmgr, 0, &task));
|
||||||
timermgr = NULL;
|
timermgr = NULL;
|
||||||
|
|||||||
@@ -0,0 +1,284 @@
|
|||||||
|
/*
|
||||||
|
* 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 http://mozilla.org/MPL/2.0/.
|
||||||
|
*
|
||||||
|
* See the COPYRIGHT file distributed with this work for additional
|
||||||
|
* information regarding copyright ownership.
|
||||||
|
*/
|
||||||
|
|
||||||
|
/*! \file */
|
||||||
|
#include <config.h>
|
||||||
|
|
||||||
|
#include <stdio.h>
|
||||||
|
#include <string.h>
|
||||||
|
|
||||||
|
#include <isc/hmacmd5.h>
|
||||||
|
#include <isc/hmacsha.h>
|
||||||
|
#include <isc/md5.h>
|
||||||
|
#include <isc/sha1.h>
|
||||||
|
#include <isc/util.h>
|
||||||
|
#include <isc/print.h>
|
||||||
|
#include <isc/string.h>
|
||||||
|
|
||||||
|
#include <pk11/site.h>
|
||||||
|
|
||||||
|
static void
|
||||||
|
print_digest(const char *s, const char *hash, unsigned char *d,
|
||||||
|
unsigned int words)
|
||||||
|
{
|
||||||
|
unsigned int i, j;
|
||||||
|
|
||||||
|
printf("hash (%s) %s:\n\t", hash, s);
|
||||||
|
for (i = 0; i < words; i++) {
|
||||||
|
printf(" ");
|
||||||
|
for (j = 0; j < 4; j++)
|
||||||
|
printf("%02x", d[i * 4 + j]);
|
||||||
|
}
|
||||||
|
printf("\n");
|
||||||
|
}
|
||||||
|
|
||||||
|
int
|
||||||
|
main(int argc, char **argv) {
|
||||||
|
isc_sha1_t sha1;
|
||||||
|
isc_sha224_t sha224;
|
||||||
|
isc_md5_t md5;
|
||||||
|
isc_hmacmd5_t hmacmd5;
|
||||||
|
isc_hmacsha1_t hmacsha1;
|
||||||
|
isc_hmacsha224_t hmacsha224;
|
||||||
|
isc_hmacsha256_t hmacsha256;
|
||||||
|
isc_hmacsha384_t hmacsha384;
|
||||||
|
isc_hmacsha512_t hmacsha512;
|
||||||
|
unsigned char digest[ISC_SHA512_DIGESTLENGTH];
|
||||||
|
unsigned char buffer[1024];
|
||||||
|
const char *s;
|
||||||
|
unsigned char key[20];
|
||||||
|
|
||||||
|
UNUSED(argc);
|
||||||
|
UNUSED(argv);
|
||||||
|
|
||||||
|
s = "abc";
|
||||||
|
isc_sha1_init(&sha1);
|
||||||
|
memmove(buffer, s, strlen(s));
|
||||||
|
isc_sha1_update(&sha1, buffer, strlen(s));
|
||||||
|
isc_sha1_final(&sha1, digest);
|
||||||
|
print_digest(s, "sha1", digest, ISC_SHA1_DIGESTLENGTH/4);
|
||||||
|
|
||||||
|
s = "abcdbcdecdefdefgefghfghighijhijkijkljklmklmnlmnomnopnopq";
|
||||||
|
isc_sha1_init(&sha1);
|
||||||
|
memmove(buffer, s, strlen(s));
|
||||||
|
isc_sha1_update(&sha1, buffer, strlen(s));
|
||||||
|
isc_sha1_final(&sha1, digest);
|
||||||
|
print_digest(s, "sha1", digest, ISC_SHA1_DIGESTLENGTH/4);
|
||||||
|
|
||||||
|
s = "abc";
|
||||||
|
isc_sha224_init(&sha224);
|
||||||
|
memmove(buffer, s, strlen(s));
|
||||||
|
isc_sha224_update(&sha224, buffer, strlen(s));
|
||||||
|
isc_sha224_final(digest, &sha224);
|
||||||
|
print_digest(s, "sha224", digest, ISC_SHA224_DIGESTLENGTH/4);
|
||||||
|
|
||||||
|
s = "abcdbcdecdefdefgefghfghighijhijkijkljklmklmnlmnomnopnopq";
|
||||||
|
isc_sha224_init(&sha224);
|
||||||
|
memmove(buffer, s, strlen(s));
|
||||||
|
isc_sha224_update(&sha224, buffer, strlen(s));
|
||||||
|
isc_sha224_final(digest, &sha224);
|
||||||
|
print_digest(s, "sha224", digest, ISC_SHA224_DIGESTLENGTH/4);
|
||||||
|
|
||||||
|
s = "abc";
|
||||||
|
isc_md5_init(&md5);
|
||||||
|
memmove(buffer, s, strlen(s));
|
||||||
|
isc_md5_update(&md5, buffer, strlen(s));
|
||||||
|
isc_md5_final(&md5, digest);
|
||||||
|
print_digest(s, "md5", digest, 4);
|
||||||
|
|
||||||
|
/*
|
||||||
|
* The 3 HMAC-MD5 examples from RFC2104
|
||||||
|
*/
|
||||||
|
s = "Hi There";
|
||||||
|
memset(key, 0x0b, 16);
|
||||||
|
isc_hmacmd5_init(&hmacmd5, key, 16);
|
||||||
|
memmove(buffer, s, strlen(s));
|
||||||
|
isc_hmacmd5_update(&hmacmd5, buffer, strlen(s));
|
||||||
|
isc_hmacmd5_sign(&hmacmd5, digest);
|
||||||
|
print_digest(s, "hmacmd5", digest, 4);
|
||||||
|
|
||||||
|
s = "what do ya want for nothing?";
|
||||||
|
strlcpy((char *)key, "Jefe", sizeof(key));
|
||||||
|
isc_hmacmd5_init(&hmacmd5, key, 4);
|
||||||
|
memmove(buffer, s, strlen(s));
|
||||||
|
isc_hmacmd5_update(&hmacmd5, buffer, strlen(s));
|
||||||
|
isc_hmacmd5_sign(&hmacmd5, digest);
|
||||||
|
print_digest(s, "hmacmd5", digest, 4);
|
||||||
|
|
||||||
|
s = "\335\335\335\335\335\335\335\335\335\335"
|
||||||
|
"\335\335\335\335\335\335\335\335\335\335"
|
||||||
|
"\335\335\335\335\335\335\335\335\335\335"
|
||||||
|
"\335\335\335\335\335\335\335\335\335\335"
|
||||||
|
"\335\335\335\335\335\335\335\335\335\335";
|
||||||
|
memset(key, 0xaa, 16);
|
||||||
|
isc_hmacmd5_init(&hmacmd5, key, 16);
|
||||||
|
memmove(buffer, s, strlen(s));
|
||||||
|
isc_hmacmd5_update(&hmacmd5, buffer, strlen(s));
|
||||||
|
isc_hmacmd5_sign(&hmacmd5, digest);
|
||||||
|
print_digest(s, "hmacmd5", digest, 4);
|
||||||
|
|
||||||
|
/*
|
||||||
|
* The 3 HMAC-SHA1 examples from RFC4634.
|
||||||
|
*/
|
||||||
|
s = "Hi There";
|
||||||
|
memset(key, 0x0b, 20);
|
||||||
|
isc_hmacsha1_init(&hmacsha1, key, 20);
|
||||||
|
memmove(buffer, s, strlen(s));
|
||||||
|
isc_hmacsha1_update(&hmacsha1, buffer, strlen(s));
|
||||||
|
isc_hmacsha1_sign(&hmacsha1, digest, ISC_SHA1_DIGESTLENGTH);
|
||||||
|
print_digest(s, "hmacsha1", digest, ISC_SHA1_DIGESTLENGTH/4);
|
||||||
|
|
||||||
|
s = "what do ya want for nothing?";
|
||||||
|
strlcpy((char *)key, "Jefe", sizeof(key));
|
||||||
|
isc_hmacsha1_init(&hmacsha1, key, 4);
|
||||||
|
memmove(buffer, s, strlen(s));
|
||||||
|
isc_hmacsha1_update(&hmacsha1, buffer, strlen(s));
|
||||||
|
isc_hmacsha1_sign(&hmacsha1, digest, ISC_SHA1_DIGESTLENGTH);
|
||||||
|
print_digest(s, "hmacsha1", digest, ISC_SHA1_DIGESTLENGTH/4);
|
||||||
|
|
||||||
|
s = "\335\335\335\335\335\335\335\335\335\335"
|
||||||
|
"\335\335\335\335\335\335\335\335\335\335"
|
||||||
|
"\335\335\335\335\335\335\335\335\335\335"
|
||||||
|
"\335\335\335\335\335\335\335\335\335\335"
|
||||||
|
"\335\335\335\335\335\335\335\335\335\335";
|
||||||
|
memset(key, 0xaa, 20);
|
||||||
|
isc_hmacsha1_init(&hmacsha1, key, 20);
|
||||||
|
memmove(buffer, s, strlen(s));
|
||||||
|
isc_hmacsha1_update(&hmacsha1, buffer, strlen(s));
|
||||||
|
isc_hmacsha1_sign(&hmacsha1, digest, ISC_SHA1_DIGESTLENGTH);
|
||||||
|
print_digest(s, "hmacsha1", digest, ISC_SHA1_DIGESTLENGTH/4);
|
||||||
|
|
||||||
|
/*
|
||||||
|
* The 3 HMAC-SHA224 examples from RFC4634.
|
||||||
|
*/
|
||||||
|
s = "Hi There";
|
||||||
|
memset(key, 0x0b, 20);
|
||||||
|
isc_hmacsha224_init(&hmacsha224, key, 20);
|
||||||
|
memmove(buffer, s, strlen(s));
|
||||||
|
isc_hmacsha224_update(&hmacsha224, buffer, strlen(s));
|
||||||
|
isc_hmacsha224_sign(&hmacsha224, digest, ISC_SHA224_DIGESTLENGTH);
|
||||||
|
print_digest(s, "hmacsha224", digest, ISC_SHA224_DIGESTLENGTH/4);
|
||||||
|
|
||||||
|
s = "what do ya want for nothing?";
|
||||||
|
strlcpy((char *)key, "Jefe", sizeof(key));
|
||||||
|
isc_hmacsha224_init(&hmacsha224, key, 4);
|
||||||
|
memmove(buffer, s, strlen(s));
|
||||||
|
isc_hmacsha224_update(&hmacsha224, buffer, strlen(s));
|
||||||
|
isc_hmacsha224_sign(&hmacsha224, digest, ISC_SHA224_DIGESTLENGTH);
|
||||||
|
print_digest(s, "hmacsha224", digest, ISC_SHA224_DIGESTLENGTH/4);
|
||||||
|
|
||||||
|
s = "\335\335\335\335\335\335\335\335\335\335"
|
||||||
|
"\335\335\335\335\335\335\335\335\335\335"
|
||||||
|
"\335\335\335\335\335\335\335\335\335\335"
|
||||||
|
"\335\335\335\335\335\335\335\335\335\335"
|
||||||
|
"\335\335\335\335\335\335\335\335\335\335";
|
||||||
|
memset(key, 0xaa, 20);
|
||||||
|
isc_hmacsha224_init(&hmacsha224, key, 20);
|
||||||
|
memmove(buffer, s, strlen(s));
|
||||||
|
isc_hmacsha224_update(&hmacsha224, buffer, strlen(s));
|
||||||
|
isc_hmacsha224_sign(&hmacsha224, digest, ISC_SHA224_DIGESTLENGTH);
|
||||||
|
print_digest(s, "hmacsha224", digest, ISC_SHA224_DIGESTLENGTH/4);
|
||||||
|
|
||||||
|
/*
|
||||||
|
* The 3 HMAC-SHA256 examples from RFC4634.
|
||||||
|
*/
|
||||||
|
s = "Hi There";
|
||||||
|
memset(key, 0x0b, 20);
|
||||||
|
isc_hmacsha256_init(&hmacsha256, key, 20);
|
||||||
|
memmove(buffer, s, strlen(s));
|
||||||
|
isc_hmacsha256_update(&hmacsha256, buffer, strlen(s));
|
||||||
|
isc_hmacsha256_sign(&hmacsha256, digest, ISC_SHA256_DIGESTLENGTH);
|
||||||
|
print_digest(s, "hmacsha256", digest, ISC_SHA256_DIGESTLENGTH/4);
|
||||||
|
|
||||||
|
s = "what do ya want for nothing?";
|
||||||
|
strlcpy((char *)key, "Jefe", sizeof(key));
|
||||||
|
isc_hmacsha256_init(&hmacsha256, key, 4);
|
||||||
|
memmove(buffer, s, strlen(s));
|
||||||
|
isc_hmacsha256_update(&hmacsha256, buffer, strlen(s));
|
||||||
|
isc_hmacsha256_sign(&hmacsha256, digest, ISC_SHA256_DIGESTLENGTH);
|
||||||
|
print_digest(s, "hmacsha256", digest, ISC_SHA256_DIGESTLENGTH/4);
|
||||||
|
|
||||||
|
s = "\335\335\335\335\335\335\335\335\335\335"
|
||||||
|
"\335\335\335\335\335\335\335\335\335\335"
|
||||||
|
"\335\335\335\335\335\335\335\335\335\335"
|
||||||
|
"\335\335\335\335\335\335\335\335\335\335"
|
||||||
|
"\335\335\335\335\335\335\335\335\335\335";
|
||||||
|
memset(key, 0xaa, 20);
|
||||||
|
isc_hmacsha256_init(&hmacsha256, key, 20);
|
||||||
|
memmove(buffer, s, strlen(s));
|
||||||
|
isc_hmacsha256_update(&hmacsha256, buffer, strlen(s));
|
||||||
|
isc_hmacsha256_sign(&hmacsha256, digest, ISC_SHA256_DIGESTLENGTH);
|
||||||
|
print_digest(s, "hmacsha256", digest, ISC_SHA256_DIGESTLENGTH/4);
|
||||||
|
|
||||||
|
/*
|
||||||
|
* The 3 HMAC-SHA384 examples from RFC4634.
|
||||||
|
*/
|
||||||
|
s = "Hi There";
|
||||||
|
memset(key, 0x0b, 20);
|
||||||
|
isc_hmacsha384_init(&hmacsha384, key, 20);
|
||||||
|
memmove(buffer, s, strlen(s));
|
||||||
|
isc_hmacsha384_update(&hmacsha384, buffer, strlen(s));
|
||||||
|
isc_hmacsha384_sign(&hmacsha384, digest, ISC_SHA384_DIGESTLENGTH);
|
||||||
|
print_digest(s, "hmacsha384", digest, ISC_SHA384_DIGESTLENGTH/4);
|
||||||
|
|
||||||
|
s = "what do ya want for nothing?";
|
||||||
|
strlcpy((char *)key, "Jefe", sizeof(key));
|
||||||
|
isc_hmacsha384_init(&hmacsha384, key, 4);
|
||||||
|
memmove(buffer, s, strlen(s));
|
||||||
|
isc_hmacsha384_update(&hmacsha384, buffer, strlen(s));
|
||||||
|
isc_hmacsha384_sign(&hmacsha384, digest, ISC_SHA384_DIGESTLENGTH);
|
||||||
|
print_digest(s, "hmacsha384", digest, ISC_SHA384_DIGESTLENGTH/4);
|
||||||
|
|
||||||
|
s = "\335\335\335\335\335\335\335\335\335\335"
|
||||||
|
"\335\335\335\335\335\335\335\335\335\335"
|
||||||
|
"\335\335\335\335\335\335\335\335\335\335"
|
||||||
|
"\335\335\335\335\335\335\335\335\335\335"
|
||||||
|
"\335\335\335\335\335\335\335\335\335\335";
|
||||||
|
memset(key, 0xaa, 20);
|
||||||
|
isc_hmacsha384_init(&hmacsha384, key, 20);
|
||||||
|
memmove(buffer, s, strlen(s));
|
||||||
|
isc_hmacsha384_update(&hmacsha384, buffer, strlen(s));
|
||||||
|
isc_hmacsha384_sign(&hmacsha384, digest, ISC_SHA384_DIGESTLENGTH);
|
||||||
|
print_digest(s, "hmacsha384", digest, ISC_SHA384_DIGESTLENGTH/4);
|
||||||
|
|
||||||
|
/*
|
||||||
|
* The 3 HMAC-SHA512 examples from RFC4634.
|
||||||
|
*/
|
||||||
|
s = "Hi There";
|
||||||
|
memset(key, 0x0b, 20);
|
||||||
|
isc_hmacsha512_init(&hmacsha512, key, 20);
|
||||||
|
memmove(buffer, s, strlen(s));
|
||||||
|
isc_hmacsha512_update(&hmacsha512, buffer, strlen(s));
|
||||||
|
isc_hmacsha512_sign(&hmacsha512, digest, ISC_SHA512_DIGESTLENGTH);
|
||||||
|
print_digest(s, "hmacsha512", digest, ISC_SHA512_DIGESTLENGTH/4);
|
||||||
|
|
||||||
|
s = "what do ya want for nothing?";
|
||||||
|
strlcpy((char *)key, "Jefe", sizeof(key));
|
||||||
|
isc_hmacsha512_init(&hmacsha512, key, 4);
|
||||||
|
memmove(buffer, s, strlen(s));
|
||||||
|
isc_hmacsha512_update(&hmacsha512, buffer, strlen(s));
|
||||||
|
isc_hmacsha512_sign(&hmacsha512, digest, ISC_SHA512_DIGESTLENGTH);
|
||||||
|
print_digest(s, "hmacsha512", digest, ISC_SHA512_DIGESTLENGTH/4);
|
||||||
|
|
||||||
|
s = "\335\335\335\335\335\335\335\335\335\335"
|
||||||
|
"\335\335\335\335\335\335\335\335\335\335"
|
||||||
|
"\335\335\335\335\335\335\335\335\335\335"
|
||||||
|
"\335\335\335\335\335\335\335\335\335\335"
|
||||||
|
"\335\335\335\335\335\335\335\335\335\335";
|
||||||
|
memset(key, 0xaa, 20);
|
||||||
|
isc_hmacsha512_init(&hmacsha512, key, 20);
|
||||||
|
memmove(buffer, s, strlen(s));
|
||||||
|
isc_hmacsha512_update(&hmacsha512, buffer, strlen(s));
|
||||||
|
isc_hmacsha512_sign(&hmacsha512, digest, ISC_SHA512_DIGESTLENGTH);
|
||||||
|
print_digest(s, "hmacsha512", digest, ISC_SHA512_DIGESTLENGTH/4);
|
||||||
|
|
||||||
|
return (0);
|
||||||
|
}
|
||||||
@@ -30,7 +30,7 @@ main(int argc, char *argv[]) {
|
|||||||
|
|
||||||
isc_mem_debugging = ISC_MEM_DEBUGRECORD;
|
isc_mem_debugging = ISC_MEM_DEBUGRECORD;
|
||||||
|
|
||||||
isc_mutex_init(&lock);
|
RUNTIME_CHECK(isc_mutex_init(&lock) == ISC_R_SUCCESS);
|
||||||
|
|
||||||
mctx = NULL;
|
mctx = NULL;
|
||||||
RUNTIME_CHECK(isc_mem_create(0, 0, &mctx) == ISC_R_SUCCESS);
|
RUNTIME_CHECK(isc_mem_create(0, 0, &mctx) == ISC_R_SUCCESS);
|
||||||
@@ -114,7 +114,7 @@ main(int argc, char *argv[]) {
|
|||||||
|
|
||||||
isc_mem_destroy(&mctx);
|
isc_mem_destroy(&mctx);
|
||||||
|
|
||||||
isc_mutex_destroy(&lock);
|
DESTROYLOCK(&lock);
|
||||||
|
|
||||||
return (0);
|
return (0);
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -104,7 +104,8 @@ main(int argc, char *argv[]) {
|
|||||||
isc_interval_set(&linterval, 1, 0);
|
isc_interval_set(&linterval, 1, 0);
|
||||||
|
|
||||||
RUNTIME_CHECK(isc_mem_create(0, 0, &mctx) == ISC_R_SUCCESS);
|
RUNTIME_CHECK(isc_mem_create(0, 0, &mctx) == ISC_R_SUCCESS);
|
||||||
RUNTIME_CHECK(isc_taskmgr_create(mctx, 3, &taskmgr) == ISC_R_SUCCESS);
|
RUNTIME_CHECK(isc_taskmgr_create(mctx, 3, 0, &taskmgr) ==
|
||||||
|
ISC_R_SUCCESS);
|
||||||
RUNTIME_CHECK(isc_timermgr_create(mctx, &timermgr) ==
|
RUNTIME_CHECK(isc_timermgr_create(mctx, &timermgr) ==
|
||||||
ISC_R_SUCCESS);
|
ISC_R_SUCCESS);
|
||||||
RUNTIME_CHECK(isc_task_create(taskmgr, 0, &g_task) ==
|
RUNTIME_CHECK(isc_task_create(taskmgr, 0, &g_task) ==
|
||||||
|
|||||||
@@ -183,7 +183,7 @@ main(int argc, char *argv[]) {
|
|||||||
RUNTIME_CHECK(isc_mem_create(0, 0, &mctx) == ISC_R_SUCCESS);
|
RUNTIME_CHECK(isc_mem_create(0, 0, &mctx) == ISC_R_SUCCESS);
|
||||||
mctx2 = NULL;
|
mctx2 = NULL;
|
||||||
RUNTIME_CHECK(isc_mem_create(0, 0, &mctx2) == ISC_R_SUCCESS);
|
RUNTIME_CHECK(isc_mem_create(0, 0, &mctx2) == ISC_R_SUCCESS);
|
||||||
RUNTIME_CHECK(isc_taskmgr_create(mctx, workers, &task_manager) ==
|
RUNTIME_CHECK(isc_taskmgr_create(mctx, workers, 0, &task_manager) ==
|
||||||
ISC_R_SUCCESS);
|
ISC_R_SUCCESS);
|
||||||
RUNTIME_CHECK(isc_timermgr_create(mctx, &timer_manager) ==
|
RUNTIME_CHECK(isc_timermgr_create(mctx, &timer_manager) ==
|
||||||
ISC_R_SUCCESS);
|
ISC_R_SUCCESS);
|
||||||
|
|||||||
@@ -206,7 +206,7 @@ main(int argc, char *argv[]) {
|
|||||||
|
|
||||||
RUNTIME_CHECK(isc_app_start() == ISC_R_SUCCESS);
|
RUNTIME_CHECK(isc_app_start() == ISC_R_SUCCESS);
|
||||||
|
|
||||||
isc_mutex_init(&lock);
|
RUNTIME_CHECK(isc_mutex_init(&lock) == ISC_R_SUCCESS);
|
||||||
|
|
||||||
mctx = NULL;
|
mctx = NULL;
|
||||||
RUNTIME_CHECK(isc_mem_create(0, 0, &mctx) == ISC_R_SUCCESS);
|
RUNTIME_CHECK(isc_mem_create(0, 0, &mctx) == ISC_R_SUCCESS);
|
||||||
@@ -228,7 +228,8 @@ main(int argc, char *argv[]) {
|
|||||||
dst_result_register();
|
dst_result_register();
|
||||||
|
|
||||||
taskmgr = NULL;
|
taskmgr = NULL;
|
||||||
RUNTIME_CHECK(isc_taskmgr_create(mctx, 2, &taskmgr) == ISC_R_SUCCESS);
|
RUNTIME_CHECK(isc_taskmgr_create(mctx, 2, 0, &taskmgr) ==
|
||||||
|
ISC_R_SUCCESS);
|
||||||
task1 = NULL;
|
task1 = NULL;
|
||||||
RUNTIME_CHECK(isc_task_create(taskmgr, 0, &task1) == ISC_R_SUCCESS);
|
RUNTIME_CHECK(isc_task_create(taskmgr, 0, &task1) == ISC_R_SUCCESS);
|
||||||
|
|
||||||
@@ -254,7 +255,7 @@ main(int argc, char *argv[]) {
|
|||||||
CHECK("dns_name_fromtext", result);
|
CHECK("dns_name_fromtext", result);
|
||||||
|
|
||||||
key = NULL;
|
key = NULL;
|
||||||
result = dst_key_fromfile(name, 33180, DNS_KEYALG_RSASHA1,
|
result = dst_key_fromfile(name, 4017, DNS_KEYALG_DSA,
|
||||||
DST_TYPE_PUBLIC | DST_TYPE_PRIVATE,
|
DST_TYPE_PUBLIC | DST_TYPE_PRIVATE,
|
||||||
NULL, mctx, &key);
|
NULL, mctx, &key);
|
||||||
CHECK("dst_key_fromfile", result);
|
CHECK("dst_key_fromfile", result);
|
||||||
@@ -281,7 +282,7 @@ main(int argc, char *argv[]) {
|
|||||||
isc_mem_stats(mctx, stdout);
|
isc_mem_stats(mctx, stdout);
|
||||||
isc_mem_destroy(&mctx);
|
isc_mem_destroy(&mctx);
|
||||||
|
|
||||||
isc_mutex_destroy(&lock);
|
DESTROYLOCK(&lock);
|
||||||
|
|
||||||
isc_app_finish();
|
isc_app_finish();
|
||||||
|
|
||||||
|
|||||||
@@ -297,7 +297,7 @@ main(int argc, char *argv[]) {
|
|||||||
* The task manager is independent (other than memory context)
|
* The task manager is independent (other than memory context)
|
||||||
*/
|
*/
|
||||||
manager = NULL;
|
manager = NULL;
|
||||||
RUNTIME_CHECK(isc_taskmgr_create(mctx, workers, &manager) ==
|
RUNTIME_CHECK(isc_taskmgr_create(mctx, workers, 0, &manager) ==
|
||||||
ISC_R_SUCCESS);
|
ISC_R_SUCCESS);
|
||||||
|
|
||||||
/*
|
/*
|
||||||
|
|||||||
@@ -81,7 +81,7 @@ main(int argc, char *argv[]) {
|
|||||||
|
|
||||||
RUNTIME_CHECK(isc_mem_create(0, 0, &mctx) == ISC_R_SUCCESS);
|
RUNTIME_CHECK(isc_mem_create(0, 0, &mctx) == ISC_R_SUCCESS);
|
||||||
|
|
||||||
RUNTIME_CHECK(isc_taskmgr_create(mctx, workers, &manager) ==
|
RUNTIME_CHECK(isc_taskmgr_create(mctx, workers, 0, &manager) ==
|
||||||
ISC_R_SUCCESS);
|
ISC_R_SUCCESS);
|
||||||
|
|
||||||
RUNTIME_CHECK(isc_task_create(manager, 0, &t1) == ISC_R_SUCCESS);
|
RUNTIME_CHECK(isc_task_create(manager, 0, &t1) == ISC_R_SUCCESS);
|
||||||
|
|||||||
@@ -110,7 +110,7 @@ main(int argc, char *argv[]) {
|
|||||||
printf("%u workers\n", workers);
|
printf("%u workers\n", workers);
|
||||||
|
|
||||||
RUNTIME_CHECK(isc_mem_create(0, 0, &mctx1) == ISC_R_SUCCESS);
|
RUNTIME_CHECK(isc_mem_create(0, 0, &mctx1) == ISC_R_SUCCESS);
|
||||||
RUNTIME_CHECK(isc_taskmgr_create(mctx1, workers, &manager) ==
|
RUNTIME_CHECK(isc_taskmgr_create(mctx1, workers, 0, &manager) ==
|
||||||
ISC_R_SUCCESS);
|
ISC_R_SUCCESS);
|
||||||
RUNTIME_CHECK(isc_timermgr_create(mctx1, &timgr) == ISC_R_SUCCESS);
|
RUNTIME_CHECK(isc_timermgr_create(mctx1, &timgr) == ISC_R_SUCCESS);
|
||||||
|
|
||||||
|
|||||||
@@ -12,7 +12,6 @@
|
|||||||
#include <config.h>
|
#include <config.h>
|
||||||
|
|
||||||
#include <sys/param.h>
|
#include <sys/param.h>
|
||||||
#include <sys/select.h>
|
|
||||||
#include <sys/types.h>
|
#include <sys/types.h>
|
||||||
#include <sys/time.h>
|
#include <sys/time.h>
|
||||||
|
|
||||||
@@ -36,6 +35,10 @@
|
|||||||
#include <dns/result.h>
|
#include <dns/result.h>
|
||||||
#include <dns/zone.h>
|
#include <dns/zone.h>
|
||||||
|
|
||||||
|
#ifdef ISC_PLATFORM_NEEDSYSSELECTH
|
||||||
|
#include <sys/select.h>
|
||||||
|
#endif
|
||||||
|
|
||||||
static int debug = 0;
|
static int debug = 0;
|
||||||
static int quiet = 0;
|
static int quiet = 0;
|
||||||
static int stats = 0;
|
static int stats = 0;
|
||||||
@@ -284,7 +287,7 @@ main(int argc, char **argv) {
|
|||||||
|
|
||||||
RUNTIME_CHECK(isc_app_start() == ISC_R_SUCCESS);
|
RUNTIME_CHECK(isc_app_start() == ISC_R_SUCCESS);
|
||||||
RUNTIME_CHECK(isc_mem_create(0, 0, &mctx) == ISC_R_SUCCESS);
|
RUNTIME_CHECK(isc_mem_create(0, 0, &mctx) == ISC_R_SUCCESS);
|
||||||
RUNTIME_CHECK(isc_taskmgr_create(mctx, 2, &taskmgr) ==
|
RUNTIME_CHECK(isc_taskmgr_create(mctx, 2, 0, &taskmgr) ==
|
||||||
ISC_R_SUCCESS);
|
ISC_R_SUCCESS);
|
||||||
RUNTIME_CHECK(isc_timermgr_create(mctx, &timermgr) == ISC_R_SUCCESS);
|
RUNTIME_CHECK(isc_timermgr_create(mctx, &timermgr) == ISC_R_SUCCESS);
|
||||||
RUNTIME_CHECK(isc_socketmgr_create(mctx, &socketmgr) == ISC_R_SUCCESS);
|
RUNTIME_CHECK(isc_socketmgr_create(mctx, &socketmgr) == ISC_R_SUCCESS);
|
||||||
|
|||||||
@@ -69,7 +69,7 @@ PARALLEL = rpzrecurse serve-stale dnssec \
|
|||||||
rrchecker rrl rrsetorder rsabigexponent runtime \
|
rrchecker rrl rrsetorder rsabigexponent runtime \
|
||||||
sfcache smartsign sortlist \
|
sfcache smartsign sortlist \
|
||||||
spf staticstub statistics statschannel stub synthfromdnssec \
|
spf staticstub statistics statschannel stub synthfromdnssec \
|
||||||
tcp tools tsig tsiggss ttl \
|
tcp tools tsig tsiggss \
|
||||||
unknown upforwd verify views wildcard \
|
unknown upforwd verify views wildcard \
|
||||||
xfer xferquota zero zonechecks
|
xfer xferquota zero zonechecks
|
||||||
|
|
||||||
|
|||||||
@@ -22,10 +22,3 @@ ns2 A 10.53.0.2
|
|||||||
|
|
||||||
a A 10.0.7.1
|
a A 10.0.7.1
|
||||||
mail A 10.0.7.2
|
mail A 10.0.7.2
|
||||||
b A 10.0.7.3
|
|
||||||
c A 10.0.7.4
|
|
||||||
d A 10.0.7.5
|
|
||||||
e A 10.0.7.6
|
|
||||||
f A 10.0.7.7
|
|
||||||
g A 10.0.7.8
|
|
||||||
h A 10.0.7.9
|
|
||||||
|
|||||||
-9
@@ -18,15 +18,6 @@ options {
|
|||||||
dnssec-validation no;
|
dnssec-validation no;
|
||||||
};
|
};
|
||||||
|
|
||||||
key rndc_key {
|
|
||||||
secret "1234abcd8765";
|
|
||||||
algorithm hmac-sha256;
|
|
||||||
};
|
|
||||||
|
|
||||||
controls {
|
|
||||||
inet 10.53.0.3 port @CONTROLPORT@ allow { any; } keys { rndc_key; };
|
|
||||||
};
|
|
||||||
|
|
||||||
zone "." {
|
zone "." {
|
||||||
type hint;
|
type hint;
|
||||||
file "../../common/root.hint";
|
file "../../common/root.hint";
|
||||||
@@ -1,36 +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 http://mozilla.org/MPL/2.0/.
|
|
||||||
*
|
|
||||||
* See the COPYRIGHT file distributed with this work for additional
|
|
||||||
* information regarding copyright ownership.
|
|
||||||
*/
|
|
||||||
|
|
||||||
options {
|
|
||||||
port @PORT@;
|
|
||||||
pid-file "named.pid";
|
|
||||||
listen-on { 10.53.0.3; };
|
|
||||||
listen-on-v6 { none; };
|
|
||||||
recursion yes;
|
|
||||||
allow-recursion { any; };
|
|
||||||
allow-recursion-on { none; };
|
|
||||||
allow-query-cache-on { 10.53.0.3; };
|
|
||||||
dnssec-validation no;
|
|
||||||
};
|
|
||||||
|
|
||||||
key rndc_key {
|
|
||||||
secret "1234abcd8765";
|
|
||||||
algorithm hmac-sha256;
|
|
||||||
};
|
|
||||||
|
|
||||||
controls {
|
|
||||||
inet 10.53.0.3 port @CONTROLPORT@ allow { any; } keys { rndc_key; };
|
|
||||||
};
|
|
||||||
|
|
||||||
zone "." {
|
|
||||||
type hint;
|
|
||||||
file "../../common/root.hint";
|
|
||||||
};
|
|
||||||
@@ -1,36 +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 http://mozilla.org/MPL/2.0/.
|
|
||||||
*
|
|
||||||
* See the COPYRIGHT file distributed with this work for additional
|
|
||||||
* information regarding copyright ownership.
|
|
||||||
*/
|
|
||||||
|
|
||||||
options {
|
|
||||||
port @PORT@;
|
|
||||||
pid-file "named.pid";
|
|
||||||
listen-on { 10.53.0.3; 10.53.1.2; };
|
|
||||||
listen-on-v6 { none; };
|
|
||||||
recursion yes;
|
|
||||||
allow-recursion { any; };
|
|
||||||
allow-query-cache { any; };
|
|
||||||
allow-query-cache-on { 10.53.0.3; }; # allow-recursion-on inherits
|
|
||||||
dnssec-validation no;
|
|
||||||
};
|
|
||||||
|
|
||||||
key rndc_key {
|
|
||||||
secret "1234abcd8765";
|
|
||||||
algorithm hmac-sha256;
|
|
||||||
};
|
|
||||||
|
|
||||||
controls {
|
|
||||||
inet 10.53.0.3 port @CONTROLPORT@ allow { any; } keys { rndc_key; };
|
|
||||||
};
|
|
||||||
|
|
||||||
zone "." {
|
|
||||||
type hint;
|
|
||||||
file "../../common/root.hint";
|
|
||||||
};
|
|
||||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user