1ldns(3)                    Library Functions Manual                    ldns(3)
2
3
4

NAME

6       ldns_pkt_set_flags,  ldns_pkt_set_id, ldns_pkt_set_qr, ldns_pkt_set_aa,
7       ldns_pkt_set_tc,  ldns_pkt_set_rd,  ldns_pkt_set_cd,   ldns_pkt_set_ra,
8       ldns_pkt_set_ad,        ldns_pkt_set_opcode,        ldns_pkt_set_rcode,
9       ldns_pkt_set_qdcount,    ldns_pkt_set_ancount,    ldns_pkt_set_nscount,
10       ldns_pkt_set_arcount,  ldns_pkt_set_answerfrom, ldns_pkt_set_querytime,
11       ldns_pkt_set_size, ldns_pkt_set_section_count, ldns_pkt_set_tsig
12
13

SYNOPSIS

15       #include <stdint.h>
16       #include <stdbool.h>
17
18       #include <ldns/ldns.h>
19
20       bool ldns_pkt_set_flags(ldns_pkt *pkt, uint16_t flags);
21
22       void ldns_pkt_set_id(ldns_pkt *p, uint16_t id);
23
24       void ldns_pkt_set_qr(ldns_pkt *p, bool b);
25
26       void ldns_pkt_set_aa(ldns_pkt *p, bool b);
27
28       void ldns_pkt_set_tc(ldns_pkt *p, bool b);
29
30       void ldns_pkt_set_rd(ldns_pkt *p, bool b);
31
32       void ldns_pkt_set_cd(ldns_pkt *p, bool b);
33
34       void ldns_pkt_set_ra(ldns_pkt *p, bool b);
35
36       void ldns_pkt_set_ad(ldns_pkt *p, bool b);
37
38       void ldns_pkt_set_opcode(ldns_pkt *p, ldns_pkt_opcode c);
39
40       void ldns_pkt_set_rcode(ldns_pkt *p, uint8_t c);
41
42       void ldns_pkt_set_qdcount(ldns_pkt *p, uint16_t c);
43
44       void ldns_pkt_set_ancount(ldns_pkt *p, uint16_t c);
45
46       void ldns_pkt_set_nscount(ldns_pkt *p, uint16_t c);
47
48       void ldns_pkt_set_arcount(ldns_pkt *p, uint16_t c);
49
50       void ldns_pkt_set_answerfrom(ldns_pkt *p, ldns_rdf *r);
51
52       void ldns_pkt_set_querytime(ldns_pkt *p, uint32_t t);
53
54       void ldns_pkt_set_size(ldns_pkt *p, size_t s);
55
56       void  ldns_pkt_set_section_count(ldns_pkt   *p,   ldns_pkt_section   s,
57       uint16_t x);
58
59       void ldns_pkt_set_tsig(ldns_pkt *p, ldns_rr *t);
60

DESCRIPTION

62       ldns_pkt_set_flags() sets the flags in a packet.
63              pkt: the packet to operate on
64              flags: ORed values: LDNS_QR| LDNS_AR for instance
65              Returns true on success otherwise false
66
67       ldns_pkt_set_id() Set the packet's id
68              p: the packet
69              id: the id to set
70
71       ldns_pkt_set_qr() Set the packet's qr bit
72              p: the packet
73              b: the value to set (boolean)
74
75       ldns_pkt_set_aa() Set the packet's aa bit
76              p: the packet
77              b: the value to set (boolean)
78
79       ldns_pkt_set_tc() Set the packet's tc bit
80              p: the packet
81              b: the value to set (boolean)
82
83       ldns_pkt_set_rd() Set the packet's rd bit
84              p: the packet
85              b: the value to set (boolean)
86
87       ldns_pkt_set_cd() Set the packet's cd bit
88              p: the packet
89              b: the value to set (boolean)
90
91       ldns_pkt_set_ra() Set the packet's ra bit
92              p: the packet
93              b: the value to set (boolean)
94
95       ldns_pkt_set_ad() Set the packet's ad bit
96              p: the packet
97              b: the value to set (boolean)
98
99       ldns_pkt_set_opcode() Set the packet's opcode
100              p: the packet
101              c: the opcode
102
103       ldns_pkt_set_rcode() Set the packet's respons code
104              p: the packet
105              c: the rcode
106
107       ldns_pkt_set_qdcount() Set the packet's qd count
108              p: the packet
109              c: the count
110
111       ldns_pkt_set_ancount() Set the packet's an count
112              p: the packet
113              c: the count
114
115       ldns_pkt_set_nscount() Set the packet's ns count
116              p: the packet
117              c: the count
118
119       ldns_pkt_set_arcount() Set the packet's arcount
120              p: the packet
121              c: the count
122
123       ldns_pkt_set_answerfrom() Set the packet's answering server
124              p: the packet
125              r: the address
126
127       ldns_pkt_set_querytime() Set the packet's query time
128              p: the packet
129              t: the querytime in msec
130
131       ldns_pkt_set_size() Set the packet's size
132              p: the packet
133              s: the size
134
135       ldns_pkt_set_section_count() Set a packet's section count to x
136              p: the packet
137              s: the section
138              x: the section count
139
140       ldns_pkt_set_tsig() Set the packet's tsig rr
141              p: the packet
142              t: the tsig rr
143

AUTHOR

145       The  ldns  team  at  NLnet Labs. Which consists out of Jelte Jansen and
146       Miek Gieben.
147
148

REPORTING BUGS

150       Please report bugs to ldns-team@nlnetlabs.nl  or  in  our  bugzilla  at
151       http://www.nlnetlabs.nl/bugs/index.html
152
153
155       Copyright (c) 2004 - 2006 NLnet Labs.
156
157       Licensed under the BSD License. There is NO warranty; not even for MER‐
158       CHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
159
160

SEE ALSO

162       ldns_pkt .  And perldoc Net::DNS, RFC1034,  RFC1035,  RFC4033,  RFC4034
163       and RFC4035.
164

REMARKS

166       This manpage was automaticly generated from the ldns source code by use
167       of Doxygen and some perl.
168
169
170
171                                  30 May 2006                          ldns(3)
Impressum