---
name: "ldns_dnssec_name_free"
section: "3"
platform: "linux"
package: "ldns"
version: "1.9.2-1"
release: "Arch Linux 2026-11-01"
platforms: ["linux"]
url: "https://new.carta.tech/ldns_dnssec_name_free"
---

# ldns\_dnssec\_name\_free(3)

functions for ldns\_dnssec\_name

## NAME

ldns\_dnssec\_name\_new, ldns\_dnssec\_name\_new\_frm\_rr, ldns\_dnssec\_name\_free, ldns\_dnssec\_name\_name, ldns\_dnssec\_name\_set\_name, ldns\_dnssec\_name\_set\_nsec, ldns\_dnssec\_name\_cmp, ldns\_dnssec\_name\_add\_rr, ldns\_dnssec\_name\_find\_rrset, ldns\_dnssec\_name\_print - functions for ldns\_dnssec\_name

## SYNOPSIS

\#include \<stdint.h\>\
 \#include \<stdbool.h\>\

\#include \<ldns/ldns.h\>

ldns\_dnssec\_name\* ldns\_dnssec\_name\_new(void);

ldns\_dnssec\_name\* ldns\_dnssec\_name\_new\_frm\_rr(ldns\_rr \*rr);

void ldns\_dnssec\_name\_free(ldns\_dnssec\_name \*name);

ldns\_rdf\* ldns\_dnssec\_name\_name(const ldns\_dnssec\_name \*name);

void ldns\_dnssec\_name\_set\_name(ldns\_dnssec\_name \*name, ldns\_rdf \*dname);

void ldns\_dnssec\_name\_set\_nsec(ldns\_dnssec\_name \*name, ldns\_rr \*nsec);

int ldns\_dnssec\_name\_cmp(const void \*a, const void \*b);

ldns\_status ldns\_dnssec\_name\_add\_rr(ldns\_dnssec\_name \*name, ldns\_rr \*rr);

ldns\_dnssec\_rrsets\* ldns\_dnssec\_name\_find\_rrset(const ldns\_dnssec\_name \*name, ldns\_rr\_type type);

void ldns\_dnssec\_name\_print(FILE \*out, const ldns\_dnssec\_name \*name);

## DESCRIPTION

*ldns\_dnssec\_name\_new*() Create a new data structure for a dnssec name .br Returns the allocated structure

*ldns\_dnssec\_name\_new\_frm\_rr*() Create a new data structure for a dnssec name for the given RR

.br **rr**: the RR to derive properties from, and to add to the name

*ldns\_dnssec\_name\_free*() Frees the name structure and its rrs and rrsets. Individual ldns\_rr records therein are not freed

.br **name**: the structure to free

*ldns\_dnssec\_name\_name*() Returns the domain name of the given dnssec\_name structure

.br **name**: the dnssec name to get the domain name from .br Returns the domain name

*ldns\_dnssec\_name\_set\_name*() Sets the domain name of the given dnssec\_name structure

.br **name**: the dnssec name to set the domain name of .br **dname**: the domain name to set it to. This data is \*not\* copied.

*ldns\_dnssec\_name\_set\_nsec*() Sets the NSEC(3) RR of the given dnssec\_name structure

.br **name**: the dnssec name to set the domain name of .br **nsec**: the nsec rr to set it to. This data is \*not\* copied.

*ldns\_dnssec\_name\_cmp*() Compares the domain names of the two arguments in their canonical ordering.

.br **a**: The first dnssec\_name to compare .br **b**: The second dnssec\_name to compare .br Returns -1 if the domain name of a comes before that of b in canonical ordering, 1 if it is the other way around, and 0 if they are equal

*ldns\_dnssec\_name\_add\_rr*() Inserts the given rr at the right place in the current dnssec\_name No checking is done whether the name matches

.br **name**: The ldns\_dnssec\_name to add the RR to .br **rr**: The RR to add .br Returns LDNS\_STATUS\_OK on success and LDNS\_STATUS\_EQUAL\_ERR when and RR with equal ownername, class, type and rdata already exists, and an error code otherwise

*ldns\_dnssec\_name\_find\_rrset*() Find the RRset with the given type in within this name structure

.br **name**: the name to find the RRset in .br **type**: the type of the RRset to find .br Returns the RRset, or NULL if not present

*ldns\_dnssec\_name\_print*() Prints the RRs in the  dnssec name structure to the given file descriptor

.br **out**: the file descriptor to print to .br **name**: the name structure to print the contents of

## AUTHOR

The ldns team at NLnet Labs.

## REPORTING BUGS

Please report bugs to dns-team@nlnetlabs.nl or on GitHub at https://github.com/NLnetLabs/ldns/issues

## COPYRIGHT

Copyright (c) 2004 - 2006 NLnet Labs.

Licensed under the BSD License. There is NO warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.

## SEE ALSO

*ldns\_dnssec\_zone*. And **perldoc Net::DNS**, **RFC1034**, **RFC1035**, **RFC4033**, **RFC4034**  and **RFC4035**.

## REMARKS

This manpage was automatically generated from the ldns source code.
