2
0
mirror of https://gitlab.isc.org/isc-projects/bind9 synced 2025-08-28 13:08:06 +00:00

29 Commits

Author SHA1 Message Date
Petr Špaček
2ee3f4e6c8
Update NSEC3 guidance to match draft-ietf-dnsop-nsec3-guidance-10
https://datatracker.ietf.org/doc/html/draft-ietf-dnsop-nsec3-guidance-10
is on it's way to become RFC, so let's update our recommendations in the
docs to be in line with it.
2022-06-15 17:53:33 +02:00
Evan Hunt
83f9466d61 specify time format in the documentation for 'rdnc dnssec -checkds'
also clarified the writing in the surrounding paragraph.
2022-05-18 15:24:54 -07:00
Mark Andrews
22c2402393 Fix typo, withdraw should be withdrawn 2022-05-02 12:50:46 +10:00
Petr Špaček
bbb24264bb
Use unique program + option names for link anchors to support Sphinx 1.8.5
Sphinx "standard domain" provides directive types ".. program::" and
".. option::" to create link anchor for a program name + option combination.
These can be referenced using :ref:`program option` syntax.

The problem is that Sphinx 1.8.5 (e.g. in Ubuntu 18.04) generates
conflicting link targets if a page contains two option directives
starting with the same word, e.g.:

.. program:: dnssec-settime
.. option:: -P date
.. option:: -P ds date

The reason is that option directive consumes only first word as "option
name" (-P) and all the rest is considered "option argument" (date, ds
date). Newer versions of Sphinx (e.g. 4.5.0) handle this by creating
numbered link anchors, but older versions warn and BIND build system
turns the warning into a hard error.

To handle that we use method recommended by Sphinx maintainer:
https://github.com/sphinx-doc/sphinx/issues/10218#issuecomment-1059925508
As a bonus it provides more accurate link anchors for sub-options.

Alternatives considered:
- Replacing standard domain definition of .. option - causes more
  problems, see BIND issue #3294.
- Removing hyperlinks for options - that would be a step back.

Fixes: #3295
2022-04-25 14:27:34 +02:00
Michał Kępień
e80ce6cfe2 Regenerate man pages with Sphinx 4.5.0
The Debian 11 (bullseye) Docker image, which GitLab CI uses for building
documentation, currently contains the following package versions:

  - Sphinx 4.5.0
  - sphinx-rtd-theme 1.0.0
  - docutils 0.17.1

Regenerate the man pages to match contents produced in a Sphinx
environment using the above package versions.  This is necessary to
prevent the "docs" GitLab CI job from failing.
2022-04-22 13:05:10 +02:00
Petr Špaček
1d4d008fc9
Add internal hyperlinks to See Also section of manual pages
Replace :manpage: with :iscman: to generate internal hyperlinks. That
way reader can use links even when offline, and jumps to man pages
for the same version.

Formerly HTML version of man pages did not have links in See Also
section because :manpage: role in Sphinx can generate only external
hyperlinks - and we do not have that enabled.
Enabling the Sphinx :manpage: linking could reliably create hyperlinks
only to external URLs, but that would take users to another version
of docs.

Generated by:
    find bin -name '*.rst' | xargs sed -i -e 's/:manpage:`\([^(]\+\)(\([0-9]\))`/:iscman:`\1(\2) <\1>`/g'
+ hand-edit to revert change for mmencode reference which is
  not provided in our source tree.
2022-03-14 10:46:36 +01:00
Petr Špaček
53a5776025
Hyperlink program names to their manual pages
Use the new role :iscman: to replace all occurences or ``binary``
with :iscman:`binary`, creating a hyperlink to the manual page.

Generated using:
    find bin -name *.rst | xargs fgrep --files-with-matches '.. iscman' | xargs -I{} -n1 basename {} .rst > /tmp/progs
    for PROG in $(cat /tmp/progs); do find -name '*.rst' | xargs sed -i -e "s/\`\`$PROG\`\`/:iscman:\`$PROG\`/g"; done

