diff options
author | Bob Halley <halley@dnspython.org> | 2022-11-27 17:42:31 -0800 |
---|---|---|
committer | Bob Halley <halley@dnspython.org> | 2022-11-27 17:42:31 -0800 |
commit | 0d6f2fab3827cb8cfe74babbea64288049cde699 (patch) | |
tree | 6f902442bf8b7d46d19bb7823664ecf475076fda | |
parent | 2441f606ce1bb6b4e49428ca6ba155166fcd070a (diff) | |
download | dnspython-0d6f2fab3827cb8cfe74babbea64288049cde699.tar.gz |
Basic SVCB and HTTPS doco.
-rw-r--r-- | dns/rdtypes/svcbbase.py | 2 | ||||
-rw-r--r-- | doc/rdata-subclasses.rst | 112 |
2 files changed, 113 insertions, 1 deletions
diff --git a/dns/rdtypes/svcbbase.py b/dns/rdtypes/svcbbase.py index b7e7a85..8d6fb1c 100644 --- a/dns/rdtypes/svcbbase.py +++ b/dns/rdtypes/svcbbase.py @@ -429,7 +429,7 @@ class SVCBBase(dns.rdata.Rdata): """Base class for SVCB-like records""" - # see: draft-ietf-dnsop-svcb-https-01 + # see: draft-ietf-dnsop-svcb-https-11 __slots__ = ["priority", "target", "params"] diff --git a/doc/rdata-subclasses.rst b/doc/rdata-subclasses.rst index 36056d3..5f82647 100644 --- a/doc/rdata-subclasses.rst +++ b/doc/rdata-subclasses.rst @@ -3,6 +3,11 @@ Rdata Subclass Reference ======================== +.. _rdata-subclasses-any: + +Universal Types +--------------- + .. autoclass:: dns.rdata.GenericRdata .. attribute:: data @@ -617,6 +622,11 @@ Rdata Subclass Reference A ``bytes``, the PSDN address. +.. _rdata-subclasses-in: + +Types specific to class IN +-------------------------- + .. autoclass:: dns.rdtypes.IN.A.A :members: @@ -665,6 +675,23 @@ Rdata Subclass Reference A ``bytes``, the data (the content of the RR is opaque as far as the DNS is concerned). +.. autoclass:: dns.rdtypes.IN.HTTPS.HTTPS + :members: + + .. attribute:: priority + + An ``int``, the unsigned 16-bit integer priority. + + .. attribute:: target + + A ``dns.name.Name``, the target name. + + .. attribute:: params + + A ``dict[dns.rdtypes.svcbbase.ParamKey, dns.rdtypes.svcbbase.Param]``, the + parameters. See the dedicated section :ref:`svcb-https-params` below for + more information on the parameter types. + .. autoclass:: dns.rdtypes.IN.IPSECKEY.IPSECKEY :members: @@ -779,6 +806,23 @@ Rdata Subclass Reference A ``dns.name.Name``, the target host. +.. autoclass:: dns.rdtypes.IN.SVCB.SVCB + :members: + + .. attribute:: priority + + An ``int``, the unsigned 16-bit integer priority. + + .. attribute:: target + + A ``dns.name.Name``, the target name. + + .. attribute:: params + + A ``dict[dns.rdtypes.svcbbase.ParamKey, dns.rdtypes.svcbbase.Param]``, the + parameters. See the dedicated section :ref:`svcb-https-params` below for + more information on the parameter types. + .. autoclass:: dns.rdtypes.IN.WKS.WKS :members: @@ -793,3 +837,71 @@ Rdata Subclass Reference .. attribute:: bitmap A ``bytes``, the bitmap. + +.. _svcb-https-params: + +SVCB and HTTPS Parameter Classes +-------------------------------- + +.. autoclass:: dns.rdtypes.svcbbase.ParamKey + :members: + + .. attribute:: ALPN + .. attribute:: ECH + .. attribute:: IPV4HINT + .. attribute:: IPV6HINT + .. attribute:: MANDATORY + .. attribute:: NO_DEFAULT_ALPN + .. attribute:: PORT + +.. autoclass:: dns.rdtypes.svcbbase.Param + :members: + +.. autoclass:: dns.rdtypes.svcbbase.GenericParam + :members: + + .. attribute:: value + + A ``bytes``, the value of the parameter. + +.. autoclass:: dns.rdtypes.svcbbase.MandatoryParam + :members: + + .. attribute:: keys + + A tuple of ``ParamKey``, the keys which are mandatory. + +.. autoclass:: dns.rdtypes.svcbbase.ALPNParam + :members: + + .. attribute:: ids + + A tuple of ``bytes`` values, the APLN ids. + +.. autoclass:: dns.rdtypes.svcbbase.PortParam + :members: + + .. attribute:: port + + An ``int``, the unsigned 16-bit integer port. + +.. autoclass:: dns.rdtypes.svcbbase.IPv4HintParam + :members: + + .. attribute:: addresses + + A tuple of ``string``, which each string is an IPv4 address. + +.. autoclass:: dns.rdtypes.svcbbase.IPv6HintParam + :members: + + .. attribute:: addresses + + A tuple of ``string``, which each string is an IPv6 address. + +.. autoclass:: dns.rdtypes.svcbbase.ECHParam + :members: + + .. attribute:: ech + + A ``bytes``. |