Public documentation
Zonemaster is a software package that validates the quality of a DNS delegation. The ambition of the Zonemaster project is to develop and maintain an open source DNS validation tool, offering improved performance over existing tools and providing extensive documentation which could be re-used by similar projects in the future.
Zonemaster consists of several modules or components. The components will help different types of users to check domain servers for configuration errors and generate a report that will assist in fixing the errors.
Zonemaster is developed by Afnic and IIS.
A public instance is running at https://zonemaster.net.
The public documentation is divided into the following main categories:
- Release information gives release information of latest release.
- Installation contains documents that explain how to install the different components of Zonemaster.
- Upgrading contains documents that explain how to upgrade a Zonemaster installation.
- Configuration contains documents that explain how a Zonemaster installation can be configured.
- Using contains user guides to the different components of Zonemaster.
- Specifications contains specifications of the Zonemaster test cases, test types and test zones.
- Development contains information for developers both in and outside the Zonemaster project.
- License gives the license information for Zonemaster.
Release v2024.2 (2024-12-09)
[Release information]
- Translations have not been fully updated in this release. They will be updated in an upcoming extra release.
- User documentation for the current and past releases will now also be published on https://doc.zonemaster.net
[Breaking changes]
- Refactors ASNLookup code in Zonemaster-Engine
[Features]
- Updates global cache documentationand makes the feature being supported and not experimental (#1327, #1303). Also see Zonemaster-Engine release notes
- Updates or adds specification of test cases or test scenarios for test cases Connectivity04 (#1311, #1299, #1298). Also see Zonemaster-Engine release notes for updates implementation
- Updates specification of test case Connectivity03 (#1297). Also see Zonemaster-Engine release notes for updated implementation
- Updates or adds specification of test cases or test scenarios for test cases DNSSEC10 (#1294, #1179). Also see Zonemaster-Engine release notes for updated implementation
- Corrects display when running 'zonemaster-cli'. See Zonemaster-CLI release notes
- Makes utilities zmb() and zmtest supported. See Zonemaster-Backend release notes
- Rebuild Zonemaster-GUI distribution package to remove potential vulnerabilities. See Zonemaster-GUI release notes
[Fixes]
- Updates installation instructions (#1334, #1332, #1330, #1331, #1322, #1321, #1314, #1307)
- Updates translations instructions (#1320)
- Updates general documents (#1319, #1318, #1317, #1316)
- Updates usage document for CLI (#1309)
- Adds specification of test scenarios for test cases Delegation01, Delegation02 and Delegation03 (#1305)
- Removes unimplemented test case Nameserver14 (#1300)
- Updates and adds usage document for Backend and batch testing (#1310, #1303)
- Updates or adds specification of MethodsV2 (shared between test cases) or test scenarios for MethodsV2 (#1290, #1287, #1254)
- Corrects spelling i various documents (external controbution from @jsoref) (#1278)
- Adds specification of test scenarios for the CNAME function in Recursor.pm in Engine (#1220)
[Zonemaster product]
This version of Zonemaster also consists of the following components. For each component, see its Changes file or Github release notes for complete release information.
Component | Github release notes | Changes file | Updated in this release |
---|---|---|---|
Zonemaster-LDNS | v4.1.0 | Changes | Yes |
Zonemaster-Engine | v7.0.0 | Changes | Yes |
Zonemaster-CLI | v7.1.0 | Changes | Yes |
Zonemaster-Backend | v11.3.0 | Changes | Yes |
Zonemaster-GUI | v4.3.1 | Changes | Yes |
For more information on previous versions of the Zonemaster product see the Changes file or the releases page on Github. For general information ses the README file.
Installation instructions
Manual installation
Before installing Zonemaster, check the prerequisites first.
Start by installing the following components, in order:
At this point, tests can be run from the command-line on the local machine. To install the Web GUI, install the following additional components, in order:
Docker
Alternatively, Zonemaster-CLI is available on Docker Hub, and can be conveniently downloaded and run without any installation. Through Docker Zonemaster-CLI can be run on Linux, macOS and Windows. See Using the CLI for how to run Zonemaster-CLI on Docker.
To build your own Docker image, see the Docker Image Creation documentation.
Prerequisites
Zonemaster comes with documentation for and has been tested on the operating systems and processor architecture listed below.
Supported processor architectures
- x86_64 / amd64
Supported operating system versions
- Debian 12
- Docker
- FreeBSD 14
- Rocky Linux 8
- Rocky Linux 9
- Ubuntu 20.04
- Ubuntu 22.04
- Ubuntu 24.04
Only the latest long-term supported version of Debian and FreeBSD, respectively, is supported. All long-term supported versions of Rocky Linux and Ubuntu are supported, unless such a version has end of support before the expected next release of Zonemaster.
Only the Docker images provided by the Zonemaster project on Docker Hub are supported. Currently only Zonemaster-CLI is supported on Docker. Docker itself can run on any of the Docker supported OSs (Linux, macOS and Windows).
Rocky Linux has replaced CentOS in Zonemaster version v2021.2 since CentOS 8 is not supported anymore and CentOS 7 is old and does not support modern OpenSSL required by Zonemaster. Rocky Linux is also a Red Hat derivative and is available at large cloud providers.
Supported database engine versions
Operating System | MariaDB | PostgreSQL |
---|---|---|
Debian 12 | 10.11 | 15 |
Docker | n/a | n/a |
FreeBSD 14 | 8.0 (*) | 16 |
Rocky Linux 8 | 10.3 | 10 |
Rocky Linux 9 | 10.5 | 13 |
Ubuntu 20.04 | 10.3 | 12 |
Ubuntu 22.04 | 10.6 | 14 |
Ubuntu 24.04 | 10.11 | 16 |
- (*) FreeBSD uses MySQL, not MariaDB.
- SQLite is bundled in Perl DBD::SQLite and loaded as a dependency to Zonemaster-Backend.
- Zonemaster Backend has been tested with the combination of OS and database engine version listed in the table above.
- Zonemaster depends on functionality introduced in PostgreSQL version 10, and earlier versions of PostgreSQL are as such not supported.
- Zonemaster Backend has not been published on Docker Hub.
Supported Perl versions
Operating System | Perl |
---|---|
Debian 12 | 5.36 |
Docker | (*) |
FreeBSD 14 | 5.36 |
Rocky Linux 8 | 5.26 |
Rocky Linux 9 | 5.32 |
Ubuntu 20.04 | 5.30 |
Ubuntu 22.04 | 5.34 |
Ubuntu 24.04 | 5.38 |
- Zonemaster technically requires Perl version 5.16 or higher, but has only been tested with the versions in the table above.
- Zonemaster has been tested with the default version of Perl in the OSs as listed in the table above.
- (*) Perl is included in the Docker image published on Docker Hub.
Supported Client Browser versions
Zonemaster GUI is tested on the browsers in the table below. The latest version of the browser at the time of testing is used.
Browser |
---|
Firefox |
Chrome |
Zonemaster GUI is tested manually and with testing tools. See the Zonemaster-gui repository for more details.
Installation: Zonemaster-LDNS
Recommended installation
The recommended way to install Zonemaster::LDNS is to follow the installation instructions for Zonemaster::Engine where you will find all prerequisites and dependencies for Zonemaster::LDNS before installing it.
Installation from source
Override the default set of features by appending --FEATURE
and/or
--no-FEATURE
options to the perl Makefile.PL
command.
git clone https://github.com/zonemaster/zonemaster-ldns
cd zonemaster-ldns
perl Makefile.PL
make
make test
make install
Note: The source ZIP files downloaded from GitHub are broken with respect to this instruction.
Optional features
When installing from source, you can choose to enable or disable a number
of optional features using command line options to the perl Makefile.PL
commands.
Ed25519
Enabled by default.
Disabled with --no-ed25519
Requires support for algorithms Ed25519 and Ed448 in both openssl and ldns.
Note: Zonemaster Engine relies on this feature for its analysis when Ed25519 (DNSKEY algorithm 15) or Ed448 (DNSKEY algorithm 16) is being used in DNSSEC signatures.
IDN
Enabled by default.
Disable with --no-idn
.
If the IDN feature is enabled, the GNU libidn2
library will be used to
add a simple function that converts strings from Perl's internal encoding
to IDNA domain name format.
In order to convert strings from whatever encoding you have to Perl's
internal format, use L
Note: The Zonemaster Engine test suite assumes this feature is enabled.
Internal ldns
Enabled by default.
Disable with --no-internal-ldns
.
When enabled, an included version of ldns is statically linked into Zonemaster::LDNS. When disabled, libldns is dynamically linked just like other dependencies.
Randomized capitalization
Disabled by default.
Enable with --randomize
.
Note: This feature is experimental.
Randomizes the capitalization of returned domain names.
Custom OpenSSL
Disabled by default.
Enabled with --prefix-openssl=/path/to/openssl
or
--openssl-inc=/path/to/openssl_inc
or --openssl-lib=/path/to/openssl_lib
.
Enabling this makes the build tools look for OpenSSL in a non-standard place.
Technically this does two things:
- Libcrypto is sought in the
lib
directory under the given directory. - The
include
directory under the given directory is added to the include path.
Note: The
lib
directory under the given path must be known to the dynamic linker or feature checks will fail.
If both headers and libraries directories (include
and lib
) are not in the
same parent directory, use --openssl-inc
and --openssl-lib
options to
specify both paths.
Custom LDNS
Disabled by default.
Enabled with --ldns-inc=/path/to/ldns_inc
or --ldns-lib=/path/to/ldns_lib
.
Enabling this makes the build tools look for LDNS in a non-standard place.
Requires Internal LDNS to be disabled.
Custom Libidn
Disabled by default.
Enabled with --libidn-inc=/path/to/libidn_inc
or
--libidn-lib=/path/to/ldns_lib
.
Enabling this makes the build tools look for Libidn in a non-standard place.
Requires IDN to be enabled.
Debug
Disabled by default.
Enabled with --debug
.
Gives a more verbose output.
Post-installation sanity check
perl -MZonemaster::LDNS -E 'say Zonemaster::LDNS->new("8.8.8.8")->query("zonemaster.net")->string'
The above command should print some dig
-like output.
Testing
Some of the unit tests depend on data on the Internet, which may change. To avoid
false fails, those unit tests are only run if the environment variable
TEST_WITH_NETWORK
is true
. By default that variable is unset (those tests are
not run). To run all tests, execute
TEST_WITH_NETWORK=1 make test
Installation: Zonemaster-Engine
Table of contents
- Local installation
- Post-installation sanity check
- Troubleshooting installation
- Global cache
- What to do next
Local installation
Installation on Rocky Linux
-
Install the EPEL repository:
sudo dnf install --assumeyes epel-release sudo crb enable
-
Enable SHA-1 in the crypto policy:
# Only on Rocky Linux 9: sudo update-crypto-policies --set DEFAULT:SHA1
-
Install locales:
sudo dnf install --assumeyes glibc-all-langpacks
-
Install binary packages:
sudo dnf install --assumeyes cpanminus gcc libidn2-devel openssl-devel perl-Class-Accessor perl-Clone perl-core perl-Devel-CheckLib perl-Email-Valid perl-ExtUtils-PkgConfig perl-File-ShareDir perl-File-Slurp perl-libintl perl-IO-Socket-INET6 perl-List-Compare perl-List-MoreUtils perl-Mail-SPF perl-Module-Find perl-Module-Install perl-Net-DNS perl-Pod-Coverage perl-Readonly perl-Sub-Override perl-Test-Differences perl-Test-Exception perl-Test-Fatal perl-Test-NoWarnings perl-Test-Pod perl-Text-CSV perl-Test-Simple
-
Install packages from CPAN:
sudo cpanm --notest Locale::PO Log::Any MIME::Base32 Module::Install::XSUtil Net::IP::XS YAML::XS
-
Install Zonemaster::LDNS and Zonemaster::Engine:
sudo cpanm --notest Zonemaster::LDNS Zonemaster::Engine
Installation on Debian and Ubuntu
Using pre-built packages is the preferred method for Debian and Ubuntu.
Installation from pre-built packages
-
Upgrade to latest patch level
sudo apt update && sudo apt upgrade
-
Add Zonemaster packages repository to repository list
curl -LOs https://package.zonemaster.net/setup.sh sudo sh setup.sh
-
Install Zonemaster Engine
sudo apt install libzonemaster-engine-perl
Installation from CPAN
-
Upgrade to latest patch level
sudo apt update && sudo apt upgrade
-
Install dependencies from binary packages:
sudo apt install autoconf automake build-essential cpanminus libclass-accessor-perl libclone-perl libdevel-checklib-perl libemail-valid-perl libextutils-pkgconfig-perl libfile-sharedir-perl libfile-slurp-perl libidn2-dev libintl-perl libio-socket-inet6-perl liblist-compare-perl liblist-moreutils-perl liblocale-po-perl liblog-any-perl libmail-spf-perl libmime-base32-perl libmodule-find-perl libmodule-install-perl libmodule-install-xsutil-perl libnet-dns-perl libnet-ip-xs-perl libpod-coverage-perl libreadonly-perl libssl-dev libsub-override-perl libtest-differences-perl libtest-exception-perl libtest-fatal-perl libtest-nowarnings-perl libtest-pod-perl libtext-csv-perl libyaml-libyaml-perl libtool m4
-
Install Zonemaster::LDNS and Zonemaster::Engine.
sudo cpanm --notest Zonemaster::LDNS Zonemaster::Engine
Installation on FreeBSD
-
Become root:
su -l
-
Update list of package repositories:
Create the file
/usr/local/etc/pkg/repos/FreeBSD.conf
with the following content, unless it is already updated:FreeBSD: { url: "pkg+http://pkg.FreeBSD.org/${ABI}/latest", }
-
Check or activate the package system:
Run the following command, and accept the installation of the
pkg
package if suggested.pkg info -E pkg
-
Update local package repository:
pkg update -f
-
Install dependencies from binary packages:
pkg install devel/gmake dns/ldns libidn2 p5-App-cpanminus p5-Class-Accessor p5-Clone p5-Devel-CheckLib p5-Email-Valid p5-ExtUtils-PkgConfig p5-File-ShareDir p5-File-Slurp p5-IO-Socket-INET6 p5-List-Compare p5-List-MoreUtils p5-Locale-libintl p5-Locale-PO p5-Log-Any p5-Mail-SPF p5-MIME-Base32 p5-Module-Find p5-Module-Install p5-Module-Install-XSUtil p5-Net-DNS p5-Net-IP-XS p5-Pod-Coverage p5-Readonly p5-Sub-Override p5-Test-Differences p5-Test-Exception p5-Test-Fatal p5-Test-NoWarnings p5-Test-Pod p5-Text-CSV p5-YAML-LibYAML
-
Install Zonemaster::LDNS:
cpanm --notest --configure-args="--no-internal-ldns" Zonemaster::LDNS
-
Install Zonemaster::Engine:
cpanm --notest Zonemaster::Engine
Post-installation sanity check
Make sure Zonemaster::Engine is properly installed.
time perl -MZonemaster::Engine -E 'say join "\n", Zonemaster::Engine->test_module("BASIC", "zonemaster.net")'
The command is expected to take a few seconds and print some results about the delegation of zonemaster.net.
Troubleshooting installation
If you have any issue with installation, and installed with cpanm
, redo the
installation above but without the --notest
and with the --verbose
option.
Installation will take longer time.
Global cache
Global cache is a feature that can be enabled in Zonemaster-Engine and consists in a shared, persistent cache. It can increase the performance when many tests are run within a short time frame. See global cache configuration.
What to do next
- For a command line interface, follow the Zonemaster::CLI installation instruction.
- For a web interface, follow the Zonemaster::Backend installation and Zonemaster::GUI installation instructions.
- For a JSON-RPC API, follow the Zonemaster::Backend installation instruction.
- For a Perl API, see the Zonemaster::Engine API documentation.
Installation: Zonemaster-CLI
Table of contents
- Overview
- Prerequisites for CPAN installation
- Local installation
- Post-installation sanity check
- Using Zonemaster-CLI
- Global cache
- What to do next?
Overview
Zonemaster-CLI provides a CLI (command line interface) to Zonemaster. To install follow the instructions below. An alternative to installing Zonemaster-CLI is to run it under Docker. See Using the CLI for run it under Docker.
Prerequisites for CPAN installation
Before installing Zonemaster::CLI from CPAN, you should install Zonemaster::Engine, unless you are to install on Debian using pre-built packages (see below).
Note: Zonemaster::Engine and Zonemaster::LDNS are dependencies of Zonemaster::CLI. Zonemaster::LDNS has a special installation requirement, and Zonemaster::Engine has a list of dependencies that you may prefer to install from your operating system distribution (rather than CPAN). We recommend following the Zonemaster::Engine installation instruction.
Prerequisite for FreeBSD is that the package system is updated and activated (see the FreeBSD section of Zonemaster::Engine installation).
For details on supported versions of Perl and operating system for Zonemaster::CLI, see the declaration of prerequisites.
Local installation
Installation on Rocky Linux
-
Install dependencies:
sudo dnf install --assumeyes perl-JSON-XS perl-Try-Tiny perl-Test-Deep perl-Mojolicious
sudo cpanm --notest JSON::Validator
Note: Test::Deep and Mojolicious are indirect dependencies. They are dependencies of JSON::Validator.
-
Install Zonemaster::CLI
sudo cpanm --notest Zonemaster::CLI
Installation on Debian and Ubuntu
Using pre-built packages is the preferred method for Debian and Ubuntu.
Installation from pre-built packages
-
Add Zonemaster packages repository to repository list
curl -LOs https://package.zonemaster.net/setup.sh sudo sh setup.sh
-
Install Zonemaster CLI
sudo apt install zonemaster-cli
-
Update configuration of "locale"
sudo perl -pi -e 's/^# (da_DK\.UTF-8.*|en_US\.UTF-8.*|es_ES\.UTF-8.*|fi_FI\.UTF-8.*|fr_FR\.UTF-8.*|nb_NO\.UTF-8.*|sv_SE\.UTF-8.*)/$1/' /etc/locale.gen sudo locale-gen
After the update,
locale -a
should at least list the following locales:da_DK.utf8 en_US.utf8 es_ES.utf8 fi_FI.utf8 fr_FR.utf8 nb_NO.utf8 sv_SE.utf8
Installation from CPAN
-
Install dependencies:
sudo apt-get install locales libmodule-install-perl libtry-tiny-perl libjson-validator-perl
-
Install Zonemaster::CLI:
sudo cpanm --notest Zonemaster::CLI
-
Update configuration of "locale"
sudo perl -pi -e 's/^# (da_DK\.UTF-8.*|en_US\.UTF-8.*|es_ES\.UTF-8.*|fi_FI\.UTF-8.*|fr_FR\.UTF-8.*|nb_NO\.UTF-8.*|sv_SE\.UTF-8.*)/$1/' /etc/locale.gen sudo locale-gen
After the update,
locale -a
should at least list the following locales:da_DK.utf8 en_US.utf8 es_ES.utf8 fi_FI.utf8 fr_FR.utf8 nb_NO.utf8 sv_SE.utf8
Installation on FreeBSD
-
Become root:
su -l
-
Install dependencies available from binary packages:
pkg install gmake p5-JSON-XS p5-Locale-libintl p5-Try-Tiny p5-JSON-Validator
-
Install Zonemaster::CLI:
cpanm --notest Zonemaster::CLI
Post-installation sanity check
Run the zonemaster-cli command:
zonemaster-cli --test basic zonemaster.net
The command is expected to take a few seconds and print some results about the delegation of zonemaster.net.
Also, verify that the manual page is properly installed:
man zonemaster-cli
Using Zonemaster-CLI
See Using the CLI for an overview on how to use zonemaster-cli
after
installation.
Global cache
If Zonemaster-CLI is to be used for large batches, global cache can improve performance. See Global cache in Zonemaster-Engine.
What to do next?
- For a web GUI, follow the Zonemaster::Backend and Zonemaster::GUI installation instructions.
- For a JSON-RPC frontend, follow the Zonemaster::Backend installation instruction.
Installation: Zonemaster-Backend
Table of contents
- 1. Overview
- 2. Prerequisites
- 3. Installation on Rocky Linux
- 4. Installation on Debian and Ubuntu
- 5. Installation on FreeBSD
- 6. Post-installation
- 7. Installation with MariaDB
- 8. Installation with PostgreSQL
- 9. Cleaning up the database
- 10. Optional features
1. Overview
This document contains all steps needed to install Zonemaster::Backend. For an overview of the Zonemaster product, please see the main Zonemaster Repository.
If you upgrade your Zonemaster installation with a newer version of Zonemaster::Backend instead, and want to keep the database, then see the Upgrade document. Otherwise remove the database and continue with this installation document.
2. Prerequisites
Before installing Zonemaster::Backend, you should install Zonemaster::Engine .
Note: Zonemaster::Engine and Zonemaster::LDNS are dependencies of Zonemaster::Backend. Zonemaster::LDNS has a special installation requirement, and Zonemaster::Engine has a list of dependencies that you may prefer to install from your operating system distribution (rather than CPAN). We recommend following the Zonemaster::Engine installation instruction.
Prerequisite for FreeBSD is that the package system is updated and activated (see the FreeBSD section of Zonemaster::Engine installation).
For details on supported versions of Perl, database engine and operating system for Zonemaster::Backend, see the declaration of prerequisites.
3. Installation on Rocky Linux
3.1 Install Zonemaster::Backend and related dependencies (Rocky Linux)
Note: Zonemaster::LDNS and Zonemaster::Engine are not listed here as they are dealt with in the prerequisites section.
Install dependencies available from binary packages:
sudo dnf install --assumeyes jq perl-Class-Method-Modifiers perl-Config-IniFiles perl-DBD-SQLite perl-DBI perl-File-ShareDir perl-File-Slurp perl-HTML-Parser perl-JSON-PP perl-libwww-perl perl-Log-Dispatch perl-Mojolicious perl-Moose perl-Parallel-ForkManager perl-Plack perl-Plack-Middleware-ReverseProxy perl-Plack-Test perl-Role-Tiny perl-Test-Differences perl-Test-Exception perl-Test-Mojo perl-Test-NoWarnings perl-Try-Tiny perl-libintl perl-LWP-Protocol-https
Install dependencies not available from binary packages:
sudo cpanm --notest Daemon::Control JSON::RPC JSON::Validator Log::Any Log::Any::Adapter::Dispatch Net::IP::XS Router::Simple Starman
For Rocky Linux 8 only, install DBD::SQLite from CPAN as the one in the system packages repository is too old:
sudo cpanm --notest DBD::SQLite
Install Zonemaster::Backend:
sudo cpanm --notest Zonemaster::Backend
The command above might try to install "DBD::Pg" and "DBD::mysql". You can ignore if it fails. The relevant libraries are installed further down in these instructions.
Add Zonemaster user (unless it already exists):
sudo useradd -r -c "Zonemaster daemon user" zonemaster
Install files to their proper locations:
cd `perl -MFile::ShareDir=dist_dir -E 'say dist_dir("Zonemaster-Backend")'`
sudo install -v -m 755 -d /etc/zonemaster
sudo install -v -m 640 -g zonemaster ./backend_config.ini /etc/zonemaster/
sudo install -v -m 775 -g zonemaster -d /var/log/zonemaster
sudo install -v -m 644 ./tmpfiles.conf /usr/lib/tmpfiles.d/zonemaster.conf
sudo install -v -m 644 ./zm-rpcapi.service /etc/systemd/system/
sudo install -v -m 644 ./zm-testagent.service /etc/systemd/system/
3.2 Database engine installation (Rocky Linux)
Check the declaration of prerequisites to make sure your preferred combination of operating system version and database engine version is supported.
The installation instructions below assumes that this is a new installation.
3.2.1 Instructions for SQLite (Rocky Linux)
Note: Zonemaster with SQLite is not meant for an installation with heavy load.
Create database directory:
sudo install -v -m 755 -o zonemaster -g zonemaster -d /var/lib/zonemaster
Some parameters can be changed, see the backend configuration documentation for details.
3.2.2 Instructions for other engines (Rocky Linux)
See sections for MariaDB and PostgreSQL.
3.3 Database configuration (Rocky Linux)
Create the database tables:
sudo -u zonemaster $(perl -MFile::ShareDir -le 'print File::ShareDir::dist_dir("Zonemaster-Backend")')/create_db.pl
3.4 Service configuration and startup (Rocky Linux)
Make sure our tmpfiles configuration takes effect:
sudo systemd-tmpfiles --create /usr/lib/tmpfiles.d/zonemaster.conf
Enable services at boot time and start them:
sudo systemctl enable zm-rpcapi
sudo systemctl enable zm-testagent
sudo systemctl start zm-rpcapi
sudo systemctl start zm-testagent
If you have changed database daemon, restart the services:
sudo systemctl restart zm-rpcapi
sudo systemctl restart zm-testagent
3.5 Post-installation (Rocky Linux)
To check if the daemons are running, do:
sudo systemctl status zm-rpcapi
sudo systemctl status zm-testagent
See the post-installation section for post-installation matters.
4. Installation on Debian and Ubuntu
4.1 Install Zonemaster::Backend and related dependencies (Debian/Ubuntu)
Note: Zonemaster::LDNS and Zonemaster::Engine are not listed here as they are dealt with in the prerequisites section.
Install required locales:
sudo perl -pi -e 's/^# (da_DK\.UTF-8.*|en_US\.UTF-8.*|es_ES\.UTF-8.*|fi_FI\.UTF-8.*|fr_FR\.UTF-8.*|nb_NO\.UTF-8.*|sv_SE\.UTF-8.*)/$1/' /etc/locale.gen
sudo locale-gen
After the update, locale -a
should at least list the following locales:
da_DK.utf8
en_US.utf8
es_ES.utf8
fi_FI.utf8
fr_FR.utf8
nb_NO.utf8
sv_SE.utf8
Install dependencies available from binary packages:
sudo apt install jq libclass-method-modifiers-perl libconfig-inifiles-perl libdbd-sqlite3-perl libdaemon-control-perl libdbi-perl libfile-sharedir-perl libfile-slurp-perl libhtml-parser-perl libmojolicious-perl libio-stringy-perl libjson-pp-perl libjson-rpc-perl libjson-validator-perl liblog-any-adapter-dispatch-perl liblog-any-perl liblog-dispatch-perl libmoose-perl libparallel-forkmanager-perl libplack-perl libplack-middleware-debug-perl libplack-middleware-reverseproxy-perl librole-tiny-perl librouter-simple-perl libtest-nowarnings-perl libtest-differences-perl libtest-exception-perl libtry-tiny-perl libintl-perl perl-doc starman
Note: libio-stringy-perl is listed here even though it's not a direct dependency. It's an undeclared dependency of libconfig-inifiles-perl.
For Ubuntu 20.04 only, install JSON::Validator from CPAN as the one in the system packages repository is too old:
sudo cpanm --notest JSON::Validator
Install Zonemaster::Backend:
sudo cpanm --notest Zonemaster::Backend
The command above might try to install "DBD::Pg" and "DBD::mysql". You can ignore if it fails. The relevant libraries are installed further down in these instructions.
Add Zonemaster user (unless it already exists):
sudo useradd -r -c "Zonemaster daemon user" zonemaster
Install files to their proper locations:
cd `perl -MFile::ShareDir=dist_dir -E 'say dist_dir("Zonemaster-Backend")'`
sudo install -v -m 755 -d /etc/zonemaster
sudo install -v -m 775 -g zonemaster -d /var/log/zonemaster
sudo install -v -m 640 -g zonemaster ./backend_config.ini /etc/zonemaster/
sudo install -v -m 755 ./zm-rpcapi.lsb /etc/init.d/zm-rpcapi
sudo install -v -m 755 ./zm-testagent.lsb /etc/init.d/zm-testagent
sudo install -v -m 644 ./tmpfiles.conf /usr/lib/tmpfiles.d/zonemaster.conf
If this is an update of Zonemaster-Backend, you should remove any
/etc/init.d/zm-backend.sh
(script from previous version of Zonemaster-Backend).
4.2 Database engine installation (Debian/Ubuntu)
Check the declaration of prerequisites to make sure your preferred combination of operating system version and database engine version is supported.
The installation instructions below assumes that this is a new installation.
4.2.1 Instructions for SQLite (Debian/Ubuntu)
Note: Zonemaster with SQLite is not meant for an installation with heavy load.
Create database directory:
sudo install -v -m 755 -o zonemaster -g zonemaster -d /var/lib/zonemaster
Some parameters can be changed, see the backend configuration documentation for details.
4.2.2 Instructions for other engines (Debian/Ubuntu)
See sections for MariaDB and PostgreSQL.
4.3 Database configuration (Debian/Ubuntu)
Create the database tables:
sudo -u zonemaster $(perl -MFile::ShareDir -le 'print File::ShareDir::dist_dir("Zonemaster-Backend")')/create_db.pl
4.4 Service configuration and startup (Debian/Ubuntu)
Make sure our tmpfiles configuration takes effect:
sudo systemd-tmpfiles --create /usr/lib/tmpfiles.d/zonemaster.conf
Enable services at boot time and start them:
sudo systemctl enable zm-rpcapi
sudo systemctl enable zm-testagent
sudo systemctl start zm-rpcapi
sudo systemctl start zm-testagent
If you have changed database daemon, restart the services:
sudo systemctl restart zm-rpcapi
sudo systemctl restart zm-testagent
4.5 Post-installation (Debian/Ubuntu)
To check if the daemons are running, do:
sudo systemctl status zm-rpcapi
sudo systemctl status zm-testagent
See the post-installation section for post-installation matters.
5. Installation on FreeBSD
For all commands below, acquire privileges, i.e. become root:
su -l
5.1 Install Zonemaster::Backend and related dependencies (FreeBSD)
Note: Zonemaster::LDNS and Zonemaster::Engine are not listed here as they are dealt with in the prerequisites section.
Install dependencies available from binary packages:
pkg install jq p5-Class-Method-Modifiers p5-Config-IniFiles p5-Daemon-Control p5-DBI p5-File-ShareDir p5-File-Slurp p5-HTML-Parser p5-JSON-PP p5-JSON-RPC p5-Mojolicious p5-Moose p5-Parallel-ForkManager p5-Plack p5-Plack-Middleware-ReverseProxy p5-Role-Tiny p5-Router-Simple p5-Starman p5-DBD-SQLite p5-Log-Dispatch p5-Log-Any p5-Log-Any-Adapter-Dispatch p5-JSON-Validator p5-YAML-LibYAML p5-Test-NoWarnings p5-Test-Differences p5-Test-Exception p5-Locale-libintl gmake
Install Zonemaster::Backend:
cpanm --notest Zonemaster::Backend
The command above might try to install "DBD::Pg" and "DBD::mysql". You can ignore if it fails. The relevant libraries are installed further down in these instructions.
Unless they already exist, add zonemaster
user and zonemaster
group
(the group is created automatically):
cd `perl -MFile::ShareDir -le 'print File::ShareDir::dist_dir("Zonemaster-Backend")'`
pw useradd zonemaster -C freebsd-pwd.conf -s /sbin/nologin -d /nonexistent -c "Zonemaster daemon user"
Install files to their proper locations:
cd `perl -MFile::ShareDir -le 'print File::ShareDir::dist_dir("Zonemaster-Backend")'`
install -v -m 755 -d /usr/local/etc/zonemaster
install -v -m 640 -g zonemaster ./backend_config.ini /usr/local/etc/zonemaster/
install -v -m 775 -g zonemaster -d /var/log/zonemaster
install -v -m 775 -g zonemaster -d /var/run/zonemaster
install -v -m 755 ./zm_rpcapi-bsd /usr/local/etc/rc.d/zm_rpcapi
install -v -m 755 ./zm_testagent-bsd /usr/local/etc/rc.d/zm_testagent
5.2 Database engine installation (FreeBSD)
Check the declaration of prerequisites to make sure your preferred combination of operating system version and database engine version is supported.
The installation instructions below assumes that this is a new installation.
5.2.1 Instructions for SQLite (FreeBSD)
Note: Zonemaster with SQLite is not meant for an installation with heavy load.
Configure Zonemaster::Backend to use the correct database path:
sed -i '' '/[[:<:]]database_file[[:>:]]/ s:=.*:= /var/db/zonemaster/db.sqlite:' /usr/local/etc/zonemaster/backend_config.ini
Create database directory:
install -v -m 755 -o zonemaster -g zonemaster -d /var/db/zonemaster
Some parameters can be changed, see the backend configuration documentation for details.
5.2.2 Instructions for other engines (FreeBSD)
See sections for MySQL and PostgreSQL.
5.3 Database configuration (FreeBSD)
Create the database tables:
su -m zonemaster -c "`perl -MFile::ShareDir -le 'print File::ShareDir::dist_dir(qw(Zonemaster-Backend))'`/create_db.pl"
5.4 Service startup (FreeBSD)
Enable services at startup and start service:
sysrc zm_rpcapi_enable="YES"
sysrc zm_testagent_enable="YES"
service zm_rpcapi start
service zm_testagent start
If you have changed database daemon, restart the services:
service zm_rpcapi restart
service zm_testagent restart
5.5 Post-installation (FreeBSD)
To check that the running daemons run:
service zm_rpcapi status
service zm_testagent status
See the post-installation section for post-installation matters.
6. Post-installation
6.1 Smoke test
If you have followed the installation instructions for Zonemaster::Backend above, you should be able to use the API on localhost port 5000 as below.
zmtest zonemaster.net
The command is expected to immediately print out a testid, followed by a percentage ticking up from 0% to 100%. Once the number reaches 100% a JSON object is printed and zmtest terminates.
6.2 Troubleshooting installation
If you have any issue with installation, and installed with cpanm
, redo the
installation above but without the --notest
and with the --verbose
option.
Installation will take longer time.
6.3. What to do next?
- For the Zonemaster-Backend functions see the following documents:
- Using Zonemaster-Backend JSON-RPC API
- Backend JSON-RPC API documentation
- Using Zonemaster-Backend for batch testing
- Backend configuration
- Zonemaster Profiles
- Backend Environment variables
- For a web interface, follow the Zonemaster::GUI installation instructions.
- For a command line interface, follow the Zonemaster::CLI installation instruction.
7. Installation with MariaDB
First follow the installation instructions for the OS in question, and then go to this section to install MariaDB.
7.1. MariaDB (Rocky Linux)
Configure Zonemaster::Backend to use the correct database engine:
sudo sed -i '/\bengine\b/ s/=.*/= MySQL/' /etc/zonemaster/backend_config.ini
Note: See the backend configuration documentation for details.
Install database engine:
sudo dnf -y install mariadb-server perl-DBD-mysql
To create the database and the database user (unless you keep an old database). Edit the commands first if you want a non-default database name, user name or password. To be safe, run the commands one by one.
sudo systemctl start mariadb
sudo mysql -e "CREATE DATABASE zonemaster;"
sudo mysql -e "CREATE USER 'zonemaster'@'localhost' IDENTIFIED BY 'zonemaster';"
sudo mysql -e "GRANT ALL ON zonemaster.* TO 'zonemaster'@'localhost';"
Update the /etc/zonemaster/backend_config.ini
file with database name,
username and password if non-default values are used.
Now go back to "Database configuration" to create the database tables and then continue with the steps after that.
7.2. MariaDB (Debian/Ubuntu)
Configure Zonemaster::Backend to use the correct database engine:
sudo sed -i '/\bengine\b/ s/=.*/= MySQL/' /etc/zonemaster/backend_config.ini
Note: See the backend configuration documentation for details.
Install the database engine and its dependencies:
sudo apt install mariadb-server libdbd-mysql-perl
To create the database and the database user (unless you keep an old database). Edit the commands first if you want a non-default database name, user name or password. To be safe, run the commands one by one.
sudo mysql -e "CREATE DATABASE zonemaster;"
sudo mysql -e "CREATE USER 'zonemaster'@'localhost' IDENTIFIED BY 'zonemaster';"
sudo mysql -e "GRANT ALL ON zonemaster.* TO 'zonemaster'@'localhost';"
Update the /etc/zonemaster/backend_config.ini
file with database name, username
and password if non-default values are used.
Now go back to "Database configuration" to create the database tables and then continue with the steps after that.
7.3. MySQL (FreeBSD)
MariaDB is not compatible with Zonemaster on FreeBSD. MySQL is used instead.
Configure Zonemaster::Backend to use the correct database engine:
sed -i '' '/[[:<:]]engine[[:>:]]/ s/=.*/= MySQL/' /usr/local/etc/zonemaster/backend_config.ini
Note: See the backend configuration documentation for details.
Install, configure and start database engine (and Perl bindings):
pkg install mysql80-server p5-DBD-mysql
sysrc mysql_enable="YES"
service mysql-server start
By default the MySQL root password is empty. Just press ENTER if prompted for password. The advice is to set a password.
To create the database and the database user (unless you keep an old database). Edit the command first if you want a non-default database name, user name or password. Run the command on one line. Use the MySQL root password when prompted.
mysql -u root -p -e "CREATE DATABASE zonemaster;" -e "CREATE USER 'zonemaster'@'localhost' IDENTIFIED BY 'zonemaster';" -e "GRANT ALL ON zonemaster.* TO 'zonemaster'@'localhost';"
Update the /usr/local/etc/zonemaster/backend_config.ini
file with database
name, username and password if non-default values are used.
Now go back to "Database configuration" to create the database tables and then continue with the steps after that.
8. Installation with PostgreSQL
First follow the installation instructions for the OS in question, and then go to this section to install PostgreSQL.
8.1. PostgreSQL (Rocky Linux)
Configure Zonemaster::Backend to use the correct database engine:
sudo sed -i '/\bengine\b/ s/=.*/= PostgreSQL/' /etc/zonemaster/backend_config.ini
Note: See the backend configuration documentation for details.
Install, initialize and configure database engine:
sudo dnf -y install postgresql-server perl-DBD-Pg
sudo postgresql-setup --initdb --unit postgresql
sudo sed -i '/^[^#]/ s/ident$/md5/' /var/lib/pgsql/data/pg_hba.conf
To create the database and the database user (unless you keep an old database). Edit the command first if you want a non-default database name, user name or password. To be safe run the commands one by one.
sudo systemctl start postgresql
sudo -u postgres psql -c "CREATE USER zonemaster WITH PASSWORD 'zonemaster';"
sudo -u postgres psql -c "CREATE DATABASE zonemaster WITH OWNER 'zonemaster' ENCODING 'UTF8';"
Note: You may get error messages from these commands about lack of permission to change directory. You can safely ignore those messages.
Update the /etc/zonemaster/backend_config.ini
file with database name, username
and password if non-default values are used.
Now go back to "Database configuration" to create the database tables and then continue with the steps after that.
8.2. PostgreSQL (Debian/Ubuntu)
Configure Zonemaster::Backend to use the correct database engine:
sudo sed -i '/\bengine\b/ s/=.*/= PostgreSQL/' /etc/zonemaster/backend_config.ini
Install the database engine and Perl bindings:
sudo apt install postgresql libdbd-pg-perl
Note: See the backend configuration documentation for details.
To create the database and the database user (unless you keep an old database). Edit the command first if you want a non-default database name, user name or password. To be safe run the commands one by one.
sudo -u postgres psql -c "CREATE USER zonemaster WITH PASSWORD 'zonemaster';"
sudo -u postgres psql -c "CREATE DATABASE zonemaster WITH OWNER 'zonemaster' ENCODING 'UTF8';"
Update the /etc/zonemaster/backend_config.ini
file with database name, username
and password if non-default values are used.
Now go back to "Database configuration" to create the database tables and then continue with the steps after that.
8.3. PostgreSQL (FreeBSD)
Configure Zonemaster::Backend to use the correct database engine:
sed -i '' '/[[:<:]]engine[[:>:]]/ s/=.*/= PostgreSQL/' /usr/local/etc/zonemaster/backend_config.ini
Note: See the backend configuration documentation for details.
Install, configure and start database engine and Perl bindings:
pkg install p5-DBD-Pg
The Perl bindings library (p5-DBD-Pg
) has a dependency to a specific version
of postgresql-client
. Determine what version was installed:
pkg info | grep postgresql | grep client
Replace XX
in the command below to install postgresql-server
with the same
major version as the installed postgresql-client
, e.g. 16
.
pkg install postgresqlXX-server
Enable daemon, initiate and start:
sysrc postgresql_enable="YES"
service postgresql initdb
service postgresql start
To create the database and the database user (unless you keep an old database). Edit the commands first if you want a non-default database name, user name or password.
psql -U postgres -c "CREATE USER zonemaster WITH PASSWORD 'zonemaster';"
psql -U postgres -c "CREATE DATABASE zonemaster WITH OWNER 'zonemaster' ENCODING 'UTF8';"
Update the /usr/local/etc/zonemaster/backend_config.ini
file with database
name, username and password if non-default values are used.
Now go back to "Database configuration" to create the database tables and then continue with the steps after that.
9. Cleaning up the database
If, at some point, you want to delete all traces of Zonemaster in the database,
you can run the file cleanup-mysql.sql
or file cleanup-postgres.sql
as a database administrator. Commands
for locating and running the file are below. It removes the user and drops the
database (obviously taking all data with it).
Each script uses default values, you may need to adapt them to your setup.
9.1. MariaDB and MySQL
Rocky Linux, Debian and Ubuntu:
sudo mysql --user=root < `perl -MFile::ShareDir -le 'print File::ShareDir::dist_dir("Zonemaster-Backend")'`/cleanup-mysql.sql
FreeBSD (you will get prompted for MySQL password):
mysql --user=root -p < `perl -MFile::ShareDir -le 'print File::ShareDir::dist_dir("Zonemaster-Backend")'`/cleanup-mysql.sql
9.2. PostgreSQL
Rocky Linux, Debian and Ubuntu:
sudo -u postgres psql -f $(perl -MFile::ShareDir=dist_dir -E 'say dist_dir("Zonemaster-Backend")')/cleanup-postgres.sql
FreeBSD (as root):
psql -U postgres -f `perl -MFile::ShareDir -le 'print File::ShareDir::dist_dir("Zonemaster-Backend")'`/cleanup-postgres.sql
9.3. SQLite
Remove the database file and recreate it following the installation instructions above.
10. Optional features
10.1 Metrics
Statsd metrics are available, to enable the feature install the additional
Net::Statsd
module. See the configuration to
configure the receiver.
The list of metrics is available in the Telemetry document.
10.1.1 Installation on Rocky Linux
sudo cpanm --notest Net::Statsd
10.1.2 Installation on Debian / Ubuntu
sudo apt install libnet-statsd-perl
10.1.3 Installation on Freebsd
cpanm --notest Net::Statsd
10.2 Global cache
If Zonemaster-Backend is to be used for large batches, global cache can improve performance. See Global cache in Zonemaster-Engine.
Installation: Zonemaster-GUI
Prerequisites
Before installing Zonemaster Web GUI, you should install Zonemaster::Engine and Zonemaster::Backend.
Prerequisite for FreeBSD is that the package system is updated and activated, see FreeBSD section of install Zonemaster::Engine.
Installation
This instruction covers the following operating systems:
1. Rocky Linux
Install Apache
sudo dnf update
sudo dnf -y install httpd unzip
Install Zonemaster Web GUI
curl -L -O https://github.com/zonemaster/zonemaster-gui/releases/download/v4.3.1/zonemaster_web_gui.zip
sudo install -vd /var/www/html/zonemaster-web-gui
sudo install -vd /var/log/zonemaster
sudo unzip -d /var/www/html/zonemaster-web-gui zonemaster_web_gui.zip
rm -f zonemaster_web_gui.zip
Configure Apache site
sudo chcon -R -t httpd_sys_content_t /var/www/html/zonemaster-web-gui/dist
sudo chcon -R -t httpd_sys_rw_content_t /var/log/zonemaster
sudo setsebool -P httpd_can_network_connect=1
sudo install -v /var/www/html/zonemaster-web-gui/zonemaster.conf-example /etc/httpd/conf.d/zonemaster.conf
Optionally update the zonemaster.conf. E.g. if Zonemaster-Backend RPCAPI runs on another server or on another port (not port 5000), update ProxyPass and ProxyPassReserve. Or if you want provide your own settings for ServerName, ServerAlias and ServerAdmin.
sudoedit /etc/httpd/conf.d/zonemaster.conf
Start Apache and allow remote access
sudo systemctl enable httpd
sudo systemctl start httpd
sudo firewall-cmd --add-service http --permanent
sudo firewall-cmd --reload
2. Debian and Ubuntu
Install Apache
sudo apt-get update && sudo apt-get upgrade -y
sudo apt-get install -y apache2 unzip
Basic Apache configuration
sudo a2enmod proxy proxy_http rewrite
sudo a2dissite 000-default
sudo systemctl enable apache2
sudo systemctl restart apache2
Install Zonemaster Web GUI
wget https://github.com/zonemaster/zonemaster-gui/releases/download/v4.3.1/zonemaster_web_gui.zip -O zonemaster_web_gui.zip
sudo unzip -d /var/www/html/zonemaster-web-gui zonemaster_web_gui.zip
sudo install -vd /var/log/zonemaster
sudo install -v /var/www/html/zonemaster-web-gui/zonemaster.conf-example /etc/apache2/sites-available/zonemaster.conf
rm -f zonemaster_web_gui.zip
Configure Zonemaster Web GUI
sudo a2ensite zonemaster #Activate the website
Then update the zonemaster.conf file with your own ServerName, ServerAlias and ServerAdmin. For testing on a local machine, you can edit zonemaster.conf and change the "*:80" part of to the host's IP or using localhost as ServerName if that is appropriate.
Reload Apache
sudo systemctl reload apache2
3. FreeBSD
For all commands below become root:
su -l
Update list of package repositories
Create the file /usr/local/etc/pkg/repos/FreeBSD.conf
with the following
content, unless it is already updated:
FreeBSD: {
url: "pkg+http://pkg.FreeBSD.org/${ABI}/latest",
}
Check or activate the package system
Run the following command, and accept the installation of the pkg
package
if suggested.
pkg info -E pkg
Update local package repository:
pkg update -f
Install Apache and its dependencies
See tutorial on Apache on FreeBSD.
pkg install apache24
Enable Apache as a service
sysrc apache24_enable=yes
Enable three apache modules in Apache configuration file
perl -pi -e 's/^#(LoadModule (proxy_module|proxy_http_module|rewrite_module) libexec)/$1/' /usr/local/etc/apache24/httpd.conf
Start Apache
service apache24 start
If you want Apache to listen to an external IP address and it says that it only
listens to localhost (127.0.0.1/::1) then you have to set ServerName
in
/usr/local/etc/apache24/httpd.conf
, e.g. ServerName 192.0.2.246:80
, and
restart Apache.
Install Zonemaster Web GUI
fetch https://github.com/zonemaster/zonemaster-gui/releases/download/v4.3.1/zonemaster_web_gui.zip
mkdir -p /var/www/html/zonemaster-web-gui
mkdir -p /var/log/zonemaster
unzip -d /var/www/html/zonemaster-web-gui zonemaster_web_gui.zip
rm zonemaster_web_gui.zip
Basic Apache configuration
install /var/www/html/zonemaster-web-gui/zonemaster.conf-example /usr/local/etc/apache24/Includes/zonemaster.conf
Then update /usr/local/etc/apache24/Includes/zonemaster.conf
with your own ServerAdmin.
If Zonemaster-Backend RPCAPI runs on another server or on another port (not port 5000)
then update the URL for the ProxyPass
and ProxyPassReverse
keys in the same
file so that it points to correct IP address or server name and correct port.
Restart Apache
service apache24 restart
Post-installation sanity check
Make sure Zonemaster-GUI is properly installed.
-
Point your browser at
http://localhost/
(or the address of the server where you installed Zonemaster Web GUI). -
Verify that the Zonemaster Web GUI is shown with the text "Program versions" in its page footer.
-
Verify that when you mouse over this text the versions of the following Zonemaster components are shown: Zonemaster-LDNS, Zonemaster-Engine, Zonemaster-Backend and Zonemaster-GUI.
What to do next?
- For a JSON-RPC API, see the Zonemaster::Backend JSON-RPC API documentation.
- For a command line interface, follow the Zonemaster::CLI installation instruction.
- For a Perl API, see the Zonemaster::Engine API documentation.
- For HTTPS, see Let's Encrypt / Certbot.
Serving the GUI and API from a custom base url
In some cases you may want to customize the application to change the base URL from wich the GUI is served.
-
In the
index.html
files, (/var/www/html/zonemaster-web-gui/dist/*/index.html
if you followed this installation guide), locate the line<base href="/">
and replace thehref
value with the path you want to server the GUI from. You can use the following command to update the base URL in all files:export BASE_URL=/zonemaster; find /var/www/html/zonemaster-web-gui/dist -name index.html | xargs sed -r "s%<base href=\"[^\"]*/([a-z]{2})/\">%<base href=\"$BASE_URL/\1/\">%" -i
You can change the
BASE_URL
variable to the path (without trailing slash) that you want. -
When serving the application from a different base, you will also need to change the Web server configuration in
zonemaster.conf
(location is found in the installation instructions above) by updating theBASE_URL
variable and adding anAlias
directive as in the following example:Define BASE_URL "/zonemaster/" Alias "/zonemaster" "/var/www/html/zonemaster-web-gui/dist"
-
Update or create
app.config.json
(/var/www/html/zonemaster-web-gui/dist/assets/app.config.json
in a default installation) by settingapiEndpoint
to/zonemaster/api
as below. See Configuration.md and the example configurationapp.config.sample.json
.{ "apiEndpoint": "/zonemaster/api" }
-
Reload Apache.
-
Point you browser to the new base URL.
NOTE: Don't forget to apply the changes to the index.html
and Web
server configuration after each update as those files will be overwritten.
Change default language
To change the default language update the Apache configuration in zonemaster.conf
that was installed in a previous section. Locate the last RewriteRule
:
# Default locale
RewriteRule ^$ /en/ [R,L]
and change it to
# Default locale
RewriteRule ^$ /<LANG>/ [R,L]
where <LANG>
is the language code of you choice.
Docker
Zonemaster-CLI is available on Docker Hub, and can be conveniently downloaded and run without any installation. Through Docker Zonemaster-CLI can be run on Linux, macOS and Windows. See USING Zonemaster-CLI for how to run Zonemaster-CLI on Docker.
To build your own Docker image, see the Docker Image Creation documentation.
Upgrading
Upgrading Zonemaster is usually a straightforward process. The only component that may require manual intervention is Zonemaster-Backend. See the instructions on upgrading Zonemaster-Backend for more information.
For other components, simply re-run the installation steps to get the updated version.
Upgrade Backend
1. Overview
This document contains pointer to instructions on how to upgrade the Zonemaster::Backend component. An upgrade usually consist of an upgrade script to upgrade the database, and instructions to install new dependencies.
When upgrading from a version < v6.2.0 to a version ≥ v8.0.0, it is recommended to install the desired version following the Installation instructions skipping the part about the database if you want to keep it. To upgrade the database, apply each upgrade instructions one after another (see table below).
2. Prerequisites
Upgrade Zonemaster::LDNS and Zonemaster::Engine first following instructions within the Zonemaster::Engine installation document.
3. Upgrading Zonemaster::Backend
To upgrade Zonemaster::Backend perform the following tasks:
- stop the
zm-rpcapi
andzm-testagent
daemons (zm_rpcapi
andzm_testagent
on FreeBSD) - remove old files with
cpanm --uninstall Zonemaster::Backend
- install any new dependencies (see corresponding upgrade document below)
- install the latest version from CPAN with
cpanm Zonemaster::Backend
- apply any remaining instructions specific to this new release
- start the
zm-rpcapi
andzm-testagent
daemons (zm_rpcapi
andzm_testagent
on FreeBSD)
Specific upgrade instructions
Always make a backup of the database before upgrading it.
When upgrading Zonemaster::Backend, it might be needed to upgrade the database and/or install new dependencies. Such instructions are available in the upgrade document coming with the release. See table below to refer to the right document.
When upgrading from an older version than the previous release, apply each upgrade instructions one after another.
Current Zonemaster::Backend version | Link to instructions | Comments |
---|---|---|
version < 1.0.3 | Upgrade to 1.0.3 | |
1.0.3 ≤ version < 1.1.0 | Upgrade to 1.1.0 | |
1.1.0 ≤ version < 5.0.0 | Upgrade to 5.0.0 | |
5.0.0 ≤ version < 5.0.2 | Upgrade to 5.0.2 | For MySQL/MariaDB only |
5.0.2 ≤ version < 8.0.0 | Upgrade to 8.0.0 | |
8.0.0 ≤ version < 9.0.0 | Upgrade to 9.0.0 | |
9.0.0 ≤ version < 11.1.0 | Upgrade to 11.1.0 | |
11.1.0 ≤ version < 11.2.0 | Upgrade to 11.2.0 | |
11.2.0 ≤ version | - | No special steps needed for upgrade |
4. Find current version
The following command will report the version of Zonemaster-Backend currently
installed. If an error is report Zonemaster-Backend is not installed or not
available for the user. If so, consider tunning the command as root or with
sudo
.
perl -E 'use Zonemaster::Backend; say $Zonemaster::Backend::VERSION;'
Upgrade to 1.0.3
Upgrading the database
If your Zonemaster database was created by a Zonemaster-Backend version smaller than v1.0.3, and not upgraded, use the following instructions.
FreeBSD
If the installation is on FreeBSD, then the environment maybe has to be set before
running any of the commands below. Check where backend_config.ini
is located.
export ZONEMASTER_BACKEND_CONFIG_FILE="/usr/local/etc/zonemaster/backend_config.ini"
MySQL
Run
cd $(perl -MFile::ShareDir -le 'print File::ShareDir::dist_dir("Zonemaster-Backend")')
perl patch/patch_mysql_db_zonemaster_backend_ver_1.0.3.pl
PostgreSQL
Run
cd $(perl -MFile::ShareDir -le 'print File::ShareDir::dist_dir("Zonemaster-Backend")')
perl patch/patch_postgresql_db_zonemaster_backend_ver_1.0.3.pl
Upgrade to 1.1.0
Upgrading the database
If your Zonemaster database was created by a Zonemaster-Backend version smaller than v1.1.0, and not upgraded, use the following instructions.
MySQL
ALTER TABLE test_results ADD queue INTEGER DEFAULT 0;
PostgreSQL
ALTER TABLE test_results ADD queue INTEGER DEFAULT 0;
Upgrade to 5.0.0
Upgrading the database
If your Zonemaster database was created by a Zonemaster-Backend version smaller than v5.0.0, and not upgraded, use the following instructions.
FreeBSD
If the installation is on FreeBSD, then set the environment before running any of the commands below:
export ZONEMASTER_BACKEND_CONFIG_FILE="/usr/local/etc/zonemaster/backend_config.ini"
MySQL (or MariaDB)
Run
cd $(perl -MFile::ShareDir -le 'print File::ShareDir::dist_dir("Zonemaster-Backend")')
perl patch/patch_mysql_db_zonemaster_backend_ver_5.0.0.pl
PostgreSQL
Run
cd $(perl -MFile::ShareDir -le 'print File::ShareDir::dist_dir("Zonemaster-Backend")')
perl patch/patch_postgresql_db_zonemaster_backend_ver_5.0.0.pl
Upgrade to 5.0.2
Upgrading the database
If your Zonemaster database was created by a Zonemaster-Backend version smaller than v5.0.2, and not upgraded, use the following instructions.
FreeBSD
If the installation is on FreeBSD, then set the environment before running any of the commands below:
export ZONEMASTER_BACKEND_CONFIG_FILE="/usr/local/etc/zonemaster/backend_config.ini"
MySQL (or MariaDB)
Run
cd $(perl -MFile::ShareDir -le 'print File::ShareDir::dist_dir("Zonemaster-Backend")')
perl patch/patch_mysql_db_zonemaster_backend_ver_5.0.2.pl
PostgreSQL
No patching (upgrading) is needed on zonemaster database on PostgreSQL for this version of Zonemaster-Backend.
Upgrade to 8.0.0
On FreeBSD run the following command first to become root:
su -l
New dependencies
Zonemaster::Backend requires new dependencies. Depending on the used OS, run the corresponding command.
Rocky Linux
sudo dnf install perl-libintl perl-Mojolicious
sudo cpanm Plack::Middleware::ReverseProxy
Debian / Ubuntu
sudo apt-get install libplack-middleware-reverseproxy-perl libintl-perl libmojolicious-perl
Specific to Ubuntu
sudo cpanm JSON::Validator
FreeBSD
pkg install p5-Plack-Middleware-ReverseProxy p5-Locale-libintl p5-Mojolicious
Changes in the ini file
New sections and properties have been added to the backend_config.ini
file.
By default the add_api_user
method is disabled. To enable it, add the
following to your backend_config.ini
file:
[RPCAPI]
enable_add_api_user = yes
See the Configuration document for more information.
Upgrading init scripts
The zm-rpcapi
(zm_rpcapi
on FreeBSD) init script has been updated. It needs
to be reinstalled.
Rocky Linux
cd `perl -MFile::ShareDir=dist_dir -E 'say dist_dir("Zonemaster-Backend")'`
sudo install -v -m 755 ./zm-rpcapi.lsb /etc/init.d/zm-rpcapi
Debian / Ubuntu
cd `perl -MFile::ShareDir=dist_dir -E 'say dist_dir("Zonemaster-Backend")'`
sudo install -v -m 755 ./zm-rpcapi.lsb /etc/init.d/zm-rpcapi
FreeBSD
cd `perl -MFile::ShareDir=dist_dir -E 'say dist_dir("Zonemaster-Backend")'`
install -v -m 755 ./zm_rpcapi-bsd /usr/local/etc/rc.d/zm_rpcapi
Upgrading the database
If your Zonemaster database was created by a Zonemaster-Backend version smaller than v8.0.0, and not upgraded, use the following instructions.
Depending on the database size this upgrade can take some time (around 30 minutes for a database with 1 million entries)
You may need to run the command with
sudo
.
SQLite
Run
cd `perl -MFile::ShareDir -le 'print File::ShareDir::dist_dir("Zonemaster-Backend")'`
perl patch/patch_sqlite_db_zonemaster_backend_ver_8.0.0.pl
MySQL (or MariaDB)
First update the privileges of the zonemaster
user:
- Linux
sudo mysql -e "GRANT ALL ON zonemaster.* TO 'zonemaster'@'localhost';"
- FreeBSD
mysql -u root -p -e "GRANT ALL ON zonemaster.* TO 'zonemaster'@'localhost';"
then run
cd `perl -MFile::ShareDir -le 'print File::ShareDir::dist_dir("Zonemaster-Backend")'`
perl patch/patch_mysql_db_zonemaster_backend_ver_8.0.0.pl
PostgreSQL
Run
cd `perl -MFile::ShareDir -le 'print File::ShareDir::dist_dir("Zonemaster-Backend")'`
perl patch/patch_postgresql_db_zonemaster_backend_ver_8.0.0.pl
Upgrade to 9.0.0
Upgrading the database
If your Zonemaster database was created by a Zonemaster-Backend version smaller than v9.0.0, and not upgraded, use the following instruction.
You may need to run these command with root privileges.
Preparation when using MariaDB
If you're using MariaDB you need to make a backup of your database before upgrading its schema.
mysqldump zonemaster > backup-file.sql
In case the schema upgrade fails you may need to restore the backup before trying again.
mysql zonemaster < backup-file.sql
Upgrade database schema
cd `perl -MFile::ShareDir -le 'print File::ShareDir::dist_dir("Zonemaster-Backend")'`
perl patch/patch_db_zonemaster_backend_ver_9.0.0.pl
Upgrade to 11.1.0
Upgrading the database
If your Zonemaster database was created by a Zonemaster-Backend version smaller than v11.1.0, and not upgraded, use the following instruction.
You may need to run these command with root privileges.
Warning: this database update will result in an increase of the used size. Make sure you have enough free disk space before upgrading. Depending on the database engine, you may need up to 5 times the database size of free space.
Upgrade database schema
cd `perl -MFile::ShareDir -le 'print File::ShareDir::dist_dir("Zonemaster-Backend")'`
perl patch/patch_db_zonemaster_backend_ver_11.1.0.pl
Upgrade to 11.2.0
Upgrading the database
If your Zonemaster database was created by a Zonemaster-Backend version smaller than v11.2.0, and not upgraded, use the following instructions.
You may need to run these command with root privileges.
Migration script
The following script fixes existing untranslated entries that were missed between Zonemaster-Backend v11.1.0 (release v2023.2) and this version (release v2024.1).
cd `perl -MFile::ShareDir -le 'print File::ShareDir::dist_dir("Zonemaster-Backend")'`
perl patch/patch_db_zonemaster_backend_ver_11.2.0.pl
Configuration
This section contains information about configuration of the different components of Zonemaster:
- Setting up or modifying the profile in Zonemaster-Engine.
- Enabling the global cache feature (experimental)
- Configuring Zonemaster-Backend in the Backend configuration file.
- Using environment variables for Zonemaster-Backend.
- Configuring Zonemaster-GUI in the GUI configuration file.
Profiles
Default profile
The default profile is documented in the profile properties section of the Zonemaster::Engine::Profile module.
The default profile can be extracted from Zonemaster-Engine to a file using this command.
perl -MZonemaster::Engine::Test -E 'say Zonemaster::Engine::Profile->default->to_json' | jq -S . > profile.json
Creating profiles
Some properties are empty by default such as logfilter
and
test_cases_vars
. Those properties are not present in the default
profile. For an example of their usage, refer to the additional file,
profile_additional_properties.json.
The content of the two files, as-is or modified, can be merged into a custom profile file that can be loaded by Zonemaster-Engine. Both Zonemaster-CLI and Zonemaster-Backend have direct options for loading a custom profile file.
A custom profile file only has to contain those properties that it should override.
Configuration: Global cache in Zonemaster-Engine
Table of contents
- Introduction
- Prerequisites
- Installation for global cache
- Create directory for custom profile
- Enable global cache
- Using global cache
Introduction
Global cache is a feature that can increase performance when many tests are run within a short time frame, especially when they share some data such as using the same name server names. The global cache is meant for batch testing rather than single tests through the GUI. In the latter case it is desirable that Zonemaster checks again since the zone may have been corrected due to the report in a very recent test.
The global cache improves the caching function by making the DNS lookups from
one test to be available for further tests. The cache is stored in Redis
, a
cache service running in a separate daemon.
To enable global caching, additional software has to be installed and custom profile has to be created, where global caching is enabled.
Prerequisites
Before installing or enabling global cache you must follow the
Zonemaster::Engine installation first. The feature is available from version
v5.0.0
of Zonemaster-Engine.
For installation on FreeBSD being user root is assumed.
Installation for global cache
Install the Redis
daemon and needed Perl library. And then start the Redis
daemon. It will listen to localhost and default port.
Rocky Linux
sudo dnf --assumeyes install redis perl-Redis perl-Data-MessagePack
sudo systemctl enable redis
sudo systemctl start redis
Debian and Ubuntu
sudo apt install redis libredis-perl libdata-messagepack-perl
sudo systemctl enable redis
sudo systemctl start redis
FreeBSD
pkg install -y redis p5-Redis p5-Data-MessagePack
sysrc redis_enable="YES"
service redis start
Create directory for custom profile
Create a directory to be used for a custom profile, which is here the same directory as used by Zonemaster-Backend. And then copy the default profile to this directory.
Rocky Linux, Debian and Ubuntu
test -d /etc/zonemaster || sudo mkdir -v /etc/zonemaster
perl -MZonemaster::Engine::Test -E 'say Zonemaster::Engine::Profile->default->to_json' | jq -S . | sudo tee /etc/zonemaster/profile.json > /dev/null
FreeBSD
test -d /usr/local/etc/zonemaster || mkdir -v /usr/local/etc/zonemaster
perl -MZonemaster::Engine::Test -E 'say Zonemaster::Engine::Profile->default->to_json' | jq -S . > /usr/local/etc/zonemaster/profile.json
Enable global cache
Update /etc/zonemaster/profile.json
(or /usr/local/etc/zonemaster/profile.json
for FreeBSD) by adding a cache section. If the profile already has an empty cache
section (i.e. "cache": {}
) then it must be removed. Add the following section,
"cache": {
"redis": {
"server": "127.0.0.1:6379",
"expire": 7200
}
},
The expire
value can be increased or decreased to increase or decrease the time
in seconds that Redis
will cache the data. Caching of specific DNS data is
never longer than the normal DNS TTL value.
Using global cache
If Zonemaster-CLI has been installed, then
run zonemaster-cli
with --profile /etc/zonemaster/profile.json
(or --profile /usr/local/etc/zonemaster/profile.json
for FreeBSD) to use the
global cache. Caching will persist between test unless it has expired.
See man zonemaster-cli
and look for cli.args
for how to make it the custom
profile being the default profile for zonemaster-cli
.
See Zonemaster::Backend configuration for how to make the custom profile being used for Zonemaster-Backend and Zonemaster-GUI.
For more documentation on profiles, see profile documentation.
Configuration
Table of contents
- Introduction
- RPCAPI section
- DB section
- MYSQL section
- POSTGRESQL section
- SQLITE section
- LANGUAGE section
- METRICS section
- PUBLIC PROFILES and PRIVATE PROFILES sections
- ZONEMASTER section
Introduction
Zonemaster Backend is configured in
/etc/zonemaster/backend_config.ini
(Linux) or
/usr/local/etc/zonemaster/backend_config.ini
(FreeBSD). Following
Installation instructions will create the file with factory settings.
Restart the zm-rpcapi
and zm-testagent
daemons to load the changes
made to the backend_config.ini
file.
The backend_config.ini
file uses a file format in the INI family that is
described in detail here.
Repeating a key name in one section is forbidden.
Each section in backend_config.ini
is documented below.
In addition to the configuration file, some settings can configured using environment variables.
RPCAPI section
Available keys: enable_batch_create
, enable_user_create
,
enable_add_batch_job
, enable_add_api_user
.
enable_add_batch_job
Boolean value to enable the add_batch_job
and batch_create
methods of the API.
Accepted values: yes
(or true
) or no
(or false
),
default to yes
(enabled).
enable_add_api_user
Boolean value to enable the add_api_user
and user_create
method of the API.
Accepted values: yes
(or true
) or no
(or false
),
default to no
(disabled).
enable_batch_create
An experimental alias for enable_add_batch_job.
enable_user_create
An experimental alias for enable_add_api_user.
DB section
Available keys : engine
, user
, password
, database_name
,
database_host
, polling_interval
.
engine
Specifies what database engine to use.
The value must be one of the following, case-insensitively: MySQL
,
PostgreSQL
and SQLite
.
This table declares what value to use for each supported database engine.
Database Engine | Value |
---|---|
MariaDB | MySQL |
MySQL | MySQL |
PostgreSQL | PostgreSQL |
SQLite | SQLite |
polling_interval
A strictly positive decimal number. Max 5 and 3 digits in the integer and fraction components respectively.
Time in seconds between database lookups by Test Agent.
Default value: 0.5
.
MYSQL section
Available keys : host
, port
, user
, password
, database
.
host
An LDH domain name or IP address.
The host name of the machine on which the MySQL server is running.
port
The port the MySQL server is listening on.
Default value: 3306
.
If MYSQL.host is set to localhost
(but neither 127.0.0.1
nor ::1
),
then the value of the MYSQL.port property is discarded as the driver
connects using a UNIX socket (see the DBD::mysql documentation).
user
An ASCII-only MariaDB unquoted identifier. Max length 80 characters.
The name of the user with sufficient permission to access the database.
password
A string of US ASCII printable characters.
The first character must be neither space nor <
.
Max length 100 characters.
The password of the configured user.
database
A US ASCII-only MariaDB unquoted identifier. Max length 64 characters.
The name of the database to use.
POSTGRESQL section
Available keys : host
, port
, user
, password
, database
.
host
An LDH domain name or IP address.
The host name of the machine on which the PostgreSQL server is running.
port
The port the PostgreSQL server is listening on.
Default value: 5432
.
user
A US ASCII-only PostgreSQL identifier. Max length 63 characters.
The name of the user with sufficient permission to access the database.
password
A string of US ASCII printable characters.
The first character must be neither space nor <
.
Max length 100 characters.
The password of the configured user.
database
A US ASCII-only PostgreSQL identifier. Max length 63 characters.
The name of the database to use.
SQLITE section
Available keys : database_file
.
database_file
An absolute path.
The full path to the SQLite main database file.
LANGUAGE section
The LANGUAGE section has one key, locale
.
locale
A string representing a space-separated list of one or more locale tags
.
Each tag consists of a two-lowercase-letter language code, an underscore
character, and a two-uppercase-letter country code (i.e. it matches the regular
expression /^[a-z]{2}_[A-Z]{2}$/
).
Each locale tag
must have a unique language code.
Default value: en_US
.
Design
The language code of a locale tag
is intended to be an ISO 639-1 code.
The country code is intended to be an ISO 3166-1 alpha-2 code.
A locale tag
is a locale setting for the available translation
of messages without ".UTF-8", which is implied.
Usage
Removing a language from the configuration file just blocks that language from being allowed.
English is the Zonemaster default language, but it can be blocked
from being allowed by RPC-API by including some locale tag
in the
configuration, but none starting with language code for English ("en").
Out-of-the-box support
The default installation and configuration supports the following languages.
Language | Locale tag value | Language code | Locale value used |
---|---|---|---|
Danish | da_DK | da | da_DK.UTF-8 |
English | en_US | en | en_US.UTF-8 |
Spanish | es_ES | es | es_ES.UTF-8 |
Finnish | fi_FI | fi | fi_FI.UTF-8 |
French | fr_FR | fr | fr_FR.UTF-8 |
Norwegian | nb_NO | nb | nb_NO.UTF-8 |
Swedish | sv_SE | sv | sv_SE.UTF-8 |
Setting in the default configuration file:
locale = da_DK en_US es_ES fi_FI fr_FR nb_NO sv_SE
Installation considerations
If a new locale tag
is added to the configuration then the equivalent
MO file should be added to Zonemaster-Engine at the correct place so
that gettext can retrieve it, or else the added locale tag
will not
add any actual language support. The MO file should be created for the
language code
of the locale tag
(see the table above), not the entire
locale tag
. E.g. if the locale
configuration key includes "sv_SE" then
a MO file for "sv" should be included in the installation.
Use of MO files based on the entire locale tag
is deprecated.
See the Zonemaster-Engine share directory for the existing PO files that are converted to MO files during installation. (Here we should have a link to documentation instead.)
Each locale set in the configuration file, including the implied ".UTF-8", must also be installed or activate on the system running the RPCAPI daemon for the translation to work correctly.
METRICS section
statsd_host
An LDH domain name or IP address.
The host name of the machine on which the StatsD receiver is running.
Leave unspecified to disable the metrics.
Note that this feature requires the Net::Statsd
module to be installed.
statsd_port
The port the StatsD receiver is listening on.
Default value: 8125
.
PUBLIC PROFILES and PRIVATE PROFILES sections
The PUBLIC PROFILES and PRIVATE PROFILES sections together define the available profiles.
Keys in both sections are profile names
, and values are absolute file system
paths to profile JSON files. The key must conform to the character limitation
specified for profile name
as specified in the API document
Profile name section. Keys that only differ in case are considered to be equal.
Keys must not be duplicated between or within the sections, and the key
default
must not be present in the PRIVATE PROFILES section.
There is a default
profile that is special. It is always available even
if not specified. If it is not explicitly mapped to a profile JSON file, it is implicitly
mapped to the Zonemaster Engine default profile.
Each profile JSON file contains a (possibly empty) set of overrides to the Zonemaster Engine default profile. Specifying a profile JSON file that contains a complete set of profile data is equivalent to specifying a profile JSON file with only the parts that differ from the Zonemaster Engine default profile.
Specifying a profile JSON file that contains no profile data is equivalent to specifying a profile JSON file containing the entire Zonemaster Engine default profile.
ZONEMASTER section
The ZONEMASTER section has several keys :
- max_zonemaster_execution_time
- number_of_processes_for_frontend_testing
- number_of_processes_for_batch_testing
- lock_on_queue
- age_reuse_previous_test
max_zonemaster_execution_time
A strictly positive integer. Max length 5 digits.
Time in seconds before reporting an unfinished test as failed.
Default value: 600
.
number_of_processes_for_frontend_testing
A strictly positive integer. Max length 5 digits.
Number of processes allowed to run in parallel (added with
number_of_processes_for_batch_testing
).
Default value: 20
.
Despite its name, this key does not limit the number of process used by the
frontend, but is used in combination of
number_of_processes_for_batch_testing
.
number_of_processes_for_batch_testing
A non-negative integer. Max length 5 digits.
Number of processes allowed to run in parallel (added with
number_of_processes_for_frontend_testing
).
Default value: 20
.
Despite its name, this key does not limit the number of process used by any
batch pool of tests, but is used in combination of
number_of_processes_for_frontend_testing
.
lock_on_queue
A non-negative integer. Max length 5 digits.
A label to associate a test to a specific Test Agent.
Default value: 0
.
age_reuse_previous_test
A strictly positive integer. Max length 5 digits.
The shelf life of a test in seconds after its creation.
Default value: 600
.
If a new test is requested for the same zone name and parameters within the shelf life of a previous test result, that test result is reused. Otherwise a new test request is enqueued.
Environment variables
Variable used by both RPCAPI daemon and Test Agent daemon
ZONEMASTER_BACKEND_CONFIG_FILE
: Set a custom path for the backend configuration file.
Variables used by RPCAPI daemon only
ZM_BACKEND_RPCAPI_LOGLEVEL
: Configure the log level,trace
by default. Accepted values are:trace
debug
info
(also accepted:inform
)notice
warning
(also accepted:warn
)error
(also accepted:err
)critical
(also accepted:crit
,fatal
)alert
emergency
ZM_BACKEND_RPCAPI_LOGJSON
: Setting it to any thruthy value (non-empty string or non-zero number) will configure the logger to log in JSON format, undefined by default.
Variables used by unit test scripts
-
TARGET
: Set the database to use. If empty or undefined, "SQLite" will be assumed. Accepted values are:SQLite
PostgreSQL
MySQL
-
ZONEMASTER_RECORD
: Setting it to any thruthy value (non-empty string or non-zero number) will record the data from the test to a file. Otherwise the data is loaded from a file.
Configuration
The GUI can be configured by creating the file
DISTBASE/dist/assets/app.config.json
. "DISTBASE" is where the Zonemaster
Web GUI zip file is installed, which is /var/www/html/zonemaster-web-gui
by
default installation (see Installation instructions).
This file can by created by copying app.config.sample.json
found in
DISTBASE/dist/assets
:
cp app.config.sample.json app.config.json
The supported configuration items are the following.
"apiEndpoint"
: The URL to use to contact the API, default"/api"
. It could be either a full URL to use an API endpoint not located on the same origin as the one serving the GUI or just a path, like the default value, when both the API and GUI are served from the same origin."defaultLanguage"
: (Deprecated) This does not work anymore, to change the default language update the Apache configuration as mentioned in the installation instructions."enabledLanguages"
: An array of the languages enabled in the GUI, default[ "da", "en", "es", "fi", "fr", "nb", "sv" ]
."contactAddress"
: The contact email address displayed in the footer, default"contact@zonemaster.net"
."logoUrl
": The URL to the image displayed in the navigation bar, default"assets/images/zonemaster_logo_2021_color.png"
."msgBanner"
: A message to display to the user, if empty or undefined no banner will be shown. HTML formatting is supported (such as<a>
tag) and some characters such as&><
need to be written as HTML codes to be properly rendered."pollingInterval"
: Time between each test progress query in millisecond, default:5000
(5 seconds)."footerLogo"
: Optional logotype in the footer, default none (""), but else path to file."footerLogoAlt"
: Optional alternative text for the "footerLogo", only meaningful if "footerLogo" is defined. Typical "footerLogoAlt" is the name in "footerLogo".
Zonemaster users guide
The purpose of the Zonemaster project is to develop a DNS validation software. There are three ways one can use the Zonemaster software:
- Using the Web user Interface: In this case, there is no installation of the Zonemaster software needed. A user types the URL https://zonemaster.net, provides as input a domain name, and then can view the results.
- From the Command Line Interface (CLI): In this case, the user has to install two components of the Zonemaster software, i.e. the Zonemaster-Engine and the Zonemaster-CLI.
- There are cases, wherein an organisation or a user, that wants to have the results of their DNS validation stored and can be viewed later. In that case, in addition to the Zonemaster-Engine and Zonemaster-CLI, the user has to install the Zonemaster-Backend and the Zonemaster-GUI.
User guides:
Using the CLI
Table of contents
- Docker or local installation
- Invoking the command line tool using Docker
- Invoking the command line tool using local installation
- More details on the command line tool invocation
- Test reports
- Translation
- Advanced use
- Docker on Mac with M1 chip
Docker or local installation
The zonemaster-cli
tool can be run from the command line of any computer that
meets one of the following requirements:
- Docker is installed on the computer, or
- Zonemaster-CLI has been installed on the computer.
Using Docker
To run Zonemaster-CLI on Docker you have to make sure that Docker is installed on the computer and that you can run Docker on it.
- Instructions for installation are found on Docker get started page.
- Run the command
docker ps
on the command line to verify that you can run Docker on the computer.
When Docker has been correctly installed, no more installation is needed to run
zonemaster-cli
. Just follow the examples below.
There is a limitation in Docker regarding IPv6. Unless IPv6 has been enabled in
the Docker daemon, there is no support for IPv6. To avoid meaningless errors,
use --no-ipv6
if there is no IPv6 support. Also see "Enable IPv6 support".
Local installation
To have an local installation of Zonemaster-CLI follow the installation instruction. When installed, the examples below can be followed.
If the network has no IPv6 support (common in home networks) then turn off IPv6.
Use --no-ipv6
to avoid meaningless errors if there is no IPv6 support.
Invoking the command line tool using Docker
The most basic use of the zonemaster-cli
command is to just test a domain, e.g.
"zonemaster.net".
docker run -t --rm zonemaster/cli zonemaster.net --no-ipv6
or
docker run -t --rm zonemaster/cli zonemaster.net
To make sure that Docker uses the latest version, add --pull always
, e.g.
docker run -t --rm --pull always zonemaster/cli zonemaster.net --no-ipv6
If --pull always
is skipped, the invocation is quicker. The recommendation is
to include --pull always
in the first command of a session to make sure latest
version is used, and then to exclude it to improve performance.
Invoking the command line tool using local installation
The most basic use of the zonemaster-cli
command is to just test a domain, e.g.
"zonemaster.net".
zonemaster-cli zonemaster.net
or
zonemaster-cli zonemaster.net --no-ipv6
More details on the command line tool invocation
The output of any of the commands above comes continuously as the tests (test cases) are performed.
Seconds Level Message
======= ========= =======
21.39 WARNING The DNSKEY with tag 54636 uses an algorithm number 5 (RSA/SHA1) which is not recommended to be used.
21.80 WARNING DNSKEY with tag 26280 and using algorithm 5 (RSA/SHA1) has a size (1024) smaller than the recommended one (2048).
23.61 NOTICE SOA 'refresh' value (10800) is less than the recommended one (14400).
The test and output can be modified with different options:
- If your machine is not configured for use with IPv6 you want to disable the
use of IPv6 with the
--no-ipv6
option. - If you want to have the test case from which the message is printed then
include the
--show-testcase
option. - If you want to see the messages translated into another language (see
"Translation" section below) then include e.g.
--locale da
(Docker) or--locale da_DK.UTF-8
(local installation).
The same test as above with the three options included:
docker run -t --rm zonemaster/cli zonemaster.net --no-ipv6 --show-testcase --locale=da
zonemaster-cli zonemaster.net --no-ipv6 --show-testcase --locale=da_DK.UTF-8
To get brief descriptions of a selection of the most important command line options run:
zonemaster-cli --help
For complete reference documentation, see the manual page. This includes an exhaustive list of options and in-depth documentation for each one, as well as examples and additional context.
man zonemaster-cli
Using Docker or local installation
The difference between running zonemaster-cli
on Docker or local installation
is the invocation string, docker run -t --rm zonemaster/cli
vs.
zonemaster-cli
. To simplify this document, from now on the shorter
zonemaster-cli
will be used and for Docker the longer string will be assumed.
To simplify repeated invocation on Docker an alias can be created for the shell.
Test reports
The severity level of the different messages is CRITICAL, ERROR, WARNING, NOTICE,
INFO, DEBUG, DEBUG2 or DEBUG3. The default reporting level is NOTICE and higher.
To change the level of reporting you can use a command line option, e.g
--level=INFO
includes level INFO and higher in the report. See
"Severity Level Definitions" for more information on the levels.
By default the output is formatted as plain text in English (or some other
language), but other more "technical" output formats are also available with
options --raw
and json
, respectively.
Translation
In Docker
By default all messages are in English. By using the --locale=LANG
option
another language can be selected. Select "LANG" from the table below to have
Zonemaster translated into that language.
LANG | Language |
---|---|
da | Danish |
en | English |
fi | Finnish |
fr | French |
nb | Norwegian |
es | Spanish |
sv | Swedish |
E.g.:
docker run -t --rm zonemaster/cli zonemaster.net --locale=da
An alternative is to set the LC_ALL
environment variable with correct language
value when the command is invoked, which can be useful if a shell alias is
created. E.g.
docker run -e LC_ALL=da -t --rm zonemaster/cli zonemaster.net
If environment variable LC_ALL
is set in the local shell with the correct
"LANG" or with the equivalent "LOCALE" in from next section, then the following
command will export LC_ALL
with the that value to the docker container.
docker run -e LC_ALL -t --rm zonemaster/cli zonemaster.net
Environment variables LANG
and LC_MESSAGES
can be used in the same way as
LC_ALL
.
In local installation
By default all messages are in the language set in the local environment (if
available in Zonemaster) or else in English. By using the --locale=LOCALE
option another language can be selected. Select "LOCALE" from the table below to
have Zonemaster translated into that language.
LOCALE | Language |
---|---|
da_DK.UTF-8 | Danish |
en_US.UTF-8 | English |
fi_FI.UTF-8 | Finnish |
fr_FR.UTF-8 | French |
nb_NO.UTF-8 | Norwegian |
es_ES.UTF-8 | Spanish |
sv_SE.UTF-8 | Swedish |
E.g.:
docker run -t --rm zonemaster/cli zonemaster.net --locale=da_DK.UTF-8
If the environment variable LANGUAGE
is set with correct LOCALE then no option
is needed, e.g. LANGUAGE=da_DK.UTF-8
. zonemaster-cli
also respects LC_ALL
,
LC_MESSAGES
and LANG
. LANGUAGE
takes precedence over the other, and then
the order is LC_ALL
, LC_MESSAGES
and last LANG
.
Advanced use
There are some nice features available that can be of some use for advanced users.
Only run specific test cases
If you only want to run a specific test case rather than the whole suite of tests, you can do that as well. E.g. test only test case Connectivity03:
zonemaster-cli --test Connectivity/connectivity03 example.com
Or all test case in the Connectivity test level:
zonemaster-cli --test Connectivity example.com
For more information on the available tests, you can list them right from the command line tool:
zonemaster-cli --list_tests
Use custom root hints
You can override the built-in list of root servers that zonemaster-cli
uses
by providing a path to a custom root hints file with the --hints HINTS-FILE
option. For example:
zonemaster-cli --hints /path/to/custom.hints example.com
If you are running zonemaster-cli
using Docker, you must mount your custom
root hints file inside the container using a volume so that zonemaster-cli
can access it, like so:
docker run -t --rm \
-v /path/to/custom.hints:/hints \
zonemaster/cli --hints /hints example.com
Undelegated test
Before you do any delegation change at the parent, either changing the NS records, glue address records or DS records, you might want to perform a check of your new child zone configuration so that everything you plan to change is in order. Zonemaster can do this for you. All you have to do is give Zonemaster all the parent data you plan to have for your new configuration. Any DNS lookups going for the parent will instead be answered by the data you entered. E.g.
zonemaster-cli --ns ns1.example.com/192.168.23.23 \
--ns ns2.example.com/192.168.24.24 \
--ds 12345,3,1,123456789abcdef67890123456789abcdef67890
Any number of NS records and DS records can be given multiple times. The syntax of the NS records is name/address, and the address can be both IPv4 and IPv6. The DS syntax is keytag,algorithm,type,digest.
You can also choose to do a undelegated test using only the new DS record, but keep the NS records from the parent by only specifying the DS record and no NS records on the command line.
Docker on Mac with M1 chip
If you run the Docker commands above on a Mac computer with the M1 chip, then you will get the following warning:
WARNING: The requested image's platform (linux/amd64) does not match the detected host platform (linux/arm64/v8) and no specific platform was requested
The warning says that the image is created for Intel/AMD64 architecture, and that
is not what your computer has. To get rid of the warning, add
--platform linux/amd64
to docker run
, e.g.
docker run --platform linux/amd64 -t --rm zonemaster/cli zonemaster.net --no-ipv6
If you search for the error messages you will get suggestions for how to
automatically include the --platform linux/amd64
option every time you run
docker run
.
Using the Backend
- Using Zonemaster-Backend JSON-RPC API
- Using Zonemaster-Backend for batch testing
- RPCAPI reference
- Collecting metrics
Using Zonemaster-Backend JSON-RPC API
Table of contents
- Introduction
- Check that the RPC API daemon is running and answering properly
- Run a test of the zonemaster.net zone using zmtest
- Run a test of the zonemaster.net zone using zmb
- Find available languages
- Find previous tests
- Other APIs
- IDN domain names
- Using curl instead
Introduction
This is a guide for getting started with the Zonemaster JSON-RPC API service (running as a daemon).
Note that this guide makes a number of assumptions about your setup:
- That it is a Unix-like environment.
- That you have Zonemaster-Backend installed according to the installation guide
- That Zonemaster-Backend is running. See installation guide for how to start Zonemaster-Backend.
- If you have changed IP address (default 127.0.0.1) or port (default 5000) then you must specify that in the commands below. Here we assume default.
For this guide we will use the two Zonemaster-Backend tools zmb
and zmtest
.
Both are installed when Zonemaster-Backend is installed. To get more information
what parameters they expect, run zmb -h
and zmtest -h
.
With zmtest
you can start a domain test and get the result directly. With zmb
you can also do that, but in several steps, but on the other hand, zmb
offers
many more possibilities. Actually, zmtest
uses zmb
behind the scen.
The zmb
tool uses the JSON-RPC API to interact with Zonemaster-Backend.
Zonemaster-GUI also uses the same JSON-RPC API to start tests and fetch the
test results.
Check that the JSON-RPC API service is running and answering properly
zmb version_info
To get a more readable output, pipe the command through jq
:
zmb version_info | jq
If there is no response from the JSON-RPC API service, go to the installation guide for how to start or restart it.
Below most commands will be piped through jq
, but for processing you might want
to have the JSON on one line, or you might want to look at the options for jq
to extract fields (see jq -h
).
Run a test of the zonemaster.net zone using zmtest
To just run a test zmtest
is the simple tool to use:
zmtest zonemaster.net
The tool will also display the result, which will be a large JSON object (here truncated).
testid: 879d13569db70fde
100% done
{
"id": 1,
"jsonrpc": "2.0",
"result": {
"created_at": "2024-10-25T09:28:38Z",
"hash_id": "879d13569db70fde",
"params": {
"domain": "zonemaster.net",
"ds_info": [],
"ipv4": true,
"ipv6": true,
"nameservers": [],
"priority": 10,
"profile": "default",
"queue": 0
},
"results": [
{
"level": "INFO",
"message": "Using version v6.0.0 of the Zonemaster engine.\n",
"module": "System",
"testcase": "Unspecified"
},
{
"level": "INFO",
"message": "The parent zone is \"net\" as returned from name servers \"a.gtld-servers.net/192.5.6.30; a.gtld-servers.net/2001:503:a83e::2:30; b.gtld-servers.net/192.33.14.30; b.gtld-servers.net/2001:503:231d::2:30; c.gtld-servers.net/192.26.92.30; c.gtld-servers.net/2001:503:83eb::30; d.gtld-servers.net/192.31.80.30; d.gtld-servers.net/2001:500:856e::30; e.gtld-servers.net/192.12.94.30; e.gtld-servers.net/2001:502:1ca1::30; f.gtld-servers.net/192.35.51.30; f.gtld-servers.net/2001:503:d414::30; g.gtld-servers.net/192.42.93.30; g.gtld-servers.net/2001:503:eea3::30; h.gtld-servers.net/192.54.112.30; h.gtld-servers.net/2001:502:8cc::30; i.gtld-servers.net/192.43.172.30; i.gtld-servers.net/2001:503:39c1::30; j.gtld-servers.net/192.48.79.30; j.gtld-servers.net/2001:502:7094::30; k.gtld-servers.net/192.52.178.30; k.gtld-servers.net/2001:503:d2d::30; l.gtld-servers.net/192.41.162.30; l.gtld-servers.net/2001:500:d937::30; m.gtld-servers.net/192.55.83.30; m.gtld-servers.net/2001:501:b1f9::30\".\n",
"module": "Basic",
"testcase": "Basic01"
},
{
"level": "INFO",
"message": "The zone \"zonemaster.net\" is found.\n",
"module": "Basic",
"testcase": "Basic01"
},
{
"level": "INFO",
"message": "Authoritative answer on SOA query for \"zonemaster.net\" is returned by name servers \"ns2.nic.fr/192.93.0.4; ns2.nic.fr/2001:660:3005:1::1:2; nsa.dnsnode.net/194.58.192.46; nsa.dnsnode.net/2a01:3f1:46::53; nsp.dnsnode.net/194.58.198.32; nsp.dnsnode.net/2a01:3f1:3032::53; nsu.dnsnode.net/185.42.137.98; nsu.dnsnode.net/2a01:3f0:400::32\".\n",
"module": "Basic",
"testcase": "Basic02"
},
(...)
You will find the meaning of all fields in the outputs in Zonemaster-Backend JSON-RPC API reference.
Run a test of the zonemaster.net zone using zmb
If we instead use zmb
then this will be done in three steps (that happen
behind the scen when using zmtest
):
- Enqueue test.
- Check if testing has completed (progress) - maybe several times.
- Fetch result (maybe several times with different translations).
Enqueue a test
To enqueue a test of zonemaster.net we run
zmb start_domain_test --domain zonemaster.net | jq
and immediately get the
response
{
"jsonrpc": "2.0",
"id": 1,
"result": "879d13569db70fde"
}
The results
field holds the test ID which we need for further steps. It
always consists of 16 hexadecimal digits.
Check the progress
To check the progress we run zmb test_progress --test-id 879d13569db70fde | jq
with the test ID from enqueueing, and get the response
{
"jsonrpc": "2.0",
"id": 1,
"result": 8
}
Now the results
field holds the progress of testing, an integer between 0 and
100 to mean 0% to 100%. 0% means that testing has not started (maybe many tests
in the queue) and 100% means that testing has completed.
We have to stay in the check step until the test has reached 100%. In our example above, it is 8%, so we run the command again and now we get the response
{
"result": 100,
"jsonrpc": "2.0",
"id": 1
}
Fetch the results
When the test has completed the test results can be fetched. The test ID is found
above and then the language has to be chosen. Here en
is used. More about
languages below. Run
zmb get_test_results --test-id 879d13569db70fde --lang en | jq
and get a JSON
structure with data (as with zmtest
). Again, the JSON structure is long and is
truncated here.
{
"id": 1,
"result": {
"results": [
{
"message": "Using version v6.0.0 of the Zonemaster engine.\n",
"testcase": "Unspecified",
"level": "INFO",
"module": "System"
},
{
"module": "Basic",
"level": "INFO",
"testcase": "Basic01",
"message": "The parent zone is \"net\" as returned from name servers \"a.gtld-servers.net/192.5.6.30; a.gtld-servers.net/2001:503:a83e::2:30; b.gtld-servers.net/192.33.14.30; b.gtld-servers.net/2001:503:231d::2:30; c.gtld-servers.net/192.26.92.30; c.gtld-servers.net/2001:503:83eb::30; d.gtld-servers.net/192.31.80.30; d.gtld-servers.net/2001:500:856e::30; e.gtld-servers.net/192.12.94.30; e.gtld-servers.net/2001:502:1ca1::30; f.gtld-servers.net/192.35.51.30; f.gtld-servers.net/2001:503:d414::30; g.gtld-servers.net/192.42.93.30; g.gtld-servers.net/2001:503:eea3::30; h.gtld-servers.net/192.54.112.30; h.gtld-servers.net/2001:502:8cc::30; i.gtld-servers.net/192.43.172.30; i.gtld-servers.net/2001:503:39c1::30; j.gtld-servers.net/192.48.79.30; j.gtld-servers.net/2001:502:7094::30; k.gtld-servers.net/192.52.178.30; k.gtld-servers.net/2001:503:d2d::30; l.gtld-servers.net/192.41.162.30; l.gtld-servers.net/2001:500:d937::30; m.gtld-servers.net/192.55.83.30; m.gtld-servers.net/2001:501:b1f9::30\".\n"
},
{
"message": "The zone \"zonemaster.net\" is found.\n",
"module": "Basic",
"testcase": "Basic01",
"level": "INFO"
},
{
"level": "INFO",
"testcase": "Basic02",
"module": "Basic",
"message": "Authoritative answer on SOA query for \"zonemaster.net\" is returned by name servers \"ns2.nic.fr/192.93.0.4; ns2.nic.fr/2001:660:3005:1::1:2; nsa.dnsnode.net/194.58.192.46; nsa.dnsnode.net/2a01:3f1:46::53; nsp.dnsnode.net/194.58.198.32; nsp.dnsnode.net/2a01:3f1:3032::53; nsu.dnsnode.net/185.42.137.98; nsu.dnsnode.net/2a01:3f0:400::32\".\n"
},
(...)
Find available languages
The result can be presented in several languages, depending on installation. To
find out what languages that are available, run zmb get_language_tags | jq
.
{
"jsonrpc": "2.0",
"id": 1,
"result": [
"da",
"en",
"es",
"fi",
"fr",
"nb",
"sv"
]
}
Find previous tests
It is possible to find previous tests of a specific domain (zone). Run
zmb get_test_history --domain zonemaster.net |jq
to get all tests of
zonemaster.net
. The output looks like the following:
{
"jsonrpc": "2.0",
"result": [
{
"undelegated": false,
"created_at": "2024-10-25T09:54:38Z",
"id": "00669309ac7887c3",
"overall_result": "ok"
},
{
"overall_result": "ok",
"id": "879d13569db70fde",
"undelegated": false,
"created_at": "2024-10-25T09:28:38Z"
}
],
"id": 1
}
Now you can get the results of any of the listed tests by running
get_test_results
with selected test ID and language as above.
Other APIs
There are a few other APIs that can be used throught zmb
, and can be found by
zmb -h
and in Zonemaster-Backend JSON-RPC API reference. The APIs for batch
testing are covered in Using Zonemaster Backend for batch testing.
IDN domain names
When enqueuing a test of an IDN domain name with zmb start_domain_test
it is
possible to provide the domain name as either A-label or U-label. E.g. both
"räksmörgås.se" or "xn--rksmrgs-5wao1o.se" (the same domain name) work as well.
The same is also true if using Curl instead (see below).
Using Curl instead
Instead of using zmb
it is possible to run the commands by curl
, which
requires that the JSON structure is created, but can give greater flexibility.
The method can also be copied into different programming languages when
scripting.
The same enqueuing of the zonemaster.net zone as above will then be:
curl -sS -H "Content-Type: application/json" -d '{"jsonrpc": "2.0", "id": 2, "method": "start_domain_test", "params": {"domain": "zonemaster.net"}}' http://localhost:5000/ | jq .
And fetching the result, when completed, will be:
curl -sS -H "Content-Type: application/json" -d '{"jsonrpc": "2.0", "id": 5, "method": "get_test_results", "params": {"id": "879d13569db70fde", "language": "en"}}' http://localhost:5000/ | jq .
The format of the JSON structure for every method is found in the Zonemaster-Backend JSON-RPC API reference.
Using Zonemaster-Backend for batch testing
Table of contents
- Introduction
- Combining GUI and batch
- Configuration to run batches
- Create batch user
- Run a batch job
- Scale out
- Queues
- Appendix: Add more JSON-RPC API services
Introduction
In Using the Backend JSON-RPC API it is shown how a test of a single domain name
(zone) can be started using the JSON-RPC API to Zonemaster-Backend. It is also
possible to start a batch of domain names at the same time. In principle such
a batch is the same thing as running the start_domain_test
individually for each
domain name in the batch.
This document describes how batches of domain name tests can be run and what to think about when running batches, especially large ones.
Zonemaster-Backend uses a database to store enqueued tests and results from tests. It is possible to use SQLite as the database backend for small installations and test installations, but that is not appropriate for running real batches on. Therefore in this document it is assumed that Backend has been installed with MariaDB/MySQL or PostgreSQL.
Combining GUI and batch
Both GUI and batch uses Zonemaster-Backend that stores the data in the database.
If the same database is used, then all tests run, regardless if they are
started via GUI or a batch, will be available in the GUI interface
using the get_test_history
(see relevant section in
Using the Backend JSON-RPC API). Depending on the
situation, running batches on the same Backend as GUI may be desirable or not
recommended. If the results are expected to be available through GUI then the batches must be
run on the same Backend. If the batches are run with a reduced set of test cases
then it can be confusing since the results are not fully comparable with
those from tests started from GUI. If the results from batch tests should not be
mixed with tests from normal GUI tests, a separate installation of Backend is
required, and that might not need any GUI at all.
Test prioritization is another aspect of mixing tests from batches and GUI on the same Backend. By default Backend will run
tests from GUI (or rather by start_domain_test
) before test from a batch. In
this way interactive GUI users run tests do not have to wait for a
batch to complete. A large batch might run for days.
Configuration to run batches
To start a batch job, setting enable_add_batch_job
in backend_config.ini must
be enabled (enabled by default). Moreover a special user must also be available.
To create that user setting enable_add_api_user
must be enabled
(disabled by default). (See below for how to create the user.) Note that this setting
only needs to be enabled while creating the user(s), not when starting a batch job.
After changing these settings, the JSON-RPC API service (running as a daemon) must be restarted.
It is not recommended to enable enable_add_api_user
for an JSON-RPC API service
that can be used by untrusted users, e.g. via GUI. If the installation for the
batch jobs is a dedicated installation, then it is not an issue. If it is used by
a public GUI that could be closed while the batch user or users are created, then
that could be an option. Creating the user only takes as long time as it takes to
type the command in, i.e. seconds.
Another option is to set up an additional JSON-RPC API service using the same database. Zonemaster-Backend can have several parallel JSON-RPC API services with different configuration, see Appendix: Add more JSON-RPC API services.
Create batch user
The Using the Backend JSON-RPC API guide shows how zmb
can be used for
several JSON-RPC API methods. It can also be used for the creation of the batch
user. It is here assumed that enable_add_api_user
has been enabled or else the
following will be included in the response to the zmb add_api_user
command:
"message": "Procedure 'add_api_user' not found"
Run zmb add_api_user --username myuser --api-key mykey | jq
where myuser
is
a user name of your choice and mykey
the password, which should probably be
longer and more complex. The output is simply
{
"jsonrpc": "2.0",
"result": 1,
"id": 1
}
Now enable_add_api_user
can be disabled.
Run a batch job
The zmb
tool is used for that purpose. A batch job can be started with just a few
domain names or a list of millions of domain names.
Start a batch job
Batches are created using add_batch_job
:
$ zmb add_batch_job --username myuser --api-key mykey --domain zonemaster.net --domain zonemaster.se --domain zonemaster.fr | jq
{
"jsonrpc": "2.0",
"result": 2,
"id": 1
}
Options that are mandatory are --username
, --api-key
and --domain
. Option
--domain
is repeated for every domain name in the batch. The other options are
optional. For all options see zmb man
.
The batch ID is found in "result", which is "2" in this case.
Listing the domain names one by one is however cumbersome unless it is a very
small batch as above. A better alternative for a larger batch is to create text
file of the domain names to test, one domain name per line. Comments starting
with #
is permitted, which makes it possible to add meta information to the
file.
cat batchfile.txt
# Example batch
zonemaster.net
zonemaster.se
zonemaster.fr
Now we can run the same batch as above, but from the file:
$ zmb add_batch_job --username myuser --api-key mykey --file batchfile | jq
{
"jsonrpc": "2.0",
"result": 3,
"id": 1
}
Starting the batch with the domain names one by one or in the file gives exactly the same result. Also in this case, IDN domain names can be entered both with A-label and U-label (UTF-8 is assumed).
Status of a batch job
To check the status of a batch job the batch ID is required ("2" in the
case above), using get_batch_job_result
:
$ zmb get_batch_job_result --batch-id 2 | jq
{
"id": 1,
"result": {
"nb_running": 3,
"nb_finished": 0
},
"jsonrpc": "2.0"
}
Three tests are running, none has been completed yet. After some time running the command again gives:
{
"jsonrpc": "2.0",
"result": {
"nb_running": 0,
"finished_test_ids": [
"b26b874493ed4b57",
"9af528070fa2551a",
"708f82b5176261dc"
],
"nb_finished": 3
},
"id": 1
}
Now all tests in the batch are completed. The test IDs in finished_test_ids
can be used to get the results with get_test_results
.
Scale out
Running a batch can take a long time and if that is a problem then it is possible to increase the performance by:
- Enabling global cache
- Increasing
number_of_processes_for_batch_testing
- Adding one or more Test Agent service
- Adding one or more test servers
Enable global cache
For each domain name in a batch job, a test run is executed. Each test run keeps its own cache to avoid sending the same query twice. However these caches are never shared between test runs. This may result in large numbers of redundant queries for large batches where the domain name directly (or indirectly) share data with other domain names. To share responses between test runs, you can enable the global cache feature which works like a second level cache.
For interactive tests via GUI the global cache is probably not desired. If a user changes the DNS configuration of a domain then the following tests results should not be based on old data.
To enable global cache a custom profile must be used. See the instructions in Configuration: Global cache in Zonemaster-Engine.
The custom profile is assumed to be /etc/zonemaster/profile-batch.json
(Linux) or /etc/local/zonemaster/profile-batch.json
(FreeBSD).
The custom profile file, say profile-batch.json
, must be added to the Backend
configuration to be made available for the tests. In backend_config.ini
look
for the section [PRIVATE PROFILES]
. Under that add the following line for
Linux:
batch=/etc/zonemaster/profile-batch.json
For FreeBSD add:
batch=/usr/local/etc/zonemaster/profile-batch.json
After updating the Backend configuration, restart both JSON-RPC API service and Test Agent service (all daemons of both services if there are more than one of each).
Now you can start a batch -- using the same batch file as above -- with:
$ zmb add_batch_job --profile batch --username myuser --api-key mykey --file batchfile | jq
{
"jsonrpc": "2.0",
"result": 4,
"id": 1
}
Increase the worker pool size
A standard Backend installation has a single Test Agent service. Each Test Agent service maintains a pool of workers. Test Agents monitor the Backend database for tests and assigns them to workers.
Increasing the size of the worker pool can improve the testing performance. The improvement is limited by CPU, I/O, memory and the ability of the Test Agent service to keep its workers busy, so monitor these factors to find the best configuration.
To adjust the worker pool size, set number_of_processes_for_batch_testing
in
the backend_config.ini configuration file.
Add more Test Agent services
If the increase of number_of_processes_for_batch_testing
does not help anymore
and the server has free resources (IO, CPU and RAM) then adding another Test
Agent services (with its pool of workers) can help.
The default Test Agent service is started by the start script
/etc/systemd/system/zm-testagent.service
(Rocky Linux),
/etc/init.d/zm-testagent
(Debian/Ubuntu) or /usr/local/etc/rc.d/zm_testagent
(FreeBSD). Create a copy so that the additional Test Agent service has a new
name, new PID file and new log file. Also see the
Backend installation instructions. Each Test Agent service will be its own
daemon.
Start the new daemon and now a second Test Agent service is running. Additional Test Agent services can be added by repeating the steps above.
Unless the different Test Agent services should process different queues the same configuration file can be used.
Add more test servers
Adding more servers is a generalization of adding more Test Agent daemons.
- Configure the database to listen on an external interface. The database can also be moved to a dedicated server.
- Install Backend on the new Test Agent server, but disable JSON-RPC API service.
- Update configuration to use the external database server.
- Consider adding more Test Agent services.
- If global cache is used, configure Redis to listen on an external interface. The Redis server can also be moved to a dedicated server.
- Consider moving JSON-RPC API service to a dedicated server. If so, update the configuration to use the external database server.
- If applicable, configure all parts to use external database server and external Redis server.
Queues
Every enqueued test has a queue tag. In the
configuration file it is set which queue should be
processed by the Test Agent service. Only tests with matching queue value
(default 0) will be processed. Queue tag is set by the JSON-RPC API methods
start_domain_test
and add_batch_job
, respectively (default 0 in both cases).
If desirable it is possible to create a batch with another queue value and then let a dedicated Test Agent service, possibly on a dedicated server, process the tests in the batch, while another Test Agent service processes tests from GUI.
It is important to note that if a test is tagged with a queue value that no Test Agent service uses it will never be processed.
In the end, all completed tests will end up in the same database and will be
mixed when looking for completed tests for the same domain name
(get_test_history
).
Appendix: Add more JSON-RPC API services
The JSON-RPC API service listens by default on 127.0.0.1 on port 5000. That is
governed by the start script for the JSON-RPC API service which is
/etc/systemd/system/zm-rpcapi.service
(Rocky Linux), /etc/init.d/zm-rpcapi
(Ubuntu and Debian) or /usr/local/etc/rc.d/zm_rpcapi
(FreeBSD). Create a copy
so that the additional service (daemon) has a new name, new PID file, new log
file and listens to a new port. Also see the Backend installation instructions.
Start the new daemon and now a second JSON-RPC API service is running.
To be useful, the second JSON-RPC API service should probably have a different
configuration file too. The configuration file is found as
/etc/zonemaster/backend_config.ini
(Linux) or as
/usr/local/etc/zonemaster/backend_config.ini
(FreeBSD). The database settings
must not be changed, or else the two JSON-RPC API services will not be part of
the same Zonemaster Backend. Examples of settings that could be different between
the two JSON-RPC API services are:
- enable_add_api_user
- Available profiles
Restart the JSON-RPC API services to use the updated configuration files.
API
Table of contents
- Purpose
- Protocol
- Request handling
- Error reporting
- Privilege levels
- Data types
- API methods
- API method: version_info
- API method: profile_names
- API method: get_language_tags
- API method: get_host_by_name
- API method: get_data_from_parent_zone
- API method: start_domain_test
- API method: test_progress
- API method: get_test_results
- API method: get_test_history
- API method: add_api_user
- API method: add_batch_job
- API method: get_batch_job_result
- API method: get_test_params
- Experimental API methods
Purpose
This document describes the JSON-RPC API provided by the Zonemaster RPC API daemon. This API provides means to check the health of domains and to fetch domain health reports. Health checks are called tests in Zonemaster lingo.
Protocol
This API is implemented using JSON-RPC 2.0.
JSON-RPC request objects are accepted in the body of HTTP POST requests to any path.
The HTTP request must contain the header Content-Type: application/json
.
All JSON-RPC request and response objects have the keys "jsonrpc"
, "id"
and "method"
.
For details on these, refer to the JSON-RPC 2.0 specification.
Deviations from JSON-RPC 2.0
- The
"jsonrpc"
property is not checked. - The error code -32603 is used for invalid arguments, as opposed to the dedicated error code -32602.
- When standard error codes are used, the accompanying messages are not the standard ones.
Notes on the JSON-RPC 2.0 implementation
- Extra top-level properties in request objects are allowed but ignored.
- No extra properties are allowed in the
"params"
object. - Error messages from the API should be considered sensitive as they sometimes leak details about the internals of the application and the system.
- The error code -32601 is used when the
"method"
property is missing, rather than the perhaps expected error code -32600.
Request handling
When a method expects a string argument but receives an array or an object,
the value may be interpreted as something like "ARRAY(0x1a2d1d0)"
or "HASH(0x1a2d2c8)"
.
When a method expects a boolean argument, any kind of value is accepted.
A number of values are interpreted as false: false
, null
, ""
, "0"
and any number equal to zero.
Everything else is interpreted as true.
When a method expects an integer arguments, numbers encoded in strings are also accepted and used transparently, and numbers with fractions are rounded to the nearest integer.
For details on when a test are performed after it's been requested, see the architecture documentation.
Error reporting
If the request object is invalid JSON, an error with code -32700
is reported.
If no method is specified or an invalid method is specified, an error with code -32601
is reported.
If no params
object is specified when it is required, or the params
object
for the specified method is invalid, an error with code -32602
is reported.
For more information on the validation error data format see
Validation error data.
All error states that occur after the RPC method has been identified are reported as internal errors with code -32603
.
Privilege levels
This API provides three classes of methods:
- Unrestricted methods are available to anyone with access to the API.
- Authenticated methods have parameters for username and api key credentials.
- Administrative methods require that the connection to the API is opened from
localhost (
127.0.0.1
or::1
).
Data types
This sections describes a number of data types used in this API. Each data type is based on a JSON data type, but additionally imposes its own restrictions.
API key
Basic data type: string
A string of alphanumerics, hyphens (-
) and underscores (_
), of at least 1
and at most 512 characters.
I.e. a string matching /^[a-zA-Z0-9-_]{1,512}$/
.
Represents the password of an authenticated account (see Privilege levels)
Batch id
Basic data type: number
A strictly positive integer.
The unique id of a batch.
Client id
Basic data type: string
A string of alphanumerics, hyphens, underscores, pluses (+
), tildes (~
),
full stops (.
), colons (:
) and spaces (
), of at least 1 and at most 50
characters.
I.e. a string matching /^[a-zA-Z0-9-+~_.: ]{1,50}$/
.
Represents the name of the client. Used for monitoring which client (GUI) uses the API.
Client version
Basic data type: string
A string of alphanumerics, hyphens, pluses, tildes, underscores, full stops,
colons and spaces, of at least 1 and at most 50 characters.
I.e. a string matching /^[a-zA-Z0-9-+~_.: ]{1,50}$/
.
Represents the version of the client. Used for monitoring which client (GUI) uses the API.
Domain name
Basic data type: string
-
If the string is a single character, that character must be
.
. -
The length of the string must not be greater than 254 characters.
-
When the string is split at
.
characters (after IDNA conversion, if needed), each component part must be at most 63 characters long.
Note: Currently there are no restrictions on what characters that are allowed.
DS info
Basic data type: object
DS for Delegation Signer references a DNSKEY record in the delegated zone.
Properties:
"digest"
: A string, required. Either 40, 64 or 96 hexadecimal characters (case-insensitive)."algorithm"
: An non negative integer, required."digtype"
: An non negative integer, required."keytag"
: An non negative integer, required.
IP address
Basic data type: string
This parameter is a string that is either
- a valid IPv4 address in dot-decimal notation ;
- a valid IPv6 address in recommended text format for IPv6 addresses.
Language tag
Basic data type: string
A string matching /^[a-z]{2}$/
.
The set of valid language tags is further constrained by the
LANGUAGE.locale
property.
A language tag needs to match the language code of a locale tag in
LANGUAGE.locale
.
Design
The language tag values are intended to be ISO 639-1 two-character language codes.
Out-of-the box support
A default installation will accept the following language tags:
Language | Language tag |
---|---|
Danish | da |
English | en |
Spanish | es |
Finnish | fi |
French | fr |
Norwegian | nb |
Swedish | sv |
Name server
Basic data type: object
Properties:
"ns"
: A domain name, required."ip"
: An IP address (IPv4 or IPv6), optional. (default: unset)
Non-negative integer
Basic data type: number (integer)
A non-negative integer is either zero or strictly positive.
Priority
Basic data type: number (integer)
This parameter is any integer that will be used by The Zonemaster Test Agents to sort the test requests from highest to lowest priority. This parameter will typically be used in a setup where a GUI will send requests to the RPC API and would like to get response as soon as possible while at the same time using the idle time for background batch testing. The drawback of this setup will be that the GUI will have to wait for at least one background processing slot to become free (would be a few seconds in a typical installation with up to 30 parallel zonemaster processes allowed)
Profile name
Basic data type: string
This parameter is a case-insensitive string validated with the case-insensitive
regex /^[a-z0-9]$|^[a-z0-9][a-z0-9_-]{0,30}[a-z0-9]$/i
which must be predefined
in the configuration file as specified in the Configuration document
profile sections.
The name of a profile.
Progress percentage
Basic data type: number (integer)
An integer ranging from 0 (not started) to 100 (finished).
Queue
Basic data type: number (integer)
This parameter allows an optional separation of testing in the same database. The default value for the queue is 0. It is closely related to the ZONEMASTER.lock_on_queue
parameter of the backend_config.ini file.
The typical use case for this parameter would be a setup with several separate Test Agents running on separate physical or virtual machines each one dedicated to a specific task, for example queue 0 for frontend tests and queue 1 dedicated to batch testing.
Severity level
Basic data type: string
One of the strings (in order from least to most severe):
"INFO"
"NOTICE"
"WARNING"
"ERROR"
"CRITICAL"
Severity levels in Zonemaster are defined in the Severity Level Definitions document. The following severity levels are not available through the RPCAPI (in order from least to most severe):
- DEBUG3
- DEBUG2
- DEBUG
Test id
Basic data type: string
A string of exactly 16 lower-case hex-digits matching /^[0-9a-f]{16}$/
.
Each test has a unique test id.
Test result
Basic data type: object
The object has four keys, "module"
, "message"
, "level"
and "testcase"
.
"module"
: a string. The test module that produced the result."message"
: a string. A human-readable message describing that particular result."level"
: a severity level. The severity of the message."testcase"
: a string. The Test Case Identifier of the Test Case that produced the result.
Sometimes additional keys are present.
"ns"
: a domain name. The name server used by the test module. This key is added when the module name is"NAMESERVER"
.
Timestamp
Basic data type: string
A string representing a date and time using the following ISO 8601 format: "YYYY-MM-DDThh:mm:ssZ". Example: "2017-12-18T07:56:17Z"
Username
Basic data type: string
A string of alphanumerics, dashes, full stops and at-signs, of at least 1 and at
most 50 characters.
I.e. a string matching /^[a-zA-Z0-9-.@]{1,50}$/
.
Represents the name of an authenticated account (see Privilege levels)
Validation error data
Basic data type: array
The items of the array are objects with two keys, "path"
and "message"
:
"path"
: a string. A JSON Pointer to an element in the request's param object. E.g.:"/nameservers/0/ip"
."message"
: a string. The error message associated with the element referenced by"path"
.
API methods
API method: version_info
Returns the version of the Zonemaster-LDNS, Zonemaster-Engine and Zonemaster-Backend software combination.
Example request:
{
"jsonrpc": "2.0",
"id": 1,
"method": "version_info"
}
Example response:
{
"jsonrpc": "2.0",
"id": 1,
"result": {
"zonemaster_ldns": "1.0.1",
"zonemaster_backend": "1.0.7",
"zonemaster_engine": "v1.0.14"
}
}
"result"
An object with the following properties:
"zonemaster_ldns"
: A string. The version number of the running Zonemaster LDNS."zonemaster_backend"
: A string. The version number of the running Zonemaster Backend."zonemaster_engine"
: A string. The version number of the Zonemaster Engine used by the RPC API daemon.
"error"
TODO: List all possible error codes and describe what they mean enough for clients to know how react to them.
API method: profile_names
Returns the names of the public subset of the available profiles.
Example request:
{
"jsonrpc": "2.0",
"id": 1,
"method": "profile_names"
}
Example response:
{
"jsonrpc": "2.0",
"id": 1,
"result": [
"default",
"another-profile"
]
}
"result"
An array of Profile names in lower case. "default"
is always included.
API method: get_language_tags
Returns the set of valid language tags.
Example request:
{
"jsonrpc": "2.0",
"id": 1,
"method": "get_language_tags"
}
Example response:
{
"jsonrpc": "2.0",
"id": 1,
"result": [
"da",
"en",
"es",
"fi",
"fr",
"nb",
"sv"
]
}
"result"
An array of language tags. It is never empty.
"error"
TODO: List all possible error codes and describe what they mean enough for clients to know how react to them. Or prevent RPCAPI from starting with errors in the configuration file and make it not to reread the configuration file while running.
API method: get_host_by_name
Looks up the A and AAAA records for a hostname (domain name) on the public Internet.
Example request:
Valid syntax:
{
"jsonrpc": "2.0",
"id": 2,
"method": "get_host_by_name",
"params": {"hostname": "zonemaster.net"}
}
Example response:
{
"jsonrpc": "2.0",
"id": 2,
"result": [
{
"zonemaster.net": "192.134.4.83"
},
{
"zonemaster.net": "2001:67c:2218:3::1:83"
}
]
}
"params"
An object with the property:
"hostname"
: A domain name, required. The hostname whose IP addresses are to be resolved.
"result"
A list of one or two objects representing IP addresses (if 2 one is for IPv4 the
other for IPv6). The objects each have a single key and value. The key is the
domain name given as input. The value is an IP address for the name, or the
value 0.0.0.0
if the lookup returned no A or AAAA records.
TODO: If the name resolves to two or more IPv4 address, how is that represented?
"error"
-
If any parameter is invalid an error code of -32602 is returned. The
data
property contains an array of all errors, see Validation error data.Example of error response:
{
"jsonrpc": "2.0",
"id": 1624630143271,
"error": {
"message": "Invalid method parameter(s).",
"code": "-32602",
"data": [
{
"path": "/hostname",
"message": "Missing property"
}
]
}
}
API method: get_data_from_parent_zone
Returns all the NS/IP and DS/DNSKEY/ALGORITHM pairs of the domain from the parent zone.
Example request: Valid syntax:
{
"jsonrpc": "2.0",
"id": 3,
"method": "get_data_from_parent_zone",
"params": {"domain": "zonemaster.net"}
}
Example response:
{
"jsonrpc": "2.0",
"id": 3,
"result": {
"ns_list": [
{
"ns": "ns.nic.se",
"ip": "2001:67c:124c:100a::45"
},
{
"ns": "ns.nic.se",
"ip": "91.226.36.45"
},
...
],
"ds_list": [
{
"algorithm": 5,
"digtype": 2,
"keytag": 54636,
"digest": "cb496a0dcc2dff88c6445b9aafae2c6b46037d6d144e43def9e68ab429c01ac6"
},
{
"keytag": 54636,
"digest": "fd15b55e0d8ee2b5a8d510ab2b0a95e68a78bd4a",
"algorithm": 5,
"digtype": 1
}
]
}
}
Note: The above example response was abbreviated for brevity to only include the first two elements in each list. Omitted elements are denoted by a
...
symbol.
"params"
An object with the properties:
"domain"
: A domain name, required. The domain whose DNS records are requested."language"
: A language tag, optional, used for validation error messages translation, if not provided messages will be untranslated (in English).
"result"
An object with the following properties:
"ns_list"
: A list of name server objects representing the nameservers of the given domain name."ds_list"
: A list of DS info objects representing delegation signer (DS record data) of the given domain name.
"error"
-
If any parameter is invalid an error code of -32602 is returned. The
data
property contains an array of all errors, see Validation error data.Example of error response:
{
"jsonrpc": "2.0",
"id": 1624630143271,
"error": {
"data": [
{
"message": "The domain name character(s) are not supported",
"path": "/domain"
}
],
"code": "-32602",
"message": "Invalid method parameter(s)."
}
}
API method: start_domain_test
Enqueues a new test and returns the test id of the test.
Example request:
{
"jsonrpc": "2.0",
"id": 4,
"method": "start_domain_test",
"params": {
"client_id": "Zonemaster Dancer Frontend",
"domain": "zonemaster.net",
"profile": "default",
"client_version": "1.0.1",
"nameservers": [
{
"ip": "2001:67c:124c:2007::45",
"ns": "ns3.nic.se"
},
{
"ip": "192.93.0.4",
"ns": "ns2.nic.fr"
}
],
"ds_info": [],
"ipv6": true,
"ipv4": true
}
}
Example response:
{
"jsonrpc": "2.0",
"id": 4,
"result": "c45a3f8256c4a155"
}
"params"
An object with the following properties:
"domain"
: A domain name, required. The zone to test."ipv6"
: A boolean, optional. (default:net.ipv4
profile value). Used to enable or disable testing over IPv4 transport protocol."ipv4"
: A boolean, optional. (default:net.ipv6
profile value). Used to enable or disable testing over IPv6 transport protocol."nameservers"
: A list of name server objects, optional. (default:[]
). Used to perform un-delegated test."ds_info"
: A list of DS info objects, optional. (default:[]
). Used to perform un-delegated test."profile"
: A profile name, optional. (default:"default"
). Run the tests using the given profile."client_id"
: A client id, optional. (default: unset). Used to monitor which client uses the API."client_version"
: A client version, optional. (default: unset). Used to monitor which client use the API"priority"
: A priority, optional. (default:10
)"queue"
: A queue, optional. (default:0
)"language"
: A language tag, optional, used for validation error messages translation, if not provided messages will be untranslated.
"result"
A test id.
If a test has been requested with the same parameters (as listed below) not more
than "reuse time" ago, then a new request will not trigger a new test. Instead
the test id
of the previous test will be returned. The default value of
"reuse time" is 600 seconds, and can be set by the
ZONEMASTER.age_reuse_previous_test
key
in the configuration file.
The parameters that are compared when to determine if two requests are to be
considered to be the same are domain
, ipv6
, ipv4
, nameservers
, ds_info
and profile
.
"error"
-
If any parameter is invalid an error code of -32602 is returned. The
data
property contains an array of all errors, see Validation error data. -
If the given
profile
is not among the available profiles, a user error is returned, see profile name section.
Example of error response:
{
"jsonrpc": "2.0",
"id": 1,
"error": {
"code": "-32602",
"data": [
{
"message": "Expected integer - got string.",
"path": "/ds_info/0/algorithm"
},
{
"message": "Missing property.",
"path": "/ds_info/0/digest"
},
{
"path": "/profile",
"message": "Unknown profile"
},
{
"path": "/domain",
"message": "The domain name character(s) are not supported"
},
{
"path": "/nameservers/0/ip",
"message": "Invalid IP address"
}
],
"message": "Invalid method parameter(s)."
}
}
API method: test_progress
Reports on the progress of a test.
Example request:
Valid syntax:
{
"jsonrpc": "2.0",
"id": 5,
"method": "test_progress",
"params": {"test_id": "c45a3f8256c4a155"}
}
Example response:
{
"jsonrpc": "2.0",
"id": 5,
"result": 100
}
"params"
An object with the property:
"test_id"
: A test id, required. The test to report on.
"result"
"error"
TODO: List all possible error codes and describe what they mean enough for clients to know how react to them.
API method: get_test_results
Return all test result objects of a test, with messages in the requested language as selected by the language tag.
Example request:
{
"jsonrpc": "2.0",
"id": 6,
"method": "get_test_results",
"params": {
"id": "c45a3f8256c4a155",
"language": "en"
}
}
The id
parameter must match the result
in the response to a start_domain_test
call, and that test must have been completed.
Example response:
{
"jsonrpc": "2.0",
"id": 6,
"result": {
"created_at": "2016-11-15T11:53:13Z",
"hash_id": "c45a3f8256c4a155",
"params": {
"ds_info": [],
"client_version": "1.0.1",
"domain": "zonemaster.net",
"profile": "default",
"ipv6": true,
"nameservers": [
{
"ns": "ns3.nic.se",
"ip": "2001:67c:124c:2007::45"
},
{
"ip": "192.93.0.4",
"ns": "ns2.nic.fr"
}
],
"ipv4": true,
"client_id": "Zonemaster Dancer Frontend"
},
"testcase_descriptions": {
"ZONE08": "MX is not an alias",
"SYNTAX05": "Misuse of '@' character in the SOA RNAME field",
...
},
"results": [
{
"module": "SYSTEM",
"message": "Using version v1.0.14 of the Zonemaster engine.\n",
"level": "INFO"
},
{
"message": "Configuration was read from DEFAULT CONFIGURATION\n",
"level": "INFO",
"module": "SYSTEM"
},
...
]
}
}
Note: The above example response was abbreviated for brevity to only include the first two elements in each list. Omitted elements are denoted by a
...
symbol.
"params"
An object with the following properties:
"id"
: A test id, required."language"
: A language tag, required.
"result"
An object with the following properties:
"created_at"
: A timestamp. The time in UTC at which the test was created."hash_id"
: A test id. The test in question."params"
: See below."results"
: A list of test result objects."testcase_descriptions"
: A map with the Test Case Identifiers as keys and the translated Test Case Description of the corresponding Test Cases as values.
If the test was created by start_domain_test
then "params"
is a normalized version "params"
object sent to start_domain_test
when the test was created.
If the test was created with add_batch_job
then "params"
is a normalized version of an object created from the following parts:
- The keys from the
"test_params"
object sent toadd_batch_job
when the test was created as part of a batch. - The
"domain"
key holding the specific domain name for this test result from the"domains"
object included in the call toadd_batch_job
.
TODO: Change name in the API of
"hash_id"
to"test_id"
"error"
TODO: List all possible error codes and describe what they mean enough for clients to know how react to them.
API method: get_test_params
Return a normalized params objects of a test.
Example request:
Valid syntax:
{
"jsonrpc": "2.0",
"id": 143014426992009,
"method": "get_test_params",
"params": {"test_id": "6814584dc820354a"}
}
Example response:
{
"jsonrpc": "2.0",
"id": 143014426992009,
"result": {
"domain": "zonemaster.net",
"profile": "default",
"client_id": "Zonemaster Dancer Frontend",
"nameservers": [
{
"ns": "ns3.nic.se",
"ip": "2001:67c:124c:2007::45"
},
{
"ip": "192.93.0.4",
"ns": "ns2.nic.fr"
}
],
"ipv4": true,
"ipv6": true,
"client_version": "1.0.1",
"ds_info": []
}
}
"params"
An object with the property:
"test_id"
: A test id, required.
"result"
The "params"
object sent to start_domain_test
or
add_batch_job
when the test was started.
"error"
TODO: List all possible error codes and describe what they mean enough for clients to know how react to them.
API method: get_test_history
Returns a list of completed tests for a domain.
Example request:
{
"jsonrpc": "2.0",
"id": 7,
"method": "get_test_history",
"params": {
"offset": 0,
"limit": 200,
"filter": "all",
"frontend_params": {
"domain": "zonemaster.net"
}
}
}
Example response:
{
"jsonrpc": "2.0",
"id": 7,
"result": [
{
"id": "c45a3f8256c4a155",
"creation_time": "2016-11-15 11:53:13.965982",
"created_at": "2016-11-15T11:53:13Z",
"undelegated": true,
"overall_result": "error"
},
{
"id": "32dd4bc0582b6bf9",
"undelegated": false,
"creation_time": "2016-11-14 08:46:41.532047",
"created_at": "2016-11-14T08:46:41Z",
"overall_result": "error"
},
...
]
}
Note: The above example response was abbreviated for brevity to only include the first two elements in each list. Omitted elements are denoted by a
...
symbol.
Undelegated and delegated
A test is considered to be "delegated"
below if the test was started, by
start_domain_test
or add_batch_job
without specifying neither "nameserver"
nor "ds_info"
. Else it is considered to
be "undelegated"
.
"params"
An object with the following properties:
"offset"
: A non-negative integer, optional. (default: 0). Position of the first returned element from the database returned list."limit"
: A non-negative integer, optional. (default: 200). Number of element returned from the offset element."filter"
: A string, one of"all"
,"delegated"
and"undelegated"
, optional. (default:"all"
)"frontend_params"
: An object, required.
The value of "frontend_params" is an object with the following properties:
"domain"
: A domain name, required.
"result"
An object with the following properties:
"id"
A test id."created_at"
: A timestamp. The time in UTC at which the test was created."overall_result"
: A string. It reflects the most severe problem level among the test results for the test. It has one of the following values:"ok"
, if there are only messages with severity level"INFO"
or"NOTICE"
."warning"
, if there is at least one message with severity level"WARNING"
, but none with"ERROR"
or"CRITICAL"
."error"
, if there is at least one message with severity level"ERROR"
, but none with"CRITICAL"
."critical"
, if there is at least one message with severity level"CRITICAL"
.
"undelegated"
:true
if the test is undelegated,false
otherwise.
"error"
TODO: List all possible error codes and describe what they mean enough for clients to know how react to them.
API method: add_api_user
In order to use the add_batch_job
method a
username and its api key must be added by this method.
This method is not available if RPCAPI.enable_add_api_user
is disabled (disabled by default). This method is not available unless the connection to
RPCAPI is over localhost (administrative method).
Example request:
{
"jsonrpc": "2.0",
"id": 4711,
"method": "add_api_user",
"params": {
"username": "citron",
"api_key": "fromage"
}
}
Example response:
{
"jsonrpc": "2.0",
"id": 4711,
"result": 1
}
"params"
An object with the following properties:
"username"
: A username, required. The username to be added."api_key"
: An api key, required. The api key for the username to be added.
"result"
An integer. The value is equal to 1 if the registration is a success, or 0 if it failed.
"error"
TODO: List all possible error codes and describe what they mean enough for clients to know how react to them.
Trying to add a already existing user:
{
"jsonrpc": "2.0",
"id": 1,
"error": {
"data": {
"username": "citron"
},
"message": "User already exists",
"code": -32603
}
}
Omitting params:
{
"jsonrpc": "2.0",
"id": 1,
"error": {
"code": "-32602",
"message": "Invalid method parameter(s).",
"data": [
{
"message": "Expected string - got null.",
"path": "/api_key"
}
]
}
}
{
"jsonrpc": "2.0",
"id": 1,
"error": {
"data": [
{
"path": "/username",
"message": "Expected string - got null."
}
],
"message": "Invalid method parameter(s).",
"code": "-32602"
}
}
Trying to add a user over non-localhost:
{
"jsonrpc": "2.0",
"id": 1,
"error": {
"code": -32603,
"data": {
"remote_ip": "10.0.0.1"
},
"message": "Call to \"add_api_user\" method not permitted from a remote IP"
}
}
Trying to add a user when the method is disabled:
{
"error": {
"code": -32601,
"message": "Procedure 'add_api_user' not found"
}
}
API method: add_batch_job
Add a new batch test composed by a set of domain name and a params object. All the domains will be tested using identical parameters.
This method is not available if RPCAPI.enable_add_batch_job
is disabled (enabled by default).
A username and its api key can be added with the
add_api_user
method.
Tests enqueued using this method are assigned a priority of 5.
In previous versions of Zonemaster-Backend a new batch could not be created by the same username if that username had created a batch that was not yet finished. That restriction has been removed in version 2023.2.
Example request:
{
"jsonrpc": "2.0",
"id": 147559211348450,
"method": "add_batch_job",
"params" : {
"api_key": "fromage",
"username": "citron",
"test_params": {},
"domains": [
"zonemaster.net",
"domain1.se",
"domain2.fr"
]
}
}
Example response:
{
"jsonrpc": "2.0",
"id": 147559211348450,
"result": 8
}
"params"
An object with the following properties:
"username"
: A username, required. The name of the account of an authorized user."api_key"
: An api key, required. The api_key associated with the username."domains"
: A list of domain names, required. The domains to be tested."test_params"
: As described below, optional. (default:{}
)
The value of "test_params"
is an object with the following properties:
"client_id"
: A client id, optional. (default: unset)"profile"
: A profile name, optional (default:"default"
). Run the tests using the given profile."client_version"
: A client version, optional. (default: unset)"nameservers"
: A list of name server objects, optional. (default:[]
)"ds_info"
: A list of DS info objects, optional. (default:[]
)"ipv4"
: A boolean, optional. (default:net.ipv4
profile value)."ipv6"
: A boolean, optional. (default:net.ipv6
profile value)."priority"
: A priority, optional. (default:5
)"queue"
: A queue, optional. (default:0
)
"result"
A batch id.
"error"
If the given profile
is not among the available profiles, a
user error is returned, see the profile name section.
Trying to add a batch when wrong username or api key is used:
{
"jsonrpc": "2.0",
"id": 1,
"error": {
"message": "User not authorized to use batch mode",
"code": -32603,
"data": {
"username": "citron"
}
}
}
Trying to add a batch with an empty list of domains:
{
"jsonrpc": "2.0",
"id": 1,
"error": {
"data": [
{
"message": "Not enough items: 0/1.",
"path": "/domains"
}
],
"message": "Invalid method parameter(s).",
"code": "-32602"
}
}
Trying to add a batch when the method has been disabled.
{
"error": {
"message": "Procedure 'add_batch_job' not found",
"code": -32601
}
}
API method: get_batch_job_result
Return all test id objects of a batch test, with the number of finished test.
Example request:
Valid syntax:
{
"jsonrpc": "2.0",
"id": 147559211994909,
"method": "batch_status",
"params": {
"batch_id": "8"
}
}
Example response:
{
"jsonrpc": "2.0",
"id": 147559211994909,
"result": {
"nb_finished": 5,
"finished_test_ids": [
"43b408794155324b",
"be9cbb44fff0b2a8",
"62f487731116fd87",
"692f8ffc32d647ca",
"6441a83fcee8d28d"
],
"nb_running": 195
}
}
"params"
An object with the property:
"batch_id"
: A batch id, required.
"result"
An object with the following properties:
"nb_finished"
: a non-negative integer. The number of finished tests."nb_running"
: a non-negative integer. The number of running tests."finished_test_ids"
: a list of test ids. The set of finished tests in this batch.
"error"
If the batch_id
is undefined the following error is returned:
{
"jsonrpc": "2.0",
"id": 1,
"error": {
"data": {
"batch_id": "10"
},
"message": "Unknown batch",
"code": -32603
}
}
Experimental API methods
There are also some experimental API methods documented only by name:
- system_versions
- conf_profiles
- conf_languages
- lookup_address_records
- lookup_delegation_data
- job_create
- job_status
- job_results
- job_params
- domain_history
- user_create
- batch_create
- batch_status
Telemetry
Metrics
If enabled in the Metrics section in the configuration file, Statsd compatible metrics are available to use:
Name | Type | Description |
---|---|---|
zonemaster.rpcapi.requests.<METHOD>.<STATUS> | Counter | Number of times the JSON RPC method <METHOD> resulted in JSON RPC status <STATUS>. The status is represented in string, possible values are: RPC_PARSE_ERROR , RPC_INVALID_REQUEST , RPC_METHOD_NOT_FOUND , RPC_INVALID_PARAMS , RPC_INTERNAL_ERROR . |
zonemaster.testagent.tests_started | Counter | Number of tests that have started. |
zonemaster.testagent.tests_completed | Counter | Number of tests that have been completed successfully. |
zonemaster.testagent.tests_died | Counter | Number of tests that have died. |
zonemaster.testagent.tests_duration_seconds | Timing | The duration of a test, emitted for each test. |
zonemaster.testagent.cleanup_duration_seconds | Timing | Time spent to kill timed out processes. |
zonemaster.testagent.fetchtests_duration_seconds | Timing | Time spent selecting the next text to run and processing unfinished tests. |
zonemaster.testagent.running_processes | Gauge | Number of running processes in a test agent. |
zonemaster.testagent.maximum_processes | Gauge | Maximum number of running processes in a test agent. |
Usage
Testing the metrics feature can be as easy as running a listening UDP server like
ns -lup 8125
This should be enough to see the metrics emitted by Zonemaster.
More complex setups are required for the metrics to be used in alerts and dashboards. StatsD metrics can be integrated to a number of metrics backend like Prometheus (using the StatsD exporter), InfluxDB (using Telegraf and the StatsD plugin), Graphite (integration guide) and others.
StatsD Exporter (Prometheus)
- Download the binary (tar file) corresponding to your environment https://github.com/prometheus/statsd_exporter/releases
- Untar the file
cd
into the statsd_exporter directory- Create a
statsd_mapping.yml
file with content as belowmappings: - match: zonemaster.rpcapi.requests.*.* name: zonemaster_rpcapi_requests_total labels: method: $1 status: $2 - match: zonemaster.testagent.tests_duration_seconds observer_type: histogram buckets: [ 1, 2.5, 5, 10, 15, 30, 45, 60, 75, 90, 105, 120, 150, 180] name: zonemaster_testagent_tests_duration_seconds - match: zonemaster.testagent.cleanup_duration_seconds observer_type: histogram buckets: [ 0.01, 0.025, 0.05, 0.075, 0.1, 0.25, 0.5, 0.75, 1, 1.25, 1.5, 1.75, 2] name: zonemaster_testagent_cleanup_duration_seconds - match: zonemaster.testagent.fetchtests_duration_seconds observer_type: histogram buckets: [ 0.001, 0.0025, 0.005, 0.0075, 0.01, 0.025, 0.05, 0.075, 0.1, 0.25, 0.5, 0.75, 1, 1.25, 1.5, 1.75, 2, 3, 5, 10] name: zonemaster_testagent_fetchtests_duration_seconds
- Run it like
./statsd_exporter --statsd.mapping-config=./statsd_mapping.yml --statsd.listen-udp=:8125 --statsd.listen-tcp=:8125
- Run the following to see Zonemaster metrics:
curl localhost:9102/metrics | grep zonemaster
Using the GUI
- The GUI API
API
The Zonemaster GUI provides an API to access specific resource and perform specific tasks.
A path is added to the Zonemaster GUI base URL, e.g. https://zonemaster.net/.
The supported paths are the following:
<lang>/run-test
: the default path, access the input form.<lang>/domain_check
: same asrun-test
, but deprecated.<lang>/run-test/<domain>
: populate the input form with<domain>
, which is expected to be a name of a DNS zone, and launch the test. Currently undelegated tests cannot be performed via the API.<lang>/result/<test-id>
: access the result page with results for the test with<test-id>
.<lang>/test/<test-id>
: same as<lang>/result/<test-id>
, but deprecated.<lang>/faq
: access the FAQ.
The GUI will rewrite <lang>/domain_check
to <lang>/run-test
before the page
is displayed. Note that <lang>/domain_check/<domain>
is not rewritten and
hence is an invalid path.
The GUI will rewrite <lang>/test/<test-id>
to <lang>/result/<test-id>
before the result is displayed.
The GUI will redirect from <path>
to <lang>/<path>
automatically using the
user browser language, if supported and configured by the installation.
Else it uses the default language defined in the reverse proxy configuration.
Specifications
- Test Cases: contains the specifications of the Test Cases that the Zonemaster implementation is based on.
- Test types: contains the specification of Test Types, currently only for undelegated tests.
- Test zones: contains the specifications of Test Zones for the verification of Test Case implementation.
Test Types
This directory contains Test Type specifications, currently only specification for undelegated tests.
Undelegated tests
Objective
The purpose of an undelegated test is to test a possible future delegation before it is put in production. Hence, while testing an undelegated test, extra information (such as name servers, IP addresses) must be provided as input, and Zonemaster should run the test cases with the provided information.
Specification
An undelegated test should mimic the a delegated test. The information for the test must be provided when starting the test.
An undelegated test can be run on a already delegated domain, but then Zonemaster must disregard the specific information for that domain found in public DNS.
Information that is part of the delegation must be provided with the initiation of the test. That following information is used for the undelegated test:
-
Domain (zone) to be tested. Mandatory information.
-
NS records. No NS records may be looked up before the test starts, the complete RR set must be provided. Mandatory information.
-
Glue records. The IP addresses of the name server names that belong to the delegated zone or below must be provided. They must not be looked up before the test starts. If not provided or only partly provided, the information will be treated as an incomplete delegation.
-
DS records. If no DS records are provided, then it is assumed that there are no DS records for the zone. They must not be looked up.
-
Name server addresses. Addresses of name server names that belong to the delegated zone is covered under "glue records" above. Addresses of other name servers may be provided, of else they are looked up. If at least one address (IPv4 or IPv6) is provided for a name server, then no further lookup shall be done for that name during the test (neither IPv4 nor IPv6).
The complete set of "NS records", the "Glue records" and the "DS records" is considered to be equivalent to what must be provided by the delegating zone, and replaces that, if the delegation exists. If the delegation does not exists, the provided set works as if the delegation existed.
The Name server addresses provided, if any, are considered to replace the real IP addresses for those name server names.
Test scenarios for verification of test case implementation
Table of contents
Objective
The purpose of the structure found here is to define test zones to be able to test the correctness of the implementation of the Zonemaster test cases. The main use case is to be the basis for the unit tests in the Zonemaster implementation. The second use case is to verify work in progress, e.g. implementation of new or updated test cases or updated test case implementation where the test case has not changed.
There can be other use cases, but only these two use cases are covered here and in the test zone specifications.
Test scenarios
The goal of the test scenarios is to cover all reasonable contexts where different message tags are outputted when a test case is run on test zones. The message tags are defined in the test case specifications found via "test cases" and the scenarios are defined in the test case specific specifications for test data found via the test-zones directory.
In the test zone specifications the scenarios are defined in two parts:
- What messages from test case that are expected to be outputted and what messages are expected not to be outputted when a test zone setup according to the scenario is tested by the test case.
- Specification of the zone setup for the scenario.
One special aspect is the test scenario name. Since the name is to be part of the test zone name there are some requirements on it:
- Under a specific test case there must not be two scenarios with the same name. Two closely related scenarios can, in their names, be separated with a relevant suffix.
- The length of the scenario name must not exceed 32 characters to give room for additional parts and still make sure it can fit into a DNS label.
- The character set of the name is limited to those of a host name, i.e.
A-Z0-9-
whereA-Z
will be downcased toa-z
in the domain name. - The scenario name must not start or end with
-
.
Test environment
The tests against the test zones are assumed to be run in a closed environment with a private DNS tree to achieve full access to any zone. Configuration data and instructions to set this up are available in the test-zone-data directory in this repository.
Naming conventions
In this document, domain names are given without trailing dot, except for the root
zone (or node) given as a dot .
.
The non-existing .xa
TLD and its tree is used to host the target test
zones, i.e. the zone name that will be given as Child Zone to the test case.
All test zones are to be created under .xa
except for a few cases elaborated
below.
Unless specified in the test zone specification, DNS records that can be stored within the zone should also be stored there:
- MX records should point at the relative name
mail
and that name should be added to the zone. - Name server names (NS record RDATA) should be in-bailiwick. "Prefixes" to be
used are
ns1
,ns2
,ns3
etc.
Test zone names
The normal test zone name is built from the following parts:
.xa
, the non-existing TLD used here.- The test case identifier in lower case, e.g.
zone09
. - The test scenario name in lower case, e.g.
no-response-mx-query
.
In the normal case, the test zone name is <scenario name>.<test case name>.xa
,
e.g. no-response-mx-query.zone09.xa
. The normal case should be used as long as
it is possible.
There are some exceptions to the name of the test zone that are identified here:
- If the test zone is the root, then the name is
.
. - If the test zone is a TLD zone, then the name is
<scenario name>-<test case name>
. Note that hyphen "-" is used between the parts to create one label. E.g.no-mx-tld-zone09
. In practice such a TLD can never be in conflict with real TLDs in the public DNS tree, especially since TLD names are not permitted to contain neither dash "-" nor digits. - If the test zone must be in the ARPA tree, then the name is
<scenario name>.<test case name>.arpa
, e.g.no-mx-arpa.zone09.arpa
. In practice such a name will never be in conflict with names in the public DNS tree since there no such names under public.arpa
. - If a scenario requires that the parent zone has different settings compared to
other scenarios for the same test case, then the test zone name is
child.<scenario name>.<test case name>.xa
, e.g.child.no-response-mx-query.zone09.xa
, whereno-response-mx-query.zone09.xa
, instead ofzone09.xa
, is the parent zone of the test zone. - If a scenario requires that the grandparent zone has different settings
compared to other scenarios for the same test case, then the test zone name is
child.parent.<scenario name>.<test case name>.xa
, e.g.child.parent.no-response-mx-query.zone09.xa
, whereno-response-mx-query.zone09.xa
, instead ofzone09.xa
, is the grandparent zone of the test zone.
Data outside the test zones
If a scenario requires that a certain name is outside its own zone, it should be
stored within the .xb
TLD (also a non-existing TLD) using the same name
structure as under .xa
, i.e. names for a scenario should be stored under
<scenario name>.<test case name>.xb
, e.g. no-mx-arpa.zone09.xb
. If required
test zones can be created in the same way under .xc
and .xd
.
What was stated above on data outside its own zone does not apply to reverse data
since that must be stored in the in-addr.arpa
or ip6.arpa
tree, and the
owner names of such data must follow the reverse data standards. There is no
requirements for creating separate zones for in-addr.arpa
or ip6.arpa
or
below.
Undelegated data
Some test scenarios require that an undelegated test be carried out on it. In that case, the scenario specification will contain a small "undelegated data" structure with one line per name server. The format is one of the following
- NAME-SERVER-NAME
- NAME-SERVER-NAME/IPv4
- NAME-SERVER-NAME/IPv6
where "NAME-SERVER-NAME" is the actual name of the name server, e.g.
ns1a.del-non-distinct-und.delegation02.xa
, and "IPv4" and "IPv6", respectively, are literal strings indicating that in the test zone configuration an IP address of that type should be used. If there is no "/IPv4" or "/IPv6" then the name server is given without IP address.
In the undelegated structure for a specific scenario the name server name can be repeated multiple times with different IP addresses. If it appears without IP address specification it should only appear once.
Here is an example of an undelegated data section from a scenario specification:
* Undelegated data:
* ns1a.del-non-distinct-und.delegation02.xa/IPv4
* ns1a.del-non-distinct-und.delegation02.xa/IPv6
* ns1b.del-non-distinct-und.delegation02.xa/IPv4
* ns1b.del-non-distinct-und.delegation02.xa/IPv6
Terminology
-
"Glue Record" - The term is used as defined in RFC 8499, section 7, pages 24-25.
-
"In-Bailiwick" - The term is used as defined in RFC 8499, section 7, pages 24-25. In this document it is limited to the meaning "in domain" in the RFC.
-
"Out-Of-Bailiwick" - The terms means, in this document, what is not "In-Bailiwick, in domain". RFC 8499, section 7, pages 24-25.
Specification of test zones for Basic-TP
Test zone specifications are available for:
- Basic01
- Basic02 not yet available
- Basic03 not yet available
Specification of test zones for Basic01
Table of contents
- Background
- Test Case
- Test scenarios
- Test zone names
- Test scenarios and message tags
- Zone setup for test scenarios
Background
See the test zone README file.
Test Case
This document specifies defined test zones for test case Basic01.
Test scenarios
The purpose of the test scenarios is to cover all reasonable contexts where different message tags are outputted when Basic01 is run on a test zone. The message tags are defined in the test case (Basic01) and the scenarios are defined below.
The test scenarios are structured as stated in the test zone README file.
Test zone names
The test zone for each test scenario in this document is a subdomain (or lower
zone) delegated from the base name (basic01.xa
) and that subdomain having the
same name as the scenario. The names of those zones are given in section
"Zone setup for test scenarios" below.
All tags
The test case can output any of these message tags, but not necessarily in any combination.
- B01_CHILD_FOUND
- B01_CHILD_IS_ALIAS
- B01_INCONSISTENT_ALIAS
- B01_INCONSISTENT_DELEGATION
- B01_NO_CHILD
- B01_PARENT_DISREGARDED
- B01_PARENT_FOUND
- B01_PARENT_NOT_FOUND
- B01_PARENT_UNDETERMINED
- B01_ROOT_HAS_NO_PARENT
- B01_SERVER_ZONE_ERROR
Test scenarios and message tags
If a message tag is not listed for the scenario, its presence or non-presence is irrelevant to the test scenario and must be ignored.
Scenario name | Mandatory message tag | Forbidden message tags |
---|---|---|
GOOD-1 | B01_CHILD_FOUND, B01_PARENT_FOUND | 2) |
GOOD-MIXED-1 | B01_CHILD_FOUND, B01_PARENT_FOUND | 2) |
GOOD-MIXED-2 | B01_CHILD_FOUND, B01_PARENT_FOUND | 2) |
GOOD-PARENT-HOST-1 | B01_CHILD_FOUND, B01_PARENT_FOUND | 2) |
GOOD-GRANDPARENT-HOST-1 | B01_CHILD_FOUND, B01_PARENT_FOUND | 2) |
GOOD-UNDEL-1 | B01_CHILD_FOUND, B01_PARENT_DISREGARDED | 2) |
GOOD-MIXED-UNDEL-1 | B01_CHILD_FOUND, B01_PARENT_DISREGARDED | 2) |
GOOD-MIXED-UNDEL-2 | B01_CHILD_FOUND, B01_PARENT_DISREGARDED | 2) |
NO-DEL-UNDEL-1 | B01_CHILD_FOUND, B01_PARENT_DISREGARDED | 2) |
NO-DEL-MIXED-UNDEL-1 | B01_CHILD_FOUND, B01_PARENT_DISREGARDED | 2) |
NO-DEL-MIXED-UNDEL-2 | B01_CHILD_FOUND, B01_PARENT_DISREGARDED | 2) |
NO-CHILD-1 | B01_NO_CHILD, B01_PARENT_FOUND | 2) |
NO-CHILD-2 | B01_NO_CHILD, B01_PARENT_FOUND | 2) |
NO-CHLD-PAR-UNDETER-1 | B01_NO_CHILD, B01_PARENT_FOUND, B01_PARENT_UNDETERMINED | 2) |
CHLD-FOUND-PAR-UNDET-1 | B01_CHILD_FOUND, B01_PARENT_FOUND, B01_PARENT_UNDETERMINED | 2) |
CHLD-FOUND-INCONSIST-1 | B01_CHILD_FOUND, B01_INCONSISTENT_DELEGATION, B01_PARENT_FOUND | 2) |
CHLD-FOUND-INCONSIST-2 | B01_CHILD_FOUND, B01_INCONSISTENT_DELEGATION, B01_PARENT_FOUND | 2) |
CHLD-FOUND-INCONSIST-3 | B01_CHILD_FOUND, B01_INCONSISTENT_DELEGATION, B01_PARENT_FOUND | 2) |
CHLD-FOUND-INCONSIST-4 | B01_CHILD_IS_ALIAS, B01_CHILD_FOUND, B01_INCONSISTENT_DELEGATION, B01_PARENT_FOUND | 2) |
CHLD-FOUND-INCONSIST-5 | B01_CHILD_FOUND, B01_INCONSISTENT_DELEGATION, B01_PARENT_FOUND | 2) |
CHLD-FOUND-INCONSIST-6 | B01_CHILD_FOUND, B01_INCONSISTENT_DELEGATION, B01_PARENT_FOUND | 2) |
CHLD-FOUND-INCONSIST-7 | B01_CHILD_FOUND, B01_INCONSISTENT_DELEGATION, B01_PARENT_FOUND | 2) |
CHLD-FOUND-INCONSIST-8 | B01_CHILD_FOUND, B01_INCONSISTENT_DELEGATION, B01_PARENT_FOUND | 2) |
CHLD-FOUND-INCONSIST-9 | B01_CHILD_IS_ALIAS, B01_CHILD_FOUND, B01_INCONSISTENT_DELEGATION, B01_PARENT_FOUND | 2) |
CHLD-FOUND-INCONSIST-10 | B01_CHILD_FOUND, B01_INCONSISTENT_DELEGATION, B01_PARENT_FOUND | 2) |
NO-DEL-UNDEL-NO-PAR-1 | B01_CHILD_FOUND, B01_PARENT_DISREGARDED | 2) |
NO-DEL-UNDEL-PAR-UND-1 | B01_CHILD_FOUND, B01_PARENT_DISREGARDED | 2) |
NO-CHLD-NO-PAR-1 | B01_NO_CHILD, B01_PARENT_NOT_FOUND, B01_SERVER_ZONE_ERROR | 2) |
CHILD-ALIAS-1 | B01_CHILD_IS_ALIAS, B01_NO_CHILD, B01_PARENT_FOUND | 2) |
CHILD-ALIAS-2 | B01_CHILD_IS_ALIAS, B01_NO_CHILD, B01_INCONSISTENT_ALIAS, B01_PARENT_FOUND | 2) |
ZONE-ERR-GRANDPARENT-1 | B01_CHILD_FOUND, B01_PARENT_FOUND, B01_SERVER_ZONE_ERROR | 2) |
ZONE-ERR-GRANDPARENT-2 | B01_CHILD_FOUND, B01_PARENT_FOUND, B01_SERVER_ZONE_ERROR | 2) |
ZONE-ERR-GRANDPARENT-3 | B01_CHILD_FOUND, B01_PARENT_FOUND, B01_SERVER_ZONE_ERROR | 2) |
ROOT-ZONE | B01_CHILD_FOUND, B01_ROOT_HAS_NO_PARENT | 2) |
- (1) All tags except for those specified as "Forbidden message tags" (no instances for these test scenarios)
- (2) All tags except for those specified as "Mandatory message tags"
Zone setup for test scenarios
Assumptions for the scenario specifications unless otherwise specified for the specific scenario:
- The child zone is
child.parent.SCENARIO.basic01.xa
.- It is delegated to two name servers,
ns1-delegated-child.basic01.xa
andns2-delegated-child.basic01.xa
.- The name server names have A and AAAA records to avoid non-relevant error messages.
- There is no zone file or zone data for the child zone.
- If there is an undelegated "version" of the child zone, it is
referred to
ns3-undelegated-child.basic01.xa
andns4-undelegated-child.basic01.xa
.- The name server names have A and AAAA records to avoid non-relevant error messages.
- There is no zone file or zone data for the undelegated "version".
- It is delegated to two name servers,
- The parent zone is
parent.SCENARIO.basic01.xa
.- It is served by two in-bailiwick NS (ns1 and ns2).
- ns1 and ns2 have the same zone content.
- ns1 and ns2 have both IPv4 and IPv6 glue.
- The records matching glue in the zone are complete.
- The delegation from the grand parent has the same NS with complete glue.
- The grandparent zone is
SCENARIO.basic01.xa
.- It is served by two in-bailiwick NS (ns1 and ns2).
- ns1 and ns2 have the same zone content.
- ns1 and ns2 have both IPv4 and IPv6 glue.
- The records matching glue in the zone are complete.
- The delegation from the SCENARIO zone has the same NS with complete glue.
- Responds with a A record for the zone on query for A.
- Responds with a AAAA record for the zone on query for AAAA.
- All responses are authoritative with RCODE Name "NoError"
- EDNS, version 0, is included in all responses on queries with EDNS.
- EDNS is not included in responses on queries without EDNS.
- Standard test zone root is used.
- In all cases, delegation and zone are consistent.
- Same NS.
- Any required glue matches address records in zone.
- No extra address records for the NS names.
GOOD-1
A "happy path". Everything is fine.
- Zone: child.parent.good-1.basic01.xa
GOOD-MIXED-1
One grandparent server also serves parent zone.
- Zone: child.parent.good-mixed-1.basic01.xa
- Parent zone
parent.good-mixed-1.basic01.xa
is served byns1
,ns2
and onns4.good-mixed-1.basic01.xa
. - Grandparent zone
good-mixed-1.basic01.xa
is served onns1
andns4
.
- Parent zone
GOOD-MIXED-2
One parent server also hosts the child zone.
- Zone: child.parent.good-mixed-2.basic01.xa
- Child zone is served by
ns1
,ns2
andns4.parent.good-mixed-2.basic01.xa
. - Child zone exists.
- There is a zone file for the child zone, and that is loaded on the child zone name servers.
- Parent zone
parent.good-mixed-2.basic01.xa
is served byns1
andns4
.
- Child zone is served by
GOOD-PARENT-HOST-1
The child is hosted on parent servers only.
- Zone: child.parent.good-parent-host-1.basic01.xa
- Child zone is served by
ns1.parent.good-parent-host-1.basic01.xa
andns2.parent.good-parent-host-1.basic01.xa
. - There is a zone file for the child zone.
- Child zone is served by
GOOD-GRANDPARENT-HOST-1
The child is hosted on grandparent servers only.
- Zone: child.parent.good-grandparent-host-1.basic01.xa
- Child zone is served by
ns1.good-grandparent-host-1.basic01.xa
andns2.good-grandparent-host-1.basic01.xa
. - There is a zone file for the child zone.
- Child zone is served by
GOOD-UNDEL-1
The child zone is delegated, but there is also an undelegated version which is the one tested.
- Zone: child.parent.good-undel-1.basic01.xa
- Child zone is delegated, but there is also an undelegated version.
- There are no zone files for child (delegated or undelegated).
- Undelegated data:
- ns3-undelegated-child.basic01.xa
- ns4-undelegated-child.basic01.xa
GOOD-MIXED-UNDEL-1
The child zone is delegated, but there is also an undelegated version which is the one tested. One grandparent server, in the delegated tree, also serves parent zone.
- Zone: child.parent.good-mixed-undel-1.basic01.xa
- Parent zone
parent.good-mixed-undel-1.basic01.xa
is served byns1
,ns2
and onns4.good-mixed-undel-1.basic01.xa
. - Grandparent zone
good-mixed-undel-1.basic01.xa
is served onns1
andns4
. - Child zone is delegated, but there is also an undelegated version.
- No child zone exists.
- Undelegated data:
- ns3-undelegated-child.basic01.xa
- ns4-undelegated-child.basic01.xa
- Parent zone
GOOD-MIXED-UNDEL-2
The child zone is delegated, but there is also an undelegated version. One parent server also serves the delegated child zone.
- Zone: child.parent.good-mixed-undel-2.basic01.xa
- Child zone is served by
ns1
,ns2
andns6.parent.good-mixed-undel-2.basic01.xa
. - Child zone exists.
- Parent zone
parent.good-mixed-undel-2.basic01.xa
is served byns1
andns6
. - Child zone is delegated, but there is also an undelegated version, but no zone for the undelegated version.
- Undelegated data:
- ns3-undelegated-child.basic01.xa
- ns4-undelegated-child.basic01.xa
- Child zone is served by
NO-DEL-UNDEL-1
The child zone is not delegated, but there is an undelegated version.
- Zone: child.parent.no-del-undel-1.basic01.xa
- Undelegated data:
- ns3-undelegated-child.basic01.xa
- ns4-undelegated-child.basic01.xa
- Undelegated data:
NO-DEL-MIXED-UNDEL-1
The child zone is not delegated, but there is an undelegated version that is tested. One grandparent server also serves the parent zone.
- Zone: child.parent.no-del-mixed-undel-1.basic01.xa
- Parent zone
parent.no-del-mixed-undel-1.basic01.xa
is served byns1
,ns2
and onns4.no-del-mixed-undel-1.basic01.xa
. - Grandparent zone
no-del-mixed-undel-1.basic01.xa
is served onns1
andns4
. - Child zone is not delegated, but there is an undelegated version, but no zone file.
- Undelegated data:
- ns3-undelegated-child.basic01.xa
- ns4-undelegated-child.basic01.xa
- Parent zone
NO-DEL-MIXED-UNDEL-2
The child zone is not delegated, but there is an undelegated version that is tested. One grandparent server also serves the parent zone. There are extra empty nodes between the zone cuts.
- Zone: child.w.x.parent.y.z.no-del-mixed-undel-2.basic01.xa
- Parent zone
parent.y.z.no-del-mixed-undel-2.basic01.xa
is served byns1
,ns2
and onns4.no-del-mixed-undel-2.basic01.xa
. - Grandparent zone
no-del-mixed-undel-2.basic01.xa
is served onns1
andns4
. - There are no zone cuts at
w
,x
,y
andz
. - Child zone is not delegated, but there is also an undelegated version, but no zone file.
- Undelegated data:
- ns3-undelegated-child.basic01.xa
- ns4-undelegated-child.basic01.xa
- Parent zone
NO-CHILD-1
The child zone is not delegated. Parent zone returns NXDOMAIN.
- Zone: child.parent.no-child-1.basic01.xa
- Child zone does not exist and is not served by any NS.
NO-CHILD-2
The child zone is not delegated. Parent zone returns NODATA.
- Zone: child.parent.no-child-2.basic01.xa
- Child zone does not exist and is not served by any NS.
- The name child.parent.no-child-2.basic01.xa exists as a TXT record.
NO-CHLD-PAR-UNDETER-1
The child zone is not delegated. One grandparent NS lacks delegation of parent and return NXDOMAIN of child. The parent zone lacks delegation of child.
- Zone: child.parent.no-chld-par-undeter-1.basic01.xa
- Child zone does not exist is not served by any NS.
- Grandparent
ns1
lacks delegation of parent. - Grandparent
ns2
has delegation of parent (to both parent NS). - Parent zone lacks delegation of child.
CHLD-FOUND-PAR-UNDET-1
The child zone is delegated from one grandparent NS and from the parent zone.
- Zone: child.parent.chld-found-par-undet-1.basic01.xa
- Grandparent
ns1
has delegation of child but lacks delegation of parent. - Grandparent
ns2
has delegation of parent (to both parent NS). - Parent zone has delegation of child.
- Grandparent
CHLD-FOUND-INCONSIST-1
The child is delegated from one parent NS. The other responds with NXDOMAIN.
- Zone: child.parent.chld-found-inconsist-1.basic01.xa
- Parent
ns1
has normal delegation of child to two child NS,ns1
andns2
. - Parent
ns2
lacks delegation of child (NXDOMAIN).
- Parent
CHLD-FOUND-INCONSIST-2
The child is delegated from one parent NS. On the other there is an CNAME response.
- Zone: child.parent.chld-found-inconsist-2.basic01.xa
- Parent
ns1
has normal delegation of child to two child NS,ns1
andns2
. - Parent
ns2
lacks delegation of child, and has a CNAME on that name, pointing atno-child.parent.chld-found-inconsist-2.basic01.xa
, which has two address records (A and AAAA) with the IP addresses of childns2
.
- Parent
CHLD-FOUND-INCONSIST-3
The child is delegated from one parent NS. On the other there is a CNAME to another name, and that other name is delegated.
- Zone: child.parent.chld-found-inconsist-3.basic01.xa
- Parent
ns1
has normal delegation of child to two child NS,ns1
andns2
. - Parent
ns2
lacks delegation of child, and has a CNAME on the name, pointing atsister.parent.chld-found-inconsist-3.basic01.xa
, which is delegated tons1-delegated-child.basic01.xa
andns2-delegated-child.basic01.xa
. - Zone
sister
does not exist.
- Parent
CHLD-FOUND-INCONSIST-4
The child is delegated from one parent NS. On the other there is a DNAME to another name.
- Zone: child.parent.chld-found-inconsist-4.basic01.xa
- Parent
ns1
has normal delegation of child to two child NS,ns1
andns2
. - Parent
ns2
has a DNAME onchild
pointing atsister.parent.chld-found-inconsist-4.basic01.xa
which is delegated tons1-delegated-child.basic01.xa
andns2-delegated-child.basic01.xa
. - Zone
sister
does not exist.
- Parent
CHLD-FOUND-INCONSIST-5
The child is delegated from one parent NS. On the other there is a NODATA response.
- Zone: child.parent.chld-found-inconsist-5.basic01.xa
- Parent
ns1
has normal delegation of child to two child NS,ns1
andns2
. - Parent
ns2
lacks delegation of child, insteadchild
has two address records (A and AAAA) with the IP addresses of childns2
.
- Parent
CHLD-FOUND-INCONSIST-6
The child is delegated from one parent NS, which is also NS for the child. On the other there is an NXDOMAIN response.
- Zone: child.parent.chld-found-inconsist-6.basic01.xa
- Parent
ns1
has normal delegation of child to the two child NS. - Parent
ns2
lacks delegation of child (NXDOMAIN). - Child shares
ns1.parent.chld-found-inconsist-6.basic01.xa
with parent. - Child also uses child
ns2
. - Child exists with a zone.
- Parent
CHLD-FOUND-INCONSIST-7
The child is delegated from one parent NS, which is also NS for the child. On the other there is a CNAME response.
- Zone: child.parent.chld-found-inconsist-7.basic01.xa
- Parent
ns1
has normal delegation of child to two child NS,ns1
andns2
. - Parent
ns2
lacks delegation of child, and has a CNAME on that name, pointing atno-child.parent.chld-found-inconsist-7.basic01.xa
, which has two address records (A and AAAA) with the IP addresses of childns2
. - Child shares
ns1.parent.chld-found-inconsist-7.basic01.xa
with parent. - Child also uses
ns2
. - Child exists with a zone.
- Parent
CHLD-FOUND-INCONSIST-8
The child is delegated from one parent NS, which is also NS for the child. On the other there is a CNAME to another name, and that other name is delegated.
- Zone: child.parent.chld-found-inconsist-8.basic01.xa
- Parent
ns1
has normal delegation of child to two child NS,ns1
andns2
. - Parent
ns2
lacks delegation of child, and has a CNAME on the name, pointing atsister.parent.chld-found-inconsist-8.basic01.xa
, which isns1-delegated-child.basic01.xa
andns2-delegated-child.basic01.xa
. - Zone
sister
does not exist. - Child shares
ns1.parent.chld-found-inconsist-8.basic01.xa
with parent. - Child also uses
ns2
. - Child exists with a zone.
- Parent
CHLD-FOUND-INCONSIST-9
The child is delegated from one parent NS, which is also NS for the child. On the other there is a DNAME to another name.
- Zone: child.parent.chld-found-inconsist-9.basic01.xa
- Parent
ns1
has normal delegation of child to two child NS,ns1
andns2
. - Parent
ns2
has a DNAME onchild
pointing atsister.parent.chld-found-inconsist-9.basic01.xa
which is delegated tons1-delegated-child.basic01.xa
andns2-delegated-child.basic01.xa
. - Zone
sister
does not exist. - Child shares
ns1.parent.chld-found-inconsist-9.basic01.xa
with parent. - Child also uses
ns2
. - Child exists with a zone.
- Parent
CHLD-FOUND-INCONSIST-10
The child is delegated from one parent NS, which is also NS for the child. On the other there is a NODATA response.
- Zone: child.parent.chld-found-inconsist-10.basic01.xa
- Parent
ns1
has normal delegation of child to two child NS,ns1
andns2
. - Parent
ns2
lacks delegation of child, insteadchild
has two address records (A and AAAA) with the IP addresses of childns2
. - Child shares
ns1.parent.chld-found-inconsist-10.basic01.xa
with parent. - Child also uses
ns2
. - Child exists with a zone.
- Parent
NO-DEL-UNDEL-NO-PAR-1
The child is not delegated, but there is undelegated data to test. Both grandparent NS return SERVFAIL.
- Zone: child.parent.no-del-undel-no-par-1.basic01.xa
- Grandparent
ns1
andns2
both return SERVFAIL. - No need of parent zone.
- Child zone is not delegated, but there is an undelegated version.
- Undelgated data:
- ns3-undelegated-child.basic01.xa
- ns4-undelegated-child.basic01.xa
- Grandparent
NO-DEL-UNDEL-PAR-UND-1
The child is not delegated, but there is an undelegated data to test. One grandparent NS lacks delegation of parent and return NXDOMAIN of child. The parent zone lacks delegation of child.
- Zone: child.parent.no-del-undel-par-und-1.basic01.xa
- Child zone does not exist is not served by any NS.
- Grandparent
ns1
lacks delegation of parent. - Grandparent
ns2
has delegation of parent (to both parent NS). - Parent zone lacks delegation of child.
- Child zone is not delegated, but there is an undelegated version.
- Undelegated data:
- ns3-undelegated-child.basic01.xa
- ns4-undelegated-child.basic01.xa
NO-CHLD-NO-PAR-1
The child is not delegated. Both grandparent NS return SERVFAIL.
- Zone: child.parent.no-chld-no-par-1.basic01.xa
- Grandparent
ns1
andns2
both return SERVFAIL. - No need of parent zone.
- Child zone is not delegated, and there is no undelegated data.
- No need of child zone.
- Grandparent
CHILD-ALIAS-1
The child zone does not exist, instead there is a DNAME in the parent zone.
- Zone: child.parent.child-alias-1.basic01.xa
- Parent has a DNAME on
child
pointing atsister.parent.child-alias-1.basic01.xa
which is delegated tons1-delegated-child.basic01.xa
andns2-delegated-child.basic01.xa
. - Zone
sister
does not exist.
- Parent has a DNAME on
CHILD-ALIAS-2
The child zone does not exist, instead there is a DNAME in the parent zone, however, different DNAME targets in the two parents.
- Zone: child.parent.child-alias-2.basic01.xa
- On
ns1
parent has a DNAME onchild
pointing atsister.parent.child-alias-2.basic01.xa
which is delegated tons1-delegated-child.basic01.xa
andns2-delegated-child.basic01.xa
. - Zone
sister
does not exist. - On
ns2
parent has a DNAME onchild
pointing atbrother.parent.child-alias-2.basic01.xa
which is delegated tons1-delegated-child.basic01.xa
andns2-delegated-child.basic01.xa
. - Zone
brother
does not exist.
- On
ZONE-ERR-GRANDPARENT-1
Grandparent ns2
responds with AA bit unset on queries for grandparent zone.
- Zone: child.parent.zone-err-grandparent-1.basic01.xa
- Normal response on grandparent
ns1
. - Grandparent
ns2
responds with AA bit unset on queries for the grandparent zone.
- Normal response on grandparent
ZONE-ERR-GRANDPARENT-2
Grandparent ns2
responds with NODATA on NS query for grandparent zone.
- Zone: child.parent.zone-err-grandparent-2.basic01.xa
- Normal response on grandparent
ns1
. - Grandparent
ns2
responds with NODATA on NS query for the grandparent zone.
- Normal response on grandparent
ZONE-ERR-GRANDPARENT-3
Grandparent ns2
responds with wrong owner name on NS
on query for grandparent zone NS.
- Zone: child.parent.zone-err-grandparent-3.basic01.xa
- Normal response on grandparent
ns1
. - Grandparent
ns2
responds with other owner name on NS query forzone-err-grandparent-3.basic01.xa
:- Owner name
oncle.zone-err-grandparent-3.basic01.xa
instead.
- Owner name
- Normal response on grandparent
ROOT-ZONE
Test on the standard root zone.
- Zone: .
- No special zone files are to be created.
Specification of test zones for Consistency-TP
Test zone specifications are available for:
Specification of test zones for CONSISTENCY05
Table of contents
- Background
- Test Case
- Test scenarios
- Test zone names
- Test scenarios and message tags
- Zone setup for test scenarios
Background
See the test zone README file.
Test Case
This document specifies defined test zones for test case CONSISTENCY05.
Test scenarios
The purpose of the test scenarios is to cover all reasonable contexts where different message tags are outputted when CONSISTENCY05 is run on a test zone. The message tags are defined in the test case (CONSISTENCY05) and the scenarios are defined below.
The test scenarios are structured as stated in the test zone README file.
Test zone names
The test zone for each test scenario in this document is a subdomain delegated
from the base name (consistency05.xa
) and that subdomain having the same name as the
scenario. The names of those zones are given in section
"Zone setup for test scenarios" below.
Test scenarios and message tags
If a message tag is not listed for the scenario, its presence or non-presence is irrelevant to the test scenario and must be ignored.
Scenario name | Mandatory message tag | Forbidden message tags |
---|---|---|
ADDRESSES-MATCH-1 | ADDRESSES_MATCH | IN_BAILIWICK_ADDR_MISMATCH, OUT_OF_BAILIWICK_ADDR_MISMATCH, EXTRA_ADDRESS_CHILD, CHILD_ZONE_LAME, CHILD_NS_FAILED, NO_RESPONSE |
ADDRESSES-MATCH-2 | ADDRESSES_MATCH | IN_BAILIWICK_ADDR_MISMATCH, OUT_OF_BAILIWICK_ADDR_MISMATCH, EXTRA_ADDRESS_CHILD, CHILD_ZONE_LAME, CHILD_NS_FAILED, NO_RESPONSE |
ADDRESSES-MATCH-3 | ADDRESSES_MATCH, CHILD_NS_FAILED | IN_BAILIWICK_ADDR_MISMATCH, OUT_OF_BAILIWICK_ADDR_MISMATCH, EXTRA_ADDRESS_CHILD, CHILD_ZONE_LAME, NO_RESPONSE |
ADDRESSES-MATCH-4 | ADDRESSES_MATCH, CHILD_NS_FAILED | IN_BAILIWICK_ADDR_MISMATCH, OUT_OF_BAILIWICK_ADDR_MISMATCH, EXTRA_ADDRESS_CHILD, CHILD_ZONE_LAME, NO_RESPONSE |
ADDRESSES-MATCH-5 | ADDRESSES_MATCH, NO_RESPONSE | IN_BAILIWICK_ADDR_MISMATCH, OUT_OF_BAILIWICK_ADDR_MISMATCH, EXTRA_ADDRESS_CHILD, CHILD_ZONE_LAME, CHILD_NS_FAILED |
ADDRESSES-MATCH-6 | ADDRESSES_MATCH | IN_BAILIWICK_ADDR_MISMATCH, OUT_OF_BAILIWICK_ADDR_MISMATCH, EXTRA_ADDRESS_CHILD, CHILD_ZONE_LAME, CHILD_NS_FAILED, NO_RESPONSE |
ADDRESSES-MATCH-7 | ADDRESSES_MATCH | IN_BAILIWICK_ADDR_MISMATCH, OUT_OF_BAILIWICK_ADDR_MISMATCH, EXTRA_ADDRESS_CHILD, CHILD_ZONE_LAME, CHILD_NS_FAILED, NO_RESPONSE |
ADDR-MATCH-DEL-UNDEL-1 | ADDRESSES_MATCH | IN_BAILIWICK_ADDR_MISMATCH, OUT_OF_BAILIWICK_ADDR_MISMATCH, EXTRA_ADDRESS_CHILD, CHILD_ZONE_LAME, CHILD_NS_FAILED, NO_RESPONSE |
ADDR-MATCH-DEL-UNDEL-2 | ADDRESSES_MATCH | IN_BAILIWICK_ADDR_MISMATCH, OUT_OF_BAILIWICK_ADDR_MISMATCH, EXTRA_ADDRESS_CHILD, CHILD_ZONE_LAME, CHILD_NS_FAILED, NO_RESPONSE |
ADDR-MATCH-NO-DEL-UNDEL-1 | ADDRESSES_MATCH | IN_BAILIWICK_ADDR_MISMATCH, OUT_OF_BAILIWICK_ADDR_MISMATCH, EXTRA_ADDRESS_CHILD, CHILD_ZONE_LAME, CHILD_NS_FAILED, NO_RESPONSE |
ADDR-MATCH-NO-DEL-UNDEL-2 | ADDRESSES_MATCH | IN_BAILIWICK_ADDR_MISMATCH, OUT_OF_BAILIWICK_ADDR_MISMATCH, EXTRA_ADDRESS_CHILD, CHILD_ZONE_LAME, CHILD_NS_FAILED, NO_RESPONSE |
CHILD-ZONE-LAME-1 | CHILD_ZONE_LAME, NO_RESPONSE | IN_BAILIWICK_ADDR_MISMATCH, OUT_OF_BAILIWICK_ADDR_MISMATCH, EXTRA_ADDRESS_CHILD, CHILD_NS_FAILED, ADDRESSES_MATCH |
CHILD-ZONE-LAME-2 | CHILD_ZONE_LAME, CHILD_NS_FAILED | IN_BAILIWICK_ADDR_MISMATCH, OUT_OF_BAILIWICK_ADDR_MISMATCH, EXTRA_ADDRESS_CHILD, ADDRESSES_MATCH, NO_RESPONSE |
IB-ADDR-MISMATCH-1 | IN_BAILIWICK_ADDR_MISMATCH, EXTRA_ADDRESS_CHILD | OUT_OF_BAILIWICK_ADDR_MISMATCH, CHILD_ZONE_LAME, CHILD_NS_FAILED, NO_RESPONSE, ADDRESSES_MATCH |
IB-ADDR-MISMATCH-2 | IN_BAILIWICK_ADDR_MISMATCH | OUT_OF_BAILIWICK_ADDR_MISMATCH, EXTRA_ADDRESS_CHILD, CHILD_ZONE_LAME, CHILD_NS_FAILED, NO_RESPONSE, ADDRESSES_MATCH |
IB-ADDR-MISMATCH-3 | IN_BAILIWICK_ADDR_MISMATCH, NO_RESPONSE | OUT_OF_BAILIWICK_ADDR_MISMATCH, EXTRA_ADDRESS_CHILD, CHILD_ZONE_LAME, CHILD_NS_FAILED, NO_RESPONSE, ADDRESSES_MATCH |
IB-ADDR-MISMATCH-4 | IN_BAILIWICK_ADDR_MISMATCH | OUT_OF_BAILIWICK_ADDR_MISMATCH, EXTRA_ADDRESS_CHILD, CHILD_ZONE_LAME, CHILD_NS_FAILED, NO_RESPONSE, ADDRESSES_MATCH |
EXTRA-ADDRESS-CHILD | EXTRA_ADDRESS_CHILD | IN_BAILIWICK_ADDR_MISMATCH, OUT_OF_BAILIWICK_ADDR_MISMATCH, CHILD_ZONE_LAME, CHILD_NS_FAILED, NO_RESPONSE, ADDRESSES_MATCH |
OOB-ADDR-MISMATCH | OUT_OF_BAILIWICK_ADDR_MISMATCH | IN_BAILIWICK_ADDR_MISMATCH, EXTRA_ADDRESS_CHILD, CHILD_ZONE_LAME, CHILD_NS_FAILED, NO_RESPONSE, ADDRESSES_MATCH |
Zone setup for test scenarios
Assumptions for the scenario specifications unless otherwise specified for the specific scenario:
- For each scenario zone there are two name servers configured.
- Both NS (ns1 and ns2) are equal in delegation and in zone.
- Both NS are in-bailiwick
- Both NS have both IPv4 and IPv6 addresses
- All required glue are present in the delegation.
- All glue exactly matches the authoritative address records in correct zone (not more and not less records).
- All NS IP addresses respond with identical zone content.
- Responds with a A record for the zone on query for A.
- Responds with a AAAA record for the zone on query for AAAA.
- All responses are authoritative with RCODE Name "NoError"
- EDNS, version 0, is included in all responses on queries with EDNS.
- EDNS is not included in responses on queries without EDNS.
- In undelegated data,
IPv4
andIPv6
, respectively, are placeholders for the actual IP addresses used for the scenario. They are to be found where the data is specified.- If no placeholder is given with the name server name, then no IP address is given and might be looked up.
- The format for undelegated data follow the format used for
zonemaster-cli
(after--ns
).
ADDRESSES-MATCH-1
The "happy path". Everything is fine.
- Zone: addresses-match-1.consistency05.xa
ADDRESSES-MATCH-2
Also the "happy path". Out-of-bailiwick NS this time. And no glue.
- Zone: addresses-match-2.consistency05.xa
- Both ns1 and ns2 are out-of-bailiwick under the xb tree.
- ns1 is "ns1.addresses-match-2.consistency05.xb"
- ns2 is "ns2.addresses-match-2.consistency05.xb"
- Delegation is without glue.
- The zone has no address records for the NS names
- The "addresses-match-2.consistency05.xb" zone has a full set of the address records for ns1 and ns2.
ADDRESSES-MATCH-3
One NS does not give AA answer, but else fine.
- Zone: addresses-match-3.consistency05.xa
- ns1 responds with AA flag unset.
ADDRESSES-MATCH-4
One NS does give SERVFAIL response, but else fine.
- Zone: addresses-match-4.consistency05.xa
- ns1 responds with RCODE Name "ServFail".
ADDRESSES-MATCH-5
One NS does not respond, but else fine.
- Zone: addresses-match-5.consistency05.xa
- ns1 gives no response at all.
ADDRESSES-MATCH-6
Also "happy path". Out-of-bailiwick NS, but with glue.
- Zone: child.addresses-match-6.consistency05.xa
- Both ns1 and ns2 are out-of-bailiwick
- ns1 is "ns1.sibbling.addresses-match-6.consistency05.xa"
- ns2 is "ns2.sibbling.addresses-match-6.consistency05.xa"
- Delegation is with glue.
- The test zone ("child") has no address records for the NS names, but the "sibbling" zone has full set of address records.
ADDRESSES-MATCH-7
Also "happy path". NS in subdomain.
- Zone: addresses-match-7.consistency05.xa
- ns1 is "ns1.subdomain.addresses-match-7.consistency05.xa."
- ns2 is "ns2.subdomain.addresses-match-7.consistency05.xa."
- Delegation is with glue.
- "subdomain.addresses-match-7.consistency05.xa" is delegated to the same ns1 and ns2.
- ns1 and ns2 are defined with address records in the "subdomain" zone.
ADDR-MATCH-DEL-UNDEL-1
Also the "happy path". But there is an undelegated zone to be tested.
- Zone: addr-match-del-undel-1.consistency05.xa
- Delegated zone on ns1 and ns2.
- Undelegated zone on ns3 and ns4.
- Delegated zone has neither ns1, ns2, ns3 nor ns4 as address records.
- Undelegated zone has neither ns1 nor ns2 as an address record, but it has both ns3 and ns4 as address records.
- Undelgated data:
- ns3.addr-match-del-undel-1.consistency05.xa/IPv4
- ns3.addr-match-del-undel-1.consistency05.xa/IPv6
- ns4.addr-match-del-undel-1.consistency05.xa/IPv4
- ns4.addr-match-del-undel-1.consistency05.xa/IPv6
ADDR-MATCH-DEL-UNDEL-2
Also the "happy path". But there is an undelegated zone to be tested, and its NS are out-of-bailiwick.
- Zone: addr-match-del-undel-2.consistency05.xa
- Delegated zone on ns1 and ns2.
- Undelegated zone on "ns3.addr-match-del-undel-2.consistency05.xb" and "ns4.addr-match-del-undel-2.consistency05.xb".
- Delegated and undelegated zone, respectively, do not have neither ns1 nor ns2 as an address record.
- Undelegated data:
- ns3.addr-match-del-undel-2.consistency05.xb
- ns4.addr-match-del-undel-2.consistency05.xb
ADDR-MATCH-NO-DEL-UNDEL-1
Also the "happy path". No delegation but there is an undelegated zone to be tested.
- Zone: addr-match-no-del-undel-1.consistency05.xa
- No delegated zone.
- Undelegated zone on ns1 and ns2.
- Undelegated data:
- ns1.addr-match-no-del-undel-1.consistency05.xa/IPv4
- ns1.addr-match-no-del-undel-1.consistency05.xa/IPv6
- ns2.addr-match-no-del-undel-1.consistency05.xa/IPv4
- ns2.addr-match-no-del-undel-1.consistency05.xa/IPv6
ADDR-MATCH-NO-DEL-UNDEL-2
Also the "happy path". No delegation but there is an undelegated zone to be tested. NS are out-of-bailiwick.
- Zone: addr-match-no-del-undel-2.consistency05.xa
- No delegated zone.
- Undelegated zone on "ns3.addr-match-no-del-undel-2.consistency05.xb" and "ns4.addr-match-no-del-undel-2.consistency05.xb".
- Undelegated data:
- ns3.addr-match-no-del-undel-2.consistency05.xb
- ns4.addr-match-no-del-undel-2.consistency05.xb
CHILD-ZONE-LAME-1
Lame. No NS responds.
- Zone: child-zone-lame-1.consistency05.xa
- ns1 and ns2 do not respond.
CHILD-ZONE-LAME-2
Lame. One NS non-AA and one NS SERVFAIL.
- Zone: child-zone-lame-2.consistency05.xa
- ns1 responses with AA bit unset.
- ns2 responds with RCODE Name "ServFail".
IB-ADDR-MISMATCH-1
For one NS (in-bailiwick), the addresses in the glue do not match those in the authoritative data from the zone.
- Zone: ib-addr-mismatch-1.consistency05.xa
- ns2 is defined in the zone, but with different addresses (IPv4 and IPv6), i.e. not the same as in glue.
- Both ns2 servers (IP address sets from glue and child, respectively) must give identical DNS responses.
IB-ADDR-MISMATCH-2
For one NS (in-bailiwick), address records exist in the glue, but not in the authoritative data for the zone.
- Zone: ib-addr-mismatch-2.consistency05.xa
- ns2 is not defined in the zone, i.e. there are no address records for ns2 (IPv4 or IPv6) in the zone.
IB-ADDR-MISMATCH-3
For ns2 (in-bailiwick), there is no NS for ns2 and the glue does not match any address records in the zone. Furthermore, ns2 does not respond.
- Zone: ib-addr-mismatch-3.consistency05.xa
- There is no NS record with ns2 in RDATA.
- ns2 is not defined in the zone, i.e. there are no address records for ns2 (IPv4 or IPv6) in the zone.
- ns2 does not respond (but it is in the delegation)
IB-ADDR-MISMATCH-4
Both NS are in-bailiwick and exist with correct glue in the delegation, but there are no address records in the zone matching the glue records.
- Zone: ib-addr-mismatch-4.consistency05.xa
- Neither ns1 nor ns2 are defined in the zone as address records.
- The correct NS records are in the zone.
EXTRA-ADDRESS-CHILD
Child zone has one extra address record on the NS name.
- Zone: extra-address-child.consistency05.xa
- The zone has address records for ns2 that match glue, but in addition the zone has extra A and AAAA records for ns2.
- Both ns2 servers (both sets of IP addresses from child) must give identical DNS responses.
OOB-ADDR-MISMATCH
For one NS (out-of-bailiwick, but with glue) glue does not match AA address response.
- Zone: child.oob-addr-mismatch.consistency05.xa
- Both ns1 and ns2 are out-of-bailiwick
- ns1 is "ns1.sibbling.oob-addr-mismatch.consistency05.xa"
- ns2 is "ns2.sibbling.oob-addr-mismatch.consistency05.xa"
- Delegation is with glue.
- The test zone ("child") has no address records for the NS names.
- The "sibling" zone has full set of address records
- ns1 in the "sibling" zone matches the addresses of glue.
- ns2 in the "sibling" zone does not match the addresses of glue.
- All IP addresses of ns1 and ns2 must serve identical versions of the zone.
Specification of test zones for CONSISTENCY06
Table of contents
- Background
- Test Case
- Test scenarios
- Test zone names
- Test scenarios and message tags
- Zone setup for test scenarios
Background
See the test zone README file.
Test Case
This document specifies defined test zones for test case CONSISTENCY06.
Test scenarios
The purpose of the test scenarios is to cover all reasonable contexts where different message tags are outputted when CONSISTENCY06 is run on a test zone. The message tags are defined in the test case (CONSISTENCY06) and the scenarios are defined below.
The test scenarios are structured as stated in the test zone README file.
Test zone names
The test zone for each test scenario in this document is a subdomain delegated
from the base name (consistency06.xa
) and that subdomain having the same name as the
scenario. The names of those zones are given in section
"Zone setup for test scenarios" below.
Test scenarios and message tags
If a message tag is not listed for the scenario, its presence or non-presence is irrelevant to the test scenario and must be ignored.
Scenario name | Mandatory message tag | Forbidden message tags |
---|---|---|
ONE-SOA-MNAME-1 | ONE_SOA_MNAME | NO_RESPONSE, NO_RESPONSE_SOA_QUERY, MULTIPLE_SOA_MNAMES |
ONE-SOA-MNAME-2 | ONE_SOA_MNAME, NO_RESPONSE | NO_RESPONSE_SOA_QUERY, MULTIPLE_SOA_MNAMES |
ONE-SOA-MNAME-3 | ONE_SOA_MNAME, NO_RESPONSE_SOA_QUERY | NO_RESPONSE, MULTIPLE_SOA_MNAMES |
ONE-SOA-MNAME-4 | ONE_SOA_MNAME, NO_RESPONSE | NO_RESPONSE_SOA_QUERY, MULTIPLE_SOA_MNAMES |
MULTIPLE-SOA-MNAMES-1 | MULTIPLE_SOA_MNAMES | NO_RESPONSE, NO_RESPONSE_SOA_QUERY, ONE_SOA_MNAME |
MULTIPLE-SOA-MNAMES-2 | MULTIPLE_SOA_MNAMES,NO_RESPONSE | NO_RESPONSE_SOA_QUERY, ONE_SOA_MNAME |
MULT-SOA-MNAMES-NO-DEL-UNDEL-1 | MULTIPLE_SOA_MNAMES | NO_RESPONSE, NO_RESPONSE_SOA_QUERY, ONE_SOA_MNAME |
MULT-SOA-MNAMES-NO-DEL-UNDEL-2 | MULTIPLE_SOA_MNAMES | NO_RESPONSE, NO_RESPONSE_SOA_QUERY, ONE_SOA_MNAME |
NO-RESPONSE | NO_RESPONSE | NO_RESPONSE_SOA_QUERY, MULTIPLE_SOA_MNAMES, ONE_SOA_MNAME |
Zone setup for test scenarios
Assumptions for the scenario specifications unless otherwise specified for the specific scenario:
- For each scenario zone there are two name servers configured.
- Both NS (ns1 and ns2) are equal in delegation and in zone.
- Both NS are in-bailiwick
- Both NS have both IPv4 and IPv6 addresses
- All required glue are present in the delegation.
- All NS IP addresses respond with identical zone content.
- All queries for SOA are responded with a SOA record in an authoritative answer.
- ns1 and ns2 respond with identical SOA records.
- All responses, to zone content, are authoritative with RCODE Name "NoError"
- EDNS, version 0, is included in all responses on queries with EDNS.
- EDNS is not included in responses on queries without EDNS.
- In undelegated data,
IPv4
andIPv6
, respectively, are placeholders for the actual IP addresses used for the scenario. They are to be found where the data is specified.- If no placeholder is given with the name server name, then no IP address is given and might be looked up.
- The format for undelegated data follow the format used for
zonemaster-cli
(after--ns
).
ONE-SOA-MNAME-1
The "happy path". Everything is fine.
- Zone: one-soa-mname-1.consistency06.xa.
ONE-SOA-MNAME-2
Not so "happy path". One name server does not respond.
- Zone: one-soa-mname-2.consistency06.xa.
- ns1 gives no response at all.
ONE-SOA-MNAME-3
Not so "happy path". One name server responds without SOA
- Zone: one-soa-mname-3.consistency06.xa.
- ns1 responds, but with no SOA record in the answer section (maybe answering but not having the zone).
ONE-SOA-MNAME-4
Not so "happy path". One name server does not respond. That ns is also missing in the zone.
- Zone: one-soa-mname-4.consistency06.xa.
- ns2 gives no response at all.
- ns2 is missing in the zone (but available in the delegation)
MULTIPLE-SOA-MNAMES-1
Different SOA MNAME on the servers
- Zone: multiple-soa-mnames-1.consistency06.xa.
- MNAME in SOA on ns1 equal to ns1
- MNAME in SOA on ns2 equal to ns2
MULTIPLE-SOA-MNAMES-2
Different SOA MNAME on two servers and a third not responding server
- Zone: multiple-soa-mnames-2.consistency06.xa.
- MNAME in SOA on ns1 equal to ns1
- MNAME in SOA on ns2 equal to ns2
- Also delegated to ns3, for which there is no response.
MULT-SOA-MNAMES-NO-DEL-UNDEL-1
Zone not delegated, but there is an undelegated version. Different SOA MNAME on the servers.
- Zone: mult-soa-mnames-no-del-undel-1.consistency06.xa.
- MNAME in SOA on ns1 equal to ns1
- MNAME in SOA on ns2 equal to ns2
- Undelegated data:
- ns1.mult-soa-mnames-no-del-undel-1.consistency06.xa/IPv4
- ns1.mult-soa-mnames-no-del-undel-1.consistency06.xa/IPv6
- ns2.mult-soa-mnames-no-del-undel-1.consistency06.xa/IPv4
- ns2.mult-soa-mnames-no-del-undel-1.consistency06.xa/IPv6
MULT-SOA-MNAMES-NO-DEL-UNDEL-2
Zone not delegated, but there is an undelegated version. Different SOA MNAME on the servers. NS are out-of-bailiwick.
- Zone: mult-soa-mnames-no-del-undel-2.consistency06.xa.
- NS are out-of-bailiwick, "ns3.mult-soa-mnames-no-del-undel-2.consistency06.xb" and "ns4.mult-soa-mnames-no-del-undel-2.consistency06.xb".
- MNAME in SOA on ns1 equal to ns1
- MNAME in SOA on ns2 equal to ns2
- Undelegated data:
- ns3.mult-soa-mnames-no-del-undel-2.consistency06.xb
- ns3.mult-soa-mnames-no-del-undel-2.consistency06.xb
NO-RESPONSE
No name server responds.
- Zone: no-response.consistency06.xa.
- ns1 gives no response at all.
- ns2 gives no response at all.
Specification of test scenarios for DNSSEC-TP
Test scenario specifications are available for:
Specification of test zones for DNSSEC03
Table of contents
- Background
- Test Case
- Test scenarios
- Test zone names
- Test scenarios and message tags
- Zone setup for test scenarios
- Terminology
Background
See the test zone README file.
Test Case
This document specifies defined test zones for test case DNSSEC03.
Test scenarios
The purpose of the test scenarios is to cover all reasonable contexts where different message tags are outputted when DNSSEC03 is run on a test zone. The message tags are defined in the test case (DNSSEC03) and the scenarios are defined below.
The test scenarios are structured as stated in the test zone README file.
Test zone names
The test zone for each test scenario in this document is a subdomain delegated
from the base name (dnssec03.xa
) and that subdomain having the same name as the
scenario except where the test domain must be the root zone, a TLD or a domain
under .arpa
. The names of those zones are given in section
"Zone setup for test scenarios" below.
Test scenarios and message tags
If a message tag is not listed for the scenario, its presence or non-presence is irrelevant to the test scenario and must be ignored.
Scenario name | Mandatory message tags | Forbidden message tags |
---|---|---|
NO-DNSSEC-SUPPORT | DS03_NO_DNSSEC_SUPPORT | DS03_ERR_MULT_NSEC3, DS03_ILLEGAL_HASH_ALGO, DS03_ILLEGAL_ITERATION_VALUE, DS03_ILLEGAL_SALT_LENGTH, DS03_INCONSISTENT_HASH_ALGO, DS03_INCONSISTENT_ITERATION, DS03_INCONSISTENT_NSEC3_FLAGS, DS03_INCONSISTENT_SALT_LENGTH, DS03_LEGAL_EMPTY_SALT, DS03_LEGAL_HASH_ALGO, DS03_LEGAL_ITERATION_VALUE, DS03_NO_NSEC3, DS03_NSEC3_OPT_OUT_DISABLED, DS03_NSEC3_OPT_OUT_ENABLED_NON_TLD, DS03_NSEC3_OPT_OUT_ENABLED_TLD, DS03_SERVER_NO_DNSSEC_SUPPORT, DS03_SERVER_NO_NSEC3, DS03_UNASSIGNED_FLAG_USED, DS03_ERROR_RESPONSE_NSEC_QUERY, DS03_NO_RESPONSE_NSEC_QUERY |
NO-NSEC3 | DS03_NO_NSEC3 | DS03_ERR_MULT_NSEC3, DS03_ILLEGAL_HASH_ALGO, DS03_ILLEGAL_ITERATION_VALUE, DS03_ILLEGAL_SALT_LENGTH, DS03_INCONSISTENT_HASH_ALGO, DS03_INCONSISTENT_ITERATION, DS03_INCONSISTENT_NSEC3_FLAGS, DS03_INCONSISTENT_SALT_LENGTH, DS03_LEGAL_EMPTY_SALT, DS03_LEGAL_HASH_ALGO, DS03_LEGAL_ITERATION_VALUE, DS03_NO_DNSSEC_SUPPORT, DS03_NSEC3_OPT_OUT_DISABLED, DS03_NSEC3_OPT_OUT_ENABLED_NON_TLD, DS03_NSEC3_OPT_OUT_ENABLED_TLD, DS03_SERVER_NO_DNSSEC_SUPPORT, DS03_SERVER_NO_NSEC3, DS03_UNASSIGNED_FLAG_USED, DS03_ERROR_RESPONSE_NSEC_QUERY, DS03_NO_RESPONSE_NSEC_QUERY |
GOOD-VALUES | DS03_LEGAL_EMPTY_SALT, DS03_LEGAL_HASH_ALGO, DS03_LEGAL_ITERATION_VALUE, DS03_NSEC3_OPT_OUT_DISABLED | DS03_ERR_MULT_NSEC3, DS03_ILLEGAL_HASH_ALGO, DS03_ILLEGAL_ITERATION_VALUE, DS03_ILLEGAL_SALT_LENGTH, DS03_INCONSISTENT_HASH_ALGO, DS03_INCONSISTENT_ITERATION, DS03_INCONSISTENT_NSEC3_FLAGS, DS03_INCONSISTENT_SALT_LENGTH, DS03_NO_DNSSEC_SUPPORT, DS03_NO_NSEC3, DS03_NSEC3_OPT_OUT_ENABLED_NON_TLD, DS03_NSEC3_OPT_OUT_ENABLED_TLD, DS03_SERVER_NO_DNSSEC_SUPPORT, DS03_SERVER_NO_NSEC3, DS03_UNASSIGNED_FLAG_USED, DS03_ERROR_RESPONSE_NSEC_QUERY, DS03_NO_RESPONSE_NSEC_QUERY |
ERR-MULT-NSEC3 | DS03_ERR_MULT_NSEC3, DS03_LEGAL_EMPTY_SALT, DS03_LEGAL_HASH_ALGO, DS03_LEGAL_ITERATION_VALUE, DS03_NSEC3_OPT_OUT_DISABLED | DS03_ILLEGAL_HASH_ALGO, DS03_ILLEGAL_ITERATION_VALUE, DS03_ILLEGAL_SALT_LENGTH, DS03_INCONSISTENT_HASH_ALGO, DS03_INCONSISTENT_ITERATION, DS03_INCONSISTENT_NSEC3_FLAGS, DS03_INCONSISTENT_SALT_LENGTH, DS03_NO_DNSSEC_SUPPORT, DS03_NO_NSEC3, DS03_NSEC3_OPT_OUT_ENABLED_NON_TLD, DS03_NSEC3_OPT_OUT_ENABLED_TLD, DS03_SERVER_NO_DNSSEC_SUPPORT, DS03_SERVER_NO_NSEC3, DS03_UNASSIGNED_FLAG_USED, DS03_ERROR_RESPONSE_NSEC_QUERY, DS03_NO_RESPONSE_NSEC_QUERY |
BAD-VALUES | DS03_ILLEGAL_HASH_ALGO, DS03_ILLEGAL_ITERATION_VALUE, DS03_ILLEGAL_SALT_LENGTH, DS03_NSEC3_OPT_OUT_ENABLED_NON_TLD | DS03_ERR_MULT_NSEC3, DS03_INCONSISTENT_HASH_ALGO, DS03_INCONSISTENT_ITERATION, DS03_INCONSISTENT_NSEC3_FLAGS, DS03_INCONSISTENT_SALT_LENGTH, DS03_LEGAL_EMPTY_SALT, DS03_LEGAL_HASH_ALGO, DS03_LEGAL_ITERATION_VALUE, DS03_NO_DNSSEC_SUPPORT, DS03_NO_NSEC3, DS03_NSEC3_OPT_OUT_DISABLED, DS03_NSEC3_OPT_OUT_ENABLED_TLD, DS03_SERVER_NO_DNSSEC_SUPPORT, DS03_SERVER_NO_NSEC3, DS03_UNASSIGNED_FLAG_USED, DS03_ERROR_RESPONSE_NSEC_QUERY, DS03_NO_RESPONSE_NSEC_QUERY |
INCONSISTENT-VALUES | DS03_ILLEGAL_HASH_ALGO, DS03_ILLEGAL_ITERATION_VALUE, DS03_ILLEGAL_SALT_LENGTH, DS03_INCONSISTENT_HASH_ALGO, DS03_INCONSISTENT_ITERATION, DS03_INCONSISTENT_NSEC3_FLAGS, DS03_INCONSISTENT_SALT_LENGTH, DS03_LEGAL_EMPTY_SALT, DS03_LEGAL_HASH_ALGO, DS03_LEGAL_ITERATION_VALUE, DS03_NSEC3_OPT_OUT_DISABLED, DS03_NSEC3_OPT_OUT_ENABLED_NON_TLD | DS03_ERR_MULT_NSEC3, DS03_NO_DNSSEC_SUPPORT, DS03_NO_NSEC3, DS03_NSEC3_OPT_OUT_ENABLED_TLD, DS03_SERVER_NO_DNSSEC_SUPPORT, DS03_SERVER_NO_NSEC3, DS03_UNASSIGNED_FLAG_USED, DS03_ERROR_RESPONSE_NSEC_QUERY, DS03_NO_RESPONSE_NSEC_QUERY |
NSEC3-OPT-OUT-ENABLED-TLD | DS03_NSEC3_OPT_OUT_ENABLED_TLD, DS03_LEGAL_EMPTY_SALT, DS03_LEGAL_HASH_ALGO, DS03_LEGAL_ITERATION_VALUE | DS03_ERR_MULT_NSEC3, DS03_ILLEGAL_HASH_ALGO, DS03_ILLEGAL_ITERATION_VALUE, DS03_ILLEGAL_SALT_LENGTH, DS03_INCONSISTENT_HASH_ALGO, DS03_INCONSISTENT_ITERATION, DS03_INCONSISTENT_NSEC3_FLAGS, DS03_INCONSISTENT_SALT_LENGTH, DS03_NO_DNSSEC_SUPPORT, DS03_NO_NSEC3, DS03_NSEC3_OPT_OUT_DISABLED, DS03_NSEC3_OPT_OUT_ENABLED_NON_TLD, DS03_SERVER_NO_DNSSEC_SUPPORT, DS03_SERVER_NO_NSEC3, DS03_UNASSIGNED_FLAG_USED, DS03_ERROR_RESPONSE_NSEC_QUERY, DS03_NO_RESPONSE_NSEC_QUERY |
SERVER-NO-DNSSEC-SUPPORT | DS03_SERVER_NO_DNSSEC_SUPPORT, DS03_LEGAL_EMPTY_SALT, DS03_LEGAL_HASH_ALGO, DS03_LEGAL_ITERATION_VALUE, DS03_NSEC3_OPT_OUT_DISABLED | DS03_ERR_MULT_NSEC3, DS03_ILLEGAL_HASH_ALGO, DS03_ILLEGAL_ITERATION_VALUE, DS03_ILLEGAL_SALT_LENGTH, DS03_INCONSISTENT_HASH_ALGO, DS03_INCONSISTENT_ITERATION, DS03_INCONSISTENT_NSEC3_FLAGS, DS03_INCONSISTENT_SALT_LENGTH, DS03_NO_DNSSEC_SUPPORT, DS03_NO_NSEC3, DS03_NSEC3_OPT_OUT_ENABLED_NON_TLD, DS03_NSEC3_OPT_OUT_ENABLED_TLD, DS03_SERVER_NO_NSEC3, DS03_UNASSIGNED_FLAG_USED, DS03_ERROR_RESPONSE_NSEC_QUERY, DS03_NO_RESPONSE_NSEC_QUERY |
SERVER-NO-NSEC3 | DS03_SERVER_NO_NSEC3, DS03_LEGAL_EMPTY_SALT, DS03_LEGAL_HASH_ALGO, DS03_LEGAL_ITERATION_VALUE, DS03_NSEC3_OPT_OUT_DISABLED | DS03_ERR_MULT_NSEC3, DS03_ILLEGAL_HASH_ALGO, DS03_ILLEGAL_ITERATION_VALUE, DS03_ILLEGAL_SALT_LENGTH, DS03_INCONSISTENT_HASH_ALGO, DS03_INCONSISTENT_ITERATION, DS03_INCONSISTENT_NSEC3_FLAGS, DS03_INCONSISTENT_SALT_LENGTH, DS03_NO_DNSSEC_SUPPORT, DS03_NO_NSEC3, DS03_NSEC3_OPT_OUT_ENABLED_NON_TLD, DS03_NSEC3_OPT_OUT_ENABLED_TLD, DS03_SERVER_NO_DNSSEC_SUPPORT, DS03_UNASSIGNED_FLAG_USED, DS03_ERROR_RESPONSE_NSEC_QUERY, DS03_NO_RESPONSE_NSEC_QUERY |
UNASSIGNED-FLAG-USED | DS03_UNASSIGNED_FLAG_USED, DS03_LEGAL_EMPTY_SALT, DS03_LEGAL_HASH_ALGO, DS03_LEGAL_ITERATION_VALUE, DS03_NSEC3_OPT_OUT_DISABLED | DS03_ERR_MULT_NSEC3, DS03_ILLEGAL_HASH_ALGO, DS03_ILLEGAL_ITERATION_VALUE, DS03_ILLEGAL_SALT_LENGTH, DS03_INCONSISTENT_HASH_ALGO, DS03_INCONSISTENT_ITERATION, DS03_INCONSISTENT_NSEC3_FLAGS, DS03_INCONSISTENT_SALT_LENGTH, DS03_NO_DNSSEC_SUPPORT, DS03_NO_NSEC3, DS03_NSEC3_OPT_OUT_ENABLED_NON_TLD, DS03_NSEC3_OPT_OUT_ENABLED_TLD, DS03_SERVER_NO_DNSSEC_SUPPORT, DS03_SERVER_NO_NSEC3, DS03_ERROR_RESPONSE_NSEC_QUERY, DS03_NO_RESPONSE_NSEC_QUERY |
ERROR-RESPONSE-NSEC-QUERY | DS03_LEGAL_EMPTY_SALT, DS03_LEGAL_HASH_ALGO, DS03_LEGAL_ITERATION_VALUE, DS03_NSEC3_OPT_OUT_DISABLED, DS03_ERROR_RESPONSE_NSEC_QUERY | DS03_ERR_MULT_NSEC3, DS03_ILLEGAL_HASH_ALGO, DS03_ILLEGAL_ITERATION_VALUE, DS03_ILLEGAL_SALT_LENGTH, DS03_INCONSISTENT_HASH_ALGO, DS03_INCONSISTENT_ITERATION, DS03_INCONSISTENT_NSEC3_FLAGS, DS03_INCONSISTENT_SALT_LENGTH, DS03_NO_DNSSEC_SUPPORT, DS03_NO_NSEC3, DS03_NSEC3_OPT_OUT_ENABLED_NON_TLD, DS03_NSEC3_OPT_OUT_ENABLED_TLD, DS03_SERVER_NO_DNSSEC_SUPPORT, DS03_SERVER_NO_NSEC3, DS03_UNASSIGNED_FLAG_USED, DS03_NO_RESPONSE_NSEC_QUERY |
NO-RESPONSE-NSEC-QUERY | DS03_LEGAL_EMPTY_SALT, DS03_LEGAL_HASH_ALGO, DS03_LEGAL_ITERATION_VALUE, DS03_NSEC3_OPT_OUT_DISABLED, DS03_NO_RESPONSE_NSEC_QUERY | DS03_ERR_MULT_NSEC3, DS03_ILLEGAL_HASH_ALGO, DS03_ILLEGAL_ITERATION_VALUE, DS03_ILLEGAL_SALT_LENGTH, DS03_INCONSISTENT_HASH_ALGO, DS03_INCONSISTENT_ITERATION, DS03_INCONSISTENT_NSEC3_FLAGS, DS03_INCONSISTENT_SALT_LENGTH, DS03_NO_DNSSEC_SUPPORT, DS03_NO_NSEC3, DS03_NSEC3_OPT_OUT_ENABLED_NON_TLD, DS03_NSEC3_OPT_OUT_ENABLED_TLD, DS03_SERVER_NO_DNSSEC_SUPPORT, DS03_SERVER_NO_NSEC3, DS03_UNASSIGNED_FLAG_USED, DS03_ERROR_RESPONSE_NSEC_QUERY |
ERROR-NSEC-QUERY | DS03_ERROR_RESPONSE_NSEC_QUERY, DS03_NO_RESPONSE_NSEC_QUERY | DS03_ERR_MULT_NSEC3, DS03_ILLEGAL_HASH_ALGO, DS03_ILLEGAL_ITERATION_VALUE, DS03_ILLEGAL_SALT_LENGTH, DS03_INCONSISTENT_HASH_ALGO, DS03_INCONSISTENT_ITERATION, DS03_INCONSISTENT_NSEC3_FLAGS, DS03_INCONSISTENT_SALT_LENGTH, DS03_LEGAL_EMPTY_SALT, DS03_LEGAL_HASH_ALGO, DS03_LEGAL_ITERATION_VALUE, DS03_NO_DNSSEC_SUPPORT, DS03_NO_NSEC3, DS03_NSEC3_OPT_OUT_DISABLED, DS03_NSEC3_OPT_OUT_ENABLED_NON_TLD, DS03_NSEC3_OPT_OUT_ENABLED_TLD, DS03_SERVER_NO_DNSSEC_SUPPORT, DS03_SERVER_NO_NSEC3, DS03_UNASSIGNED_FLAG_USED |
Zone setup for test scenarios
Assumptions for the scenario specifications, unless stated otherwise for the specific scenario:
- Each zone is hosted by two NS, ns1 and ns2.
- Both ns have equal hosting.
- NS in delegation is equal to NS in zone.
- All responses are authoritative.
- RRSIG in responses are disregarded.
- The actual owner name of the NSEC3 record will not be verified.
- The record type list of the NSEC3 record will not be verified.
- The zone is to respond with one SOA record with the zone name as owner name on SOA query.
- The zone is to respond with one DNSKEY record with the zone name as owner name on DNSKEY query.
- The zone is to respond with one NSEC3 record with a hash owner name in authority section on NSEC query (note, NSEC not NSEC3). NODATA response.
- The NSEC3 record is to have the following settings:
- Hash algo = 1
- Flags = 0
- Iteration = 0
- Salt = "-" (no salt)
NO-DNSSEC-SUPPORT
No DNSSEC support in the zone.
- Zone: "no-dnssec-support.dnssec03.xa."
- No DNSKEY in query for DNSKEY (9).
NO-NSEC3
No NSEC3 support in the zone.
- Zone: "no-nsec3.dnssec03.xa."
- No NSEC3 in query for NSEC (10).
GOOD-VALUES
Happy path
- Zone: "good-values.dnssec03.xa."
ERR-MULT-NSEC3
Strange response with two NSEC3 records.
- Zone: "err-mult-nsec3.dnssec03.xa."
- Two NSEC3 records, with different hash owner name are to be included in the response. RDATA can be identical. (10)
BAD-VALUES
The NSEC3 record has values no permitted by RFC 9276, see the specification of test case DNSSEC03.
- Zone: "bad-values.dnssec03.xa."
- The following values in NSEC3 (11):
- Hash algo = 2
- Flags = 1
- Iteration = 1
- Salt = "8104"
- The following values in NSEC3 (11):
INCONSISTENT-VALUES
The NSEC3 records returned from the two NS are not equal.
- Zone: "inconsistent-values.dnssec03.xa."
- Both NS give the same owner name of the NSEC3 record, but
ns1 gives standard values, whereas ns2 responds with an NSEC3 record with
the following values: (2, 11)
- Hash algo = 2
- Flags = 1
- Iteration = 1
- Salt = "8104"
- Both NS give the same owner name of the NSEC3 record, but
ns1 gives standard values, whereas ns2 responds with an NSEC3 record with
the following values: (2, 11)
NSEC3-OPT-OUT-ENABLED-TLD
On a TLD, opt-out just gives an INFO message.
- Zone: "nsec3-opt-out-enabled-tld-dnssec03." (TLD)
- NSEC3 record with the following value: (11)
- Flags = 1
- NSEC3 record with the following value: (11)
SERVER-NO-DNSSEC-SUPPORT
One NS of two does not support DNSSEC (no DNSKEY)
- Zone: "server-no-dnssec-support.dnssec03.xa"
- ns2 does not return any DNSKEY record on DNSKEY query (2, 9)
SERVER-NO-NSEC3
One NS of two does not have NSEC3
- Zone: "server-no-nsec3.dnssec03.xa"
- ns2 does not return any NSEC3 record on NSEC query (2, 10)
UNASSIGNED-FLAG-USED
Unassigned flag used.
- Zone: "unassigned-flag-used.dnssec03.xa"
- NSEC3 record with the following value: (11)
- Flags = 2
- NSEC3 record with the following value: (11)
ERROR-RESPONSE-NSEC-QUERY
Error in response from one NS on NSEC query.
- Zone: "error-response-nsec-query.dnssec03.xa"
- Normal response on DNSKEY query from ns1.
- RCODE name SERVFAIL on NSEC query from ns1.
- Normal responses from ns2.
NO-RESPONSE-NSEC-QUERY
No response from one NS on NSEC query.
- Zone: "no-response-nsec-query.dnssec03.xa"
- Normal responses from ns1.
- Normal response on DNSKEY query from ns2.
- No response on NSEC query from ns2.
ERROR-NSEC-QUERY
No response and error in response on NSEC query, respectively, from two NS.
- Zone: "error-nsec-query.dnssec03.xa"
- Normal response on DNSKEY query from ns1 and ns2.
- RCODE name SERVFAIL on NSEC query from ns1.
- No response on NSEC query from ns2.
Specification of Test Scenarios for DNSSEC10
Table of contents
- Background
- Test Case
- Test scenarios
- Test zone names
- All message tags
- Test scenarios and message tags
- Test scenarios and setup of test zones
Background
See the test scenario README file.
Test Case
This document specifies defined test scenarios for test case DNSSEC10.
Test scenarios
The purpose of the test scenarios is to cover all reasonable contexts where different message tags are outputted when DNSSEC10 is run on a test zone. The message tags are defined in the test case (DNSSEC10) and the scenarios are defined below.
The test scenarios are structured as stated in the test scenario README file.
Test zone names
The test zone or zones for each test scenario in this document is a subdomain
(or lower zone) delegated from the base name (dnssec10.xa
) and that subdomain
having the same name as the scenario. The names of those zones are given in
section "Test scenarios and setup of test zones" below.
All message tags
The test case can output any of these message tags, but not necessarily in any combination. See DNSSEC10 for the specification of the tags.
- DS10_ALGO_NOT_SUPPORTED_BY_ZM
- DS10_ERR_MULT_NSEC
- DS10_ERR_MULT_NSEC3
- DS10_ERR_MULT_NSEC3PARAM
- DS10_EXPECTED_NSEC_NSEC3_MISSING
- DS10_HAS_NSEC
- DS10_HAS_NSEC3
- DS10_INCONSISTENT_NSEC
- DS10_INCONSISTENT_NSEC3
- DS10_INCONSISTENT_NSEC_NSEC3
- DS10_MIXED_NSEC_NSEC3
- DS10_NSEC3PARAM_GIVES_ERR_ANSWER
- DS10_NSEC3PARAM_MISMATCHES_APEX
- DS10_NSEC3PARAM_QUERY_RESPONSE_ERR
- DS10_NSEC3_ERR_TYPE_LIST
- DS10_NSEC3_MISMATCHES_APEX
- DS10_NSEC3_MISSING_SIGNATURE
- DS10_NSEC3_NODATA_MISSING_SOA
- DS10_NSEC3_NODATA_WRONG_SOA
- DS10_NSEC3_NO_VERIFIED_SIGNATURE
- DS10_NSEC3_RRSIG_EXPIRED
- DS10_NSEC3_RRSIG_NOT_YET_VALID
- DS10_NSEC3_RRSIG_NO_DNSKEY
- DS10_NSEC3_RRSIG_VERIFY_ERROR
- DS10_NSEC_ERR_TYPE_LIST
- DS10_NSEC_GIVES_ERR_ANSWER
- DS10_NSEC_MISMATCHES_APEX
- DS10_NSEC_MISSING_SIGNATURE
- DS10_NSEC_NODATA_MISSING_SOA
- DS10_NSEC_NODATA_WRONG_SOA
- DS10_NSEC_NO_VERIFIED_SIGNATURE
- DS10_NSEC_QUERY_RESPONSE_ERR
- DS10_NSEC_RRSIG_EXPIRED
- DS10_NSEC_RRSIG_NOT_YET_VALID
- DS10_NSEC_RRSIG_NO_DNSKEY
- DS10_NSEC_RRSIG_VERIFY_ERROR
- DS10_SERVER_NO_DNSSEC
- DS10_ZONE_NO_DNSSEC
Test scenarios and message tags
If a message tag is not listed for the scenario, its presence or non-presence is irrelevant to the test scenario and must be ignored.
Scenario name | Mandatory message tag | Forbidden message tags |
---|---|---|
GOOD-NSEC-1 | DS10_HAS_NSEC | 2) |
GOOD-NSEC3-1 | DS10_HAS_NSEC3 | 2) |
ALGO-NOT-SUPP-BY-ZM-1 | DS10_ALGO_NOT_SUPPORTED_BY_ZM, DS10_HAS_NSEC | 2) |
ALGO-NOT-SUPP-BY-ZM-2 | DS10_ALGO_NOT_SUPPORTED_BY_ZM, DS10_HAS_NSEC3 | 2) |
ERR-MULT-NSEC-1 | DS10_ERR_MULT_NSEC, DS10_HAS_NSEC | 2) |
ERR-MULT-NSEC-2 | DS10_ERR_MULT_NSEC, DS10_HAS_NSEC | 2) |
ERR-MULT-NSEC3-1 | DS10_ERR_MULT_NSEC3, DS10_HAS_NSEC3 | 2) |
ERR-MULT-NSEC3PARAM-1 | DS10_ERR_MULT_NSEC3PARAM, DS10_HAS_NSEC3 | 2) |
EXP-NSEC-NSEC3-MISS-1 | DS10_EXPECTED_NSEC_NSEC3_MISSING | 2) |
INCONSISTENT-NSEC-1 | DS10_INCONSISTENT_NSEC, DS10_HAS_NSEC | 2) |
INCONSISTENT-NSEC3-1 | DS10_INCONSISTENT_NSEC3, DS10_HAS_NSEC3 | 2) |
INCONSIST-NSEC-NSEC3-1 | DS10_INCONSISTENT_NSEC_NSEC3 | 2) |
INCONSIST-NSEC-NSEC3-2 | DS10_INCONSISTENT_NSEC_NSEC3, DS10_INCONSISTENT_NSEC, DS10_INCONSISTENT_NSEC3 | 2) |
MIXED-NSEC-NSEC3-1 | DS10_MIXED_NSEC_NSEC3 | 2) |
MIXED-NSEC-NSEC3-2 | DS10_MIXED_NSEC_NSEC3 | 2) |
NSEC3PARAM-GIVES-ERR-ANSWER-1 | DS10_NSEC3PARAM_GIVES_ERR_ANSWER, DS10_HAS_NSEC3, DS10_INCONSISTENT_NSEC3 | 2) |
NSEC3PARAM-GIVES-ERR-ANSWER-2 | DS10_NSEC3PARAM_GIVES_ERR_ANSWER, DS10_EXPECTED_NSEC_NSEC3_MISSING, DS10_INCONSISTENT_NSEC3, DS10_HAS_NSEC3 | 2) |
NSEC3PARAM-MISMATCHES-APEX-1 | DS10_NSEC3PARAM_MISMATCHES_APEX, DS10_HAS_NSEC3 | 2) |
NSEC3PARAM-Q-RESPONSE-ERR-1 | DS10_NSEC3PARAM_QUERY_RESPONSE_ERR, DS10_HAS_NSEC3, DS10_INCONSISTENT_NSEC3 | 2) |
NSEC3PARAM-Q-RESPONSE-ERR-2 | DS10_NSEC3PARAM_QUERY_RESPONSE_ERR, DS10_HAS_NSEC3, DS10_INCONSISTENT_NSEC3 | 2) |
NSEC3PARAM-Q-RESPONSE-ERR-3 | DS10_NSEC3PARAM_QUERY_RESPONSE_ERR, DS10_EXPECTED_NSEC_NSEC3_MISSING, DS10_INCONSISTENT_NSEC3 | 2) |
NSEC3-ERR-TYPE-LIST-1 | DS10_NSEC3_ERR_TYPE_LIST, DS10_HAS_NSEC3 | 2) |
NSEC3-ERR-TYPE-LIST-2 | DS10_NSEC3_ERR_TYPE_LIST, DS10_HAS_NSEC3 | 2) |
NSEC3-MISMATCHES-APEX-1 | DS10_NSEC3_MISMATCHES_APEX, DS10_HAS_NSEC3 | 2) |
NSEC3-MISSING-SIGNATURE-1 | DS10_NSEC3_MISSING_SIGNATURE, DS10_HAS_NSEC3 | 2) |
NSEC3-NODATA-MISSING-SOA-1 | DS10_NSEC3_NODATA_MISSING_SOA, DS10_HAS_NSEC3 | 2) |
NSEC3-NODATA-WRONG-SOA-1 | DS10_NSEC3_NODATA_WRONG_SOA, DS10_HAS_NSEC3 | 2) |
NSEC3-NO-VERIFIED-SIGNATURE-1 | DS10_NSEC3_NO_VERIFIED_SIGNATURE, DS10_HAS_NSEC3, DS10_NSEC3_RRSIG_NO_DNSKEY | 2) |
NSEC3-NO-VERIFIED-SIGNATURE-2 | DS10_NSEC3_NO_VERIFIED_SIGNATURE, DS10_HAS_NSEC3, DS10_NSEC3_RRSIG_EXPIRED | 2) |
NSEC3-NO-VERIFIED-SIGNATURE-3 | DS10_NSEC3_NO_VERIFIED_SIGNATURE, DS10_HAS_NSEC3, DS10_NSEC3_RRSIG_NOT_YET_VALID | 2) |
NSEC3-NO-VERIFIED-SIGNATURE-4 | DS10_NSEC3_NO_VERIFIED_SIGNATURE, DS10_HAS_NSEC3, DS10_NSEC3_RRSIG_VERIFY_ERROR | 2) |
NSEC-ERR-TYPE-LIST-1 | DS10_NSEC_ERR_TYPE_LIST, DS10_HAS_NSEC | 2) |
NSEC-ERR-TYPE-LIST-2 | DS10_NSEC_ERR_TYPE_LIST, DS10_HAS_NSEC | 2) |
NSEC-GIVES-ERR-ANSWER-1 | DS10_NSEC_GIVES_ERR_ANSWER, DS10_HAS_NSEC, DS10_INCONSISTENT_NSEC | 2) |
NSEC-GIVES-ERR-ANSWER-2 | DS10_NSEC_GIVES_ERR_ANSWER, DS10_EXPECTED_NSEC_NSEC3_MISSING, DS10_INCONSISTENT_NSEC, DS10_HAS_NSEC | 2) |
NSEC-MISMATCHES-APEX-1 | DS10_NSEC_MISMATCHES_APEX, DS10_HAS_NSEC | 2) |
NSEC-MISMATCHES-APEX-2 | DS10_NSEC_MISMATCHES_APEX, DS10_HAS_NSEC | 2) |
NSEC-MISSING-SIGNATURE-1 | DS10_NSEC_MISSING_SIGNATURE, DS10_HAS_NSEC | 2) |
NSEC-NODATA-MISSING-SOA-1 | DS10_NSEC_NODATA_MISSING_SOA, DS10_HAS_NSEC | 2) |
NSEC-NODATA-WRONG-SOA-1 | DS10_NSEC_NODATA_WRONG_SOA, DS10_HAS_NSEC | 2) |
NSEC-NO-VERIFIED-SIGNATURE-1 | DS10_NSEC_NO_VERIFIED_SIGNATURE, DS10_HAS_NSEC, DS10_NSEC_RRSIG_NO_DNSKEY | 2) |
NSEC-NO-VERIFIED-SIGNATURE-2 | DS10_NSEC_NO_VERIFIED_SIGNATURE, DS10_HAS_NSEC, DS10_NSEC_RRSIG_EXPIRED | 2) |
NSEC-NO-VERIFIED-SIGNATURE-3 | DS10_NSEC_NO_VERIFIED_SIGNATURE, DS10_HAS_NSEC, DS10_NSEC_RRSIG_NOT_YET_VALID | 2) |
NSEC-NO-VERIFIED-SIGNATURE-4 | DS10_NSEC_NO_VERIFIED_SIGNATURE, DS10_HAS_NSEC, DS10_NSEC_RRSIG_VERIFY_ERROR | 2) |
NSEC-QUERY-RESPONSE-ERR-1 | DS10_NSEC_QUERY_RESPONSE_ERR, DS10_HAS_NSEC, DS10_INCONSISTENT_NSEC | 2) |
NSEC-QUERY-RESPONSE-ERR-2 | DS10_NSEC_QUERY_RESPONSE_ERR, DS10_HAS_NSEC, DS10_INCONSISTENT_NSEC | 2) |
NSEC-QUERY-RESPONSE-ERR-3 | DS10_NSEC_QUERY_RESPONSE_ERR, DS10_EXPECTED_NSEC_NSEC3_MISSING, DS10_INCONSISTENT_NSEC | 2) |
SERVER-NO-DNSSEC-1 | DS10_SERVER_NO_DNSSEC, DS10_HAS_NSEC | 2) |
SERVER-NO-DNSSEC-2 | DS10_SERVER_NO_DNSSEC, DS10_HAS_NSEC3 | 2) |
ZONE-NO-DNSSEC-1 | DS10_ZONE_NO_DNSSEC | 2) |
- (1) All tags except for those specified as "Forbidden message tags" (no instances for these test scenarios)
- (2) All tags except for those specified as "Mandatory message tags"
Test scenarios and setup of test zones
Default zone configuration
Unless otherwise specified in the specific scenario specification, the test zone
or zones for the scenario will follow the default setup as stated below. The
child zone
is the zone to be tested for the scenario.
- The child zone is
SCENARIO.dnssec10.xa
.- It is delegated to two name servers,
ns1.SCENARIO.dnssec10.xa
andns2.SCENARIO.dnssec10.xa
.- The name server names have A and AAAA records to avoid non-relevant error messages.
- The delegation of the child zone is complete with glue records.
- There is a zone file for the child zone.
- All child zone servers give the same response.
- The responses are either with NSEC record (NSEC zone) or NSEC3 record (NSEC3 zone), not mixed.
- It is delegated to two name servers,
- The parent zone is
dnssec10.xa
.- It is served by two in-bailiwick NS (ns1 and ns2).
- ns1 and ns2 have the same zone content.
- ns1 and ns2 have both IPv4 and IPv6 glue.
- The records matching glue in the zone are complete.
- If the child zone is an NSEC zone:
- Responds with an NSEC response on the NSEC3PARAM query.
- Responds with an NSEC record in answer section on the NSEC query.
- If the child zone is an NSEC3 zone:
- Responds with an NSEC3 response on the NSEC query.
- Responds with an NSEC3PARAM record in answer section on the NSEC3PARAM query.
- All responses will have the AA bit set.
- All responses will have the RCODE Name "NoError".
GOOD-NSEC-1
An NSEC zone and a "happy path". Everything is fine.
- Zone: good-nsec-1.dnssec10.xa
GOOD-NSEC3-1
An NSEC3 zone and a "happy path". Everything is fine.
- Zone: good-nsec3-1.dnssec10.xa
ALGO-NOT-SUPP-BY-ZM-1
An NSEC zone. Unknown algorithm of a DNSKEY.
- Zone: algo-not-supp-by-zm-1.dnssec10.xa
- There is an extra RRSIG for the NSEC record (as the response to the
NSEC3PARAM query).
- That RRSIG has been created by algorithm 255, which is an unsupported private algorithm.
- A matching DNSKEY (algorithm 255) is available.
- For this test scenario a fake signature and a fake public key are used.
- The extra DNSKEY is in the DNSKEY RRset which is resigned by the valid KSK.
- There is an extra RRSIG for the NSEC record (as the response to the
NSEC3PARAM query).
ALGO-NOT-SUPP-BY-ZM-2
An NSEC3 zone. Unknown algorithm of a DNSKEY.
- Zone: algo-not-supp-by-zm-2.dnssec10.xa
- There is an extra RRSIG for the NSEC3 record (as the response to the
NSEC query).
- That RRSIG has been created by algorithm 255, which is an unsupported private algorithm.
- A matching DNSKEY (algorithm 255) is available.
- For this test scenario a fake signature and a fake public key are used.
- The extra DNSKEY is in the DNSKEY RRset which is resigned by the valid KSK.
- There is an extra RRSIG for the NSEC3 record (as the response to the
NSEC query).
ERR-MULT-NSEC-1
An NSEC zone. An extra NSEC record is returned on the NSEC3PARAM query.
- Zone: err-mult-nsec-1.dnssec10.xa
- An extra NSEC record is returned in the response to the NSEC3PARAM query.
- The extra NSEC record has the same owner name, but different value in "Next Domain Name" field.
- RRSIG is recalculated.
- An extra NSEC record is returned in the response to the NSEC3PARAM query.
ERR-MULT-NSEC-2
An NSEC zone. An extra NSEC record is returned on the NSEC query.
- Zone: err-mult-nsec-2.dnssec10.xa
- An extra NSEC record is returned in the response to the NSEC query.
- The extra NSEC record has the same owner name, but different value in "Type List" field.
- RRSIG is recalculated.
- An extra NSEC record is returned in the response to the NSEC query.
ERR-MULT-NSEC3-1
An NSEC3 zone. An extra NSEC3 record is returned.
- Zone: err-mult-nsec3-1.dnssec10.xa
- An extra NSEC3 record is returned in the response to the NSEC query.
- The extra NSEC3 record has the same hash owner name, but different value in "Next Hashed Owner Name" field.
- The NSEC3 RRset has been signed with a valid RRSIG.
- An extra NSEC3 record is returned in the response to the NSEC query.
ERR-MULT-NSEC3PARAM-1
An NSEC3 zone. An extra NSEC3PARAM record is returned.
- Zone: err-mult-nsec3param-1.dnssec10.xa
- An extra NSEC3PARAM record is returned in the response to the NSEC query.
- The extra NSEC3PARAM record has the same owner name, but different number of iterations.
- The NSEC3PARAM RRset has been signed with a valid RRSIG.
- An extra NSEC3PARAM record is returned in the response to the NSEC query.
EXP-NSEC-NSEC3-MISS-1
A zone without NSEC and NSEC3. There is no NSEC or NSEC3 function.
- Zone: exp-nsec-nsec3-miss-1.dnssec10.xa
- The NSEC query gives a NODATA response with no NSEC or NSEC3 record.
- The NSEC3PARAM query gives a NODATA response with no NSEC or NSEC3 record.
INCONSISTENT-NSEC-1
An NSEC zone. Some errors in NSEC handling.
- Zone: inconsistent-nsec-1.dnssec10.xa
- ns1 includes no NSEC record in the NODATA response on the NSEC3PARAM query.
- ns2 includes no NSEC record in the NODATA response on the NSEC query.
INCONSISTENT-NSEC3-1
An NSEC3 zone. Some errors in NSEC3 handling.
- Zone: inconsistent-nsec3-1.dnssec10.xa
- ns1 includes no NSEC3 record in the NODATA response on the NSEC query.
- ns2 includes no NSEC3PARAM or NSEC3 record in the NODATA response on the NSEC3PARAM query.
INCONSIST-NSEC-NSEC3-1
Mixing beteen NSEC and NSEC3.
- Zone: inconsist-nsec-nsec3-1.dnssec10.xa
- ns1 holds an NSEC version of the zone.
- ns2 holds an NSEC3 version of the zone.
INCONSIST-NSEC-NSEC3-2
NSEC on one server and NSEC3 on the other plus errors in NSEC and NSEC3 handling.
- Zone: inconsist-nsec-nsec3-2.dnssec10.xa
- ns1 holds an NSEC version of the zone.
- It responds with a NODATA respond without NSEC record on the NSEC3PARAM query.
- It does respond with an NSEC record to the NSEC query.
- ns2 holds an NSEC3 version of the zone.
- It responds with a NODATA respond without NSEC3 record on the NSEC query.
- It does respond with an NSEC3PARAM record to the NSEC3PARAM query.
- ns1 holds an NSEC version of the zone.
MIXED-NSEC-NSEC3-1
Servers gives both NSEC and NSEC3
- Zone: mixed-nsec-nsec3-1.dnssec10.xa
- The zone gives an NSEC record in response to NSEC query.
- The zone gives an NSEC3PARAM record in response to the NSEC3PARAM query.
MIXED-NSEC-NSEC3-2
Servers gives both NSEC and NSEC3
- Zone: mixed-nsec-nsec3-2.dnssec10.xa
- The zone gives a NODATA response with NSEC3 record in response to NSEC query.
- The zone gives a NODATA response with NSEC record in response to the NSEC3PARAM query.
NSEC3PARAM-GIVES-ERR-ANSWER-1
An NSEC3 zone. Error in response to NSEC3PARAM query.
- Zone: nsec3param-gives-err-answer-1.dnssec10.xa
- The zone gives a TXT record, but no NSEC3PARAM record, in response to the NSEC3PARAM query.
NSEC3PARAM-GIVES-ERR-ANSWER-2
An NSEC3 zone. Error in response to NSEC3PARAM query on ns1. No NSEC or NSEC3 on ns2.
- Zone: nsec3param-gives-err-answer-1.dnssec10.xa
- On ns1, the zone gives a TXT record, but no NSEC3PARAM record, in response to the NSEC3PARAM query.
- On ns2, the zone gives NODATA responses without NSEC or NSEC3 record for both the NSEC3PARAM query and the NSEC query.
NSEC3PARAM-MISMATCHES-APEX-1
An NSEC3 zone. The owner name of the NSEC3PARAM record is erroneous.
- Zone: nsec3param-mismatches-apex-1.dnssec10.xa
- The owner name of the NSEC3PARAM record in response to the NSEC3PARAM query is
erroneous and does not match apex.
- The owner name is
sub.nsec3param-mismatches-apex-1.dnssec10.xa
instead of expectednsec3param-mismatches-apex-1.dnssec10.xa
.
- The owner name is
- The owner name of the NSEC3PARAM record in response to the NSEC3PARAM query is
erroneous and does not match apex.
NSEC3PARAM-Q-RESPONSE-ERR-1
An NSEC3 zone. Error in response to NSEC3PARAM query.
- Zone: nsec3param-q-response-err-1.dnssec10.xa
- No DNS response on the NSEC3PARAM query.
NSEC3PARAM-Q-RESPONSE-ERR-2
An NSEC3 zone. Error in response to NSEC3PARAM query.
- Zone: nsec3param-q-response-err-2.dnssec10.xa
- The response on the NSEC3PARAM query has the RCODE Name "REFUSED".
NSEC3PARAM-Q-RESPONSE-ERR-3
An NSEC3 zone. Error in response to NSEC3PARAM query on ns1. No NSEC or NSEC3 on ns2.
- Zone: nsec3param-q-response-err-3.dnssec10.xa
- The response from ns1 on the NSEC3PARAM query has the AA flag unset.
- On ns2, the zone gives NODATA responses without NSEC or NSEC3 record for both the NSEC3PARAM query and the NSEC query.
NSEC3-ERR-TYPE-LIST-1
An NSEC3 zone. The type list of the NSEC3 record is erroneous.
- Zone: nsec3-err-type-list-1.dnssec10.xa
- The type list of the NSEC3 record includes NSEC.
NSEC3-ERR-TYPE-LIST-2
An NSEC3 zone. The type list of the NSEC3 record is erroneous.
- Zone: nsec3-err-type-list-2.dnssec10.xa
- The type list of the NSEC3 record misses RRSIG.
NSEC3-MISMATCHES-APEX-1
An NSEC3 zone. The hash owner name of the NSEC3 record is erroneous.
- Zone: nsec3-mismatches-apex-1.dnssec10.xa
- The hash owner name of the NSEC3 record in response to the NSEC query is erroneous and does not match apex.
NSEC3-MISSING-SIGNATURE-1
An NSEC3 zone. The RRSIG is missing
- Zone: nsec3-missing-signature-1.dnssec10.xa
- There is no RRSIG for the NSEC3 record in the response with NSEC3 record.
NSEC3-NODATA-MISSING-SOA-1
An NSEC3 zone. The SOA record is missing in the NODATA response.
- Zone: nsec3-nodata-missing-soa-1.dnssec10.xa
- In the NODATA response to the NSEC query the SOA record is missing.
NSEC3-NODATA-WRONG-SOA-1
An NSEC3 zone. In the NODATA response the SOA record has the wrong owner name.
- Zone: nsec3-nodata-wrong-soa-1.dnssec10.xa
- The owner name of the SOA record in the NODATA response to the NSEC query
is
sub.nsec3-nodata-wrong-soa-1.dnssec10.xa
instead of expectednsec3-nodata-wrong-soa-1.dnssec10.xa
.
- The owner name of the SOA record in the NODATA response to the NSEC query
is
NSEC3-NO-VERIFIED-SIGNATURE-1
An NSEC3 zone. The RRSIG for the NSEC3 record cannot be verified.
- Zone: nsec3-no-verified-signature-1.dnssec10.xa
- The RRSIG record for the NSEC3 record in the NODATA response to the NSEC
query cannot be verified.
- There is no matching DNSKEY for the RRSIG for the NSEC3 record.
- The RRSIG record for the NSEC3 record in the NODATA response to the NSEC
query cannot be verified.
NSEC3-NO-VERIFIED-SIGNATURE-2
An NSEC3 zone. The RRSIG for the NSEC3 record cannot be verified.
- Zone: nsec3-no-verified-signature-2.dnssec10.xa
- The RRSIG record for the NSEC3 record in the NODATA response to the NSEC
query cannot be verified.
- The RRSIG has expired, i.e. the current date-time is beyond the last valid date-time.
- The RRSIG record for the NSEC3 record in the NODATA response to the NSEC
query cannot be verified.
NSEC3-NO-VERIFIED-SIGNATURE-3
An NSEC3 zone. The RRSIG for the NSEC3 record cannot be verified.
- Zone: nsec3-no-verified-signature-3.dnssec10.xa
- The RRSIG record for the NSEC3 record in the NODATA response to the NSEC
query cannot be verified.
- The RRSIG it not yet valid, i.e. the current date-time is before the first valid date-time.
- The RRSIG record for the NSEC3 record in the NODATA response to the NSEC
query cannot be verified.
NSEC3-NO-VERIFIED-SIGNATURE-4
An NSEC3 zone. The RRSIG for the NSEC3 record cannot be verified.
- Zone: nsec3-no-verified-signature-4.dnssec10.xa
- The RRSIG record for the NSEC3 record in the NODATA response to the NSEC
query cannot be verified.
- The RRSIG signature does not match the NSEC record and appointed DNSKEY.
- The RRSIG record for the NSEC3 record in the NODATA response to the NSEC
query cannot be verified.
NSEC-ERR-TYPE-LIST-1
An NSEC zone. The type list of the NSEC record is erroneous.
- Zone: nsec-err-type-list-1.dnssec10.xa
- The type list of the NSEC record includes NSEC3PARAM.
NSEC-ERR-TYPE-LIST-2
An NSEC zone. The type list of the NSEC record is erroneous.
- Zone: nsec-err-type-list-2.dnssec10.xa
- The type list of the NSEC record misses RRSIG.
NSEC-GIVES-ERR-ANSWER-1
An NSEC zone. Error in response to NSEC query.
- Zone: nsec-gives-err-answer-1.dnssec10.xa
- The zone gives a TXT record, but no NSEC record, in response to the NSEC query.
NSEC-GIVES-ERR-ANSWER-2
An NSEC zone. Error in response to NSEC query on ns1. No NSEC or NSEC3 on ns2.
- Zone: nsec-gives-err-answer-2.dnssec10.xa
- On ns1, the zone gives a TXT record, but no NSEC record, in response to the NSEC query.
- On ns2, the zone gives NODATA responses without NSEC or NSEC3 record for both the NSEC3PARAM query and the NSEC query.
NSEC-MISMATCHES-APEX-1
An NSEC zone. The owner name of the NSEC record is errouneous.
- Zone: nsec-mismatches-apex-1.dnssec10.xa
- The owner name of the NSEC record in response to the NSEC3PARAM query is
errouneous and does not match apex.
- The owner name is
sub.nsec-mismatches-apex-1.dnssec10.xa
instead of expectednsec-mismatches-apex-1.dnssec10.xa
.
- The owner name is
- The owner name of the NSEC record in response to the NSEC3PARAM query is
errouneous and does not match apex.
NSEC-MISMATCHES-APEX-2
An NSEC zone. The owner name of the NSEC record is errouneous.
- Zone: nsec-mismatches-apex-2.dnssec10.xa
- The owner name of the NSEC record in response to the NSEC query is
errouneous and does not match apex.
- The owner name is
sub.nsec-mismatches-apex-2.dnssec10.xa
instead of expectednsec-mismatches-apex-2.dnssec10.xa
.
- The owner name is
- The owner name of the NSEC record in response to the NSEC query is
errouneous and does not match apex.
NSEC-MISSING-SIGNATURE-1
An NSEC zone. The RRSIG is missing.
- Zone: nsec-missing-signature-1.dnssec10.xa
- There is no RRSIG for the NSEC record in the response with NSEC record on the NSEC3PARAM query.
NSEC-NODATA-MISSING-SOA-1
An NSEC zone. The SOA record is missing in the NODATA response.
- Zone: nsec-nodata-missing-soa-1.dnssec10.xa
- In the NODATA response to the NSEC3PARAM query the SOA record is missing.
NSEC-NODATA-WRONG-SOA-1
An NSEC zone. In the NODATA response the SOA record has the wrong owner name.
- Zone: nsec-nodata-wrong-soa-1.dnssec10.xa
- The owner name of the SOA record in the NODATA response to the NSEC3PARAM
query is
sub.nsec-nodata-wrong-soa-1.dnssec10.xa
instead of expectednsec-nodata-wrong-soa-1.dnssec10.xa
.
- The owner name of the SOA record in the NODATA response to the NSEC3PARAM
query is
NSEC-NO-VERIFIED-SIGNATURE-1
An NSEC zone. The RRSIG for the NSEC record cannot be verified.
- Zone: nsec-no-verified-signature-1.dnssec10.xa
- The RRSIG record for the NSEC record in the NODATA response to the NSEC3PARAM
query cannot be verified.
- There is no matching DNSKEY for the RRSIG for that NSEC record.
- The RRSIG record for the NSEC record in the NODATA response to the NSEC3PARAM
query cannot be verified.
NSEC-NO-VERIFIED-SIGNATURE-2
An NSEC zone. The RRSIG for the NSEC record cannot be verified.
- Zone: nsec-no-verified-signature-2.dnssec10.xa
- The RRSIG record for the NSEC record in the NODATA response to the NSEC3PARAM
query cannot be verified.
- The RRSIG has expired, i.e. the current date-time is beyond the last valid date-time.
- The RRSIG record for the NSEC record in the NODATA response to the NSEC3PARAM
query cannot be verified.
NSEC-NO-VERIFIED-SIGNATURE-3
An NSEC zone. The RRSIG for the NSEC record cannot be verified.
- Zone: nsec-no-verified-signature-3.dnssec10.xa
- The RRSIG record for the NSEC record in the NODATA response to the NSEC3PARAM
query cannot be verified.
- The RRSIG it not yet valid, i.e. the current date-time is before the first valid date-time.
- The RRSIG record for the NSEC record in the NODATA response to the NSEC3PARAM
query cannot be verified.
NSEC-NO-VERIFIED-SIGNATURE-4
An NSEC zone. The RRSIG for the NSEC record cannot be verified.
- Zone: nsec-no-verified-signature-4.dnssec10.xa
- The RRSIG record for the NSEC record in the NODATA response to the NSEC3PARAM
query cannot be verified.
- The RRSIG signature does not match the RRSIG record and appointed DNSKEY.
- The RRSIG record for the NSEC record in the NODATA response to the NSEC3PARAM
query cannot be verified.
NSEC-QUERY-RESPONSE-ERR-1
An NSEC zone. Error in response to NSEC query.
- Zone: nsec-query-response-err-1.dnssec10.xa
- No DNS response on the NSEC query.
NSEC-QUERY-RESPONSE-ERR-2
An NSEC zone. Error in response to NSEC query.
- Zone: nsec-query-response-err-2.dnssec10.xa
- The response on the NSEC query has the RCODE Name "REFUSED".
NSEC-QUERY-RESPONSE-ERR-3
An NSEC zone. Error in response to NSEC query on ns1. No NSEC or NSEC3 in responses from ns2.
- Zone: nsec-query-response-err-3.dnssec10.xa
- The response from ns1 on the NSEC query has the AA flag unset.
- On ns2, the zone gives NODATA responses without NSEC or NSEC3 record for both the NSEC3PARAM query and the NSEC query.
SERVER-NO-DNSSEC-1
An NSEC zone. No DNSKEY in response from ns1. Normal response from ns2.
- Zone: server-no-dnssec-1.dnssec10.xa
- The answer section in response from ns1 on the DNSKEY query is empty. Unsigned NODATA response without NSEC or NSEC3.
- The NSEC and NSEC3PARAM queries are irrelevant, but they also give a Unsigned NODATA response without NSEC or NSEC3 on ns1.
SERVER-NO-DNSSEC-2
An NSEC3 zone. No DNSKEY in response from ns1. Normal response from ns2.
- Zone: server-no-dnssec-2.dnssec10.xa
- The answer section in response from ns1 on the DNSKEY query is empty. Unsigned NODATA response without NSEC or NSEC3.
- The NSEC and NSEC3PARAM queries are irrelevant, but they also give a Unsigned NODATA response without NSEC or NSEC3 on ns1.
ZONE-NO-DNSSEC-1
No DNSKEY in response.
- Zone: zone-no-dnssec-1.dnssec10.xa
- The answer section in response on the DNSKEY query is empty. Unsigned NODATA response without NSEC or NSEC3.
- The NSEC and NSEC3PARAM queries are irrelevant, but they also give a Unsigned NODATA response without NSEC or NSEC3.
Specification of test zones for DNSSEC16
Table of contents
- Background
- Test Case
- Test scenarios
- Test zone names
- Test scenarios and message tags
- Zone setup for test scenarios
- Terminology
Background
See the test zone README file.
Test Case
This document specifies defined test zones for test case DNSSEC16.
Test scenarios
The purpose of the test scenarios is to cover all reasonable contexts where different message tags are outputted when DNSSEC16 is run on a test zone. The message tags are defined in the test case (DNSSEC16) and the scenarios are defined below.
The test scenarios are structured as stated in the test zone README file.
Test zone names
The test zone for each test scenario in this document is a subdomain delegated
from the base name (dnssec16.xa
) and that subdomain having the same name as the
scenario except where the test domain must be the root zone, a TLD or a domain
under .arpa
. The names of those zones are given in section
"Zone setup for test scenarios" below.
Test scenarios and message tags
If a message tag is not listed for the scenario, its presence or non-presence is irrelevant to the test scenario and must be ignored.
Scenario name | Mandatory message tags | Forbidden message tags |
---|---|---|
CDS-INVALID-RRSIG | DS16_CDS_INVALID_RRSIG | DS16_CDS_MATCHES_NON_SEP_DNSKEY, DS16_CDS_MATCHES_NON_ZONE_DNSKEY, DS16_CDS_MATCHES_NO_DNSKEY, DS16_CDS_NOT_SIGNED_BY_CDS, DS16_CDS_SIGNED_BY_UNKNOWN_DNSKEY, DS16_CDS_UNSIGNED, DS16_CDS_WITHOUT_DNSKEY, DS16_DELETE_CDS, DS16_DNSKEY_NOT_SIGNED_BY_CDS, DS16_MIXED_DELETE_CDS |
CDS-MATCHES-NO-DNSKEY | DS16_CDS_MATCHES_NO_DNSKEY | DS16_CDS_INVALID_RRSIG, DS16_CDS_MATCHES_NON_SEP_DNSKEY, DS16_CDS_MATCHES_NON_ZONE_DNSKEY, DS16_CDS_NOT_SIGNED_BY_CDS, DS16_CDS_SIGNED_BY_UNKNOWN_DNSKEY, DS16_CDS_UNSIGNED, DS16_CDS_WITHOUT_DNSKEY, DS16_DELETE_CDS, DS16_DNSKEY_NOT_SIGNED_BY_CDS, DS16_MIXED_DELETE_CDS |
CDS-MATCHES-NON-SEP-DNSKEY | DS16_CDS_MATCHES_NON_SEP_DNSKEY | DS16_CDS_INVALID_RRSIG, DS16_CDS_MATCHES_NON_ZONE_DNSKEY, DS16_CDS_MATCHES_NO_DNSKEY, DS16_CDS_NOT_SIGNED_BY_CDS, DS16_CDS_SIGNED_BY_UNKNOWN_DNSKEY, DS16_CDS_UNSIGNED, DS16_CDS_WITHOUT_DNSKEY, DS16_DELETE_CDS, DS16_DNSKEY_NOT_SIGNED_BY_CDS, DS16_MIXED_DELETE_CDS |
CDS-MATCHES-NON-ZONE-DNSKEY | DS16_CDS_MATCHES_NON_ZONE_DNSKEY | DS16_CDS_INVALID_RRSIG, DS16_CDS_MATCHES_NON_SEP_DNSKEY, DS16_CDS_MATCHES_NO_DNSKEY, DS16_CDS_NOT_SIGNED_BY_CDS, DS16_CDS_SIGNED_BY_UNKNOWN_DNSKEY, DS16_CDS_UNSIGNED, DS16_CDS_WITHOUT_DNSKEY, DS16_DELETE_CDS, DS16_DNSKEY_NOT_SIGNED_BY_CDS, DS16_MIXED_DELETE_CDS |
CDS-NOT-SIGNED_BY_CDS | DS16_CDS_NOT_SIGNED_BY_CDS | DS16_CDS_INVALID_RRSIG, DS16_CDS_MATCHES_NON_SEP_DNSKEY, DS16_CDS_MATCHES_NON_ZONE_DNSKEY, DS16_CDS_MATCHES_NO_DNSKEY, DS16_CDS_SIGNED_BY_UNKNOWN_DNSKEY, DS16_CDS_UNSIGNED, DS16_CDS_WITHOUT_DNSKEY, DS16_DELETE_CDS, DS16_DNSKEY_NOT_SIGNED_BY_CDS, DS16_MIXED_DELETE_CDS |
CDS-SIGNED-BY-UNKNOWN-DNSKEY | DS16_CDS_SIGNED_BY_UNKNOWN_DNSKEY | DS16_CDS_INVALID_RRSIG, DS16_CDS_MATCHES_NON_SEP_DNSKEY, DS16_CDS_MATCHES_NON_ZONE_DNSKEY, DS16_CDS_MATCHES_NO_DNSKEY, DS16_CDS_NOT_SIGNED_BY_CDS, DS16_CDS_UNSIGNED, DS16_CDS_WITHOUT_DNSKEY, DS16_DELETE_CDS, DS16_DNSKEY_NOT_SIGNED_BY_CDS, DS16_MIXED_DELETE_CDS |
CDS-UNSIGNED | DS16_CDS_UNSIGNED, DS16_CDS_NOT_SIGNED_BY_CDS | DS16_CDS_INVALID_RRSIG, DS16_CDS_MATCHES_NON_SEP_DNSKEY, DS16_CDS_MATCHES_NON_ZONE_DNSKEY, DS16_CDS_MATCHES_NO_DNSKEY, DS16_CDS_SIGNED_BY_UNKNOWN_DNSKEY, DS16_CDS_WITHOUT_DNSKEY, DS16_DELETE_CDS, DS16_DNSKEY_NOT_SIGNED_BY_CDS, DS16_MIXED_DELETE_CDS |
CDS-WITHOUT-DNSKEY | DS16_CDS_WITHOUT_DNSKEY | DS16_CDS_INVALID_RRSIG, DS16_CDS_MATCHES_NON_SEP_DNSKEY, DS16_CDS_MATCHES_NON_ZONE_DNSKEY, DS16_CDS_MATCHES_NO_DNSKEY, DS16_CDS_NOT_SIGNED_BY_CDS, DS16_CDS_SIGNED_BY_UNKNOWN_DNSKEY, DS16_CDS_UNSIGNED, DS16_DELETE_CDS, DS16_DNSKEY_NOT_SIGNED_BY_CDS, DS16_MIXED_DELETE_CDS |
DELETE-CDS | DS16_DELETE_CDS | DS16_CDS_INVALID_RRSIG, DS16_CDS_MATCHES_NON_SEP_DNSKEY, DS16_CDS_MATCHES_NON_ZONE_DNSKEY, DS16_CDS_MATCHES_NO_DNSKEY, DS16_CDS_NOT_SIGNED_BY_CDS, DS16_CDS_SIGNED_BY_UNKNOWN_DNSKEY, DS16_CDS_UNSIGNED, DS16_CDS_WITHOUT_DNSKEY, DS16_DNSKEY_NOT_SIGNED_BY_CDS, DS16_MIXED_DELETE_CDS |
DNSKEY-NOT-SIGNED-BY-CDS | DS16_DNSKEY_NOT_SIGNED_BY_CDS | DS16_CDS_INVALID_RRSIG, DS16_CDS_MATCHES_NON_SEP_DNSKEY, DS16_CDS_MATCHES_NON_ZONE_DNSKEY, DS16_CDS_MATCHES_NO_DNSKEY, DS16_CDS_NOT_SIGNED_BY_CDS, DS16_CDS_SIGNED_BY_UNKNOWN_DNSKEY, DS16_CDS_UNSIGNED, DS16_CDS_WITHOUT_DNSKEY, DS16_DELETE_CDS, DS16_MIXED_DELETE_CDS |
MIXED-DELETE-CDS | DS16_MIXED_DELETE_CDS | DS16_CDS_INVALID_RRSIG, DS16_CDS_MATCHES_NON_SEP_DNSKEY, DS16_CDS_MATCHES_NON_ZONE_DNSKEY, DS16_CDS_MATCHES_NO_DNSKEY, DS16_CDS_NOT_SIGNED_BY_CDS, DS16_CDS_SIGNED_BY_UNKNOWN_DNSKEY, DS16_CDS_UNSIGNED, DS16_CDS_WITHOUT_DNSKEY, DS16_DELETE_CDS, DS16_DNSKEY_NOT_SIGNED_BY_CDS |
NO-CDS | (none) | DS16_CDS_INVALID_RRSIG, DS16_CDS_MATCHES_NON_SEP_DNSKEY, DS16_CDS_MATCHES_NON_ZONE_DNSKEY, DS16_CDS_MATCHES_NO_DNSKEY, DS16_CDS_NOT_SIGNED_BY_CDS, DS16_CDS_SIGNED_BY_UNKNOWN_DNSKEY, DS16_CDS_UNSIGNED, DS16_CDS_WITHOUT_DNSKEY, DS16_DELETE_CDS, DS16_DNSKEY_NOT_SIGNED_BY_CDS, DS16_MIXED_DELETE_CDS |
NOT-AA | (none) | DS16_CDS_INVALID_RRSIG, DS16_CDS_MATCHES_NON_SEP_DNSKEY, DS16_CDS_MATCHES_NON_ZONE_DNSKEY, DS16_CDS_MATCHES_NO_DNSKEY, DS16_CDS_NOT_SIGNED_BY_CDS, DS16_CDS_SIGNED_BY_UNKNOWN_DNSKEY, DS16_CDS_UNSIGNED, DS16_CDS_WITHOUT_DNSKEY, DS16_DELETE_CDS, DS16_DNSKEY_NOT_SIGNED_BY_CDS, DS16_MIXED_DELETE_CDS |
VALID-CDS | (none) | DS16_CDS_INVALID_RRSIG, DS16_CDS_MATCHES_NON_SEP_DNSKEY, DS16_CDS_MATCHES_NON_ZONE_DNSKEY, DS16_CDS_MATCHES_NO_DNSKEY, DS16_CDS_NOT_SIGNED_BY_CDS, DS16_CDS_SIGNED_BY_UNKNOWN_DNSKEY, DS16_CDS_UNSIGNED, DS16_CDS_WITHOUT_DNSKEY, DS16_DELETE_CDS, DS16_DNSKEY_NOT_SIGNED_BY_CDS, DS16_MIXED_DELETE_CDS |
Zone setup for test scenarios
Assumptions for the scenario specifications:
- Only CDS or DNSKEY records in apex are considered.
- Unless stated otherwise, all name servers respond authoritatively with RCODE Name "NoError" on all queries.
- Unless stated otherwise, all name servers respond authoritatively with (or without) CDS records on CDS queries and DNSKEY records on DNSKEY queries, respectively.
- Unless stated otherwise, all RRSIGs are present where expected and are valid.
- Each zone is served by two nameservers and both respond consistently.
- No DS record is published at parent zone (
dnssec16.xa
).
CDS-INVALID-RRSIG
- Zone: "cds-invalid-rrsig.dnssec16.xa."
- The zone has a Well Formed DNSKEY Record (key 1).
- The zone has one Well Formed CDS Record, that matches key 1, but the RRSIG of the CDS RRset has expired.
CDS-MATCHES-NO-DNSKEY
- Zone: "cds-matches-no-dnskey.dnssec16.xa."
- The zone has one Well Formed DNSKEY Record (key 1).
- The zone has one Well Formed CDS Record that matches key 1.
- The zone has a second Well Formed CDS Record that matches no key by key tag.
CDS-MATCHES-NON-SEP-DNSKEY
- Zone: "cds-matches-non-sep-dnskey.dnssec16.xa."
- The zone has a Well Formed DNSKEY Record, but flag bit 15 is unset (key 1).
- The zone has one Well Formed CDS Record that matches key 1.
CDS-MATCHES-NON-ZONE-DNSKEY
- Zone: "cds-matches-non-zone-dnskey.dnssec16.xa."
- The zone has one Well Formed DNSKEY Record (key 1).
- The zone has a second Well Formed DNSKEY Record, but flag bit 7 is unset and the key has not signed the DNSKEY RRset (key 2).
- The zone has one Well Formed CDS Record and matches key 1 (CDS 1).
- The zone has a second Well Formed CDS Record, matching key 2, but the key has not signed the CDS RRset.
CDS-NOT-SIGNED-BY-CDS
- Zone: "cds-not-signed-by-cds.dnssec16.xa."
- The zone has two Well Formed DNSKEY Record (key 1 and 2).
- The zone has one Well Formed CDS Record that matches key 1.
- The zone has a second Well Formed CDS Record that matches key 2, but its DNSKEY has not signed the CDS RRset.
CDS-SIGNED-BY-UNKNOWN-DNSKEY
- Zone: "cds-signed-by-unknown-dnskey.dnssec16.xa."
- The zone has a Well Formed DNSKEY Record (key 1).
- The zone has one Well Formed CDS Record, and it matches key 1.
- The CDS RRset has an additional RRSIG that matches no DNSKEY by key tag.
CDS-UNSIGNED
- Zone: "cds-unsigned.dnssec16.xa."
- The zone has a Well Formed DNSKEY Record (key 1).
- The zone has one Well Formed CDS Record, and it matches key 1, but the CDS RRset is not signed.
CDS-WITHOUT-DNSKEY
- Zone: "cds-without-dnskey.dnssec16.xa."
- The zone has no DNSKEY.
- The zone has one Well Formed CDS Record that matches no DNSKEY.
DELETE-CDS
- Zone: "delete-cds.dnssec16.xa."
- The zone has a Well Formed DNSKEY Record.
- The zone has one CDS RR that is a Delete CDS.
DNSKEY-NOT-SIGNED-BY-CDS
- Zone: "dnskey-not-signed-by-cds.dnssec16.xa."
- The zone has a Well Formed DNSKEY Record (key 1), but the key has not signed the DNSKEY RRset.
- The zone has one Well Formed CDS Record, and it matches key 1.
MIXED-DELETE-CDS
- Zone: "mixed-delete-cds.dnssec16.xa."
- The zone has a Well Formed DNSKEY Record (key 1).
- The zone has one Well Formed CDS Record, and it matches key 1.
- The zone has a second CDS RR that is a Delete CDS.
NO-CDS
- Zone: "no-cds.dnssec16.xa."
- The name servers give no CDS RRset on CDS query (NODATA).
NOT-AA
- Zone: "not-aa.dnssec16.xa."
- The name servers give non-AA response on CDS queries.
VALID-CDS
- Zone: "valid-cds.dnssec16.xa."
- The zone has a Well Formed DNSKEY Record (key 1).
- The zone has one Well Formed CDS Record, and it matches key 1.
Terminology
-
"Well Formed DNSKEY Record" - The term is used, in this document, for a DNSKEY record that meets the following requirements:
-
"Well Formed CDS Record" - The term is used, in this document, for a CDS record that meets the following requirements:
- It is a CDS record in apex.
- It uses hash digest 2 (SHA-256), see DNSSEC01.
- Its digest is a digest of a Well Formed DNSKEY Record.
- The CDS RRset has been signed by the its DNSKEY and the RRSIG is valid.
Specification of test scenarios for Delegation-TP
Test scenario specifications are available for:
Specification of test Scenarios for Delegation01
Table of contents
- Background
- Test Case
- Test scenarios
- Test zone names
- All message tags
- Test scenarios and message tags
- Test zone setup
Background
See the test scenario README file.
Test Case
This document specifies test scenarios for test case Delegation01.
Test scenarios
The purpose of the test scenarios is to cover all reasonable contexts where different message tags are output when Delegation01 is run on a test zone. The message tags are defined in the test case (Delegation01) and the scenarios are defined below.
The test scenarios are structured as stated in the test scenario README file.
Test zone names
The test zone for each test scenario in this document is a subdomain delegated
from the base name (delegation01.xa
) and that subdomain having the same name as
the scenario. The names of those zones are given in section
Test zone setup below.
All message tags
The test case can output any of these message tags, but not necessarily in any combination. See Delegation01 for the specification of the tags.
- ENOUGH_IPV4_NS_CHILD
- ENOUGH_IPV4_NS_DEL
- ENOUGH_IPV6_NS_CHILD
- ENOUGH_IPV6_NS_DEL
- ENOUGH_NS_CHILD
- ENOUGH_NS_DEL
- NOT_ENOUGH_IPV4_NS_CHILD
- NOT_ENOUGH_IPV4_NS_DEL
- NOT_ENOUGH_IPV6_NS_CHILD
- NOT_ENOUGH_IPV6_NS_DEL
- NOT_ENOUGH_NS_CHILD
- NOT_ENOUGH_NS_DEL
- NO_IPV4_NS_CHILD
- NO_IPV4_NS_DEL
- NO_IPV6_NS_CHILD
- NO_IPV6_NS_DEL
Test scenarios and message tags
If a message tag is not listed for the scenario, its presence or non-presence is irrelevant to the test scenario and must be ignored.
Scenario name | Mandatory message tag | Forbidden message tags |
---|---|---|
ENOUGH-1 | ENOUGH_IPV4_NS_CHILD, ENOUGH_IPV4_NS_DEL, ENOUGH_IPV6_NS_CHILD, ENOUGH_IPV6_NS_DEL, ENOUGH_NS_CHILD, ENOUGH_NS_DEL | 2) |
ENOUGH-2 | ENOUGH_IPV4_NS_CHILD, ENOUGH_IPV4_NS_DEL, ENOUGH_IPV6_NS_CHILD, ENOUGH_IPV6_NS_DEL, ENOUGH_NS_CHILD, ENOUGH_NS_DEL | 2) |
ENOUGH-3 | ENOUGH_IPV4_NS_CHILD, ENOUGH_IPV4_NS_DEL, ENOUGH_IPV6_NS_CHILD, ENOUGH_IPV6_NS_DEL, ENOUGH_NS_CHILD, ENOUGH_NS_DEL | 2) |
ENOUGH-DEL-NOT-CHILD | ENOUGH_IPV4_NS_DEL, ENOUGH_IPV6_NS_DEL, ENOUGH_NS_DEL, NOT_ENOUGH_IPV4_NS_CHILD, NOT_ENOUGH_IPV6_NS_CHILD, NOT_ENOUGH_NS_CHILD | 2) |
ENOUGH-CHILD-NOT-DEL | ENOUGH_IPV4_NS_CHILD, ENOUGH_IPV6_NS_CHILD, ENOUGH_NS_CHILD, NOT_ENOUGH_IPV4_NS_DEL, NOT_ENOUGH_IPV6_NS_DEL, NOT_ENOUGH_NS_DEL | 2) |
IPV6-AND-DEL-OK-NO-IPV4-CHILD | ENOUGH_IPV4_NS_DEL, ENOUGH_IPV6_NS_CHILD, ENOUGH_IPV6_NS_DEL, ENOUGH_NS_CHILD, ENOUGH_NS_DEL, NO_IPV4_NS_CHILD | 2) |
IPV4-AND-DEL-OK-NO-IPV6-CHILD | ENOUGH_IPV4_NS_DEL, ENOUGH_IPV4_NS_CHILD, ENOUGH_IPV6_NS_DEL, ENOUGH_NS_CHILD, ENOUGH_NS_DEL, NO_IPV6_NS_CHILD | 2) |
NO-IPV4-1 | ENOUGH_IPV6_NS_CHILD, ENOUGH_IPV6_NS_DEL, ENOUGH_NS_CHILD, ENOUGH_NS_DEL, NO_IPV4_NS_CHILD, NO_IPV4_NS_DEL | 2) |
NO-IPV4-2 | ENOUGH_IPV6_NS_CHILD, ENOUGH_IPV6_NS_DEL, ENOUGH_NS_CHILD, ENOUGH_NS_DEL, NO_IPV4_NS_CHILD, NO_IPV4_NS_DEL | 2) |
NO-IPV4-3 | ENOUGH_IPV6_NS_CHILD, ENOUGH_IPV6_NS_DEL, ENOUGH_NS_CHILD, ENOUGH_NS_DEL, NO_IPV4_NS_CHILD, NO_IPV4_NS_DEL | 2) |
NO-IPV6-1 | ENOUGH_IPV4_NS_CHILD, ENOUGH_IPV4_NS_DEL, ENOUGH_NS_CHILD, ENOUGH_NS_DEL, NO_IPV6_NS_CHILD, NO_IPV6_NS_DEL | 2) |
NO-IPV6-2 | ENOUGH_IPV4_NS_CHILD, ENOUGH_IPV4_NS_DEL, ENOUGH_NS_CHILD, ENOUGH_NS_DEL, NO_IPV6_NS_CHILD, NO_IPV6_NS_DEL | 2) |
NO-IPV6-3 | ENOUGH_IPV4_NS_CHILD, ENOUGH_IPV4_NS_DEL, ENOUGH_NS_CHILD, ENOUGH_NS_DEL, NO_IPV6_NS_CHILD, NO_IPV6_NS_DEL | 2) |
MISMATCH-DELEGATION-CHILD-1 | ENOUGH_IPV4_NS_CHILD, NOT_ENOUGH_IPV4_NS_DEL, ENOUGH_IPV6_NS_CHILD, NOT_ENOUGH_IPV6_NS_DEL, ENOUGH_NS_CHILD, ENOUGH_NS_DEL | 2) |
MISMATCH-DELEGATION-CHILD-2 | NOT_ENOUGH_IPV4_NS_CHILD, ENOUGH_IPV4_NS_DEL, NOT_ENOUGH_IPV6_NS_CHILD, ENOUGH_IPV6_NS_DEL, ENOUGH_NS_CHILD, ENOUGH_NS_DEL | 2) |
1) All tags except for those specified as "Forbidden message tags" (no instances for these test scenarios)
2) All tags except for those specified as "Mandatory message tags"
Test zone setup
Assumptions for the scenario specifications unless otherwise specified for the specific scenario:
- For each scenario zone there are two name servers configured.
- Both name servers (ns1 and ns2) are equal in delegation and in zone.
- Both name servers are in-bailiwick.
- Both name servers have both IPv4 and IPv6 addresses.
- All required glue records are present in the delegation.
- All glue exactly match the authoritative address records in correct zone (not more and not less records).
- All name server IP addresses respond with identical zone content.
ENOUGH-1
This is the main happy path.
- Zone: enough-1.delegation01.xa
ENOUGH-2
This is also a happy path. Out-of-bailiwick.
- Zone: enough-2.delegation01.xa
- Both ns1 and ns2 are out-of-bailiwick.
- ns1 is "ns1.enough-2.delegation01.xb"
- ns2 is "ns2.enough-2.delegation01.xb"
- Delegation is without glue.
- The test zone ("child") has no address records for the name server names.
- The "delegation01.xb" zone has the full set of address records.
- Both ns1 and ns2 are out-of-bailiwick.
ENOUGH-3
This is also a happy path. Also out-of-bailiwick, but with sibling glue.
- Zone: enough-3.delegation01.xa
- Both ns1 and ns2 are out-of-bailiwick
- ns1 is "ns1.enough-3.sibling.delegation01.xa"
- ns2 is "ns2.enough-3.sibling.delegation01.xa"
- Delegation is with glue.
- The child zone has no address records for the name server names.
- The two name servers are defined directly in the parent zone with full set of address records.
- Both ns1 and ns2 are out-of-bailiwick
ENOUGH-DEL-NOT-CHILD
Only one name server in child zone.
- Zone: enough-del-not-child.delegation01.xa
- The child zone defines only one name server, ns1.
- Delegation is complete.
ENOUGH-CHILD-NOT-DEL
Only one name server in delegation.
- Zone: enough-child-not-del.delegation01.xa
- The delegation has only one name server, for ns1.
- The child has two name servers with full set of address records.
IPV6-AND-DEL-OK-NO-IPV4-CHILD
No IPv4 in zone.
- Zone: ipv6-and-del-ok-no-ipv4-child.delegation01.xa
- No A records for ns1 and ns2 in zone.
- Delegation is complete.
IPV4-AND-DEL-OK-NO-IPV6-CHILD
No IPv6 in zone.
- Zone: ipv4-and-del-ok-no-ipv6-child.delegation01.xa
- No AAAA records for ns1 and ns2 in zone.
- Delegation is complete.
NO-IPV4-1
No IPv4 in delegation or zone.
- Zone: no-ipv4-1.delegation01.xa
- No A glue for ns1 and ns2.
- No A records in zone for ns1 and ns2.
NO-IPV4-2
No IPv4 in delegation or zone. Out-of-bailiwick name servers and no glue.
- Zone: no-ipv4-2.delegation01.xa
- Both ns1 and ns2 are out-of-bailiwick under the xb tree.
- ns1 is "ns1.no-ipv4-2.delegation01.xb"
- ns2 is "ns2.no-ipv4-2.delegation01.xb"
- Delegation is without glue.
- The test zone ("child") has no address records for the name server names
- The "delegation01.xb" zone has full set of address records for this.
- AAAA only, not A
- Both ns1 and ns2 are out-of-bailiwick under the xb tree.
NO-IPV4-3
No IPv4 in delegation or zone. Out-of-bailiwick name servers, but with sibling glue.
- Zone: no-ipv4-3.delegation01.xa
- Both ns1 and ns2 are out-of-bailiwick
- ns1 is "ns1.no-ipv4-3.sibling.delegation01.xa"
- ns2 is "ns2.no-ipv4-3.sibling.delegation01.xa"
- Delegation is with glue.
- The child zone has no address records for the name server names
- The sibling names have full sets of address records.
- AAAA only, not A.
- Both ns1 and ns2 are out-of-bailiwick
NO-IPV6-1
No IPv6 in delegation or zone.
- Zone: no-ipv6-1.delegation01.xa
- No AAAA glue for ns1 and ns2.
- No AAAA records in zone for ns1 and ns2.
NO-IPV6-2
No IPv6 in delegation or zone. Out-of-bailiwick name servers and no glue.
- Zone: no-ipv6-2.delegation01.xa
- Both ns1 and ns2 are out-of-bailiwick under the xb tree.
- ns1 is "ns1.no-ipv6-2.delegation01.xb"
- ns2 is "ns2.no-ipv6-2.delegation01.xb"
- Delegation is without glue.
- The test zone ("child") has no address records for the name servers names
- The "delegation01.xb" zone has full set of address records for this.
- A only, not AAAA
- Both ns1 and ns2 are out-of-bailiwick under the xb tree.
NO-IPV6-3
No IPv6 in delegation or zone. Out-of-bailiwick name servers, but with sibling glue.
- Zone: no-ipv6-3.delegation01.xa
- Both ns1 and ns2 are out-of-bailiwick
- ns1 is "ns1.no-ipv6-3.sibling.delegation01.xa"
- ns2 is "ns2.no-ipv6-3.sibling.delegation01.xa"
- Delegation is with glue.
- The child zone has no address records for the name server names
- The sibling names has full set of address records.
- A only, not AAAA.
- Both ns1 and ns2 are out-of-bailiwick
MISMATCH-DELEGATION-CHILD-1
Missing glue, only IPv4 on ns1 and only IPv6 on ns2.
- Zone: mismatch-delegation-child-1.delegation01.xa
- Only IPv4 glue on ns1.
- Only IPv6 glue on ns2.
- Full set in zone.
MISMATCH-DELEGATION-CHILD-2
The zone has only IPv4 on ns1 and only IPv6 on ns2.
- Zone: mismatch-delegation-child-2.delegation01.xa
- Only IPv4 on ns1 in zone.
- Only IPv6 on ns2 in zone.
- Full set in delegation.
Specification of test Scenarios for Delegation02
Table of contents
- Background
- Test Case
- Test scenarios
- Test zone names
- All message tags
- Test scenarios and message tags
- Test zone setup
Background
See the test scenario README file.
Test Case
This document specifies test scenarios for test case Delegation02.
Test scenarios
The purpose of the test scenarios is to cover all reasonable contexts where different message tags are output when Delegation02 is run on a test zone. The message tags are defined in the test case (Delegation02) and the scenarios are defined below.
The test scenarios are structured as stated in the test scenario README file.
Test zone names
The test zone for each test scenario in this document is a subdomain delegated
from the base name (delegation02.xa
) and that subdomain having the same name as
the scenario. The names of those zones are given in section Test zone setup
below.
All message tags
The test case can output any of these message tags, but not necessarily in any combination. See Delegation02 for the specification of the tags.
- DEL_DISTINCT_NS_IP
- CHILD_DISTINCT_NS_IP
- DEL_NS_SAME_IP
- CHILD_NS_SAME_IP
Test scenarios and message tags
If a message tag is not listed for the scenario, its presence or non-presence is irrelevant to the test scenario and must be ignored.
Scenario name | Mandatory message tag | Forbidden message tags |
---|---|---|
ALL-DISTINCT-1 | DEL_DISTINCT_NS_IP, CHILD_DISTINCT_NS_IP | 2) |
ALL-DISTINCT-2 | DEL_DISTINCT_NS_IP, CHILD_DISTINCT_NS_IP | 2) |
ALL-DISTINCT-3 | DEL_DISTINCT_NS_IP, CHILD_DISTINCT_NS_IP | 2) |
DEL-NON-DISTINCT | DEL_NS_SAME_IP, CHILD_DISTINCT_NS_IP | 2) |
DEL-NON-DISTINCT-UND | DEL_NS_SAME_IP, CHILD_DISTINCT_NS_IP | 2) |
CHILD-NON-DISTINCT | DEL_DISTINCT_NS_IP, CHILD_NS_SAME_IP | 2) |
CHILD-NON-DISTINCT-UND | DEL_DISTINCT_NS_IP, CHILD_NS_SAME_IP | 2) |
NON-DISTINCT-1 | DEL_NS_SAME_IP, CHILD_NS_SAME_IP | 2) |
NON-DISTINCT-2 | DEL_NS_SAME_IP, CHILD_NS_SAME_IP | 2) |
NON-DISTINCT-3 | DEL_NS_SAME_IP, CHILD_NS_SAME_IP | 2) |
1) All tags except for those specified as "Forbidden message tags" (no instances for these test scenarios)
2) All tags except for those specified as "Mandatory message tags"
Test zone setup
Assumptions for the scenario specifications unless otherwise specified for the specific scenario:
- For each scenario zone there are two name servers configured.
- Both name servers (ns1 and ns2) are equal in delegation and in zone.
- Both name servers are in-bailiwick.
- Both name servers have both IPv4 and IPv6 addresses.
- All addresses are distinct.
- All required glue are present in the delegation.
- All glue exactly matches the authoritative address records in correct zone (not more and not less records).
- All name server IP addresses respond with identical zone content.
ALL-DISTINCT-1
This is the happy path.
- Zone: all-distinct-1.delegation02.xa
ALL-DISTINCT-2
This is also a happy path. Out-of-bailiwick.
- Zone: all-distinct-2.delegation02.xa
- Both ns1 and ns2 are out-of-bailiwick under the xb tree.
- ns1 is "ns1.all-distinct-2.delegation02.xb"
- ns2 is "ns2.all-distinct-2.delegation02.xb"
- Delegation is without glue.
- The test zone has no address records for the name server names.
- The "delegation02.xb" zone has full set of address records for this scenario.
- Both ns1 and ns2 are out-of-bailiwick under the xb tree.
ALL-DISTINCT-3
This is also a happy path. Also out-of-bailiwick, but with sibling glue.
- Zone: all-distinct-3.delegation02.xa
- Both ns1 and ns2 are out-of-bailiwick
- ns1 is "ns1.all-distinct-3.sibling.delegation02.xa"
- ns2 is "ns2.all-distinct-3.sibling.delegation02.xa"
- Delegation is with glue.
- The test zone ("child") has no address records for the name server names.
- The "delegation02.xa" zone has full set of address records for this scenario.
- Both ns1 and ns2 are out-of-bailiwick
DEL-NON-DISTINCT
The glue records use the same IP addresses.
- Zone: del-non-distinct.delegation02.xa
- The name servers are ns1a and ns1b
- ns1a and ns1b in the delegation (glue) have the same IPv4 and IPv6 addresses, respectively.
- ns1a and ns1b have distinct addresses in the zone (IPv4 and IPv6, respectively).
- The name servers are ns1a and ns1b
DEL-NON-DISTINCT-UND
The glue records use the same IP addresses. The zone is undelegated.
- Zone: del-non-distinct-und.delegation02.xa
- The zone is undelegated.
- name servers are ns1a and ns1b
- ns1a and ns1b in the delegation (glue) have the same IPv4 and IPv6 addresses, respectively.
- ns1a and ns1b have distinct addresses in the zone (IPv4 and IPv6, respectively).
- Undelegated data:
- ns1a.del-non-distinct-und.delegation02.xa/IPv4
- ns1a.del-non-distinct-und.delegation02.xa/IPv6
- ns1b.del-non-distinct-und.delegation02.xa/IPv4
- ns1b.del-non-distinct-und.delegation02.xa/IPv6
CHILD-NON-DISTINCT
The address records in the zone use the same IP addresses.
- Zone: child-non-distinct.delegation02.xa
- name servers are ns1a and ns1b
- ns1a and ns1b in the delegation (glue) have distinct addresses (IPv4 and IPv6, respectively).
- ns1a and ns1b have the same addresses in the zone, IPv4 and IPv6, respectively.
- name servers are ns1a and ns1b
CHILD-NON-DISTINCT-UND
The address records in the zone use the same IP addresses.
- Zone: child-non-distinct-und.delegation02.xa
- The zone is undelegated.
- name servers are ns1a and ns1b
- ns1a and ns1b in the delegation (glue) have distinct addresses (IPv4 and IPv6, respectively).
- ns1a and ns1b have the same addresses in the zone, IPv4 and IPv6, respectively.
- Undelegated data:
- ns1a.child-non-distinct-und.delegation02.xa/IPv4
- ns1a.child-non-distinct-und.delegation02.xa/IPv6
- ns1b.child-non-distinct-und.delegation02.xa/IPv4
- ns1b.child-non-distinct-und.delegation02.xa/IPv6
NON-DISTINCT-1
The address records in both delegation and zone use the same IP addresses.
- Zone: non-distinct-1.delegation02.xa
- name servers are ns1a, ns1b and ns2
- ns1a and ns1b in the delegation (glue) have the same IPv4 and IPv6 addresses, respectively.
- ns1a and ns1b have the same addresses in the zone, IPv4 and IPv6, respectively.
- ns2 has a distinct address both in delegation and in zone.
- name servers are ns1a, ns1b and ns2
NON-DISTINCT-2
The name servers in both delegation and zone refer to the same IP addresses. The names are out-of-bailiwick.
- Zone: non-distinct-2.delegation02.xa
- name servers are ns1a, ns1b and ns2, and are out-of-bailiwick under the xb
tree.
- ns1a is "ns1a.non-distinct-2.delegation02.xb"
- ns1b is "ns1a.non-distinct-2.delegation02.xb"
- ns2 is "ns2.non-distinct-2.delegation02.xb"
- Delegation is without glue.
- ns1a and ns1b have the same addresses, IPv4 and IPv6, respectively.
- ns2 has distinct addresses (IPv4 and IPv6).
- The test zone has no address records for the name server names.
- The "delegation02.xb" zone has full set of address records for this scenario.
- name servers are ns1a, ns1b and ns2, and are out-of-bailiwick under the xb
tree.
NON-DISTINCT-3
The name servers in both delegation and zone refer to the same IP addresses. The names are out-of-bailiwick, but with sibling glue.
- Zone: non-distinct-3.delegation02.xa
- name servers are ns1a, ns1b and ns2, and are out-of-bailiwick.
- ns1a is "ns1a.non-distinct-3.sibling.delegation02.xa"
- ns1b is "ns1a.non-distinct-3.sibling.delegation02.xa"
- ns2 is "ns2.non-distinct-3.sibling.delegation02.xa"
- Delegation has sibling glue.
- ns1a and ns1b have the same addresses, IPv4 and IPv6, respectively.
- ns2 has distinct addresses (IPv4 and IPv6).
- The test zone has no address records for the name server names.
- The "delegation02.xa" zone has full set of address records for this scenario.
- name servers are ns1a, ns1b and ns2, and are out-of-bailiwick.
Specification of test Scenarios for Delegation03
Table of contents
- Background
- Test Case
- Test scenarios
- Test zone names
- All message tags
- Test scenarios and message tags
- Test zone setup
Background
See the test scenario README file.
Test Case
This document specifies test scenarios for test case Delegation03.
Test scenarios
The purpose of the test scenarios is to cover all reasonable contexts where different message tags are output when Delegation03 is run on a test zone. The message tags are defined in the test case (Delegation03) and the scenarios are defined below.
The test scenarios are structured as stated in the test scenario README file.
Test zone names
The test zone for each test scenario in this document is a subdomain delegated
from the base name (delegation03.xa
) and that subdomain having the same name as the
scenario. The names of those zones are given in section
Test zone setup below.
All message tags
The test case can output any of these message tags, but not necessarily in any combination. See Delegation03 for the specification of the tags.
- REFERRAL_SIZE_OK
- REFERRAL_SIZE_TOO_LARGE
Test scenarios and message tags
If a message tag is not listed for the scenario, its presence or non-presence is irrelevant to the test scenario and must be ignored.
Scenario name | Mandatory message tag | Forbidden message tags |
---|---|---|
REFERRAL-SIZE-OK-1 | REFERRAL_SIZE_OK | 2) |
REFERRAL-SIZE-OK-2 | REFERRAL_SIZE_OK | 2) |
REFERRAL-SIZE-TOO-LARGE-1 | REFERRAL_SIZE_TOO_LARGE | 2) |
REFERRAL-SIZE-TOO-LARGE-2 | REFERRAL_SIZE_TOO_LARGE | 2) |
1) All tags except for those specified as "Forbidden message tags" (no instances for these test scenarios)
2) All tags except for those specified as "Mandatory message tags"
Test zone setup
Assumptions for the scenario specifications unless otherwise specified for the specific scenario:
- For each scenario zone there are two name server configured.
- Both name servers are in-bailiwick.
- Both name servers have both IPv4 and IPv6 addresses.
- All addresses are distinct.
- All required glue are present in the delegation.
- There is no actual zone or zone file, only a delegation.
- For these scenarios only the delegation is needed.
REFERRAL-SIZE-OK-1
This is the happy path.
- Zone: referral-size-ok-1.delegation03.xa.
REFERRAL-SIZE-OK-2
Referral is large, but not too large. The name servers are in-bailiwick.
- Zone: referral-size-ok-2.delegation03.xa.
- ns1 is "ns1.ipv4-large-but-not-too-large.referral-size-ok-2.delegation03.xa".
- ns1 is "ns1.ipv6-large-but-not-too-large.referral-size-ok-2.delegation03.xa".
- ns2 is "ns2.ipv4-large-but-not-too-large.referral-size-ok-2.delegation03.xa".
- ns2 is "ns2.ipv6-large-but-not-too-large.referral-size-ok-2.delegation03.xa".
REFERRAL-SIZE-TOO-LARGE-1
Referral is too large and name servers are in-bailiwick.
- Zone: referral-size-too-large-1.delegation03.xa
- Name server names are relative to the zone name:
- ns1 is "ns1.1abcdefghijklmnopqrstuv.1defghijkl"
- ns2 is "ns2.2abcdefghijklmnopqrstuv.2defghijkl"
- ns3 is "ns3.2abcdefghijklmnopqrstuv.3defghijkl"
- ns4 is "ns4.2abcdefghijklmnopqrstuv.4defghijkl"
- ns5 is "ns5.2abcdefghijklmnopqrstuv.5defghijkl"
- Name server names are relative to the zone name:
REFERRAL-SIZE-TOO-LARGE-2
Referral is too large and name servers are out-of-bailiwick with no glue.
- Zone: referral-size-too-large-2.delegation03.xa
- The zone is delegated to ns1, ns2, ns3 and ns4.
- ns1 is "ns1.1abcdefghijklmnopqrstuvwxyz.1abcdefghijklmnopqrstuvwxy.1abcdefghijklmnopqrstuvw.referral-size-too-large-2.delegation03.xb"
- ns2 is "ns2.2abcdefghijklmnopqrstuvwxyz.2abcdefghijklmnopqrstuvwxy.2abcdefghijklmnopqrstuvw.referral-size-too-large-2.delegation03.xb"
- ns3 is "ns3.3abcdefghijklmnopqrstuvwxyz.3abcdefghijklmnopqrstuvwxy.3abcdefghijklmnopqrstuvw.referral-size-too-large-2.delegation03.xb"
- ns4 is "ns4.4abcdefghijklmnopqrstuvwxyz.4abcdefghijklmnopqrstuvwxy.4abcdefghijklmnopqrstuvw.referral-size-too-large-2.delegation03.xb"
- Delegation is without glue.
- The test zone has no address records for the name server names.
- The "delegation03.xb" zone has full set of address records (IPv4 and IPv6).
- The zone is delegated to ns1, ns2, ns3 and ns4.
Specification of test zones for Nameserver-TP
Test zone specifications are available for:
Specification of test zones for NAMESERVER11
Table of contents
- Background
- Test Case
- Test scenarios
- Test zone names
- Test scenarios and message tags
- Zone setup for test scenarios
Background
See the test zone README file.
Test Case
This document specifies defined test zones for test case NAMESERVER11.
Test scenarios
The purpose of the test scenarios is to cover all reasonable contexts where different message tags are outputted when NAMESERVER11 is run on a test zone. The message tags are defined in the test case (NAMESERVER11) and the scenarios are defined below.
The test scenarios are structured as stated in the test zone README file.
Test zone names
The test zone for each test scenario in this document is a subdomain delegated
from the base name (nameserver11.xa
) and that subdomain having the same name as the
scenario. The names of those zones are given in section
"Zone setup for test scenarios" below.
Test scenarios and message tags
If a message tag is not listed for the scenario, its presence or non-presence is irrelevant to the test scenario and must be ignored.
Scenario name | Mandatory message tag | Forbidden message tags |
---|---|---|
NO-EDNS-ON-UNKNOWN-OC | N11_NO_EDNS | N11_NO_RESPONSE, N11_RETURNS_UNKNOWN_OPTION_CODE, N11_UNEXPECTED_ANSWER_SECTION, N11_UNEXPECTED_RCODE, N11_UNSET_AA |
NO-ERROR | (none) | N11_NO_EDNS, N11_NO_RESPONSE, N11_RETURNS_UNKNOWN_OPTION_CODE, N11_UNEXPECTED_ANSWER_SECTION, N11_UNEXPECTED_RCODE, N11_UNSET_AA |
NO-RESPONSE-ON-EDNS | (none) | N11_NO_EDNS, N11_NO_RESPONSE, N11_RETURNS_UNKNOWN_OPTION_CODE, N11_UNEXPECTED_ANSWER_SECTION, N11_UNEXPECTED_RCODE, N11_UNSET_AA |
NO-RESPONSE-ON-UNKNOWN-OC | N11_NO_RESPONSE | N11_NO_EDNS, N11_RETURNS_UNKNOWN_OPTION_CODE, N11_UNEXPECTED_ANSWER_SECTION, N11_UNEXPECTED_RCODE, N11_UNSET_AA |
RETURNS-UNKNOWN-OC | N11_RETURNS_UNKNOWN_OPTION_CODE | N11_NO_EDNS, N11_NO_RESPONSE, N11_UNEXPECTED_ANSWER_SECTION, N11_UNEXPECTED_RCODE, N11_UNSET_AA |
UNEXPECTED-ANSWER-SECTION | N11_UNEXPECTED_ANSWER_SECTION | N11_NO_EDNS, N11_NO_RESPONSE, N11_RETURNS_UNKNOWN_OPTION_CODE, N11_UNEXPECTED_RCODE, N11_UNSET_AA |
UNEXPECTED-RCODE-FORMERR | N11_UNEXPECTED_RCODE | N11_NO_EDNS, N11_NO_RESPONSE, N11_RETURNS_UNKNOWN_OPTION_CODE, N11_UNEXPECTED_ANSWER_SECTION, N11_UNSET_AA |
UNEXPECTED-RCODE-REFUSED | N11_UNEXPECTED_RCODE | N11_NO_EDNS, N11_NO_RESPONSE, N11_RETURNS_UNKNOWN_OPTION_CODE, N11_UNEXPECTED_ANSWER_SECTION, N11_UNSET_AA |
UNSET-AA | N11_UNSET_AA | N11_NO_EDNS, N11_NO_RESPONSE, N11_RETURNS_UNKNOWN_OPTION_CODE, N11_UNEXPECTED_ANSWER_SECTION, N11_UNEXPECTED_RCODE |
Zone setup for test scenarios
Assumptions for the scenario specifications:
- For each scenario zone there is one name server configured.
- Unless stated otherwise, all name servers respond as follows:
- Responds with a SOA record for the zone on query for SOA.
- All responses are authoritative with RCODE Name "NoError".
- EDNS, version 0, is included in all responses on queries with EDNS.
- EDNS is not included in responses on queries without EDNS.
- Unknown EDNS option codes are not included in responses.
NO-EDNS-ON-UNKNOWN-OC
- Zone: "no-edns-on-unknown-oc.nameserver11.xa."
- The name server will respond without EDNS if the query includes an unknown EDNS OPTION CODE.
NO-ERROR
- Zone: "no-error.nameserver11.xa."
- The name server will respond as default (no error).
NO-RESPONSE-ON-EDNS
- Zone: "no-response-on-edns.nameserver11.xa."
- The name server will not respond to any query with EDNS.
NO-RESPONSE-ON-UNKNOWN-OC
- Zone: "no-response-on-unknown-oc.nameserver11.xa."
- The name server will not respond if the query includes an unknown EDNS OPTION CODE.
RETURNS-UNKNOWN-OC
- Zone: "returns-unknown-oc.nameserver11.xa."
- The name server will respond with an unknown EDNS OPTION CODE if the query includes an unknown EDNS OPTION CODE.
UNEXPECTED-ANSWER-SECTION
- Zone: "unexpected-answer-section.nameserver11.xa."
- The name server will respond without the SOA record if the query includes an unknown EDNS OPTION CODE.
UNEXPECTED-RCODE-FORMERR
- Zone: "unexpected-rcode-formerr.nameserver11.xa."
- The name server will respond with RCODE Name "FormErr" if the query includes an unknown EDNS OPTION CODE.
UNEXPECTED-RCODE-REFUSED
- Zone: "unexpected-rcode-refused.nameserver11.xa."
- The name server will respond with RCODE Name "Refused" if the query includes an unknown EDNS OPTION CODE.
UNSET-AA
- Zone: "unset-aa.nameserver11.xa."
- The name server will respond with AA unset if the query includes an unknown EDNS OPTION CODE.
Specification of test zones for NAMESERVER15
Table of contents
- Background
- Test Case
- Test scenarios
- Test zone names
- Test scenarios and message tags
- Zone setup for test scenarios
Background
See the test zone README file.
Test Case
This document specifies defined test zones for test case NAMESERVER15.
Test scenarios
The purpose of the test scenarios is to cover all reasonable contexts where different message tags are outputted when NAMESERVER15 is run on a test zone. The message tags are defined in the test case (NAMESERVER15) and the scenarios are defined below.
The test scenarios are structured as stated in the test zone README file.
Test zone names
The test zone for each test scenario in this document is a subdomain delegated
from the base name (nameserver15.xa
) and that subdomain having the same name as the
scenario. The names of those zones are given in section
"Zone setup for test scenarios" below.
Test scenarios and message tags
If a message tag is not listed for the scenario, its presence or non-presence is irrelevant to the test scenario and must be ignored.
Scenario name | Mandatory message tag | Forbidden message tags |
---|---|---|
NO-VERSION-REVEALED-1 | N15_NO_VERSION_REVEALED | N15_ERROR_ON_VERSION_QUERY, N15_SOFTWARE_VERSION, N15_WRONG_CLASS |
NO-VERSION-REVEALED-2 | N15_NO_VERSION_REVEALED | N15_ERROR_ON_VERSION_QUERY, N15_SOFTWARE_VERSION, N15_WRONG_CLASS |
NO-VERSION-REVEALED-3 | N15_NO_VERSION_REVEALED | N15_ERROR_ON_VERSION_QUERY, N15_SOFTWARE_VERSION, N15_WRONG_CLASS |
NO-VERSION-REVEALED-4 | N15_NO_VERSION_REVEALED | N15_ERROR_ON_VERSION_QUERY, N15_SOFTWARE_VERSION, N15_WRONG_CLASS |
NO-VERSION-REVEALED-5 | N15_NO_VERSION_REVEALED | N15_ERROR_ON_VERSION_QUERY, N15_SOFTWARE_VERSION, N15_WRONG_CLASS |
NO-VERSION-REVEALED-6 | N15_NO_VERSION_REVEALED | N15_ERROR_ON_VERSION_QUERY, N15_SOFTWARE_VERSION, N15_WRONG_CLASS |
ERROR-ON-VERSION-QUERY-1 | N15_ERROR_ON_VERSION_QUERY, N15_NO_VERSION_REVEALED | N15_SOFTWARE_VERSION, N15_WRONG_CLASS |
ERROR-ON-VERSION-QUERY-2 | N15_ERROR_ON_VERSION_QUERY, N15_NO_VERSION_REVEALED | N15_SOFTWARE_VERSION, N15_WRONG_CLASS |
SOFTWARE-VERSION-1 | N15_SOFTWARE_VERSION | N15_ERROR_ON_VERSION_QUERY, N15_NO_VERSION_REVEALED, N15_WRONG_CLASS |
SOFTWARE-VERSION-2 | N15_SOFTWARE_VERSION | N15_ERROR_ON_VERSION_QUERY, N15_NO_VERSION_REVEALED, N15_WRONG_CLASS |
WRONG-CLASS-1 | N15_SOFTWARE_VERSION, N15_WRONG_CLASS | N15_ERROR_ON_VERSION_QUERY, N15_NO_VERSION_REVEALED |
WRONG-CLASS-2 | N15_SOFTWARE_VERSION, N15_WRONG_CLASS | N15_ERROR_ON_VERSION_QUERY, N15_NO_VERSION_REVEALED |
Zone setup for test scenarios
Assumptions for the scenario specifications:
- For each scenario zone there is one name server configured.
- Unless stated otherwise, all name servers respond as follows:
- Responds with a SOA record for the zone on query for SOA.
- Responds with CH class on queries on CH class.
- Software version query names are "version.bind" and "version.server".
- All responses are RCODE Name "NoError".
- EDNS, version 0, is included in all responses on queries with EDNS.
- EDNS is not included in responses on queries without EDNS.
NO-VERSION-REVEALED-1
This is a happy path
- Zone: "no-version-revealed-1.nameserver15.xa."
- The name server responds with empty answer section on both software version query names.
NO-VERSION-REVEALED-2
This is a happy path
- Zone: "no-version-revealed-2.nameserver15.xa."
- The name server responds with empty answer section on both software version query names.
- The name server responds with RCODE Name "NxDomain" on both software version query names.
NO-VERSION-REVEALED-3
This is a happy path
- Zone: "no-version-revealed-3.nameserver15.xa."
- The name server responds with empty answer section on both software version query names.
- The name server responds with RCODE Name "Refused" on both software version query names.
NO-VERSION-REVEALED-4
This is a happy path
- Zone: "no-version-revealed-4.nameserver15.xa."
- The name server responds with a single CNAME record and no other record in
answer section on both software version query names.
- "version.bind. CNAME version.server." when query name is version.bind.
- "version.server. CNAME version.bind." when query name is version.server.
- The name server responds with a single CNAME record and no other record in
answer section on both software version query names.
NO-VERSION-REVEALED-5
This is a happy path
- Zone: "no-version-revealed-5.nameserver15.xa."
- RDATA of the TXT records for both software version query names is the empty string.
NO-VERSION-REVEALED-6
This is a happy path
- Zone: "no-version-revealed-6.nameserver15.xa."
- RDATA of the TXT records for both software version query names only consists of space characters.
ERROR-ON-VERSION-QUERY-1
Unexpected response from server
- Zone: "error-on-version-query-1.nameserver15.xa."
- The name server responds with empty answer section on both software version query names.
- The name server responds with RCODE Name "ServFail" on both software version query names.
ERROR-ON-VERSION-QUERY-2
Unexpected response from server
- Zone: "error-on-version-query-2.nameserver15.xa."
- The name server does not respond at all to the queries with the software version query names.
SOFTWARE-VERSION-1
Normal version string
- Zone: "software-version-1.nameserver15.xa."
- Empty response on software query name "version.bind".
- TXT record with RDATA "v0" in response on software query name "version.server" in answer section.
SOFTWARE-VERSION-2
Normal version string
- Zone: "software-version-2.nameserver15.xa."
- Empty response on software query name "version.server".
- TXT record with RDATA "v0" in response on software query name "version.bind" in answer section.
WRONG-CLASS-1
Version string returned in wrong class
- Zone: "wrong-class-1.nameserver15.xa."
- Empty response on software query name "version.bind".
- TXT record with RDATA "v0" in response on software query name
"version.server" in answer section.
- TXT record is in IN class, not CH class.
WRONG-CLASS-2
Version string returned in wrong class
- Zone: "wrong-class-2.nameserver15.xa."
- Empty response on software query name "version.server".
- TXT record with RDATA "v0" in response on software query name
"version.bind" in answer section.
- TXT record is in IN class, not CH class.
Specification of test zones for Zone-TP
Test zone specifications are available for:
Specification of test zones for ZONE09
Table of contents
- Background
- Test Case
- Test scenarios
- Test zone names
- Test scenarios and message tags
- Zone setup for test scenarios
Background
See the test zone README file.
Test Case
This document specifies defined test zones for test case Zone09.
Test scenarios
The purpose of the test scenarios is to cover all reasonable contexts where different message tags are outputted when Zone09 is run on a test zone. The message tags are defined in the test case (Zone09) and the scenarios are defined below.
The test scenarios are structured as stated in the test zone README file.
Test zone names
The test zone for each test scenario in this document is a subdomain delegated
from the base name (zone09.xa
) and that subdomain having the same name as the
scenario except where the test domain must be the root zone, a TLD or a domain
under .arpa
. The names of those zones are given in section
"Zone setup for test scenarios" below.
Test scenarios and message tags
If a message tag is not listed for the scenario, its presence or non-presence is irrelevant to the test scenario and must be ignored.
Scenario name | Mandatory message tags | Forbidden message tags |
---|---|---|
NO-RESPONSE-MX-QUERY | Z09_NO_RESPONSE_MX_QUERY | (none) |
UNEXPECTED-RCODE-MX | Z09_UNEXPECTED_RCODE_MX | (none) |
NON-AUTH-MX-RESPONSE | Z09_NON_AUTH_MX_RESPONSE | (none) |
INCONSISTENT-MX | Z09_INCONSISTENT_MX, Z09_MX_FOUND Z09, NO_MX_FOUND, Z09_MX_DATA | Z09_MISSING_MAIL_TARGET |
INCONSISTENT-MX-DATA | Z09_INCONSISTENT_MX_DATA, Z09_MX_DATA | Z09_MISSING_MAIL_TARGET, Z09_NULL_MX_NON_ZERO_PREF, Z09_NULL_MX_WITH_OTHER_MX, Z09_ROOT_EMAIL_DOMAIN, Z09_TLD_EMAIL_DOMAIN |
NULL-MX-WITH-OTHER-MX | Z09_NULL_MX_WITH_OTHER_MX | Z09_INCONSISTENT_MX_DATA, Z09_MX_DATA, Z09_MISSING_MAIL_TARGET, Z09_ROOT_EMAIL_DOMAIN, Z09_TLD_EMAIL_DOMAIN |
NULL-MX-NON-ZERO-PREF | Z09_NULL_MX_NON_ZERO_PREF | Z09_INCONSISTENT_MX_DATA, Z09_MX_DATA, Z09_MISSING_MAIL_TARGET, Z09_ROOT_EMAIL_DOMAIN, Z09_TLD_EMAIL_DOMAIN |
TLD-EMAIL-DOMAIN | Z09_TLD_EMAIL_DOMAIN | Z09_INCONSISTENT_MX_DATA, Z09_MX_DATA, Z09_MISSING_MAIL_TARGET, Z09_ROOT_EMAIL_DOMAIN, Z09_NULL_MX_WITH_OTHER_MX, Z09_NULL_MX_NON_ZERO_PREF |
ROOT-EMAIL-DOMAIN | Z09_ROOT_EMAIL_DOMAIN | Z09_INCONSISTENT_MX_DATA, Z09_MX_DATA, Z09_MISSING_MAIL_TARGET, Z09_TLD_EMAIL_DOMAIN, Z09_NULL_MX_WITH_OTHER_MX, Z09_NULL_MX_NON_ZERO_PREF |
MX-DATA | Z09_MX_DATA | Z09_INCONSISTENT_MX_DATA, Z09_MISSING_MAIL_TARGET, Z09_TLD_EMAIL_DOMAIN, Z09_ROOT_EMAIL_DOMAIN, Z09_NULL_MX_WITH_OTHER_MX, Z09_NULL_MX_NON_ZERO_PREF |
NULL-MX | (none) | Z09_INCONSISTENT_MX_DATA, Z09_MX_DATA, Z09_MISSING_MAIL_TARGET, Z09_TLD_EMAIL_DOMAIN, Z09_ROOT_EMAIL_DOMAIN, Z09_NULL_MX_WITH_OTHER_MX, Z09_NULL_MX_NON_ZERO_PREF |
NO-MX-SLD | Z09_MISSING_MAIL_TARGET | Z09_INCONSISTENT_MX_DATA, Z09_MX_DATA, Z09_TLD_EMAIL_DOMAIN, Z09_ROOT_EMAIL_DOMAIN, Z09_NULL_MX_WITH_OTHER_MX, Z09_NULL_MX_NON_ZERO_PREF |
NO-MX-TLD | (none) | Z09_INCONSISTENT_MX_DATA, Z09_MX_DATA, Z09_MISSING_MAIL_TARGET, Z09_TLD_EMAIL_DOMAIN, Z09_ROOT_EMAIL_DOMAIN, Z09_NULL_MX_WITH_OTHER_MX, Z09_NULL_MX_NON_ZERO_PREF |
NO-MX-ARPA | (none) | Z09_INCONSISTENT_MX_DATA, Z09_MX_DATA, Z09_MISSING_MAIL_TARGET, Z09_TLD_EMAIL_DOMAIN, Z09_ROOT_EMAIL_DOMAIN, Z09_NULL_MX_WITH_OTHER_MX, Z09_NULL_MX_NON_ZERO_PREF |
Zone setup for test scenarios
Assumptions for the zone setup for the test scenarios:
- Only MX records in apex are considered.
- Unless otherwise stated, all name servers respond authoritatively with the SOA record on SOA queries.
- Unless otherwise stated, all name servers respond authoritatively with (or without) MX records on MX queries.
- Unless otherwise stated, all responses are authoritative and with RCODE Name "NoError".
NO-RESPONSE-MX-QUERY
- Zone: "no-response-mx-query.zone09.xa."
- The zone has two name servers.
- Both name servers return an authoritative answer on SOA query.
- One name server does not respond on MX query.
UNEXPECTED-RCODE-MX
- Zone: "unexpected-rcode-mx.zone09.xa."
- The zone has two name servers.
- Both name servers return an authoritative answer on SOA query.
- One name server returns with any RCODE Name except "NoError".
NON-AUTH-MX-RESPONSE
- Zone: "non-auth-mx-response.zone09.xa."
- The zone has two name servers.
- Both name server return an authoritative answer on SOA query.
- One name server returns with RCODE Name "NoError" and non-AA on MX query.
INCONSISTENT-MX
- Zone: "inconsistent-mx.zone09.xa."
- The zone has two name servers.
- One name server respond with a non-Null MX RRset.
- The other responds without MX RRset (NODATA).
INCONSISTENT-MX-DATA
- Zone: "inconsistent-mx-data.zone09.xa."
- The zone has two name servers.
- Both name servers respond with an MX RRset.
- The two MX RRsets are not equal.
NULL-MX-WITH-OTHER-MX
- Zone: "null-mx-with-other-mx.zone09.xa."
- All name servers respond with the same MX RRset.
- The MX RRset is a mix of Null MX and non-Null MX.
NULL-MX-NON-ZERO-PREF
- Zone: "null-mx-non-zero-pref.zone09.xa."
- All name servers respond with the same MX RRset.
- The MX RRset is a single MX record.
- The MX record is a Null MX with a non-zero preference.
TLD-EMAIL-DOMAIN
- Zone: "tld-email-domain-zone09." (TLD, dash "-", not dot ".")
- The test zone is a TLD zone.
- All name servers respond with the same MX RRset.
- All MX records are non-Null MX.
ROOT-EMAIL-DOMAIN
- Zone: "." (root zone)
- The test zone is the root zone.
- All name servers respond with the same MX RRset.
- All MX records are non-Null MX.
MX-DATA
- Zone: "mx-data.zone09.xa."
- All name servers respond with the same MX RRset.
- All MX records are non-Null MX.
NULL-MX
- Zone: "null-mx.zone09.xa."
- All name servers respond with the same MX RRset.
- The MX RRset has a single, valid NULL MX.
NO-MX-SLD
- Zone: "no-mx-sld.zone09.xa."
- The test zone is neither root, TLD or under .ARPA.
- All name servers respond with no MX RRset (NODATA).
NO-MX-TLD
- Zone: "no-mx-tld-zone09." (TLD, dash "-", not dot ".")
- The test zone is a TLD.
- All name servers respond with no MX RRset (NODATA).
NO-MX-ARPA
- Zone: "no-mx-arpa.zone09.arpa."
- The test zone is under .ARPA.
- All name servers respond with no MX RRset (NODATA).
Zonemaster Test Case Specifications
Table of contents
- Background
- Mapping the Test Requirements to Test Case
- Elaboration of the test case
- Document hierarchy
- Other documents
- List of Defined Test Cases
Background
This is the collection of Test Case specifications for the Zonemaster project. All the details are in the Master Test Plan.
- The test cases that has been elaborated as Test Case specifications have been defined as a list of test requirements. Each test falls under a specific category.
- The document hierarchy of the Test Case specifications could be found in the Master Test Plan.
Mapping the Test Requirements to Test Case
- Each test level has been separated into a separate directory below this directory.
- Under each test level directory there is a level document (README.md) describing the test level. Links are found below.
- The Test Cases are listed below. The mapping from Test Requirement to Test Case is found in the Test requirements document.
Elaboration of the Test Case
Test cases are written for almost all Test Requirements. There could be the case that a requirement can be implemented by doing more test cases than one, or that several requirements are solved by only one test case.
Document hierarchy
Each Test Level described in Master Test Plan should be linked directly to the correct level document (the README.md in the test level directory). The level documents are found here:
- Address-TP
- Basic-TP
- Connectivity-TP
- Consistency-TP
- DNSSEC-TP
- Delegation-TP
- Nameserver-TP
- Syntax-TP
- Zone-TP
Other documents
The following documents are linked from and used by the Test Case specifications listed in the table below:
- DNS Query and Response Defaults
- Methods common to Test Case Specifications (version 1)
- Methods common to Test Case Specifications (version 2)
- Requirements and normalization of domain names in input
- Severity Level Definitions
The following documents are useful documents when studying the Test Case specifications:
List of Defined Test Cases
Test Plan/Test Case | Test Case Description |
---|---|
Address-TP | |
ADDRESS01 | Name server address must be globally routable |
ADDRESS02 | Reverse DNS entry exists for name server IP address |
ADDRESS03 | Reverse DNS entry matches name server name |
Basic-TP | |
BASIC01 | Check for the parent zone and the zone itself |
BASIC02 | The domain must have at least one working name server |
BASIC03 | The Broken but functional test |
Connectivity-TP | |
CONNECTIVITY01 | UDP connectivity to name servers |
CONNECTIVITY02 | TCP connectivity to name servers |
CONNECTIVITY03 | AS Diversity |
CONNECTIVITY04 | IP Prefix Diversity |
Consistency-TP | |
CONSISTENCY01 | SOA serial number consistency |
CONSISTENCY02 | SOA RNAME consistency |
CONSISTENCY03 | SOA timers consistency |
CONSISTENCY04 | Name server NS consistency |
CONSISTENCY05 | Consistency between glue and authoritative data |
CONSISTENCY06 | SOA MNAME consistency |
DNSSEC-TP | |
DNSSEC01 | Legal values for the DS hash digest algorithm |
DNSSEC02 | DS must match a valid DNSKEY in the child zone |
DNSSEC03 | Verify NSEC3 parameters |
DNSSEC04 | Check for too short or too long RRSIG lifetimes |
DNSSEC05 | Check for invalid DNSKEY algorithms |
DNSSEC06 | Verify DNSSEC additional processing |
DNSSEC07 | If DNSKEY at child, parent should have DS |
DNSSEC08 | Valid RRSIG for DNSKEY |
DNSSEC09 | RRSIG(SOA) must be valid and created by a valid DNSKEY |
DNSSEC10 | Zone contains NSEC or NSEC3 records |
DNSSEC11 | DS in delegation requires signed zone |
DNSSEC12 | Test for DNSSEC Algorithm Completeness |
DNSSEC13 | All DNSKEY algorithms used to sign the zone |
DNSSEC14 | Check for valid RSA DNSKEY key size |
DNSSEC15 | Existence of CDS and CDNSKEY |
DNSSEC16 | Validate CDS |
DNSSEC17 | Validate CDNSKEY |
DNSSEC18 | Validate trust from DS to CDS and CDNSKEY |
Delegation-TP | |
DELEGATION01 | Minimum number of name servers |
DELEGATION02 | Name servers must have distinct IP addresses |
DELEGATION03 | No truncation of referrals |
DELEGATION04 | Name server is authoritative |
DELEGATION05 | Name server must not point at CNAME alias |
DELEGATION06 | Existence of SOA |
DELEGATION07 | Parent glue name records present in child |
Nameserver-TP | |
NAMESERVER01 | A name server should not be a recursor |
NAMESERVER02 | Test of EDNS0 support |
NAMESERVER03 | Test availability of zone transfer (AXFR) |
NAMESERVER04 | Same source address |
NAMESERVER05 | Behaviour against AAAA query |
NAMESERVER06 | NS can be resolved |
NAMESERVER07 | To check whether authoritative name servers return an upward referral |
NAMESERVER08 | Testing QNAME case insensitivity |
NAMESERVER09 | Testing QNAME case sensitivity |
NAMESERVER10 | Test for undefined EDNS version |
NAMESERVER11 | Test for unknown EDNS OPTION-CODE |
NAMESERVER12 | Test for unknown EDNS flags |
NAMESERVER13 | Test for truncated response on EDNS query |
NAMESERVER15 | Checking for revealed software version |
Syntax-TP | |
SYNTAX01 | No illegal characters in the domain name |
SYNTAX02 | No hyphen ('-') at the start or end of the domain name |
SYNTAX03 | There must be no double hyphen ('--') in position 3 and 4 of the domain name |
SYNTAX04 | The NS name must have a valid domain/hostname |
SYNTAX05 | Misuse of '@' character in the SOA RNAME field |
SYNTAX06 | No illegal characters in the SOA RNAME field |
SYNTAX07 | No illegal characters in the SOA MNAME field |
SYNTAX08 | MX name must have a valid hostname |
Zone-TP | |
ZONE01 | Fully qualified master nameserver in SOA |
ZONE02 | SOA 'refresh' minimum value |
ZONE03 | SOA 'retry' lower than 'refresh' |
ZONE04 | SOA 'retry' at least 1 hour |
ZONE05 | SOA 'expire' minimum value |
ZONE06 | SOA 'minimum' maximum value |
ZONE07 | SOA master is not an alias |
ZONE08 | MX is not an alias |
ZONE09 | MX record present |
ZONE10 | No multiple SOA records |
ZONE11 | SPF policy validation |
Zonemaster Master Test Plan
Introduction
This section gives a brief introduction to Zonemaster.
Background
DNSCheck from IIS and Zonecheck from AFNIC were two different software packages that do DNS validation of the quality of a DNS delegation. The Zonemaster implementation is a major rewrite of these software packages, and implement the best parts of both.
Purpose
The purpose of Zonemaster is to test the quality of a DNS delegation. The core of the software is all the implemented tests. There is a command line tool to run a complete set of tests, and a web interface tailored for use by both basic and advanced users.
Goals
The goal of this document is to give an overview of the requirements and the test levels. Each of the requirements will be broken down into a set of test procedures. The process of doing this will be done in accordance with the standard IEEE 829-2008.
The test requirements are all documented in the Test Requirements document.
Scope
The Test Requirements document is the base directive on what test specifications implement.
References
External
References to external documents are found in the Test Requirements document.
Internal
No internal requirements.
Document hierarchy
- Master Test Plan
- Basic Test Plan
- Test Case x
- Delegation Test Plan
- Test Case x
- Consistency Test Plan
- Test Case x
- DNSSEC Test Plan
- Test Case x
- Address Test Plan
- Test Case x
- Name Server Test Plan
- Test Case x
- Connectivity Test Plan
- Test Case x
- Zone Test Plan
- Test Case x
- Syntax Test Plan
- Test Case x
- Basic Test Plan
System overview and key features
A domain will be tested for the quality of the delegation in the DNS hierarchy. Some of the high level properties that will be tested include:
- Basic (initial tests)
- Delegation properties (parent and child name servers)
- Consistency (all names have consistent answers)
- DNSSEC properties (algorithms, secure delegation)
- Address properties (IP addresses)
- Name server properties
- Name server Connectivity
- Zone properties (are data controlling the zone sane)
- Syntax (illegal hostnames and characters)
A domain can be given to the testing system and all DNS information will be retrieved from the public global DNS hierarchy, or a set of pre-delegation data can be given to test a domain not yet published in the global DNS hierarchy. A complete set of DNS queries and answers can also be given as the input to the system for repeat testing.
Test overview
The test organization, test schedule, integrity level scheme, test resources, responsibilities, tools, techniques, and methods are necessary to perform the testing.
Organization
A test is run on any machine where the Zonemaster software is available. The tests ordinarily needs access to a complete DNS hierarchy to be performed.
Master test schedule
A test is run as soon as the software is scheduled to run, often immediately upon execution.
The first tests that are supposed to run are those from the Basic test plan. If those tests succeeds, the rest of the test plans are run in no specific order.
Integrity level schema
An integrity level schema is used for illustrating relative importance of a software component. The effect of a failing component can range from negligible to catastrophic. A component with a high integrity level needs to be tested more thoroughly than a component with a lower level. There is, however, no guidance in the requirements that indicate the relative importance of different areas. Each area is thus considered equally important. However, one of the main objectives is to ensure the stability of DNS.
Resources summary
TODO: Briefly describe the necessary resources to run a test.
Responsibilities
Tools, techniques, methods, and metrics
TODO: Briefly described the necessary input and any metrics in the output.
Details of the Master Test Plan
The utilization of the IEEE 829-2008 is described in this chapter. There is also a mapping between the test areas and the requirements.
Test processes
The goal of these documents is to describe the test cases and how the DNS is tested. This is a part of a larger project where the goal is to test the quality of the Internet. Processes for Management, Acquisition, Supply, Development, Operation, and Maintenance are not part of this subproject to define.
Definition of test levels
There can be different types of tests, e.g. unit, system, and acceptance tests. This test environment will only focus on compliance testing for DNS, thus only one test level. Multiple areas have however been identified within the system requirements:
- Basic
- Delegation
- Consistency
- DNSSEC
- Address
- Name server
- Connectivity
- Zone
- Syntax
The separation of test levels does not necessarily mean that the levels are fully separated in the Zonemaster implementation. At this level, the separation is done to make a better overview of all the test cases specified.
Test documentation requirements
The following documents can be created according to the standard:
- Level Test Plan (LTP)
- Level Test Design (LTD)
- Level Test Case (LTC)
- Level Test Procedure (LTPr)
However, the LTD has been incorporated in the LTP and in the LTC. LTPr has been incorporated in the LTC.
Level Test Plan
The system will undergo acceptance testing against the requirements. Each area is documented in a separate test plan. The purpose is to map the requirements into test cases and also to describe the approach for testing this level.
In the title of the plan, the word “Level” is replaced by the name for the particular level being documented by the plan. E.g. Delegation Test Plan and DNSSEC Test Plan.
Level Test Case
The purpose of the LTC is to define the information needed as it pertains to inputs to and outputs from the software or software-based system being tested. The test cases may be documented in a single or multiple LTC depending on the extent of the area. Any procedures are included in the documentation.
In the title of the test case, the word “Level” is replaced by the name for the particular level being documented by the test case. The documents have sub-titles since there can be more than one document within one level. E.g. DNSSEC Test Cases or Connectivity Test Cases.
Test administration requirements
These activities are needed to administer the tests during execution.
Anomaly Resolution
The tests are executed with the input given by the user. The input data is validated to be correct. Depending on the input data and what is available in the public DNS, some test cases might not be executed.
The output from Zonemaster should clearly indicate what test cases have been executed, and which have not.
Reporting Processes
The output from all the tests are collected by the system and reported back to the user depending on the choice of the user. There might be several different methods used, for example as a brief or verbose log file, or as XML or JSON output, or directly into a database.
Test reporting requirements
The following documents can be created according to the standard:
- Level Test Log (LTL)
- Anomaly Report (AR)
- Level Interim Test Status Report (LITSR)
- Level Test Report (LTR)
- Master Test Report (MTR)
Only an MTR will be generated by the system.
Level Test Log
All logs from each test level are aggregated into the Master Test Report.
Anomaly Report
An Anomaly Report is created if the result from the test is not conclusive due to internal or external anomalies. All anomalies are in the Master Test Report. However, the software implementation will also report any anomalies with a different return code, so any calling software can determine if the test cases were executed as planned, or if any anomaly stopped the execution prematurely.
Master Test Report
The Master Test Report is generated continually during the execution of the test plan. It will indicate the result of all the test cases, and depending on any selected verbosity also down to the level where you can see all the DNS queries and replies in a preferred data format.
TODO: make a better description of the log files here?
System requirements
The requirements are found in Test Requirements document.
RFCs
Where it is possible, the test cases refer to any RFCs describing what the current IETF standards advise on the implementation of the DNS protocol.
General
This section contains the glossary and document change procedures for all of the test plans and test cases.
Glossary
Word / Acronym | Explanation |
---|---|
DNS | Domain Name System |
DNSSEC | DNS Security Extensions |
RFC | Request for Comments, IETF document |
MTP | Master Test Plan |
MTR | Master Test Report |
LTC | Level Test Case |
LTL | Level Test Log |
LTP | Level Test Plan |
LTR | Level Test Report |
AR | Anomaly Report |
Definitions of Terms
Since there are some terms relating to DNS that are commonly used with unclear or multiple meanings, we will define here exactly what we mean when we use them in the context of these specifications and these tests. Any uncommon or special terms we use will also be defined here.
Child Domain or Child Zone is the domain or zone being tested.
Parent Domain is the domain or zone that delegates directly to the domain being tested. Differently put, it is the domain whose nameservers delivers the glue records for the child domain.
Glue Name Records are defined as all NS records pertaining to the child domain that are delivered by the nameservers for the parent domain.
Glue Address Records are all A or AAAA records pertaining to the child domain that are delivered by the nameservers for the parent domain
In bailiwick means that nameservers for a domain is in the same domain (within the domain). i.e for 'domain.com', nameserver is ns.domain.com and not ns.domain.net nor ns.otherdomain.org
Out of bailiwick The term out-of-bailiwick means that nameservers for a domain is not in the same domain. ie for 'domain.com' nameserver is ns.domain.net or ns.otherdomain.org etc.
Document change procedures
The overall change procedures are defined by the project and the change management. However, there are some steps to take into consideration when changing the test documents.
Identifying
A change to the documents may be initiated because of several reasons:
- New internal or external requirements
- Problems with the test cases
- Text that needs to be clarified
- Etc.
Implementing
The document versioning is managed by a version control system (Git). Each change must contain a specific commit message detailing the change. The major revisions section of this document should also be updated if there is a new release of the document.
It is important that the outcome of the test cases stays the same; unless the change was based on new or updated requirements.
Recording changes
An overall description must be stated in the document control chapter, including a new revision number. A more detailed description of the changes is part of the specific commit in the version control system.
Approving
The technical review team must approve any changes made to the test cases.
Methods common to Test Case Specifications (version 1)
This is a list of generic Methods used in many Test Case specifications. The Test Cases that makes use of any of these Methods should link directly to this text.
This document holds version 1 of the set of Methods. Version 2 is defined in MethodsV2. Methods from version 1 will be replaced by Methods from version 2 in all Test Case specifications.
Before the transition all Test Cases specifications use version 1 (this document). During the transition it will be stated in each specification if the Test Case uses Methods from version 1 (this document) or Methods from version 2 (MethodsV2). When the transition is completed, this document will be removed.
Method 1: Obtain the parent domain
This Method tries to obtain the parent domain from the domain used as input to this Method.
- A recursive SOA-record lookup for the child domain name starting at the root domain should be done, and the steps of the process recorded.
- If the recursion reaches a name server that responds with a redirect directly to the requested domain, including functional glue, the test succeeds. The domain through which the name server was found is considered the parent domain.
- If the recursion reaches a name server that authoritatively responds with NXDOMAIN for the child domain, the test succeeds. The domain through which the name server was found is considered the parent domain.
Method 2: Obtain "glue Name records" from parent
This Method tries to obtain the authoritative name servers from the delegation of the parent domain.
- Obtain the parent domain as input from Method 1.
- Send a query to the parent domain asking for the list of name servers authoritative for the domain that is being tested
- Record the list of name servers obtained from the authority section
Method 3: Obtain name servers from child
Just as in Method 2, this Method tries to obtain the name servers configured for the child zone from the child domain itself.
- A NS query for the domain is made to all listed name servers obtained from Method 2.
- Record all the unique name servers from the answers received from the query in step 1.
Method 4: Obtain "glue address records" from parent
This Method tries to obtain any glue address records from the delegation in the parent zone.
- Query the servers in Method 2 for A and AAAA addresses.
- Record the unique IP addresses from the answers (both A and AAAA) in the additional section, which are the glue address records for the domain.
Method 5: Obtain the name server address records from child
This Method tries to obtain the IP addresses for the name servers used in the child zone.
- Send an A query to all name servers obtained in Method 3.
- Record the list of unique IPv4 addresses in the answer section.
- Send an AAAA query to all name servers obtained in Method 3.
- Record the list of unique IPv6 addresses in the answer section.
Methods common to Test Case Specifications (version 2)
Table of contents
- Objective
- Scope
- Internal Methods
- Methods Inputs
- Method: Get parent NS IP addresses
- Method: Get delegation NS names and IP addresses
- Method: Get delegation NS names
- Method: Get delegation NS IP addresses
- Method: Get zone NS names
- Method: Get zone NS names and IP addresses
- Method: Get zone NS IP addresses
- Method: Get delegation (Internal)
- Method: Get in-bailiwick address records in zone (Internal)
- Method: Get out-of-bailiwick ip addresses (Internal)
- Method inter-dependencies
- Terminology
Objective
The Methods are used in, and referred from, the Test Case specifications as shortcuts for steps shared between Test Cases. A Test Case that makes use of any of the Methods defined in this document must refer directly to the specific Method or Methods.
Scope
This document holds version 2 of the set of Methods. Version 1 is defined in Methods. Methods from version 1 will be replaced by Methods from version 2 in all Test Case specifications.
Before the transition all Test Cases specifications use version 1 (Methods). During the transition it will be stated in each specification if the Test Case uses Methods from version 1 (Methods) or Methods from version 2 (this document). When the transition is completed, the version 1 document will be removed.
In these Methods any DS record data in Undelegated Data is disregarded. If with Child Zone DS record data is provided, but no name server data, then the will here be treated as "normal test", not "undelegated test".
Internal methods
Methods, in this document, that are referred to as Internal or Internal Method must not be referred to from the Test Case specifications. Internal Methods may only be referred to from Methods in this document. Test Case specifications can freely refer to the other Methods.
Methods Inputs
The following input units are provided when a Method is executed and are available to all Methods. All Methods, however, do not use all input units and it is specified in the Method inputs subsections which units are used for the specific Method.
- "Child Zone" - Mandatory data. The name of the zone to be tested. It must be a valid domain name.
- "Root Name Servers" - The default data is the IANA Root Hints File with names and IP addresses of the root name servers, but that can optionally be replaced by equivalent information to a private root zone. It must contain at least one valid name server name with at least one valid IP address.
- "Undelegated Data" - Optional data. If included it must consist of a set of at least one valid name server name and for each name server name an optional set of at least one valid IP address. The name servers and IP addresses represent a possible delegation of Child Zone from its parent zone (may be indetermined).
- "Test Type" - Derived data. It is set to "normal test" if Undelegated Data is absent (empty) and to "undelegated test" if it is non-empty.
Method: Get parent NS IP addresses
Method identifier
Get-Parent-NS-IP
Objective
This Method will obtain the name servers that serves the parent zone, i.e. the zone from which the Child Zone is delegated from.
This is done by finding the parent zone and then the name servers that serve the parent zone. In case there is an inconsistency of which is the parent zone, the list of name servers will be the gross list, i.e. rather include too much than too little. Too much is always a result of incorrect configuration in the parent zone or in a grand parent zone.
If Child Zone is the root zone, then there is by definition no parent zone and no parent name servers.
If the test type is undelegated, then the information that the parent name servers are supposed to provide included in the input data. In that case a list of parent name servers has no meaning.
The Method will output a list of parent name server IP addresses. If the zone is the root zone or if the test is an undelegated test, the list is defined but empty. If the parent zone cannot be determined, then an undefined list is returned.
Addresses for name servers (RDATA of NS records) are extracted even if the resolution goes through CNAME. It is, however, not permitted for a NS record to point at a name that has a CNAME, but that test is covered by Test Case Delegation05. This method should extract as much as possible to find all possible paths.
This Method must, in general, use the same algorithm as Test Case Basic01, but the test case extracts more information and outputs messages.
Inputs
This Method uses the following input units defined in section Methods Inputs:
- "Child Zone" - The name of the child zone to be tested.
- "Root Name Servers"
- "Test Type" - "undelegated test" or "normal test".
Procedures
-
If the Child Zone is the root zone (".") then output empty set and exit these procedures.
-
If the Test Type is "undelegated test" then output empty set and exit these procedures.
-
Create the following empty sets:
- Name server IP and zone name ("Remaining Servers").
- Name server IP and query name ("Handled Servers").
- Parent name server IP addresses ("Parent NS IP").
-
Insert all addresses from Root Name Servers and the root zone name into the Remaining Servers set.
In the loop below, the steps tries to capture the name of the parent zone of Child Zone and the IP addresses of the name servers for that parent zone. This is done using a modified version of the "QNAME minimization" technique RFC 9156. SOA is the query type used for traversing the tree.
-
While the Remaining Servers is non-empty pick next name server IP address and zone name from the set ("Server Address" and "Zone Name") and do:
-
Extract and remove Server Address including its Zone Name from Remaining Servers.
-
Insert Server Address and Zone Name into Handled Servers.
-
Create DNS queries:
- Query type SOA and query name Zone Name ("Zone Name SOA Query").
- Query type NS and query name Zone Name ("Zone Name NS Query").
-
Send Zone Name SOA Query to Server Address.
-
Go to next server in Remaining Servers if one or more of the following matches:
- No DNS response.
- RCODE Name different from NoError in response.
- AA bit not set in response.
- Not exactly one SOA record in answer section
- Owner name of SOA record is not Zone Name.
-
Send Zone Name NS Query to Server Address.
-
Go to next server in Remaining Servers if one or more of the following matches:
- No DNS response.
- RCODE Name different from NoError in response.
- AA bit not set in response.
- No NS records in answer section
- Owner name of any of the NS records is not Zone Name.
-
Extract the name server names from the NS records and any address records in the additional section.
-
Do DNS Lookup of name server names (A and AAAA) not already listed in the additional section of the response. Follow CNAME if provided.
- For each IP address add the IP address and Zone Name to the Remaining Servers set unless the IP address is already listed in Handled Servers together with Zone Name.
- Ignore any failing lookups or lookups resulting in NODATA or NXDOMAIN.
-
Create "Intermediate Query Name" by copying Zone name as start value.
-
Run a loop processing Server Address (jumps back here from the steps below).
- Extend Intermediate Query Name by adding one more label to the left by copying the equivalent label from Child Zone. (See "Example 1" below.)
- Create a DNS Query with query name Intermediate Query Name and query type SOA ("Intermediate SOA query").
- Send Intermediate SOA Query to Server Address. (See "Example 2" below.)
- Go to next server in Remaining Servers if there is no DNS response.
- If the response has exactly one SOA record with owner name
Intermediate Query Name in the answer section, with the AA bit
set and RCODE Name NoError then do:
- If Intermediate Query Name is equal to Child Zone then
- Save Server Address to the Parent NS IP set.
- Go to next server in Remaining Servers.
- Else do:
- Create a DNS query with query name Intermediate Query Name and query type NS ("Intermediate NS query").
- Send Intermediate NS Query to Server Address.
- Go to next server in Remaining Servers if one or more of the
following matches:
- No DNS response.
- RCODE Name different from NoError in response.
- AA bit not set in response.
- No NS records in answer section.
- Owner name of any of the NS records is not Intermediate Query Name.
- Extract the name server names from the NS records and any address records in the additional section.
- Do DNS Lookup of name server names (A and AAAA) not already listed in the additional section of the response. Follow CNAME if provided.
- For each IP address add the IP address and Intermediate Query Name to the Remaining Servers set unless the IP address is already listed in Handled Servers together with Intermediate Query Name.
- Set Zone Name to Intermediate Query Name.
- Go back to the start of the loop.
- If Intermediate Query Name is equal to Child Zone then
- Else, if the response contains a Referral of Intermediate Query Name
then do:
- If Intermediate Query Name is equal to Child Zone then do:
- Save Server Address to the Parent NS IP set.
- Else do:
- Extract the name server names from the NS records and any glue records.
- Do DNS Lookup of name server names (A and AAAA) not already listed as glue record or records. Follow CNAME if provided.
- For each IP address add Server Address and Intermediate Query Name to the Remaining Servers set unless Server Address is already listed in Handled Servers together with Intermediate Query Name.
- Go to next server in Remaining Servers.
- If Intermediate Query Name is equal to Child Zone then do:
- Else, if the RCODE Name is NoError and the AA is set then do:
- If Intermediate Query Name is not equal to Child Zone then go back to the start of the loop.
- Else go to next server in Remaining Servers.
- Else, go to next server in Remaining Servers.
-
Examples referred to from the steps.
Example 1: If Child Zone is "foo.bar.xa" and Intermediate Query Name is "." (root zone) then Intermediate Query Name becomes "xa". If it is "xa", it will become "bar.xa" instead.
Example 2: An "bar.xa SOA" query to a name server for "xa".
-
If the Parent NS IP set is non-empty then do:
- Extract the list of name server IP addresses.
- Return the following from the Method:
- The extracted list of name server IP addresses (parent zone name servers).
- Exit these procedures.
-
If the Parent NS IP set is empty then do:
- Return the following from the Method:
- Undefined value. (Parent name severs cannot be determined.)
- Exit these procedures.
- Return the following from the Method:
Outputs
- A set of name server IP address for the parent zone:
- Non-empty set: The name servers have been identified.
- Empty set: Root zone or undelegated test.
- Undefined set: The name servers cannot be determined due to errors in the delegation.
Dependencies
None.
Method: Get delegation NS names and IP addresses
Method identifier
Get-Del-NS-Names-and-IPs
Objective
Obtain the name server names (from the NS records) and the IP addresses (from Glue Records) from the delegation of the given zone (child zone) from the parent zone. Glue Records, if any, are address records for name server names. Also obtain the IP addresses for the Out-Of-Bailiwick name server names, if any. If the Glue Records include address records for Out-Of-Bailiwick name servers they will be included twice, unless identical.
Inputs
This Method uses the following input units defined in section Methods Inputs:
- "Child Zone" - The name of the child zone to be tested.
Procedures
-
Get the set of name servers where each unique name server name is linked to a possibly empty set of its IP addresses by using Method Get-Delegation ("Name Servers").
-
If the Name Servers set is undefined, then output an undefined set and exit these procedures.
-
If the Name Servers set is empty, then output an empty set and exit these procedures.
-
Extract the set of Out-Of-Bailiwick name server names from Name Servers ("OOB Names").
-
Get the IP addresses for name server names in OOB Names by using Method Get-OOB-IPs with OOB Names as input.
-
Merge the set returned from Get-OOB-IPs with Name Servers.
-
Output the Name Servers set.
Outputs
- A set of delegation name servers, where each unique name server name
links to a possibly empty set of its IP addresses:
- Non-empty set: The normal case.
- Empty set: Get-Delegation returned an empty set.
- Undefined set: Get-Delegation returned an undefined set.
Dependencies
This Method depends on Get-Delegation and Get-OOB-IPs.
Method: Get delegation NS names
Method identifier
Get-Del-NS-Names
Objective
In general, this Method replaces Method2 in Methods, version 1.
Obtain the name server names for Child Zone as defined in the delegation from parent zone.
Inputs
This Method uses the following input units defined in section Methods Inputs:
- "Child Zone" - The name of the child zone to be tested.
Procedures
-
Get the set of name servers where each unique name server name is linked to a possibly empty set of its IP addresses by using Method Get-Del-NS-Names-and-IPs ("Name Servers").
-
If the Name Servers set is undefined, then output an undefined set and exit these procedures.
-
If the Name Servers set is empty, then output an empty set and exit these procedures.
-
If the set is empty, then output an empty set and exit these test procedures.
-
Extract the set of name server names from Name Servers.
-
Output the set of name server names.
Outputs
- The set of delegation name server names:
- Non-empty set: The normal case.
- Empty set: Get-Del-NS-Names-and-IPs returned an empty set.
- Undefined set: Get-Del-NS-Names-and-IPs returned an undefined set.
Dependencies
This Method depends on Get-Del-NS-Names-and-IPs.
Method: Get delegation NS IP addresses
Method identifier
Get-Del-NS-IPs
Objective
In general, this Method replaces Method4 in Methods, version 1.
Obtain the IP addresses (from Glue Records) from the delegation of the given zone (child zone) from the parent zone. Glue Records are address records for In-Bailiwick name server names, if any. Obtain the IP addresses for the Out-Of-Bailiwick name server names, if any.
Inputs
This Method uses the following input units defined in section Methods Inputs:
- "Child Zone" - The name of the child zone to be tested.
Procedures
-
Get the set of name servers where each unique name server name is linked to a possibly empty set of its IP addresses by using Method Get-Del-NS-Names-and-IPs ("Name Servers").
-
If the Name Servers set is undefined, then output an undefined set and exit these procedures.
-
If the Name Servers set is empty, then output an empty set and exit these procedures.
-
Extract the IP addresses from Name Servers and create a set of unique addresses ("NS IPs").
-
Output the NS IPs set.
Outputs
- The set of delegation name server IP addresses:
- Non-empty set: The normal case.
- Empty set: Get-Del-NS-Names-and-IPs returned an empty set.
- Undefined set: Get-Del-NS-Names-and-IPs returned an undefined set.
Dependencies
This Method depends on Get-Del-NS-Names-and-IPs.
Method: Get zone NS names
Method identifier
Get-Zone-NS-Names
Objective
In general, this Method replaces Method3 in Methods, version 1.
Obtain the names of the authoritative name servers for the given zone (child zone) as defined in the NS records in the zone itself.
Inputs
This Method uses the following input units defined in section Methods Inputs:
- "Child Zone" - The name of the child zone to be tested.
Procedures
-
Using Method Get-Del-NS-IPs, obtain the IP addresses of the name servers ("Name Server IPs").
-
If the Name Server IPs set is undefined, then output an undefined set and exit these procedures.
-
If the Name Server IPs set is empty, then output an empty set and exit these procedures.
-
Create an empty set of name server names ("Name Server Names").
-
Create a DNS Query with query type NS and query name Child Zone ("NS Query").
-
Send NS Query to every IP address in Name Server IPs.
-
Collect all DNS Responses and ignore all non-responses.
-
Collect all the unique NS records with Child Zone as owner name in the answer sections of the responses where the AA flag is set. Ignore any other response.
-
Extract the name server names from the RDATA of the NS records and add them to the Name Server Names set.
-
Output the possibly empty Name Server Names set.
Outputs
- The set of zone name servers (name server names):
- Non-empty set: The normal case.
- Empty set: Get-Del-NS-IPs returned an empty set or no name server names were found.
- Undefined set: Get-Del-NS-IPs returned an undefined set.
Dependencies
This Method depends on Get-Del-NS-IPs.
Method: Get zone NS names and IP addresses
Method identifier
Get-Zone-NS-Names-and-IPs
Objective
Obtain the name server names (extracted from the NS records) from the apex of the child zone. For In-Bailiwick name server names obtain the IP addresses from the child zone. For the Out-Of-Bailiwick name server names obtain the IP addresses from resolver lookup.
Inputs
This Method uses the following input units defined in section Methods Inputs:
- "Child Zone" - The name of the child zone to be tested.
Procedures
-
Get the name server names for the Child Zone as defined in the Child Zone by using Method Get-Zone-NS-Names ("Names").
-
If the Names set is undefined, then output an undefined set and exit these procedures.
-
If the Names set is empty, then output an empty set and exit these procedures.
-
Create a set of name servers where each unique name server name in Names is linked to an empty set of IP addresses ("Name Servers").
-
Fetch the IP addresses for any In-Bailiwick name server names in Names by using Method Get-IB-Addr-in-Zone.
-
Add each fetched IP address, if any, to Name Servers to the name server name it belongs to.
-
Extract the set of Out-Of-Bailiwick name server names from Names ("OOB Names").
-
Get the IP addresses for name server names in OOB Names by using Method Get-OOB-IPs with OOB Names as input.
-
Merge the set returned from Get-OOB-IPs with Name Servers.
-
Output the Name Servers set.
Outputs
- The set of zone name servers, where each unique name server name links to a
possibly empty set of its IP addresses:
- Non-empty set: The normal case.
- Empty set: Get-Zone-NS-Names returned an empty set.
- Undefined set: Get-Zone-NS-Names returned an undefined set.
Dependencies
This Method depends on Methods Get-Zone-NS-Names, Get-IB-Addr-in-Zone and Get-OOB-IPs.
Method: Get zone NS IP addresses
Method identifier
Get-Zone-NS-IPs
Objective
In general, this Method replaces Method5 in Methods, version 1.
Obtain the IP addresses of the name servers, as extracted from the NS records of apex of the child zone.
Inputs
This Method uses the following input units defined in section Methods Inputs:
- "Child Zone" - The name of the child zone to be tested.
Procedures
-
Get the name servers set where each unique name server name is linked to a possibly empty set of its IP addresses by using Method Get-Zone-NS-Names-and-IPs ("Name Servers");
-
If the Name Servers set is undefined, then output an undefined set and exit these procedures.
-
If the Name Servers set is empty, then output an empty set and exit these procedures.
-
Extract the IP addresses from Name Servers and create a set of unique IP addresses.
-
Output the set of IP addresses.
Outputs
- The set of zone name server IP addresses:
- Non-empty set: The normal case.
- Empty set: Get-Zone-NS-Names-and-IPs returned an empty set.
- Undefined set: Get-Zone-NS-Names-and-IPs returned an undefined set.
Dependencies
This Method depends on Method Get-Zone-NS-Names-and-IPs.
Method: Get delegation (Internal)
Method identifier
Get-Delegation
Objective
Obtain the name server names (from the NS records) and the IP addresses (from Glue Records) from the delegation of the given zone (child zone) from the parent zone. Glue Records are address records for In-Bailiwick name server names, if any. Extract addresses even if the resolution goes through CNAME. It is, however, not permitted for a NS record to point at a name that has a CNAME, but that test is covered by Test Case Delegation05.
IP addresses for Out-Of-Bailiwick name server names are not extracted with this Method. To get those use Method Get-Del-NS-IPs or Method Get-Del-NS-Names-and-IPs.
This is an Internal Method that can be referred to by other Methods in this document, but not by Test Case specifications.
Inputs
This Method uses the following input units defined in section Methods Inputs:
- "Child Zone" - The name of the child zone to be tested.
- "Root Name Servers"
- "Undelegated Data" - The name servers and IP addresses representing a possible delegation of Child Zone.
- "Test Type" - "undelegated test" or "normal test".
Procedures
-
If the Test Type is "undelegated test", then:
- Use Undelegated Data.
- Create an empty set of name servers where each unique name server name is linked to an empty set of IP addresses ("Name Servers").
- Extract all name server names from the Undelegated Data set and add to the Name Servers set.
- For each In-Bailiwick name server name collect any IP addresses from Undelegated Data and add that to the Name Servers set under the name server name.
- For any Out-Of-Bailiwick name server name the IP address should be ignored.
- Output the Name Servers set.
- Exit these procedures.
-
If Child Zone is the root zone ".", then output the set of name server names and IP addresses from Root Name Servers and exit these procedures.
-
Using Method Get-Parent-NS-IP extract the name server IP addresses for the parent zone ("Parent NS").
-
If Parent NS is empty, then output the undefined set and exit these test procedures.
-
Create DNS Query with query type NS and query name Child Zone ("NS Query").
-
Create empty sets:
- Unique name server names where each name can be linked to a possibly empty set of IP addresses ("Delegation Name Servers").
- Unique name server names where each name can be linked to a possibly empty set of IP addresses ("AA Name Servers").
-
For each parent name server in Parent NS do:
- Send NS query to to the parent name server.
- Go to next parent name server if:
- Does not respond at all, or
- Responds with an invalid DNS response, or
- Responds with an RCODE Name besides NoError.
- If the DNS Response is a Referral to the Child Zone:
- Extract the name server names from the RDATA of the NS records in the authority section.
- Extract any A or AAAA record from the additional section if the owner name is an In-Bailiwick name server name matching an NS record from the same response.
- Update Delegation Name Servers with unique name server names and with
a possibly empty set of IP addresses.
- If the name already exists in the set and additional IP addresses exists, add those to the name in the set.
- If the DNS response has the AA bit set and the answer section contains
the NS record of the Child Zone do:
- Extract the name server names from the RDATA of the NS records.
- Extract any A or AAAA record from the additional section if the owner name is an In-Bailiwick name server name matching an NS record from the same response.
- Update AA Name Servers with unique name server names and with
a possibly empty set of IP addresses.
- If the name already exists in the set and additional IP addresses exists, add those to the name in the set.
- If any In-Bailiwick name server name from the NS records lacks IP
address, then:
- Send two DNS Queries with that name server name as query name to the parent name server, query type A and AAAA, respectively.
- If the DNS Response is a Referral to a sub-zone of Child Zone, follow that delegation, possibly in several steps, by repeating the A and AAAA queries.
- If a CNAME is returned, follow that, possibly in several steps, to resolve the name to IP addresses, if possible.
- Update AA Name Servers with captured IP addresses, if any.
-
If the Delegation Name Servers set is non-empty output that and exit these procedures.
-
Else, if the AA Name Servers set is non-empty output that and exit these procedures.
-
Else, if both Delegation Name Servers and AA Name Servers sets are empty then output an empty set.
Outputs
- The set of name servers, the delegation, where each unique name server name
links to a possibly empty set of its IP addresses:
- Non-empty set: The normal case.
- Empty set: No delegation was found.
- Undefined set: Get-Parent-NS-IP returned undefined set of parent name server IPs.
Dependencies
This Method depends on the output from Get-Parent-NS-IP if test type is a "normal test".
Method: Get in-bailiwick address records in zone (Internal)
Method identifier
Get-IB-Addr-in-Zone
Objective
From the child zone, obtain the address records matching the In-Bailiwick name server names found in the zone itself. Extract addresses even if the resolution goes through CNAME. It is, however, not permitted for a NS record to point at a name that has a CNAME, but that test is covered by Test Case Delegation05.
This is an Internal Method that can be referred to by other Methods in this document, but not by Test Case specifications.
Inputs
This Method uses the following input units defined in section Methods Inputs:
- "Child Zone" - The name of the child zone to be tested.
Procedures
-
Using Method Get-Del-NS-IPs, obtain the IP addresses to the name servers ("Name Server IPs").
-
Using Method Get-Zone-NS-Names, obtain the names of the name servers from the Child Zone ("Child Zone Name Server Names").
-
If the Name Server IPs set or the Child Zone Name Server Names set is empty or undefined, then output an undefined set and exit these test procedures.
-
If no name in Child Zone Name Server Names is an In-Bailiwick name server name:
- Output an empty set.
- Exit these procedures.
-
Create an empty set the In-Bailiwick name server names from the Child Zone Name Server Names set, where each name is linked to an empty set of IP addresses ("Name Servers").
-
For name in Name Servers do:
- Create the following two DNS queries:
- Query type A and the In-Bailiwick name as the query name ("A Query").
- Query type AAAA and the In-Bailiwick name as the query name ("AAAA Query").
- Send A Query and AAAA Query to all servers in Name Server IPs and process the DNS Responses from each of them.
- If a Referral to a sub-zone of Child Zone is returned, follow that delegation, possibly in several steps, by repeating A Query and AAAA Query.
- If a CNAME is returned, follow that, possibly in several steps, to resolve the name to IP addresses, if possible.
- Ignore non-referral responses [see Referral unless AA flag is set (cached data is not accepted) and ignore response with any other RCODE Name than NoError.
- Add found IP addresses for the name server names in Name Servers.
- Create the following two DNS queries:
-
Output the possibly empty Name Servers set.
Outputs
- A set of name server names pointing at possibly empty sets of IP addresses:
- Non-empty set: The normal case.
- Empty set: There are no In-Bailiwick names or those are not defined in Child Zone, also a normal case.
- Undefined set: Get-Del-NS-IPs returned an empty or undefined set.
Dependencies
This Method depends on Get-Zone-NS-Names and Get-Del-NS-IPs.
Method: Get out-of-bailiwick ip addresses (Internal)
Method identifier
Get-OOB-IPs
Objective
Obtain the IP addresses of the Out-Of-Bailiwick name servers for the given zone (child zone) and a given set of name server names.
Extract addresses even if the resolution goes through CNAME, here ignoring that it is not permitted for a NS record to point at a name that has a CNAME record. See Test Case Delegation05 for a test of NS records pointing at names that holds CNAME records.
This is an Internal Method that can be referred to by other Methods in this document, but not by Test Case specifications.
Inputs
This Method uses the following input units defined in section Methods Inputs:
- "Child Zone" - The name of the child zone to be tested.
- "Undelegated Data" - The name servers and IP addresses representing a possible delegation of Child Zone.
- "Test Type" - "undelegated test" or "normal test".
This Method also used the following input unit from the calling Method:
- "NS Set" - Name servers names to be looked up.
Procedures
-
If NS Set is empty then output an empty set and exit these procedures.
-
Create a set of name servers where each unique name server name in NS Set is linked to an empty set of IP addresses ("Name Servers").
-
For each name server name ("Name") in NS Set do:
-
If Test Type is "undelegated test" and if the Name has IP address specification (IPv4 or IPv6) in Undelegated Data, then:
- Add the address or addresses to Name Servers for Name.
- Go to next server name server name.
-
Create the following two DNS queries:
- Query type A and Name as the query name and the RD flag set true ("A Query").
- Query type AAAA and Name as the query name and the RD flag set true ("AAAA Query").
-
Do DNS Lookup of the two queries.
-
If the DNS Responses, if any, contains a list of A or AAAA records (follow any CNAME chain) in the answer section then remember the IP addresses for next step.
-
Collect all IP addresses for the Name and add the address or addresses to Name Servers for that Name and go to next Name.
-
-
Output the Name Servers set.
Outputs
- A set of name servers, where each unique name server name links to a possibly
empty set of its IP addresses:
- Non-empty set: The normal case.
- Empty set: No addresses were available.
Dependencies
None.
Method inter-dependencies
Terminology
-
"Glue Record" - The term is used as defined in RFC 8499, section 7, pages 24-25.
-
"DNS Lookup" - The term is used when a recursive lookup is used, though any changes to the DNS tree introduced by an undelegated test must be respected.
-
"DNS Query" - The term is used for a DNS query that is to follow the specification for DNS queries in DNS Query and Response Defaults.
-
"DNS Response" - The term is used when the DNS response is to be handled as defined in DNS Query and Response Defaults.
-
"In-Bailiwick" - The term is used as defined in RFC 8499, section 7, pages 24-25. In this document it is limited to the meaning "in domain" in the RFC.
-
"Out-Of-Bailiwick" - The terms means, in this document, what is not "In-Bailiwick, in domain". RFC 8499, section 7, pages 24-25.
-
"Referral" - The term means a DNS response with RCODE Name NoError, AA flag unset and NS records in the authority section.
- The answer section is empty or with CNAME record or records. If the query type is CNAME, then the answer section must be empty.
- The additional section may contain address (glue) records (A and AAAA) for the name server names from the RCODE of the NS records.
- The referral refers the zone identical to the owner name of the NS records to the name servers specified by the RDATA in the NS records.
-
"Send" - The terms are used when a DNS query is sent to a specific name server (name server IP address).
-
"Valid Domain Name" -- The term stands for a non-empty domain name string that has successfully passed the tests and normalizations in the Requirements and normalization specification.
-
"Valid IP Address" -- The term stands for either an IPv4 address or an IPv6 address in any address range.
-
"Valid Name Server Name" -- The term stands for a Valid Domain Name that functions as the name of a name server.
Mapping test messages to Test Cases
Index of Text Cases are found in README.
Message tag from Zonemaster-Engine | Module | Method (implemented test case) |
---|---|---|
NAMESERVER_IP_PRIVATE_NETWORK | Address | address01 |
NO_IP_PRIVATE_NETWORK | Address | address01 |
TEST_CASE_END | Address | address01 |
TEST_CASE_START | Address | address01 |
NAMESERVERS_IP_WITH_REVERSE | Address | address02 |
NAMESERVER_IP_WITHOUT_REVERSE | Address | address02 |
NO_RESPONSE_PTR_QUERY | Address | address02 |
TEST_CASE_END | Address | address02 |
TEST_CASE_START | Address | address02 |
NAMESERVER_IP_PTR_MATCH | Address | address03 |
NAMESERVER_IP_PTR_MISMATCH | Address | address03 |
NAMESERVER_IP_WITHOUT_REVERSE | Address | address03 |
NO_RESPONSE_PTR_QUERY | Address | address03 |
TEST_CASE_END | Address | address03 |
TEST_CASE_START | Address | address03 |
B01_CHILD_FOUND | Basic | basic01 |
B01_CHILD_IS_ALIAS | Basic | basic01 |
B01_INCONSISTENT_ALIAS | Basic | basic01 |
B01_INCONSISTENT_DELEGATION | Basic | basic01 |
B01_NO_CHILD | Basic | basic01 |
B01_PARENT_DISREGARDED | Basic | basic01 |
B01_PARENT_FOUND | Basic | basic01 |
B01_PARENT_NOT_FOUND | Basic | basic01 |
B01_PARENT_UNDETERMINED | Basic | basic01 |
B01_ROOT_HAS_NO_PARENT | Basic | basic01 |
B01_SERVER_ZONE_ERROR | Basic | basic01 |
TEST_CASE_END | Basic | basic01 |
TEST_CASE_START | Basic | basic01 |
B02_AUTH_RESPONSE_SOA | Basic | basic02 |
B02_NO_DELEGATION | Basic | basic02 |
B02_NO_WORKING_NS | Basic | basic02 |
B02_NS_BROKEN | Basic | basic02 |
B02_NS_NOT_AUTH | Basic | basic02 |
B02_NS_NO_IP_ADDR | Basic | basic02 |
B02_NS_NO_RESPONSE | Basic | basic02 |
B02_UNEXPECTED_RCODE | Basic | basic02 |
IPV4_DISABLED | Basic | basic02 |
IPV4_ENABLED | Basic | basic02 |
IPV6_DISABLED | Basic | basic02 |
IPV6_ENABLED | Basic | basic02 |
TEST_CASE_END | Basic | basic02 |
TEST_CASE_START | Basic | basic02 |
A_QUERY_NO_RESPONSES | Basic | basic03 |
HAS_A_RECORDS | Basic | basic03 |
IPV4_DISABLED | Basic | basic03 |
IPV4_ENABLED | Basic | basic03 |
IPV6_DISABLED | Basic | basic03 |
IPV6_ENABLED | Basic | basic03 |
NO_A_RECORDS | Basic | basic03 |
TEST_CASE_END | Basic | basic03 |
TEST_CASE_START | Basic | basic03 |
CN01_IPV4_DISABLED | Connectivity | connectivity01 |
CN01_IPV6_DISABLED | Connectivity | connectivity01 |
CN01_MISSING_NS_RECORD_UDP | Connectivity | connectivity01 |
CN01_MISSING_SOA_RECORD_UDP | Connectivity | connectivity01 |
CN01_NO_RESPONSE_NS_QUERY_UDP | Connectivity | connectivity01 |
CN01_NO_RESPONSE_SOA_QUERY_UDP | Connectivity | connectivity01 |
CN01_NO_RESPONSE_UDP | Connectivity | connectivity01 |
CN01_NS_RECORD_NOT_AA_UDP | Connectivity | connectivity01 |
CN01_SOA_RECORD_NOT_AA_UDP | Connectivity | connectivity01 |
CN01_UNEXPECTED_RCODE_NS_QUERY_UDP | Connectivity | connectivity01 |
CN01_UNEXPECTED_RCODE_SOA_QUERY_UDP | Connectivity | connectivity01 |
CN01_WRONG_NS_RECORD_UDP | Connectivity | connectivity01 |
CN01_WRONG_SOA_RECORD_UDP | Connectivity | connectivity01 |
IPV4_DISABLED | Connectivity | connectivity01 |
IPV6_DISABLED | Connectivity | connectivity01 |
TEST_CASE_END | Connectivity | connectivity01 |
TEST_CASE_START | Connectivity | connectivity01 |
CN02_MISSING_NS_RECORD_TCP | Connectivity | connectivity02 |
CN02_MISSING_SOA_RECORD_TCP | Connectivity | connectivity02 |
CN02_NO_RESPONSE_NS_QUERY_TCP | Connectivity | connectivity02 |
CN02_NO_RESPONSE_SOA_QUERY_TCP | Connectivity | connectivity02 |
CN02_NO_RESPONSE_TCP | Connectivity | connectivity02 |
CN02_NS_RECORD_NOT_AA_TCP | Connectivity | connectivity02 |
CN02_SOA_RECORD_NOT_AA_TCP | Connectivity | connectivity02 |
CN02_UNEXPECTED_RCODE_NS_QUERY_TCP | Connectivity | connectivity02 |
CN02_UNEXPECTED_RCODE_SOA_QUERY_TCP | Connectivity | connectivity02 |
CN02_WRONG_NS_RECORD_TCP | Connectivity | connectivity02 |
CN02_WRONG_SOA_RECORD_TCP | Connectivity | connectivity02 |
IPV4_DISABLED | Connectivity | connectivity02 |
IPV6_DISABLED | Connectivity | connectivity02 |
TEST_CASE_END | Connectivity | connectivity02 |
TEST_CASE_START | Connectivity | connectivity02 |
ASN_INFOS_ANNOUNCE_BY | Connectivity | connectivity03 |
ASN_INFOS_ANNOUNCE_IN | Connectivity | connectivity03 |
ASN_INFOS_RAW | Connectivity | connectivity03 |
EMPTY_ASN_SET | Connectivity | connectivity03 |
ERROR_ASN_DATABASE | Connectivity | connectivity03 |
IPV4_DIFFERENT_ASN | Connectivity | connectivity03 |
IPV4_ONE_ASN | Connectivity | connectivity03 |
IPV4_SAME_ASN | Connectivity | connectivity03 |
IPV6_DIFFERENT_ASN | Connectivity | connectivity03 |
IPV6_ONE_ASN | Connectivity | connectivity03 |
IPV6_SAME_ASN | Connectivity | connectivity03 |
TEST_CASE_END | Connectivity | connectivity03 |
TEST_CASE_START | Connectivity | connectivity03 |
ASN_INFOS_ANNOUNCE_IN | Connectivity | connectivity04 |
ASN_INFOS_RAW | Connectivity | connectivity04 |
CN04_EMPTY_PREFIX_SET | Connectivity | connectivity04 |
CN04_ERROR_PREFIX_DATABASE | Connectivity | connectivity04 |
CN04_IPV4_DIFFERENT_PREFIX | Connectivity | connectivity04 |
CN04_IPV4_SAME_PREFIX | Connectivity | connectivity04 |
CN04_IPV4_SINGLE_PREFIX | Connectivity | connectivity04 |
CN04_IPV6_DIFFERENT_PREFIX | Connectivity | connectivity04 |
CN04_IPV6_SAME_PREFIX | Connectivity | connectivity04 |
CN04_IPV6_SINGLE_PREFIX | Connectivity | connectivity04 |
TEST_CASE_END | Connectivity | connectivity04 |
TEST_CASE_START | Connectivity | connectivity04 |
IPV4_DISABLED | Consistency | consistency01 |
IPV6_DISABLED | Consistency | consistency01 |
MULTIPLE_SOA_SERIALS | Consistency | consistency01 |
NO_RESPONSE | Consistency | consistency01 |
NO_RESPONSE_SOA_QUERY | Consistency | consistency01 |
ONE_SOA_SERIAL | Consistency | consistency01 |
SOA_SERIAL | Consistency | consistency01 |
SOA_SERIAL_VARIATION | Consistency | consistency01 |
TEST_CASE_END | Consistency | consistency01 |
TEST_CASE_START | Consistency | consistency01 |
IPV4_DISABLED | Consistency | consistency02 |
IPV6_DISABLED | Consistency | consistency02 |
MULTIPLE_SOA_RNAMES | Consistency | consistency02 |
NO_RESPONSE | Consistency | consistency02 |
NO_RESPONSE_SOA_QUERY | Consistency | consistency02 |
ONE_SOA_RNAME | Consistency | consistency02 |
SOA_RNAME | Consistency | consistency02 |
TEST_CASE_END | Consistency | consistency02 |
TEST_CASE_START | Consistency | consistency02 |
IPV4_DISABLED | Consistency | consistency03 |
IPV6_DISABLED | Consistency | consistency03 |
MULTIPLE_SOA_TIME_PARAMETER_SET | Consistency | consistency03 |
NO_RESPONSE | Consistency | consistency03 |
NO_RESPONSE_SOA_QUERY | Consistency | consistency03 |
ONE_SOA_TIME_PARAMETER_SET | Consistency | consistency03 |
SOA_TIME_PARAMETER_SET | Consistency | consistency03 |
TEST_CASE_END | Consistency | consistency03 |
TEST_CASE_START | Consistency | consistency03 |
IPV4_DISABLED | Consistency | consistency04 |
IPV6_DISABLED | Consistency | consistency04 |
MULTIPLE_NS_SET | Consistency | consistency04 |
NO_RESPONSE | Consistency | consistency04 |
NO_RESPONSE_NS_QUERY | Consistency | consistency04 |
NS_SET | Consistency | consistency04 |
ONE_NS_SET | Consistency | consistency04 |
TEST_CASE_END | Consistency | consistency04 |
TEST_CASE_START | Consistency | consistency04 |
ADDRESSES_MATCH | Consistency | consistency05 |
CHILD_NS_FAILED | Consistency | consistency05 |
CHILD_ZONE_LAME | Consistency | consistency05 |
EXTRA_ADDRESS_CHILD | Consistency | consistency05 |
IN_BAILIWICK_ADDR_MISMATCH | Consistency | consistency05 |
NO_RESPONSE | Consistency | consistency05 |
OUT_OF_BAILIWICK_ADDR_MISMATCH | Consistency | consistency05 |
TEST_CASE_END | Consistency | consistency05 |
TEST_CASE_START | Consistency | consistency05 |
MULTIPLE_SOA_MNAMES | Consistency | consistency06 |
NO_RESPONSE | Consistency | consistency06 |
NO_RESPONSE_SOA_QUERY | Consistency | consistency06 |
ONE_SOA_MNAME | Consistency | consistency06 |
TEST_CASE_END | Consistency | consistency06 |
TEST_CASE_START | Consistency | consistency06 |
ENOUGH_IPV4_NS_CHILD | Delegation | delegation01 |
ENOUGH_IPV4_NS_DEL | Delegation | delegation01 |
ENOUGH_IPV6_NS_CHILD | Delegation | delegation01 |
ENOUGH_IPV6_NS_DEL | Delegation | delegation01 |
ENOUGH_NS_CHILD | Delegation | delegation01 |
ENOUGH_NS_DEL | Delegation | delegation01 |
NOT_ENOUGH_IPV4_NS_CHILD | Delegation | delegation01 |
NOT_ENOUGH_IPV4_NS_DEL | Delegation | delegation01 |
NOT_ENOUGH_IPV6_NS_CHILD | Delegation | delegation01 |
NOT_ENOUGH_IPV6_NS_DEL | Delegation | delegation01 |
NOT_ENOUGH_NS_CHILD | Delegation | delegation01 |
NOT_ENOUGH_NS_DEL | Delegation | delegation01 |
NO_IPV4_NS_CHILD | Delegation | delegation01 |
NO_IPV4_NS_DEL | Delegation | delegation01 |
NO_IPV6_NS_CHILD | Delegation | delegation01 |
NO_IPV6_NS_DEL | Delegation | delegation01 |
TEST_CASE_END | Delegation | delegation01 |
TEST_CASE_START | Delegation | delegation01 |
CHILD_DISTINCT_NS_IP | Delegation | delegation02 |
CHILD_NS_SAME_IP | Delegation | delegation02 |
DEL_DISTINCT_NS_IP | Delegation | delegation02 |
DEL_NS_SAME_IP | Delegation | delegation02 |
DISTINCT_IP_ADDRESS | Delegation | delegation02 |
SAME_IP_ADDRESS | Delegation | delegation02 |
TEST_CASE_END | Delegation | delegation02 |
TEST_CASE_START | Delegation | delegation02 |
REFERRAL_SIZE_OK | Delegation | delegation03 |
REFERRAL_SIZE_TOO_LARGE | Delegation | delegation03 |
TEST_CASE_END | Delegation | delegation03 |
TEST_CASE_START | Delegation | delegation03 |
ARE_AUTHORITATIVE | Delegation | delegation04 |
IPV4_DISABLED | Delegation | delegation04 |
IPV6_DISABLED | Delegation | delegation04 |
IS_NOT_AUTHORITATIVE | Delegation | delegation04 |
TEST_CASE_END | Delegation | delegation04 |
TEST_CASE_START | Delegation | delegation04 |
NO_NS_CNAME | Delegation | delegation05 |
NO_RESPONSE | Delegation | delegation05 |
NS_IS_CNAME | Delegation | delegation05 |
TEST_CASE_END | Delegation | delegation05 |
TEST_CASE_START | Delegation | delegation05 |
UNEXPECTED_RCODE | Delegation | delegation05 |
IPV4_DISABLED | Delegation | delegation06 |
IPV6_DISABLED | Delegation | delegation06 |
SOA_EXISTS | Delegation | delegation06 |
SOA_NOT_EXISTS | Delegation | delegation06 |
TEST_CASE_END | Delegation | delegation06 |
TEST_CASE_START | Delegation | delegation06 |
EXTRA_NAME_CHILD | Delegation | delegation07 |
EXTRA_NAME_PARENT | Delegation | delegation07 |
NAMES_MATCH | Delegation | delegation07 |
TEST_CASE_END | Delegation | delegation07 |
TEST_CASE_START | Delegation | delegation07 |
TOTAL_NAME_MISMATCH | Delegation | delegation07 |
DS01_DIGEST_NOT_SUPPORTED_BY_ZM | DNSSEC | dnssec01 |
DS01_DS_ALGO_2_MISSING | DNSSEC | dnssec01 |
DS01_DS_ALGO_DEPRECATED | DNSSEC | dnssec01 |
DS01_DS_ALGO_NOT_DS | DNSSEC | dnssec01 |
DS01_DS_ALGO_RESERVED | DNSSEC | dnssec01 |
TEST_CASE_END | DNSSEC | dnssec01 |
TEST_CASE_START | DNSSEC | dnssec01 |
DS02_ALGO_NOT_SUPPORTED_BY_ZM | DNSSEC | dnssec02 |
DS02_DNSKEY_NOT_FOR_ZONE_SIGNING | DNSSEC | dnssec02 |
DS02_DNSKEY_NOT_SEP | DNSSEC | dnssec02 |
DS02_DNSKEY_NOT_SIGNED_BY_ANY_DS | DNSSEC | dnssec02 |
DS02_NO_DNSKEY_FOR_DS | DNSSEC | dnssec02 |
DS02_NO_MATCHING_DNSKEY_RRSIG | DNSSEC | dnssec02 |
DS02_NO_MATCH_DS_DNSKEY | DNSSEC | dnssec02 |
DS02_NO_VALID_DNSKEY_FOR_ANY_DS | DNSSEC | dnssec02 |
DS02_RRSIG_NOT_VALID_BY_DNSKEY | DNSSEC | dnssec02 |
DS03_ERR_MULT_NSEC3 | DNSSEC | dnssec03 |
DS03_ILLEGAL_HASH_ALGO | DNSSEC | dnssec03 |
DS03_ILLEGAL_ITERATION_VALUE | DNSSEC | dnssec03 |
DS03_ILLEGAL_SALT_LENGTH | DNSSEC | dnssec03 |
DS03_INCONSISTENT_HASH_ALGO | DNSSEC | dnssec03 |
DS03_INCONSISTENT_ITERATION | DNSSEC | dnssec03 |
DS03_INCONSISTENT_NSEC3_FLAGS | DNSSEC | dnssec03 |
DS03_INCONSISTENT_SALT_LENGTH | DNSSEC | dnssec03 |
DS03_LEGAL_EMPTY_SALT | DNSSEC | dnssec03 |
DS03_LEGAL_HASH_ALGO | DNSSEC | dnssec03 |
DS03_LEGAL_ITERATION_VALUE | DNSSEC | dnssec03 |
DS03_NO_DNSSEC_SUPPORT | DNSSEC | dnssec03 |
DS03_NO_NSEC3 | DNSSEC | dnssec03 |
DS03_NSEC3_OPT_OUT_DISABLED | DNSSEC | dnssec03 |
DS03_NSEC3_OPT_OUT_ENABLED_NON_TLD | DNSSEC | dnssec03 |
DS03_NSEC3_OPT_OUT_ENABLED_TLD | DNSSEC | dnssec03 |
DS03_SERVER_NO_DNSSEC_SUPPORT | DNSSEC | dnssec03 |
DS03_SERVER_NO_NSEC3 | DNSSEC | dnssec03 |
DS03_UNASSIGNED_FLAG_USED | DNSSEC | dnssec03 |
DURATION_LONG | DNSSEC | dnssec04 |
DURATION_OK | DNSSEC | dnssec04 |
REMAINING_LONG | DNSSEC | dnssec04 |
REMAINING_SHORT | DNSSEC | dnssec04 |
RRSIG_EXPIRATION | DNSSEC | dnssec04 |
RRSIG_EXPIRED | DNSSEC | dnssec04 |
TEST_CASE_END | DNSSEC | dnssec04 |
TEST_CASE_START | DNSSEC | dnssec04 |
ALGORITHM_DEPRECATED | DNSSEC | dnssec05 |
ALGORITHM_NOT_RECOMMENDED | DNSSEC | dnssec05 |
ALGORITHM_NOT_ZONE_SIGN | DNSSEC | dnssec05 |
ALGORITHM_OK | DNSSEC | dnssec05 |
ALGORITHM_PRIVATE | DNSSEC | dnssec05 |
ALGORITHM_RESERVED | DNSSEC | dnssec05 |
ALGORITHM_UNASSIGNED | DNSSEC | dnssec05 |
IPV4_DISABLED | DNSSEC | dnssec05 |
IPV6_DISABLED | DNSSEC | dnssec05 |
KEY_DETAILS | DNSSEC | dnssec05 |
NO_RESPONSE | DNSSEC | dnssec05 |
NO_RESPONSE_DNSKEY | DNSSEC | dnssec05 |
TEST_CASE_END | DNSSEC | dnssec05 |
TEST_CASE_START | DNSSEC | dnssec05 |
EXTRA_PROCESSING_BROKEN | DNSSEC | dnssec06 |
EXTRA_PROCESSING_OK | DNSSEC | dnssec06 |
TEST_CASE_END | DNSSEC | dnssec06 |
TEST_CASE_START | DNSSEC | dnssec06 |
ADDITIONAL_DNSKEY_SKIPPED | DNSSEC | dnssec07 |
DNSKEY_AND_DS | DNSSEC | dnssec07 |
DNSKEY_BUT_NOT_DS | DNSSEC | dnssec07 |
DS_BUT_NOT_DNSKEY | DNSSEC | dnssec07 |
NEITHER_DNSKEY_NOR_DS | DNSSEC | dnssec07 |
NOT_SIGNED | DNSSEC | dnssec07 |
TEST_CASE_END | DNSSEC | dnssec07 |
TEST_CASE_START | DNSSEC | dnssec07 |
DS08_ALGO_NOT_SUPPORTED_BY_ZM | DNSSEC | dnssec08 |
DS08_DNSKEY_RRSIG_EXPIRED | DNSSEC | dnssec08 |
DS08_DNSKEY_RRSIG_NOT_YET_VALID | DNSSEC | dnssec08 |
DS08_MISSING_RRSIG_IN_RESPONSE | DNSSEC | dnssec08 |
DS08_NO_MATCHING_DNSKEY | DNSSEC | dnssec08 |
DS08_RRSIG_NOT_VALID_BY_DNSKEY | DNSSEC | dnssec08 |
DS09_ALGO_NOT_SUPPORTED_BY_ZM | DNSSEC | dnssec09 |
DS09_MISSING_RRSIG_IN_RESPONSE | DNSSEC | dnssec09 |
DS09_NO_MATCHING_DNSKEY | DNSSEC | dnssec09 |
DS09_RRSIG_NOT_VALID_BY_DNSKEY | DNSSEC | dnssec09 |
DS09_SOA_RRSIG_EXPIRED | DNSSEC | dnssec09 |
DS09_SOA_RRSIG_NOT_YET_VALID | DNSSEC | dnssec09 |
DS10_ALGO_NOT_SUPPORTED_BY_ZM | DNSSEC | dnssec10 |
DS10_ERR_MULT_NSEC | DNSSEC | dnssec10 |
DS10_ERR_MULT_NSEC3 | DNSSEC | dnssec10 |
DS10_ERR_MULT_NSEC3PARAM | DNSSEC | dnssec10 |
DS10_EXPECTED_NSEC_NSEC3_MISSING | DNSSEC | dnssec10 |
DS10_HAS_NSEC | DNSSEC | dnssec10 |
DS10_HAS_NSEC3 | DNSSEC | dnssec10 |
DS10_INCONSISTENT_NSEC | DNSSEC | dnssec10 |
DS10_INCONSISTENT_NSEC3 | DNSSEC | dnssec10 |
DS10_INCONSISTENT_NSEC_NSEC3 | DNSSEC | dnssec10 |
DS10_MIXED_NSEC_NSEC3 | DNSSEC | dnssec10 |
DS10_NSEC3PARAM_GIVES_ERR_ANSWER | DNSSEC | dnssec10 |
DS10_NSEC3PARAM_MISMATCHES_APEX | DNSSEC | dnssec10 |
DS10_NSEC3PARAM_QUERY_RESPONSE_ERR | DNSSEC | dnssec10 |
DS10_NSEC3_ERR_TYPE_LIST | DNSSEC | dnssec10 |
DS10_NSEC3_MISMATCHES_APEX | DNSSEC | dnssec10 |
DS10_NSEC3_MISSING_SIGNATURE | DNSSEC | dnssec10 |
DS10_NSEC3_NODATA_MISSING_SOA | DNSSEC | dnssec10 |
DS10_NSEC3_NODATA_WRONG_SOA | DNSSEC | dnssec10 |
DS10_NSEC3_NO_VERIFIED_SIGNATURE | DNSSEC | dnssec10 |
DS10_NSEC3_RRSIG_EXPIRED | DNSSEC | dnssec10 |
DS10_NSEC3_RRSIG_NOT_YET_VALID | DNSSEC | dnssec10 |
DS10_NSEC3_RRSIG_NO_DNSKEY | DNSSEC | dnssec10 |
DS10_NSEC3_RRSIG_VERIFY_ERROR | DNSSEC | dnssec10 |
DS10_NSEC_ERR_TYPE_LIST | DNSSEC | dnssec10 |
DS10_NSEC_GIVES_ERR_ANSWER | DNSSEC | dnssec10 |
DS10_NSEC_MISMATCHES_APEX | DNSSEC | dnssec10 |
DS10_NSEC_MISSING_SIGNATURE | DNSSEC | dnssec10 |
DS10_NSEC_NODATA_MISSING_SOA | DNSSEC | dnssec10 |
DS10_NSEC_NODATA_WRONG_SOA | DNSSEC | dnssec10 |
DS10_NSEC_NO_VERIFIED_SIGNATURE | DNSSEC | dnssec10 |
DS10_NSEC_QUERY_RESPONSE_ERR | DNSSEC | dnssec10 |
DS10_NSEC_RRSIG_EXPIRED | DNSSEC | dnssec10 |
DS10_NSEC_RRSIG_NOT_YET_VALID | DNSSEC | dnssec10 |
DS10_NSEC_RRSIG_NO_DNSKEY | DNSSEC | dnssec10 |
DS10_NSEC_RRSIG_VERIFY_ERROR | DNSSEC | dnssec10 |
DS10_SERVER_NO_DNSSEC | DNSSEC | dnssec10 |
DS10_ZONE_NO_DNSSEC | DNSSEC | dnssec10 |
DS11_DS_BUT_UNSIGNED_ZONE | DNSSEC | dnssec11 |
DS11_INCONSISTENT_DS | DNSSEC | dnssec11 |
DS11_INCONSISTENT_SIGNED_ZONE | DNSSEC | dnssec11 |
DS11_NS_WITH_SIGNED_ZONE | DNSSEC | dnssec11 |
DS11_NS_WITH_UNSIGNED_ZONE | DNSSEC | dnssec11 |
DS11_PARENT_WITHOUT_DS | DNSSEC | dnssec11 |
DS11_PARENT_WITH_DS | DNSSEC | dnssec11 |
DS11_UNDETERMINED_DS | DNSSEC | dnssec11 |
DS11_UNDETERMINED_SIGNED_ZONE | DNSSEC | dnssec11 |
DS13_ALGO_NOT_SIGNED_DNSKEY | DNSSEC | dnssec13 |
DS13_ALGO_NOT_SIGNED_NS | DNSSEC | dnssec13 |
DS13_ALGO_NOT_SIGNED_SOA | DNSSEC | dnssec13 |
DNSKEY_SMALLER_THAN_REC | DNSSEC | dnssec14 |
DNSKEY_TOO_LARGE_FOR_ALGO | DNSSEC | dnssec14 |
DNSKEY_TOO_SMALL_FOR_ALGO | DNSSEC | dnssec14 |
IPV4_DISABLED | DNSSEC | dnssec14 |
IPV6_DISABLED | DNSSEC | dnssec14 |
KEY_SIZE_OK | DNSSEC | dnssec14 |
NO_RESPONSE | DNSSEC | dnssec14 |
NO_RESPONSE_DNSKEY | DNSSEC | dnssec14 |
TEST_CASE_END | DNSSEC | dnssec14 |
TEST_CASE_START | DNSSEC | dnssec14 |
DS15_HAS_CDNSKEY_NO_CDS | DNSSEC | dnssec15 |
DS15_HAS_CDS_AND_CDNSKEY | DNSSEC | dnssec15 |
DS15_HAS_CDS_NO_CDNSKEY | DNSSEC | dnssec15 |
DS15_INCONSISTENT_CDNSKEY | DNSSEC | dnssec15 |
DS15_INCONSISTENT_CDS | DNSSEC | dnssec15 |
DS15_MISMATCH_CDS_CDNSKEY | DNSSEC | dnssec15 |
DS15_NO_CDS_CDNSKEY | DNSSEC | dnssec15 |
DS16_CDS_INVALID_RRSIG | DNSSEC | dnssec16 |
DS16_CDS_MATCHES_NON_SEP_DNSKEY | DNSSEC | dnssec16 |
DS16_CDS_MATCHES_NON_ZONE_DNSKEY | DNSSEC | dnssec16 |
DS16_CDS_MATCHES_NO_DNSKEY | DNSSEC | dnssec16 |
DS16_CDS_NOT_SIGNED_BY_CDS | DNSSEC | dnssec16 |
DS16_CDS_SIGNED_BY_UNKNOWN_DNSKEY | DNSSEC | dnssec16 |
DS16_CDS_UNSIGNED | DNSSEC | dnssec16 |
DS16_CDS_WITHOUT_DNSKEY | DNSSEC | dnssec16 |
DS16_DELETE_CDS | DNSSEC | dnssec16 |
DS16_DNSKEY_NOT_SIGNED_BY_CDS | DNSSEC | dnssec16 |
DS16_MIXED_DELETE_CDS | DNSSEC | dnssec16 |
DS17_CDNSKEY_INVALID_RRSIG | DNSSEC | dnssec17 |
DS17_CDNSKEY_IS_NON_SEP | DNSSEC | dnssec17 |
DS17_CDNSKEY_IS_NON_ZONE | DNSSEC | dnssec17 |
DS17_CDNSKEY_MATCHES_NO_DNSKEY | DNSSEC | dnssec17 |
DS17_CDNSKEY_NOT_SIGNED_BY_CDNSKEY | DNSSEC | dnssec17 |
DS17_CDNSKEY_SIGNED_BY_UNKNOWN_DNSKEY | DNSSEC | dnssec17 |
DS17_CDNSKEY_UNSIGNED | DNSSEC | dnssec17 |
DS17_CDNSKEY_WITHOUT_DNSKEY | DNSSEC | dnssec17 |
DS17_DELETE_CDNSKEY | DNSSEC | dnssec17 |
DS17_DNSKEY_NOT_SIGNED_BY_CDNSKEY | DNSSEC | dnssec17 |
DS17_MIXED_DELETE_CDNSKEY | DNSSEC | dnssec17 |
DS18_NO_MATCH_CDNSKEY_RRSIG_DS | DNSSEC | dnssec18 |
DS18_NO_MATCH_CDS_RRSIG_DS | DNSSEC | dnssec18 |
IS_A_RECURSOR | Nameserver | nameserver01 |
NO_RECURSOR | Nameserver | nameserver01 |
NO_RESPONSE | Nameserver | nameserver01 |
TEST_CASE_END | Nameserver | nameserver01 |
TEST_CASE_START | Nameserver | nameserver01 |
BREAKS_ON_EDNS | Nameserver | nameserver02 |
EDNS0_SUPPORT | Nameserver | nameserver02 |
EDNS_RESPONSE_WITHOUT_EDNS | Nameserver | nameserver02 |
EDNS_VERSION_ERROR | Nameserver | nameserver02 |
NO_EDNS_SUPPORT | Nameserver | nameserver02 |
NO_RESPONSE | Nameserver | nameserver02 |
NS_ERROR | Nameserver | nameserver02 |
TEST_CASE_END | Nameserver | nameserver02 |
TEST_CASE_START | Nameserver | nameserver02 |
AXFR_AVAILABLE | Nameserver | nameserver03 |
AXFR_FAILURE | Nameserver | nameserver03 |
TEST_CASE_END | Nameserver | nameserver03 |
TEST_CASE_START | Nameserver | nameserver03 |
DIFFERENT_SOURCE_IP | Nameserver | nameserver04 |
SAME_SOURCE_IP | Nameserver | nameserver04 |
TEST_CASE_END | Nameserver | nameserver04 |
TEST_CASE_START | Nameserver | nameserver04 |
AAAA_BAD_RDATA | Nameserver | nameserver05 |
AAAA_QUERY_DROPPED | Nameserver | nameserver05 |
AAAA_UNEXPECTED_RCODE | Nameserver | nameserver05 |
AAAA_WELL_PROCESSED | Nameserver | nameserver05 |
A_UNEXPECTED_RCODE | Nameserver | nameserver05 |
IPV4_DISABLED | Nameserver | nameserver05 |
IPV6_DISABLED | Nameserver | nameserver05 |
NO_RESPONSE | Nameserver | nameserver05 |
TEST_CASE_END | Nameserver | nameserver05 |
TEST_CASE_START | Nameserver | nameserver05 |
CAN_BE_RESOLVED | Nameserver | nameserver06 |
CAN_NOT_BE_RESOLVED | Nameserver | nameserver06 |
NO_RESOLUTION | Nameserver | nameserver06 |
TEST_CASE_END | Nameserver | nameserver06 |
TEST_CASE_START | Nameserver | nameserver06 |
NO_UPWARD_REFERRAL | Nameserver | nameserver07 |
TEST_CASE_END | Nameserver | nameserver07 |
TEST_CASE_START | Nameserver | nameserver07 |
UPWARD_REFERRAL | Nameserver | nameserver07 |
UPWARD_REFERRAL_IRRELEVANT | Nameserver | nameserver07 |
QNAME_CASE_INSENSITIVE | Nameserver | nameserver08 |
QNAME_CASE_SENSITIVE | Nameserver | nameserver08 |
TEST_CASE_END | Nameserver | nameserver08 |
TEST_CASE_START | Nameserver | nameserver08 |
CASE_QUERIES_RESULTS_DIFFER | Nameserver | nameserver09 |
CASE_QUERIES_RESULTS_OK | Nameserver | nameserver09 |
CASE_QUERY_DIFFERENT_ANSWER | Nameserver | nameserver09 |
CASE_QUERY_DIFFERENT_RC | Nameserver | nameserver09 |
CASE_QUERY_NO_ANSWER | Nameserver | nameserver09 |
CASE_QUERY_SAME_ANSWER | Nameserver | nameserver09 |
CASE_QUERY_SAME_RC | Nameserver | nameserver09 |
TEST_CASE_END | Nameserver | nameserver09 |
TEST_CASE_START | Nameserver | nameserver09 |
N10_EDNS_RESPONSE_ERROR | Nameserver | nameserver10 |
N10_NO_RESPONSE_EDNS1_QUERY | Nameserver | nameserver10 |
N10_UNEXPECTED_RCODE | Nameserver | nameserver10 |
TEST_CASE_END | Nameserver | nameserver10 |
TEST_CASE_START | Nameserver | nameserver10 |
N11_NO_EDNS | Nameserver | nameserver11 |
N11_NO_RESPONSE | Nameserver | nameserver11 |
N11_RETURNS_UNKNOWN_OPTION_CODE | Nameserver | nameserver11 |
N11_UNEXPECTED_ANSWER_SECTION | Nameserver | nameserver11 |
N11_UNEXPECTED_RCODE | Nameserver | nameserver11 |
N11_UNSET_AA | Nameserver | nameserver11 |
TEST_CASE_END | Nameserver | nameserver11 |
TEST_CASE_START | Nameserver | nameserver11 |
NO_EDNS_SUPPORT | Nameserver | nameserver12 |
NO_RESPONSE | Nameserver | nameserver12 |
NS_ERROR | Nameserver | nameserver12 |
TEST_CASE_END | Nameserver | nameserver12 |
TEST_CASE_START | Nameserver | nameserver12 |
Z_FLAGS_NOTCLEAR | Nameserver | nameserver12 |
MISSING_OPT_IN_TRUNCATED | Nameserver | nameserver13 |
NO_EDNS_SUPPORT | Nameserver | nameserver13 |
NO_RESPONSE | Nameserver | nameserver13 |
NS_ERROR | Nameserver | nameserver13 |
TEST_CASE_END | Nameserver | nameserver13 |
TEST_CASE_START | Nameserver | nameserver13 |
N15_ERROR_ON_VERSION_QUERY | Nameserver | nameserver15 |
N15_NO_VERSION_REVEALED | Nameserver | nameserver15 |
N15_SOFTWARE_VERSION | Nameserver | nameserver15 |
N15_WRONG_CLASS | Nameserver | nameserver15 |
NON_ALLOWED_CHARS | Syntax | syntax01 |
ONLY_ALLOWED_CHARS | Syntax | syntax01 |
TEST_CASE_END | Syntax | syntax01 |
TEST_CASE_START | Syntax | syntax01 |
INITIAL_HYPHEN | Syntax | syntax02 |
NO_ENDING_HYPHENS | Syntax | syntax02 |
TERMINAL_HYPHEN | Syntax | syntax02 |
TEST_CASE_END | Syntax | syntax02 |
TEST_CASE_START | Syntax | syntax02 |
DISCOURAGED_DOUBLE_DASH | Syntax | syntax03 |
NO_DOUBLE_DASH | Syntax | syntax03 |
TEST_CASE_END | Syntax | syntax03 |
TEST_CASE_START | Syntax | syntax03 |
NAMESERVER_DISCOURAGED_DOUBLE_DASH | Syntax | syntax04 |
NAMESERVER_NON_ALLOWED_CHARS | Syntax | syntax04 |
NAMESERVER_NUMERIC_TLD | Syntax | syntax04 |
NAMESERVER_SYNTAX_OK | Syntax | syntax04 |
TEST_CASE_END | Syntax | syntax04 |
TEST_CASE_START | Syntax | syntax04 |
NO_RESPONSE_SOA_QUERY | Syntax | syntax05 |
RNAME_MISUSED_AT_SIGN | Syntax | syntax05 |
RNAME_NO_AT_SIGN | Syntax | syntax05 |
TEST_CASE_END | Syntax | syntax05 |
TEST_CASE_START | Syntax | syntax05 |
NO_RESPONSE | Syntax | syntax06 |
NO_RESPONSE_SOA_QUERY | Syntax | syntax06 |
RNAME_MAIL_DOMAIN_INVALID | Syntax | syntax06 |
RNAME_MAIL_DOMAIN_LOCALHOST | Syntax | syntax06 |
RNAME_MAIL_ILLEGAL_CNAME | Syntax | syntax06 |
RNAME_RFC822_INVALID | Syntax | syntax06 |
RNAME_RFC822_VALID | Syntax | syntax06 |
TEST_CASE_END | Syntax | syntax06 |
TEST_CASE_START | Syntax | syntax06 |
MNAME_DISCOURAGED_DOUBLE_DASH | Syntax | syntax07 |
MNAME_NON_ALLOWED_CHARS | Syntax | syntax07 |
MNAME_NUMERIC_TLD | Syntax | syntax07 |
MNAME_SYNTAX_OK | Syntax | syntax07 |
NO_RESPONSE_SOA_QUERY | Syntax | syntax07 |
TEST_CASE_END | Syntax | syntax07 |
TEST_CASE_START | Syntax | syntax07 |
MX_DISCOURAGED_DOUBLE_DASH | Syntax | syntax08 |
MX_NON_ALLOWED_CHARS | Syntax | syntax08 |
MX_NUMERIC_TLD | Syntax | syntax08 |
MX_SYNTAX_OK | Syntax | syntax08 |
NO_RESPONSE_MX_QUERY | Syntax | syntax08 |
TEST_CASE_END | Syntax | syntax08 |
TEST_CASE_START | Syntax | syntax08 |
TEST_CASE_END | Zone | zone01 |
TEST_CASE_START | Zone | zone01 |
Z01_MNAME_HAS_LOCALHOST_ADDR | Zone | zone01 |
Z01_MNAME_IS_DOT | Zone | zone01 |
Z01_MNAME_IS_LOCALHOST | Zone | zone01 |
Z01_MNAME_IS_MASTER | Zone | zone01 |
Z01_MNAME_MISSING_SOA_RECORD | Zone | zone01 |
Z01_MNAME_NOT_AUTHORITATIVE | Zone | zone01 |
Z01_MNAME_NOT_IN_NS_LIST | Zone | zone01 |
Z01_MNAME_NOT_MASTER | Zone | zone01 |
Z01_MNAME_NOT_RESOLVE | Zone | zone01 |
Z01_MNAME_NO_RESPONSE | Zone | zone01 |
Z01_MNAME_UNEXPECTED_RCODE | Zone | zone01 |
NO_RESPONSE_SOA_QUERY | Zone | zone02 |
REFRESH_MINIMUM_VALUE_LOWER | Zone | zone02 |
REFRESH_MINIMUM_VALUE_OK | Zone | zone02 |
TEST_CASE_END | Zone | zone02 |
TEST_CASE_START | Zone | zone02 |
NO_RESPONSE_SOA_QUERY | Zone | zone03 |
REFRESH_HIGHER_THAN_RETRY | Zone | zone03 |
REFRESH_LOWER_THAN_RETRY | Zone | zone03 |
TEST_CASE_END | Zone | zone03 |
TEST_CASE_START | Zone | zone03 |
NO_RESPONSE_SOA_QUERY | Zone | zone04 |
RETRY_MINIMUM_VALUE_LOWER | Zone | zone04 |
RETRY_MINIMUM_VALUE_OK | Zone | zone04 |
TEST_CASE_END | Zone | zone04 |
TEST_CASE_START | Zone | zone04 |
EXPIRE_LOWER_THAN_REFRESH | Zone | zone05 |
EXPIRE_MINIMUM_VALUE_LOWER | Zone | zone05 |
EXPIRE_MINIMUM_VALUE_OK | Zone | zone05 |
NO_RESPONSE_SOA_QUERY | Zone | zone05 |
TEST_CASE_END | Zone | zone05 |
TEST_CASE_START | Zone | zone05 |
NO_RESPONSE_SOA_QUERY | Zone | zone06 |
SOA_DEFAULT_TTL_MAXIMUM_VALUE_HIGHER | Zone | zone06 |
SOA_DEFAULT_TTL_MAXIMUM_VALUE_LOWER | Zone | zone06 |
SOA_DEFAULT_TTL_MAXIMUM_VALUE_OK | Zone | zone06 |
TEST_CASE_END | Zone | zone06 |
TEST_CASE_START | Zone | zone06 |
MNAME_HAS_NO_ADDRESS | Zone | zone07 |
MNAME_IS_CNAME | Zone | zone07 |
MNAME_IS_NOT_CNAME | Zone | zone07 |
NO_RESPONSE_SOA_QUERY | Zone | zone07 |
TEST_CASE_END | Zone | zone07 |
TEST_CASE_START | Zone | zone07 |
MX_RECORD_IS_CNAME | Zone | zone08 |
MX_RECORD_IS_NOT_CNAME | Zone | zone08 |
NO_RESPONSE_MX_QUERY | Zone | zone08 |
TEST_CASE_END | Zone | zone08 |
TEST_CASE_START | Zone | zone08 |
TEST_CASE_END | Zone | zone09 |
TEST_CASE_START | Zone | zone09 |
Z09_INCONSISTENT_MX | Zone | zone09 |
Z09_INCONSISTENT_MX_DATA | Zone | zone09 |
Z09_MISSING_MAIL_TARGET | Zone | zone09 |
Z09_MX_DATA | Zone | zone09 |
Z09_MX_FOUND | Zone | zone09 |
Z09_NON_AUTH_MX_RESPONSE | Zone | zone09 |
Z09_NO_MX_FOUND | Zone | zone09 |
Z09_NO_RESPONSE_MX_QUERY | Zone | zone09 |
Z09_NULL_MX_NON_ZERO_PREF | Zone | zone09 |
Z09_NULL_MX_WITH_OTHER_MX | Zone | zone09 |
Z09_ROOT_EMAIL_DOMAIN | Zone | zone09 |
Z09_TLD_EMAIL_DOMAIN | Zone | zone09 |
Z09_UNEXPECTED_RCODE_MX | Zone | zone09 |
MULTIPLE_SOA | Zone | zone10 |
NO_RESPONSE | Zone | zone10 |
NO_SOA_IN_RESPONSE | Zone | zone10 |
ONE_SOA | Zone | zone10 |
TEST_CASE_END | Zone | zone10 |
TEST_CASE_START | Zone | zone10 |
WRONG_SOA | Zone | zone10 |
Z11_DIFFERENT_SPF_POLICIES_FOUND | Zone | zone11 |
Z11_INCONSISTENT_SPF_POLICIES | Zone | zone11 |
Z11_NO_SPF_FOUND | Zone | zone11 |
Z11_SPF1_MULTIPLE_RECORDS | Zone | zone11 |
Z11_SPF1_SYNTAX_ERROR | Zone | zone11 |
Z11_SPF1_SYNTAX_OK | Zone | zone11 |
Z11_UNABLE_TO_CHECK_FOR_SPF | Zone | zone11 |
Severity Level Definitions
The following severity levels are defined to be assigned to test result messages, one at a time, and below it is specified what they intend to mean.
- CRITICAL
- ERROR
- WARNING
- NOTICE
- INFO
- DEBUG
- DEBUG2
- DEBUG3
CRITICAL
A result at level CRITICAL means that the zone being tested has one or more problems that are so severe that it is not possible to even test it. Examples can be that the name requested is not syntactically possible, that it's situated under a domain that does not exist, or that none of its nameservers are responding.
A zone with one or more CRITICAL errors can reasonably be said not to exist.
ERROR
A result at level ERROR means a problem that is very likely (or possibly certain) to negatively affect the function of the zone being tested, but not so severe that the entire zone becomes unresolvable. Examples of ERROR level problems are nameservers that do not respond to queries over TCP, only having a single nameserver and using a reserved algorithm for DNSKEY records.
WARNING
A result at level WARNING means something that will under some circumstances be a problem, but that is unlikely to be noticed by a casual user. Problems at this level may be an extra nameserver listed at the parent side, or unsuitable time values in a SOA record.
NOTICE
A result at level NOTICE means something that should be known by the zone's administrator but that need not necessarily be a problem at all. An example of this can be that different name servers for the zone reports slightly different SOA serial numbers, which is a perfectly natural consequence of propagation delays but that the admin should be aware of.
INFO
A result at level INFO is something that may be of interest to the zone's administrator but that definitely does not indicate a problem. Examples of this can be name server software versions, the fact that the zone uses DNSCurve encryption or that a name server does not recurse.
DEBUG
Results at level DEBUG are related to the zone being tested, but not normally of interest to anyone. Implementors of tests are encouraged to be generous with the production of these messages. Examples can be that a test section started running, that an ordinary action performed as expected or that a value was inside its normal range.
DEBUG2
Results at level DEBUG2 are produced by the testing framework itself, and are intended to only be displayed when trying to identify and diagnose unusual and hard to understand problems in a zone. This level includes at least one line of information for every DNS query sent and response received.
DEBUG3
Results at level DEBUG3 have all the same attributes as those for DEBUG2, and are even more voluminous. At this level, full string representations of all received DNS packets will be included. At the time of writing, a test run for the same domain produces about fifty times as much output on level DEBUG3 as it does on level DEBUG and a thousand times as much as on the default NOTICE level.
DNS Query and Response Defaults
Table of contents
- Overview
- Application of this specification
- Default setting in DNS Query
- Default setting in EDNS Query
- Default setting in DNSSEC Query
- Default handling of a DNS Response
- Default handling of an EDNS Response
- Default handling of a DNSSEC response
- Appendix A: UDP Message size setting in EDNS
Overview
Almost all test cases emit DNS queries and react to the responses. This document defines the default "setting" of a DNS query and the default handling of "setting" in the DNS response. The meaning of "setting" here will be clear from the specification below.
Application of this specification
This specification applies to all test case specifications that has an explicit reference to this document.
Default setting in DNS Query
A DNS Query has the following default setting. A test case specification can refer to a DNS Query with one or several changes to the Parameters overriding the default values. If a Parameter is specified as "fixed" (with an "X" in that column) then the default value cannot be overidden.
Parameter | Default value | Fixed | Comment |
---|---|---|---|
Protocol | UDP | ||
OpCode | "query" | X | |
QR flag | unset | X | |
AA flag | unset | X | |
TC flag | unset | X | |
RD flag | unset | ||
RA flag | unset | X | |
AD flag | unset | ||
CD flag | unset | ||
RCODE | "NoError" | X | |
Query Name | - | Must be defined in test case | |
Query Type | - | Must be defined in test case | |
Query Class | "IN" | ||
EDNS | no | No OPT record is included |
Default setting in EDNS Query
An EDNS Query inherit the default setting from a DNS Query except for the parameters specified below. If a Parameter is specified as "fixed" (with an "X" in that column) then the default value cannot be overidden.
A test case specification can refer to an EDNS Query with one or several changes to the Parameters.
Parameter | Default value | Fixed | Comment |
---|---|---|---|
EDNS | OPT record included | X | |
EDNS UDP Message size | 512 | See Appendix A | |
EDNS Extended RCODE | no | ||
EDNS Version | 0 | ||
EDNS DO flag | unset | ||
EDNS Z flag | unset | ||
EDNS0 Option | none |
Default setting in DNSSEC Query
A DNSSEC Query inherits the default setting from an EDNS Query except for the parameter specified below. If a Parameter is specified as "fixed" (with an "X" in that column) then the default value cannot be overidden.
A test case specification can refer to a DNSSEC Query with one or several changes to the Parameters.
Parameter | Default value | Fixed | Comment |
---|---|---|---|
EDNS DO flag | set | X | |
EDNS UDP Message size | 1232 | See Appendix A | |
Default handling of a DNS Response
A DNS Response is a response to a DNS Query. Unless specified in the test case specification, the items in the response are handled as listed in the table below.
Validation of DNS message
If a Response Item is specified as "fixed" (with an "X" in that column) then the requirement, as specified under "Default handling", must be met for the response to be considered to be a DNS response.
Response Item | Default handling | Fixed | Comment |
---|---|---|---|
OpCode | Require value to be "response" | X | |
QR flag | Require flag to be set | X | |
AA flag | - | Defined in test case | |
TC flag | Re-query over TCP if set | ||
RD flag | ignore | ||
RA flag | ignore | ||
AD flag | ignore | ||
CD flag | ignore | ||
RCODE | - | Defined in test case | |
Query Name | ignore | ||
Query Type | ignore | ||
Query Class | Require value to be same as in the query | Normally "IN" | |
EDNS | ignore |
Extraction of DNS records
-
Owner name and record type of a DNS record are compared, by default, against Query Name and Query Type in the question section in the query, not in the response.
-
When fetching records from the answer section, these are the default criteria:
- Only records matching Query Name and Query Type are fetched. Any RRSIG records meeting the next criterion are also fetched.
- RRSIG records matching Query Name and covering Query Type are fetched.
- CNAME records are ignored unless Query Type is CNAME.
-
When the test case specification states that a CNAME chain is to be followed, the default handling is to only follow a CNAME chain, and fetch the records, if the CNAME chain is valid.
- The chain is, by default, considered to be valid if the following criteria
are met:
- It must be possible to arrange all CNAME records from the answer section into a contiguous logical chain with a possible addition of a non-CNAME record whose owner name matches the RDATA of the last CNAME record.
- The owner name of the first CNAME record in the chain must match Query Name.
- The last record in the chain must either be a CNAME or a record matching Query Type.
- For each owner name of the CNAME records in the chain there must not be any additional records in the answer section with the same owner name besides RRSIG and NSEC records (that may exist).
- CNAME records not part of a valid CNAME chain are by default ignored.
- The chain is, by default, considered to be valid if the following criteria
are met:
-
Authority and additional sections are by default ignored.
The test case specification may prescribe that CNAME records are handled in a different way than the default above.
Default handling of an EDNS Response
An EDNS response is a response to an EDNS Query. An EDNS Response inherits the default handling from a DNS Response except for the response items specified below. Unless specified in the test case specification, the items in the response are handled using the default handling.
Response Item | Default handling | Comment |
---|---|---|
EDNS | Take note if OPT is missing | Further actions to be specified in the test case specification |
Default handling of a DNSSEC response
A DNSSEC response is a response to a DNSSEC Query. A DNSSEC Response inherits the default handling from a EDNS Response except for the response items specified below. Unless specified in the test case specification, the items in the response are handled using the default handling.
Response Item | Default handling | Comment |
---|---|---|
EDNS DO flag | Take note if DO flag is missing | Further actions to be specified in the test case specification |
Appendix A: UDP Message size setting in EDNS
In non-DNSSEC messages the Zonemaster choice is to set the EDNS UDP Message size to 512 to prevent any firewalls from blocking a response. This guarantees that the response is never larger than the non-EDNS limit, assuming that the remote server respects the setting.
In DNSSEC messages the Zonemaster choice is to set the EDNS UDP Message size to a value that makes fragmentation unlikely, even though fragmentation of UDP messages is supported. 1280 is the smallest MTU supported by IPv6. When 48 bytes for IPv6 and UDP headers are removed the value is 1232 bytes, which is the Zonemaster choice and also the recommendation in DNS flag day 2020.
At the time of writing there is an active IETF draft, not yet an RFC, that recommends 1400 bytes as the EDNS UDP Message size. See IP Fragmentation Avoidance in DNS over UDP.
Choosing a small value is permitted. It might result in more truncated responses and requerying over TCP.
Requirements and normalization of domain names in input
Table of contents
- Objective
- Overview
- Scope
- Inputs
- Summary
- Test procedure
- Outcome(s)
- Special procedural requirements
- Detailed requirements
- Terminology
Objective
This specification defines the requirements for zone name to be tested. The same requirements are put on name server names in the input, if any. If the requirements are not met, then Zonemaster will not start any tests.
This specification also defines some normalization that the domain names (zone name and name server name) will go through. If a domain name is normalized it means that an updated form of the name will be used. The updated form is considered to be equal in meaning.
In order to execute the tests of the zone name from the input it must be a valid domain name. If name servers are provided for the zone in the input, the names of the name servers must also be valid domain names. Both types of domain names, zone names and name server names, are tested and normalized by this test case. The zone name is called Child Zone in Zonemaster test case specifications.
Overview
To be valid, Domain Name must be one of two:
- a valid ASCII domain name, or
- a valid IDN name (Internationalized Domain Name) as of IDNA2008.
The process defined in this specification will normalize Domain Name and output a normalized form to be used by all Zonemaster test cases. The objectives of the normalization are
- Remove leading and trailing white space characters.
- Convert other dot characters to regular dot (or "FULL STOP").
- Create legal IDNA 2008 U-labels from convenient alternative forms.
- Create consistent representation of the same zone name.
The result of the normalization can be a new form of Domain Name to be used by the tests in test cases, the normalized form. If the normalized form is neither a valid ASCII domain name nor a valid IDN name, then Domain Name cannot be used for Zonemaster testing.
If the outcome (see Outcome(s)) is not "fail" then Domain Name in normalized form is returned to be used as input value for Zonemaster test cases.
See the details in the Detailed requirements section below.
References
The following references are consulted for this specification:
Scope
This specification only tests and creates a normalized form of the domain name (zone name or name server name).
In this specification, ASCII is identical to the first 128 characters in Unicode (0000..007F).
RFC 1123, section 2.1, specifies that a domain name label may not start or end with a HYPHEN-MINUS ("-"), only digit or letter. This restriction on HYPHEN-MINUS is disregarded in this specification and is assumed to be handled in test case Syntax02.
The use of the SOLIDUS ("/") and the LOW LINE ("_") in domain name is discussed in the section "ASCII domain name" below. Any restrictions on where in the domain name or label those could or should be used are disregarded in this specification, and are assumed to be handled in test cases Syntax01 and Syntax02.
Inputs
- "Domain Name" - The domain name to be tested and normalized according to this specification. It must be a non-empty string of Unicode characters.
Summary
In the specification there are six scenarios that will result in the domain name not being usable, i.e. it cannot be used for Zonemaster testing. Each scenario is here listed with a message tag, level (always CRITICAL in this specification), suitable argument to be used in the same descriptive message and a message that can be returned to the user.
Message Tag | Level | Arguments | Message ID for message tag |
---|---|---|---|
AMBIGUOUS_DOWNCASING | CRITICAL | unicode_name | Ambiguous downcasing of character "{unicode_name}" in the domain name. Use all lower case instead. |
DOMAIN_NAME_TOO_LONG | CRITICAL | Domain name is too long (more than 253 characters with no final dot). | |
EMPTY_DOMAIN_NAME | CRITICAL | Domain name is empty. | |
INITIAL_DOT | CRITICAL | Domain name starts with dot. | |
INVALID_ASCII | CRITICAL | label | Domain name has an ASCII label ("{label}") with a character not permitted. |
INVALID_U_LABEL | CRITICAL | label | Domain name has a non-ASCII label ("{label}") which is not a valid U-label. |
LABEL_TOO_LONG | CRITICAL | label | Domain name has a label that is too long (more than 63 characters), "{label}". |
REPEATED_DOTS | CRITICAL | Domain name has repeated dots. |
The value in the Level column is the default severity level of the message. Also see the Severity Level Definitions document.
The argument names in the Arguments column lists the arguments used in the message. The argument names are defined in the argument list.
Test procedure
Tables 1, 2, 3 and 4 are found in the Detailed requirements section below.
-
Create the following sets
- Set of permitted ASCII characters in Table 1 below ("Valid ASCII").
- Set of Unicode white space characters in Table 3 below ("White Space")
- Set of Unicode full stops (dot characters) in Table 4 below ("Unicode Full Stops").
-
If Domain Name starts with one or more of White Space then those are removed from Domain Name before further processing.
-
If Domain Name ends with one or more of White Space then those are removed from Domain Name before further processing.
-
If Domain Name is an empty string then output EMPTY_DOMAIN_NAME and terminate these test procedures.
-
If Domain Name contains LATIN CAPITAL LETTER I WITH DOT ABOVE then:
- Output AMBIGUOUS_DOWNCASING and the Unicode name of the code point in question.
- Terminate these test procedures.
-
Create an empty, ordered list of labels ("Domain Labels").
-
Replace all instances of character from Unicode Full Stops in Domain Name with the label separating, regular dot U+002E (see Table 2).
-
If Domain Name is the root zone, i.e. the exact string "." (U+002E), then terminate these test procedures with no message tags.
-
If Domain Name starts with dot (".", U+002E) then output INITIAL_DOT and terminate these test procedures.
-
If Domain Name has any instance of two or more consecutive dots (".", U+002E) then output REPEATED_DOTS and terminate these test procedures.
-
Remove trailing dot (".", U+002E) from Domain Name.
-
Split Domain Name into labels by dot "." (U+002E) and put them in the same order in Domain Labels.
-
For each "Label" in Domain Labels do:
- If all characters in Label are ASCII characters, then do:
- If any character in Label is not listed in Valid ASCII, then output INVALID_ASCII and Label, and terminate these test procedures.
- Else, downcase all upper case characters as specified in section "Upper case" below.
- Else do:
- Assume that Label is a U-label.
- Downcase all upper case characters as specified in section "Upper case" below.
- Normalize Label to NFC as specified in Unicode TR 15. Also see section "Unicode normalization" below.
- Convert Label to an A-label as specified by IDNA2008.
- If the conversion failed, then output INVALID_U_LABEL and Label, and terminate these test procedures.
- Else, replace the U-label in Domain Labels with the A-label from the conversion above.
- Go to next label.
- If all characters in Label are ASCII characters, then do:
-
For each "Label" in Domain Labels do:
- If the length (number of characters) in Label is greater than 63 then output LABEL_TOO_LONG and Label, and terminate these test procedures.
-
Map the labels in Domain Labels back into Domain Name with one dot (".", U+002E), between the labels (no dots if the there is only one label).
-
If the length of Domain Name is longer than 253 characters including the dots, then output DOMAIN_NAME_TOO_LONG and terminate these test procedures.
Outcome(s)
The outcome of the tests in this specification consists of three parts
- The outcome value as defined below in this section.
- The message tags, if any, and data connected to the message tags, if any.
- Domain Name in the normalized form to be used as input value for all test cases. If the outcome value is "fail" then no Domain Name is returned.
The outcome value of this specification is "fail" if there is at least one message outputted. In other cases it is "pass".
Special procedural requirements
The tests and normalizations defined in this specification must always be run and evaluated before any Zonemaster test case is run.
If the outcome from this specification is "fail", then no test cases should be run.
Detailed requirements
This section describes the requirements on the domain name. Besides ensuring that the domain name is valid, these requirements also ensure that the domain name is used in a normalized form.
ASCII domain name
An ASCII domain name is valid if it follows the rules defined in RFC 1123, section 2.1, i.e. only consists of the ASCII characters "a-z", "A-Z", "0-9", "." and "-" with the extension of the following two characters:
- The LOW LINE (underscore, "_") character standardized for e.g. SRV records (RFC 2782) and other record types and special names.
- The SOLIDUS (forward slash, "/") used in reverse zone names for IPv4 networks smaller than /24. See examples in RFC 2317, section 4.
In ASCII names, upper case A-Z are treated as equal to a-z (RFC 1034, section 3.1 and RFC 1035, section 2.3.3). The regular dot, or FULL STOP ("."), is used as label separator (RFC 1034, section 3.1). Also see Table 2 below.
Table 1: A summary of the valid ASCII characters in labels using Unicode codes.
Unicode code or code range | Character or character range | Comment |
---|---|---|
0061..007A | a-z | |
0041..005A | A-Z | Upper case of a-z |
0030..0039 | 0-9 | |
U+002D | - | HYPHEN-MINUS |
U+002F | / | SOLIDUS (forward slash) |
U+005F | _ | LOW LINE (underscore) |
Table 2: A summary of the valid ASCII character between labels using Unicode codes.
Unicode code | Character | Comment |
---|---|---|
U+002E | . | FULL STOP (in this document referred to as "dot") |
The fact that "." (U+002E) character is the delimiter between labels puts some limitations on its use. The first label cannot be en empty label unless that is the only label, i.e. the root domain name. With that exception (covered below) a domain name cannot have a "." (dot) initially. Only the last label can be an empty label (the root label), which means that there cannot be two or more consecutive "." (dots) in a valid domain name. The domain name, as entered to Zonemaster, can either have a final dot or not, and will be normalized as described below.
IDN name
A valid IDN name is a domain named where one or more labels are valid IDN label (RFC 5890) and the remaining labels are valid ASCII labels as defined above. An IDN label can be an A-label or a U-label (RFC 5890, section 2.3.2.1).
-
A valid IDN name where all IDN labels are A-labels will automatically meet the ASCII name requirements above given that the non-IDN labels meet them.
-
A valid IDN name with one or more U-labels can be converted to a valid IDN name where all IDN labels are A-labels.
A valid ASCII name is, by definition, encoded in ASCII. A valid IDN name must either be encoded in ASCII (no U-labels) or in UTF-8 (at least one U-label). If not, Zonemaster will not be able to process the domain name. Note that ASCII is a subset of UTF-8.
A valid ASCII name consists, by definition, of only ASCII characters. A valid IDN name must either consists of only ASCII characters (no U-labels, only A-labels) or consist of at least one non-ASCII Unicode character in at least one label, i.e. at least one U-label. U-labels and A-labels can be mixed, and IDN labels can be mixed with non-IDN labels.
Length limitations
There is a maximum length for the whole domain name and a maximum length for each label. These limitations are defined for a domain name of ASCII characters only, which means that any IDN U-label must be converted to the equivalent A-label before the limitations can be checked.
The maximum total length of a domain name is 253 characters (or octets) if it has no final dot, 254 with the final dot (RFC 1035, section 2.3.4). Note that he RFC defines the limit as 255 octets, but that is the limitation in the DNS packet, where labels separation is done differently.
The maximum length of a label is 63 characters (or octets), RFC 1035, section 2.3.4. A label must be at least one character (octet) long unless it is the label representing the root domain name, which is zero in length and always after the final dot.
Root zone
If the root zone is to be tested, then it must be represented as a single dot "." and in no other way. The label that represents the root zone is an empty label after the dot.
Creating IDNA2008 compatible format
For a discussion on pre-processing the domain name to achieve IDNA compatible U-label from convenient alternative forms see RFC 5895. Unicode normalization is covered by RFC 5891 and Unicode TR 15
Unicode normalization
For Unicode strings normalization processes have been defined to make convert different representations into a normalized form. Specifically, it is required that an IDN label (IDNA2008) is in the so called "Normalized Form C" (NFC) as of RFC 5891, section 5.2.
For ASCII domain names NFC is no issue since they are always in NFC format. For an IDN name the situation is different. The letter "ö" in the IDN domain name "malmö.se" can be represented as either the single Unicode code point U+00F6 or as the Unicode code point sequence "006F 0308". Only the former is in NFC form, which means that if the domain name is entered with the sequence it must be preprocessed before entering IDNA2008 processing, i.e. conversion to A-label format. See Unicode TR 15 for a specification of Unicode normalization and more examples relevant to domain names.
Zonemaster (this specification) requires that any domain name must be converted to NFC form before conversion to A-label. However, the domain name is entered in A-label format, this specification does not require that the corresponding U-label is in NFC format.
White space
In the user interface there is a risk that leading or trailing white space characters are added to the domain name by mistake. The domain name will in this specification be normalized by removing such characters. In Table 3 it is specified what counts as white space characters. It should be pointed out that white space characters within the domain name are not removed, and in the end count as invalid characters.
Table 3: White space characters*
Unicode code | Name |
---|---|
U+0020 | SPACE |
U+0009 | CHARACTER TABULATION |
U+00A0 | NO-BREAK SPACE |
U+2000 | EN QUAD |
U+2001 | EM QUAD |
U+2002 | EN SPACE |
U+2003 | EM SPACE |
U+2004 | THREE-PER-EM SPACE |
U+2005 | FOUR-PER-EM SPACE |
U+2006 | SIX-PER-EM SPACE |
U+2007 | FIGURE SPACE |
U+2008 | PUNCTUATION SPACE |
U+2009 | THIN SPACE |
U+200A | HAIR SPACE |
U+205F | MEDIUM MATHEMATICAL SPACE |
U+3000 | IDEOGRAPHIC SPACE |
U+1680 | OGHAM SPACE MARK |
Full stop
The regular dot "." expected in domain names is a U+002E (FULL STOP), see Table 2 above. There are other characters that may be entered instead due to the script setting. Table 4 lists full stop characters that are to be mapped into the ASCII FULL STOP (Unicode TR 46, section 2.3). That mapping must be done before any verification or checks of the dot and before splitting Domain Name into labels.
Table 4: Non-ASCII dots (Full Stops) using Unicode codes
Unicode code | Character | Name |
---|---|---|
U+FF0E | . | FULLWIDTH FULL STOP |
U+3002 | 。 | IDEOGRAPHIC FULL STOP |
U+FF61 | 。 | HALFWIDTH IDEOGRAPHIC FULL STOP |
Final dot
If the domain name has one final dot it should be removed to create a consistent representation. The exception is the root zone which is always represented by the exact string ".".
Upper case
If the domain name has any letters tagged as "upper case" by the Unicode database, those should be mapped into the equivalent lower case letter. This applies to both ASCII (i.e. "A-Z" mapped into "a-z") in both A- and U-labels and non-ASCII characters found in U-labels (RFC 5895, section 2). This mapping is done before a U-label is converted to A-label. A valid U-label must not contain any upper case letters.
For Zonemaster special rules applies to U+0049 (LATIN CAPITAL LETTER I) and U+0130 (LATIN CAPITAL LETTER I WITH DOT ABOVE).
- LATIN CAPITAL LETTER I is downcased to U+0069 (LATIN SMALL LETTER I) also in Turkish and Azeri locale, i.e. not following the special Unicode rule in those locale (Unicode SpecialCasing).
- Label with LATIN CAPITAL LETTER I WITH DOT ABOVE should be rejected since normal downcasing gives a sequence not reasonable in a domain name context (see "Lowercase Mapping" in LATIN CAPITAL LETTER I WITH DOT ABOVE).
A-label and U-label
DNS can only handle A-labels, not U-label. In the test core suite of Zonemaster only A-labels are used. For normalization, all U-labels are converted to A-labels. Test cases will only handle an ASCII-only Domain Name. Conversion from U-label to A-label should be done as specified for IDNA2008, not IDNA2003.
Terminology
No special terminology for this specification.
Arguments for test case messages
Introduction
This document defines arguments. An argument is defined with its name, its
type of value and its usage and formatting. The arguments are primarily used in
a Zonemaster-Engine message, but can also be used in messages output by
Zonemaster-CLI and Zonemaster-Backend. The messages, in the form of msgid
strings, are primarily defined in the Perl modules for the test cases, e.g.
Basic.pm. The arguments are also used in the translated messages, in the form
of msgstr strings, in the PO files, e.g. fr.po and sv.po. When an
argument is used in a message (msgid or msgstr) it is represented by its
name which is put within curly brackets, e.g. as {ns}
.
When a message is created or updated only arguments defined in this document should be used. If there is not a defined argument that can be used for the message then a new argument must be defined and this document is to be updated.
Multiple instances of the same argument
In a message the same argument can only be used once. In case a message needs more than one instance of an argument, the instances need to be disambiguated. This is done by adding different suffixes to the argument's name. The suffix is an underscore ("_") followed by a descriptive string of lower case "a-z0-9". The suffixed argument name is not to be listed in this document, it is just an instance of the argument name without the specific suffix.
Example of multiple instances
If two arguments of type "List of IP addresses" are to be used in a message, then
both argument names should be ns_ip_list
following the list of defined
arguments below. If the relevant suffixes for those are "nsec" (connected to an
NSEC record type) and "nsec3" (connected to an NSEC3 record type) then two
resulting argument names should be ns_ip_list_nsec
and ns_ip_list_nsec3
,
respectively.
The following is a message (msgid in this case) where this is in use:
The zone is inconsistent on NSEC and NSEC3. NSEC is fetched from nameservers with IP addresses "{ns_ip_list_nsec}". NSEC3 is fetched from nameservers with IP addresses "{ns_ip_list_nsec3}".
Defined arguments
When a suitable argument is found in this list, it should also be used in new and updated messages (msgids and msgstr).
Argument name | Type of value | Description and formatting |
---|---|---|
algo_descr | Text | The human readable description of a DNSSEC algorithm as in table in DNSSEC05. |
algo_mnemo | Text | The mnemonic of a DNSSEC algorithm as in table in DNSSEC05. |
algo_num | Non-negative integer | The numeric value for a DNSSEC algorithm as in table in DNSSEC05. |
cli_arg | Text | Command line (CLI) argument to an option, valid or invalid |
domain | Domain name | A domain name. If "nsname", "mailtarget" or "query_name" is also applicable, use that one instead. |
ds_algo_descr | Text | The human readable description of a DS Digest algorithm. |
ds_algo_mnemo | Text | The mnemonic of a DS Digest algorithm. |
ds_algo_num | Non-negative integer | The numeric value for a DS Digest algorithm. |
int | integer | An integer. If "algo_num", "ds_also_num", "keytag", "soaserial" or some other specific name is applicable, use that instead. |
ip_prefix | IP prefix | An IP prefix (i.e., an IP address with a network mask in CIDR notation). |
keytag | Non-negative integer | A keytag for a DNSKEY record or a keytag used in a DS or RRSIG record. |
label | Domain name label | A single label, i.e. the string between the dots, from a domain name. |
locale | Locale label | A locale label, user provided or taken from the environment |
mailtarget | Domain name | The domain name of the mailserver in an MX RDATA. |
mailtarget_list | List of domain names | A list of name servers, as specified by "mailtarget", separated by ";". |
module | A Zonemaster test module, or all | The name of a Zonemaster test module. |
module_list | List of Zonemaster test modules | A list of Zonemaster test modules, separated by ":". |
ns | Domain name and IP address pair | The name and IP address of a name server, separated by "/". |
ns_ip | IP address | The IP address of a name server. |
ns_ip_list | List of IP addresses | A list of name servers, as specified by "ns_ip", separated by ";". |
ns_list | List of domain name and IP address pairs | A list of name servers, as specified by "ns", separated by ";". |
nsname | Domain name | The domain name of a name server. |
nsname_list | List of domain names | A list of name servers, as specified by "nsname", separated by ";". |
query_name | Domain name | A query domain name (QNAME), as defined in RFC1035, section 4.1.2. |
rcode | An RCODE Name | An RCODE Name (not numeric code) from DNS RCODEs. |
rrtype | A Resource Record TYPE Name | A Resource Record TYPE Name (not numeric code) from DNS RR TYPEs. |
soaserial | Non-negative integer | The numeric value for the SERIAL field in an SOA record. Integer in range 0-4,294,967,295 |
soaserial_list | List of non-negative integers | A list of non-negative integers, as specified by "soaserial", separated by ";". |
string | Text | The content of the RDATA of a TXT resource record. |
testcase | A Zonemaster test case, or all | A test case identifier. |
unicode_name | Unicode name of a code point | The name is a string in ASCII only and in upper case, e.g. "LATIN SMALL LETTER A" |
Preliminary or proposed arguments
The arguments in in this table are not fully defined. If used it should follow the pattern of defined arguments, be fully defined and moved to the list of defined arguments.
Argument name | Type of value | Description and formatting |
---|---|---|
AS number | An Autonomous Space number for an IP address. | |
Address record type (A or AAAA) | Used to tell the difference between IPv4 and IPv6. | |
Count of different SOA RNAMEs. | Total number of different SOA RNAME fields seen. | |
Count of different SOA serial numbers | Total number of different SOA serial numbers seen. | |
Count of different sets of NS name/IP seen. | Total number of different sets of nameserver information seen. | |
Count of different time parameter sets seen | Total number of different sets of SOA time parameters seen. | |
Count of domain names | A count of domain names. | |
Count of nameservers | A count of nameservers. | |
DNS packet size | The size in octets of a DNS packets. | |
DNSKEY key length | The key length for a DNSKEY. The interpretation of this value various quite a bit with the algorithm. Be careful when using it for algorithms that aren't RSA-based. | |
DNSSEC delegation verification failure reason | A somewhat human-readable reason why the delegation step between the tested zone and its parent is not secure. | |
dlength (?) | Domain name label length | The length of a domain name label. |
Duration in seconds | An integer number of seconds. | |
fqdn (?) | FQDN | A fully qualified domain name (with terminating dot). |
fqdnlength (?) | FQDN length | The length of an FQDN. |
IP address | An IPv4 or IPv6 address. | |
IP address or nothing | An IPv4 or IPv6 address, or no value. | |
IP range | An IP range. | |
IP reserved range description | A brief description what an IP range is reserved for. | |
Largest SOA serial number seen | The numerically largest SOA serial value seen. | |
List of AS numbers | A list of Autonomous Space numbers. | |
List of DNSKEY keytags | A list of keytags from DNSKEY records. | |
List of DS keytags | A list of keytags from DS records. | |
List of DS/DNSKEY/RRSIG keytags | A list of keytags from DS, DNSKEY or RRSIG records. | |
List of IP addresses | A list of IP addresses. | |
List of MX domain names | A list of domain names from MX records. | |
List of RR types | A list of RR types, typically from an NSEC or NSEC3 record. | |
List of SOA RNAMEs | A list of RNAME values from SOA records. | |
List of SOA serial numbers | A list of serial number values from SOA records. | |
List of domain names | A list of domain names. | |
NS names from child | A list of nameserver names taken from a zone's child servers. | |
NS names from parent | A list of nameserver names taken from a zone's parent servers. | |
NSEC3 iteration count | An iteration count from an NSEC3PARAM record. | |
Number of DNSKEY RRs in packet | The number of DNSKEY records found in a packet. | |
Number of RRSIG RRs in packet | The number of RRSIG records found in a packet. | |
Number of SOA RRs in packet | The number of SOA records found in a packet. | |
Protocol (UDP or TCP) | The protocol used for a query. | |
RFC reference | A reference to an RFC. | |
rrtype (?) | RR type | The type of RR the message pertains to. |
RRSIG Expiration date | The time when a signature expires. | |
RRSIG validation error message | The human-readable reason why the cryptographic validation of a signature failed. | |
SOA MNAME | The MNAME value from a SOA record. | |
SOA RNAME | The RNAME value from a SOA record. | |
SOA expire | The expire value from a SOA record. | |
SOA expire minimum value | The lowest value considered OK for the SOA expire field. | |
SOA minimum | The minimum value from a SOA record. | |
SOA minimum maximum value | The highest value considered OK for the SOA minimum field. | |
SOA minimum minimum value | The lowest value considered OK for the SOA minimum field. | |
SOA refresh | The refresh value from a SOA record. | |
SOA refresh minimum value | The lowest value considered OK for the SOA refresh field. | |
SOA retry | The retry value from a SOA record. | |
SOA retry minimum value | The lowest value considered OK for the SOA retry field. | |
SOA serial number | The serial number value from a SOA record. | |
Smallest SOA serial number seen | The smallest value seen in a SOA serial field in the tested zone. | |
TLD | The name of a top-level domain. | |
time_t value when RRSIG validation was attempted | The time when an RRSIG validation was attempted, in Unix time_t format. |
Message names marked with a question mark should not be considered stable.
Implemented Test Cases
Index of Text Case specifications is also found in README. Zonemaster-Engine is the repository of the implementation of the Test Cases (the methods).
Address Test Plan
These tests focus on the Address specific test cases of the DNS tests.
This document uses the terminology defined in the Master Test Plan.
Test cases list
Test Case | Test Case Description |
---|---|
ADDRESS01 | Name server address must be globally routable |
ADDRESS02 | Reverse DNS entry exists for name server IP address |
ADDRESS03 | Reverse DNS entry matches name server name |
ADDRESS01: Name server address must be globally routable
Test case identifier
ADDRESS01 Name server address must be globally routable
Objective
In order for the domain and its resources to be accessible, authoritative name servers must have addresses in the routable public addressing space.
IANA is responsible for global coordination of the IP addressing system. Aside its address allocation activities, it maintains reserved address ranges for special uses. These ranges can be categorized into three types : Special purpose IPv4 addresses, Special purpose IPv6 addresses and Multicast reserved addresses.
Inputs
The domain name to be tested.
Ordered description of steps to be taken to execute the test case
-
Obtain the IP addresses of each name server of the domain from the parent using Method4 and child using Method5
-
If any IP address (IPv4 or IPv6) falls within any of the blocks in the below mentioned IANA links, the test case fails:
Outcome(s)
If one name server has one of its addresses matches a forbidden address block, the test fails. If all the name server addresses are outside these forbidden blocks, the test case succeeds.
Special procedural requirements
The registries listed in bullet 2 above must be fetched prior to testing
Intercase dependencies
None.
ADDRESS02: Reverse DNS entry exists for name server IP address
Test case identifier
ADDRESS02 Reverse DNS entry should exist for name server IP address
Objective
Some anti-spam techniques use reverse DNS lookup to allow incoming traffic. In order to prevent name servers to be blocked or blacklisted, DNS administrators should publish PTR records associated to name server addresses.
TODO: Technical reference to be found
Inputs
The domain name to be tested.
Ordered description of steps to be taken to execute the test case
-
Obtain the glue address records of the domain checked using Method4
-
Obtain the IP addresses of each name server of the domain checked using Method5
-
For each IP address, a recursive PTR query must be performed.
-
If any answer of the queries performed in step 3 contains an RCODE other than NOERROR or if the answer does not include a PTR record, this test case fails.
Outcome(s)
If the test case succeeds, its result is a list of addresses with corresponding hostnames which are the result of the PTR queries performed. The result could be represented as a hash table where the keys are the IP addresses and the values their corresponding hostnames.
Special procedural requirements
None.
Intercase dependencies
The outcomes of this test is used as the input of ADDRESS03 test case.
ADDRESS03: Reverse DNS entry matches name server name
Test case identifier
ADDRESS03 Reverse DNS entry matches name server name
Objective
Some anti-spam techniques use reverse DNS lookup to allow incoming traffic. In order to prevent name servers to be blocked or blacklisted, DNS administrators should publish PTR records associated with the name server addresses.
Moreover, as mentioned in paragraph 2.1 of RFC 1912 when a PTR record exists, it must match the host name.
Inputs
The domain name to be tested.
Ordered description of steps to be taken to execute the test case
-
Obtain the IP addresses of each name server of the domain from the child using Method5. These IP addresses can be associated to the name servers through a hash table where each address is a key and the name server it's unique value. Let's call this hash table HASH1.
-
Obtain the reverse DNS entries associated to name servers names as described in test case ADDRESS02. Let's call its outcome HASH2 which consists of IP addresses as keys and hostnames as values. As multiple PTR records are allowed, an IP address can have several corresponding hostnames.
-
Compare HASH2 to HASH1.
Parse the address list of HASH1.
For an address (a) of HASH1, take the corresponding hostname (h) in HASH1. If this hostname (h) is present in the hostnames list associated to this address (a) in HASH2, then the test succeeds for address (a).
If the hostname (h) does not match any hostnames associated to address (a) in HASH2, then the test fails for address (a).
If the test fails for one IP address, the whole test case fails.
Outcome(s)
Multiple addresses and multiple PTR records are allowed. The test succeeds if every name server address has one or more PTR records and one of these records matches the server name. If one address doesn't match, the whole test case fails.
Special procedural requirements
None.
Intercase dependencies
Some of the input of this test comes as the result of test case ADDRESS02. ADDRESS02 must succeed prior to proceed with this test case ADDRESS03.
Basic Test Plan
These are tests of a domain's most basic functionality. If these fail, it will be hard or impossible to perform any other tests at all. The test code should be constructed so that these tests are always run, even if a subset of tests is asked for that would not normally include them.
This document uses the terminology defined in the Master Test Plan.
Test cases list
Test Case | Test Case Description |
---|---|
BASIC01 | Check for the parent zone and the zone itself |
BASIC02 | The domain must have at least one working name server |
BASIC03 | The Broken but functional test |
BASIC01: Check for the parent zone and the zone itself
Test case identifier
BASIC01
Table of contents
- Objective
- Scope
- Inputs
- Summary
- Test procedure
- Outcome(s)
- Special procedural requirements
- Intercase dependencies
- Terminology
Objective
In order for a domain (zone) to work, it must be delegated from a zone higher up in the DNS hierarchy (a parent domain or zone). This Test Case will determine if parent zone and child zones, respectively, exist.
If the test is an undelegated test, however, it can be tested even it is not delegated. Parent zone for undelegated test is disregarded.
If the zone to be tested is the root zone, it has no parent or delegation and will always pass this Test Case.
If no parent can be determined, there cannot be any delegation.
Scope
The algorithm in this test case should match the algorithm in method Get parent zone.
If the child zone does not exist (is not delegated), the only test case to be run after this test case is BASIC03. However, if the test type is an undelegated test, then all other test cases can be run even if the child zone is not delegated.
Inputs
Input for this Test Case:
- "Child Zone" - The label of the domain name (zone) to be tested
- "Root Name Servers" - The IANA List of Root Servers
- "Test Type" - The test type with values "undelegated test" or "normal test".
Summary
Message Tag | Level | Arguments | Message ID for message tag |
---|---|---|---|
B01_CHILD_FOUND | INFO | domain | The zone "{domain}" is found. |
B01_CHILD_IS_ALIAS | NOTICE | domain_child, domain_target, ns_list | "{domain_child}" is not a zone. It is an alias for "{domain_target}". Run a test for "{domain_target}" instead. Returned from name servers "{ns_list}". |
B01_INCONSISTENT_ALIAS | ERROR | domain | The alias for "{domain}" is inconsistent between name servers. |
B01_INCONSISTENT_DELEGATION | ERROR | domain_child, domain_parent, ns_list | The name servers for parent zone "{domain_parent}" give inconsistent delegation of "{domain_child}". Returned from name servers "{ns_list}". |
B01_NO_CHILD | ERROR | domain_child, domain_super | "{domain_child}" does not exist as a DNS zone. Try to test "{domain_super}" instead. |
B01_PARENT_DISREGARDED | INFO | This is a test of an undelegated domain so finding the parent zone is disregarded. | |
B01_PARENT_FOUND | INFO | domain, ns_list | The parent zone is "{domain}" as returned from name servers "{ns_list}". |
B01_PARENT_NOT_FOUND | WARNING | The parent zone cannot be found. | |
B01_PARENT_UNDETERMINED | WARNING | ns_list | The parent zone cannot be determined on name servers "{ns_list}". |
B01_ROOT_HAS_NO_PARENT | INFO | This is a test of the root zone which has no parent zone. | |
B01_SERVER_ZONE_ERROR | DEBUG | query_name, rrtype, ns | Unexpected response on query for "{query_name}" with query type "{rrtype}" to "{ns}". |
The value in the Level column is the default severity level of the message. The severity level can be changed in the Zonemaster-Engine profile. Also see the Severity Level Definitions document.
The argument names in the Arguments column lists the arguments used in the message. The argument names are defined in the argument list.
The name server names are assumed to be available at the time when the msgid is created, if the argument name is "ns" or "ns_list" even when in the "Test procedure" below it is only referred to the IP address of the name servers.
Test procedure
In this section and unless otherwise specified below, the terms "DNS Query" follow the specification for DNS queries as specified in DNS Query and Response Defaults. The handling of the DNS responses on the DNS queries follow, unless otherwise specified below, what is specified for DNS Response in the same specification.
-
If the Child Zone is the root zone (".") then:
- Output B01_CHILD_FOUND with zone name (".").
- Output B01_ROOT_HAS_NO_PARENT.
- Exit the test case.
-
If Test Type is "undelegated test", then:
- Output B01_CHILD_FOUND with zone name equal to Child Zone.
- Output B01_PARENT_DISREGARDED.
- Exit the test case.
-
Create DNS queries:
- Query type DNAME and query name Child Zone ("DNAME Child Query").
-
Create the following empty sets:
- Name server IP and zone name ("Remaining Servers").
- Name server IP and query name ("Handled Servers").
- Parent name server IP and parent zone name ("Parent Found").
- Parent name server IP and parent zone name ("Delegation Found").
- Parent name server IP and parent zone name ("AA NXDomain Found").
- Parent name server IP and parent zone name ("AA SOA Found").
- Parent name server IP and parent zone name ("AA CNAME Found").
- Parent name server IP and parent zone name ("CNAME with Referral Found").
- Parent name server IP, parent zone name and DNAME target ("AA DNAME Found").
- Parent name server IP and parent zone name ("AA NODATA Found").
-
Insert all addresses from Root Name Servers and the root zone name into the Remaining Servers set.
In the loop below, the steps tries to capture the name of the parent zone of Child Zone and the IP addresses of the name servers for that parent zone. This is done using a modified version of the "QNAME minimization" technique RFC 9156. SOA is the query type used for traversing the tree.
-
While the Remaining Servers is non-empty pick next name server IP address and zone name from the set ("Server Address" and "Zone Name") and do:
- Extract and remove Server Address including its Zone Name from Remaining Servers.
- Insert Server Address and Zone Name into Handled Servers.
- Create DNS queries:
- Query type SOA and query name Zone Name ("Zone Name SOA Query").
- Query type NS and query name Zone Name ("Zone Name NS Query").
- Send Zone Name SOA Query to Server Address.
- Output B01_SERVER_ZONE_ERROR with query name Zone Name, query type
SOA and name server IP Server Address and go to next server in
Remaining Servers if one or more of the following matches:
- No DNS response.
- RCODE Name different from NoError in response.
- AA bit not set in response.
- Not exactly one SOA record in answer section
- Owner name of SOA record is not Zone Name.
- Send Zone Name NS Query to Server Address.
- Output B01_SERVER_ZONE_ERROR with query name Zone Name, query type
NS and name server IP Server Address and go to next server in
Remaining Servers if one or more of the following matches:
- No DNS response.
- RCODE Name different from NoError in response.
- AA bit not set in response.
- No NS records in answer section
- Owner name of any of the NS records is not Zone Name.
- Extract the name server names from the NS records and any address records in the additional section.
- Do DNS Lookup of name server names (A and AAAA) not already listed in the
additional section of the response.
- For each IP address add the IP address and Zone Name to the Remaining Servers set unless the IP address is already listed in Handled Servers together with Zone Name.
- Ignore any failing lookups or lookups resulting in NODATA or NXDOMAIN.
- Create "Intermediate Query Name" by copying Zone name as start value.
- Run a loop processing Server Address (jumps back here from the steps
below).
- Extend Intermediate Query Name by adding one more label to the left by copying the equivalent label from Child Zone. (See "Example 1" below.)
- Create a DNS Query with query name Intermediate Query Name and query type SOA ("Intermediate SOA query").
- Send Intermediate SOA Query to Server Address. (See "Example 2" below.)
- Output B01_SERVER_ZONE_ERROR with query name Intermediate Query Name and query type SOA and name server IP Server Address and go to next server in Remaining Servers if there is no DNS response.
- If the response has exactly one SOA record with owner name
Intermediate Query Name in the answer section, with the AA bit
set and RCODE Name NoError then do:
- If Intermediate Query Name is equal to Child Zone then
- Save Server Address and Zone Name to the Parent Found set and to the AA SOA Found set.
- Go to next server in Remaining Servers.
- Else do:
- Create a DNS query with query name Intermediate Query Name and query type NS ("Intermediate NS query").
- Send Intermediate NS Query to Server Address.
- Output B01_SERVER_ZONE_ERROR with query name
Intermediate NS Name and query type NS and name server IP
Server Address and go to next server in Remaining Servers if
one or more of the following matches:
- No DNS response.
- RCODE Name different from NoError in response.
- AA bit not set in response.
- No NS records in answer section.
- Owner name of any of the NS records is not Intermediate Query Name.
- Extract the name server names from the NS records and any address records in the additional section.
- Do DNS Lookup of name server names (A and AAAA) not already listed in the additional section of the response.
- For each IP address add the IP address and Intermediate Query Name to the Remaining Servers set unless the IP address is already listed in Handled Servers together with Intermediate Query Name.
- Set Zone Name to Intermediate Query Name.
- Go back to the start of the loop.
- If Intermediate Query Name is equal to Child Zone then
- Else, if the RCODE Name is NXDomain and the AA is set then do:
- Save Server Address and Zone Name to the AA NXDomain Found set and the Parent Found set.
- Go to next server in Remaining Servers.
- Else, if the response contains a Referral of Intermediate Query Name
then do:
- If Intermediate Query Name is equal to Child Zone then do:
- Save Server Address and Zone Name to the Parent Found set and to the Delegation Found set.
- Else do:
- Extract the name server names from the NS records and any glue records.
- Do DNS Lookup of name server names (A and AAAA) not already listed as glue record or records.
- For each IP address add Server Address and Intermediate Query Name to the Remaining Servers set unless Server Address is already listed in Handled Servers together with Intermediate Query Name.
- Go to next server in Remaining Servers.
- If Intermediate Query Name is equal to Child Zone then do:
- Else, if the RCODE Name is NoError and the AA is set then do:
- If Intermediate Query Name is not equal to Child Zone then go back to the start of the loop.
- Else do:
- If the response has a CNAME record with Child Zone as owner
name in the answer section, then do:
- Save Server Address and Zone Name to the Parent Found set and to the AA CNAME Found set.
- Go to next server in Remaining Servers.
- Else do:
- Send a DNAME Child Query to the name server IP address.
- If there is a response with the AA flag set, the RCODE Name
NoError and a DNAME record with Child Zone as owner name in
the answer section, then
- Save Server Address and Zone Name to the Parent Found set.
- Save Server Address, Zone Name and the DNAME target (RDATA value) to the AA DNAME Found set.
- Else (no response or some other response than above) save the Server Address and Zone Name to the Parent Found set and to the AA NODATA Found set.
- Go to next server in Remaining Servers.
- If the response has a CNAME record with Child Zone as owner
name in the answer section, then do:
- Else, if the response is a Referral with a CNAME record with
Child Zone as owner name in the answer section, then
- Save Server Address and Zone Name to the Parent Found set and to the CNAME with Referral Found set.
- Go to next server in Remaining Servers.
- Else, output B01_SERVER_ZONE_ERROR with query name Intermediate NS Name, query type SOA and name server IP Server Address and go to next server in Remaining Servers.
-
If the Parent Found set is non-empty, then
- For each parent zone name output B01_PARENT_FOUND, parent zone name and the set of name server IP addresses for that name.
- If not all members of the set have the same parent zone then output B01_PARENT_UNDETERMINED and the whole set of name server IP addresses.
-
If the Parent Found set is empty, then output B01_PARENT_NOT_FOUND.
-
If one or both of the Delegation Found and the AA SOA Found sets are non-empty, then do:
- Output B01_CHILD_FOUND with Child Zone.
- If one or more of the following five sets are also non-empty then output
B01_INCONSISTENT_DELEGATION with Child Zone, parent zone name and
the combined set of name server IP addresses from all five sets.
- AA NXDomain Found
- AA CNAME Found
- CNAME with Referral Found
- AA DNAME Found
- AA NODATA Found
-
If both of the Delegation Found and the AA SOA Found sets are empty, then do:
- Create "Superdomain" as a copy of Child Zone with the first label removed.
- Output B01_NO_CHILD with Child zone and Superdomain.
-
If the AA DNAME Found set is non-empty then do:
- For each DNAME target in the set output B01_CHILD_IS_ALIAS with name server IP list, Child Zone and the DNAME target.
- If not all members of the set have the same DNAME target, output B01_INCONSISTENT_ALIAS with Child Zone.
Examples referred to from the steps.
Example 1: If Child Zone is "foo.bar.xa" and Intermediate Query Name is "." (root zone) then Intermediate Query Name becomes "xa". If it is "xa", it will become "bar.xa" instead.
Example 2: An "bar.xa SOA" query to a name server for "xa".
Outcome(s)
The outcome of this Test Case is "fail" if there is at least one message with the severity level ERROR or CRITICAL.
The outcome of this Test Case is "warning" if there is at least one message with the severity level WARNING, but no message with severity level ERROR or CRITICAL.
In other cases, no message or only messages with severity level INFO or NOTICE, the outcome of this Test Case is "pass".
Special procedural requirements
If either IPv4 or IPv6 transport is disabled, skip Sending queries over that transport protocol. A message will be outputted reporting that the transport protocol has been skipped.
The Child Zone must be a valid name meeting "Requirements and normalization of domain names in input".
Intercase dependencies
None.
Terminology
-
"Direct Subdomain" - Domain A is considered to be a "direct Subdomain" to domain B if domain A is just the addition of one label at the least significant (left) side, e.g. "foo.domain.com" is a direct subdomain to "domain.com".
-
"DNS Lookup" - The term is used when a recursive lookup is used, though any changes to the DNS tree introduced by an undelegated test must be respected. Compare with "Send".
-
"Non-Referral" - See "Referral".
-
"Referral" - A DNS response with RCODE Name NoError, AA flag unset and NS records in the authority section. The answer section is empty or with CNAME record or records. If the query type is CNAME, then the answer section must be empty (does not apply to this test case). The additional section may contain address records (A and AAAA) for the name server names from the NS (glue records).
-
"Send" - The term "send" (to an IP address) is used when a DNS query is sent to a specific name server. Compare with "DNS Lookup".
BASIC02: The domain must have at least one working name server
Test case identifier
BASIC02
Table of contents
- Objective
- Scope
- Inputs
- Summary
- Test procedure
- Outcome(s)
- Special procedural requirements
- Intercase dependencies
- Terminology
Objective
In order for the domain to work, it must have at least one name server that can answer queries about the domain. This test case will verify that.
Scope
If this test fails, it is not meaningful to continue Zonemaster testing and the whole testing process, except for the Basic03 test, is aborted.
Inputs
- The domain name to be tested ("Child Zone").
- "Test Type" - The test type with values "undelegated test" or "normal test".
- If undelegated test:
- The list of name servers for the child zone ("Undelegated NS").
- Any IP addresses of the in-bailiwick undelegated NS ("Undelegated Glue IP").
- Any IP addresses of the out-of-bailiwick undelegated NS ("Undelegated Non-Glue IP").
Summary
Message Tag | Level | Arguments | Message ID for message tag |
---|---|---|---|
B02_AUTH_RESPONSE_SOA | INFO | ns_list, domain | Authoritative answer on SOA query for "{domain}" is returned by name servers "{ns_list}". |
B02_NO_DELEGATION | CRITICAL | domain | There is no delegation (name servers) for "{domain}" which means it does not exist as a zone. |
B02_NO_WORKING_NS | CRITICAL | domain | There is no working name server for "{domain}" so it is unreachable. |
B02_NS_BROKEN | ERROR | ns | Broken response from name server "{ns}" on an SOA query. |
B02_NS_NOT_AUTH | ERROR | ns | Name server "{ns}" does not give an authoritative answer on an SOA query. |
B02_NS_NO_IP_ADDR | ERROR | nsname | Name server "{nsname}" cannot be resolved into an IP address. |
B02_NS_NO_RESPONSE | WARNING | ns | Name server "{ns}" does not respond to an SOA query. |
B02_UNEXPECTED_RCODE | ERROR | ns, rcode | Name server "{ns}" responds with an unexpected RCODE name ("{rcode}") on an SOA query. |
The value in the Level column is the default severity level of the message. The severity level can be changed in the Zonemaster-Engine profile. Also see the Severity Level Definitions document.
The argument names in the Arguments column lists the arguments used in the message. The argument names are defined in the argument list.
Test procedure
In this section and unless otherwise specified below, the terms "DNS Query" follow the specification for DNS queries as specified in DNS Query and Response Defaults. The handling of the DNS responses on the DNS queries follow, unless otherwise specified below, what is specified for DNS Response in the same specification.
-
Create a DNS Query with query type SOA and query name Child Zone ("SOA Query").
-
Create the following empty sets:
- Name server name and IP address ("Auth Response on SOA Query").
- Name server name and IP address ("Broken NS").
- Name server name and IP address ("NS not auth").
- Name server name ("NS Cannot Resolve Into IP").
- Name server name and IP address ("No Response From NS").
- Name server name, IP address and RCODE Name ("Unexpected RCODE").
- Name server name with IP address set ("Delegation NS").
-
Populate the set Delegation NS with name and the set of IP addresses for each name from the name servers of the delegation of Child Zone.
- If the test is an undelegated test, then:
- Use Undelegated NS, Undelegated Glue IP and Undelegated Non-Glue IP.
- If any out-of-bailiwick name server name in the set has no IP address then do a recursive lookup for address records (both IPv4 and IPv6) for that name and add resolved addresses, if any, to the set.
- Else, do:
- Retrieve the NS records for Child Zone using Method 2 and the IP addresses (glue records) for any in-bailiwick name servers using Method 4.
- Retrieve the IP addresses for any out-of-bailiwick name servers using recursive lookup for address records (both IPv4 and IPv6) for that name and add resolved addresses, if any, to the set.
- If the test is an undelegated test, then:
-
If the Delegation NS set is empty, then do:
- Output B02_NO_DELEGATION with Child Zone name.
- Exit these test procedures.
-
Else, for each name server name in the Delegation NS set do:
- If the name server name has no IP address then add the name server name to the NS Cannot Resolve Into IP set.
- Else, for each IP address for the name server name do:
- Send SOA Query to the name server IP.
- If there is no DNS Response, then add the name server name and IP address to the No Response From NS set.
- Else, if the RCODE Name is not "NoError" in the DNS Response, then add the name server name, IP address and the RCODE Name to the Unexpected RCODE set.
- Else, if the AA flag is not set in the DNS Response, then add the name server name and IP address to the NS not auth set.
- Else do:
- If the answer section in the DNS Response contains an SOA record with Child Zone as owner name, then add the name server name and IP address to the Auth Response on SOA Query set.
- Else, add the name server name and IP address to the Broken NS set.
-
If the Auth Response on SOA Query set is non-empty, then:
- Output B02_AUTH_RESPONSE_SOA with a list of name server name and IP address pairs derived from the set and with Child Zone name.
- Exit these test procedures.
-
Else do:
- Output B02_NO_WORKING_NS with Child Zone name.
- If the Broken NS set is non-empty then for each name server name and IP address pair from the set output B02_NS_BROKEN with the pair.
- If the NS not auth set is non-empty then for each name server name and IP address pair from the set output B02_NS_NOT_AUTH with the pair.
- If the NS Cannot Resolve Into IP set is non-empty then for each name server name output B02_NS_NO_IP_ADDR with the name server name.
- If the No Response From NS set is non-empty then for each name server name and IP address pair from the set output B02_NS_NO_RESPONSE with the pair.
- If the Unexpected RCODE set is non-empty then for each name server name and IP address pair from the set output B02_UNEXPECTED_RCODE with the pair and the RCODE Name for that pair in the set.
Outcome(s)
The outcome of this Test Case is "fail" if there is at least one message with the severity level ERROR or CRITICAL.
The outcome of this Test Case is "warning" if there is at least one message with the severity level WARNING, but no message with severity level ERROR or CRITICAL.
In other cases, no message or only messages with severity level INFO or NOTICE, the outcome of this Test Case is "pass".
Special procedural requirements
If either IPv4 or IPv6 transport is disabled, skip sending queries over that transport protocol. A message will be outputted reporting that the transport protocol has been skipped.
The Child Zone must be a valid name meeting "Requirements and normalization of domain names in input".
Terminology
The terms "in-bailiwick", "out-of-bailiwick" and "glue record" are defined in RFC 8499, section 7, pages 24-25. In this document, the term "in-bailiwick" is limited to the meaning "in domain" in RFC 8499. The term "out-of-bailiwick" means what is not "in-bailiwick, in domain", in this document.
Intercase dependencies
None.
BASIC03: The Broken but functional test
Test case identifier
BASIC03 The Broken but functional test
Objective
The case where the delegation for a domain is too broken to be fully tested but functional enough for simple web browsing should be detected. This test should only be performed if the BASIC02 test has failed, in order to explain why the domain seemingly works but otherwise is untestable.
Inputs
The label of the domain name to be tested.
Ordered description of steps to be taken to execute the test case
- Retrieve the IP addresses from the parent delegation using Method 4. For name server that are out-of-bailiwick, do separate recursive queries to retrieve the IP addresses of those names.
- An A query for the child domain name with the label 'www' prepended is sent to each address from the input parameters, and the responses recorded.
- If no answer from the above queries contain any A record, this test fails.
Outcome(s)
If at least one recorded response contains at least one A record for the requested name, this test succeeds.
Special procedural requirements
This test should only be performed if the BASIC02 test has failed.
Intercase dependencies
Only perform this test if BASIC02 fails.
Connectivity Test Plan
This document uses the terminology defined in the Master Test Plan.
Test cases list
Test Case | Test Case Description |
---|---|
CONNECTIVITY01 | UDP connectivity to name servers |
CONNECTIVITY02 | TCP connectivity to name servers |
CONNECTIVITY03 | AS Diversity |
CONNECTIVITY04 | IP Prefix Diversity |
CONNECTIVITY01: UDP connectivity to name servers
Test case identifier
CONNECTIVITY01
Table of contents
- Objective
- Scope
- Inputs
- Summary
- Test procedure
- Outcome(s)
- Special procedural requirements
- Intercase dependencies
- Terminology
Objective
UDP is the fundamental protocol to reach a general purpose name server hosting a zone, "DNS servers MUST be able to service UDP [...]" (RFC 1123, section 6.1.3.2, page 75), also restated in RFC 7766, section 5.
This Test Case will verify if the name servers of Child Zone are reachable over UDP. The name servers tested are both those in the delegation of Child Zone and those in the NS records in the Child Zone itself.
Most Zonemaster Test Cases will query the name servers in the delegation or the name servers appointed by the NS records in the zone for the NS or SOA record, or both. It is crucial that problems are reported, but instead of letting several Test Cases report the same problems found, most Test Cases assume that this test case is run. Only this Test Case will report problems found in the following areas over UDP:
- Name Server not responding to a query without EDNS.
- Name Server not including SOA record of Child Zone in the answer section in the response on a SOA query for Child Zone.
- Name Server not including NS record of Child Zone in the answer section in the response on an NS query for Child Zone.
- Name Server not setting the AA flag in a response with SOA or NS in answer section.
- Name Server responding with unexpected RCODE Name (any except "NoError") on query for SOA or NS for Child Zone.
In addition, this test case will output a message if transport over IPv4 or IPv6 has been disabled.
Scope
The only UDP port defined for DNS is port 53 (RFC 1035, section 4.2.1), and that is the only port used by this and other Test Cases for DNS queries to the name servers.
Inputs
- "Child Zone" - The domain name to be tested.
Summary
Message Tag | Level | Arguments | Message ID for message tag |
---|---|---|---|
CN01_IPV4_DISABLED | NOTICE | ns_list | IPv4 is disabled. No DNS queries are sent to these name servers: "{ns_list}". |
CN01_IPV6_DISABLED | NOTICE | ns_list | IPv6 is disabled. No DNS queries are sent to these name servers: "{ns_list}". |
CN01_MISSING_NS_RECORD_UDP | WARNING | ns | Nameserver {ns} responds to a NS query with no NS records in the answer section over UDP. |
CN01_MISSING_SOA_RECORD_UDP | WARNING | ns | Nameserver {ns} responds to a SOA query with no SOA records in the answer section over UDP. |
CN01_NO_RESPONSE_NS_QUERY_UDP | WARNING | ns | Nameserver {ns} does not respond to NS queries over UDP. |
CN01_NO_RESPONSE_SOA_QUERY_UDP | WARNING | ns | Nameserver {ns} does not respond to SOA queries over UDP. |
CN01_NO_RESPONSE_UDP | WARNING | ns | Nameserver {ns} does not respond to any queries over UDP. |
CN01_NS_RECORD_NOT_AA_UDP | WARNING | ns | Nameserver {ns} does not give an authoritative response on an NS query over UDP. |
CN01_SOA_RECORD_NOT_AA_UDP | WARNING | ns | Nameserver {ns} does not give an authoritative response on an SOA query over UDP. |
CN01_UNEXPECTED_RCODE_NS_QUERY_UDP | WARNING | ns, rcode | Nameserver {ns} responds with an unexpected RCODE ({rcode}) on an NS query over UDP. |
CN01_UNEXPECTED_RCODE_SOA_QUERY_UDP | WARNING | ns, rcode | Nameserver {ns} responds with an unexpected RCODE ({rcode}) on an SOA query over UDP. |
CN01_WRONG_NS_RECORD_UDP | WARNING | ns, domain_found, domain_expected | Nameserver {ns} responds with a wrong owner name ({domain_found} instead of {domain_expected}) on NS queries over UDP. |
CN01_WRONG_SOA_RECORD_UDP | WARNING | ns, domain_found, domain_expected | Nameserver {ns} responds with a wrong owner name ({domain_found} instead of {domain_expected}) on SOA queries over UDP. |
The value in the Level column is the default severity level of the message. The severity level can be changed in the Zonemaster-Engine profile. Also see the Severity Level Definitions document.
The argument names in the Arguments column lists the arguments used in the message. The argument names are defined in the argument list.
Test procedure
In this section and unless otherwise specified below, the term "DNS Query" follows the specification for DNS queries as specified in DNS Query and Response Defaults. The handling of the DNS responses on the DNS queries follow, unless otherwise specified below, what is specified for DNS Response in the same specification.
-
Create DNS Queries:
- Query type SOA and query name Child Zone ("SOA Query").
- Query type NS and query name Child Zone ("NS Query").
-
Obtain the set of name server IP addresses using Method4 and Method5 ("Name Server IP").
-
If IPv4 is disabled then do:
- Extract all name servers with IPv4 address from Name Server IP.
- If the set of IPv4 name servers is non-empty then output CN01_IPV4_DISABLED with the set of IPv4 name servers (names and IP addresses).
-
If IPv6 is disabled then do:
- Extract all name servers with IPv6 address from Name Server IP.
- If the set of IPv6 name servers is non-empty then output CN01_IPV6_DISABLED with the set of IPv6 name servers (names and IP addresses).
-
For each name server in Name Server IP do:
- Send SOA Query and NS Query to the name server and collect the DNS Responses.
- If there is no DNS response on neither query, then:
- Output CN01_NO_RESPONSE_UDP with name and IP address of the name server.
- Go to next name server.
- Else:
- Process the response on SOA Query:
- If there is no DNS response, then output CN01_NO_RESPONSE_SOA_QUERY_UDP with name and IP address of the name server.
- Else, if RCODE Name is not "NoError" then output CN01_UNEXPECTED_RCODE_SOA_QUERY_UDP with RCODE Name and name and IP address of the name server.
- Else, if there is no SOA record in the answer section, then output CN01_MISSING_SOA_RECORD_UDP with name and IP address of the name server.
- Else, if the SOA record has owner name other than Child Zone then output CN01_WRONG_SOA_RECORD_UDP with name and IP address of the name server, the SOA record owner name and Child Zone.
- Else, if AA flag is unset, then output CN01_SOA_RECORD_NOT_AA_UDP with name and IP address of the name server.
- Process the response on NS Query:
- If there is no DNS Response, then output CN01_NO_RESPONSE_NS_QUERY_UDP with name and IP address of the name server.
- Else, if RCODE Name is not "NoError" then output CN01_UNEXPECTED_RCODE_NS_QUERY_UDP with RCODE Name and name and IP address of the name server.
- Else, if there is no NS record in the answer section, then output CN01_MISSING_NS_RECORD_UDP with name and IP address of the name server.
- Else, if the NS record has owner name other than Child Zone then output CN01_WRONG_NS_RECORD_UDP with name and IP address of the name server, the NS record owner name and Child Zone.
- Else, if AA flag is unset, then output CN01_NS_RECORD_NOT_AA_UDP with name and IP address of the name server.
- Process the response on SOA Query:
Outcome(s)
The outcome of this Test Case is "fail" if there is at least one message with the severity level ERROR or CRITICAL.
The outcome of this Test Case is "warning" if there is at least one message with the severity level WARNING, but no message with severity level ERROR or CRITICAL.
In other cases, no message or only messages with severity level INFO or NOTICE, the outcome of this Test Case is "pass".
Special procedural requirements
If either IPv4 or IPv6 transport is disabled, skip sending queries over that transport protocol.
Intercase dependencies
None.
Terminology
No special terminology for this test case.
CONNECTIVITY02: TCP connectivity to name servers
Test case identifier
CONNECTIVITY02
Table of contents
- Objective
- Scope
- Inputs
- Summary
- Test procedure
- Outcome(s)
- Special procedural requirements
- Intercase dependencies
- Terminology
Objective
TCP is a protocol to reach a general purpose name server hosting a zone, "All general-purpose DNS implementations MUST support [...] TCP transport" (RFC 7766, section 5).
This Test Case will verify if the name servers of Child Zone are reachable over TCP. The name servers tested are both those in the delegation of Child Zone and those in the NS records in the Child Zone itself.
This Test Case will mimic the tests done by Connectivity01, but over TCP instead:
- Name Server responding to a query.
- Name Server including SOA record of Child Zone in the answer section in the response on a SOA query for Child Zone.
- Name Server including NS record of Child Zone in the answer section in the response on an NS query for Child Zone.
- Name Server setting the AA flag in a response with SOA or NS in answer section.
- Name Server responding with expected RCODE Name ("NoError") on query for SOA or NS for Child Zone.
Scope
The only TCP port defined for DNS is port 53 (RFC 1035, section 4.2.1), and that is the only port used by this and other Test Cases for DNS queries to the name servers.
UDP connectivity is tested by Test Case Connectivity01.
Inputs
- "Child Zone" - The domain name to be tested.
Summary
Message Tag | Level | Arguments | Message ID for message tag |
---|---|---|---|
CN02_MISSING_NS_RECORD_TCP | WARNING | ns | Nameserver {ns} responds to a NS query with no NS records in the answer section over TCP. |
CN02_MISSING_SOA_RECORD_TCP | WARNING | ns | Nameserver {ns} responds to a SOA query with no SOA records in the answer section over TCP. |
CN02_NO_RESPONSE_NS_QUERY_TCP | WARNING | ns | Nameserver {ns} does not respond to NS queries over TCP. |
CN02_NO_RESPONSE_SOA_QUERY_TCP | WARNING | ns | Nameserver {ns} does not respond to SOA queries over TCP. |
CN02_NO_RESPONSE_TCP | WARNING | ns | Nameserver {ns} does not respond to any queries over TCP. |
CN02_NS_RECORD_NOT_AA_TCP | WARNING | ns | Nameserver {ns} does not give an authoritative response on an NS query over TCP. |
CN02_SOA_RECORD_NOT_AA_TCP | WARNING | ns | Nameserver {ns} does not give an authoritative response on an SOA query over TCP. |
CN02_UNEXPECTED_RCODE_NS_QUERY_TCP | WARNING | ns, rcode | Nameserver {ns} responds with an unexpected RCODE ({rcode}) on an NS query over TCP. |
CN02_UNEXPECTED_RCODE_SOA_QUERY_TCP | WARNING | ns, rcode | Nameserver {ns} responds with an unexpected RCODE ({rcode}) on an SOA query over TCP. |
CN02_WRONG_NS_RECORD_TCP | WARNING | ns, , domain_found, domain_expected | Nameserver {ns} responds with a wrong owner name ({domain_found} instead of {domain_expected}) on NS queries over TCP. |
CN02_WRONG_SOA_RECORD_TCP | WARNING | ns, , domain_found, domain_expected | Nameserver {ns} responds with a wrong owner name ({domain_found} instead of {domain_expected}) on SOA queries over TCP. |
The value in the Level column is the default severity level of the message. The severity level can be changed in the Zonemaster-Engine profile. Also see the Severity Level Definitions document.
The argument names in the Arguments column lists the arguments used in the message. The argument names are defined in the argument list.
Test procedure
In this section and unless otherwise specified below, the term "DNS Query" follows the specification for DNS queries as specified in DNS Query and Response Defaults. The handling of the DNS responses on the DNS queries follow, unless otherwise specified below, what is specified for DNS Response in the same specification.
-
Create DNS Queries:
- Query type SOA and query name Child Zone over TCP ("SOA Query TCP").
- Query type NS and query name Child Zone over TCP ("NS Query TCP").
-
Obtain the set of name server IP addresses using Method4 and Method5 ("Name Server IP").
-
For each name server in Name Server IP do:
- Send SOA Query TCP and NS Query TCP to the name server and collect the DNS Responses.
- If there is no DNS response on neither query, then:
- Output CN02_NO_RESPONSE_TCP with name and IP address of the name server.
- Go to next name server.
- Else:
- Process the response on SOA Query TCP:
- If there is no DNS response, then output CN02_NO_RESPONSE_SOA_QUERY_TCP with name and IP address of the name server.
- Else, if RCODE Name is not "NoError" then output CN02_UNEXPECTED_RCODE_SOA_QUERY_TCP with RCODE Name and name and IP address of the name server.
- Else, if there is no SOA record in the answer section, then output CN02_MISSING_SOA_RECORD_TCP with name and IP address of the name server.
- Else, if the SOA record has owner name other than Child Zone then output CN02_WRONG_SOA_RECORD_TCP with name and IP address of the name server, the SOA record owner name and Child Zone.
- Else, if AA flag is unset, then output CN02_SOA_RECORD_NOT_AA_TCP with name and IP address of the name server.
- Process the response on NS Query TCP:
- If there is no DNS Response, then output CN02_NO_RESPONSE_NS_QUERY_TCP with name and IP address of the name server.
- Else, if RCODE Name is not "NoError" then output CN02_UNEXPECTED_RCODE_NS_QUERY_TCP with RCODE Name and name and IP address of the name server.
- Else, if there is no NS record in the answer section, then output CN02_MISSING_NS_RECORD_TCP with name and IP address of the name server.
- Else, if the NS record has owner name other than Child Zone then output CN02_WRONG_NS_RECORD_TCP with name and IP address of the name server, the NS record owner name and Child Zone.
- Else, if AA flag is unset, then output CN02_NS_RECORD_NOT_AA_TCP with name and IP address of the name server.
- Process the response on SOA Query TCP:
Outcome(s)
The outcome of this Test Case is "fail" if there is at least one message with the severity level ERROR or CRITICAL.
The outcome of this Test Case is "warning" if there is at least one message with the severity level WARNING, but no message with severity level ERROR or CRITICAL.
In other cases, no message or only messages with severity level INFO or NOTICE, the outcome of this Test Case is "pass".
Special procedural requirements
If either IPv4 or IPv6 transport is disabled, skip sending queries over that transport protocol.
Intercase dependencies
None.
Terminology
No special terminology for this Test Case.
CONNECTIVITY03: AS Diversity
Test case identifier
CONNECTIVITY03
Objective
The objective in this test is to verify that all IP addresses of the domain's authoritative name servers are announced from different ASNs (autonomous system number). See RFC 1930 and Wikipedia for an explanation of AS (autonomous system).
This test is done separately on IPv4 and IPv6, and both must match the criterion.
RFC 2182, section 3.1, clearly specifies that distinct authoritative name servers for a child domain should be placed in different topological and geographical locations. The objective is to minimise the likelihood of a single failure disabling all of them.
Inputs
- "Child Zone" - The domain name to be tested.
- "ASN Database" - The database of ASN data to be used. Possible values are "RIPE" and "Cymru" (the default value).
- "Cymru Base Name" - If the ASN Database is "Cymru", the default value is "asnlookup.zonemaster.net".
- "Ris Whois Server" - If the ASN Database is "RIPE", the default value is "riswhois.ripe.net".
Ordered description of steps to be taken to execute the test case
-
Obtain the total set of IP addresses of the name servers for the Child Zone using Method4 and Method5 and split those IP addresses into one set of IPv4 addresses ("NS IPv4") and one set of IPv6 addresses ("NS IPv6"). (One of two sets may be empty.)
-
For each IP address in the set NS IPv4 and NS IPv6, respectively, determine the ASN set announcing the IP address using either the Cymru database or the RIPE database as described in separate sections below. Create two sets of ASN data ("NS IPv4 ASN" and "NS IPv6 ASN", respectively).
-
Analyze the NS IPv4 ASN set:
- If NS IPv4 ASN is empty (no IPv4 address) do nothing.
- Else, if all IPv4 addresses are announced from one and the same ASN, output IPV4_ONE_ASN.
- Else, if all IPv4 addresses are announced from the same set of multiple ASNs, output IPV4_SAME_ASN.
- Else, output IPV4_DIFFERENT_ASN.
-
Analyze the NS IPv6 ASN set:
- If NS IPv6 ASN is empty (no IPv6 address) do nothing.
- Else, if all IPv6 addresses are announced from one and the same ASN, output IPV6_ONE_ASN.
- Else, if all IPv6 addresses are announced from the same set of multiple ASNs, output IPV6_SAME_ASN.
- Else, output IPV6_DIFFERENT_ASN.
Outcome(s)
The outcome of this Test Case is "fail" if there is at least one message with the severity level ERROR or CRITICAL.
The outcome of this Test Case is "warning" if there is at least one message with the severity level WARNING, but no message with severity level ERROR or CRITICAL.
In other cases the outcome of this Test Case is "pass".
Message | Default severity level |
---|---|
EMPTY_ASN_SET | NOTICE |
ERROR_ASN_DATABASE | NOTICE |
IPV4_ONE_ASN | WARNING |
IPV4_SAME_ASN | NOTICE |
IPV4_DIFFERENT_ASN | INFO |
IPV6_ONE_ASN | WARNING |
IPV6_SAME_ASN | NOTICE |
IPV6_DIFFERENT_ASN | INFO |
Special procedural requirements
This test case is dependent on one of two possible services that can provide ASN lookup, RIPE or Cymru. The service must be available over the network.
Cymru ASN lookup
The Cymru lookup method is described on the Team Cymru IP to ASN Mapping
using DNS lookup, but the default data comes from bgp.tools (Port 179 Ltd
in England and Wales) and is continuously being mapped into
asnlookup.zonemaster.net
by the Zonemaster project. Data is fetched from
https://bgp.tools/table.txt. The Cymru source can also be used, if
requested.
- Prepend the Cymru Base Name with the label "origin" (IPv4) or "origin6" (IPv6). Example of expanded basenames ("expanded base name"):
origin.asnlookup.zonemaster.net
origin6.asnlookup.zonemaster.net
-
Reverse the IP address with the same method as is used for reverse lookup. For description see RFC 1035, section 3.5, for IPv4 and RFC 3596, section 2.5, for IPv6.
-
Prepend the expanded base name with the reversed IP address. For description see IP to ASN Mapping.
-
Send a DNS query for the TXT record of the full name created in step 3.
-
If either the DNS response has RCODE "NXDOMAIN" or the DNS response has RCODE "NOERROR" but empty answer section, output EMPTY_ASN_SET and end these steps for Cymru look-up of the specific IP address.
-
If there is no response (timeout) or the DNS response does not have the RCODE "NOERROR", output ERROR_ASN_DATABASE and end these steps for Cymru look-up of the specific IP address.
-
The expected response is a non-empty string in the TXT record or records. See IP to ASN Mapping for examples.
-
Do the following:
- Split the string or strings into fields.
- If there are multiple strings (TXT records), ignore all strings except for the string with the most specific subnet.
- Extract the ASN or ASNs.
- If it was not possible to extract the ASN or ASNs, output ERROR_ASN_DATABASE and end these steps for Cymru look-up of the specific IP address (the response was malformed).
-
Create the ASN set, for the IP address, from the ASN or ASNs from the steps above and use it for the further processing.
RIPE ASN lookup
The RIPE ASN lookup is described on the RIPE RISwhois page.
-
Construct a query string by prepending the IP address with " -F -M ". Using "192.0.2.10" as an example, the query string will be the following (the leading space is intentional)
" -F -M 192.0.2.10"
-
Send the query string to the Ris Whois Server on port 43 with the nicname (whois) protocol. Example of command line command on unix:
whois -h riswhois.ripe.net " -F -M 192.0.2.10"
-
Do the following:
- The non-empty line not prepended with "%" contains the string with data (no or one such line).
- Check if there is no string with data (empty reply). If so, output EMPTY_ASN_SET and end these steps for RIPE look-up of the specific IP address.
- If there is no response from the Ris Whois Server, output ERROR_ASN_DATABASE and end these steps for RIPE look-up of the specific IP address.
- The first field has the ASN or list of ASNs. Split that into ASNs.
- If it was not possible to extract the ASN or ASNs, output ERROR_ASN_DATABASE and end these steps (the response was malformed).
-
Create the ASN set, for the IP address, from the ASN or ASNs from the steps above and use it for the further processing.
Intercase dependencies
None
CONNECTIVITY04: IP Prefix Diversity
Test case identifier
CONNECTIVITY04
Table of contents
- Objective
- Scope
- Inputs
- Summary
- Test procedure
- Outcome(s)
- Special procedural requirements
- Prefix lookup methods
- Intercase dependencies
- Terminology
Objective
The objective in this Test Case is to verify that all IP addresses of the domain's authoritative name servers are not announced from the same IP prefix.
RFC 2182, section 3.1, clearly specifies that distinct authoritative name servers for a child domain should be placed in different topological and geographical locations. The objective is to minimise the likelihood of a single failure disabling all of them.
Scope
It is assumed that Child Zone is also tested and reported by Connectivity01. This Test Case will just ignore non-responsive name servers or name servers not giving a correct DNS response for an authoritative name server.
Inputs
- "Child Zone" - The domain name to be tested.
- "Prefix Database" - The database of IP Prefix data to be used. Possible values are "RIPE" and "Cymru" (the default value).
- "Cymru Base Name" - If the Prefix Database is "Cymru", the default value is "asnlookup.zonemaster.net".
- "RIS Whois Server" - If the Prefix Database is "RIPE", the default value is "riswhois.ripe.net".
Summary
Message Tag | Level | Arguments | Message ID for message tag |
---|---|---|---|
CN04_EMPTY_PREFIX_SET | NOTICE | ns_ip | Prefix database returned no information for IP address {ns_ip}. |
CN04_ERROR_PREFIX_DATABASE | NOTICE | ns_ip | Prefix database error for IP address {ns_ip}. |
CN04_IPV4_DIFFERENT_PREFIX | INFO | ns_list | The following name server(s) are announced in unique IPv4 prefix(es): "{ns_list}" |
CN04_IPV4_SAME_PREFIX | NOTICE | ns_list, ip_prefix | The following name server(s) are announced in the same IPv4 prefix ({ip_prefix}): "{ns_list}" |
CN04_IPV4_SINGLE_PREFIX | WARNING | All name server(s) IPv4 address(es) are announced in the same IPv4 prefix. | |
CN04_IPV6_DIFFERENT_PREFIX | INFO | ns_list | The following name server(s) are announced in unique IPv6 prefix(es): "{ns_list}" |
CN04_IPV6_SAME_PREFIX | NOTICE | ns_list, ip_prefix | The following name server(s) are announced in the same IPv6 prefix ({ip_prefix}): "{ns_list}" |
CN04_IPV6_SINGLE_PREFIX | WARNING | All name server(s) IPv6 address(es) are announced in the same IPv6 prefix. |
The value in the Level column is the default severity level of the message. The severity level can be changed in the Zonemaster-Engine Profile. Also see the Severity Level Definitions document.
The argument names in the Arguments column lists the arguments used in the message. The argument names are defined in the Argument List.
Test procedure
-
Create the following empty sets:
- IP prefix, name server name and IP address ("IPv4 Prefix")
- IP prefix, name server name and IP address ("IPv6 Prefix")
-
Obtain the set of name server names and IP addresses using Get-Del-NS-Names-and-IPs and Get-Zone-NS-Names-and-IPs in MethodsV2 and split those into IPv4 and IPv6 ("NS IPv4" and "NS IPv6", respectively).
-
For each IP address in NS IPv4 and NS IPv6 ("NS IP Address"), respectively, do:
- Determine the IP prefix in which NS IP Address is announced using Prefix Database. Go to Prefix Lookup Methods section below with the IP address as input.
- Add found IP prefix, if any, with NS IP Address and name server name to the IPv4 Prefix and IPv6 Prefix sets, respectively.
-
If the IPv4 Prefix set is non-empty, then do:
- For each IP prefix in the set that has two or more members, output CN04_IPV4_SAME_PREFIX with the prefix and list of all members (name server names and IP addresses) for that prefix.
- For all IP prefixes in the set that have exactly one member, output CN04_IPV4_DIFFERENT_PREFIX with the combined set of their associated members (name server names and IP addresses).
- If all members of NS IPv4 are members of the same IP prefix in IPv4 Prefix then output CN04_IPV4_SINGLE_PREFIX.
-
If the IPv6 Prefix set is non-empty, then do:
- For each IP prefix in the set that has two or more members, output CN04_IPV6_SAME_PREFIX with the prefix and list of all members (name server names and IP addresses) for that prefix.
- For all IP prefixes in the set that have exactly one member, output CN04_IPV6_DIFFERENT_PREFIX with the combined set of their associated members (name server names and IP addresses).
- If all members of NS IPv6 are members of the same IP prefix in IPv6 Prefix then output CN04_IPV6_SINGLE_PREFIX.
Outcome(s)
The outcome of this Test Case is "fail" if there is at least one message with the severity level ERROR or CRITICAL.
The outcome of this Test Case is "warning" if there is at least one message with the severity level WARNING, but no message with severity level ERROR or CRITICAL.
In other cases, no message or only messages with severity level INFO or NOTICE, the outcome of this Test Case is "pass".
Special procedural requirements
This Test Case is dependent on one of two possible services that can provide ASN lookup (Cymru or RIPE RIS). The service must be available over the network.
The Child Zone must be a valid name meeting "Requirements and normalization of domain names in input".
Prefix lookup methods
Use the prefix method set in Prefix Database and the IP address in the call to this section. Refer to the appropriate section below with the IP address as input.
Cymru prefix lookup
The Cymru prefix lookup is described on the Team Cymru IP to ASN Mapping
using DNS lookup, but the default data comes from bgp.tools (Port 179 Ltd
in England and Wales) and is continuously being mapped into
asnlookup.zonemaster.net
by the Zonemaster project. Data is fetched from
https://bgp.tools/table.txt. The Cymru source can also be used, if
requested.
-
Input is the IP address in the call to this section ("Input IP").
-
Prepend the Cymru Base Name with the label "origin" (IPv4) or "origin6" (IPv6) ("Expanded Base Name"). Example of expanded basenames :
origin.asnlookup.zonemaster.net
origin6.asnlookup.zonemaster.net
-
Reverse Input IP with the same method as is used for reverse lookup ("Reverse IP"). For description see RFC 1035, section 3.5, for IPv4 and RFC 3596, section 2.5, for IPv6.
-
Prepend the Expanded Base Name with Reverse IP ("Query Name"). See IP to ASN Mapping for details.
-
Create a DNS Query with query type TXT and query name Query Name. ("TXT Query").
-
Do DNS Lookup of TXT Query.
-
If at least one of the following criteria is met, output CN04_EMPTY_PREFIX_SET and exit this lookup:
- The DNS Response has the RCODE Name NXDomain.
- The DNS Response has the RCODE Name NoError and an empty answer section.
-
If at least one of the following criteria is met, output CN04_ERROR_PREFIX_DATABASE and exit this lookup:
- There is no DNS response.
- The DNS Response does not have the RCODE Name NoError.
- The answer section has no TXT record.
-
Extract the TXT record(s) from the answer section (see IP to ASN Mapping for examples). Do for each TXT record:
- If the TXT record consists of multiple strings in RDATA, then concatenate the strings into one string.
- Using the format of such string parse the string into its parts and
extract the subnet specification.
- If it was not possible to parse the string, ignore it and go to next TXT record.
- If Input IP does not match the extracted subnet, output CN04_ERROR_PREFIX_DATABASE, break the processing of TXT records and exit this loop without returning any prefix.
- Store the extracted prefix.
-
If more than one IP prefix was stored from the loop above, keep the most specific and discard the rest.
-
If no IP prefix was stored, output CN04_EMPTY_PREFIX_SET.
-
Return the IP prefix, or an empty string if no IP prefix was stored.
RIPE prefix lookup
The RIPE Prefix lookup is described on the RIPE RISwhois page.
-
Create a query string by prepending the IP address with " -F -M " ("WHOIS String"). E.g., using IP address "192.0.2.10":
" -F -M 192.0.2.10"
-
Create a WHOIS query (port 43 with the nicname ((whois)) protocol) using the WHOIS String ("WHOIS Query"). E.g., on Linux:
whois -h riswhois.ripe.net " -F -M 192.0.2.10"
-
Send WHOIS Query to the RIS Whois Server.
-
If there is no response, output CN04_ERROR_PREFIX_DATABASE and exit this lookup.
-
Extract the string (non-empty line not prepended with "%") from the response, and do:
- If there is no such string, output CN04_EMPTY_PREFIX_SET and exit this lookup.
- Extract the IP prefix from the second field of the string.
- If it was not possible to extract the IP prefix (i.e., malformed response), output CN04_ERROR_PREFIX_DATABASE and exit this lookup.
-
Return the IP prefix.
Intercase dependencies
None
Terminology
-
"Concatenate" - The term is used to refer to the conversion of a TXT resource record’s data to a single contiguous string, as specified in RFC 7208, section 3.3.
-
"DNS Lookup" - The term is used when a recursive lookup is used, though any changes to the DNS tree introduced by an undelegated test must be respected. Compare with "Send".
-
"Send" - The term "send" (to an IP address) is used when a DNS query is sent to a specific name server IP address. Compare with "DNS Lookup".
Consistency Test Plan
This document uses the terminology defined in the Master Test Plan.
Test cases list
Test Case | Test Case Description |
---|---|
CONSISTENCY01 | SOA serial number consistency |
CONSISTENCY02 | SOA RNAME consistency |
CONSISTENCY03 | SOA timers consistency |
CONSISTENCY04 | Name server NS consistency |
CONSISTENCY05 | Consistency between glue and authoritative data |
CONSISTENCY06 | SOA MNAME consistency |
CONSISTENCY01: SOA serial number consistency
Test case identifier
CONSISTENCY01
Objective
For the data served by the authoritative name servers for a designated zone to be consistent, all authoritative name servers must serve the same SOA record for the designated zone.
If the serial number (explained in 3.3.13. of RFC 1035), which is part of the SOA record, is not consistent between authoritative servers, there is a possibility that the data served is inconsistent. The reasons for this inconsistency may be different - such as misconfiguration, or as a result of slow propagation to the secondary name servers.
The objective of this test is to verify that the serial number is consistent between different authoritative name servers.
For reference purposes : RFC 1982 explains the serial number arithmetic, and section 4.3.5 of RFC 1034 explains the importance of serial number consistency.
Scope
It is assumed that Child Zone is also tested by Connectivity01. This test case will set DEBUG level on messages for non-responsive name servers.
Inputs
- "Child Zone" - The domain name to be tested
- "Accepted Serial Difference" - Accepted difference between SOA serial values from SOA records of different name servers for Child Zone. Default value is 0, i.e. no difference.
Ordered description of steps to be taken to execute the test case
-
Obtain the list of name server IPs for the Child Zone from Method4 and Method5 ("Name Server IP").
-
Create an SOA query for Child Zone name (the top of the zone).
-
Create an empty set of pair of retrieved SOA serials and name server name and IP ("SOA Serial Set").
-
For each name server in Name Server IP do:
-
Send the SOA query to the name server.
-
If the name server does not respond with a DNS response, then output NO_RESPONSE.
-
Or, if the name server returns a DNS response, but no SOA record is included, then output NO_RESPONSE_SOA_QUERY.
-
Or, retrieve the SOA SERIAL from the response and add it to SOA Serial Set (unless it is already there) and update the set with the name server name and IP.
-
-
If SOA Serial Set has exactly one SOA serial value, then output ONE_SOA_SERIAL.
-
Or, if SOA Serial Set has at least two SOA serials values, then do:
- Order the serial number values from SOA Serial Set from smallest to largest following the arithmetic for serial number, if possible.
- If there is not a single, uniquely defined order of the serial numbers, then output SOA_SERIAL_VARIATION and MULTIPLE_SOA_SERIALS.
- Or, if the difference between the first and the last serial number is larger than Accepted Serial Difference, using arithmetic for serial number, then output SOA_SERIAL_VARIATION and MULTIPLE_SOA_SERIALS.
- Or, if the difference between the first and the last serial number is not larger than Accepted Serial Difference, using arithmetic for serial number, output MULTIPLE_SOA_SERIALS_OK.
-
For each SOA serial value in SOA Serial Set, output SOA_SERIAL with the serial number and a semicolon separated list of name server names and IP address pairs (name/IP).
Outcome(s)
The outcome of this Test Case is "fail" if there is at least one message with the severity level ERROR or CRITICAL.
The outcome of this Test Case is "warning" if there is at least one message with the severity level WARNING, but no message with severity level ERROR or CRITICAL.
In other cases the outcome of this Test Case is "pass".
Message | Default severity level (if message is emitted) |
---|---|
NO_RESPONSE | DEBUG |
NO_RESPONSE_SOA_QUERY | DEBUG |
ONE_SOA_SERIAL | INFO |
MULTIPLE_SOA_SERIALS | WARNING |
MULTIPLE_SOA_SERIALS_OK | NOTICE |
SOA_SERIAL | INFO |
SOA_SERIAL_VARIATION | NOTICE |
Special procedural requirements
If either IPv4 or IPv6 transport is disabled, ignore the evaluation of the result of any test using this transport protocol. Log a message reporting on the ignored result.
A manual inspection of the SOA serial may be needed to determine if the zone updates work properly or not, and if the serial values are within a reasonable range, then the test is OK.
When comparing SOA serial it must be done using the arithmetic defined in RFC 1982.
Intercase dependencies
None
CONSISTENCY02: SOA RNAME consistency
Test case identifier
CONSISTENCY02
Objective
All authoritative name servers must serve the same SOA record for the tested domain (section 4.2.1 of RFC 1034). As per section 3.3.13 of RFC 1035, the RNAME field in the SOA RDATA refers to the administrative contact. An inconsistency in the administrative contact for the domain might result in operational failures being reported to different persons.
The objective of this test is to verify that the administrative contact is consistent between different authoritative name servers.
Scope
It is assumed that Child Zone is also tested by Connectivity01. This test case will set DEBUG level on messages for non-responsive name servers.
Inputs
- The domain name to be tested ("Child Zone")
Ordered description of steps to be taken to execute the test case
- Obtain the list of name server IPs for the Child Zone from Method4 and Method5.
- Create an SOA query for Child Zone apex and send it to all name server IPs.
- Retrieve the SOA RR from the responses from all name server IPs.
- If a name server does not respond, emit NO_RESPONSE.
- If a name server responds but does not include a SOA record in the response, emit NO_RESPONSE_SOA_QUERY.
- If at least one SOA record has been retrieved and RNAME is identical in all SOA records, emit ONE_SOA_RNAME.
- If RNAME is not identical in all SOA records, emit MULTIPLE_SOA_RNAMES.
Outcome(s)
The outcome of this Test Case is "fail" if there is at least one message with the severity level ERROR or CRITICAL.
The outcome of this Test Case is "warning" if there is at least one message with the severity level WARNING, but no message with severity level ERROR or CRITICAL.
In other cases the outcome of this Test Case is "pass".
Message | Default severity level (if message is emitted) |
---|---|
NO_RESPONSE | DEBUG |
NO_RESPONSE_SOA_QUERY | DEBUG |
ONE_SOA_RNAME | INFO |
MULTIPLE_SOA_RNAMES | NOTICE |
Special procedural requirements
If either IPv4 or IPv6 transport is disabled, ignore the evaluation of the result of any test using this transport protocol. Log a message reporting on the ignored result.
Intercase dependencies
None
CONSISTENCY03: SOA timers consistency
Test case identifier
CONSISTENCY03
Objective
All SOA record timer fields must be consistent across all authoritative name servers. An inconsistency in these fields might result in operational inconsistencies for the designated zone.
There are other test cases that provide consistency tests for the other SOA fields:
- CONSISTENCY01 (SOA Serial)
- CONSISTENCY02 (RNAME)
- CONSISTENCY06 (MNAME)
Scope
It is assumed that Child Zone is also tested by Connectivity01. This test case will set DEBUG level on messages for non-responsive name servers.
Inputs
- The domain name to be tested ("Child Zone").
Ordered description of steps to be taken to execute the test case
-
Create an SOA query for Child Zone apex.
-
Obtain the list of name server IPs for the Child Zone from Method4 and Method5.
-
Send the SOA query to all name server IPs.
-
If a name server does not respond, emit NO_RESPONSE.
-
If a name server responds but no SOA record is included in the response, emit NO_RESPONSE_SOA_QUERY.
-
Retrieve the SOA RR from the responses from all name server IPs.
-
Emit ONE_SOA_TIME_PARAMETER_SET if at least one SOA record has been retrieved and all SOA records have:
- the same REFRESH value,
- the same RETRY value,
- the same EXPIRE value, and
- the same MINIMUM value.
-
Emit MULTIPLE_SOA_TIME_PARAMETER_SET if any two SOA records had different values in previous step.
Outcome(s)
The outcome of this Test Case is "fail" if there is at least one message with the severity level ERROR or CRITICAL.
The outcome of this Test Case is "warning" if there is at least one message with the severity level WARNING, but no message with severity level ERROR or CRITICAL.
In other cases the outcome of this Test Case is "pass".
Message | Default severity level (if message is emitted) |
---|---|
NO_RESPONSE | DEBUG |
NO_RESPONSE_SOA_QUERY | DEBUG |
ONE_SOA_TIME_PARAMETER_SET | INFO |
MULTIPLE_SOA_TIME_PARAMETER_SET | NOTICE |
Special procedural requirements
If either IPv4 or IPv6 transport is disabled, ignore the evaluation of the result of any test using this transport protocol. Log a message reporting on the ignored result.
Intercase dependencies
None.
CONSISTENCY04: Name server NS consistency
Test case identifier
CONSISTENCY04
Objective
All authoritative name servers must serve the same NS record set for the tested domain, child zone (RFC 1034, section 4.2.2). Any inconsistencies in NS records described in RFC 1035, section 3.3.11, might result in operational failures.
The objective of this test is to verify that the NS records are consistent between all authoritative name servers of the child zone.
Two NS RR sets are considered to be equal if both sets have the same number of NS records, and for each NS record in one of the sets there is exactly one NS record with identical owner name, class, TTL and RDATA in the other NS set.
Scope
It is assumed that Child Zone is also tested by Connectivity01. This test case will set DEBUG level on messages for non-responsive name servers.
Inputs
- The domain name to be tested ("Child Zone").
Ordered description of steps to be taken to execute the test case
-
Obtain the set of name server IPs for the Child Zone using Method4 and Method5.
-
Create an NS query for the apex of the Child Zone.
-
Send the NS query to each of the retrieved name server IPs.
-
If a name server IP does not respond, emit NO_RESPONSE.
-
If the response from a name server IP does not include an NS RR set for the Child Zone with the AA flag set, emit NO_RESPONSE_NS_QUERY.
-
If all retrieved NS RR sets are equal, emit ONE_NS_SET. Otherwise, emit MULTIPLE_NS_SET.
Outcome(s)
The outcome of this Test Case is "fail" if there is at least one message with the severity level ERROR or CRITICAL.
The outcome of this Test Case is "warning" if there is at least one message with the severity level WARNING, but no message with severity level ERROR or CRITICAL.
In other cases the outcome of this Test Case is "pass".
Message | Default severity level (if message is emitted) |
---|---|
NO_RESPONSE | DEBUG |
NO_RESPONSE_NS_QUERY | DEBUG |
ONE_NS_SET | INFO |
MULTIPLE_NS_SET | NOTICE |
Special procedural requirements
If either IPv4 or IPv6 transport is disabled, ignore the evaluation of the result of any test using this transport protocol. Log a message reporting on the ignored result.
Intercase dependencies
None
CONSISTENCY05: Consistency between glue and authoritative data
Test case identifier
CONSISTENCY05
Objective
For name servers that have IP addresses listed as glue, the IP addresses must match the authoritative A and AAAA records for that host. This is an IANA name server requirement.
The objective of this test is to verify that the glue records in the delegation are consistent with authoritative data.
Scope
It is assumed that Child Zone is also tested by Connectivity01. This test case will set DEBUG level on messages for non-responsive name servers.
Inputs
- "Child Zone" - The domain name to be tested.
Ordered description of steps to be taken to execute the test case
-
Obtain the set of name server names from the NS records in the delegation of Child Zone using Method2 and any glue IP addresses from the same delegation using Method4.
-
Extract the in-bailiwick name server names and create the set "Delegation Strict Glue", where each name server name is matched with its IP address or addresses, if available. (The set may be empty.)
-
Extract the out-of-bailiwick name server names and create the set "Delegation Extended Glue", where each name server name is matched with its IP address or addresses, if available. (The set may be empty.)
-
-
Obtain the set of name server names for the Child Zone using Method2 and Method3 and extract the in-bailiwick name server names, "IB NS Name Set". (The set may be empty.)
-
Create an empty set of name server name with associated IP address or addresses, "Address Records From Child".
-
If IB NS Name Set is non-empty, obtain the set of name server IP addresses, "NS IP", for Child Zone using Method4 and Method5.
-
If IB NS Name Set is non-empty, then for each name server name in that set do:
-
Create one A query and one AAAA query with the RD flag unset and name server name as owner name.
-
For each name server in NS IP and for each record types (A, AAAA):
- Send the address query to the name server.
- If there is no DNS response from the server, then output NO_RESPONSE.
- Or, if the response is a delegation (referral) to a
sub-zone of Child Zone, then:
- Copy the address query (A, AAAA) that gave the referral response.
- Set the RD flag in the copied query (from unset to set).
- Do a DNS Lookup of the query.
- If the lookup returns the relevant address record or records, A for A record query and AAAA for AAAA record query, and with the same owner name as in the query (i.e. CNAME should not be followed), then extract those and add to Address Records From Child with name and IP address or addresses.
- Or, if the response has the AA flag unset, then output CHILD_NS_FAILED.
- Or, if the RCODE of the response is neither NOERROR nor NXDOMAIN, then output CHILD_NS_FAILED.
- Or, if the RCODE is NOERROR (with the AA flag set), then extract any address records (A, AAAA) from the answer section whose owner name matches the owner name of the query (i.e. CNAME should not be followed) and add that or those to Address Records From Child with name and IP.
- Else, there is nothing to do (i.e. RCODE is NXDOMAIN).
-
If all servers outputted NO_RESPONSE or CHILD_NS_FAILED, then output CHILD_ZONE_LAME and completely stop processing this test case.
-
-
Compare the IP address for the name servers from Delegation Strict Glue with Address Records From Child (i.e. in-bailiwick only).
-
If an IP from Delegation Strict Glue is not listed in Address Records From Child with that same name server name, then output IN_BAILIWICK_ADDR_MISMATCH.
-
If an IP from Address Records From Child is not listed in Delegation Strict Glue with that same name server name, then output EXTRA_ADDRESS_CHILD.
-
-
For each name server name in Delegation Extended Glue (i.e. out-of-bailiwick only) ("DEG Name Server Name") do:
-
Do two DNS Lookups, one record type A and one record type AAAA, for DEG Name Server Name on public DNS and create a set of the IP addresses from the A and AAAA records, respectively, from the answer sections of the responses and that matches the owner name of the query (i.e. CNAME should not be followed). (The set will be empty if there are no relevant records in the answer sections or if there is no response, e.g. SERVFAIL.)
-
For each IP address for DEG Name Server Name in Delegation Extended Glue do:
- If the address is not member of the IP address set created in the previous DNS lookups, output OUT_OF_BAILIWICK_ADDR_MISMATCH.
-
-
If none of IN_BAILIWICK_ADDR_MISMATCH, EXTRA_ADDRESS_CHILD or OUT_OF_BAILIWICK_ADDR_MISMATCH has been outputted, output ADDRESSES_MATCH.
Outcome(s)
The outcome of this Test Case is "fail" if there is at least one message with the severity level ERROR or CRITICAL.
The outcome of this Test Case is "warning" if there is at least one message with the severity level WARNING, but no message with severity level ERROR or CRITICAL.
The outcome of this Test case is "pass" in all other cases.
Message | Default severity level (when message is outputted) |
---|---|
CHILD_NS_FAILED | DEBUG |
NO_RESPONSE | DEBUG |
CHILD_ZONE_LAME | ERROR |
IN_BAILIWICK_ADDR_MISMATCH | ERROR |
OUT_OF_BAILIWICK_ADDR_MISMATCH | ERROR |
EXTRA_ADDRESS_CHILD | NOTICE |
ADDRESSES_MATCH | INFO |
Special procedural requirements
If either IPv4 or IPv6 transport is disabled, ignore the evaluation of the result of any test using this transport protocol and log a message reporting the ignored result.
If the test is an undelegated test then Method2 and Method4 will include the provided input data instead of data from any real delegation and authoritative data.
For an undelegated test it is possible to intentionally insert data for out-of-bailiwick name servers that do not match what is found in public DNS. This Test Case will then report this as an ERROR which may not match the users expectation.
It is assumed that the name servers of the parent zone behave the same way for the parent zone as when BASIC01 was run.
Intercase dependencies
None
Terminology
The terms "in-bailiwick" and "out-of-bailiwick" are used as defined in RFC 7719, section 6, page 15.
The term "glue records" is defined in RFC 7719, section 6, page 15. Here we use "glue" in the wider sense.
When the term "using Method" is used, names and IP addresses are fetched using the defined Methods.
The term "send" (to an IP address) is used when a DNS query is sent to a specific name server.
The term "DNS Lookup" is used when a recursive lookup is used, though any changes to the DNS tree introduced by an undelegated test must be respected.
CONSISTENCY06: SOA MNAME consistency
Test case identifier
CONSISTENCY06
Objective
All authoritative name servers must serve the same SOA record (section 4.2.1) of RFC 1034 for the tested domain. As per section 3.3.13 of RFC 1035 the MNAME field in the SOA RDATA refers to the name of "the name server that was the original or primary source of data for this zone". Inconsistency in MNAME of the domain might result in operational failures for applications that uses MNAME.
Scope
It is assumed that Child Zone is also tested by Connectivity01. This test case will set DEBUG level on messages for non-responsive name servers.
Inputs
- "Child Zone" - The domain name to be tested.
Ordered description of steps to be taken to execute the test case
-
Obtain the set of name server IPs for the Child Zone from Method4 and Method5 ("Name Server IP").
-
Create an SOA query for Child Zone apex.
-
For each name server in Name Server IP do:
- Send the query to name server.
- If the name server does not respond with a DNS response, emit NO_RESPONSE for that name server and go to next server.
- If the DNS response does not include a SOA record in the answer section then emit NO_RESPONSE_SOA_QUERY for that server and go to next server.
- Retrieve the MNAME field from the SOA RR from the DNS response and save that to compare it with the MNAME from the other name servers.
-
Compare the MNAME fields retrieved from all name servers.
-
If at least one name server has responded with a SOA record and the MNAME is identical in all SOA records retrieved, emit ONE_SOA_MNAME.
-
If MNAME is not identical in all SOA records retrieved, emit MULTIPLE_SOA_MNAMES.
Outcome(s)
The outcome of this Test Case is "fail" if there is at least one message with the severity level ERROR or CRITICAL.
The outcome of this Test Case is "warning" if there is at least one message with the severity level WARNING, but no message with severity level ERROR or CRITICAL.
In other cases the outcome of this Test Case is "pass".
Message | Default severity level (if message is emitted) |
---|---|
NO_RESPONSE | DEBUG |
NO_RESPONSE_SOA_QUERY | DEBUG |
ONE_SOA_MNAME | INFO |
MULTIPLE_SOA_MNAMES | NOTICE |
Special procedural requirements
If either IPv4 or IPv6 transport is disabled, ignore the evaluation of the result of any test using this transport protocol. Log a message reporting on the ignored result.
Intercase dependencies
None
DNSSEC Test Plan
These are the DNSSEC tests for a domain.
This document uses the terminology defined in the Master Test Plan.
Default DNS query flags for all DNSSEC tests
- Transport: UDP
- Bufsize: EDNS0 buffer size (512)
- Flags -- query flags
- do -- DNSSEC ok (1)
- cd -- Checking Disabled (1)
- rd -- Recursion Desired (0)
- ad -- Authenticated Data (0)
See section 3.2 of RFC 4035 for a description of the flags used by a recursive name server.
Key, hash and signature algorithms
There are many algorithms defined for doing DNSSEC, not all of them are mandatory to implement. This test case should strive not only to implement all mandatory algorithms, but also most of those that are in use on the internet today as well.
If any algorithm in a DNSSEC record type is not recognized by the test system, the test system should emit a notice about this.
Test cases list
Test Case | Test Case Description |
---|---|
DNSSEC01 | Legal values for the DS hash digest algorithm |
DNSSEC02 | DS must match a valid DNSKEY in the child zone |
DNSSEC03 | Verify NSEC3 parameters |
DNSSEC04 | Check for too short or too long RRSIG lifetimes |
DNSSEC05 | Check for invalid DNSKEY algorithms |
DNSSEC06 | Verify DNSSEC additional processing |
DNSSEC07 | If DNSKEY at child, parent should have DS |
DNSSEC08 | Valid RRSIG for DNSKEY |
DNSSEC09 | RRSIG(SOA) must be valid and created by a valid DNSKEY |
DNSSEC10 | Zone contains NSEC or NSEC3 records |
DNSSEC11 | DS in delegation requires signed zone |
DNSSEC12 | Test for DNSSEC Algorithm Completeness |
DNSSEC13 | All DNSKEY algorithms used to sign the zone |
DNSSEC14 | Check for valid RSA DNSKEY key size |
DNSSEC15 | Existence of CDS and CDNSKEY |
DNSSEC16 | Validate CDS |
DNSSEC17 | Validate CDNSKEY |
DNSSEC18 | Validate trust from DS to CDS and CDNSKEY |
DNSSEC01: Legal values for the DS hash digest algorithm
Test case identifier
DNSSEC01
Table of contents
- Objective
- Scope
- Inputs
- Summary
- Test procedure
- Outcome(s)
- Special procedural requirements
- Intercase dependencies
- Terminology
Objective
The list of allowed Digest Algorithms in a DS record published by the parent is specified by RFC 8624, section 3.3, and is published in the IANA registry of DS RR Type Digest Algorithms. No DS Digest Algorithm values, other than those specified in the RFC and allocated by IANA, should be used in public DNS.
If RFC 8624 and the IANA registry disagree on the same DS digest algorithm, the RFC takes precedence until the registry has a been updated with a reference to the RFC.
The table of algorithms below is for reference only and is copied from IANA registry. It is here to make it easier to read the steps when symbolic names are given. This is only an excerpt from the table. The full table is available at the IANA registry.
Algorithm number | Algorithm (or description) |
---|---|
0 | (Reserved) |
1 | SHA-1 |
2 | SHA-256 |
3 | GOST R 34.11-94 |
4 | SHA-384 |
5-255 | (Unassigned) |
This test case will verify that the Zonemaster implementation has support for the DS digest algorithm of the DS record found, and if not output a message tag. If the support is missing other test cases will not be able to verify that DS record.
Scope
This test case will query the name servers of the parent zone, and will just ignore non-responsive name servers or name servers not giving a correct DNS response for an authoritative name server.
If no DS record is found in the parent zone then this test case will be terminated without outputting any message tag.
This test case does not report if the parent servers give inconsistent responses.
If the Child Zone is the root zone, then it has no parent zone, and no DS records can be fetch.
Inputs
- "Child Zone" - The domain name to be tested.
- "Algorithm Status" - The status of all DS digest algorithms from RFC 8624 and the IANA registry.
- "Test Type" - The test type with value "undelegated" or "normal".
- "Undelegated DS" - The DS record or records submitted, undefined unless Test Type is undelegated and empty if no DS record has been submitted.
Summary
- At least one DS record must be found, or no further investigation will be done and no messages will be outputted.
- No messages will be outputted due to errors in the responses from the parent name servers.
Message Tag outputted | Level | Arguments | Description of when message tag is outputted |
---|---|---|---|
DS01_DIGEST_NOT_SUPPORTED_BY_ZM | NOTICE | ns_ip_list, algo_mnemo, algo_num, keytag | DS Digest cannot be validated by this installation of Zonemaster. |
DS01_DS_ALGO_DEPRECATED | ERROR | ns_ip_list, algo_mnemo, algo_num, keytag | The DS digest algorithm is deprecated. |
DS01_DS_ALGO_2_MISSING | NOTICE | DS created with algo 2 (SHA-256) is missing. | |
DS01_DS_ALGO_NOT_DS | ERROR | ns_ip_list, algo_mnemo, algo_num, keytag | The DS digest algorithm is not for DS. |
DS01_DS_ALGO_RESERVED | ERROR | ns_ip_list, algo_mnemo, algo_num, keytag | No DS digest algorithm defined for the digest code. |
The value in the Level column is the default severity level of the message. The severity level can be overridden in the Zonemaster-Engine profile. Also see the Severity Level Definitions document.
The argument names in the Arguments column lists the arguments used in the message. The argument names are defined in the argument list.
Test procedure
In this section and unless otherwise specified below, the term "DNSSEC Query" follows the specification for DNS queries as specified in DNS Query and Response Defaults. The handling of the DNS responses on the DNS queries follow, unless otherwise specified below, what is specified for DNSSEC Response in the same specification.
-
If the Test Type is "undelegated" do:
-
If Undelegated DS is empty then do terminate the test procedure.
-
Else, for each DS record in Undelegated DS do:
-
Extract the digest algorithm code and key tag from the DS record ("Digest Code" and "Key Tag", respectively).
-
If Digest Code is 0 then output DS01_DS_ALGO_NOT_DS with Digest Code and Key Tag. Set IP address as "-".
-
If Digest Code is 1 or 3 then output DS01_DS_ALGO_DEPRECATED with Digest Code and Key Tag. Set IP address as "-".
-
If Digest Code is 5-255 then output DS01_DS_ALGO_RESERVED with Digest Code and Key tag. Set IP address as "-".
-
Verify if the Zonemaster implementation can create a digest of any valid DNSKEY record using Digest Code. If the verification fails output DS01_DIGEST_NOT_SUPPORTED_BY_ZM with Digest Code and Key tag. Set IP address as "-".
-
-
If none of the DS records has digest algorithm value 2 output DS01_DS_ALGO_2_MISSING.
-
Terminate the test procedure.
-
-
From here the test procedure is for normal test, not undelegated.
-
If Child Zone is the root zone (".") then terminate the test procedure.
-
Create the following empty set:
- Name server IP, key tag from DS record and digest algorithm code ("DS Records").
-
Create a DNSSEC Query with query type DS and query name Child Zone ("DS Query").
-
Retrieve all name server IP addresses for the parent zone of Child Zone using Method1 (store as "Parent NS IP").
-
For each parent name server in Parent NS IP do:
- Send DS Query to the name server IP.
- If at least one of the following criteria is met, then go to next
parent name server:
- There is no DNSSEC Response.
- The RCODE in the DNSSEC Response is not "NoError" (IANA RCODE List).
- The OPT record is absent in the DNSSEC Response.
- The DO flag is unset in the DNSSEC Response.
- The AA flag is not set in the DNSSEC Response.
- There is no DS record with matching owner name in the answer section of the DNSSEC Response.
- Retrieve the DS records from the DNSSEC Response and add name sever IP, key tag from the DS record and the digest algorithm code from the DS record to the DS Records set.
-
If the DS Records set is empty terminate the test procedure.
-
For each subset in DS Records where both DS digest code ("Digest Code") and key tag ("Key Tag") are identical for all subset elements do:
- If Digest Code is 0 then output DS01_DS_ALGO_NOT_DS with Digest Code, Key Tag and list of name server IP addresses.
- If Digest Code is 1 or 3 then output DS01_DS_ALGO_DEPRECATED with Digest Code, Key Tag and list of name server IP addresses.
- If Digest Code is 5-255 then output DS01_DS_ALGO_RESERVED with Digest Code, Key Tag and list of name server IP addresses.
- Verify that the Zonemaster implementation can create a digest of any valid DNSKEY record using Digest Code. If the verification fails output DS01_DIGEST_NOT_SUPPORTED_BY_ZM with Digest Code, Key Tag and list of name server IP addresses.
-
If none of the elements in DS Records has digest algorithm value 2 output DS01_DS_ALGO_2_MISSING.
Outcome(s)
The outcome of this Test Case is "fail" if there is at least one message with the severity level ERROR or CRITICAL.
The outcome of this Test Case is "warning" if there is at least one message with the severity level WARNING, but no message with severity level ERROR or CRITICAL.
In other cases, no message or only messages with severity level INFO or NOTICE, the outcome of this Test Case is "pass".
Special procedural requirements
If either IPv4 or IPv6 transport is disabled, ignore the evaluation of the result of any test using this transport protocol. Log a message reporting on the ignored result.
See the DNSSEC README document about DNSSEC algorithms.
Intercase dependencies
None.
Terminology
No special terminology for this test case.
DNSSEC02: DS must match a valid DNSKEY in the child zone
Test case identifier
DNSSEC02
Table of contents
- Objective
- Scope
- Inputs
- Summary
- Test procedure
- Outcome(s)
- Special procedural requirements
- Intercase dependencies
- Terminology
Objective
DNS delegations from a parent to a child are secured with DNSSEC by publishing one or several Delegation Signer (DS) records in the parent zone, along with the NS records for the delegation.
For the secure delegation to work, at least one DS record must match a DNSKEY record in the child zone (RFC 4035, section 5). Each DS record should match a DNSKEY record in the child zone. More than one DS may match the same DNSKEY. The DNSKEY that the DS record refer to must be used to sign the DNSKEY RRset in the child zone (RFC 4035, section 5).
The DNSKEY record that the DS record refer to must have bit 7 ("Zone Key flag") set in the DNSKEY RR Flags (RFC 4034, section 5.2).
Bit 15 ("Secure Entry Point flag") on a DNSKEY record signals that it is meant to be a KSK and pointed out by a DS record. It is noted if the DNSKEY record that the DS points at does not have that flag set (RFC 4034, section 2.1.1).
Scope
This test case will just ignore non-responsive name servers or name servers not giving a correct DNS response for an authoritative name server (handled by Connectivity01).
If no DS record is found in the parent zone or no DNSKEY record is found in the Child Zone then this test case will be terminated (also see DNSSEC11).
This test case does not report if the parent servers are unresponsive or inconsistent.
Inputs
- "Child Zone" - The domain name to be tested.
- "Test Type" - The test type with value "undelegated" or "normal".
- "Undelegated DS" - The DS record or records submitted (only if Test Type is undelegated).
Summary
- Both DS record and DNSKEY record must be found, or else no further investigation will be done and no messages will be outputted.
- No messages will be outputted due to errors in the responses from the parent name servers.
Message Tag outputted | Level | Arguments | Description of when message tag is outputted |
---|---|---|---|
DS02_ALGO_NOT_SUPPORTED_BY_ZM | NOTICE | ns_ip_list, algo_mnemo, algo_num, keytag | DNSKEY with tag {keytag} uses unsupported algorithm {algo_num} ({algo_mnemo}) by this installation of Zonemaster. Fetched from the nameservers with IP addresses "{ns_ip_list}". |
DS02_DNSKEY_NOT_FOR_ZONE_SIGNING | ERROR | ns_ip_list, keytag | Flags field of DNSKEY record with tag {keytag} does not have ZONE bit set although DS with same tag is present in parent. Fetched from the nameservers with IP addresses "{ns_ip_list}". |
DS02_DNSKEY_NOT_SEP | NOTICE | ns_ip_list, keytag | Flags field of DNSKEY record with tag {keytag} does not have SEP bit set although DS with same tag is present in parent. Fetched from the nameservers with IP addresses "{ns_ip_list}". |
DS02_DNSKEY_NOT_SIGNED_BY_ANY_DS | ERROR | ns_ip_list | The DNSKEY RRset has not been signed by any DNSKEY matched by a DS record. Fetched from the nameservers with IP addresses "{ns_ip_list}". |
DS02_NO_DNSKEY_FOR_DS | WARNING | ns_ip_list, keytag | The DNSKEY record with tag {keytag} that the DS refers to does not exist in the DNSKEY RRset. Fetched from the nameservers with IP "{ns_ip_list}". |
DS02_NO_MATCHING_DNSKEY_RRSIG | WARNING | ns_ip_list, keytag | The DNSKEY RRset is not signed by the DNSKEY with tag {keytag} that the DS record refers to. Fetched from the nameservers with IP "{ns_ip_list}". |
DS02_NO_MATCH_DS_DNSKEY | ERROR | ns_ip_list, keytag | The DS record does not match the DNSKEY with tag {keytag} by algorithm or digest. Fetched from the nameservers with IP "{ns_ip_list}". |
DS02_NO_VALID_DNSKEY_FOR_ANY_DS | ERROR | ns_ip_list | There is no valid DNSKEY matched by any of the DS records. Fetched from the nameservers with IP addresses "{ns_ip_list}". |
DS02_RRSIG_NOT_VALID_BY_DNSKEY | ERROR | ns_ip_list, keytag | The DNSKEY RRset is signed with an RRSIG with tag {keytag} which cannot be validated by the matching DNSKEY. Fetched from the nameservers with IP addresses "{ns_ip_list}". |
The value in the Level column is the default severity level of the message. The severity level can be overridden in the Zonemaster-Engine profile. Also see the Severity Level Definitions document.
The argument names in the Arguments column lists the arguments used in the message. The argument names are defined in the argument list.
Test procedure
In this section and unless otherwise specified below, the term "DNSSEC Query" follows the specification for DNS queries as specified in DNS Query and Response Defaults. The handling of the DNS responses on the DNS queries follow, unless otherwise specified below, what is specified for DNSSEC Response in the same specification.
-
Create the following empty sets:
- DS record RDATA ("DS Record").
- Name server IP and key tag from DS record ("No DNSKEY for DS").
- Name server IP and key tag from DS record ("No Match DS DNSKEY").
- Name server IP and DNSKEY record key tag ("DNSKEY Not for Zone Signing").
- Name server IP and DNSKEY record key tag ("DNSKEY not SEP").
- Name server IP and DNSKEY record key tag ("No Matching DNSKEY RRSIG").
- Name server IP address, DNSKEY record key tag and DNSKEY algorithm code ("Algo Not Supported By ZM").
- Name server IP and key tag from RRSIG record ("RRSIG Not Valid by DNSKEY").
- Name server IP ("Responding Child Name Servers").
- DNSKEY record and key tag ("DNSKEY Matching DS").
- Name server IP ("Has DNSKEY Match DS").
- Name server IP ("Has DNSKEY RRSIG Match DS").
-
If the Test Type is "undelegated" do:
- If Undelegated DS is empty then do terminate this test case.
- Else add Undelegated DS as DS records to the DS Record set.
-
If Test Type is "normal", then:
- Create a DNSSEC Query with query type DS and query name Child Zone ("DS Query").
- Retrieve all name server IP addresses for the parent zone of Child Zone using Method1 (store as "Parent NS IP").
- For each parent name server in Parent NS IP do:
- Send DS Query to the name server IP.
- If at least one of the following criteria is met, then go to next
parent name server:
- There is no DNSSEC Response.
- The RCODE in the DNSSEC Response is not "NoError" (IANA RCODE List).
- The OPT record is absent in the DNSSEC Response.
- The DO flag is unset in the DNSSEC Response.
- The AA flag is not set in the DNSSEC Response.
- There is no DS record with matching owner name in the answer section of the DNSSEC Response.
- Retrieve the DS records from the DNSSEC Response and add them to the DS Record set.
- If the DS Record set is empty exit this test case.
-
Create a DNSSEC Query with query type DNSKEY and query name Child Zone ("DNSKEY Query").
-
Obtain the set of child name server IP addresses using Method4 and Method5 (store as "Child NS IP").
-
For each child name server in Child NS IP do:
- Send DNSKEY Query to the name server IP and collect the response.
- If at least one of the following criteria is met, then go to next
child name server:
- There is no DNSSEC Response.
- The RCODE in the DNSSEC Response is not "NoError" (IANA RCODE List).
- The OPT record is absent in the DNSSEC Response.
- The DO flag is unset in the DNSSEC Response.
- The AA flag is not set in the DNSSEC Response.
- There is no DNSKEY record with matching owner name in the answer section of the DNSSEC Response.
- Add the name server IP address to the Responding Child Name Servers set.
- Retrieve the DNSKEY RRset (store as "DNSKEY RRs") from the DNSSEC Response.
- Retrieve the RRSIG records covering the DNSKEY RRset, possibly none (store as "DNSKEY RRSIG") from the DNSSEC Response.
- Empty the DNSKEY Matching DS set.
- For each DS in DS Records, do:
- Find the equivalent DNSKEY in DNSKEY RRs by key ID (key tag). If there is more than one such DNSKEY, select the correct one.
- If matching DNSKEY is not found add DS key tag and name server IP to the No DNSKEY for DS set and go to next DS.
- Verify if the Zonemaster installation has support for the digest
algorithm that created the DS:
- If no support, then ignore the following test if the DS matches the DNSKEY.
- Else, if the DS values (algorithm and digest) do not match the DNSKEY record then add DS key tag and name server IP to the No Match DS DNSKEY set.
- If bit 7 of the DNSKEY flags field is unset (value 0), then do:
- Add DS key tag and name server IP to the DNSKEY Not for Zone Signing set.
- Go to next DS.
- If bit 15 of the DNSKEY flags field is unset (value 0), then add the DNSKEY record key tag and name server IP to the DNSKEY not SEP set.
- Add the DNSKEY record and key tag to the DNSKEY Matching DS set.
- Add the name server IP to the Has DNSKEY Match DS set.
- For each DNSKEY in the DNSKEY Matching DS set, do:
- Look for an RRSIG record created by the DNSKEY in DNSKEY RRSIG.
- Use key ID (key tag) to identify the corresponding RRSIG record.
- If there is more than one such RRSIG record, select the correct one by verifying the signature against the DNSKEY.
- If a matching RRSIG is not found, add DNSKEY record key tag and name server IP to the No Matching DNSKEY RRSIG set.
- Else, if the Zonemaster installation does not have support for the DNSKEY algorithm that created the RRSIG, then add name server IP, DNSKEY algorithm and DNSKEY key tag to the Algo Not Supported By ZM set.
- Else, if the RRSIG values (algorithm and signature) do not match the DNSKEY then add the key tag from the RRSIG record and name server IP to the RRSIG Not Valid by DNSKEY set.
- Else add the name server IP address to the Has DNSKEY RRSIG Match DS set.
- Look for an RRSIG record created by the DNSKEY in DNSKEY RRSIG.
-
If the No DNSKEY for DS set is non-empty, then for each key tag from the DS record from the set output DS02_NO_DNSKEY_FOR_DS with the key tag and the name servers IP addresses from the set.
-
If the No Match DS DNSKEY set is non-empty, then for each key tag from the DS record from the set output DS02_NO_MATCH_DS_DNSKEY with the key tag and the name servers IP addresses from the set.
-
If the DNSKEY Not for Zone Signing set is non-empty, then for each DNSKEY key tag from the set output DS02_DNSKEY_NOT_FOR_ZONE_SIGNING with the key tag and the name servers IP addresses from the set.
-
If the DNSKEY not SEP set is non-empty, then for each DNSKEY key tag from the set output DS02_DNSKEY_NOT_SEP with the key tag and the name servers IP addresses from the set.
-
If the No Matching DNSKEY RRSIG set is non-empty, then for each DNSKEY key tag from the set output DS02_NO_MATCHING_DNSKEY_RRSIG with the key tag and the name servers IP addresses from the set.
-
If the Algo Not Supported By ZM set is non-empty, then output DS02_ALGO_NOT_SUPPORTED_BY_ZM for each DNSKEY key tag with the name server IP addresses, the key tag and the algorithm code from the set.
-
If the RRSIG Not Valid by DNSKEY set is non-empty, then for each key tag from the RRSIG record from the set output DS02_RRSIG_NOT_VALID_BY_DNSKEY with the key tag and the name servers IP addresses from the set.
-
Extract the name server IP addresses that are members of Responding Child Name Servers but are not members of Has DNSKEY Match DS set.
-
If the subset from previous step is non-empty, then output DS02_NO_VALID_DNSKEY_FOR_ANY_DS with the subset of name server IP addresses.
-
Else do:
- Extract the name server IP addresses that are members of Responding Child Name Servers but are not members of Has DNSKEY RRSIG Match DS set.
- If that subset is non-empty, then output DS02_DNSKEY_NOT_SIGNED_BY_ANY_DS with the subset of name server IP addresses.
Outcome(s)
The outcome of this Test Case is "fail" if there is at least one message with the severity level ERROR or CRITICAL.
The outcome of this Test Case is "warning" if there is at least one message with the severity level WARNING, but no message with severity level ERROR or CRITICAL.
In other cases, no message or only messages with severity level INFO or NOTICE, the outcome of this Test Case is "pass".
Special procedural requirements
If either IPv4 or IPv6 transport is disabled, skip sending queries over that transport protocol. Output a message reporting that the transport protocol has been disabled.
See the DNSSEC README document about DNSSEC algorithms.
Intercase dependencies
None.
Terminology
No special terminology for this test case.
DNSSEC03: Verify NSEC3 parameters
Test case identifier
DNSSEC03
Table of contents
- Objective
- Scope
- Inputs
- Summary
- Test procedure
- Outcome(s)
- Special procedural requirements
- Intercase dependencies
- Terminology
Objective
The NSEC3 record type and its parameters are defined in RFC 5155. The recommended values of the parameters have been updated by RFC 9276.
For NSEC3 there are four fields that determine how the NSEC3 record are created and interpreted (RFC 5155, section 3):
- Hash algorithm
- Flags
- Iterations
- Salt
Hash algorithm: The only legal value of the hash algorithm is value 1 (SHA-1). See (RFC 5155, section 11 and IANA NSEC3 Parameters registry).
Flags: The only defined flags in the flag field is bit 7 (the least significant bit), "opt-out". It may only be set in the NSEC record, not in the NSEC3PARAM record (RFC 5155, section 11 and IANA NSEC3 Parameters registry). "For small zones, the use of opt-out-based NSEC3 records is NOT RECOMMENDED. For very large and sparsely signed zones, where the majority of the records are insecure delegations, opt-out MAY be used" (RFC 9276, section 3.1). This means that unless the zone is a TLD or a TLD like domain found in the Public Suffix List it should not have the opt-out bit set.
Iterations: For a name server an increased number of NSEC3 iterations have a negative impact on performance. The recommendation is to have 0 iterations. "If NSEC3 must be used, then an iterations count of 0 MUST be used to alleviate computational burdens" (RFC 9276, section 3.1).
Salt: The salt parameter has been seen as a security feature but RFC 9276, section 3.1, states that zones "SHOULD NOT use a salt by indicating a zero-length salt value instead". The justification for the recommendation is found in RFC 9276, section 2.4.
Scope
This test case will just ignore non-responsive name servers or name servers not giving a correct DNS response for an authoritative name server (covered by Connectivity01).
This test case is only relevant if the zone has been DNSSEC signed.
Inputs
- "Child Zone" - The domain name to be tested.
- "Public Suffix List Data" - The list or a copy of the list found at Public Suffix List data.
Summary
- If no DNSKEY records are found, no further investigation will be done.
Message Tag outputted | Level | Arguments | Message ID for message tag |
---|---|---|---|
DS03_ERROR_RESPONSE_NSEC_QUERY | ERROR | ns_list | The following servers give erroneous response to NSEC query. Fetched from name servers "{ns_list}". |
DS03_ERR_MULT_NSEC3 | ERROR | ns_list | Multiple NSEC3 records when one is expected. Fetched from name servers "{ns_list}". |
DS03_ILLEGAL_HASH_ALGO | ERROR | ns_list, algo_num | The following servers respond with an illegal hash algorithm for NSEC3 ({algo_num}). Fetched from name servers "{ns_list}". |
DS03_ILLEGAL_ITERATION_VALUE | ERROR | ns_list, int | The following servers respond with the NSEC3 iteration value {int}. The recommended practice is to set this value to 0. Fetched from name servers "{ns_list}". |
DS03_ILLEGAL_SALT_LENGTH | WARNING | ns_list, int | The following servers respond with a non-empty salt in NSEC3 ({int} octets). The recommended practice is to use an empty salt. Fetched from name servers "{ns_list}". |
DS03_INCONSISTENT_HASH_ALGO | ERROR | Inconsistent hash algorithm in NSEC3 in responses for the child zone from different name servers. | |
DS03_INCONSISTENT_ITERATION | ERROR | Inconsistent NSEC3 iteration value in responses for the child zone from different name servers. | |
DS03_INCONSISTENT_NSEC3_FLAGS | ERROR | Inconsistent NSEC3 flag list in responses for the child zone from different name servers. | |
DS03_INCONSISTENT_SALT_LENGTH | ERROR | Inconsistent salt length in NSEC3 in responses for the child zone from different name servers. | |
DS03_LEGAL_EMPTY_SALT | INFO | ns_list | The following servers respond with a legal empty salt in NSEC3. Fetched from name servers "{ns_list}". |
DS03_LEGAL_HASH_ALGO | INFO | ns_list | The following servers respond with a legal hash algorithm in NSEC3. Fetched from name servers "{ns_list}". |
DS03_LEGAL_ITERATION_VALUE | INFO | ns_list | The following servers respond with NSEC3 iteration value set to zero (as recommended). Fetched from name servers "{ns_list}". |
DS03_NO_DNSSEC_SUPPORT | NOTICE | ns_list | The zone is not DNSSEC signed or not properly DNSSEC signed. Testing for NSEC3 has been skipped. Fetched from name servers "{ns_list}". |
DS03_NO_NSEC3 | INFO | ns_list | The zone does not use NSEC3. Testing for NSEC3 has been skipped. Fetched from name servers "{ns_list}". |
DS03_NO_RESPONSE_NSEC_QUERY | ERROR | ns_list | The following servers do not respond to NSEC query. Fetched from name servers "{ns_list}". |
DS03_NSEC3_OPT_OUT_DISABLED | INFO | ns_list | The following servers respond with NSEC3 opt-out disabled (as recommended). Fetched from name servers "{ns_list}". |
DS03_NSEC3_OPT_OUT_ENABLED_NON_TLD | NOTICE | ns_list | The following servers respond with NSEC3 opt-out enabled. The recommended practice is to disable opt-out. Fetched from name servers "{ns_list}". |
DS03_NSEC3_OPT_OUT_ENABLED_TLD | INFO | ns_list | The following servers respond with NSEC3 opt-out enabled. Fetched from name servers "{ns_list}". |
DS03_SERVER_NO_DNSSEC_SUPPORT | ERROR | ns_list | The following name servers do not support DNSSEC or have not been properly configured. Testing for NSEC3 has been skipped on those servers. Fetched from name servers "{ns_list}". |
DS03_SERVER_NO_NSEC3 | ERROR | ns_list | The following name servers do not use NSEC3, but others do. Testing for NSEC3 has been skipped on the following servers. Fetched from name servers "{ns_list}". |
DS03_UNASSIGNED_FLAG_USED | ERROR | ns_list, int | The following servers respond with an NSEC3 record where an unassigned flag is used (bit {int}). Fetched from name servers "{ns_list}". |
The value in the Level column is the default severity level of the message. The severity level can be changed in the Zonemaster-Engine profile. Also see the Severity Level Definitions document.
The argument names in the Arguments column lists the arguments used in the message. The argument names are defined in the argument list.
The name server names are assumed to be available at the time when the msgid is created, if the argument name is "ns" or "ns_list" even when in the "Test procedure" below it is only referred to the IP address of the name servers.
Test procedure
In this section and unless otherwise specified below, the term "DNSSEC Query" follows the specification for DNS queries as specified in DNS Query and Response Defaults. The handling of the DNS responses on the DNS queries follow, unless otherwise specified below, what is specified for DNSSEC Response in the same specification.
A complete list of all DNS Resource Record types can be found in the IANA RR Type List.
-
Create a DNSSEC Query with query type DNSKEY and query name Child Zone ("DNSKEY Query").
-
Create a DNSSEC Query with query type NSEC and query name Child Zone ("NSEC Query").
-
Retrieve all name server names and IP addresses for the Child Zone using Method4 and Method5 ("NS IP").
-
Create the following empty sets:
- Name server IP address ("Responds Without DNSKEY").
- Name server IP address ("Responds With DNSKEY").
- Name server IP address ("Responds Without NSEC3").
- Name server IP address ("Responds With NSEC3").
- Name server IP address ("Multiple NSEC3").
- Name server IP address and NSEC3 hash algorithm ("Hash Algorithm").
- Name server IP address and NSEC3 flags ("NSEC3 Flags").
- Name server IP address and NSEC3 iterations value ("NSEC3 Iterations").
- Name server IP address and NSEC3 salt length ("NSEC3 Salt Length").
- Name server IP address ("No Response NSEC Query")
- Name server IP address ("Error Response NSEC Query")
-
For each name server IP address in NS IP do:
- Send DNSKEY Query to the name server IP.
- If at least one of the following criteria is met, then go to next name
server IP:
- There is no DNS response.
- The RCODE Name in the response is not "NoError".
- The AA flag is not set in the response.
- If the response does not contain any DNSKEY record with owner name matching Child Zone in the answer section, add name server IP to the Responds Without DNSKEY set and go to next name server.
- Add name server IP to the Responds With DNSKEY set.
- Send NSEC Query to the name server IP.
- If there is no DNS response do:
- Add name server IP to the No Response NSEC Query set.
- Go to next name server IP.
- If the RCODE Name in the response is not "NoError" or if the AA flag is
not set in the response (or both) then do:
- Add name server IP to the Error Response NSEC Query set.
- Go to next name server IP.
- If the authority section contains no NSEC3 record then add the name server IP to the Responds Without NSEC3 set and go to next name server.
- Else do:
- If there are more than one NSEC3 record in the authority section then add name server IP to the Multiple NSEC3 set and use the first one for the following steps.
- Add name server IP to the Responds With NSEC3 set.
- Extract the NSEC3 hash algorithm and add it and the name server IP to the Hash Algorithm set.
- Extract the NSEC3 flags and add them and the name server IP to the NSEC3 flags set.
- Extract the NSEC3 hash iterations value and add it and the name server IP to the NSEC3 Iterations set.
- Extract the NSEC3 salt length and add it and the name server IP to the NSEC3 Salt Length set.
-
If the Responds With DNSKEY set is empty and the Responds Without DNSKEY is non-empty then output DS03_NO_DNSSEC_SUPPORT with the name server IP addresses from the Responds Without DNSKEY set.
-
If both the Responds With DNSKEY set and the Responds Without DNSKEY set are non-empty then output DS03_SERVER_NO_DNSSEC_SUPPORT with the name server IP addresses from the Responds Without DNSKEY set.
-
If the Responds With NSEC3 set is empty and the Responds Without NSEC3 is non-empty then output DS03_NO_NSEC3 with the name server IP addresses from the Responds Without NSEC3 set.
-
If both the Responds With NSEC3 set and the Responds Without NSEC3 are non-empty then output DS03_SERVER_NO_NSEC3 with the name server IP addresses from the Responds Without NSEC3 set.
-
If the Multiple NSEC3 set is non-empty then output DS03_ERR_MULT_NSEC3 with the name server IP addresses from the set.
-
If the Hash Algorithm set is non-empty then do:
- If the set has more than one hash algorithm value then output DS03_INCONSISTENT_HASH_ALGO.
- For each algorithm value do:
- If the value is 1 output DS03_LEGAL_HASH_ALGO with the name servers IP addresses from the set with that value.
- Else, output DS03_ILLEGAL_HASH_ALGO with the hash algorithm value and the name servers IP addresses from the set with that value.
-
If the NSEC3 Flags set is non-empty then do:
- If the set has more than one flag list value then output DS03_INCONSISTENT_NSEC3_FLAGS.
- For each flag list value do:
- If any flag 0-6 (bits 0-6) is set then for each such flag output DS03_UNASSIGNED_FLAG_USED with the flag (bit) number and the name server IP addresses from the flag list value where the bit is set.
- If flag 7 (bit 7) is set, then do:
- If Child Zone is the root zone, a TLD zone or a zone matching Public Suffix List Data then output DS03_NSEC3_OPT_OUT_ENABLED_TLD with the name servers IP addresses from the set with that flag list value.
- Else, output DS03_NSEC3_OPT_OUT_ENABLED_NON_TLD with the name servers IP addresses from the set with that flag list value.
- If flag 7 (bit 7) is unset, then output DS03_NSEC3_OPT_OUT_DISABLED with the name servers IP addresses from the set with that flag list value.
-
If the NSEC3 Iterations set is non-empty then do:
- If the set has more than one iteration value then output DS03_INCONSISTENT_ITERATION.
- For each iteration value do:
- If the value is 0 output DS03_LEGAL_ITERATION_VALUE with the name servers IP addresses from the set with that iteration value.
- Else, output DS03_ILLEGAL_ITERATION_VALUE with the value and the name servers IP addresses from the set with that iteration value.
-
If the NSEC3 Salt Length set is non-empty then do:
- If the set has more than one salt length then output DS03_INCONSISTENT_SALT_LENGTH.
- For each iteration value do:
- If the length is 0 output DS03_LEGAL_EMPTY_SALT with the name servers IP addresses from the set with that salt length.
- Else, output DS03_ILLEGAL_SALT_LENGTH with the length and the name servers IP addresses from the set with that salt length.
-
If the No Response NSEC Query set is non-empty then output DS03_NO_RESPONSE_NSEC_QUERY with the name server IP addresses from the set.
-
If the Error Response NSEC Query set is non-empty then output DS03_ERROR_RESPONSE_NSEC_QUERY with the name server IP addresses from the set.
Outcome(s)
The outcome of this Test Case is "fail" if there is at least one message with the severity level ERROR or CRITICAL.
The outcome of this Test Case is "warning" if there is at least one message with the severity level WARNING, but no message with severity level ERROR or CRITICAL.
In other cases, no message or only messages with severity level INFO or NOTICE, the outcome of this Test Case is "pass".
Special procedural requirements
If either IPv4 or IPv6 transport is disabled, skip sending queries over that transport protocol. A message will be outputted reporting that the transport protocol has been skipped.
See the DNSSEC README document about DNSSEC algorithms.
Intercase dependencies
None.
Terminology
No special terminology for this Test Case.
DNSSEC04: Check for too short or too long RRSIG lifetimes
Test case identifier
DNSSEC04 Check for too short or too long RRSIG lifetimes
Objective
Having RRSIG signature lifetimes last for too long opens up for DNS replay attacks. Having too short RRSIG signature lifetimes is likely to have a major operational impact if the master name server is down for that long.
There is no clear recommendation of the exact validity periods to use with DNSSEC. Shorter validity than 12 hours until expiration will give a serious operational problem just in case of temporary network problems, and longer than 180 days will create wide open holes for replay attacks.
The considerations are described in RFC6781.
Inputs
The domain name to be tested.
Ordered description of steps to be taken to execute the test case
- Obtain a set of name server IP addresses using Method4 and Method5.
- Create a DNSKEY query with DO flag set for the apex of the child zone.
- Create a SOA query with DO flag set for the apex of the child zone.
- Send the DNSKEY query over UDP to each name server IP address until a response is received or until the set is exhausted.
- Send the SOA query over UDP to each name server IP address until a response is received or until the set is exhausted.
- If any RRSIG validity is found where the expiration time already has passed, this test case fails.
- If any RRSIG validity time is shorter than 12 hours (from "now"), this test case fails.
- If any RRSIG validity time is longer than 180 days (from "now"), this test fails.
- If any RRSIG validity from inception to expiration is longer than 180 days, this test case fails.
Outcome(s)
If any of the signature expirations time is either shorter than 12 hours or longer than 180 days, this test case fails.
Special procedural requirements
Test case is only performed if RRSIG RRs are found in the answers.
Intercase dependencies
None.
DNSSEC05: Check for invalid DNSKEY algorithms
Test case identifier
DNSSEC05
Objective
A domain name (zone) should only use DNSKEY algorithms that are specified by RFC 8624, section 3.1 and the IANA registry of DNSSEC Algorithm Numbers to be used for DNSSEC signing. A public domain name (zone) should not use private algorithms.
If RFC 8624 and IANA registry disagree on the same algorithm, the RFC takes precedence until the registry has a been updated with a reference to the RFC.
The table of algorithms below is copied from IANA registry. Only the first three columns are copied. The complete table is available at IANA registry. In the table below, however, mnemonic is defined when undefined in the IANA table.
Algorithm no | Algorithm (or description) | Mnemonic | Note |
---|---|---|---|
0 | Delete DS | DELETE | |
1 | RSA/MD5 | RSAMD5 | |
2 | Diffie-Hellman | DH | |
3 | DSA/SHA1 | DSA | |
4 | Reserved | RESERVED | (1) |
5 | RSA/SHA-1 | RSASHA1 | |
6 | DSA-NSEC3-SHA1 | DSA-NSEC3-SHA1 | |
7 | RSASHA1-NSEC3-SHA1 | RSASHA1-NSEC3-SHA1 | |
8 | RSA/SHA-256 | RSASHA256 | |
9 | Reserved | RESERVED | (1) |
10 | RSA/SHA-512 | RSASHA512 | |
11 | Reserved | RESERVED | (1) |
12 | GOST R 34.10-2001 | ECC-GOST | |
13 | ECDSA Curve P-256 with SHA-256 | ECDSAP256SHA256 | |
14 | ECDSA Curve P-384 with SHA-384 | ECDSAP384SHA384 | |
15 | Ed25519 | ED25519 | |
16 | Ed448 | ED448 | |
17-122 | Unassigned | UNASSIGNED | (1) |
123-251 | Reserved | RESERVED | (1) |
252 | Reserved for Indirect Keys | INDIRECT | |
253 | private algorithm | PRIVATEDNS | |
254 | private algorithm OID | PRIVATEOID | |
255 | Reserved | RESERVED | (1) |
(1) Mnemonic defined for Zonemaster usage when undefined in the IANA table.
Scope
It is assumed that Child Zone is also tested by Connectivity01. This test case will set DEBUG level on messages for non-responsive name servers.
Inputs
- The domain name to be tested ("Child Zone").
- The status of all algorithms from RFC 8624 and IANA registry ("Algorithm Status").
Ordered description of steps to be taken to execute the test case
-
Create a DNSKEY query with DO flag set for the apex of the Child Zone.
-
Retrieve all name server IP addresses for the Child Zone using Method4 and Method5.
-
Repeat the following steps for each name server IP address:
- Send the DNSKEY query over UDP.
- If no DNS response is returned, then output NO_RESPONSE.
- Else if the DNS response does not contain an DNSKEY RRset, then output NO_RESPONSE_DNSKEY.
- Else extract the algorithm numbers from each DNSKEY record and
compare the algorithm number to Algorithm Status.
- If the algorithm is deprecated (algorithm 1, 3, 6 or 12) output ALGORITHM_DEPRECATED.
- If the algorithm is reserved (algorithm 4, 9, 11, 123-251 or 255), output ALGORITHM_RESERVED.
- If the algorithm is unassigned (algorithm 17-122), output ALGORITHM_UNASSIGNED.
- If the algorithm is private algorithm (algorithm 253-254), output ALGORITHM_PRIVATE.
- If the algorithm is not meant for zone signing (algorithm 0, 2 or 252), output ALGORITHM_NOT_ZONE_SIGN.
- If the algorithm is not recommended for zone signing (algorithm 5, 7 or 10), output ALGORITHM_NOT_RECOMMENDED.
- If no message has been outputted for the DNSKEY (i.e. algorithm 8, 13, 14, 15 or 16), output ALGORITHM_OK.
Outcome(s)
The outcome of this Test Case is "fail" if there is at least one message with the severity level ERROR or CRITICAL.
The outcome of this Test Case is "warning" if there is at least one message with the severity level WARNING, but no message with severity level ERROR or CRITICAL.
In other cases the outcome of this Test Case is "pass".
Message | Default severity level |
---|---|
NO_RESPONSE | DEBUG |
NO_RESPONSE_DNSKEY | WARNING |
ALGORITHM_DEPRECATED | ERROR |
ALGORITHM_RESERVED | ERROR |
ALGORITHM_UNASSIGNED | ERROR |
ALGORITHM_NOT_RECOMMENDED | WARNING |
ALGORITHM_PRIVATE | ERROR |
ALGORITHM_NOT_ZONE_SIGN | ERROR |
ALGORITHM_OK | INFO |
Special procedural requirements
If either IPv4 or IPv6 transport is disabled, ignore the evaluation of the result of any test using this transport protocol. Log a message reporting on the ignored result.
See the DNSSEC README document about DNSSEC algorithms.
The test case is only performed if some DNSKEY record is found in the Child Zone.
Intercase dependencies
None.
DNSSEC06: Verify DNSSEC additional processing
Test case identifier
DNSSEC06 Verify DNSSEC additional processing
Objective
In order for an authoritative name server to be DNSSEC compliant, it must serve DNSSEC signatures (RRSIG) as additional data in a DNS answer. This additional processing is described in section 3.1 of RFC 4035.
Inputs
The domain name to be tested.
Ordered description of steps to be taken to execute the test case
- For each name server configured for the domain:
- Retrieve the DNSKEY RR set from the child zone.
- If the answer from the query does contain a DNSKEY and RRSIG, this test case passes.
- If there is no DNSKEY RR or RRSIG RR in the answer and the RCODE is NOERROR, this test case fails.
Outcome(s)
If any of the name servers configured for the domains fail to answer with DNSSEC data, this test case fails.
Special procedural requirements
None.
Intercase dependencies
This test should only run if DNSSEC07 has been successful in finding a DNSKEY for the domain.
DNSSEC07: If DNSKEY at child, parent should have DS
Test case identifier
DNSSEC07 If DNSKEY at child, parent should have DS
Objective
If the child zone have a DNSKEY published, the intent may be to have a secure chain up to the root. If there is no DS record published at the parent zone, this might be a configuration error.
The method for authentication a DNS response is described in section 5 of RFC 4035. The DS record is described in section 5 of RFC 4034 and the DNSKEY record is described in section 2 of RFC 4034.
Inputs
The domain name to be tested.
Ordered description of steps to be taken to execute the test case
- Retrieve the DNSKEY RR set from the child zone.
- Retrieve the DS RR set from the parent zone.
- Issue a warning if there is a DNSKEY in the child zone and no DS in the parent zone.
Outcome(s)
A warning is issued there is a DNSKEY present in the child zone, and there is no DS record present in the parent zone.
Special procedural requirements
None.
Intercase dependencies
None.
DNSSEC08: Valid RRSIG for DNSKEY
Test case identifier
DNSSEC08
Table of contents
- Objective
- Scope
- Inputs
- Summary
- Test procedure
- Outcome(s)
- Special procedural requirements
- Intercase dependencies
- Terminology
Objective
A DNSSEC signed zone should have a DNSKEY RRset in the zone apex (RFC 4035, section 2.1) and that RRset should be signed by a key that matches one of the records in the DNSKEY RRset (RFC 4035, section 2.2).
This test case will verify if the Child Zone meets that requirement.
Scope
It is assumed that Child Zone is tested and reported by Connectivity01. This test case will just ignore non-responsive name servers or name servers not giving a correct DNS response for an authoritative name server.
This test case is only relevant if the zone has been DNSSEC signed.
Inputs
- "Child Zone" - The domain name to be tested.
Summary
- If no DNSKEY records are found, then further investigation will not be done and no messages will be outputted.
Message Tag outputted | Level | Arguments | Description of when message tag is outputted |
---|---|---|---|
DS08_ALGO_NOT_SUPPORTED_BY_ZM | NOTICE | ns_ip_list, algo_mnemo, algo_num, keytag | This installation of Zonemaster does not support the DNSKEY algorithm. |
DS08_DNSKEY_RRSIG_EXPIRED | ERROR | ns_ip_list, keytag | DNSKEY RRset is signed with an RRSIG that has expired. |
DS08_DNSKEY_RRSIG_NOT_YET_VALID | ERROR | ns_ip_list, keytag | DNSKEY RRset is signed with a not yet valid RRSIG. |
DS08_MISSING_RRSIG_IN_RESPONSE | ERROR | ns_ip_list | DNSKEY is unsigned which is against expectation. |
DS08_NO_MATCHING_DNSKEY | ERROR | ns_ip_list, keytag | DNSKEY RRset is signed with an RRSIG that does not match any DNSKEY. |
DS08_RRSIG_NOT_VALID_BY_DNSKEY | ERROR | ns_ip_list, keytag | DNSKEY RRset is signed with an RRSIG that cannot be validated by the matching DNSKEY. |
The value in the Level column is the default severity level of the message. The severity level can be changed in the Zonemaster-Engine profile. Also see the Severity Level Definitions document.
The argument names in the Arguments column lists the arguments used in the message. The argument names are defined in the argument list.
Test procedure
-
Create a DNSKEY query with DO flag set for Child Zone ("DNSKEY Query").
-
Retrieve all name server IP addresses for the Child Zone using Method4 and Method5 ("NS IP").
-
Create the following empty sets:
- Name server IP address ("DNSKEY without RRSIG").
- Name server IP address and RRSIG key tag ("DNSKEY RRSIG not yet valid").
- Name server IP address and RRSIG key tag ("DNSKEY RRSIG expired").
- Name server IP address and RRSIG key tag ("No matching DNSKEY").
- Name server IP address and RRSIG key tag ("RRSIG not valid by DNSKEY").
- Name server IP address, DNSKEY record key tag and DNSKEY algorithm code ("Algo Not Supported By ZM").
-
For each name server IP address in NS IP do:
- Send DNSKEY Query to the name server IP.
- If at least one of the following criteria is met, then go to next name
server IP:
- There is no DNS response.
- The RCODE of response is not "NoError" (IANA RCODE List).
- The AA flag is not set in the response.
- There is no DNSKEY record with matching owner name in the answer section.
- Retrieve the DNSKEY records and its RRSIG records from the answer section.
- If there is no RRSIG for the DNSKEY record, then add the name server IP address to the DNSKEY without RRSIG set and go to next name server IP.
- Else, for each DNSKEY RRSIG record do:
- If the RRSIG record start of validity is after the time of the test, then add name server IP and RRSIG key tag to the DNSKEY RRSIG not yet valid set.
- Else, if the RRSIG record end of validity is before the time of the test, then add name server IP and RRSIG key tag to the DNSKEY RRSIG expired set.
- Else, if the Zonemaster installation does not have support for the DNSKEY algorithm that created the RRSIG, then add name server IP, DNSKEY algorithm and DNSKEY key tag to the Algo Not Supported By ZM set.
- Else, if the RRSIG does not match any DNSKEY, then add the name server IP and the RRSIG key tag to the No matching DNSKEY set.
- Else, if the RRSIG cannot be validated by the matching DNSKEY record, then add the name server IP and the RRSIG key tag to the RRSIG not valid by DNSKEY set.
-
If the DNSKEY without RRSIG set is non-empty, then output DS08_MISSING_RRSIG_IN_RESPONSE with the name servers IP addresses from the set.
-
If the DNSKEY RRSIG not yet valid set is non-empty, then for each RRSIG key tag from the set output DS08_DNSKEY_RRSIG_NOT_YET_VALID with the key tag and the name servers IP addresses from the set.
-
If the DNSKEY RRSIG expired set is non-empty, then for each RRSIG key tag from the set output DS08_DNSKEY_RRSIG_EXPIRED with the key tag and the name servers IP addresses from the set.
-
If the No matching DNSKEY set is non-empty, then for each RRSIG key tag from the set output DS08_NO_MATCHING_DNSKEY with the key tag and the name servers IP addresses from the set.
-
If the RRSIG not valid by DNSKEY set is non-empty, then for each RRSIG key ID from the set output DS08_RRSIG_NOT_VALID_BY_DNSKEY with the key tag and the name servers IP addresses from the set.
-
If the Algo Not Supported By ZM set is non-empty, then output DS08_ALGO_NOT_SUPPORTED_BY_ZM for each DNSKEY key tag with the name server IP addresses, the key tag and the algorithm name and code from the set.
Outcome(s)
The outcome of this Test Case is "fail" if there is at least one message with the severity level ERROR or CRITICAL.
The outcome of this Test Case is "warning" if there is at least one message with the severity level WARNING, but no message with severity level ERROR or CRITICAL.
In other cases, no message or only messages with severity level INFO or NOTICE, the outcome of this Test Case is "pass".
Special procedural requirements
If either IPv4 or IPv6 transport is disabled, ignore the evaluation of the result of any test using this transport protocol. Log a message reporting on the ignored result.
See the DNSSEC README document about DNSSEC algorithms.
Intercase dependencies
None.
Terminology
No special terminology for this test case.
DNSSEC09: RRSIG(SOA) must be valid and created by a valid DNSKEY
Test case identifier
DNSSEC09
Table of contents
- Objective
- Scope
- Inputs
- Summary
- Test procedure
- Outcome(s)
- Special procedural requirements
- Intercase dependencies
- Terminology
Objective
If the zone is signed, the SOA RR should be signed with a valid RRSIG using a DNSKEY from the DNSKEY RR set. This is described in RFC 4035, section 2.2.
This test case will verify if the Child Zone meets that requirement.
Scope
It is assumed that Child Zone is tested and reported by Connectivity01. This test case will just ignore non-responsive name servers or name servers not giving a correct DNS response for an authoritative name server.
Inconsistencies in the SOA record are expected to be caught by Consistency01, Consistency02, Consistency03 and Consistency06.
Inconsistencies in the DNSKEY RRset are expected to be caught by DNSSEC08.
This test case is only relevant if the zone has been DNSSEC signed.
Inputs
- "Child Zone" - The domain name to be tested.
Summary
- If no DNSKEY records are found, then further investigation will not be done and no messages will be outputted.
Message Tag outputted | Level | Arguments | Description of when message tag is outputted |
---|---|---|---|
DS09_ALGO_NOT_SUPPORTED_BY_ZM | NOTICE | ns_ip_list, algo_mnemo, algo_num, keytag | This installation of Zonemaster does not support the DNSKEY algorithm. |
DS09_MISSING_RRSIG_IN_RESPONSE | ERROR | ns_ip_list | SOA is unsigned which is against expectation |
DS09_NO_MATCHING_DNSKEY | ERROR | ns_ip_list, keytag | SOA is signed with an RRSIG that does not match any DNSKEY |
DS09_RRSIG_NOT_VALID_BY_DNSKEY | ERROR | ns_ip_list, keytag | SOA is signed with an RRSIG that cannot be validated by the matching DNSKEY |
DS09_SOA_RRSIG_EXPIRED | ERROR | ns_ip_list, keytag | SOA is signed with an RRSIG that has expired |
DS09_SOA_RRSIG_NOT_YET_VALID | ERROR | ns_ip_list, keytag | SOA is signed with a not yet valid RRSIG |
The value in the Level column is the default severity level of the message. The severity level can be changed in the Zonemaster-Engine profile. Also see the Severity Level Definitions document.
The argument names in the Arguments column lists the arguments used in the message. The argument names are defined in the argument list.
Test procedure
-
Create a DNSKEY query with DO flag set for Child Zone ("DNSKEY Query").
-
Create an SOA query with DO flag set for Child Zone ("SOA Query").
-
Retrieve all name server IP addresses for the Child Zone using Method4 and Method5 ("NS IP").
-
Create the following empty sets:
- Name server IP address ("SOA without RRSIG").
- Name server IP address and RRSIG key tag ("SOA RRSIG not yet valid").
- Name server IP address and RRSIG key tag ("SOA RRSIG expired").
- Name server IP address and RRSIG key tag ("No matching DNSKEY").
- Name server IP address and RRSIG key tag ("RRSIG not valid by DNSKEY").
- Name server IP address, DNSKEY record key tag and DNSKEY algorithm code ("Algo Not Supported By ZM").
-
For each name server IP address in NS IP do:
- Send DNSKEY Query to the name server IP.
- If at least one of the following criteria is met, then go to next name
server IP:
- There is no DNS response.
- The RCODE of response is not "NoError" (IANA RCODE List).
- The AA flag is not set in the response.
- There is no DNSKEY record with matching owner name in the answer section.
- Retrieve the DNSKEY records with matching owner name from the answer section (any DNSKEY records with non-matching owner name are ignored).
- Send SOA Query over UDP to the name server IP.
- If at least one of the following criteria is met, then go to next name
server IP:
- There is no DNS response.
- The RCODE of response is not "NoError" (IANA RCODE List).
- The AA flag is not set in the response.
- There is no SOA record with matching owner name in the answer section.
- Retrieve the SOA record with matching owner name and its RRSIG record.
- Retrieve only one SOA record if there are multiple records. Any SOA records with non-matching owner name are ignored.
- If there is no RRSIG for the SOA record, then add the name server IP address to the SOA without RRSIG set and go to next name server IP.
- Else, for each SOA RRSIG record do:
- If the RRSIG record start of validity is after the time of the test, then add name server IP and RRSIG key tag to the SOA RRSIG not yet valid set.
- Else, if the RRSIG record end of validity is before the time of the test, then add name server IP and RRSIG key tag to the SOA RRSIG expired set.
- Else, if the Zonemaster installation does not have support for the DNSKEY algorithm that created the RRSIG, then add name server IP, DNSKEY algorithm and DNSKEY key tag to the Algo Not Supported By ZM set.
- Else, if the RRSIG does not match any DNSKEY, then add the name server IP and the RRSIG key tag to the No matching DNSKEY set.
- Else, if the RRSIG cannot be validated by the matching DNSKEY record, then add the name server IP and the RRSIG key tag to the RRSIG not valid by DNSKEY set.
-
If the SOA without RRSIG set is non-empty, then output DS09_MISSING_RRSIG_IN_RESPONSE with the name servers IP addresses from the set.
-
If the SOA RRSIG not yet valid set is non-empty, then for each RRSIG key tag from the set output DS09_SOA_RRSIG_NOT_YET_VALID with the key tag and the name servers IP addresses from the set.
-
If the SOA RRSIG expired set is non-empty, then for each RRSIG key tag from the set output DS09_SOA_RRSIG_EXPIRED with the key tag and the name servers IP addresses from the set.
-
If the No matching DNSKEY set is non-empty, then for each RRSIG key tag from the set output DS09_NO_MATCHING_DNSKEY with the key tag and the name servers IP addresses from the set.
-
If the RRSIG not valid by DNSKEY set is non-empty, then for each RRSIG key ID from the set output DS09_RRSIG_NOT_VALID_BY_DNSKEY with the key tag and the name servers IP addresses from the set.
-
If the Algo Not Supported By ZM set is non-empty, then output DS09_ALGO_NOT_SUPPORTED_BY_ZM for each DNSKEY key tag with the name server IP addresses, the key tag and the algorithm name and code from the set.
Outcome(s)
The outcome of this Test Case is "fail" if there is at least one message with the severity level ERROR or CRITICAL.
The outcome of this Test Case is "warning" if there is at least one message with the severity level WARNING, but no message with severity level ERROR or CRITICAL.
In other cases, no message or only messages with severity level INFO or NOTICE, the outcome of this Test Case is "pass".
Special procedural requirements
If either IPv4 or IPv6 transport is disabled, ignore the evaluation of the result of any test using this transport protocol. Log a message reporting on the ignored result.
See the DNSSEC README document about DNSSEC algorithms.
Intercase dependencies
None.
Terminology
No special terminology for this test case.
DNSSEC10: Zone contains NSEC or NSEC3 records
Test case identifier
DNSSEC10
Table of contents
- Objective
- Scope
- Inputs
- Summary
- Test procedure
- Outcome(s)
- Special procedural requirements
- Intercase dependencies
- Terminology
Objective
When DNSSEC is enabled, NSEC or NSEC3 records provide a secure denial of existence for records not present in the zone. This Test Case verifies that correct NSEC or NSEC3 records with valid signatures are returned for a query for an RR type that does not exist for that specific name (node in the DNS tree). The existing RR types are listed in the IANA RR Type List.
Furthermore, it is verified that the name servers for the zone are consistent about NSEC and NSEC3, i.e. either all servers should use NSEC or all servers should use NSEC3. It is never permitted to serve both NSEC and NSEC3 for the same zone.
The NSEC3PARAM RR that must exist in the zone (in apex, and apex only) if NSEC3 is used, but must not exist in a zone using NSEC.
The use of the NSEC RR type is described in RFC 4035, section 3.1.3, and the description of the NSEC RR itself is in RFC 4034, section 4.
The description of the NSEC3 and NSEC3PARAM RRs are found in RFC 5155, section 3, and RFC 5155, section 4, respectively. The use of NSEC3 in the DNS response is described in RFC 5155, section 7.2.
Scope
This test case will just ignore non-responsive name servers or name servers not giving a correct DNS response for an authoritative name server (covered by Connectivity01).
This test case is only relevant if the zone has been DNSSEC signed.
Inputs
- "Child Zone" - The domain name to be tested.
Summary
- If no DNSKEY records are found, then further investigation will not be done and no messages will be outputted.
Message Tag outputted | Level | Arguments | Message ID for message tag |
---|---|---|---|
DS10_ALGO_NOT_SUPPORTED_BY_ZM | NOTICE | ns_list, algo_mnemo, algo_num, keytag | DNSKEY with tag {keytag} uses unsupported algorithm {algo_num} ({algo_mnemo}) by this installation of Zonemaster. Fetched from name servers "{ns_list}". |
DS10_ERR_MULT_NSEC | ERROR | ns_list | Multiple NSEC records when one is expected. Fetched from name servers "{ns_list}". |
DS10_ERR_MULT_NSEC3 | ERROR | ns_list | Multiple NSEC3 records when one is expected. Fetched from name servers "{ns_list}". |
DS10_ERR_MULT_NSEC3PARAM | ERROR | ns_list | Multiple NSEC3PARAM records when one is expected. Fetched from name servers "{ns_list}". |
DS10_EXPECTED_NSEC_NSEC3_MISSING | ERROR | ns_list | The server responded with DNSKEY but not with expected NSEC or NSEC3. Fetched from name servers "{ns_list}". |
DS10_HAS_NSEC | INFO | ns_list | The zone has NSEC records. Fetched from name servers "{ns_list}". |
DS10_HAS_NSEC3 | INFO | ns_list | The zone has NSEC3 records. Fetched from name servers "{ns_list}". |
DS10_INCONSISTENT_NSEC | ERROR | ns_list | Inconsistent responses from zone with NSEC. Fetched from name servers "{ns_list}". |
DS10_INCONSISTENT_NSEC3 | ERROR | ns_list | Inconsistent responses from zone with NSEC3. Fetched from name servers "{ns_list}". |
DS10_INCONSISTENT_NSEC_NSEC3 | ERROR | ns_list_nsec, ns_list_nsec3 | The zone is inconsistent on NSEC and NSEC3. NSEC is fetched from name servers "{ns_list_nsec}". NSEC3 is fetched from name servers "{ns_list_nsec3}". |
DS10_MIXED_NSEC_NSEC3 | ERROR | ns_list | The zone responds with both NSEC and NSEC3, where only one of them is expected. Fetched from name servers "{ns_list}". |
DS10_NSEC3PARAM_GIVES_ERR_ANSWER | ERROR | ns_list | Unexpected DNS record in the answer section on an NSEC3PARAM query. Fetched from name servers "{ns_list}". |
DS10_NSEC3PARAM_MISMATCHES_APEX | ERROR | ns_list | The returned NSEC3PARAM record has an unexpected non-apex owner name. Fetched from name servers "{ns_list}". |
DS10_NSEC3PARAM_QUERY_RESPONSE_ERR | ERROR | ns_list | No response or error in response on query for NSEC3PARAM. Fetched from name servers "{ns_list}". |
DS10_NSEC3_ERR_TYPE_LIST | ERROR | ns_list | NSEC3 record for the zone apex with incorrect type list. Fetched from name servers "{ns_list}". |
DS10_NSEC3_MISMATCHES_APEX | ERROR | ns_list | The returned NSEC3 record unexpectedly does not match the zone name. Fetched from name servers "{ns_list}". |
DS10_NSEC3_MISSING_SIGNATURE | ERROR | ns_list | Missing RRSIG (signature) for the NSEC3 record or records. Fetched from name servers "{ns_list}". |
DS10_NSEC3_NODATA_MISSING_SOA | ERROR | ns_list | Missing SOA record in NODATA response with NSEC3. Fetched from name servers "{ns_list}". |
DS10_NSEC3_NODATA_WRONG_SOA | ERROR | ns_list, domain | Wrong owner name ("{domain}") on SOA record in NODATA response with NSEC3. Fetched from name servers "{ns_list}". |
DS10_NSEC3_NO_VERIFIED_SIGNATURE | ERROR | ns_list | The RRSIG (signature) for the NSEC3 record cannot be verified. Fetched from name servers "{ns_list}". |
DS10_NSEC3_RRSIG_EXPIRED | ERROR | ns_list, keytag | The RRSIG (signature) with tag {keytag} for the NSEC3 record has expired. Fetched from name servers "{ns_list}". |
DS10_NSEC3_RRSIG_NOT_YET_VALID | ERROR | ns_list, keytag | The RRSIG (signature) with tag {keytag} for the NSEC3 record it not yet valid. Fetched from name servers "{ns_list}". |
DS10_NSEC3_RRSIG_NO_DNSKEY | WARNING | ns_list, keytag | There is no DNSKEY record matching the RRSIG (signature) with tag {keytag} for the NSEC3 record. Fetched from name servers "{ns_list}". |
DS10_NSEC3_RRSIG_VERIFY_ERROR | ERROR | ns_list, keytag | The RRSIG (signature) with tag {keytag} for the NSEC3 record cannot be verified. Fetched from name servers "{ns_list}". |
DS10_NSEC_ERR_TYPE_LIST | ERROR | ns_list | NSEC record for the zone apex with incorrect type list. Fetched from name servers "{ns_list}". |
DS10_NSEC_GIVES_ERR_ANSWER | ERROR | ns_list | Unexpected DNS record in the answer section on an NSEC query. Fetched from name servers "{ns_list}". |
DS10_NSEC_MISMATCHES_APEX | ERROR | ns_list | The returned NSEC record has an unexpected non-apex owner name. Fetched from name servers "{ns_list}". |
DS10_NSEC_MISSING_SIGNATURE | ERROR | ns_list | Missing RRSIG (signature) for the NSEC record or records. Fetched from name servers "{ns_list}". |
DS10_NSEC_NODATA_MISSING_SOA | ERROR | ns_list | Missing SOA record in NODATA response with NSEC. Fetched from name servers "{ns_list}". |
DS10_NSEC_NODATA_WRONG_SOA | ERROR | ns_list, domain | Wrong owner name ("{domain}") on SOA record in NODATA response with NSEC. Fetched from name servers "{ns_list}". |
DS10_NSEC_NO_VERIFIED_SIGNATURE | ERROR | ns_list | There is no RRSIG (signature) for the NSEC record that can be verified. Fetched from name servers "{ns_list}". |
DS10_NSEC_QUERY_RESPONSE_ERR | ERROR | ns_list | No response or error in response on query for NSEC. Fetched from name servers "{ns_list}". |
DS10_NSEC_RRSIG_EXPIRED | ERROR | ns_list, keytag | The RRSIG (signature) with tag {keytag} for the NSEC record has expired. Fetched from name servers "{ns_list}". |
DS10_NSEC_RRSIG_NOT_YET_VALID | ERROR | ns_list, keytag | The RRSIG (signature) with tag {keytag} for the NSEC record it not yet valid. Fetched from name servers "{ns_list}". |
DS10_NSEC_RRSIG_NO_DNSKEY | WARNING | ns_list, keytag | There is no DNSKEY record matching the RRSIG (signature) with tag {keytag} for the NSEC record. Fetched from name servers "{ns_list}". |
DS10_NSEC_RRSIG_VERIFY_ERROR | ERROR | ns_list, keytag | The RRSIG (signature) with tag {keytag} for the NSEC record cannot be verified. Fetched from name servers "{ns_list}". |
DS10_SERVER_NO_DNSSEC | ERROR | ns_list | The following name servers do not support DNSSEC or have not been properly configured. Testing for NSEC and NSEC3 has been skipped on these servers. Fetched from name servers "{ns_list}". |
DS10_ZONE_NO_DNSSEC | NOTICE | ns_list | The zone is not DNSSEC signed or not properly DNSSEC signed. Testing for NSEC and NSEC3 has been skipped. Fetched from name servers "{ns_list}". |
The value in the Level column is the default severity level of the message. The severity level can be changed in the Zonemaster-Engine profile. Also see the Severity Level Definitions document.
The argument names in the Arguments column lists the arguments used in the message. The argument names are defined in the argument list.
The name server names are assumed to be available at the time when the msgid is created, if the argument name is "ns" or "ns_list" even when in the "Test procedure" below it is only referred to the IP address of the name servers.
For the Zonemaster definition of the mnemonics for DNSKEY algorithms, see the algorithm table in the "Objective" section in DNSSEC05.
Comments on mixing of NSEC and NSEC3
In section "Test procedure" below, if the server returns an NSEC record (either in the answer section when querying for NSEC or on the authority section when querying for NSEC3PARAM) it is considered to be "NSEC type" for the zone.
If the server returns an NSEC3PARAM record in the answer section when querying for it or an NSEC3 record in the authority section when querying for NSEC, it is considered to be "NSEC3 type" for the zone.
DS10_MIXED_NSEC_NSEC3 means that one or several name servers have been identified as both "NSEC type" and "NSEC3 type".
DS10_INCONSISTENT_NSEC_NSEC3 means that some name servers are non-mixed "NSEC type" and others are non-mixed "NSEC3 type" for the same zone.
Test procedure
In this section and unless otherwise specified below, the term "DNSSEC Query" follow the specification for DNS queries as specified in DNS Query and Response Defaults. The handling of the DNS responses on the DNS queries follow, unless otherwise specified below, what is specified for DNSSEC Response in the same specification.
A complete list of all DNS Resource Record types can be found in the IANA RR Type List.
-
Create a DNSSEC Query with query type DNSKEY and query name Child Zone ("DNSKEY Query").
-
Create a DNSSEC Query with query type NSEC and query name Child Zone ("NSEC Query").
-
Create a DNSSEC Query with query type NSEC3PARAM and query name Child Zone ("NSEC3PARAM Query").
-
Retrieve all name server names and IP addresses for Child Zone using methods Get-Del-NS-Names-and-IPs and Get-Zone-NS-Names-and-IPs ("NS IP").
-
Create the following empty sets:
- Name server IP address, DNSKEY record key tag and DNSKEY algorithm code ("Algo Not Supported By ZM").
- Name server IP address ("Erroneous Multiple NSEC").
- Name server IP address ("Erroneous Multiple NSEC3").
- Name server IP address ("Erroneous Multiple NSEC3PARAM").
- Name server IP address ("NSEC In Answer").
- Name server IP address ("NSEC Incorrect Type List").
- Name server IP address ("NSEC Mismatches Apex").
- Name server IP address ("NSEC Missing Signature").
- Name server IP address and owner name (domain name data) ("NSEC NODATA Wrong SOA").
- Name server IP address ("NSEC NODATA Missing SOA").
- Name server IP address ("NSEC Query Gives Erroneous Answer").
- Name server IP address ("NSEC Query Gives NSEC3 NODATA").
- Name server IP address and key tag ("NSEC RRSIG Verify Error").
- Name server IP address and key tag ("NSEC RRSIG Expired").
- Name server IP address and key tag ("NSEC RRSIG Not Yet Valid").
- Name server IP address and key tag ("NSEC RRSIG No DNSKEY").
- Name server IP address ("NSEC RRSIG Verified").
- Name server IP address ("NSEC Query Response Error").
- Name server IP address ("NSEC3 Incorrect Type List").
- Name server IP address ("NSEC3 Mismatches Apex").
- Name server IP address ("NSEC3 Missing Signature").
- Name server IP address and owner name (domain name data) ("NSEC3 NODATA Wrong SOA").
- Name server IP address ("NSEC3 NODATA Missing SOA").
- Name server IP address and key tag ("NSEC3 RRSIG Verify Error").
- Name server IP address and key tag ("NSEC3 RRSIG Expired").
- Name server IP address and key tag ("NSEC3 RRSIG Not Yet Valid").
- Name server IP address and key tag ("NSEC3 RRSIG No DNSKEY").
- Name server IP address ("NSEC3 RRSIG Verified").
- Name server IP address ("NSEC3PARAM In Answer").
- Name server IP address ("NSEC3PARAM Mismatches Apex").
- Name server IP address ("NSEC3PARAM Query Gives Erroneous Answer").
- Name server IP address ("NSEC3PARAM Query Gives NSEC NODATA").
- Name server IP address ("NSEC3PARAM Query Response Error").
- Name server IP address ("Responds without DNSKEY").
- Name server IP address ("Responds with DNSKEY").
-
For each name server IP address in NS IP do:
-
Send DNSKEY Query to the name server IP.
-
If at least one of the following criteria is met, then go to next name server IP:
- There is no DNS response.
- The RCODE Name in the response is not "NoError".
- The AA flag is not set in the response.
-
If the response does not contain any DNSKEY record with owner name matching Child Zone in the answer section, add name server name and IP to the Responds without DNSKEY set and go to next server.
-
Else, add name server IP to the Responds with DNSKEY set and retrieve the DNSKEY records from the answer section to be used in validation below.
-
Send NSEC Query to the name server IP and do:
- If at least one of the following criteria is met, then add the name
server IP to the NSEC Query Response Error set:
- There is no DNS response.
- The RCODE Name in the response is not "NoError".
- The AA flag is not set in the response.
- Else if the answer section is non-empty, then do:
- If the answer section has at least one NSEC RR then do:
- Add the name server IP to the NSEC In Answer set.
- If the number of NSEC records is greater than one then add name server IP to the Erroneous Multiple NSEC set.
- Else, if the owner name of the NSEC record is not Child Zone then add name server IP to the NSEC Mismatches Apex set.
- Else add the name server IP to the NSEC Query Gives Erroneous Answer set.
- If the answer section has at least one NSEC RR then do:
- Else if the answer section is empty and the authority section contains
an NSEC3 record then do:
- Add the name server IP to the NSEC Query Gives NSEC3 NODATA set.
- If the SOA record is missing from the authority section then add name server IP to the NSEC3 NODATA Missing SOA set.
- Else if the owner name of SOA record is not Child Zone then add name server IP and owner name to the NSEC3 NODATA Wrong SOA set.
- If the authority section contains more than one NSEC3 record then add name server IP to the Erroneous Multiple NSEC3 set.
- Else do:
- If the hash owner name of the NSEC3 record does not match apex of Child Zone then add name server IP to the NSEC3 Mismatches Apex set.
- Else if the type list in the NSEC3 record matches at least one
of the following criteria then add name server IP to the
NSEC3 Incorrect Type List set:
- At least one of SOA, NS, DNSKEY, NSEC3PARAM or RRSIG is missing.
- At least one of NSEC or NSEC3 is included.
- Retrieve the NSEC3 record from the response.
- Retrieve the RRSIG records for the retrieved NSEC3 record.
- If the NSEC3 record do not have a matching RRSIG record, then add the name server IP to the NSEC3 Missing Signature set.
- Else do:
- Use the DNSKEY records retrieved above.
- For each NSEC3 RRSIG do:
- Verify the RRSIG record by the DNSKEY records.
- If there is no DNSKEY that matches RRSIG by key tag, then add the name server IP and RRSIG key ID to the NSEC3 RRSIG No DNSKEY set.
- Else, if the RRSIG record has a validity period that ends before the time of test execution, then add the name server IP and RRSIG key ID to the NSEC3 RRSIG Expired set.
- Else, if the RRSIG record has a validity period that starts after the time of test execution, then add the name server IP and RRSIG key ID to the NSEC3 RRSIG Not Yet Valid set.
- Else, if the Zonemaster installation does not have support for the DNSKEY algorithm that created the RRSIG, then add name server IP, DNSKEY algorithm and DNSKEY key tag to the Algo Not Supported By ZM set.
- Else, if the RRSIG cannot be validated by the DNSKEY record appointed, then add name server IP and DNSKEY key tag to the NSEC3 RRSIG Verify Error set.
- Else, add the name server IP to the NSEC3 RRSIG Verified set.
- If at least one of the following criteria is met, then add the name
server IP to the NSEC Query Response Error set:
-
Send NSEC3PARAM Query to the name server IP and do:
- If at least one of the following criteria is met, then add the name
server IP to the NSEC3PARAM Query Response Errors set:
- There is no DNS response.
- The RCODE Name in the response is not "NoError".
- The AA flag is not set in the response.
- Else if the answer section is non-empty, then do:
- If the answer section has at least one NSEC3PARAM RR then do:
- Add the name server IP to the NSEC3PARAM In Answer set.
- If the number of NSEC3PARAM records is greater than one then add name server IP to the Erroneous Multiple NSEC3PARAM set.
- Else, if the owner name of the NSEC3PARAM record is not Child Zone then add name server IP to the NSEC3PARAM Mismatches Apex set.
- Else add the name server IP to the NSEC3PARAM Query Gives Erroneous Answer set.
- If the answer section has at least one NSEC3PARAM RR then do:
- Else if the answer section is empty and the authority section contains
an NSEC record then do:
- Add the name server IP to the NSEC3PARAM Query Gives NSEC NODATA set.
- If the SOA record is missing the authority section then add the name server IP to the NSEC NODATA Missing SOA set.
- Else if the owner name of the SOA record is not Child Zone then add name server IP and the owner name to the NSEC NODATA Wrong SOA set.
- If the authority section contains more than one NSEC record then add name server IP to the Erroneous Multiple NSEC set.
- Else do:
- If the owner name of the NSEC record is not Child Zone then add name server IP to the NSEC Mismatches Apex set.
- Else if the type list in the NSEC record matches at least one
of the following criteria then add name server IP to the
NSEC Incorrect Type List set:
- At least one of SOA, NS, DNSKEY, NSEC or RRSIG is missing.
- At least one of NSEC3PARAM or NSEC3 is included.
- Retrieve the NSEC record from the response.
- Retrieve the RRSIG records for the retrieved NSEC record.
- If the NSEC record does not have a matching RRSIG record, then add the name server IP to the NSEC Missing Signature set.
- Else do:
- Use the DNSKEY records retrieved above.
- For each NSEC RRSIG do:
- Verify the RRSIG record by the DNSKEY records.
- If there is no DNSKEY that matches RRSIG by key tag, then add the name server IP and RRSIG key ID to the NSEC RRSIG No DNSKEY set.
- Else, if the RRSIG record has a validity period that ends before the time of test execution, then add the name server IP and RRSIG key ID to the NSEC RRSIG Expired set.
- Else, if the RRSIG record has a validity period that starts after the time of test execution, then add the name server IP and RRSIG key ID to the NSEC RRSIG Not Yet Valid set.
- Else, if the Zonemaster installation does not have support for the DNSKEY algorithm that created the RRSIG, then add name server IP, DNSKEY algorithm and DNSKEY key tag to the Algo Not Supported By ZM set.
- Else, if the RRSIG cannot be validated by the DNSKEY record appointed, then add name server IP and DNSKEY key tag to the NSEC RRSIG Verify Error set.
- Else, add the name server IP to the NSEC RRSIG Verified set (unless it is already a member of the set).
- If at least one of the following criteria is met, then add the name
server IP to the NSEC3PARAM Query Response Errors set:
-
-
If the Erroneous Multiple NSEC set is non-empty then output DS10_ERR_MULT_NSEC with the name server IP addresses from the set.
-
If the Erroneous Multiple NSEC3 set is non-empty then output DS10_ERR_MULT_NSEC3 with the name server IP addresses from the set.
-
If the Erroneous Multiple NSEC3PARAM set is non-empty then output DS10_ERR_MULT_NSEC3PARAM with the name server IP addresses from the set.
-
Create a list of those name server IP included in the NSEC In Answer set but not in the NSEC3PARAM Query Gives NSEC NODATA set, or the other way around. From that list remove any name server IP included in the NSEC3PARAM In Answer set or in the NSEC Query Gives NSEC3 NODATA set. Output DS10_INCONSISTENT_NSEC with the resulting list of name server IP addresses.
-
Create a list of those name server IP included in the NSEC3PARAM In Answer set but not in the NSEC Query Gives NSEC3 NODATA set, or the other way around. From that list remove any name server IP included in the NSEC In Answer set or the NSEC3PARAM Query Gives NSEC NODATA set. Output DS10_INCONSISTENT_NSEC3 with the resulting list of name server IP addresses.
-
Create a list of those name server IP included in the NSEC3PARAM In Answer set or in the NSEC Query Gives NSEC3 NODATA set, and also included in the NSEC In Answer set or the NSEC3PARAM Query Gives NSEC NODATA set. Output DS10_MIXED_NSEC_NSEC3 with the resulting list of name server IP addresses.
-
If the NSEC In Answer set or the NSEC3PARAM Query Gives NSEC NODATA set (or both) is non-empty and both the NSEC3PARAM In Answer set and the NSEC Query Gives NSEC3 NODATA set are empty, then output DS10_HAS_NSEC with the name server IP addresses from the sets.
-
If the NSEC3PARAM In Answer set or the NSEC Query Gives NSEC3 NODATA set (or both) is non-empty and both the NSEC In Answer set and the NSEC3PARAM Query Gives NSEC NODATA set are empty, then output DS10_HAS_NSEC3 with the name server IP addresses from the sets.
-
Create a list of the name server IP in the NSEC3PARAM In Answer set or in the NSEC Query Gives NSEC3 NODATA set (or both), but neither in the NSEC In Answer set or the NSEC3PARAM Query Gives NSEC NODATA set. Create a second list of the name server IP in the NSEC In Answer set or in the NSEC3PARAM Query Gives NSEC NODATA set (or both), but neither in the NSEC3PARAM In Answer set or the NSEC Query Gives NSEC3 NODATA set. If both lists are non-empty then output DS10_INCONSISTENT_NSEC_NSEC3 with both the lists.
-
If the NSEC Incorrect Type List set is non-empty, then output *DS10_NSEC_ERR_TYPE_LIST with the list of name server IP in the set.
-
If the NSEC Mismatches Apex set is non-empty, then output *DS10_NSEC_MISMATCHES_APEX with the list of name server IP in the set.
-
If the NSEC NODATA Wrong SOA set is non-empty, then for each owner name in the set output DS10_NSEC_NODATA_WRONG_SOA with the owner name and the list of name server IP in the set for that owner name.
-
If the NSEC NODATA Missing SOA set is non-empty, then output DS10_NSEC_NODATA_MISSING_SOA with the list of name server IP in the set.
-
If the NSEC Query Gives Erroneous Answer set is non-empty, then output DS10_NSEC_GIVES_ERR_ANSWER with the list of name server IP in the set.
-
If the NSEC Query Response Error set is non-empty, then output DS10_NSEC_QUERY_RESPONSE_ERR with the list of name server IP in the set.
-
If the NSEC3 Incorrect Type List set is non-empty, then output DS10_NSEC3_ERR_TYPE_LIST with the list of name server IP in the set.
-
If the NSEC3 Mismatches Apex set is non-empty, then output DS10_NSEC3_MISMATCHES_APEX with the list of name server IP in the set.
-
If the NSEC3 NODATA Wrong SOA set is non-empty, then for each owner name in the set output DS10_NSEC3_NODATA_WRONG_SOA with the owner name and the list of name server IP in the set for that owner name.
-
If the NSEC3 NODATA Missing SOA set is non-empty, then output DS10_NSEC3_NODATA_MISSING_SOA with the list of name server IP in the set.
-
If the NSEC3PARAM Query Gives Erroneous Answer set is non-empty, then output DS10_NSEC3PARAM_GIVES_ERR_ANSWER with the list of name server IP in the set.
-
If the NSEC3PARAM Mismatches Apex set is non-empty, then output DS10_NSEC3PARAM_MISMATCHES_APEX with the list of name server IP in the set.
-
If the NSEC3PARAM Query Response Error set is non-empty, then output DS10_NSEC3PARAM_QUERY_RESPONSE_ERR with the list of name server IP in the set.
-
If the NSEC Missing Signature set is non-empty then output DS10_NSEC_MISSING_SIGNATURE with the name server IP addresses from the set.
-
If the NSEC3 Missing Signature set is non-empty then output DS10_NSEC3_MISSING_SIGNATURE with the name server IP addresses from the set.
-
If the NSEC RRSIG No DNSKEY set is non-empty, then for each key ID output DS10_NSEC_RRSIG_NO_DNSKEY with the key ID and the name server IP addresses from the set for the key ID.
-
If the NSEC RRSIG Expired set is non-empty, then for each key ID output DS10_NSEC_RRSIG_EXPIRED with the key ID and the name server IP addresses from the set for the key ID.
-
If the NSEC RRSIG Not Yet Valid set is non-empty, then for each key ID output DS10_NSEC_RRSIG_NOT_YET_VALID with the key ID and the name server IP addresses from the set for the key ID.
-
If the NSEC RRSIG Verify Error set is non-empty, then for each key ID output DS10_NSEC_RRSIG_VERIFY_ERROR with the key ID and the name server IP addresses from the set for the key ID.
-
If the combined set of the unique name server IP addresses of the NSEC RRSIG No DNSKEY, NSEC RRSIG Expired, NSEC RRSIG Not Yet Valid and NSEC RRSIG Verify Error sets is non-empty, then do:
- For each name server IP address in the combined set store the IP address in a temporary set for the next step if the IP address is not a member of the NSEC RRSIG Verified set.
- If the temporary set is non-empty then output DS10_NSEC_NO_VERIFIED_SIGNATURE with the name server IP addresses from the set.
-
If the NSEC3 RRSIG No DNSKEY set is non-empty, then for each key ID output DS10_NSEC3_RRSIG_NO_DNSKEY with the key ID and the name server IP addresses from the set for the key ID.
-
If the NSEC3 RRSIG Expired set is non-empty, then for each key ID output DS10_NSEC3_RRSIG_EXPIRED with the key ID and the name server IP addresses from the set for the key ID.
-
If the NSEC3 RRSIG Not Yet Valid set is non-empty, then for each key ID output DS10_NSEC3_RRSIG_NOT_YET_VALID with the key ID and the name server IP addresses from the set for the key ID.
-
If the NSEC3 RRSIG Verify Error set is non-empty, then for each key ID output DS10_NSEC3_RRSIG_VERIFY_ERROR with the key ID and the name server IP addresses from the set for the key ID.
-
If the combined set of the NSEC3 RRSIG No DNSKEY, NSEC3 RRSIG Expired, NSEC3 RRSIG Not Yet Valid and NSEC3 RRSIG Verify Error sets is non-empty, then do:
- Extract all unique name server IP address in the combined set that are not members the NSEC3 RRSIG Verified set.
- If the extracted name server IP addresses is a non-empty set then output DS10_NSEC3_NO_VERIFIED_SIGNATURE with the extracted name server IP addresses.
-
If the Algo Not Supported By ZM set is non-empty, then output DS10_ALGO_NOT_SUPPORTED_BY_ZM for each DNSKEY key tag with the name server IP addresses, the key tag and the algorithm name and code from the set.
-
If the Responds with DNSKEY set is empty and the Responds without DNSKEY is non-empty then output DS10_ZONE_NO_DNSSEC with the name server IP addresses from the Responds without DNSKEY set.
-
If both the Responds with DNSKEY set and the Responds without DNSKEY set are non-empty then output DS10_SERVER_NO_DNSSEC with the name server IP addresses from the Responds without DNSKEY set.
-
Extract all members of the NS IP set that is not also a member of the Responds without DNSKEY set, the NSEC In Answer set, the NSEC3PARAM Query Gives NSEC NODATA set, the NSEC3PARAM In Answer set or the NSEC Query Gives NSEC3 NODATA set. If the extracted set is non-empty, then output DS10_EXPECTED_NSEC_NSEC3_MISSING with the extracted list of name server IP addresses.
Outcome(s)
The outcome of this Test Case is "fail" if there is at least one message with the severity level ERROR or CRITICAL.
The outcome of this Test Case is "warning" if there is at least one message with the severity level WARNING, but no message with severity level ERROR or CRITICAL.
In other cases, no message or only messages with severity level INFO or NOTICE, the outcome of this Test Case is "pass".
Special procedural requirements
If either IPv4 or IPv6 transport is disabled, skip sending queries over that transport protocol. A message will be outputted reporting that the transport protocol has been skipped.
See the DNSSEC README document about DNSSEC algorithms.
Intercase dependencies
None.
Terminology
No special terminology for this Test Case.
DNSSEC11: DS in delegation requires signed zone
Test case identifier
DNSSEC11
Table of contents
- Objective
- Scope
- Inputs
- Summary
- Test procedure
- Outcome(s)
- Special procedural requirements
- Intercase dependencies
- Terminology
Objective
If the delegation of the zone contains DS records, i.e. if the parent zone has DS records with the same owner name as the apex of the zone, then the zone must be signed. If not, a DNSSEC aware resolver should consider the zone to be "bogus" (see RFC 4033, section 5), and the zone will be unavailable.
This test case will verify that a zone with DS in delegation from parent is also signed. Here we just verify that it has DNSKEY in apex.
Scope
It is assumed that Child Zone is tested and reported by other test cases:
- This test case will ignore non-responsive name servers or name servers not giving a correct DNS response for an authoritative name server (covered by Connectivity01).
- This test case will ignore any irregularities in fetching the DS record from parent zone (covered by DNSSEC02).
- This test case will ignore if the DNSKEY and SOA RRsets are not signed (covered by DNSSEC08 and DNSSEC09, respectively).
Inputs
- "Child Zone" - The domain name to be tested.
- "Test Type" - The test type with value "undelegated" or "normal".
- "Undelegated DS" - The DS record or records submitted (only if Test Type is undelegated).
Summary
- If there are no DS records in the parent zone, this test case will terminate without outputting any message.
Message Tag outputted | Level | Arguments | Description of when message tag is outputted |
---|---|---|---|
DS11_INCONSISTENT_DS | WARNING | Parent name servers are inconsistent on the existence of DS. | |
DS11_INCONSISTENT_SIGNED_ZONE | ERROR | Name servers for the child zone are inconsistent on whether the zone is signed or not. | |
DS11_UNDETERMINED_DS | ERROR | It cannot be determined if the parent zone has DS for the child zone or not. | |
DS11_UNDETERMINED_SIGNED_ZONE | ERROR | It cannot be determined if the child zone is signed or not. | |
DS11_PARENT_WITHOUT_DS | NOTICE | ns_ip_list | List of parent name servers without DS for the child zone. |
DS11_PARENT_WITH_DS | NOTICE | ns_ip_list | List of parent name servers with DS for the child zone. |
DS11_NS_WITH_SIGNED_ZONE | NOTICE | ns_ip_list | List of child name servers with signed child zone. |
DS11_NS_WITH_UNSIGNED_ZONE | WARNING | ns_ip_list | List of child name servers with unsigned child zone. |
DS11_DS_BUT_UNSIGNED_ZONE | ERROR | The child zone is unsigned, but the parent zone has DS record. |
The value in the Level column is the default severity level of the message. The severity level can be changed in the Zonemaster-Engine profile. Also see the Severity Level Definitions document.
The argument names in the Arguments column lists the arguments used in the message. The argument names are defined in the argument list.
Test procedure
-
Create the following empty sets:
- Parent name server IP address ("Undetermined DS").
- Parent name server IP address ("No DS Record").
- Parent name server IP address ("Has DS Record").
- Child name server IP address ("Undetermined DNSKEY")
- Child name server IP address ("No DNSKEY Record").
- Child name server IP address ("Has DNSKEY Record").
-
If the Test Type is "undelegated" and if Undelegated DS is empty, then do exit this test case.
-
If Test Type is "normal", then:
-
Create a DS query with the DO flag set for the name of the Child Zone ("DS Query").
-
Retrieve all name server IP addresses for the parent zone of Child Zone using Method1 ("Parent NS IP").
-
For each name server IP in Parent NS IP do:
- Send DS Query to the name server IP.
- If the response has the TC flag set, re-query over TCP and use that response instead.
- Add the name server (IP) to the Undetermined DS set if at least one
of the following criteria matches:
- There is no DNS response.
- The RCODE of response is not "NoError" (IANA RCODE List).
- The AA flag is not set in the response.
- If there is no DS record with matching owner name in the answer section, then add the name server (IP) to the No DS Record set.
- Else add the name server (IP) to the Has DS Record set.
-
If the Undetermined DS set is non-empty and both the No DS Record and Has DS Record sets are empty then do:
- Output DS11_UNDETERMINED_DS.
- Exit this test case.
-
If the No DS Record set is non-empty and the Has DS Record set is empty then exit this test case.
-
If both the No DS Record and Has DS Record sets are non-empty, then do:
- Output DS11_INCONSISTENT_DS.
- Output DS11_PARENT_WITHOUT_DS and list parent name servers in No DS Record.
- Output DS11_PARENT_WITH_DS and list parent name servers in Has DS Record.
-
-
Create DNS queries for the child zone:
- SOA query for the Child Zone without any OPT record (no EDNS) ("SOA Query").
- DNSKEY query for the Child Zone with the DO flag set ("DNSKEY Query").
-
Obtain the set of child name server IP addresses using Method4 and Method5 ("Child NS IP").
-
For each name server IP in Child NS IP do:
-
Send SOA Query over UDP to the name server IP and collect the response.
-
Go to next name server if
- there is no DNS response on the SOA query, or
- the RCODE of the response is not "NoError" (IANA RCODE List), or
- the AA flag is not set in the response, or
- there is no SOA record with owner name matching the query in the answer section.
-
Send DNSKEY Query over UDP to the name server IP and collect the response.
-
If the response has the TC flag set, re-query over TCP and use that response instead.
-
Add the name server (IP) to the Undetermined DNSKEY set if at least one of the following criteria matches:
- There is no DNS response.
- The RCODE of response is not "NoError" (IANA RCODE List).
- The AA flag is not set in the response.
-
If there is no DNSKEY record with matching owner name in the answer section, then add the name server (IP) to the No DNSKEY Record set.
-
Else add the name server (IP) to the Has DNSKEY Record set.
-
-
If the Undetermined DNSKEY set is non-empty and both the No DNSKEY Record and Has DNSKEY Record sets are empty then output DS11_UNDETERMINED_SIGNED_ZONE.
-
Else, if the No DNSKEY Record set is non-empty and the Has DNSKEY Record set is empty then output DS11_DS_BUT_UNSIGNED_ZONE.
-
Else, if both the No DNSKEY Record and Has DNSKEY Record sets are non-empty, then do:
- Output DS11_INCONSISTENT_SIGNED_ZONE.
- Output DS11_NS_WITH_UNSIGNED_ZONE and list name servers in No DNSKEY Record.
- Output DS11_NS_WITH_SIGNED_ZONE and list name servers in Has DNSKEY Record.
Outcome(s)
The outcome of this Test Case is "fail" if there is at least one message with the severity level ERROR or CRITICAL.
The outcome of this Test Case is "warning" if there is at least one message with the severity level WARNING, but no message with severity level ERROR or CRITICAL.
In other cases, no message or only messages with severity level INFO or NOTICE, the outcome of this Test Case is "pass".
Special procedural requirements
If either IPv4 or IPv6 transport is disabled, ignore the evaluation of the result of any test using this transport protocol. Log a message reporting on the ignored result.
See the DNSSEC README document about DNSSEC algorithms.
This test case is always performed.
Intercase dependencies
None.
Terminology
No special terminology for this test case.
DNSSEC12: Test for DNSSEC Algorithm Completeness
Test case identifier
DNSSEC12 Test for DNSSEC Algorithm Completeness
Objective
The objectives for this Test Case has yet to be defined. This is a placeholder for a complete definition of the Test Case. The Test Case is not yet implemented.
Test for DNSSEC Algorithm Completeness (DS->DNSKEY->RRSIG)
See issues #588, #528, #529 and #231.
Inputs
TBD.
Ordered description of steps to be taken to execute the test case
TBD.
Outcome(s)
TBD.
Special procedural requirements
TBD.
Intercase dependencies
TBD.
DNSSEC13: All DNSKEY algorithms used to sign the zone
Test case identifier
DNSSEC13
Table of contents
- Objective
- Scope
- Inputs
- Summary
- Test procedure
- Outcome(s)
- Special procedural requirements
- Intercase dependencies
- Terminology
Objective
From RFC 6840, section 5.11:
The DS RRset and DNSKEY RRset are used to signal which algorithms are used to sign a zone. [...] The zone MUST also be signed with each algorithm (though not each key) present in the DNSKEY RRset. [...]
To verify that the whole zone is signed with all algorithms require access to the complete zone, which is generally not possible for public zones. This test case is limited to three RRsets that must be present in a signed zone, the SOA RRset, the NS RRset and the DNSKEY RRset.
This test case will verify that for each DNSKEY algorithm, there is a RRSIG of that algorithm for the three selected RRsets.
Scope
It is assumed that Child Zone is also tested by Connectivity01, DNSSEC08 and DNSSEC09. Issues covered by Connectivity01 (basic name server issues), DNSSEC08 (signing of DNSKEY RRset) and DNSSEC09 (signing of SOA RRset) will not result in messages from this test case.
Inputs
- "Child Zone" - The domain name to be tested.
Summary
- If the name server reports no DNSKEY RRset, then this test case will not test or report anything.
- This test case will not report anything unless there is an issue to report.
Message Tag outputted | Level | Arguments | Description of when message tag is outputted |
---|---|---|---|
DS13_ALGO_NOT_SIGNED_DNSKEY | WARNING | ns_ip_list, algo_mnemo, algo_num | The DNSKEY RRset is not signed with an algorithm present in the DNSKEY RRset |
DS13_ALGO_NOT_SIGNED_NS | WARNING | ns_ip_list, algo_mnemo, algo_num | The NS RRset is not signed with an algorithm present in the DNSKEY RRset |
DS13_ALGO_NOT_SIGNED_SOA | WARNING | ns_ip_list, algo_mnemo, algo_num | The SOA RRset is not signed with an algorithm present in the DNSKEY RRset |
The value in the Level column is the default severity level of the message. The severity level can be changed in the Zonemaster-Engine profile. Also see the Severity Level Definitions document.
The argument names in the Arguments column lists the arguments used in the message. The argument names are defined in the argument list.
Test procedure
-
Create a DNSKEY query with DO flag set for the apex of the Child Zone ("DNSKEY Query").
-
Create a SOA query with DO flag set for the apex of the Child Zone ("SOA Query").
-
Create a NS query with DO flag set for the apex of the Child Zone ("NS Query").
-
Retrieve all name server IP addresses for the Child Zone using Method4 and Method5 ("NS IP").
-
Create the following empty sets:
- Name server IP address and associated DNSKEY algorithm ("Algo not signed DNSKEY").
- Name server IP address and associated DNSKEY algorithm ("Algo not signed SOA").
- Name server IP address and associated DNSKEY algorithm ("Algo not signed NS").
-
For each name server IP in the NS IP set do:
-
Create an empty set of DNSKEY algorithms ("DNSKEY Algorithm").
-
Send DNSKEY Query over UDP and do:
- Go to next name server IP if any of the following criteria is met:
- No DNS response is returned.
- The RCODE value of the DNS response is not "NoError" (IANA RCODE List).
- The AA flag of the response is unset.
- The DNS response contains no DNSKEY record in the answer section.
- The DNS response contains no RRSIG for the DNSKEY RRset.
- Extract all DNSKEY records from the answer section.
- Extract the algorithm numbers from each DNSKEY record and add them to the DNSKEY Algorithm set.
- Extract all RRSIG records for the DNSKEY RRset from the response.
- For each algorithm in DNSKEY Algorithm do:
- If there is no RRSIG for the DNSKEY RRset created by the algorithm then add name server IP and DNSKEY algorithm to the Algo not signed DNSKEY set.
- Go to next name server IP if any of the following criteria is met:
-
Send SOA Query over UDP and do:
- Go to next name server IP if any of the following criteria is met:
- No DNS response is returned.
- The RCODE value of the DNS response is not "NoError" (IANA RCODE List).
- The AA flag of the response is unset.
- The DNS response contains no SOA record in the answer section.
- The DNS response contains no RRSIG for the SOA RRset.
- Extract the SOA record from the answer section (ignore additional SOA records, if any).
- Extract all RRSIG records for the SOA RRset from the response.
- For each algorithm in DNSKEY Algorithm do:
- If there is no RRSIG for the SOA RRset created by the algorithm then add name server IP and DNSKEY algorithm to the Algo not signed SOA set.
- Go to next name server IP if any of the following criteria is met:
-
Send NS Query over UDP.
- Go to next name server IP if any of the following criteria is met:
- No DNS response is returned.
- The RCODE value of the DNS response is not "NoError" (IANA RCODE List).
- The AA flag of the response is unset.
- The DNS response contains no NS record in the answer section.
- The DNS response contains no RRSIG for the NS RRset.
- Extract all NS records from the answer section.
- Extract all RRSIG records for the NS RRset from the response.
- For each algorithm in DNSKEY Algorithm do:
- If there is no RRSIG for the NS RRset created by the algorithm then add name server IP and DNSKEY algorithm to the Algo not signed NS set.
- Go to next name server IP if any of the following criteria is met:
-
-
If the Algo not signed DNSKEY set is non-empty, then for each DNSKEY algorithm in the set output DS13_ALGO_NOT_SIGNED_DNSKEY with the name server IP addresses from the set and the DNSKEY algorithm.
-
If the Algo not signed SOA set is non-empty, then for each DNSKEY algorithm in the set output DS13_ALGO_NOT_SIGNED_SOA with the name server IP addresses from the set and the SOA algorithm.
-
If the Algo not signed NS set is non-empty, then for each DNSKEY algorithm in the set output DS13_ALGO_NOT_SIGNED_NS with the name server IP addresses from the set and the NS algorithm.
Outcome(s)
The outcome of this Test Case is "fail" if there is at least one message with the severity level ERROR or CRITICAL.
The outcome of this Test Case is "warning" if there is at least one message with the severity level WARNING, but no message with severity level ERROR or CRITICAL.
In other cases, no message or only messages with severity level INFO or NOTICE, the outcome of this Test Case is "pass".
Special procedural requirements
If either IPv4 or IPv6 transport is disabled, ignore the evaluation of the result of any test using this transport protocol. Log a message reporting on the ignored result.
See the DNSSEC README document about DNSSEC algorithms.
Test case is only performed if DNSKEY records are found.
Intercase dependencies
None.
Terminology
No special terminology for this test case.
DNSSEC14: Check for valid RSA DNSKEY key size
Test case identifier
DNSSEC14
Objective
The DNSKEYs based on RSA have different minimum and maximum key sizes, which must be followed. This test case will validate the keys size of such keys. RSA based algorithms that are deprecated or else not suitable for DNSKEY (RFC 8624 and IANA registry) are just ignored. See test case DNSSEC05 for test of algorithm.
The table 1 below specify the maximum and minimum key size, respectively. Algorithm number can be found in IANA registry.
Table 1: Minimum and maximum RSA key sizes in bits
Algorithm | Min size | Max size | Reference |
---|---|---|---|
5 | 512 | 4096 | RFC 3110 |
7 | 512 | 4096 | RFC 5155 |
8 | 512 | 4096 | RFC 5702 |
10 | 1024 | 4096 | RFC 5702 |
It is also recommended that an RSA based algorithm has a key length of at least 2048 bit as stated in NIST SP 800-57 Part 1 Rev. 4, table 2 on page 53 in section 5.6.1 and table 4 on page 55 in section 5.6.2.
This test case verifies that RSA DNSKEYs follows the stated key lengths from the RFCs and also the NIST recommended shortest key length.
Scope
It is assumed that Child Zone is also tested by Connectivity01. This test case will set DEBUG level on messages for non-responsive name servers.
Inputs
- "Child Zone" - The domain name to be tested.
- "Key Size Table" - The table above.
Ordered description of steps to be taken to execute the test case
-
Create a DNSKEY query with DO flag set for the apex of the Child Zone.
-
Retrieve all name server IP addresses for the Child Zone using Method4 and Method5 ("NS IP").
-
Create an empty set "DNSKEY RRs".
-
For each name server IP address in NS IP do:
- Send the DNSKEY query over UDP.
- If no DNS response is returned, then output NO_RESPONSE.
- Else, if the DNS response does not contain an DNSKEY RRset, then output NO_RESPONSE_DNSKEY.
- Else, retrieve the DNSKEY RRs and add them to DNSKEY RRs.
-
For each DNSKEY from the DNSKEY RRs do:
- If the algorithm of the DNSKEY is not listed in Key Size Table, go to next DNSKEY.
- Else, if the algorithm is listed in Key Size Table and the key size is smaller than specified, then output DNSKEY_TOO_SMALL_FOR_ALGO.
- Else, if the algorithm is listed in Key Size Table and the key size is smaller than 2048 bits, then output DNSKEY_SMALLER_THAN_REC.
- Else, if the algorithm is listed in Key Size Table and the key size is larger than specified, then output DNSKEY_TOO_LARGE_FOR_ALGO.
-
If DNSKEY RRs is non-empty and no messages, except for any NO_RESPONSE, has been outputted, then output KEY_SIZE_OK.
Outcome(s)
The outcome of this Test Case is "fail" if there is at least one message with the severity level ERROR or CRITICAL.
The outcome of this Test Case is "warning" if there is at least one message with the severity level WARNING, but no message with severity level ERROR or CRITICAL.
In other cases the outcome of this Test Case is "pass".
Message | Default severity level |
---|---|
NO_RESPONSE | DEBUG |
NO_RESPONSE_DNSKEY | WARNING |
DNSKEY_SMALLER_THAN_REC | WARNING |
DNSKEY_TOO_SMALL_FOR_ALGO | ERROR |
DNSKEY_TOO_LARGE_FOR_ALGO | ERROR |
KEY_SIZE_OK | INFO |
Special procedural requirements
If either IPv4 or IPv6 transport is disabled, ignore the evaluation of the result of any test using this transport protocol. Log a message reporting on the ignored result.
See the DNSSEC README document about DNSSEC algorithms.
The test case is only performed if some DNSKEY record is found in the Child Zone.
Intercase dependencies
None.
DNSSEC15: Existence of CDS and CDNSKEY
Test case identifier
DNSSEC15
Objective
CDS and CDNSKEY record types are defined in RFC 7344 and RFC 8078. Both record types are optional in a zone. The objective of this test case is to verify that they are correctly set-up, if included in the zone.
If a CDS record is included in the zone, the corresponding CDNSKEY record should also be included (RFC 7344, section 4).
The CDS and CDNSKEY RRsets should be consistent between all name servers for the zone in question.
If there are both CDS RRs and CDNSKEY RRs in the zone they must match in content (RFC 7344, section 4). It means that both must be derived from the same DNSKEY or both being "delete" CDS and CDNSKEY.
Scope
It is assumed that Child Zone is also tested by Connectivity01. This test case will just ignore non-responsive name servers or name servers not giving a correct DNS response for an authoritative name server.
Inputs
- "Child Zone" - The domain name to be tested.
Summary
Message Tag outputted | Default level | Description of when message tag is outputted |
---|---|---|
DS15_HAS_CDNSKEY_NO_CDS | NOTICE | CDNSKEY RRset is found, but no CDS RRset. |
DS15_HAS_CDS_AND_CDNSKEY | INFO | CDNSKEY and CDS RRsets are found. |
DS15_HAS_CDS_NO_CDNSKEY | NOTICE | CDS RRset is found, but no CDNSKEY RRset. |
DS15_INCONSISTENT_CDNSKEY | ERROR | All servers do not have the same CDNSKEY RRset. |
DS15_INCONSISTENT_CDS | ERROR | All servers do not have the same CDS RRset. |
DS15_MISMATCH_CDS_CDNSKEY | ERROR | Both CDS and CDNSKEY RRsets are found but they do not match. |
DS15_NO_CDS_CDNSKEY | INFO | No CDS or CDNSKEY RRsets are found on any name server. |
Ordered description of steps to be taken to execute the test case
-
Create the following empty sets:
- Name server IP address and associated CDS RRset ("CDS RRsets"). A name server IP can hold an empty RRset.
- Name server IP address and associated CDNSKEY RRset ("CDNSKEY RRsets"). A name server IP can hold an empty RRset.
- Name server IP address set ("Mismatch CDS/CDNSKEY").
- Name server IP address set ("Has CDS No CDNSKEY").
- Name server IP address set ("Has CDNSKEY No CDS").
- Name server IP address set ("Has CDS And CDNSKEY").
-
Retrieve all name server IP addresses for the Child Zone using Method4 and Method5 ("NS IP").
-
Create a CDS query with EDNS enabled with the DO bit set for the apex of the Child Zone.
-
Create a CDNSKEY query with EDNS enabled with the DO bit set for the apex of the Child Zone.
-
For each name server IP in the NS IP set do:
- Send the CDS query over UDP to the name server IP address.
- If no DNS response is returned, then go to next name server IP.
- Else, if AA bit is not set in the DNS response, then go to next name server IP.
- Else, if the RCODE in the DNS response is not NOERROR, then go to next name server IP.
- Else, if the DNS response contains no CDS record in the answer section, then add the name server IP and an empty RRset to the CDS RRsets set.
- Else, add the name server IP and the CDS RRset from the answer section to the CDS RRsets set.
- Send the CDNSKEY query over UDP to the name server IP address.
- If no DNS response is returned, then go to next name server IP.
- Else, if AA bit is not set in the DNS response, then go to next name server IP.
- Else, if the RCODE in the DNS response is not NOERROR, then go to next name server IP.
- Else, if the DNS response contains no CDNSKEY record in the answer section, then add the name server IP and an empty RRset to the CDNSKEY RRsets set.
- Else, add the name server IP and the CDNSKEY RRset from the answer section to the CDNSKEY RRsets set.
- Go to next name server IP.
- Send the CDS query over UDP to the name server IP address.
-
If the CDS RRsets set and the CDNSKEY RRsets set are empty then output DS15_NO_CDS_CDNSKEY and terminate this test case.
-
For each name server IP in the CDS RRsets set do:
- If the name server IP is not listed in CDNSKEY RRsets, go to next name server IP.
- If the name server IP address has a non-empty RRset in the CDS RRsets set, but an empty RRset in the CDNSKEY RRsets set, then add the name server IP address to Has CDS No CDNSKEY.
- If the name server IP address has a non-empty RRset in the CDNSKEY RRsets set, but an empty RRset in the CDS RRsets set, then add the name server IP address to Has CDNSKEY No CDS.
- If the name server IP address has a non-empty RRset in both sets, CDNSKEY RRsets and CDS RRsets, then add the name server IP address to Has CDS And CDNSKEY.
- Go to next name server IP.
-
For each name server IP in the CDS RRsets set do:
- If the name server IP is not listed in CDNSKEY RRsets, go to next name server IP.
- Extract the CDS RRset (possibly empty) for the IP in the CDS RRsets set.
- Extract the CDNSKEY RRset (possibly empty) for the same IP from the CDNSKEY RRsets set.
- If both RRsets are non-empty then do:
- For each CDS RR verify that there is a matching CDNSKEY (derived from the same DNSKEY or both being "delete").
- For each CDNSKEY RR verify that there is a matching CDS (derived from the same DNSKEY or both being "delete").
- If one or both of the verifications fail then add the name server IP to the Mismatch CDS/CDNSKEY set.
- Go to next name sever IP.
-
If the Has CDS No CDNSKEY set is non-empty then output DS15_HAS_CDS_NO_CDNSKEY with the name server IP addresses from the set.
-
If the Has CDNSKEY No CDS set is non-empty then output DS15_HAS_CDNSKEY_NO_CDS with the name server IP addresses from the set.
-
If the Has CDS And CDNSKEY set is non-empty then output DS15_HAS_CDS_AND_CDNSKEY with the name server IP addresses from the set.
-
If not all CDS RRsets in the CDS RRsets set are identical, where a non-empty RRset is considered to be different from an empty RRset, then output DS15_INCONSISTENT_CDS.
-
If not all CDNSKEY RRsets in the CDNSKEY RRsets set are identical, where a non-empty RRset is considered to be different from an empty RRset, then output DS15_INCONSISTENT_CDNSKEY.
-
If the Mismatch CDS/CDNSKEY set is non-empty, then output DS15_MISMATCH_CDS_CDNSKEY and list the name server IPs from the set.
Outcome(s)
The outcome of this Test Case is "fail" if there is at least one message with the severity level ERROR or CRITICAL.
The outcome of this Test Case is "warning" if there is at least one message with the severity level WARNING, but no message with severity level ERROR or CRITICAL.
In other cases, no message or only messages with severity level INFO or NOTICE, the outcome of this Test Case is "pass".
Special procedural requirements
If either IPv4 or IPv6 transport is disabled, ignore the evaluation of the result of any test using this transport protocol. Log a message reporting the ignored protocol.
Intercase dependencies
None.
DNSSEC16: Validate CDS
Test case identifier
DNSSEC16
Objective
CDS and CDNSKEY record types are defined in RFC 7344 and RFC 8078. Both record types are optional in a zone. The objective of this test case is to verify that the CDS RRset is valid. This test case is only relevant if the zone has at least one CDS record. For tests of the CDNSKEY, see test case DNSSEC17.
Scope
It is assumed that Child Zone is also tested by Connectivity01. This test case will just ignore non-responsive name servers or name servers not giving a correct DNS response for an authoritative name server.
It is assumed that Child Zone has been tested or will be tested by DNSSEC15 and DNSSEC17 and that the servers give the same responses. Running this test case without running DNSSEC15 and DNSSEC17 can give an incomplete report of the CDS and CDNSKEY status of Child Zone.
Inputs
- "Child Zone" - The domain name to be tested.
Summary
- If no CDS record is found, the test case will terminate early with no message tag outputted.
- If a CDS record is of "delete" type, then it can by definition not match or point at any DNSKEY record.
Message Tag outputted | Default level | Description of when message tag is outputted |
---|---|---|
DS16_CDS_INVALID_RRSIG | ERROR | CDS RRset is signed with an invalid RRSIG. |
DS16_CDS_MATCHES_NON_SEP_DNSKEY | NOTICE | CDS record matches a DNSKEY with SEP bit (bit 15) unset. |
DS16_CDS_MATCHES_NON_ZONE_DNSKEY | ERROR | CDS record matches a DNSKEY with zone bit (bit 7) unset. |
DS16_CDS_MATCHES_NO_DNSKEY | WARNING | CDS record does not match any DNSKEY in DNSKEY RRset. |
DS16_CDS_NOT_SIGNED_BY_CDS | NOTICE | CDS RRset is not signed by the key that the CDS record points to. |
DS16_CDS_SIGNED_BY_UNKNOWN_DNSKEY | ERROR | CDS RRset is signed by a key not in DNSKEY RRset. |
DS16_CDS_UNSIGNED | ERROR | CDS RRset is unsigned. |
DS16_CDS_WITHOUT_DNSKEY | ERROR | CDS RRset exists, but there is no DNSKEY RRset. |
DS16_DELETE_CDS | INFO | CDS RRset has a "delete" CDS record as a single record. |
DS16_DNSKEY_NOT_SIGNED_BY_CDS | WARNING | DNSKEY RRset is not signed by the key or keys that the CDS records point to. |
DS16_MIXED_DELETE_CDS | ERROR | "Delete" CDS record is mixed with normal CDS record. |
Ordered description of steps to be taken to execute the test case
-
Create the following empty sets:
- Name server IP address and associated CDS RRset and its RRSIG records ("CDS RRsets"). The set of RRSIG records may be empty.
- Name server IP address and associated DNSKEY RRset and its RRSIG records ("DNSKEY RRsets"). The set of RRSIG records may be empty.
- Name server IP address ("No DNSKEY RRset").
- Name server IP address ("Mixed Delete CDS").
- Name server IP address ("Delete CDS").
- Name server IP address and associated CDS key tag ("No Match CDS With DNSKEY").
- Name server IP address and associated CDS key tag ("CDS points to non-zone DNSKEY").
- Name server IP address and associated CDS key tag ("CDS points to non-SEP DNSKEY").
- Name server IP address and associated CDS key tag ("DNSKEY Not Signed By CDS").
- Name server IP address and associated CDS key tag ("CDS Not Signed By CDS").
- Name server IP address ("CDS Not Signed").
- Name server IP address and key tag ("CDS Signed By Unknown DNSKEY").
- Name server IP address and key tag ("CDS Invalid RRSIG").
-
Create a CDS query with EDNS enabled and the DO bit set for the apex of the Child Zone.
-
Create a DNSKEY query with EDNS enabled and the DO bit set for the apex of the Child Zone.
-
Retrieve all name server IP addresses for the Child Zone using Method4 and Method5 ("NS IP").
-
Repeat the following steps for each name server IP address in NS IP:
- Send the CDS query over UDP to the name server IP address.
- If no DNS response is returned, then go to next name server IP.
- Else, if AA bit is not set in the DNS response, then go to next name server IP.
- Else, if the RCODE in the DNS response is not NOERROR, then go to next name server IP.
- Else, if the answer section has no CDS records, go to next name server IP.
- Add the name server IP and the CDS RRset from the answer section to the CDS RRsets set. Also include any associated RRSIG records in the answer section.
- Send the DNSKEY query over UDP to the name server IP address.
- If no DNS response is returned, then go to next name server IP.
- Else, if AA bit is not set in the DNS response, then go to next name server IP.
- Else, if the RCODE in the DNS response is not NOERROR, then go to next name server IP.
- Else, if the DNS response contains at least one DNSKEY record in the answer section, then add the name server IP and the DNSKEY RRset from the answer section to the DNSKEY RRsets set. Also include any associated RRSIG records in the answer section.
- Go to next name server IP.
- Send the CDS query over UDP to the name server IP address.
-
If the CDS RRsets set is empty then terminate this test case.
-
For each name server IP in the CDS RRsets set do:
- If the CDS RRset is empty go to next name server IP address.
- Get the CDS RRset and the associated RRSIG records, if any, from the CDS RRsets set for the name server IP.
- If any CDS record is a "delete" CDS, then do:
- If there is more than a single CDS record then add the name server IP to the Mixed Delete CDS set.
- Else, add the name server IP address to the Delete CDS set.
- Get the DNSKEY RRset and the associated RRSIG records, if any, from the DNSKEY RRsets for the same name server IP.
- If there are no DNSKEY records, then do:
- Add name server IP address to the No DNSKEY RRset set.
- Go to next name server IP.
- Repeat the following steps for each CDS record unless it is a "delete"
CDS record:
- Compare the key tag from the CDS record with the calculated key tags for the DNSKEY records.
- If the CDS record does not match any DNSKEY record then add the name server IP address and CDS record key tag to the No Match CDS With DNSKEY set.
- Else, if bit 7 of the flags field of the DNSKEY that the DS record points to is unset (value 0) then add the name server IP address and CDS record key tag to the CDS points to non-zone DNSKEY set.
- Else, do:
- If the DNSKEY RRset has not been signed by the DNSKEY record that the CDS record points at then add the name server IP address and key tag of CDS record to the DNSKEY Not Signed By CDS set.
- If the CDS RRset has not been signed by the DNSKEY record that the CDS record points at then add the name server IP address and key tag of CDS record to the CDS Not Signed By CDS set.
- If bit 15 of the flags field of the DNSKEY that the CDS record points at is unset (value 0) then add the name server IP address and the key tag of the CDS record to the CDS points to non-SEP DNSKEY set.
- If CDS RRset is not signed, then add the name server IP address to the CDS Not Signed set.
- Else, for each RRSIG for the CDS RRset do:
- If the key tag of the RRSIG does not match any DNSKEY record in the DNSKEY RRset then add the name server IP address and key tag to the CDS Signed By Unknown DNSKEY set.
- Else, if the RRSIG cannot be validated by the DNSKEY it refers to by key tag, then add the name server IP and RRSIG key tag to the CDS Invalid RRSIG set.
- Go to next name server IP address.
-
If the No DNSKEY RRset set is non-empty, then output DS16_CDS_WITHOUT_DNSKEY with all name server IP addresses in the set.
-
If the Mixed Delete CDS set is non-empty, then output DS16_MIXED_DELETE_CDS with all name server IP addresses in the set.
-
If the Delete CDS set is non-empty, then output DS16_DELETE_CDS with all name server IP addresses.
-
If the No Match CDS With DNSKEY set is non-empty then do:
- For each CDS key tag in the set do:
- Output DS16_CDS_MATCHES_NO_DNSKEY with the CDS key tag and the name server IP addresses in the set for that key tag.
- For each CDS key tag in the set do:
-
If the CDS points to non-zone DNSKEY set is non-empty then do:
- For each CDS key tag in the set do:
- Output DS16_CDS_MATCHES_NON_ZONE_DNSKEY with the CDS key tag and the name server IP addresses in the set for that key tag.
- For each CDS key tag in the set do:
-
If the CDS points to non-SEP DNSKEY set is non-empty then do:
- For each CDS key tag in the set do:
- Output DS16_CDS_MATCHES_NON_SEP_DNSKEY with the CDS key tag and the name server IP addresses in the set for that key tag.
- For each CDS key tag in the set do:
-
If the DNSKEY Not Signed By CDS set is non-empty then do:
- For each CDS key tag in the set do:
- Output DS16_DNSKEY_NOT_SIGNED_BY_CDS with the CDS key tag and the name server IP addresses in the set for that key tag.
- For each CDS key tag in the set do:
-
If the CDS Not Signed By CDS set is non-empty then do:
- For each CDS key tag in the set do:
- Output DS16_CDS_NOT_SIGNED_BY_CDS with the CDS key tag and the name server IP addresses in the set for that key tag.
- For each CDS key tag in the set do:
-
If the CDS Invalid RRSIG set is non-empty then do:
- For each RRSIG key tag in the set do:
- Output DS16_CDS_INVALID_RRSIG with the RRSIG key tag and the name server IP addresses in the set for that key tag.
- For each RRSIG key tag in the set do:
-
If the CDS Not Signed set is non-empty then output DS16_CDS_UNSIGNED with all name server IP addresses in the set.
-
If the CDS Signed By Unknown DNSKEY set is non-empty then output DS16_CDS_SIGNED_BY_UNKNOWN_DNSKEY with the name server IP addresses in the set.
Outcome(s)
The outcome of this Test Case is "fail" if there is at least one message with the severity level ERROR or CRITICAL.
The outcome of this Test Case is "warning" if there is at least one message with the severity level WARNING, but no message with severity level ERROR or CRITICAL.
In other cases, no message or only messages with severity level INFO or NOTICE, the outcome of this Test Case is "pass".
Special procedural requirements
If either IPv4 or IPv6 transport is disabled, ignore the evaluation of the result of any test using this transport protocol. Log a message reporting the ignored protocol.
Intercase dependencies
None.
DNSSEC17: Validate CDNSKEY
Test case identifier
DNSSEC17
Objective
CDS and CDNSKEY record types are defined in RFC 7344 and RFC 8078. Both record types are optional in a zone. The objective of this test case is to verify that the CDNSKEY RRset is valid. This test case is only relevant if the zone has at least one CDNSKEY record. For tests of the CDS, see test case DNSSEC16.
Scope
It is assumed that Child Zone is also tested by Connectivity01. This test case will just ignore non-responsive name servers or name servers not giving a correct DNS response for an authoritative name server.
It is assumed that Child Zone has been tested or will be tested by DNSSEC15 and DNSSEC16 and that the servers give the same responses. Running this test case without running DNSSEC15 and DNSSEC16 can give an incomplete report of the CDS and CDNSKEY status of Child Zone.
Inputs
- "Child Zone" - The domain name to be tested.
Summary
- If no CDNSKEY record is found, the test case will terminate early with no message tag outputted.
- If a CDNSKEY record is of "delete" type, then it can by definition not match or point at any DNSKEY record.
Message Tag outputted | Default level | Description of when message tag is outputted |
---|---|---|
DS17_CDNSKEY_INVALID_RRSIG | ERROR | CDNSKEY RRset signed with an invalid RRSIG. |
DS17_CDNSKEY_IS_NON_SEP | NOTICE | CDNSKEY record has the SEP bit (bit 15) unset. |
DS17_CDNSKEY_IS_NON_ZONE | ERROR | CDNSKEY record has the zone bit (bit 7) unset. |
DS17_CDNSKEY_MATCHES_NO_DNSKEY | WARNING | CDNSKEY record does not match any DNSKEY in DNSKEY RRset. |
DS17_CDNSKEY_NOT_SIGNED_BY_CDNSKEY | NOTICE | CDNSKEY RRset is not signed by the key that the CDNSKEY record points to. |
DS17_CDNSKEY_SIGNED_BY_UNKNOWN_DNSKEY | ERROR | CDNSKEY RRset is signed by a key not in DNSKEY RRset. |
DS17_CDNSKEY_UNSIGNED | ERROR | CDNSKEY RRset is unsigned. |
DS17_CDNSKEY_WITHOUT_DNSKEY | ERROR | CDNSKEY RRset exists, but there is no DNSKEY RRset. |
DS17_DELETE_CDNSKEY | INFO | CDNSKEY RRset has a "delete" CDNSKEY record as a single record. |
DS17_DNSKEY_NOT_SIGNED_BY_CDNSKEY | WARNING | DNSKEY RRset is not signed by the key or keys that the CDNSKEY records point to. |
DS17_MIXED_DELETE_CDNSKEY | ERROR | "Delete" CDNSKEY record is mixed with normal CDNSKEY record. |
Ordered description of steps to be taken to execute the test case
-
Create the following empty sets:
- Name server IP address and associated CDNSKEY RRset and its RRSIG records ("CDNSKEY RRsets"). The set of RRSIG records may be empty
- Name server IP address and associated DNSKEY RRset and its RRSIG records ("DNSKEY RRsets"). The set of RRSIG records may be empty.
- Name server IP address ("No DNSKEY RRset").
- Name server IP address ("Mixed Delete CDNSKEY").
- Name server IP address ("Delete CDNSKEY").
- Name server IP address and associated CDNSKEY key tag ("No Match CDNSKEY With DNSKEY").
- Name server IP address and associated CDNSKEY key tag ("CDNSKEY is non-zone key").
- Name server IP address and associated CDNSKEY key tag ("CDNSKEY is non-SEP key").
- Name server IP address and key tag ("DNSKEY Not Signed By CDNSKEY").
- Name server IP address and key tag ("CDNSKEY Not Signed By CDNSKEY").
- Name server IP address ("CDNSKEY Not Signed").
- Name server IP address and key tag ("CDNSKEY Signed By Unknown DNSKEY").
- Name server IP address and key tag ("CDNSKEY Invalid RRSIG").
-
Create a CDNSKEY query with EDNS enabled and the DO bit set for the apex of the Child Zone.
-
Create a DNSKEY query with EDNS enabled and the DO bit set for the apex of the Child Zone.
-
Retrieve all name server IP addresses for the Child Zone using Method4 and Method5 ("NS IP").
-
Repeat the following steps for each name server IP address in NS IP:
- Send the CDNSKEY query over UDP to the name server IP address.
- If no DNS response is returned, then go to next name server IP.
- Else, if AA bit is not set in the DNS response, then go to next name server IP.
- Else, if the RCODE in the DNS response is not NOERROR, then go to next name server IP.
- Else, if the answer section has no CDNSKEY records, go to next name server IP.
- Add the name server IP and the CDNSKEY RRset from the answer section to the CDNSKEY RRsets set. Also include any associated RRSIG records in the answer section.
- Send the DNSKEY query over UDP to the name server IP address.
- If no DNS response is returned, then go to next name server IP.
- Else, if AA bit is not set in the DNS response, then go to next name server IP.
- Else, if the RCODE in the DNS response is not NOERROR, then go to next name server IP.
- Else, if the DNS response contains at least one DNSKEY record in the answer section, then add the name server IP and the DNSKEY RRset from the answer section to the DNSKEY RRsets set. Also include any associated RRSIG records in the answer section.
- Go to next name server IP.
- Send the CDNSKEY query over UDP to the name server IP address.
-
If the CDNSKEY RRsets set is empty then terminate this test case.
-
For each name server IP in the CDNSKEY RRsets set do:
-
If the CDNSKEY RRset is empty go to next name server IP address.
-
Get the CDNSKEY RRset and the associated RRSIG records, if any, from the CDNSKEY RRsets set for the name server IP.
-
If any CDNSKEY record is a "delete" CDNSKEY, then do:
- If there is more than a single CDNSKEY record then add the name server IP to the Mixed Delete CDNSKEY set.
- Else, add the name server IP address to the Delete CDNSKEY set.
-
Get the DNSKEY RRset and the associated RRSIG records, if any, from the DNSKEY RRsets for the same name server IP.
-
If there are no DNSKEY records, then do:
- Add name server IP address to the No DNSKEY RRset set (duplicates not possible).
- Go to next name server IP.
-
Repeat the following steps for each CDNSKEY record unless it is a "delete" CDNSKEY record:
- If bit 7 of the flags field of the CDNSKEY record is unset (value 0) then add the name server IP address and the key tag calculated from the CDNSKEY record to the CDNSKEY is non-zone key set.
- Else, do:
- If bit 15 of the flags field of the CDNSKEY is unset (value 0) then add the name server IP address and the key tag calculated from the CDNSKEY to the CDNSKEY is non-SEP key set.
- Compare the CDNSKEY record with the DNSKEY records.
- If the CDNSKEY record does not match any DNSKEY record then add the name server IP address and the key tag calculated from the CDNSKEY record to the No Match CDNSKEY With DNSKEY set.
- Else, do:
- If the DNSKEY RRset is not signed by the DNSKEY record that corresponds to the CDNSKEY record then add the name server IP address and key tag calculated from CDNSKEY record to the DNSKEY Not Signed By CDNSKEY set.
- If the CDNSKEY RRset is not signed by the DNSKEY record that corresponds to the CDNSKEY record then add the name server IP address and key tag calculated from CDNSKEY record to the CDNSKEY Not Signed By CDNSKEY set.
-
If the CDNSKEY RRset is not signed, then add the name server IP address to the CDNSKEY Not Signed set.
-
Else, for each RRSIG for the CDNSKEY RRset do:
- If the key tag of the RRSIG does not match any DNSKEY record in the DNSKEY RRset then add the name server IP address and key tag to the CDNSKEY Signed By Unknown DNSKEY set.
- Else, if the RRSIG cannot be validated by the DNSKEY it refers to by key tag, then add the name server IP and RRSIG key tag to the CDNSKEY Invalid RRSIG set.
-
Go to next name server IP address.
-
-
If the No DNSKEY RRset set is non-empty, then output DS17_CDNSKEY_WITHOUT_DNSKEY with all name server IP addresses in the set.
-
If the Mixed Delete CDNSKEY set is non-empty, then output DS17_MIXED_DELETE_CDNSKEY with all name server IP addresses in the set.
-
If the Delete CDNSKEY set is non-empty then output DS17_DELETE_CDNSKEY with all name server IP addresses.
-
If the No Match CDNSKEY With DNSKEY set is non-empty then do:
- For each CDNSKEY key tag in the set do:
- Output DS17_CDNSKEY_MATCHES_NO_DNSKEY with the CDNSKEY key tag and the name server IP addresses in the set for that key tag.
- For each CDNSKEY key tag in the set do:
-
If the CDNSKEY is non-zone key set is non-empty then do:
- For each CDNSKEY key tag in the set do:
- Output DS17_CDNSKEY_IS_NON_ZONE with the CDNSKEY key tag and the name server IP addresses in the set for that key tag.
- For each CDNSKEY key tag in the set do:
-
If the CDNSKEY is non-SEP key set is non-empty then do:
- For each CDNSKEY key tag in the set do:
- Output DS17_CDNSKEY_IS_NON_SEP with the CDNSKEY key tag and the name server IP addresses in the set for that key tag.
- For each CDNSKEY key tag in the set do:
-
If the DNSKEY Not Signed By CDNSKEY set is non-empty then do:
- For each CDNSKEY key tag in the set do:
- Output DS17_DNSKEY_NOT_SIGNED_BY_CDNSKEY with the CDNSKEY key tag and the name server IP addresses in the set for that key tag.
- For each CDNSKEY key tag in the set do:
-
If the CDNSKEY Not Signed By CDNSKEY set is non-empty then do:
- For each CDNSKEY key tag in the set do:
- Output DS17_CDNSKEY_NOT_SIGNED_BY_CDNSKEY with the CDNSKEY key tag and the name server IP addresses in the set for that key tag.
- For each CDNSKEY key tag in the set do:
-
If the CDNSKEY Invalid RRSIG set is non-empty then do:
- For each RRSIG key tag in the set do:
- Output DS17_CDNSKEY_INVALID_RRSIG with the RRSIG key tag and the name server IP addresses in the set for that key tag.
- For each RRSIG key tag in the set do:
-
If the CDNSKEY Not Signed set is non-empty then output DS17_CDNSKEY_UNSIGNED with all name server IP addresses in the set.
-
If the CDNSKEY Signed By Unknown DNSKEY set is non-empty then output DS17_CDNSKEY_SIGNED_BY_UNKNOWN_DNSKEY with the name server IP addresses in the set.
Outcome(s)
The outcome of this Test Case is "fail" if there is at least one message with the severity level ERROR or CRITICAL.
The outcome of this Test Case is "warning" if there is at least one message with the severity level WARNING, but no message with severity level ERROR or CRITICAL.
In other cases, no message or only messages with severity level INFO or NOTICE, the outcome of this Test Case is "pass".
Special procedural requirements
If either IPv4 or IPv6 transport is disabled, ignore the evaluation of the result of any test using this transport protocol. Log a message reporting the ignored protocol.
Intercase dependencies
None.
DNSSEC18: Validate trust from DS to CDS and CDNSKEY
Test case identifier
DNSSEC18
Objective
CDS and CDNSKEY record types are defined in RFC 7344 and RFC 8078. Both record types are optional in a zone. The objective of this test case is to verify that there is a correct chain of trust from DS, in the parent zone to the CDS and CDNSKEY RRsets (RFC 7344, section 4.1).
As stated in RFC 4035, section 2.4:
A DS RR SHOULD point to a DNSKEY RR that is present in the child's apex DNSKEY RRset, and the child's apex DNSKEY RRset SHOULD be signed by the corresponding private key."
This Test case is only relevant if
- The Child Zone has either CDS or CDNSKEY record or both, and
- The parent zone has a DS RRset for the Child Zone.
Scope
It is assumed that Child Zone is also tested by Connectivity01. This test case will just ignore non-responsive name servers or name servers not giving a correct DNS response for an authoritative name server.
It is assumed that Child Zone has been tested or will be tested by DNSSEC15, DNSSEC16 and DNSSEC17 and that the servers give the same responses. Running this test case without running DNSSEC15, DNSSEC16 and DNSSEC17 can give an incomplete report of the CDS and CDNSKEY status of Child Zone.
Summary
- If no CDS or CDNSKEY records are found, this test case is not run and no message will be outputted.
- If no DS records are found at parent, this test case is not run and no message will be outputted.
Message Tag outputted | Default level | Description of when message tag is outputted |
---|---|---|
DS18_NO_MATCH_CDS_RRSIG_DS | ERROR | The CDS RRset is not signed with a DNSKEY record that a DS record points to. |
DS18_NO_MATCH_CDNSKEY_RRSIG_DS | ERROR | CDNSKEY RRset is not signed with a DNSKEY record that a DS record points to. |
Inputs
- "Child Zone" - The domain name to be tested.
- "Test Type" - The test type with value "undelegated" or "normal".
- "Undelegated DS" - The DS record or records submitted (only if Test Type is undelegated).
Ordered description of steps to be taken to execute the test case
-
Create a CDS query with EDNS enabled and the DO bit set for the apex of the Child Zone.
-
Create a CDNSKEY query with EDNS enabled and the DO bit set for the apex of the Child Zone.
-
Create a DNSKEY query with EDNS enabled and the DO bit set for the apex of the Child Zone.
-
Create a DS query with EDNS enabled and DO flag set for the name of the Child Zone.
-
Create the following empty sets:
- Name server IP address and associated CDS RRset and its RRSIG records ("CDS RRsets"). A name server IP can hold an empty RRset or no RRSIG records.
- Name server IP address and associated CDNSKEY RRset and its RRSIG records ("CDNSKEY RRsets"). A name server IP can hold an empty RRset or no RRSIG records.
- Name server IP address and associated DNSKEY RRset ("DNSKEY RRsets"). A name server IP can hold an empty RRset.
- DS record set ("DS Records").
- Name server IP ("DS No Match CDS RRSIG").
- Name server IP ("DS No Match CDNSKEY RRSIG").
-
If the Test Type is "undelegated, then:
- Add Undelegated DS set to DS Records.
-
Else, do (Test Type is "normal"):
- Retrieve all name server IP addresses for the parent zone of Child Zone using Get-Parent-NS-IP ("Parent NS IP").
- For each IP address in Parent NS IP do:
- Send the DS query over UDP to the name server IP.
- If no DNS response is returned, then go to next name server IP.
- Else, if AA bit is not set in the DNS response, then go to next name server IP.
- Else, if the RCODE in the DNS response is not NOERROR, then go to next name server IP.
- Else, if the DNS response contains at least one DS record add all DS records to DS Records.
-
If DS Records is empty, terminate this test case.
-
Retrieve all name server IP addresses for the Child Zone using Method4 and Method5 ("NS IP").
-
Repeat the following steps for each name server IP address in NS IP:
- Send the CDS query over UDP to the name server IP address.
- If no DNS response is returned, then go to next name server IP.
- Else, if AA bit is not set in the DNS response, then go to next name server IP.
- Else, if the RCODE in the DNS response is not NOERROR, then go to next name server IP.
- Else, if the DNS response contains at least one CDS record in the answer section, then add the name server IP and the CDS RRset to the CDS RRsets set. Also include any associated RRSIG records.
- Send the CDNSKEY query over UDP to the name server IP address.
- If no DNS response is returned, then go to next name server IP.
- Else, if AA bit is not set in the DNS response, then go to next name server IP.
- Else, if the RCODE in the DNS response is not NOERROR, then go to next name server IP.
- Else, if the DNS response contains at least one CDNSKEY record in the answer section, then add the name server IP and the CDNSKEY RRset from the answer section to the CDNSKEY RRsets set. Also include any associated RRSIG records.
- Send the DNSKEY query over UDP to the name server IP address.
- If no DNS response is returned, then go to next name server IP.
- Else, if AA bit is not set in the DNS response, then go to next name server IP.
- Else, if the RCODE in the DNS response is not NOERROR, then go to next name server IP.
- Else, if the DNS response contains at least one DNSKEY record in the answer section, then add the name server IP and the DNSKEY RRset from the answer section to the DNSKEY RRsets set.
- Go to next name server IP.
- Send the CDS query over UDP to the name server IP address.
-
If both the CDS RRsets and CDNSKEY RRsets sets are empty, then terminate this test case.
-
If the DNSKEY RRsets is empty, then terminate this test case.
-
For each name server IP in the CDS RRsets set do:
- Extract the RRSIG records for the CDS RRset.
- Extract the DNSKEY from the DNSKEY RRsets for the same name server IP.
- For each DS record in DS Records do:
- If the DS record does not point to a DNSKEY record then go to next DS record.
- Else, if the DNSKEY that the DS record points to matches an RRSIG for CDS RRset then go to next name server IP address.
- Go to next DS records.
- Add name server IP to the DS No Match CDS RRSIG (i.e. there was no match between any DS record and an RRSIG record for the CDS RRset in the DS record loop above).
- Go to next name server IP address.
-
For each name server IP in the CDNSKEY RRsets set do:
- Extract the RRSIG records for the CDNSKEY RRset.
- Extract the DNSKEY from the DNSKEY RRsets for the same name server IP.
- For each DS record in DS Records do:
- If the DS record does not point to a DNSKEY record then go to next DS record.
- Else, if the DNSKEY that the DS record points to matches an RRSIG for CDNSKEY RRset then go to next name server IP address.
- Go to next DS records.
- Add name server IP to the DS No Match CDNSKEY RRSIG (i.e. there was no match between any DS record and an RRSIG record for the CDNSKEY RRset in the DS record loop above).
- Go to next name server IP address.
-
If the DS No Match CDS RRSIG set is non-empty then output DS18_NO_MATCH_CDS_RRSIG_DS with the name server IP addresses in the set.
-
If the DS No Match CDNSKEY RRSIG set is non-empty then output DS18_NO_MATCH_CDNSKEY_RRSIG_DS with the name server IP addresses in the set.
Outcome(s)
The outcome of this Test Case is "fail" if there is at least one message with the severity level ERROR or CRITICAL.
The outcome of this Test Case is "warning" if there is at least one message with the severity level WARNING, but no message with severity level ERROR or CRITICAL.
In other cases, no message or only messages with severity level INFO or NOTICE, the outcome of this Test Case is "pass".
Special procedural requirements
If either IPv4 or IPv6 transport is disabled, ignore the evaluation of the result of any test using this transport protocol. Log a message reporting the ignored protocol.
Intercase dependencies
None.
Delegation Test Plan
This document uses the terminology defined in the Master Test Plan.
Test cases list
Test Case | Test Case Description |
---|---|
DELEGATION01 | Minimum number of name servers |
DELEGATION02 | Name servers must have distinct IP addresses |
DELEGATION03 | No truncation of referrals |
DELEGATION04 | Name server is authoritative |
DELEGATION05 | Name server must not point at CNAME alias |
DELEGATION06 | Existence of SOA |
DELEGATION07 | Parent glue name records present in child |
DELEGATION01: Minimum number of name servers
Test case identifier
DELEGATION01
Objective
Section 4.1 of RFC 1034 specifies that there must be a minimum of two name servers for a domain. This test is done to verify this condition.
The RFC (RFC 1034) predates IPv6. Since IPv4 and IPv6 work as separate networks, this test case has been extended to test for two name servers that resolve into IPv4 addresses and IPv6 addresses respectively.
Both RFC 3901 (section 3) and RFC 4472 (section 1.3) states that a domain (zone) should be available over IPv4 for the time being. Therefore, it is by the default level in this test case considered to be more problematic not being available over IPv4 than not being available over IPv6.
Inputs
"Child Zone" - The domain name to be tested
Ordered description of steps to be taken to execute the test case
-
Using Method2, obtain the complete set of names of the name servers from the delegation of the Child Zone.
-
Count the name server names:
- If zero or one, emit NOT_ENOUGH_NS_DEL.
- If two or more, emit ENOUGH_NS_DEL.
-
Using Method4, obtain the IP addresses for the name servers of the delegation of the Child Zone.
-
Count the number of name server names that resolve into at least one IPv4 address:
- If zero, emit NO_IPV4_NS_DEL.
- If one, emit NOT_ENOUGH_IPV4_NS_DEL.
- If two or more, emit ENOUGH_IPV4_NS_DEL.
-
Count the number of name server names that resolve into at least one IPv6 address:
- If zero, emit NO_IPV6_NS_DEL.
- If one, emit NOT_ENOUGH_IPV6_NS_DEL.
- If two or more, emit ENOUGH_IPV6_NS_DEL.
-
Using Method3, obtain the complete set of names of the name servers from the Child Zone for the Child Zone.
-
Count the name server names:
- If zero or one, emit NOT_ENOUGH_NS_CHILD.
- If two or more, emit ENOUGH_NS_CHILD.
-
Using Method5, obtain the IP addresses for the name servers from the Child Zone for the Child Zone.
-
Count the number of name server names that resolve into at least one IPv4 address:
- If zero, emit NO_IPV4_NS_CHILD.
- If one, emit NOT_ENOUGH_IPV4_NS_CHILD.
- If two or more, emit ENOUGH_IPV4_NS_CHILD.
-
Count the number of name server names that resolve into at least one IPv6 address:
- If zero, emit NO_IPV6_NS_CHILD.
- If one, emit NOT_ENOUGH_IPV6_NS_CHILD.
- If two or more, emit ENOUGH_IPV6_NS_CHILD.
Outcome(s)
The outcome of this Test Case is "fail" if there is at least one message with the severity level ERROR or CRITICAL.
The outcome of this Test Case is "warning" if there is at least one message with the severity level WARNING, but no message with severity level ERROR or CRITICAL.
Else the outcome of this Test Case is "pass".
Message | Default severity level |
---|---|
ENOUGH_IPV4_NS_CHILD | INFO |
ENOUGH_IPV4_NS_DEL | INFO |
ENOUGH_IPV6_NS_CHILD | INFO |
ENOUGH_IPV6_NS_DEL | INFO |
ENOUGH_NS_CHILD | INFO |
ENOUGH_NS_DEL | INFO |
NOT_ENOUGH_IPV4_NS_CHILD | ERROR |
NOT_ENOUGH_IPV4_NS_DEL | ERROR |
NOT_ENOUGH_IPV6_NS_CHILD | ERROR |
NOT_ENOUGH_IPV6_NS_DEL | ERROR |
NOT_ENOUGH_NS_CHILD | ERROR |
NOT_ENOUGH_NS_DEL | ERROR |
NO_IPV4_NS_CHILD | WARNING |
NO_IPV4_NS_DEL | WARNING |
NO_IPV6_NS_CHILD | NOTICE |
NO_IPV6_NS_DEL | NOTICE |
Special procedural requirements
None
Intercase dependencies
None
DELEGATION02: Name servers must have distinct IP addresses
Test case identifier
DELEGATION02: Name servers must have distinct IP addresses
Objective
If the domain's name servers use several different names, they can all be using the same IP address. This may be due to a configuration error, or a workaround for a certain policy restriction. This test case checks that the name servers used do not reuse the same IP addresses.
Section 4.1 of RFC 1034 says at least two name servers must be used for a delegation.
Inputs
"Child Zone" - The domain name to be tested.
Ordered description of steps to be taken to execute the test case
-
Obtain the complete set of name server names in the delegation of the Child Zone using Method2 and the IP addresses for each name using Method4.
-
If the same IP address is found for two or more name server names, emit DEL_NS_SAME_IP for each repeated address, else emit DEL_DISTINCT_NS_IP.
-
Obtain the complete set of name server names from the Child Zone using Method3 and the IP addresses for each name using Method5.
-
If the same IP address is found for two or more name server names, emit CHILD_NS_SAME_IP for each repeated address, else emit CHILD_DISTINCT_NS_IP.
Outcome(s)
The outcome of this Test Case is "fail" if there is at least one message with the severity level ERROR or CRITICAL.
The outcome of this Test Case is "warning" if there is at least one message with the severity level WARNING, but no message with severity level ERROR or CRITICAL.
In other cases the outcome of this Test Case is "pass".
Message | Default severity level (if message is emitted) |
---|---|
DEL_NS_SAME_IP | ERROR |
CHILD_NS_SAME_IP | ERROR |
DEL_DISTINCT_NS_IP | INFO |
CHILD_DISTINCT_NS_IP | INFO |
Special procedural requirements
None
Intercase dependencies
None
DELEGATION03: No truncation of referrals
Test case identifier
DELEGATION03
Objective
The Domain Name System defaults to using UDP for queries and answers with a DNS payload limit of 512 octets (bytes). Larger replies cause an initial truncation indication leading to a subsequent handling via TCP with substantially higher overhead. EDNS0 is used to allow for larger UDP responses thus reducing the need for use of TCP.
But IANA still maintains that referrals from the parent zone name servers must fit into a non-EDNS0 UDP DNS packet.
Inputs
- "Child Zone" - The domain name to be tested.
Ordered description of steps to be taken to execute the test case
-
Create a DNS packet with a maximally long subdomain under the Child Zone apex (that is, 255 octets including label separators) in the Query section.
-
Obtain the set of name server names from the delegation of the Child Zone from the parent using Method2.
-
For each name server name obtained in the previous step:
- Create an NS record with the Child Zone apex as owner name and the name server name as RDATA.
- Add the NS record to the Authority section of the DNS packet created above using the message compression schema defined in section 4.1.4 of RFC 1035 where applicable.
-
Using Method1, get the parent zone of Child Zone.
-
Obtain the name server IP addresses per name server name for the delegation using Method4.
-
Make a set of the name server names that resolve into at least one IPv4 address ("IPv4 Name Server Set").
-
If the IPv4 Name Server Set is not empty and all name server names in it are In-Bailiwick of Parent then:
- Create an A record using one of the name server names and any IPv4 address.
- Add the A record to the Additional section of the DNS packet created above using the message compression schema defined in section 4.1.4 of RFC 1035.
-
Make a set of the name server names that resolve into at least one IPv6 address ("IPv6 Name Server Set").
-
If the IPv6 Name Server Set is not empty and all name server names in it are In-Bailiwick of Parent then:
- Create a AAAA record using one of the name server names and any IPv6 address.
- Add the AAAA record to the Additional section of the DNS packet created above using the message compression schema defined in section 4.1.4 of RFC 1035.
-
If the size of the DNS packet after encoding exceeds 512 octets then output REFERRAL_SIZE_TOO_LARGE else output REFERRAL_SIZE_OK.
Outcome(s)
The outcome of this Test Case is "fail" if there is at least one message with the severity level ERROR or CRITICAL.
The outcome of this Test Case is "warning" if there is at least one message with the severity level WARNING, but no message with severity level ERROR or CRITICAL.
In other cases the outcome of this Test Case is "pass".
Message | Default severity level of message |
---|---|
REFERRAL_SIZE_TOO_LARGE | WARNING |
REFERRAL_SIZE_OK | INFO |
Special procedural requirements
None
Intercase dependencies
None
Terminology
The terms "in-bailiwick" and "out-of-bailiwick" are used as defined in RFC 7719, section 6, page 15.
In-Bailiwick of Parent
A name server name is In-Bailiwick of Parent if the name is a or below the zone cut of the parent zone. If "example.com" is the parent zone of "foofoo.example.com" then name server "ns1.barbar.example.com" is In-Bailiwick of Parent for "foofoo.example.com".
All name servers of a TLD are In-Bailiwick of Parent since all names are below the root apex '.'.
DELEGATION04: Name server is authoritative
Test case identifier
DELEGATION04: Name server is authoritative
Objective
Subsection 6.1 of RFC 2181 specifies that the nameservers must answer authoritatively for the domain. Answers to queries to the name servers for the designated zone must have the "AA" bit set.
Inputs
The domain name to be tested.
Ordered description of steps to be taken to execute the test case
- Obtain the complete set of name server address records from the parent using Method4 and the child using Method5.
- All the uniquely obtained address records are queried for the SOA record over TCP and UDP on port 53.
- For each query in step 2, check whether DNS answer (bogus response are not checked here) is obtained. If any of the query fails to respond with an answer, then do not proceed to step 4 for that query. Exit from the test without any exceptions.
- If any name server fail to give an authoritative answer ("AA-bit" is set in the answer), the test fails.
Outcome(s)
If all the name servers answer with the AA-bit set, then the test succeeds.
Special procedural requirements
If either IPv4 or IPv6 transport is disabled, ignore the evaluation of the result of any test using this transport protocol. Log a message reporting on the ignored result.
Intercase dependencies
None
DELEGATION05: Name server must not point at CNAME alias
Test case identifier
DELEGATION05
Objective
Name servers for a zone are defined in NS records. An NS record points at a name, i.e. the RDATA for an NS record is a domain name. That name is the name of the name server. RFC 2181, section 10.3, states that the name of the name server must not itself point at a CNAME.
The objective of this test is to verify that name servers of the tested domain (zone) do not point at CNAME records.
Inputs
"Child Zone" - The domain name to be tested.
Scope
It is assumed that Child Zone is also tested by Connectivity01. This test case will set DEBUG level on messages for non-responsive name servers.
Ordered description of steps to be taken to execute the test case
-
Obtain the set of name server names using Method2 and Method3 ("NS Name").
-
Obtain the set of name server IP addresses using Method4 and Method5 ("NS IP").
-
For each name server name in NS Name do:
-
Create a query for A record (A query) with the name server name as owner name.
-
If the name server name is in-domain (sub-type of in-bailiwick) then for each name server IP in NS IP do:
- Send the A query to the name server IP with the RD flag unset.
- If the name server does not respond with a DNS response, then output NO_RESPONSE.
- Else, if the RCODE is not NOERROR, then output UNEXPECTED_RCODE.
- Else, if the answer section of the response includes a CNAME record then output NS_IS_CNAME.
- Else, if the response is a delegation (referral) to a
sub-zone of Child Zone, then:
- Do a DNS Lookup of the A query with the RD flag set.
- If the answer section of the response includes a CNAME record then output NS_IS_CNAME.
-
Else (the name server name is either sibling domain or out-of-bailiwick) then do:
- Do a DNS Lookup of the A query with the RD flag set.
- If the answer section of the response includes a CNAME record then output NS_IS_CNAME.
-
-
If no NS_IS_CNAME was outputted, then output NO_NS_CNAME.
Outcome(s)
The outcome of this Test Case is "fail" if there is at least one message with the severity level ERROR or CRITICAL.
The outcome of this Test Case is "warning" if there is at least one message with the severity level WARNING, but no message with severity level ERROR or CRITICAL.
In other cases the outcome of this Test Case is "pass".
Message | Default severity level |
---|---|
NO_RESPONSE | DEBUG |
UNEXPECTED_RCODE | WARNING |
NS_IS_CNAME | ERROR |
NO_NS_CNAME | INFO |
Special procedural requirements
If either IPv4 or IPv6 transport is disabled, ignore the evaluation of the result of any test using this transport protocol. Log a message reporting on the ignored result.
Intercase dependencies
None
Terminology
The terms "in-domain", "sibling domain", "in-bailiwick" and "out-of-bailiwick" are used as defined in RFC 8499, section 7 (p 25), where "in-domain" and "sibling domain" are defined as a sub-types of "in-bailiwick".
The term "DNS Lookup" is used when a recursive lookup is used, though any changes to the DNS tree introduced by an undelegated test must be respected.
DELEGATION06: Existence of SOA
Test case identifier
DELEGATION06: Existence of SOA
Objective
Section 6.1 of the RFC 2181 specifies that the SOA record is mandatory for every zone.
This test is intended to verify the presence of a SOA record for the domain.
Inputs
The domain name to be tested.
Ordered description of steps to be taken to execute the test case
- Obtain the complete set of name server address records from the parent using Method4 and the child using Method5.
- All the uniquely obtained address records are queried for the SOA record.
- If there is an answer with NOERROR and there is no content in the answer section, this test case fails.
Outcome(s)
If there is a SOA record present for the domain this test case succeeds.
Special procedural requirements
If either IPv4 or IPv6 transport is disabled, ignore the evaluation of the result of any test using this transport protocol. Log a message reporting on the ignored result.
Intercase dependencies
None
DELEGATION07: Parent glue name records present in child
Test case identifier
DELEGATION07: Parent glue name records present in child
Objective
If the list of name servers for a domain obtained from its parent are not found in its child zone, then it leads to an inconsistency (section 2.3 of RIPE-114)
Inputs
The domain name to be tested.
Ordered description of steps to be taken to execute the test case
- Obtain the complete set of name servers from the parent using Method2 and the child using Method3.
- If the set of NS names obtained from Method2 are not found in Method3, then the test fails.
Outcome(s)
If the set of glue name records obtained are found in the list of name servers obtained from the child also, then the test succeeds
Special procedural requirements
None
Intercase dependencies
None
Name Server Test Plan
These are tests of the properties of a name server.
This document uses the terminology defined in the Master Test Plan.
Test cases list
Test Case | Test Case Description |
---|---|
NAMESERVER01 | A name server should not be a recursor |
NAMESERVER02 | Test of EDNS0 support |
NAMESERVER03 | Test availability of zone transfer (AXFR) |
NAMESERVER04 | Same source address |
NAMESERVER05 | Behaviour against AAAA query |
NAMESERVER06 | NS can be resolved |
NAMESERVER07 | To check whether authoritative name servers return an upward referral |
NAMESERVER08 | Testing QNAME case insensitivity |
NAMESERVER09 | Testing QNAME case sensitivity |
NAMESERVER10 | Test for undefined EDNS version |
NAMESERVER11 | Test for unknown EDNS OPTION-CODE |
NAMESERVER12 | Test for unknown EDNS flags |
NAMESERVER13 | Test for truncated response on EDNS query |
NAMESERVER15 | Checking for revealed software version |
NAMESERVER01: A name server should not be a recursor
Test case identifier
NAMESERVER01
Objective
To ensure consistency in DNS, an authoritative name server should not be configured to do recursive lookups. Also, open recursive resolvers are considered bad internet practice due to their capability of assisting in large scale DDoS attacks. The introduction to RFC 5358 elaborates on mixing recursor and authoritative functionality, and the issue is further elaborated by D.J. Bernstein.
Section 2.5 of RFC 2870 have very specific requirement on disabling recursion functionality on root name servers.
Scope
It is assumed that Child Zone is also tested by Connectivity01. This test case will set DEBUG level on messages for non-responsive name servers.
Inputs
- The domain name to be tested ("Child Zone").
Ordered description of steps to be taken to execute the test case
-
Create A queries for the following domain names:
- xn--nameservertest.iis.se
- xn--nameservertest.icann.org
- xn--nameservertest.ripe.net
-
Retrieve all name server IPs for the Child Zone using Method4 and Method5.
-
Repeat the following steps for each name server IP.
- Send the three A queries over UDP.
- For each query do the following steps:
- If the name server does not respond with a DNS response, then emit NO_RESPONSE.
- If the DNS response comes with the RA flag set, then emit IS_A_RECURSOR.
- If the RCODE is NXDOMAIN in the responses for all three queries then emit IS_A_RECURSOR.
- If neither NO_RESPONSE nor IS_A_RECURSOR has been emitted for that server, then emit NO_RECURSOR.
Outcome(s)
The outcome of this Test Case is "fail" if there is at least one message with the severity level ERROR or CRITICAL.
The outcome of this Test Case is "warning" if there is at least one message with the severity level WARNING, but no message with severity level ERROR or CRITICAL.
In other cases the outcome of this Test Case is "pass".
Message | Default severity level (if message is emitted) |
---|---|
NO_RESPONSE | DEBUG |
IS_A_RECURSOR | ERROR |
NO_RECURSOR | INFO |
Special procedural requirements
If either IPv4 or IPv6 transport is disabled, ignore the evaluation of the result of any test using this transport protocol. Log a message reporting on the ignored result.
The domain names used in the queries are selected to be almost certainly nonexistent name since the names are chosen to violate the IDNA 2008 specification under SLDs (second-level domains) expected to respect that specification. The SLDs are selected so that the chance that they are all hosted on the same servers is low.
Intercase dependencies
None.
Terminology
Valid domain names according to the "IDNA 2008 specification" is found in RFC 5890, section 2.3.1, page 7.
NAMESERVER02: Test of EDNS0 support
Test case identifier
NAMESERVER02
Objective
EDNS(0) is a mechanism to announce capabilities of a DNS implementation, and is now basically required by any new functionality in DNS such as DNSSEC. EDNS(0) is standardized in RFC 6891.
This test case checks that all name servers has the capability to do EDNS(0) or if not, correctly replies to queries containing EDNS (OPT record).
Servers not supporting EDNS(0) must return FORMERR (RFC 6891, section 7):
Responders that choose not to implement the protocol extensions defined in this document MUST respond with a return code (RCODE) of FORMERR to messages containing an OPT record in the additional section and MUST NOT include an OPT record in the response.
Servers supporting EDNS(0) must reply with EDNS(0) (RFC 6891, section 6.1.1):
If an OPT record is present in a received request, compliant responders MUST include an OPT record in their respective responses.
To eliminating the risk of falsely classifying the server as not supporting EDNS due e.g. firewall issues, the UDP buffer size is set to 512 bytes (octets).
Scope
It is assumed that Child Zone is also tested by Connectivity01. This test case will set DEBUG level on messages for non-responsive name servers.
Inputs
- "Child Zone" - The domain name to be tested.
Ordered description of steps to be taken to execute the test case
-
Created an SOA query for the Child Zone with an OPT record with EDNS version set to "0" and with EDNS(0) option of payload size ("bufsize") set to 512 and "DO" bit unset.
-
Create a second SOA query for the Child Zone without any OPT record.
-
Obtain the set of name server IP addresses using Method4 and Method5 ("Name Server IP").
-
For each name server in Name Server IP do:
- Send the SOA query with OPT record to the name server and collect the response.
- If there is no DNS response, then:
- Send the SOA query without OPT record to the name server and collect the response.
- If there is no DNS response, then output NO_RESPONSE and go to next server.
- Else (there is a DNS response), then output BREAKS_ON_EDNS and go to next server.
- Else, if the DNS response meet the following two criteria,
then output NO_EDNS_SUPPORT:
- It has the RCODE "FORMERR"
- It has no OPT record.
- Else, if the DNS response meet the following criteria (compliant
server), then go to the next name server:
- It has the RCODE "NOERROR".
- The answer section contains the SOA record for Child Zone.
- It has OPT record with EDNS version 0.
- Else, if the DNS response meet the following criteria,
then output EDNS_RESPONSE_WITHOUT_EDNS and go to next server.
- It has the RCODE "NOERROR".
- It has no OPT record.
- Else, if the DNS response meet the following criteria,
then output EDNS_VERSION_ERROR and go to next server.
- It has the RCODE "NOERROR".
- It has OPT record with EDNS version other than 0.
- Else output NS_ERROR (i.e. other erroneous or unexpected response).
Outcome(s)
The outcome of this Test Case is "fail" if there is at least one message with the severity level ERROR or CRITICAL.
The outcome of this Test Case is "warning" if there is at least one message with the severity level WARNING, but no message with severity level ERROR or CRITICAL.
The outcome of this Test case is "pass" in all other cases.
Message | Default severity level (when message is outputted) |
---|---|
NO_RESPONSE | DEBUG |
NO_EDNS_SUPPORT | WARNING |
BREAKS_ON_EDNS | ERROR |
EDNS_RESPONSE_WITHOUT_EDNS | ERROR |
EDNS_VERSION_ERROR | ERROR |
NS_ERROR | WARNING |
Special procedural requirements
If either IPv4 or IPv6 transport is disabled, ignore the evaluation of the result of any test using this transport protocol and log a message reporting the ignored result.
Intercase dependencies
None
NAMESERVER03: Test availability of zone transfer (AXFR)
Test case identifier
NAMESERVER03 Test availability of zone transfer (AXFR)
Objective
AXFR is a mechanism to transfer the whole content of a zone from a name server. Some people prefer to not disclose the whole content of a zone for various reasons, and thus wants the public name server infrastructure not do disclose the whole zone content to the public. This test case checks the availability of the AXFR mechanism.
AXFR is defined in its latest revision in RFC 5936.
Inputs
The domain name to be tested.
Ordered description of steps to be taken to execute the test case
- Retrieve all address records for all the name servers using Method 4 and Method 5.
- Send an AXFR query to each name server IP address found in step 1.
- If any answer to the AXFR query is starting with the SOA record for the domain, this test case fails.
Outcome(s)
If any name server for the domain allows a zone transfer using AXFR, this test case fails.
Special procedural requirements
None.
Intercase dependencies
None.
NAMESERVER04: Same source address
Test case identifier
NAMESERVER04 Same source address
Objective
Responses from the authoritative name servers must contain same source IP address as the destination IP address of the initial query. This has been clarified in section 4 of RFC 2181.
Inputs
The domain name to be tested.
Ordered description of steps to be taken to execute the test case
- Retrieve all address records for all the name servers using Method 4 and Method 5.
- A SOA query for the domain name sent to the each name server IP address found in step 1.
- Any answer received from the SOA query must come from the same source IP address as the query was sent to. If there is a mismatch, this test case fails.
Outcome(s)
If any response comes from another IP address than the query was sent to, this test case fails.
Special procedural requirements
If there are many authoritative DNS nodes behind the IP address the query is sent to, there could be multiple answers with possibly different source addresses for the query. This special case is currently ignored.
Intercase dependencies
None.
NAMESERVER05: Behaviour against AAAA query
Test case identifier
NAMESERVER05
Objective
Older implementations of authoritative name servers have shown different misbehaviours trying to answer queries for AAAA records, as described in RFC 4074. This test case is intended to find out if the name server authoritative for the domain shows any of these behaviours.
Scope
It is assumed that Child Zone is also tested by Connectivity01. This test case will set DEBUG level on messages for non-responsive name servers.
Inputs
- "Child Zone" - The domain name to be tested.
Ordered description of steps to be taken to execute the test case
-
Create an A query for the apex of the Child Zone.
-
Create a AAAA query for the apex of the Child Zone.
-
Create an empty set "AAAA OK".
-
Retrieve all name server IP addresses for the Child Zone using Method4 and Method5 ("NS IP").
-
For each name server IP address in NS IP do:
- Send the A query over UDP to the name server IP.
- If no DNS response is returned, then output NO_RESPONSE.
- Else, if DNS response does not have RCODE NOERROR, then output A_UNEXPECTED_RCODE.
- Else, do:
- Send the AAAA query over UDP to the name server IP.
- If no DNS response is returned, then output AAAA_QUERY_DROPPED.
- Else, if the RCODE of the response is not NOERROR, then output AAAA_UNEXPECTED_RCODE.
- Else, if the answer section contains an AAAA record with incorrect RDATA length (e.g. 4 instead of 16 octets), then output AAAA_BAD_RDATA.
- Else, add the name server IP to AAAA OK.
-
If AAAA OK is non-empty and no messages AAAA_QUERY_DROPPED, AAAA_UNEXPECTED_RCODE or AAAA_BAD_RDATA have been outputted for any name server IP, then output AAAA_WELL_PROCESSED.
Outcome(s)
The outcome of this Test Case is "fail" if there is at least one message with the severity level ERROR or CRITICAL.
The outcome of this Test Case is "warning" if there is at least one message with the severity level WARNING, but no message with severity level ERROR or CRITICAL.
In other cases the outcome of this Test Case is "pass".
Message | Default severity level |
---|---|
AAAA_BAD_RDATA | ERROR |
AAAA_QUERY_DROPPED | ERROR |
AAAA_UNEXPECTED_RCODE | ERROR |
AAAA_WELL_PROCESSED | INFO |
A_UNEXPECTED_RCODE | WARNING |
NO_RESPONSE | DEBUG |
Special procedural requirements
If either IPv4 or IPv6 transport is disabled, ignore the evaluation of the result of any test using this transport protocol. Log a message reporting on the ignored result.
Intercase dependencies
None.
NAMESERVER06: NS can be resolved
Test case identifier
NAMESERVER06 NS can be resolved
Objective
All name servers names listed for a delegation must be resolvable in DNS. If they are not resolvable using DNS this is a sign of misconfiguration, and raises the risk of unreachability for the domain. It could also lower the performance for any resolver trying to resolve the name.
The objective of this test is to resolve the domain using all the listed name servers used in the delegation. More information about resolver behavior is in section 7 of RFC 1035.
Inputs
The domain name to be tested.
Ordered description of steps to be taken to execute the test case
- Obtain the list of name servers for the domain using Method 2 and Method 3.
- Use Method 4 and Method 5 to resolve all the name server names obtained in step 1.
- If any name does not resolve to either an A RR or AAAA RR, this test case fails.
Outcome(s)
If any of the name server names fails to resolve to an IP address, this test case fails.
Special procedural requirements
If either IPv4 or IPv6 transport is disabled, ignore the evaluation of the result of any test using this transport protocol. Log a message reporting on the ignored result.
Intercase dependencies
None.
NAMESERVER07: To check whether authoritative name servers return an upward referral
Test case identifier
NAMESERVER07 To check whether authoritative name servers return an upward referral
Objective
The configuration and/or implementation of some authoritative name servers causes them to return an upward referral to the root zone. There are proofs that such a behaviour could be used for DDoS attacks
Inputs
The domain name to be tested.
Ordered description of steps to be taken to execute the test case
- If the input domain to be tested is the root, exit from the test.
- Retrieve all address records for all the name servers using Method 4 and Method 5.
- An NS query is sent to each name server IP address found in step 2, with the root “.” as the destination
- If any of the query returns with one or more responses in the authority section, then this test case fails.
Outcome(s)
The test case is Ok only if there are no responses in the authority section
Special procedural requirements
None.
Intercase dependencies
None.
NAMESERVER08: Testing QNAME case insensitivity
Test case identifier
NAMESERVER08 Verify whether the authoritative nameserver response match the case of every letter in the query name
Objective
The DNS standards require that nameservers treat names with case insensitivity. That is, the names example.com and EXAMPLE.COM should resolve to the same IP address. However, in the response, most nameservers echo back the name as it appeared in the request, preserving the original case.
Therefore, another way to add entropy to requests is to randomly vary the case of letters in domain names queried. This technique, also known as "0x20" because bit 0x20 is used to set the case of of US-ASCII letters, was first proposed in the IETF internet draft Use of Bit 0x20 in DNS Labels to Improve Transaction Identity. With this technique, the nameserver response must match not only the query name, but the case of every letter in the name string; for example, wWw.eXaMpLe.CoM or WwW.ExamPLe.COm. This may add little or no entropy to queries for the top-level and root domains, but it's effective for most hostnames.
Inputs
The domain name to be tested.
Ordered description of steps to be taken to execute the test case
- Retrieve all address records for all the name servers using Method 4 and Method 5.
- A random query with mixed case (e.G Www.iETf.Org) is sent to each unique name server IP address found in step 1.
- Remember the case of the QNAME in the query sent.
- Compare the QNAME in the question section of the response with the string in step3.
- If the string in step3 and step4 are not equal with respect to case in sensitivity, the test fails.
Outcome(s)
The test case is Ok only if there are no responses in the authority section
Special procedural requirements
None.
Intercase dependencies
None.
NAMESERVER09: Testing QNAME case sensitivity
Test case identifier
NAMESERVER09 Verify whether the authoritative nameserver returns same results for equivalent names with different cases in the request.
Objective
There has been cases where the nameservers respond with complete case-sensitivity (in violation of the DNS standards): that is, they match the exact case of the name in the response; but return different results for equivalent names with different cases in the request (typically NXDOMAIN).
Inputs
The domain name to be tested.
Ordered description of steps to be taken to execute the test case
- Retrieve all address records for all the name servers using Method 4 and Method 5.
- Send a query with the input string in a mixed case (e.g. wWW.iETF.oRG) to each of the name server IP address found in step 1.
- If the "answer" flag is greater than 0, remember the "answer" section, else remember the status flag.
- Send another query with an alternative mixed case (e.g. Www.Ietf.Org) to each of the name server found in step 1.
- If the "answer" flag is greater than 0, remember the "answer" section, else remember the status flag.
- Compare the results remembered in step3 and step5.
- If the results in step 6 are not equal, the test case fails.
Outcome(s)
The test case passes only if the results of all queries are exactly the same.
Special procedural requirements
None.
Intercase dependencies
None.
NAMESERVER10: Test for undefined EDNS version
Test case identifier
NAMESERVER10
Table of contents
- Objective
- Scope
- Inputs
- Summary
- Test procedure
- Outcome(s)
- Special procedural requirements
- Intercase dependencies
- Terminology
Objective
EDNS (RFC 6891) is a mechanism to announce capabilities of a DNS implementation, and is required by new functionality in DNS such as DNSSEC (RFC 4033, section 3).
RFC 6891, section 6.1.3, states that if a nameserver has implemented EDNS but has not implemented the version level of the request, then it MUST respond with RCODE "BADVERS". Only version "0" has been defined for EDNS.
Note that RCODE "BADVERS" is an extended RCODE which is calculated from the combination of the normal RCODE field in the DNS package header (RFC 1035, section 4.1.1) and the OPT record EXTENDED-RCODE field (RFC 6891, section 6.1.3). Also see IANA RCODE Registry.
Scope
Issues covered by Connectivity01 (basic name server issues) or Nameserver02 (basic EDNS issues) will not result in messages from this test case.
Inputs
- "Child Zone" - The domain name to be tested.
Summary
- Only relevant for a zone whose name servers correctly support EDNS, version 0.
Message Tag outputted | Level | Arguments | Description of when message tag is outputted |
---|---|---|---|
N10_NO_RESPONSE_EDNS1_QUERY | WARNING | ns_ip_list | Response when EDNS ver=0, but not when 1. |
N10_UNEXPECTED_RCODE | WARNING | ns_ip_list, rcode | Unexpected RCODE value when EDNS ver=1. |
N10_EDNS_RESPONSE_ERROR | WARNING | ns_ip_list | Expected RCODE value when EDNS ver=1, but error in response. |
The value in the Level column is the default severity level of the message. The severity level can be changed in the Zonemaster-Engine profile. Also see the Severity Level Definitions document.
The argument names in the Arguments column lists the arguments used in the message. The argument names are defined in the argument list.
Test procedure
-
Create the following empty sets:
- Name server IP ("No Response EDNS1 Query").
- Name server IP and associated RCODE ("Unexpected RCODE").
- Name server IP ("EDNS Response Error").
-
Create an SOA query for the Child Zone with an OPT record with EDNS version set to "0" and with EDNS option of payload size ("bufsize") set to 512 and other EDNS options and flags unset ("Query One").
-
Create an SOA query for the Child Zone with an OPT record with EDNS version set to "1" and with EDNS option of payload size ("bufsize") set to 512 and other EDNS options and flags unset ("Query Two").
-
Obtain the set of name server IP addresses using Method4 and Method5 ("Name Server IP").
-
For each name server in Name Server IP do:
- Send Query One over UDP to the name server, collect the response and do:
- If there is no DNS response then go to next name server.
- Else, if the RCODE value is not "NOERROR" then go to next name server.
- Send Query Two over UDP to the name server, collect the response and do:
- If there is no DNS response, then add the name server IP to the No Response EDNS1 Query set.
- Else, if the DNS response does not have RCODE with value "BADVERS", then add the name server IP and RCODE value to the Unexpected RCODE set.
- Else, if the DNS response meet all the following three criteria, then
just go to the next name server (correct response):
- It has the RCODE "BADVERS".
- It has EDNS version 0.
- The answer section is empty.
- Else add the name server IP to the EDNS Response Error set.
- Send Query One over UDP to the name server, collect the response and do:
-
If the No Response EDNS1 Query set is non-empty, then output N10_NO_RESPONSE_EDNS1_QUERY with the name server IP addresses from the set.
-
If the Unexpected RCODE set is non-empty, then for each RCODE value in the set do:
- Output N10_UNEXPECTED_RCODE with the RCODE value and the name server IP addresses for that RCODE value.
-
If the EDNS Response Error set is non-empty, then output N10_EDNS_RESPONSE_ERROR with the name server IP addresses from the set.
Outcome(s)
The outcome of this Test Case is "fail" if there is at least one message with the severity level ERROR or CRITICAL.
The outcome of this Test Case is "warning" if there is at least one message with the severity level WARNING, but no message with severity level ERROR or CRITICAL.
In other cases, no message or only messages with severity level INFO or NOTICE, the outcome of this Test Case is "pass".
Special procedural requirements
If either IPv4 or IPv6 transport is disabled, ignore the evaluation of the result of any test using this transport protocol and log a message reporting the ignored result.
Intercase dependencies
None
Terminology
No special terminology for this test case.
NAMESERVER11: Test for unknown EDNS OPTION-CODE
Test case identifier
NAMESERVER11
Table of contents
- Objective
- Scope
- Inputs
- Summary
- Test procedure
- Outcome(s)
- Special procedural requirements
- Intercase dependencies
- Terminology
Objective
EDNS is a mechanism to announce capabilities of a DNS implementation, and is now basically required by any new functionality in DNS such as DNSSEC (RFC 6891).
RFC 6891, section 6.1.2, states that any OPTION-CODE values not understood by a responder or requestor MUST be ignored. Unknown OPTION-CODE values must be processed as though the OPTION-CODE was not even there.
In this test case, we will query with an unknown EDNS OPTION-CODE and expect that the OPTION-CODE is not present in the response for the query.
Scope
It is assumed that Child Zone is also tested and reported by Connectivity01. This test case will just ignore non-responsive name servers or name servers not giving a correct DNS response for an authoritative name server.
It is assumed that Child Zone has been tested and reported by Nameserver02. Running this test case without running Nameserver02 can give an incomplete report status of Child Zone.
Inputs
"Child Zone" - The domain name to be tested.
Summary
Message Tag | Level | Arguments | Message ID for message tag |
---|---|---|---|
N11_NO_EDNS | WARNING | ns_ip_list | The DNS response, on query with unknown EDNS option-code, does not contain any EDNS from name servers "{ns_ip_list}". |
N11_NO_RESPONSE | WARNING | ns_ip_list | There is no response on query with unknown EDNS option-code from name servers "{ns_ip_list}". |
N11_RETURNS_UNKNOWN_OPTION_CODE | WARNING | ns_ip_list | The DNS response, on query with unknown EDNS option-code, contains an unknown EDNS option-code from name servers "{ns_ip_list}". |
N11_UNEXPECTED_ANSWER_SECTION | WARNING | ns_ip_list | The DNS response, on query with unknown EDNS option-code, does not contain the expected SOA record in the answer section from name servers "{ns_ip_list}". |
N11_UNEXPECTED_RCODE | WARNING | ns_ip_list, rcode | The DNS response, on query with unknown EDNS option-code, has unexpected RCODE name "{rcode}" from name servers "{ns_ip_list}". |
N11_UNSET_AA | WARNING | ns_ip_list | The DNS response, on query with unknown EDNS option-code, is unexpectedly not authoritative from name servers "{ns_ip_list}". |
The value in the Level column is the default severity level of the message. The severity level can be changed in the Zonemaster-Engine profile. Also see the Severity Level Definitions document.
The argument names in the Arguments column lists the arguments used in the message. The argument names are defined in the argument list.
Test procedure
In this section and unless otherwise specified below, the term "EDNS Query" follows the specification for DNS queries as specified in DNS Query and Response Defaults. The handling of the DNS responses on the DNS queries follow, unless otherwise specified below, what is specified for EDNS Response in the same specification.
-
Create the following empty sets:
- Name server IP address ("No Response on Unknown Option Code")
- Name server IP address and RCODE Name ("Unexpected RCODE on Unknown Option Code")
- Name server IP address ("No EDNS on Unknown Option Code")
- Name server IP address ("Unexpected Answer Section on Unknown Option Code")
- Name server IP address ("Unset AA on Unknown Option Code")
- Name server IP address ("Returns Unknown Option Code")
-
Create a EDNS Query with query type SOA, Child Zone as query name and with no EDNS options or flags ("SOA Query").
-
Create a EDNS Query with query type SOA, Child Zone as query name and with EDNS OPTION-CODE set to anything other than what is already assigned in the IANA-DNSSYSTEM-PARAMETERS and no other EDNS options or flags ("SOA Query with EDNS Option").
-
Obtain the set of name server IP addresses using Method4 and Method5 ("Name Server IP").
-
For each name server in Name Server IP do:
- Send SOA Query to the name server and collect the response.
- Go to next name server if at least one of the following criteria is met:
- There is no DNS response from the server.
- EDNS is unset in the response.
- The RCODE Name in the response is not "NoError".
- The AA flag is unset in the response.
- The answer section has no SOA record with Child Zone as owner name.
- Send SOA Query with EDNS Option to the name server and collect the
response.
- If there is no DNS response from the server then add the name server to the No Response on Unknown Option Code set.
- Else, if the RCODE Name in the response is not "NoError" then add the name server and RCODE Name to the Unexpected RCODE on Unknown Option Code set. server.
- Else, if EDNS is unset in the response then add the name server to the No EDNS on Unknown Option Code set.
- Else, if the answer section has no SOA record with Child Zone as owner name then add the name server to the Unexpected Answer Section on Unknown Option Code set.
- Else, if the AA flag is unset in the response then add the name server to the Unset AA on Unknown Option Code set.
- Else, if the "OPTION-CODE" from the query is present in the response, then add name server to the Returns Unknown Option Code set.
- Else, no issues were found.
-
If the No Response on Unknown Option Code set is non-empty, then output N11_NO_RESPONSE with the name servers IP addresses from the set.
-
If the Unexpected RCODE on Unknown Option Code set is non-empty, then for each RCODE NAME in the set output N11_UNEXPECTED_RCODE with the RCODE Name and the name servers IP addresses for that RCODE NAME in the set.
-
If the No EDNS on Unknown Option Code set is non-empty, then output N11_NO_EDNS with the name servers IP addresses from the set.
-
If the Unexpected Answer Section on Unknown Option Code set is non-empty, then output N11_UNEXPECTED_ANSWER_SECTION with the name servers IP addresses from the set.
-
If the Unset AA on Unknown Option Code set is non-empty, then output N11_UNSET_AA with the name servers IP addresses from the set.
-
If the Returns Unknown Option Code set is non-empty, then output N11_RETURNS_UNKNOWN_OPTION_CODE with the name servers IP addresses from the set.
Outcome(s)
The outcome of this Test Case is "fail" if there is at least one message with the severity level ERROR or CRITICAL.
The outcome of this Test Case is "warning" if there is at least one message with the severity level WARNING, but no message with severity level ERROR or CRITICAL.
In other cases, no message or only messages with severity level INFO or NOTICE, the outcome of this Test Case is "pass".
Special procedural requirements
If either IPv4 or IPv6 transport is disabled, skip sending queries over that transport protocol. A message will be outputted reporting that the transport protocol has been skipped.
Intercase dependencies
None.
Terminology
No special terminology for this test case.
NAMESERVER12: Test for unknown EDNS flags
Test case identifier
NAMESERVER12
Objective
EDNS is a mechanism to announce capabilities of a dns implementation, and is now basically required by any new functionality in dns such as DNSSEC (RFC 6891).
RFC 6891, section 6.1.4, states that "Z" flag bits must be set to zero by senders and ignored by receiver.
IANA lists the flags in the EDNS Header Flags assignment list.
In this test case, the query will have an unknown EDNS flag set, i.e. one of the Z flag bits set to "1", and it is expected that all "Z" bits to be clear in the response (set to "0").
Scope
It is assumed that Child Zone is also tested by Connectivity01. This test case will set DEBUG level on messages for non-responsive name servers.
Inputs
"Child Zone" - The domain name to be tested.
Ordered description of steps to be taken to execute the test case
-
Create a SOA query for the Child Zone with an OPT record with one of the EDNS flag "Z" bits set to "1" and no other EDNS options or flags set.
-
Obtain the set of name server IP addresses using Method4 and Method5 ("Name Server IP").
-
For each name server in Name Server IP do:
- Send the SOA query to the name server and collect the response.
- If there is no DNS response, output NO_RESPONSE and go to next server.
- Else, if the DNS response has the RCODE "FORMERR" then output NO_EDNS_SUPPORT.
- Else, if the pseudo-section has an OPT record with one or more Z flag bits being set to "1", then output Z_FLAGS_NOTCLEAR.
- Else, if the DNS response meet the following four criteria,
then just go to the next name server (no error):
- The SOA is obtained as response in the ANSWER section.
- If the DNS response has the RCODE "NOERROR".
- The pseudo-section response has an OPT record with version set to 0.
- The "Z" bits are clear in the response
- Else output NS_ERROR.
Outcome(s)
The outcome of this Test Case is "fail" if there is at least one message with the severity level ERROR or CRITICAL.
The outcome of this Test Case is "warning" if there is at least one message with the severity level WARNING, but no message with severity level ERROR or CRITICAL.
The outcome of this Test case is "pass" in all other cases.
Message | Default severity level |
---|---|
NO_RESPONSE | DEBUG |
NO_EDNS_SUPPORT | WARNING |
NS_ERROR | WARNING |
Z_FLAGS_NOTCLEAR | WARNING |
Special procedural requirements
If either IPv4 or IPv6 transport is disabled, ignore the evaluation of the result of any test using this transport protocol and log a message reporting the ignored result.
Intercase dependencies
None.
NAMESERVER13: Test for truncated response on EDNS query
Test case identifier
NAMESERVER13
Objective
EDNS is a mechanism to announce capabilities of a DNS implementation, and is now basically required by any new functionality in DNS such as DNSSEC (RFC 6891).
RFC 6891, section 7 states that an OPT record must be included in a truncated response, if the query includes an OPT pseudo record.
This Test Case will try to verify that if the response to a query with an OPT record is truncated, then the response will contain an OPT record.
To trigger a truncated response, the OPT pseudo record 'DO' bit is set and the buffer size is limited to 512 bytes. If the zone is not signed with DNSSEC, the response will probably not be truncated anyway.
Scope
It is assumed that Child Zone is also tested by Connectivity01. This test case will set DEBUG level on messages for non-responsive name servers.
Inputs
"Child Zone" - The domain name to be tested.
Ordered description of steps to be taken to execute the test case
-
Create a DNSKEY query for the Child Zone that is signed with 'DO' bit set to '1' and setting the buffer size to 512 bytes
-
Obtain the set of name server IP addresses using Method4 and Method5 ("Name Server IP").
-
For each name server in Name Server IP do:
- Send the query to the name server and collect the response.
- If there is no DNS response, output NO_RESPONSE and go to next server.
- Else, if the DNS response has the RCODE "FORMERR" then output NO_EDNS_SUPPORT and go to the next server.
- Else, if the DNS response meet the following criteria output MISSING_OPT_IN_TRUNCATED: 1. The DNS response is truncated (the "TC" flag is set). 2. The DNS response has no OPT record.
- Else, if the DNS response meet the following criteria,
then just go to the next name server (no error):
- The DNS response has the RCODE "NOERROR".
- The pseudo-section response has an OPT record with version set to 0.
- Else output NS_ERROR.
Outcome(s)
The outcome of this Test Case is "fail" if there is at least one message with the severity level ERROR or CRITICAL.
The outcome of this Test Case is "warning" if there is at least one message with the severity level WARNING, but no message with severity level ERROR or CRITICAL.
The outcome of this Test case is "pass" in all other cases.
Message | Default severity level (when message is outputted) |
---|---|
NO_RESPONSE | DEBUG |
NO_EDNS_SUPPORT | WARNING |
NS_ERROR | WARNING |
MISSING_OPT_IN_TRUNCATED | WARNING |
Special procedural requirements
If either IPv4 or IPv6 transport is disabled, ignore the evaluation of the result of any test using this transport protocol and log a message reporting the ignored result.
Intercase dependencies
None.
NAMESERVER15: Checking for revealed software version
Test case identifier
NAMESERVER15
Table of contents
- Objective
- Scope
- Inputs
- Summary
- Test procedure
- Outcome(s)
- Special procedural requirements
- Intercase dependencies
- Terminology
Objective
This Test Case verifies if a name server responds to TXT queries in the CHAOS DNS Class, specifically about its software version as it may sometimes be desirable not to reveal that information. The CHAOS class identifier is usually abbreviated as "CH".
A list of DNS classes and references for those are found in the IANA DNS Class database.
Scope
It is assumed that Child Zone is also tested and reported by Connectivity01. This Test Case will just ignore non-responsive name servers or name servers not giving a correct DNS response for an authoritative name server.
Inputs
- "Child Zone" - The domain name to be tested.
Summary
Message Tag | Level | Arguments | Message ID for message tag |
---|---|---|---|
N15_ERROR_ON_VERSION_QUERY | NOTICE | ns_list, query_name | The following name server(s) do not respond or respond with SERVFAIL to software version query "{query_name}". Returned from name servers: "{ns_list}" |
N15_NO_VERSION_REVEALED | INFO | ns_list | The following name server(s) do not reveal the software version. Returned from name servers: "{ns_list}" |
N15_SOFTWARE_VERSION | NOTICE | ns_list, query_name, string | The following name server(s) respond to software version query "{query_name}" with string "{string}". Returned from name servers: "{ns_list}" |
N15_WRONG_CLASS | WARNING | ns_list | The following name server(s) do not return CH class record(s) on CH class query. Returned from name servers: "{ns_list}" |
The value in the Level column is the default severity level of the message. The severity level can be changed in the Zonemaster-Engine Profile. Also see the Severity Level Definitions document.
The argument names in the Arguments column lists the arguments used in the message. The argument names are defined in the Argument List.
The name server names are assumed to be available at the time when the msgid is created, if the argument name is "ns" or "ns_list" even when in the "Test procedure" below it is only referred to the IP address of the name servers.
Test procedure
-
Create the following empty sets:
- Name server IP, query name and string ("TXT Data")
- Name server IP and query name ("Error On Version Query")
- Name server IP ("Sending Version Query")
- Name server IP ("Wrong Record Class")
-
Create a DNS Query with query type SOA and query name Child Zone ("SOA Query").
-
Create a DNS Query with query type TXT and query class CH ("TXT Query").
-
Create the set of query names with values "version.bind" and "version.server" ("Query Names").
-
Obtain the set of name server IP addresses using Method4 and Method5 ("Name Server IP").
-
For each name server in Name Server IP do:
- Send SOA Query to the name server IP.
- If there is no DNS response, then go to next name server IP.
- Add the name server IP to the Sending Version Query set.
- For each query name in Query Names do:
- Send TXT Query with query name to the name server and collect the response.
- If there is no DNS response or the response has the RCODE Name ServFail, add name server and query name to the Error On Version Query set and go to next query name.
- If the DNS Response does not have any TXT record in the answer section with query name as owner name, go to next query name.
- For each TXT record in the answer section of the DNS Response do:
- If DNS Class of the TXT record is not CH, then add name server to the Wrong Record Class set.
- Extract and concatenate the string(s) from the RDATA of the record.
- Remove any leading or trailing SPACE (U+0020) or CHARACTER TABULATION (horizontal tab, U+0009) characters from the concatenated string.
- If the extracted string is non-empty, add name server, query name and the string to the TXT Data set.
-
If the TXT Data set is non-empty, then, for each unique string and query name pair in the set, output N15_SOFTWARE_VERSION with name server IP list, query name and string.
-
If the Error On Version Query set is non-empty, then for each query name in the set output N15_ERROR_ON_VERSION_QUERY with the query name and the list of name server IP addresses.
-
For each name server IP in the Sending Version Query set, remove that name server IP from the set if the name server IP is also a member of the TXT Data set.
-
If the Sending Version Query set is non-empty then output N15_NO_VERSION_REVEALED with the list of the name servers in the Sending Version Query set.
-
If the Wrong Record Class set is non-empty then output N15_WRONG_CLASS with the list of the name servers in the Wrong Record Class set.
Outcome(s)
The outcome of this Test Case is "fail" if there is at least one message with the severity level ERROR or CRITICAL.
The outcome of this Test Case is "warning" if there is at least one message with the severity level WARNING, but no message with severity level ERROR or CRITICAL.
In other cases, no message or only messages with severity level INFO or NOTICE, the outcome of this Test Case is "pass".
Special procedural requirements
The Child Zone must be a valid name meeting "Requirements and normalization of domain names in input".
Intercase dependencies
None
Terminology
-
"Concatenate" - The term is used to refer to the conversion of a TXT resource record’s data to a single contiguous string, as specified in RFC 7208, section 3.3.
-
"Send" - The term is used when a DNS query is sent to a specific name server (name server IP address).
Syntax Test Plan
These are tests of the syntax of different labels in DNS, such as domain names and host names.
This document uses the terminology defined in the Master Test Plan.
Test cases list
Test Case | Test Case Description |
---|---|
SYNTAX01 | No illegal characters in the domain name |
SYNTAX02 | No hyphen ('-') at the start or end of the domain name |
SYNTAX03 | There must be no double hyphen ('--') in position 3 and 4 of the domain name |
SYNTAX04 | The NS name must have a valid domain/hostname |
SYNTAX05 | Misuse of '@' character in the SOA RNAME field |
SYNTAX06 | No illegal characters in the SOA RNAME field |
SYNTAX07 | No illegal characters in the SOA MNAME field |
SYNTAX08 | MX name must have a valid hostname |
SYNTAX01: No illegal characters in the domain name
Test case identifier
SYNTAX01 No illegal characters in the domain name
Objective
There must be no illegal characters used in the domain name. The domain name must follow the rules defined in section 2.3.1 of RFC 1035, section 2.1 of RFC 1123, section 11 of RFC 2182 and section 2 of RFC 3696.
Inputs
The domain name to be tested.
Ordered description of steps to be taken to execute the test case
- The domain name of the test object is used as the input for the validation.
- Check for characters that are not allowed in the domain name according to the rules defined in section 2.3.1 of RFC 1035.
Outcome(s)
If there are any invalid characters in the domain name, this test case fails.
Special procedural requirements
None.
Intercase dependencies
None.
SYNTAX02: No hyphen ('-') at the start or end of the domain name
Test case identifier
SYNTAX02 No hyphen ('-') at the start or end of the domain name
Objective
There must be no hyphen ('-') at the start or end of the domain name. The domain name must follow the rules defined in section 2.3.1 of RFC 1035, section 2.1 of RFC 1123, section 11 of RFC 2182 and section 2 of RFC 3696.
Inputs
The domain name to be tested.
Ordered description of steps to be taken to execute the test case
- Each label of the domain name of the test object is used as the input for the validation.
- If any label in the domain name start with a hyphen ('-') this test case fails.
- If any label in the domain name ends with a hyphen ('-') this test case fails.
Outcome(s)
If any label in the domain name start or ends with a hyphen ('-') this test case fails.
Special procedural requirements
None.
Intercase dependencies
None.
SYNTAX03: There must be no double hyphen ('--') in position 3 and 4 of the domain name
Test case identifier
SYNTAX02 No double hyphen ('--') in position 3 and 4 of the domain name
Objective
There must be no double hyphen ('--') in position 3 and 4 of the domain name, unless the domain name has the prefix 'xn--' which is used for internationalization. See section 5 of RFC 3696, "Implications of internationalization".
Inputs
The domain name to be tested.
Ordered description of steps to be taken to execute the test case
- Each label of the domain name of the test object is used as the input for the validation.
- If any label in the domain name contains hyphens ('-') in position 3 and 4, go to next step.
- Unless the prefix is 'xn', this test case fails.
Outcome(s)
If any label in the domain name has a hyphen in position 3 and 4 of the label and the prefix is not 'xn', this test case fails.
Special procedural requirements
None.
Intercase dependencies
None.
SYNTAX04: The NS name must have a valid domain/hostname
Test case identifier
SYNTAX04 The NS name must have a valid domain/hostname
Objective
The Name Server name must be a valid hostname according to the rules defined in RFC 952, in section 2.1 in RFC 1123, section 11 in RFC 2182 and section 2 and 5 in RFC 3696. Newer RFCs may override some rules defined in earlier documents.
Inputs
The hostname to be tested. The hostnames comes from all the nameservers used, from both the parent and the zone itself.
Ordered description of steps to be taken to execute the test case
- Obtain the list of name server hostnames from Method2 and Method3 (This is all the name servers from the parent delegation, and all the name servers in the apex of the zone itself.)
- Each label of the hostname of the test object is used as the input for the validation.
- If any label in the hostname does not contain a-z or 0-9 this test case fails.
- If the rightmost label (the TLD) contains only digits, this test case fails.
- If there is a hyphen ('-') in position 3 and 4 of the label, and the prefix is not xn (used for internationalization), this test case fails.
Outcome(s)
If any of the steps 3 to 5 in the ordered description of this test case fails, the whole test case fails.
Special procedural requirements
None.
Intercase dependencies
None.
SYNTAX05: Misuse of '@' character in the SOA RNAME field
Test case identifier
SYNTAX05 There must be no misused '@' character in the SOA RNAME field
Objective
The SOA RNAME field does not allow the '@' characters to be used for describing a mailbox. The first dot ('.') is thus translated into the '@' character. This is a common mistake. The rules are defined in RFC 1035.
Inputs
The domain name to be tested.
Ordered description of steps to be taken to execute the test case
- Obtain a set of name server IP addresses using Method4 and Method5.
- Create a SOA query for the zone.
- Send the SOA query over UDP to each name server IP address until a response is received or until the set is exhausted.
- Check if the RNAME field contains a '@' character.
Outcome(s)
If there is any '@' character in any SOA/RNAME field, this test case fails.
Special procedural requirements
None.
Intercase dependencies
The de-escaped output from this test is used by SYNTAX08.
SYNTAX06: No illegal characters in the SOA RNAME field
Test case identifier
SYNTAX06
Objective
The SOA RNAME field is a mailbox address. The SOA RNAME field is defined in RFC 1035, section 3.3.13 and in RFC 1912, section 2.2. The RNAME field should follow the rules of an e-mail address also defined in RFC 5322, section 3.4.1.
Scope
It is assumed that Child Zone is also tested by Connectivity01. This test case will set DEBUG level on messages for non-responsive name servers.
Inputs
- "Child Zone" - The domain name to be tested.
Ordered description of steps to be taken to execute the test case
-
Obtain the set of name server IP addresses using Method4 and Method5 ("NS IP").
-
Create a SOA query for the apex of the Child Zone with RD flag unset.
-
For each name server IP in NS IP do:
- Send the SOA query over UDP to the name server IP.
- If the name server does not respond with a DNS response, then:
- Output NO_RESPONSE.
- Go to next name server IP.
- If the DNS response does not include an SOA record in the
answer section, then:
- Output NO_RESPONSE_SOA_QUERY.
- Go to next name server IP.
- Extract the RNAME from the SOA record (from the first SOA record if multiple) and convert it to an email address ("Email Address" below) using the following steps:
- If Email Address does not meet the
mail address specification in RFC 5322,
section 3.4.1, then
- Output RNAME_RFC822_INVALID.
- Go to next name server IP.
- Extract the domain part (to the right of "@") from the Mail address ("Domain Part" below).
- Create an MX query for the Domain Part and do a DNS Lookup of that query.
- If the lookup of MX does not return a DNS response with RCODE
"NOERROR", then:
- Output RNAME_MAIL_DOMAIN_INVALID.
- Go to next name server IP.
- When doing the MX lookup, CNAME or a chain of CNAMEs are followed, if any. If an MX record or records are found via CNAME, then set Domain Part to be equal to the owner name of that MX record (instead of being equal to the domain part of Email Address).
- If the MX lookup returned a NO DATA response (no MX record),
then:
- Create address queries (A and AAAA) for the Domain Part and
do:
- Do DNS Lookups of those queries.
- If the answer section contains a CNAME record output RNAME_MAIL_ILLEGAL_CNAME.
- Else, extract any A and AAAA records from the answer sections of the DNS responses with Domain Part as owner name.
- If any A or AAAA record points at 127.0.0.1 or ::1 (localhost), respectively, then output RNAME_MAIL_DOMAIN_LOCALHOST.
- If no A or AAAA are extracted or any records points at 127.0.0.1 or ::1, then output RNAME_MAIL_DOMAIN_INVALID.
- Create address queries (A and AAAA) for the Domain Part and
do:
- If the MX lookup returns one or more MX records, then for each
MX record extract the domain name in RDATA ("Mail Exchange")
and do:
- Create address queries (A and AAAA) of Mail Exchange and do:
- Do DNS Lookups of those queries.
- If the answer section contains a CNAME record output RNAME_MAIL_ILLEGAL_CNAME.
- Else, extract any A and AAAA records from the answer sections of the DNS responses with Mail Exchange as owner name.
- If any A or AAAA record points at 127.0.0.1 or ::1 (localhost), respectively, then output RNAME_MAIL_DOMAIN_LOCALHOST.
- If no A or AAAA are extracted or any records points at 127.0.0.1 or ::1, then output RNAME_MAIL_DOMAIN_INVALID.
- Create address queries (A and AAAA) of Mail Exchange and do:
-
If at least one name server IP has neither outputted NO_RESPONSE nor NO_RESPONSE_SOA_QUERY and RNAME_MAIL_DOMAIN_INVALID has not been outputted for any name server IP, then output RNAME_RFC822_VALID.
Outcome(s)
The outcome of this Test Case is "fail" if there is at least one message with the severity level ERROR or CRITICAL.
The outcome of this Test Case is "warning" if there is at least one message with the severity level WARNING, but no message with severity level ERROR or CRITICAL.
In other cases the outcome of this Test Case is "pass".
Message | Default severity level |
---|---|
NO_RESPONSE | DEBUG |
NO_RESPONSE_SOA_QUERY | DEBUG |
RNAME_RFC822_INVALID | WARNING |
RNAME_MAIL_DOMAIN_INVALID | WARNING |
RNAME_MAIL_DOMAIN_LOCALHOST | WARNING |
RNAME_MAIL_ILLEGAL_CNAME | WARNING |
RNAME_RFC822_VALID | INFO |
Special procedural requirements
If either IPv4 or IPv6 transport is disabled, ignore the evaluation of the result of any test using this transport protocol. Log a message reporting on the ignored result.
Intercase dependencies
None.
Terminology
-
"Using Method" - When the term is used, names and IP addresses are fetched using the defined Methods.
-
"Send" (to an IP address) - The term is used when a DNS query is sent to a specific name server.
-
"DNS Lookup" - The term is used when a recursive lookup is used, though any changes to the DNS tree introduced by an undelegated test must be respected.
SYNTAX07: No illegal characters in the SOA MNAME field
Test case identifier
SYNTAX07 There must be no illegal characters in the SOA MNAME field
Objective
The SOA MNAME field is a hostname. Hostnames are valid according to the rules defined in RFC 952, in section 2.1 in RFC 1123, section 11 in RFC 2182 and section 2 and 5 in RFC 3696. Newer RFCs may override some rules defined in earlier documents.
Inputs
The domain name to be tested.
Ordered description of steps to be taken to execute the test case
- Retrieve the SOA record from the zone being tested.
- Get the MNAME from the SOA record.
- Each label of the hostname of the test object is used as the input for the validation.
- If any label in the hostname does not contain a-z or 0-9 this test case fails.
- If any label of the hostname is longer than 63 characters, this test case fails.
- If the hostname is longer than 255 characters including separators, this test case fails.
- If the rightmost label (the TLD) contains only digits, this test case fails.
- If there is a hyphen ('-') in position 3 and 4 of the label, and the prefix is not xn (used for internationalization), this test case fails.
Outcome(s)
If any of the steps 4 to 8 in the ordered description of this test case fails, the whole test case fails.
Special procedural requirements
None.
Intercase dependencies
This test case uses the same host name validator as test case SYNTAX04.
SYNTAX08: MX name must have a valid hostname
Test case identifier
SYNTAX08 The MX record name must be a valid hostname
Objective
The MX record names used for delivering mail for a domain name address must be valid hostnames according to the rules defined in RFC 952, in section 2.1 in RFC 1123, section 11 in RFC 2182 and section 2 and 5 in RFC 3696. Newer RFCs may override some rules defined in earlier documents. The MX records use of "Domain Names" is described in section 2.3.5 of RFC 5321.
Inputs
The hostnames to be tested. The hostnames comes from looking up the MX record for the domain being tested.
Ordered description of steps to be taken to execute the test case
- Query for the MX record of the domain name.
- For each hostname of the MX records found:
- If any label in the hostname does not contain a-z or 0-9 this test case fails.
- If any label of the hostname is longer than 63 characters, this test case fails.
- If the hostname is longer than 255 characters including separators, this test case fails.
- If the rightmost label (the TLD) contains only digits, this test case fails.
- If there is a hyphen ('-') in position 3 and 4 of the label, and the prefix is not xn (used for internationalization), this test case fails.
Outcome(s)
If any of the steps 3 to 7 in the ordered description of this test case fails, the whole test case fails.
Special procedural requirements
None.
Intercase dependencies
None.
Zone Test Plan
These are tests of the zone content in DNS, such as SOA and MX records.
This document uses the terminology defined in the Master Test Plan.
Test cases list
Test Case | Test Case Description |
---|---|
ZONE01 | Fully qualified master nameserver in SOA |
ZONE02 | SOA 'refresh' minimum value |
ZONE03 | SOA 'retry' lower than 'refresh' |
ZONE04 | SOA 'retry' at least 1 hour |
ZONE05 | SOA 'expire' minimum value |
ZONE06 | SOA 'minimum' maximum value |
ZONE07 | SOA master is not an alias |
ZONE08 | MX is not an alias |
ZONE09 | MX record present |
ZONE10 | No multiple SOA records |
ZONE11 | SPF policy validation |
ZONE01: Fully qualified master nameserver in SOA
Test case identifier
ZONE01 Fully qualified master nameserver in SOA
Table of contents
- Objective
- Scope
- Inputs
- Summary
- Test procedure
- Outcome(s)
- Special procedural requirements
- Intercase dependencies
- Terminology
Objective
The MNAME field from the SOA record of a zone is supposed to contain the master name server for that zone. The hostname of the MNAME field may not be listed in the NS records in the zone among the delegated name servers, but should still be authoritative for the zone. MNAME may be used for other services such as DNS NOTIFY described in RFC1996.
RFC1035, section 3.3.13, specifies that "the domain-name of the name server that was the original or primary source of data for this zone".
RFC1996, section 2, and RFC2136, section 1, add that "the primary master is named in the zone's SOA MNAME field and optionally by an NS RR. There is by definition only one primary master server per zone".
RFC2181, section 7.2, clarifies that "it is quite clear in the specifications, yet seems to have been widely ignored, that the MNAME field of the SOA record should contain the name of the primary (master) server for the zone identified by the SOA. It should not contain the name of the zone itself. That information would be useless, as to discover it, one needs to start with the domain name of the SOA record - that is the name of the zone".
There exists an unstandardized practice to set the SOA MNAME to ".", which should not be interpreted that there is no primary master server, but to indicate that there is no default server for dynamic updates. With ".", SOA MNAME has no server name. There is at least one old and expired Internet-Draft that attempted to standardize that behavior, draft-jabley-dnsop-missing-mname. If the SOA MNAME is an empty name (".") this Test Case will not try to connect to a server behind it since there will never be a server behind that name, as the purpose is most definitely to follow that practice. Instead, a special message will be outputted.
This Test Case will check that:
- the SOA MNAME contains the master name server of Child Zone, as best as it can be determined.
- the SOA MNAME name server is authoritative of Child Zone.
- the SOA SERIAL of the SOA MNAME is at least equal to the ones found from the name servers in the NS record set of Child Zone. This comparison must be done following RFC1982.
- the SOA MNAME name server is listed as part of the NS record set of Child Zone.
Scope
It is assumed that Child Zone is tested and reported by CONNECTIVITY01. This Test Case will just ignore non-responsive name servers or name servers not giving a correct DNS response for an authoritative name server, except if the name server is listed in the SOA MNAME.
The syntax of the SOA MNAME for Child Zone is not tested in this Test Case, see SYNTAX07.
The consistency of the SOA MNAME between different servers of Child Zone is not tested by this Test Case, see CONSISTENCY06.
Inputs
- "Child Zone" - The domain name to be tested.
Summary
Message Tag | Level | Arguments | Message ID for message tag |
---|---|---|---|
Z01_MNAME_HAS_LOCALHOST_ADDR | WARNING | nsname, ns_ip | SOA MNAME name server "{nsname}" resolves to a localhost IP address ({ns_ip}). |
Z01_MNAME_IS_DOT | NOTICE | ns_ip_list | SOA MNAME is specified as "." which usually means "no server". Fetched from name servers "{ns_ip_list}". |
Z01_MNAME_IS_LOCALHOST | WARNING | ns_ip_list | SOA MNAME name server is "localhost", which is invalid. Fetched from name servers "{ns_ip_list}". |
Z01_MNAME_IS_MASTER | DEBUG | ns_list | SOA MNAME name server(s) "{ns_list}" appears to be master. |
Z01_MNAME_MISSING_SOA_RECORD | WARNING | ns | SOA MNAME name server "{ns}" responds to an SOA query with no SOA records in the answer section. |
Z01_MNAME_NO_RESPONSE | WARNING | ns | SOA MNAME name server "{ns}" does not respond to an SOA query. |
Z01_MNAME_NOT_AUTHORITATIVE | WARNING | ns | SOA MNAME name server "{ns}" is not authoritative for the zone. |
Z01_MNAME_NOT_IN_NS_LIST | INFO | nsname | SOA MNAME name server "{nsname}" is not listed as NS record for the zone. |
Z01_MNAME_NOT_MASTER | WARNING | ns_list, soaserial, soaserial_list | SOA MNAME name server(s) "{ns_list}" do(es) not have the highest SOA SERIAL (expected "{soaserial}" but got "{soaserial_list}") |
Z01_MNAME_NOT_RESOLVE | WARNING | nsname | SOA MNAME name server "{nsname}" cannot be resolved into an IP address. |
Z01_MNAME_UNEXPECTED_RCODE | WARNING | ns, rcode | SOA MNAME name server "{ns}" gives unexpected RCODE name ("{rcode}") in response to an SOA query. |
The value in the Level column is the default severity level of the message. The severity level can be changed in the Zonemaster-Engine profile. Also see the Severity Level Definitions document.
The argument names in the Arguments column lists the arguments used in the message. The argument names are defined in the argument list.
Test procedure
In this section and unless otherwise specified below, the terms "DNS Query" follow the specification for DNS queries as specified in DNS Query and Response Defaults. The handling of the DNS responses on the DNS queries follow, unless otherwise specified below, what is specified for DNS Response in the same specification.
-
Create a DNS Query with query type SOA and query name Child Zone ("SOA Query").
-
Create the following empty sets:
- Name server SOA MNAME name, SOA MNAME IP address(es), SOA SERIAL(s) ("MNAME Nameservers")
- Name server SOA SERIAL ("SERIAL Nameservers")
- Name server SOA MNAME name, SOA MNAME IP address, SOA SERIAL ("MNAME Not Master")
- Name server SOA MNAME name, SOA MNAME IP address ("MNAME Is Master")
- Name server IP address ("MNAME Is Localhost")
- Name server IP address ("MNAME Is Dot")
-
Obtain the set of name server IP addresses using Method4 and Method5 ("Name Server IP").
-
For each name server IP address in Name Server IP do:
- Send SOA Query to the name server IP and collect the response.
- Go to next name server IP address if at least one of
the following criteria is met:
- There is no DNS response.
- RCODE Name of the response is not "NoError".
- The AA flag is not set in the response.
- There is no SOA record with owner name matching the query.
- From the DNS response, extract the name server name from the SOA MNAME field:
- If the name is "localhost", then add name server IP address to the MNAME Is Localhost set.
- Else if the name is ".", then add name server IP address to the MNAME Is Dot set.
- Else, add SOA MNAME name server name to the MNAME Nameservers set.
- From the SOA record in the DNS response, extract the value from the SOA SERIAL field and add it to the SERIAL Nameservers set.
- Go to next name server IP address.
-
If the set MNAME Is Localhost is non-empty, then output Z01_MNAME_IS_LOCALHOST with name server(s) IP address(es).
-
If the set MNAME Is Dot is non-empty, then output Z01_MNAME_IS_DOT with name server(s) IP address(es).
-
If the set MNAME Nameservers is empty, then terminate these procedures.
-
Obtain the set of name server names using Method3 ("Child Nameservers").
-
For each SOA MNAME name server name in MNAME Nameservers do:
- If the SOA MNAME name server name is not part of the Child Nameservers set, then output Z01_MNAME_NOT_IN_NS_LIST with SOA MNAME name server name.
- Do a DNS Lookup of SOA MNAME name server name (A and AAAA) and add the SOA MNAME name server IP address(es) found to the MNAME Nameservers set for the same entry as the SOA MNAME name server name.
- If at least one IP address from the previous step was found, then:
- For each SOA MNAME name server IP address for the SOA MNAME name server name do:
- If the IP address is a localhost address (127.0.0.1 or ::1), then output Z01_MNAME_HAS_LOCALHOST_ADDR with SOA MNAME name server name and IP.
- Else, send SOA Query to the name server IP and collect the response.
- If there is a DNS response, with RCODE Name "NoError" and
an SOA record in the answer section, then:
- If the AA flag is not set, then output Z01_MNAME_NOT_AUTHORITATIVE with SOA MNAME name server name and IP address.
- Else, add the SOA SERIAL value to the MNAME Nameservers set for the SOA MNAME name server name and IP pair.
- Else if RCODE Name is not "NoError", then output Z01_MNAME_UNEXPECTED_RCODE with RCODE Name, SOA MNAME name server name and IP address.
- Else if there is no SOA record in the answer section, then output Z01_MNAME_MISSING_SOA_RECORD with SOA MNAME name server name and IP address.
- Else, output Z01_MNAME_NO_RESPONSE with SOA MNAME name server name and IP address.
- If there is a DNS response, with RCODE Name "NoError" and
an SOA record in the answer section, then:
- Go to next SOA MNAME name server IP.
- For each SOA MNAME name server IP address for the SOA MNAME name server name do:
- Else, output Z01_MNAME_NOT_RESOLVE with SOA MNAME name server name.
- Go to next SOA MNAME name server name.
-
If there is no SOA SERIAL in the MNAME Nameservers set, then terminate these procedures.
-
For each SOA SERIAL (per SOA MNAME name server name and IP address pair) in MNAME Nameservers do:
- For each SOA SERIAL in SERIAL Nameservers do:
- Compare both SOA SERIAL values (using the arithmetic in RFC1982).
- If the one from SERIAL Nameservers is higher, then add SOA MNAME name server name, IP address and SOA SERIAL of the current SOA SERIAL value from the MNAME Nameservers set to the MNAME Not Master set, and go to next SOA SERIAL (from the MNAME Nameservers set).
- Add SOA MNAME name server name and IP address to the MNAME Is Master set.
- For each SOA SERIAL in SERIAL Nameservers do:
-
If the set MNAME Not Master is non-empty, then output Z01_MNAME_NOT_MASTER with SOA MNAME name server name(s), IP address(es) and SOA SERIAL from the set, along with the SOA SERIAL values from the SERIAL Nameservers set.
-
If the set MNAME Is Master is non-empty, then output Z01_MNAME_IS_MASTER with SOA MNAME name server name(s) and IP address(es) from the set.
Outcome(s)
The outcome of this Test Case is "fail" if there is at least one message with the severity level ERROR or CRITICAL.
The outcome of this Test Case is "warning" if there is at least one message with the severity level WARNING, but no message with severity level ERROR or CRITICAL.
In other cases, no message or only messages with severity level INFO or NOTICE, the outcome of this Test Case is "pass".
Special procedural requirements
If either IPv4 or IPv6 transport is disabled, skip sending queries over that transport protocol. A message will be outputted reporting that the transport protocol has been skipped.
Intercase dependencies
None.
Terminology
- "DNS Lookup" - The term is used when a recursive lookup is used, though any changes to the DNS tree introduced by an undelegated test must be respected.
ZONE02: SOA 'refresh' minimum value
Test case identifier
ZONE02 SOA 'refresh' minimum value
Objective
The SOA refresh value is the number of seconds that describes how often a secondary name server will poll the primary name server to see if there is any updates. The SOA refresh value is described in section 3.3.13 in RFC 1035, and clarified in section 2.2 of RFC 1912. Setting the refresh value low will increase the DNS traffic between the servers, and also increase the load on the master name server. The primary name server will in most cases send DNS notifications to tell the secondary name servers that zone content has been updated, as described in RFC 1996.
The RIPE-203 recommendation for the refresh value is 24 hours (86400 seconds). Older DNSCheck code had a four hour minimum value, and this is the minimum value we recommend.
Inputs
The domain name to be tested.
Ordered description of steps to be taken to execute the test case
- Retrieve the SOA record from a delegated name server for the domain.
- If the answer from step 1 is not authoritative, iterate step 1 until there is an authoritative answer.
- Retrieve the refresh value from the SOA record.
- If the refresh value is less than 14400 (four hours in seconds) this test case fails.
Outcome(s)
If the SOA refresh value is less than 14400 this test case fails.
Special procedural requirements
None.
Intercase dependencies
None.
ZONE03: SOA 'retry' lower than 'refresh'
Test case identifier
ZONE03 SOA 'retry' lower than 'refresh'
Objective
The SOA retry value is the number of seconds that describes minimum time elapsed since a failed zone refresh from the primary name server. The SOA refresh value is described in section 3.3.13 in RFC 1035, and clarified in section 2.2 of RFC 1912.
It's typically some fraction of the refresh interval.
Setting the retry value low will increase the DNS traffic between the servers, and also increase the load on the master name server.
Inputs
The domain name to be tested.
Ordered description of steps to be taken to execute the test case
- Retrieve the SOA record from a delegated name server for the domain.
- If the answer from step 1 is not authoritative, iterate step 1 until there is an authoritative answer.
- Retrieve the retry value from the SOA record.
- If the retry value is higher than or equal to the refresh value, this test case fails.
Outcome(s)
If the SOA retry value is higher than or equal to the refresh value, this test case fails.
Special procedural requirements
None.
Intercase dependencies
None.
ZONE04: SOA 'retry' at least 1 hour
Test case identifier
ZONE04 SOA 'retry' at least 1 hour
Objective
The SOA retry value is the number of seconds that describes minimum time elapsed since a failed zone refresh from the primary name server. The SOA refresh value is described in section 3.3.13 in RFC 1035, and clarified in section 2.2 of RFC 1912.
Setting the retry value low will increase the DNS traffic between the servers, and also increase the load on the master name server.
The RIPE-203 recommendation for the retry value is 2 hours (7200 seconds). Older DNSCheck code had a one hour minimum value (3600 seconds), and this is the minimum value we recommend.
Inputs
The domain name to be tested.
Ordered description of steps to be taken to execute the test case
- Retrieve the SOA record from a delegated name server for the domain.
- If the answer from step 1 is not authoritative, iterate step 1 until there is an authoritative answer.
- Retrieve the retry value from the SOA record.
- If the retry value is less than 3600 seconds, this test case fails.
Outcome(s)
If the retry value is less than 3600 seconds, this test case fails.
Special procedural requirements
None.
Intercase dependencies
None.
ZONE05: SOA 'expire' minimum value
Test case identifier
ZONE05 SOA 'expire' minimum value
Objective
The SOA expire value specifies for how long any secondary name server keeps the zone valid without any contact with the primary name server. This value should be greater than how long a major outage would typically last. The expire value should also be larger than the refresh and retry values, as described in section 3.3.13 in RFC 1035, and clarified in section 2.2 of RFC 1912.
Setting the expire value low will increase the risk of any unwanted non-availability of the zone because of any failures in contacting the primary name server.
The RIPE-203 recommendation for the expire value is 1000 hours (roughly 41 days). Older DNSCheck code had a 7 day minimum value (604800 seconds), and this is the minimum value we recommend as an absolute minimum.
Inputs
The domain name to be tested.
Ordered description of steps to be taken to execute the test case
- Retrieve the SOA record from a delegated name server for the domain.
- If the answer from step 1 is not authoritative, iterate step 1 until there is an authoritative answer.
- Retrieve the expire value and the refresh value from the SOA record.
- If the expire value is less than 604800 seconds (7 days), this test case fails.
- If the expire value is lower than the refresh value, this test case fails.
Outcome(s)
If the expire value is less than 604800 seconds or if the expire value is lower than the refresh value, this test case fails.
Special procedural requirements
None.
Intercase dependencies
None.
ZONE06: SOA 'minimum' maximum value
Test case identifier
ZONE06 SOA 'minimum' maximum value
Objective
The SOA minimum field sets the default TTL for all records in a zone. The recommended value is to be "cache-friendly". However, for a zone that changes content often, there is a need to keep the TTL values shorter. The use of the SOA minimum value today is the negative cache (where a resolver find content is missing).
The SOA minimum field is described in section 3.3.13 in RFC 1035, and clarified in section 2.2 of RFC 1912. The description of the implementation of negative caching is in RFC 2308 (although it has been updated by several DNSSEC related RFCs, it is still relevant for this purpose).
The RIPE-203 recommendation for the minimum value 2 days, but the negative caching is now the norm. DNSCheck has a recommended value of between 300 seconds (5 minutes) and 86400 seconds (1 day).
Inputs
The domain name to be tested.
Ordered description of steps to be taken to execute the test case
- Obtain a set of name server IP addresses using Method4 and Method5.
- Create a SOA query for the zone.
- Send the SOA query over UDP to each name server IP address until a response is received or until the set is exhausted.
- If the answer from step 3 is not authoritative, iterate step 3 until there is an authoritative answer.
- Retrieve the SOA minimum value from the SOA record.
- If the minimum value is larger than 86400 seconds (1 day), this test case fails.
- If the minimum value is lower than 300 seconds (5 minutes), this test case fails.
Outcome(s)
If the minimum value is larger than 86400 seconds or if the minimum value is lower than 300 seconds, this test case fails.
Special procedural requirements
None.
Intercase dependencies
None.
ZONE07: SOA master is not an alias
Test case identifier
ZONE07 SOA master is not an alias
Objective
Any NS type record should not be a CNAME. The SOA MNAME should in this respect not be a CNAME.
Quote from 2.4 in RFC 1912:
Having NS records pointing to a CNAME is bad and may conflict badly with current BIND servers.
The SOA MNAME field is described in section 3.3.13 in RFC 1035.
The RIPE-203 recommendation for the minimum value 2 days, but the negative caching is now the norm. DNSCheck has a recommended value of between 300 seconds (5 minutes) and 86400 seconds (1 day).
Inputs
The domain name to be tested.
Ordered description of steps to be taken to execute the test case
- Retrieve the SOA record from a delegated name server for the domain.
- If the answer from step 1 is not authoritative, iterate step 1 until there is an authoritative answer.
- Retrieve the SOA MNAME value from the SOA record.
- Query for A and AAAA records for the host from MNAME.
- If the answer to the query is a CNAME, this test case fails.
Outcome(s)
If the SOA MNAME field is pointing to a CNAME, this test case fails.
Special procedural requirements
None.
Intercase dependencies
None.
ZONE08: MX is not an alias
Test case identifier
ZONE08 MX is not an alias
Objective
An MX type record for a domain must not resolve to a CNAME, following the text in section 10.3 of RFC 2181 and section 2.3.5 in RFC 5321.
Inputs
The domain name to be tested.
Ordered description of steps to be taken to execute the test case
- Query the MX record from a delegated name server for the domain.
- If the answer from step 1 is not authoritative, iterate step 1 until there is an authoritative answer.
- If the MX answer is a CNAME, this test case fails.
Outcome(s)
If the MX record for the domain is pointing to a CNAME, this test case fails.
Special procedural requirements
None.
Intercase dependencies
None.
ZONE09: MX record present
Test case identifier
ZONE09
Table of contents
- Objective
- Scope
- Inputs
- Summary
- Test procedure
- Outcome(s)
- Special procedural requirements
- Intercase dependencies
- Terminology
Objective
It is strongly recommended in RFC 2142, section 7, that every domain should have a mailbox named HOSTMASTER@domain (where "domain" is Child Zone in this test case).
For simplicity and regularity, it is strongly recommended that the well known mailbox name HOSTMASTER always be used <HOSTMASTER@domain>.
This test case therefore expects for every domain (zone), excluding some cases described below, to publish an MX record in apex of the zone (i.e. in the same node as the SOA record).
If MX is not present, SMTP can deliver email using an address record (A or AAAA) as specified in RFC 5321, section 5.1, but that possibility is not in common use. This test case only checks for MX record and ignores the possibility to use address records for email.
Even if not mentioned in RFC 2142, there are some exceptions to the rule to include MX and mail target for a domain.
The purpose of a zone in the .ARPA tree is to hold infrastructural identifiers, and it is not expected that such a zone name is used as Email Domain (RFC 3172). This also means that the well known mailbox is not expected for reverse zones (zone under in-addr.arpa or ip6.arpa). Such zone are therefore excluded by this test case from the requirement of MX in the apex.
The root zone cannot be an Email Domain since the email domain is the part to the left of the trailing dot, and the root zone owner name has nothing left of the trailing dot. The root zone is excluded by this test case from the requirement of MX in the apex.
Top-level domains (TLDs) can technically function as Email Domains (RCF 5321, section 2.3.5) but they rarely have that function and are probably not meant to be included in the specification in RFC 2142. Internet Architecture Board concludes in a report "Dotless Domains Considered Harmful" that domain names that only consists of one label, e.g. "se", "fr" or "com", should not be used for various Internet services. This means TLD names should not be used as Email Domains. In this test case TLDs are not only excluded from the requirement of being an Email Domain, if found to be, a message will be generated that points that out.
RFC 7505 standardizes "Null MX" which means that there is no email service for the domain. A "Null MX" is accepted for any type of domain. RFC 7505, section 3, also specifies that the "Null MX" must be the sole MX record and its preference must be zero.
In this test case, the following zone types are excluded from the requirement of MX:
- Root zone
- TLD zone
- Zone in the .ARPA tree
The following zone type is expected not to have any MX (considered harmful, see IAB Statement):
- TLD zone
Scope
It is assumed that Child Zone is tested and reported by Connectivity01. This test case will just ignore non-responsive name servers or name servers not giving a correct DNS response for an authoritative name server.
Inputs
- "Child Zone" - The domain name to be tested.
Summary
- A notify is issued if MX is missing, except for root, a zone in the ARPA tree or a TLD.
- A warning is issued if a TLD has a non-Null MX.
Message Tag | Level | Arguments | Message ID for message tag |
---|---|---|---|
Z09_INCONSISTENT_MX | WARNING | Some name servers return an MX RRset while others return none. | |
Z09_INCONSISTENT_MX_DATA | WARNING | The MX RRset data is inconsistent between the name servers. | |
Z09_MISSING_MAIL_TARGET | NOTICE | The child zone has no mail target (no MX). | |
Z09_MX_DATA | INFO | ns_ip_list, mailtarget_list | The mail targets in the MX RRset, "{mailtarget_list}", as returned by name servers "{ns_ip_list}". |
Z09_MX_FOUND | INFO | ns_ip_list | MX RRset was returned by name servers "{ns_ip_list}". |
Z09_NON_AUTH_MX_RESPONSE | WARNING | ns_ip_list | Non-authoritative response on MX query from name servers "{ns_ip_list}". |
Z09_NO_MX_FOUND | INFO | ns_ip_list | No MX RRset was returned by name servers "{ns_ip_list}". |
Z09_NO_RESPONSE_MX_QUERY | WARNING | ns_ip_list | No response on MX query from name servers "{ns_ip_list}". |
Z09_NULL_MX_NON_ZERO_PREF | NOTICE | The zone has a Null MX with non-zero preference. | |
Z09_NULL_MX_WITH_OTHER_MX | WARNING | The zone has a Null MX mixed with other MX records. | |
Z09_ROOT_EMAIL_DOMAIN | NOTICE | Root zone with an unexpected MX RRset (non-Null MX). | |
Z09_TLD_EMAIL_DOMAIN | WARNING | The zone is a TLD and has an unexpected MX RRset (non-Null MX). | |
Z09_UNEXPECTED_RCODE_MX | WARNING | ns_ip_list, rcode | Unexpected RCODE value ({rcode}) in response to MX query. Responses from name servers "{ns_ip_list}". |
The value in the Level column is the default severity level of the message. The severity level can be changed in the Zonemaster-Engine profile. Also see the Severity Level Definitions document.
The argument names in the Arguments column lists the arguments used in the message. The argument names are defined in the argument list.
Test procedure
In this section and unless otherwise specified below, the terms "DNS Query" follow the specification for DNS queries as specified in DNS Query and Response Defaults. The handling of the DNS responses on the DNS queries follow, unless otherwise specified below, what is specified for DNS Response in the same specification.
-
Create a DNS Query with query type SOA and query name Child Zone ("SOA Query").
-
Create a DNS Query with query type MX and query name Child Zone ("MX Query").
-
Obtain the set of name server IP addresses using Method4 and Method5 ("Name Server IP").
-
Create the following empty sets
- Name server IP address ("No Response MX Query").
- Name server IP address and associated RCODE value ("Unexpected RCODE MX Response").
- Name server IP address ("Non-authoritative MX").
- Name server IP address ("No MX RRset").
- Name server IP address and associated MX RRset ("MX RRset").
-
For each name server IP in Name Server IP do:
-
Send SOA Query over UDP to the name server.
-
Go to next name server IP if at least one of the following criteria is met:
- There is no DNS response.
- The RCODE of the response is not "NoError" (IANA RCODE List).
- The AA flag is not set in the response.
- There is no SOA record with owner name matching the query.
-
Send MX Query over UDP to the name server and collect the response, and:
- If the response has the TC flag set, re-query over TCP and use that response instead.
- If there is no DNS response, then add the name server IP to the No Response MX Query set.
- Else, if the RCODE of response is not "NoError" (IANA RCODE List), then add the name server IP and the RCODE to the Unexpected RCODE MX Response set.
- Else, if the AA flag is not set in the response, then add the name server IP to the Non-authoritative MX set.
- Else, if there is no MX record with matching owner name in the answer section, then add the name server (IP) to the No MX RRset set.
- Else do:
- Extract the MX RRset from the response.
- Add the name server IP and the MX RRset to the MX RRset set.
-
-
If the set No Response MX Query is non-empty, then output Z09_NO_RESPONSE_MX_QUERY with the name server IP addresses from the set.
-
If the set Unexpected RCODE MX Response is non-empty, then for each RCODE in the set, do:
- Output Z09_UNEXPECTED_RCODE_MX with the RCODE value (IANA RCODE List) and the name server IP addresses from the set.
-
If the set Non-authoritative MX is non-empty, then output Z09_NON_AUTH_MX_RESPONSE with the name server IP addresses from the set.
-
If both No MX RRset set and MX RRset set are non-empty then:
- Output Z09_INCONSISTENT_MX.
- Output Z09_NO_MX_FOUND with the name server IP addresses from the No MX RRset set.
- Output Z09_MX_FOUND with the name server IP addresses from the MX RRset set.
-
If the MX RRset set is non-empty (the No MX RRset set is empty or non-empty), then do:
- If the RRsets in MX RRset are not equal for all name servers then do:
- Output Z09_INCONSISTENT_MX_DATA.
- For each RRset in MX RRset, output Z09_MX_DATA with the mail targets from the RDATA and the associated name server IP addresses in the set.
- Else do:
- If the mailtarget of any of the MX records in the RRset in MX RRset
is a Null MX then do:
- If there are more than one record in the MX RRset, then output Z09_NULL_MX_WITH_OTHER_MX with the mail targets from the RDATA of MX records.
- If the preference of the Null MX is non-zero then output Z09_NULL_MX_NON_ZERO_PREF.
- Else, if Child Zone is a TLD with a non-Null MX then output Z09_TLD_EMAIL_DOMAIN.
- Else, if Child Zone is the root zone with a non-Null MX then output Z09_ROOT_EMAIL_DOMAIN.
- Else, output Z09_MX_DATA with the mail targets from the RDATA and the associated name server IP addresses in the set.
- If the mailtarget of any of the MX records in the RRset in MX RRset
is a Null MX then do:
- If the RRsets in MX RRset are not equal for all name servers then do:
-
If the No MX RRset set is non-empty and the MX RRset set is empty, then output Z09_MISSING_MAIL_TARGET unless
- Child Zone is the root zone ("."), or
- Child Zone is a TLD, or
- Child Zone is a zone in the .ARPA tree.
Outcome(s)
The outcome of this Test Case is "fail" if there is at least one message with the severity level ERROR or CRITICAL.
The outcome of this Test Case is "warning" if there is at least one message with the severity level WARNING, but no message with severity level ERROR or CRITICAL.
In other cases, no message or only messages with severity level INFO or NOTICE, the outcome of this Test Case is "pass".
Special procedural requirements
If either IPv4 or IPv6 transport is disabled, ignore the evaluation of the result of any test using this transport protocol and log a message reporting the ignored result.
Intercase dependencies
None.
Terminology
The term "Null MX" is used for an MX record where the mail target is "." as defined in RFC 7505 with the specific restrictions given in section 3 of that RFC.
The term "TLD" is used for "Top Level Domain", i.e. a zone whose name consists of a single label (ignoring the empty label after the final dot).
The term "Email Domain" is used for the domain name at right of the at-sign ("@") in an email address.
ZONE10: No multiple SOA records
Test case identifier
ZONE10
Objective
The SOA record is crucial for the DNS zone and "exactly one SOA RR should be present at the top of the zone" (RFC 1035, section 5.2). This test case will verify that the zone of the domain to be tested return exactly one SOA record.
Scope
It is assumed that Child Zone is also tested by Connectivity01. This test case will set DEBUG level on messages for non-responsive name servers.
Inputs
- "Child Zone" - The domain name to be tested.
Ordered description of steps to be taken to execute the test case
-
Obtain the set of name server IP addresses using Method4 and Method5 ("NS IP").
-
Create a SOA query for the apex of the Child Zone with RD flag unset.
-
For each name server in NS IP do:
- Send the SOA query over UDP to the name server.
- If the name server does not respond with a DNS response, then output NO_RESPONSE.
- Else, if the DNS response does not include a SOA record in the answer section, then output NO_SOA_IN_RESPONSE.
- Else, if the SOA record or records in the answer section do not have Child Zone as owner name, then output WRONG_SOA.
- Else, if the DNS response includes multiple SOA records in the answer section, then output MULTIPLE_SOA.
-
If no message is outputted for any server, then output ONE_SOA.
Outcome(s)
The outcome of this Test Case is "fail" if there is at least one message with the severity level ERROR or CRITICAL.
The outcome of this Test Case is "warning" if there is at least one message with the severity level WARNING, but no message with severity level ERROR or CRITICAL.
In other cases the outcome of this Test Case is "pass".
Message | Default severity level |
---|---|
MULTIPLE_SOA | ERROR |
NO_RESPONSE | DEBUG |
NO_SOA_IN_RESPONSE | DEBUG |
ONE_SOA | INFO |
WRONG_SOA | DEBUG |
Special procedural requirements
If either IPv4 or IPv6 transport is disabled, ignore the evaluation of the result of any test using this transport protocol. Log a message reporting on the ignored result.
Intercase dependencies
None.
Terminology
When the term "using Method" is used, names and IP addresses are fetched using the defined Methods.
The term "send" (to an IP address) is used when a DNS query is sent to a specific name server.
ZONE11: SPF policy validation
Test case identifier
ZONE11
Table of contents
- Objective
- Scope
- Inputs
- Summary
- Test procedure
- Outcome(s)
- Special procedural requirements
- Intercase dependencies
- Terminology
Objective
Sender Policy Framework (SPF), described in RFC 7208, is a mechanism allowing domain name owners to specify which hosts are allowed to send mail claiming to be from that domain. It is implemented by means of TXT records in a structured format.
This test case looks up SPF records in the apex of Child Zone. It checks that there is at most one published SPF version 1 policy and, if present, also checks its syntax.
Scope
It is assumed that Child Zone has been tested and reported by Connectivity01. This test case will just ignore non-responsive name servers or name servers not giving a correct DNS response for an authoritative name server.
Inputs
- "Child Zone" - The domain name to be tested.
Summary
Message Tag | Level | Arguments | Message ID for message tag |
---|---|---|---|
Z11_INCONSISTENT_SPF_POLICIES | WARNING | One or more name servers do not publish the same SPF policy as the others. | |
Z11_DIFFERENT_SPF_POLICIES_FOUND | NOTICE | ns_ip_list | The following name servers returned the same SPF policy, but other name servers returned a different policy. Name servers: {ns_ip_list}. |
Z11_NO_SPF_FOUND | NOTICE | domain | No SPF policy was found for {domain}. |
Z11_SPF1_MULTIPLE_RECORDS | ERROR | ns_ip_list | The following name servers returned more than one SPF policy. Name servers: {ns_ip_list}. |
Z11_SPF1_SYNTAX_ERROR | ERROR | domain, ns_ip_list | The SPF policy of {domain} has a syntax error. Policy retrieved from the following nameservers: {ns_ip_list}. |
Z11_SPF1_SYNTAX_OK | INFO | domain | The SPF policy of {domain} has correct syntax. |
Z11_UNABLE_TO_CHECK_FOR_SPF | ERROR | None of the zone’s name servers responded with an authoritative response to queries for SPF policies. |
The value in the Level column is the default severity level of the message. The severity level can be changed in the Zonemaster-Engine profile. Also see the Severity Level Definitions document.
The argument names in the Arguments column lists the arguments used in the message. The argument names are defined in the argument list.
Test procedure
In this section and unless otherwise specified below, the term "DNS Query" follows the specification for DNS queries as specified in DNS Query and Response Defaults. The handling of the DNS responses on the DNS queries follow, unless otherwise specified below, what is specified for DNS Response in the same specification.
-
Create a DNS Query with query type TXT and query name Child Zone ("TXT query").
-
Create an empty set of pairs of IP addresses and strings, "SPF-Policies".
-
Obtain the set of name server IP addresses using Method4 and Method5 ("Name Server IP").
-
For each name server in Name Server IP do:
-
Send TXT Query to the name server and collect the DNS Response.
-
Go to the next name server IP address if at least one of the following criteria is met:
- There is no DNS response.
- RCODE Name of the response is not "NoError".
- The AA flag is not set in the response.
-
If the name server responds with no TXT record, then add the pair consisting of the Name Server IP and the empty string to the SPF-Policies set.
-
If the name server responds with at least one TXT record and none is an SPF TXT record, then add the pair consisting of the Name Server IP and the empty string to the SPF-Policies set.
-
If the name server responds with at least one TXT record that is an SPF TXT record, then, for each SPF TXT record do:
- Concatenate all strings in the RDATA field.
- Lowercase the resulting string.
- Add a pair consisting of the Name Server IP and the lowercase string thus derived from the RDATA field to the SPF-Policies set.
-
Go to the next name server.
-
-
If the SPF-Policies set is empty, then output Z11_UNABLE_TO_CHECK_FOR_SPF and terminate the test.
-
If all the pairs in the SPF-Policies set contain empty strings, then output Z11_NO_SPF_FOUND and terminate the test.
-
Compare the set of SPF-Policies retrieved from all name servers. If at least two different name servers have returned different sets of SPF policies, then:
- Output Z11_INCONSISTENT_SPF_POLICIES.
- Group SPF-Policies by equal sets of SPF policies, such that a set of SPF policies is mapped to the list of Name Server IPs that returned it.
- For each such group of name servers, output Z11_DIFFERENT_SPF_POLICIES_FOUND.
- Terminate the test.
-
If the SPF-Policies set contains at least two entries with the same IP address, then output Z11_SPF1_MULTIPLE_RECORDS with the list of nameservers that returned more than one SPF policy and terminate the test.
-
The following steps assume that all pairs in the SPF-Policies set have the same string ("SPF policy").
-
If the SPF Policy does not pass the syntax check for SPF version 1 records, then output Z11_SPF1_SYNTAX_ERROR and terminate the test.
-
If no other message was outputted by this test case, then output Z11_SPF1_SYNTAX_OK.
Outcome(s)
The outcome of this Test Case is "fail" if there is at least one message with the severity level ERROR or CRITICAL.
The outcome of this Test Case is "warning" if there is at least one message with the severity level WARNING, but no message with severity level ERROR or CRITICAL.
In other cases, no message or only messages with severity level INFO or NOTICE, the outcome of this Test Case is "pass".
Special procedural requirements
If either IPv4 or IPv6 transport is disabled, skip sending queries over that transport protocol. A message will be outputted reporting that the transport protocol has been skipped.
Intercase dependencies
None.
Terminology
-
"SPF TXT record" - The term is used to refer to a TXT resource record which, after concatenating all strings within that resource record into one string, yields a string either equal to
v=spf1
or starting withv=spf1
followed by a space, irrespective of character case. -
"concatenate" - The term is used to refer to the conversion of a TXT resource record’s data to a single contiguous string, as specified in RFC 7208, section 3.3.
-
"passing the syntax check" - The term is used in this document to refer to text that is valid according to the ABNF grammar published in RFC 7208 starting from section 4.5. Alternatively, the reader may use an online SPF syntax validator; however, such online validators should not be used as normative references.
-
"using Method" - The term is used when data is fetched using the defined Method.
Zonemaster development guide
The development guide provides instructions for various tasks related to the development of each component of Zonemaster.
Development guides:
Development
Overview
This is the development guide for Zonemaster-CLI. It provides instructions for various tasks related to the development of Zonemaster-CLI.
Common Developer Actions
Generate man page
To generate and view a development version of the man page:
perldoc -oman script/zonemaster-cli
Code license
Copyright (c) The Swedish Internet Foundation (https://internetstiftelsen.se/en/) Copyright (c) AFNIC (https://www.afnic.fr/en/) All rights reserved.
Copyright belongs to external contributor where applicable.
Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met:
Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer.
Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution.
THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
Documentation license
Copyright (c) The Swedish Internet Foundation (https://internetstiftelsen.se/en/) Copyright (c) AFNIC (https://www.afnic.fr/en/) All rights reserved.
Copyright belongs to external contributor where applicable.
Creative Commons Attribution 4.0 International License applies. See https://creativecommons.org/licenses/by/4.0/ for the license conditions.