Additional hand-edits were done mainly around filter-aaaa and
filter-a which are program names and and option names at the
same time. Couple more edits was neede to fix .rst syntax broken by
automatic replacement.
2022-03-14 10:46:36 +01:00
Tony Finch
ccc6378355
More man page option hyperlinks
The dig man page wanted -h option hyperlink and anchor, and there
were a couple of missing cross-references in the rndc man page.
2022-03-14 10:46:36 +01:00
Petr Špaček
a85df3ff9c
Add hyperlinks from program options to definition in man pages
Side-effect of hyperlinking is that typos in program and option names
are now detected by Sphinx.

Candidate -options were detected using:
    find -name *.rst | xargs grep '``-[^`]'
and then modified from ``-o`` to :option:`-o` using regex
    s/``\(-[^`]\+\)``/:option:`\1`/
+ manual modifications where necessary.

Non-hyphenated options were detected by looking at context around
program names:
    find bin -name *.rst | xargs -I{} -n1 basename {} .rst | sort -u
and grepping for program name with trailing whitespace.

Stand-alone program names like ``named`` are not hyperlinked in this
commit.
2022-03-14 10:46:36 +01:00
Petr Špaček
ec30944aa4
Denote all command line options using semantic markup (.. option::)
The markup allows referencing individual options, and also makes them
more legible (no more thin red text on gray background).

Most of the work was done using regexes:
    s/^``-\(.*\)``$/.. option:: -\1\r/
    s/^``+\(.*\)``$/.. option:: +\1\r/
on bin/**/*.rst files along with visual inspection and hand-edits,
mostly for positional arguments.

Regex for rndc.rst:
    s/^``\(.*\)``/.. option:: \1\r/
+ hand edits to remove extra asterisk and whitespace here and there.
2022-03-14 10:46:32 +01:00
Ondřej Surý
b42681c4e9 Use compile-time paths in the manual pages
Replace the hard-coded paths for various BIND 9 files (configuration,
pid, etc.) in the man pages and ARM with compile-time values using the
sphinx-build replace system.

This is more complicated, because the restructured text specification
doesn't allow |substitions| inside ``code-blocks``, so for each specific
file we had to create own substition which is sub-optimal, but it is
only way how to do this without adding Sphinx extension.
2022-02-10 16:50:22 +01:00
Michal Nowak
befd654e00
Update copyrights to 2022 2022-01-03 10:53:28 +01:00
Mark Andrews
65f6d8af75 Update the description of fetches-per-zone counters 2021-11-30 11:10:04 +00:00
Matthijs Mekking
380ba47329 Update rndc serve-stale status output
Explicitly show if cache is enabled or disabled, and if answering stale
data is enabled or disabled.
2021-10-25 10:42:10 +02:00
Matthijs Mekking
af17ca9704 Replace "master/slave" terms in documentation
Replace those terms with the preferred "primary/secondary" keywords.
2021-10-12 13:09:04 -07:00
Michał Kępień
ffd1e71fdf Regenerate man pages with docutils 0.17.1
The Debian 10 (buster) Docker image, which GitLab CI uses for building
documentation, currently contains the following package versions:

  - Sphinx 4.2.0
  - sphinx-rtd-theme 1.0.0
  - docutils 0.17.1

Regenerate the man pages to match contents produced in a Sphinx
environment using the above package versions.  This is necessary to
prevent the "docs" GitLab CI job from failing.
2021-09-16 10:57:04 +02:00
Michał Kępień
6a2daddf5b Regenerate man pages with docutils 0.16
Commit bdb777b2a2e079ce25f567a316e74436f0584029 updated the man pages
to contents produced using:

  - Sphinx 4.0.2
  - sphinx-rtd-theme 0.5.2
  - docutils 0.17.1

However, sphinx-rtd-theme 0.5.2 is incompatible with versions 0.17+ of
the docutils package.  This problem was addressed in the Docker image
used for building man pages by downgrading the docutils package to
version 0.16.

Regenerate the man pages again, this time using:

  - Sphinx 4.0.2
  - sphinx-rtd-theme 0.5.2
  - docutils 0.16

This is necessary to prevent the "docs" GitLab CI job from failing.
2021-05-31 11:22:52 +02:00
Michał Kępień
bdb777b2a2 Regenerate man pages with Sphinx 4.0.2
The man pages produced by Sphinx 4.0.2 are slightly different than those
produced by Sphinx 3.5.4.  As Sphinx 4.0.2 is now used in GitLab CI,
update all doc/man/*in files so that they reflect what that version of
Sphinx produces, in order to prevent GitLab CI job failures.
2021-05-21 10:29:02 +02:00
Mark Andrews
205d1bb762 Remove spurious $ and \ in addzone example 2021-05-04 02:18:34 +00:00
Michal Nowak
358c133ee2 Update copyright date in man pages 2021-01-11 12:27:17 +01:00
Michał Kępień
43beb080fc Minor documentation formatting tweaks 2020-10-22 08:54:32 +02:00
Matthijs Mekking
e826facadb Add rndc dnssec -rollover command
This command is similar in arguments as -checkds so refactor the
'named_server_dnssec' function accordingly.  The only difference
are that:

- It does not take a "publish" or "withdrawn" argument.
- It requires the key id to be set (add a check to make sure).

Add tests that will trigger rollover immediately and one that
schedules a test in the future.
2020-10-05 10:53:45 +02:00
Matthijs Mekking
8beda7d2ea Add -expired flag to rndc dumpdb command
This flag is the same as -cache, but will use a different style format
that will also print expired entries (awaiting cleanup) from the cache.
2020-09-23 16:08:29 +02:00
Matthijs Mekking
46fcd927e7 rndc dnssec -checkds set algorithm
In the rare case that you have multiple keys acting as KSK and that
have the same keytag, you can now set the algorithm when calling
'-checkds'.
2020-08-07 11:26:09 +02:00
Matthijs Mekking
04d8fc0143 Implement 'rndc dnssec -checkds'
Add a new 'rndc' command 'dnssec -checkds' that allows the user to
signal named that a new DS record has been seen published in the
parent, or that an existing DS record has been withdrawn from the
parent.

Upon the 'checkds' request, 'named' will write out the new state for
the key, updating the 'DSPublish' or 'DSRemoved' timing metadata.

This replaces the "parent-registration-delay" configuration option,
this was unreliable because it was purely time based (if the user
did not actually submit the new DS to the parent for example, this
could result in an invalid DNSSEC state).

Because we cannot rely on the parent registration delay for state
transition, we need to replace it with a different guard. Instead,
if a key wants its DS state to be moved to RUMOURED, the "DSPublish"
time must be set and must not be in the future. If a key wants its
DS state to be moved to UNRETENTIVE, the "DSRemoved" time must be set
and must not be in the future.

By default, with '-checkds' you set the time that the DS has been
published or withdrawn to now, but you can set a different time with
'-when'. If there is only one KSK for the zone, that key has its
DS state moved to RUMOURED. If there are multiple keys for the zone,
specify the right key with '-key'.
2020-08-07 11:26:09 +02:00
Ondřej Surý
9ab86d0da2 Update the generated files after the source manpages update 2020-07-02 10:53:16 +02:00
Matthijs Mekking
e273b95a8b Update notes, changes for #1612 2020-06-30 09:51:22 +02:00
Matthijs Mekking
e1ba1bea7c Implement dummy 'rndc dnssec -status' command
Add the code and documentation required to provide DNSSEC signing
status through rndc.  This does not yet show any useful information,
just provide the command that will output some dummy string.
2020-06-30 09:51:04 +02:00
Ondřej Surý
9fb6d11abb Convert the documentation to Sphinx documentation format
The ARM and the manpages have been converted into Sphinx documentation
format.

Sphinx uses reStructuredText as its markup language, and many of its
strengths come from the power and straightforwardness of
reStructuredText and its parsing and translating suite, the Docutils.
2020-05-07 16:02:56 +02:00