]> git.ipfire.org Git - thirdparty/pdns.git/commitdiff
dnsdist docs: copy newCAFromRaw from pdns
authorKarel Bilek <kb@karelbilek.com>
Tue, 4 Mar 2025 07:52:44 +0000 (08:52 +0100)
committerKarel Bilek <karel.bilek@cdn77.com>
Tue, 4 Mar 2025 11:25:20 +0000 (12:25 +0100)
pdns/dnsdistdist/docs/reference/comboaddress.rst

index 79d05ad99debe92813598494ea971c22d2d4d0b0..704c5f40edb2f2709b458e664e94d269f20a48a7 100644 (file)
@@ -12,6 +12,14 @@ ComboAddresses can be IPv4 or IPv6, and unless you want to know, you don't need
 
   :param string address: The IP address, with optional port, to represent.
 
+.. function:: newCAFromRaw(rawaddress[, port]) -> ComboAddress
+
+  Returns a new :class:`ComboAddress` object based on the 4- or 16-octet string.
+  For example, ``newCAFromRaw('ABCD')`` makes a ``ComboAddress`` object holding the IP ``65.66.67.68``, because those are the ASCII values for those four letters.
+
+  :param string rawaddress: The IPv4 of IPv6 address as a 4/16 octet string
+  :param int port: The optional port number
+
 .. class:: ComboAddress
 
   A ``ComboAddress`` represents an IP address with possibly a port number.