summaryrefslogtreecommitdiff
path: root/doc
diff options
context:
space:
mode:
Diffstat (limited to 'doc')
-rw-r--r--doc/libs6dns/s6dns-fmt.html9
-rw-r--r--doc/libs6dns/s6dns-message.html16
-rw-r--r--doc/libs6dns/s6dns-resolve.html10
3 files changed, 35 insertions, 0 deletions
diff --git a/doc/libs6dns/s6dns-fmt.html b/doc/libs6dns/s6dns-fmt.html
index 9534c76..247257a 100644
--- a/doc/libs6dns/s6dns-fmt.html
+++ b/doc/libs6dns/s6dns-fmt.html
@@ -89,5 +89,14 @@ the output would be more than <em>max</em> bytes, 0 ENAMETOOLONG is returned.
To avoid that, S6DNS_FMT_SRV is a suitable number of bytes to preallocate <em>s</em>.
</p>
+<p>
+<code> size_t s6dns_fmt_caa (char *s, size_t max, s6dns_message_rr_caa_t const *p) </code> <br />
+Writes into string <em>s</em> the CAA contained in *<em>p</em>: flags, then tag,
+then value, separated by spaces.
+Returns the number of bytes written, or 0 in case of failure. If
+the output would be more than <em>max</em> bytes, 0 ENAMETOOLONG is returned.
+To avoid that, S6DNS_FMT_CAA is a suitable number of bytes to preallocate <em>s</em>.
+</p>
+
</body>
</html>
diff --git a/doc/libs6dns/s6dns-message.html b/doc/libs6dns/s6dns-message.html
index 675dac5..5eb0413 100644
--- a/doc/libs6dns/s6dns-message.html
+++ b/doc/libs6dns/s6dns-message.html
@@ -79,6 +79,7 @@ also provided. The list includes:
<li> <tt>s6dns_message_rr_mx</tt> for MX RRs </li>
<li> <tt>s6dns_message_rr_soa</tt> for SOA RRs </li>
<li> <tt>s6dns_message_rr_srv</tt> for SRV RRs </li>
+ <li> <tt>s6dns_message_rr_caa</tt> for CAA RRs </li>
</ul>
<h2> Functions </h2>
@@ -167,6 +168,13 @@ Reads a SOA RR and stores it into *<em>p</em>. Returns 1 on success or 0 on fail
Reads a SRV RR and stores it into *<em>p</em>. Returns 1 on success or 0 on failure.
</p>
+<p>
+<code> int s6dns_message_get_caa (s6dns_message_rr_caa_t *p, char const *packet, unsigned int packetlen, unsigned int *pos, uint16_t rdlength) </code> <br />
+Reads a CAA RR and stores it into *<em>p</em>. Returns 1 on success or 0 on failure.
+<em>rdlength</em> is the length of the RDATA field of the record; this value is
+needed to properly parse a CAA record.
+</p>
+
<h3> High-level RR-specific parsing functions </h3>
<p>
@@ -233,6 +241,14 @@ Parses SRV RRs located in the answer section of the packet. The
containing <tt>s6dns_message_rr_srv_t</tt> structures.
</p>
+<p>
+<code> s6dns_message_func_t s6dns_message_parse_answer_caa </code> <br />
+Parses CAA RRs located in the answer section of the packet. The
+<em>data</em> argument is interpreted as a pointer to a
+<a href="//skarnet.org/software/skalibs/libstddjb/genalloc.html">genalloc</a>
+containing <tt>s6dns_message_rr_caa_t</tt> structures.
+</p>
+
<h3> High-level packet parsing </h3>
<p>
diff --git a/doc/libs6dns/s6dns-resolve.html b/doc/libs6dns/s6dns-resolve.html
index 9f0871f..69596f8 100644
--- a/doc/libs6dns/s6dns-resolve.html
+++ b/doc/libs6dns/s6dns-resolve.html
@@ -284,6 +284,16 @@ appended to the genalloc *<em>srvs</em>, which contains an array of
</p>
<p>
+<code> int s6dns_resolve_caa_g (genalloc *caas, char const *name,
+size_t len, int qualif, tain_t const *deadline) </code> <br />
+ Performs a CAA query on name <em>name</em> of length <em>len</em>, qualifying it
+iff <em>qualif</em> is nonzero. Returns -1 if an error occurs, or 0 if no answer
+can be obtained from servers, or 1 if it succeeds, in which case the domains are
+appended to the genalloc *<em>caas</em>, which contains an array of
+<tt>s6dns_message_rr_caa_t</tt>.
+</p>
+
+<p>
<code> int s6dns_resolve_txt_g (stralloc *sa, genalloc *offsets, char const *name,
unsigned int len, int qualif, tain_t const *deadline) </code> <br />
Performs an TXT query on name <em>name</em> of length <em>len</em>, qualifying it