/**
* Converts an LDNS_RDF_TYPE_A rdata element to string format and adds it to the output buffer
- * @param *rdf The rdata to convert
- * @param *output The buffer to add the data to
- * @return LDNS_STATUS_OK on success, and error status on failure
+ * \param[in] *rdf The rdata to convert
+ * \param[in] *output The buffer to add the data to
+ * \return LDNS_STATUS_OK on success, and error status on failure
*/
ldns_status ldns_rdf2buffer_str_a(ldns_buffer *output, ldns_rdf *rdf);
/**
* Converts an LDNS_RDF_TYPE_AAAA rdata element to string format and adds it to the output buffer
- * @param *rdf The rdata to convert
- * @param *output The buffer to add the data to
- * @return LDNS_STATUS_OK on success, and error status on failure
+ * \param[in] *rdf The rdata to convert
+ * \param[in] *output The buffer to add the data to
+ * \return LDNS_STATUS_OK on success, and error status on failure
*/
ldns_status ldns_rdf2buffer_str_aaaa(ldns_buffer *output, ldns_rdf *rdf);
/**
* Converts an LDNS_RDF_TYPE_STR rdata element to string format and adds it to the output buffer
- * @param *rdf The rdata to convert
- * @param *output The buffer to add the data to
- * @return LDNS_STATUS_OK on success, and error status on failure
+ * \param[in] *rdf The rdata to convert
+ * \param[in] *output The buffer to add the data to
+ * \return LDNS_STATUS_OK on success, and error status on failure
*/
ldns_status ldns_rdf2buffer_str_str(ldns_buffer *output, ldns_rdf *rdf);
/**
* Converts an LDNS_RDF_TYPE_B64 rdata element to string format and adds it to the output buffer
- * @param *rdf The rdata to convert
- * @param *output The buffer to add the data to
- * @return LDNS_STATUS_OK on success, and error status on failure
+ * \param[in] *rdf The rdata to convert
+ * \param[in] *output The buffer to add the data to
+ * \return LDNS_STATUS_OK on success, and error status on failure
*/
ldns_status ldns_rdf2buffer_str_b64(ldns_buffer *output, ldns_rdf *rdf);
/**
* Converts an LDNS_RDF_TYPE_HEX rdata element to string format and adds it to the output buffer
- * @param *rdf The rdata to convert
- * @param *output The buffer to add the data to
- * @return LDNS_STATUS_OK on success, and error status on failure
+ * \param[in] *rdf The rdata to convert
+ * \param[in] *output The buffer to add the data to
+ * \return LDNS_STATUS_OK on success, and error status on failure
*/
ldns_status ldns_rdf2buffer_str_hex(ldns_buffer *output, ldns_rdf *rdf);
/**
* Converts an LDNS_RDF_TYPE_TYPE rdata element to string format and adds it to the output buffer
- * @param *rdf The rdata to convert
- * @param *output The buffer to add the data to
- * @return LDNS_STATUS_OK on success, and error status on failure
+ * \param[in] *rdf The rdata to convert
+ * \param[in] *output The buffer to add the data to
+ * \return LDNS_STATUS_OK on success, and error status on failure
*/
ldns_status ldns_rdf2buffer_str_type(ldns_buffer *output, ldns_rdf *rdf);
/**
* Converts an LDNS_RDF_TYPE_CLASS rdata element to string format and adds it to the output buffer
- * @param *rdf The rdata to convert
- * @param *output The buffer to add the data to
- * @return LDNS_STATUS_OK on success, and error status on failure
+ * \param[in] *rdf The rdata to convert
+ * \param[in] *output The buffer to add the data to
+ * \return LDNS_STATUS_OK on success, and error status on failure
*/
ldns_status ldns_rdf2buffer_str_class(ldns_buffer *output, ldns_rdf *rdf);
/**
* Converts an LDNS_RDF_TYPE_ALG rdata element to string format and adds it to the output buffer
- * @param *rdf The rdata to convert
- * @param *output The buffer to add the data to
- * @return LDNS_STATUS_OK on success, and error status on failure
+ * \param[in] *rdf The rdata to convert
+ * \param[in] *output The buffer to add the data to
+ * \return LDNS_STATUS_OK on success, and error status on failure
*/
ldns_status ldns_rdf2buffer_str_alg(ldns_buffer *output, ldns_rdf *rdf);
/**
* Converts an LDNS_RDF_TYPE_CERT rdata element to string format and adds it to the output buffer
- * @param *rdf The rdata to convert
- * @param *output The buffer to add the data to
- * @return LDNS_STATUS_OK on success, and error status on failure
+ * \param[in] *rdf The rdata to convert
+ * \param[in] *output The buffer to add the data to
+ * \return LDNS_STATUS_OK on success, and error status on failure
*/
ldns_status ldns_rdf2buffer_str_cert(ldns_buffer *output, ldns_rdf *rdf);
/**
* Converts an LDNS_RDF_TYPE_LOC rdata element to string format and adds it to the output buffer
- * @param *rdf The rdata to convert
- * @param *output The buffer to add the data to
- * @return LDNS_STATUS_OK on success, and error status on failure
+ * \param[in] *rdf The rdata to convert
+ * \param[in] *output The buffer to add the data to
+ * \return LDNS_STATUS_OK on success, and error status on failure
*/
ldns_status ldns_rdf2buffer_str_loc(ldns_buffer *output, ldns_rdf *rdf);
/**
* Converts an LDNS_RDF_TYPE_UNKNOWN rdata element to string format and adds it to the output buffer
- * @param *rdf The rdata to convert
- * @param *output The buffer to add the data to
- * @return LDNS_STATUS_OK on success, and error status on failure
+ * \param[in] *rdf The rdata to convert
+ * \param[in] *output The buffer to add the data to
+ * \return LDNS_STATUS_OK on success, and error status on failure
*/
ldns_status ldns_rdf2buffer_str_unknown(ldns_buffer *output, ldns_rdf *rdf);
/**
* Converts an LDNS_RDF_TYPE_NSAP rdata element to string format and adds it to the output buffer
- * @param *rdf The rdata to convert
- * @param *output The buffer to add the data to
- * @return LDNS_STATUS_OK on success, and error status on failure
+ * \param[in] *rdf The rdata to convert
+ * \param[in] *output The buffer to add the data to
+ * \return LDNS_STATUS_OK on success, and error status on failure
*/
ldns_status ldns_rdf2buffer_str_nsap(ldns_buffer *output, ldns_rdf *rdf);
/**
* Converts an LDNS_RDF_TYPE_WKS rdata element to string format and adds it to the output buffer
- * @param *rdf The rdata to convert
- * @param *output The buffer to add the data to
- * @return LDNS_STATUS_OK on success, and error status on failure
+ * \param[in] *rdf The rdata to convert
+ * \param[in] *output The buffer to add the data to
+ * \return LDNS_STATUS_OK on success, and error status on failure
*/
ldns_status ldns_rdf2buffer_str_wks(ldns_buffer *output, ldns_rdf *rdf);
/**
* Converts an LDNS_RDF_TYPE_NSEC rdata element to string format and adds it to the output buffer
- * @param *rdf The rdata to convert
- * @param *output The buffer to add the data to
- * @return LDNS_STATUS_OK on success, and error status on failure
+ * \param[in] *rdf The rdata to convert
+ * \param[in] *output The buffer to add the data to
+ * \return LDNS_STATUS_OK on success, and error status on failure
*/
ldns_status ldns_rdf2buffer_str_nsec(ldns_buffer *output, ldns_rdf *rdf);
/**
* Converts an LDNS_RDF_TYPE_PERIOD rdata element to string format and adds it to the output buffer
- * @param *rdf The rdata to convert
- * @param *output The buffer to add the data to
- * @return LDNS_STATUS_OK on success, and error status on failure
+ * \param[in] *rdf The rdata to convert
+ * \param[in] *output The buffer to add the data to
+ * \return LDNS_STATUS_OK on success, and error status on failure
*/
ldns_status ldns_rdf2buffer_str_period(ldns_buffer *output, ldns_rdf *rdf);
/**
* Converts an LDNS_RDF_TYPE_TSIGTIME rdata element to string format and adds it to the output buffer
- * @param *rdf The rdata to convert
- * @param *output The buffer to add the data to
- * @return LDNS_STATUS_OK on success, and error status on failure
+ * \param[in] *rdf The rdata to convert
+ * \param[in] *output The buffer to add the data to
+ * \return LDNS_STATUS_OK on success, and error status on failure
*/
ldns_status ldns_rdf2buffer_str_tsigtime(ldns_buffer *output, ldns_rdf *rdf);
/**
* Converts an LDNS_RDF_TYPE_APL rdata element to string format and adds it to the output buffer
- * @param *rdf The rdata to convert
- * @param *output The buffer to add the data to
- * @return LDNS_STATUS_OK on success, and error status on failure
+ * \param[in] *rdf The rdata to convert
+ * \param[in] *output The buffer to add the data to
+ * \return LDNS_STATUS_OK on success, and error status on failure
*/
ldns_status ldns_rdf2buffer_str_apl(ldns_buffer *output, ldns_rdf *rdf);
/**
* Converts an LDNS_RDF_TYPE_TODO rdata element to string format and adds it to the output buffer
- * @param *rdf The rdata to convert
- * @param *output The buffer to add the data to
- * @return LDNS_STATUS_OK on success, and error status on failure
+ * \param[in] *rdf The rdata to convert
+ * \param[in] *output The buffer to add the data to
+ * \return LDNS_STATUS_OK on success, and error status on failure
*/
ldns_status ldns_rdf2buffer_str_todo(ldns_buffer *output, ldns_rdf *rdf);
/**
* Converts an LDNS_RDF_TYPE_INT16_DATA rdata element to string format and adds it to the output buffer
- * @param *rdf The rdata to convert
- * @param *output The buffer to add the data to
- * @return LDNS_STATUS_OK on success, and error status on failure
+ * \param[in] *rdf The rdata to convert
+ * \param[in] *output The buffer to add the data to
+ * \return LDNS_STATUS_OK on success, and error status on failure
*/
ldns_status ldns_rdf2buffer_str_int16_data(ldns_buffer *output, ldns_rdf *rdf);
/**
* Converts an LDNS_RDF_TYPE_IPSECKEY rdata element to string format and adds it to the output buffer
- * @param *rdf The rdata to convert
- * @param *output The buffer to add the data to
- * @return LDNS_STATUS_OK on success, and error status on failure
+ * \param[in] *rdf The rdata to convert
+ * \param[in] *output The buffer to add the data to
+ * \return LDNS_STATUS_OK on success, and error status on failure
*/
ldns_status ldns_rdf2buffer_str_ipseckey(ldns_buffer *output, ldns_rdf *rdf);
/**
* Converts an LDNS_RDF_TYPE_TSIG rdata element to string format and adds it to the output buffer
- * @param *rdf The rdata to convert
- * @param *output The buffer to add the data to
- * @return LDNS_STATUS_OK on success, and error status on failure
+ * \param[in] *rdf The rdata to convert
+ * \param[in] *output The buffer to add the data to
+ * \return LDNS_STATUS_OK on success, and error status on failure
*/
ldns_status ldns_rdf2buffer_str_tsig(ldns_buffer *output, ldns_rdf *rdf);
* Converts the data in the rdata field to presentation
* format (as char *) and appends it to the given buffer
*
- * @param output pointer to the buffer to append the data to
- * @param rdf the pointer to the rdafa field containing the data
- * @return status
+ * \param[in] output pointer to the buffer to append the data to
+ * \param[in] rdf the pointer to the rdafa field containing the data
+ * \return status
*/
ldns_status ldns_rdf2buffer_str(ldns_buffer *output, ldns_rdf *rdf);
* Converts the data in the resource record to presentation
* format (as char *) and appends it to the given buffer
*
- * @param output pointer to the buffer to append the data to
- * @param rr the pointer to the rr field to convert
- * @return status
+ * \param[in] output pointer to the buffer to append the data to
+ * \param[in] rr the pointer to the rr field to convert
+ * \return status
*/
ldns_status ldns_rr2buffer_str(ldns_buffer *output, ldns_rr *rr);
* Converts the data in the DNS packet to presentation
* format (as char *) and appends it to the given buffer
*
- * @param output pointer to the buffer to append the data to
- * @param pkt the pointer to the packet to convert
- * @return status
+ * \param[in] output pointer to the buffer to append the data to
+ * \param[in] pkt the pointer to the packet to convert
+ * \return status
*/
ldns_status ldns_pkt2buffer_str(ldns_buffer *output, ldns_pkt *pkt);
* Converts the data in the int16 typed rdata field to presentation
* format (as char *) and appends it to the given buffer
*
- * @param output pointer to the buffer to append the data to
- * @param rdf the pointer to the rdafa field containing the data
- * @return status
+ * \param[in] output pointer to the buffer to append the data to
+ * \param[in] rdf the pointer to the rdafa field containing the data
+ * \return status
*/
ldns_status ldns_rdf2buffer_str_int16(ldns_buffer *output, ldns_rdf *rdf);
* returns that as a char *.
* Remeber to free it
*
- * @param rdf The rdata field to convert
- * @return null terminated char * data, or NULL on error
+ * \param[in] rdf The rdata field to convert
+ * \return null terminated char * data, or NULL on error
*/
char *ldns_rdf2str(ldns_rdf *rdf);
* returns that as a char *.
* Remeber to free it
*
- * @param rr The rdata field to convert
- * @return null terminated char * data, or NULL on error
+ * \param[in] rr The rdata field to convert
+ * \return null terminated char * data, or NULL on error
*/
char *ldns_rr2str(ldns_rr *rr);
* returns that as a char *.
* Remeber to free it
*
- * @param pkt The rdata field to convert
- * @return null terminated char * data, or NULL on error
+ * \param[in] pkt The rdata field to convert
+ * \return null terminated char * data, or NULL on error
*/
char *ldns_pkt2str(ldns_pkt *pkt);
* Returns the data in the buffer as a null terminated char * string
* Buffer data must be char * type
*
- * @param buffer buffer containing char * data
- * @return null terminated char * data, or NULL on error
+ * \param[in] buffer buffer containing char * data
+ * \return null terminated char * data, or NULL on error
*/
char *buffer2str(ldns_buffer *buffer);
* Prints the data in the rdata field to the given file stream
* (in presentation format)
*
- * @param output the file stream to print to
- * @param rdf the rdata field to print
+ * \param[in] output the file stream to print to
+ * \param[in] rdf the rdata field to print
+ * \return void
*/
void ldns_rdf_print(FILE *output, ldns_rdf *rdf);
* Prints the data in the resource record to the given file stream
* (in presentation format)
*
- * @param output the file stream to print to
- * @param rr the resource record to print
+ * \param[in] output the file stream to print to
+ * \param[in] rr the resource record to print
+ * \return void
*/
void ldns_rr_print(FILE *output, ldns_rr *rr);
* Prints the data in the DNS packet to the given file stream
* (in presentation format)
*
- * @param output the file stream to print to
- * @param pkt the packet to print
+ * \param[in] output the file stream to print to
+ * \param[in] pkt the packet to print
+ * \return void
*/
void ldns_pkt_print(FILE *output, ldns_pkt *pkt);
void ldns_resolver_print(FILE *, ldns_resolver *);
-
#endif
#define ARCOUNT_OFF 10
#define ARCOUNT(wirebuf) (read_uint16(wirebuf+ARCOUNT_OFF))
-
-
/**
* Converts the data on the uint8_t bytearray (in wire format) to a DNS packet
* This function will initialize and allocate memory space for the packet
* structure
*
- * @param packet pointer to the structure to hold the packet
- * @param data pointer to the buffer with the data
- * @param len the length of the data buffer (in bytes)
- * @return LDNS_STATUS_OK if everything succeeds, error otherwise
+ * \param[in] packet pointer to the structure to hold the packet
+ * \param[in] data pointer to the buffer with the data
+ * \param[in] len the length of the data buffer (in bytes)
+ * \return LDNS_STATUS_OK if everything succeeds, error otherwise
*/
ldns_status ldns_wire2pkt(ldns_pkt **packet, const uint8_t *data, size_t len);
* structure
* The length of the wiredata of this rdf is added to the *pos value.
*
- * @param dname pointer to the structure to hold the rdata value
- * @param wire pointer to the buffer with the data
- * @param max the length of the data buffer (in bytes)
- * @param pos the position of the rdf in the buffer (ie. the number of bytes
+ * \param[in] dname pointer to the structure to hold the rdata value
+ * \param[in] wire pointer to the buffer with the data
+ * \param[in] max the length of the data buffer (in bytes)
+ * \param[in] pos the position of the rdf in the buffer (ie. the number of bytes
* from the start of the buffer)
- * @return LDNS_STATUS_OK if everything succeeds, error otherwise
+ * \return LDNS_STATUS_OK if everything succeeds, error otherwise
*/
-ldns_status ldns_wire2dname(ldns_rdf **dname, const uint8_t *wire, size_t max,
- size_t *pos);
-
+ldns_status ldns_wire2dname(ldns_rdf **dname, const uint8_t *wire, size_t max, size_t *pos);
/**
* Converts the data on the uint8_t bytearray (in wire format) to a DNS
* structure
* The length of the wiredata of this rdf is added to the *pos value.
*
- * @param rr pointer to the ldns_rr structure to hold the rdata value
- * @param wire pointer to the buffer with the data
- * @param max the length of the data buffer (in bytes)
- * @param pos the position of the rdf in the buffer (ie. the number of bytes
+ * \param[in] rr pointer to the ldns_rr structure to hold the rdata value
+ * \param[in]wire pointer to the buffer with the data
+ * \param[in] max the length of the data buffer (in bytes)
+ * \param[in] pos the position of the rdf in the buffer (ie. the number of bytes
* from the start of the buffer)
- * @return LDNS_STATUS_OK if everything succeeds, error otherwise
+ * \return LDNS_STATUS_OK if everything succeeds, error otherwise
*/
ldns_status ldns_wire2rdf(ldns_rr *rr, const uint8_t *wire, size_t max, size_t *pos);
* structure
* The length of the wiredata of this rr is added to the *pos value.
*
- * @param rr pointer to the structure to hold the rdata value
- * @param wire pointer to the buffer with the data
- * @param max the length of the data buffer (in bytes)
- * @param pos the position of the rr in the buffer (ie. the number of bytes
+ * \param[in] rr pointer to the structure to hold the rdata value
+ * \param[in] wire pointer to the buffer with the data
+ * \param[in] max the length of the data buffer (in bytes)
+ * \param[in] pos the position of the rr in the buffer (ie. the number of bytes
* from the start of the buffer)
- * @param section the section in the packet the rr is meant for
- * @return LDNS_STATUS_OK if everything succeeds, error otherwise
+ * \param[in] section the section in the packet the rr is meant for
+ * \return LDNS_STATUS_OK if everything succeeds, error otherwise
*/
-ldns_status ldns_wire2rr(ldns_rr **rr, const uint8_t *wire, size_t max,
- size_t *pos, ldns_pkt_section section);
-
-#endif
+ldns_status ldns_wire2rr(ldns_rr **rr, const uint8_t *wire, size_t max, size_t *pos, ldns_pkt_section section);
+#endif /* _LDNS_WIRE2HOST_H */