]> CyberLeo.Net >> Repos - FreeBSD/FreeBSD.git/blob - sys/netinet6/ip6_var.h
stand: TARGET_ARCH is spelled MACHINE_ARCH in Makefiles
[FreeBSD/FreeBSD.git] / sys / netinet6 / ip6_var.h
1 /*-
2  * SPDX-License-Identifier: BSD-3-Clause
3  *
4  * Copyright (C) 1995, 1996, 1997, and 1998 WIDE Project.
5  * All rights reserved.
6  *
7  * Redistribution and use in source and binary forms, with or without
8  * modification, are permitted provided that the following conditions
9  * are met:
10  * 1. Redistributions of source code must retain the above copyright
11  *    notice, this list of conditions and the following disclaimer.
12  * 2. Redistributions in binary form must reproduce the above copyright
13  *    notice, this list of conditions and the following disclaimer in the
14  *    documentation and/or other materials provided with the distribution.
15  * 3. Neither the name of the project nor the names of its contributors
16  *    may be used to endorse or promote products derived from this software
17  *    without specific prior written permission.
18  *
19  * THIS SOFTWARE IS PROVIDED BY THE PROJECT AND CONTRIBUTORS ``AS IS'' AND
20  * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
21  * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
22  * ARE DISCLAIMED.  IN NO EVENT SHALL THE PROJECT OR CONTRIBUTORS BE LIABLE
23  * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
24  * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
25  * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
26  * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
27  * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
28  * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
29  * SUCH DAMAGE.
30  *
31  *      $KAME: ip6_var.h,v 1.62 2001/05/03 14:51:48 itojun Exp $
32  */
33
34 /*-
35  * Copyright (c) 1982, 1986, 1993
36  *      The Regents of the University of California.  All rights reserved.
37  *
38  * Redistribution and use in source and binary forms, with or without
39  * modification, are permitted provided that the following conditions
40  * are met:
41  * 1. Redistributions of source code must retain the above copyright
42  *    notice, this list of conditions and the following disclaimer.
43  * 2. Redistributions in binary form must reproduce the above copyright
44  *    notice, this list of conditions and the following disclaimer in the
45  *    documentation and/or other materials provided with the distribution.
46  * 3. Neither the name of the University nor the names of its contributors
47  *    may be used to endorse or promote products derived from this software
48  *    without specific prior written permission.
49  *
50  * THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
51  * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
52  * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
53  * ARE DISCLAIMED.  IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
54  * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
55  * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
56  * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
57  * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
58  * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
59  * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
60  * SUCH DAMAGE.
61  *
62  *      @(#)ip_var.h    8.1 (Berkeley) 6/10/93
63  * $FreeBSD$
64  */
65
66 #ifndef _NETINET6_IP6_VAR_H_
67 #define _NETINET6_IP6_VAR_H_
68
69 #include <sys/epoch.h>
70
71 /*
72  * IP6 reassembly queue structure.  Each fragment
73  * being reassembled is attached to one of these structures.
74  */
75 struct  ip6q {
76         struct ip6asfrag *ip6q_down;
77         struct ip6asfrag *ip6q_up;
78         u_int32_t       ip6q_ident;
79         u_int8_t        ip6q_nxt;
80         u_int8_t        ip6q_ecn;
81         u_int8_t        ip6q_ttl;
82         struct in6_addr ip6q_src, ip6q_dst;
83         struct ip6q     *ip6q_next;
84         struct ip6q     *ip6q_prev;
85         int             ip6q_unfrglen;  /* len of unfragmentable part */
86 #ifdef notyet
87         u_char          *ip6q_nxtp;
88 #endif
89         int             ip6q_nfrag;     /* # of fragments */
90         struct label    *ip6q_label;
91 };
92
93 struct  ip6asfrag {
94         struct ip6asfrag *ip6af_down;
95         struct ip6asfrag *ip6af_up;
96         struct mbuf     *ip6af_m;
97         int             ip6af_offset;   /* offset in ip6af_m to next header */
98         int             ip6af_frglen;   /* fragmentable part length */
99         int             ip6af_off;      /* fragment offset */
100         u_int16_t       ip6af_mff;      /* more fragment bit in frag off */
101 };
102
103 #define IP6_REASS_MBUF(ip6af) (*(struct mbuf **)&((ip6af)->ip6af_m))
104
105 /*
106  * IP6 reinjecting structure.
107  */
108 struct ip6_direct_ctx {
109         uint32_t        ip6dc_nxt;      /* next header to process */
110         uint32_t        ip6dc_off;      /* offset to next header */
111 };
112
113 /*
114  * Structure attached to inpcb.in6p_moptions and
115  * passed to ip6_output when IPv6 multicast options are in use.
116  * This structure is lazy-allocated.
117  */
118 struct ip6_moptions {
119         struct  ifnet *im6o_multicast_ifp; /* ifp for outgoing multicasts */
120         u_char  im6o_multicast_hlim;    /* hoplimit for outgoing multicasts */
121         u_char  im6o_multicast_loop;    /* 1 >= hear sends if a member */
122         u_short im6o_num_memberships;   /* no. memberships this socket */
123         u_short im6o_max_memberships;   /* max memberships this socket */
124         struct  in6_multi **im6o_membership;    /* group memberships */
125         struct  in6_mfilter *im6o_mfilters;     /* source filters */
126         struct  epoch_context imo6_epoch_ctx;
127 };
128
129 /*
130  * Control options for outgoing packets
131  */
132
133 /* Routing header related info */
134 struct  ip6po_rhinfo {
135         struct  ip6_rthdr *ip6po_rhi_rthdr; /* Routing header */
136         struct  route_in6 ip6po_rhi_route; /* Route to the 1st hop */
137 };
138 #define ip6po_rthdr     ip6po_rhinfo.ip6po_rhi_rthdr
139 #define ip6po_route     ip6po_rhinfo.ip6po_rhi_route
140
141 /* Nexthop related info */
142 struct  ip6po_nhinfo {
143         struct  sockaddr *ip6po_nhi_nexthop;
144         struct  route_in6 ip6po_nhi_route; /* Route to the nexthop */
145 };
146 #define ip6po_nexthop   ip6po_nhinfo.ip6po_nhi_nexthop
147 #define ip6po_nextroute ip6po_nhinfo.ip6po_nhi_route
148
149 struct  ip6_pktopts {
150         struct  mbuf *ip6po_m;  /* Pointer to mbuf storing the data */
151         int     ip6po_hlim;     /* Hoplimit for outgoing packets */
152
153         /* Outgoing IF/address information */
154         struct  in6_pktinfo *ip6po_pktinfo;
155
156         /* Next-hop address information */
157         struct  ip6po_nhinfo ip6po_nhinfo;
158
159         struct  ip6_hbh *ip6po_hbh; /* Hop-by-Hop options header */
160
161         /* Destination options header (before a routing header) */
162         struct  ip6_dest *ip6po_dest1;
163
164         /* Routing header related info. */
165         struct  ip6po_rhinfo ip6po_rhinfo;
166
167         /* Destination options header (after a routing header) */
168         struct  ip6_dest *ip6po_dest2;
169
170         int     ip6po_tclass;   /* traffic class */
171
172         int     ip6po_minmtu;  /* fragment vs PMTU discovery policy */
173 #define IP6PO_MINMTU_MCASTONLY  -1 /* default; send at min MTU for multicast*/
174 #define IP6PO_MINMTU_DISABLE     0 /* always perform pmtu disc */
175 #define IP6PO_MINMTU_ALL         1 /* always send at min MTU */
176
177         int     ip6po_prefer_tempaddr;  /* whether temporary addresses are
178                                            preferred as source address */
179 #define IP6PO_TEMPADDR_SYSTEM   -1 /* follow the system default */
180 #define IP6PO_TEMPADDR_NOTPREFER 0 /* not prefer temporary address */
181 #define IP6PO_TEMPADDR_PREFER    1 /* prefer temporary address */
182
183         int ip6po_flags;
184 #if 0   /* parameters in this block is obsolete. do not reuse the values. */
185 #define IP6PO_REACHCONF 0x01    /* upper-layer reachability confirmation. */
186 #define IP6PO_MINMTU    0x02    /* use minimum MTU (IPV6_USE_MIN_MTU) */
187 #endif
188 #define IP6PO_DONTFRAG  0x04    /* disable fragmentation (IPV6_DONTFRAG) */
189 #define IP6PO_USECOA    0x08    /* use care of address */
190 };
191
192 /*
193  * Control options for incoming packets
194  */
195
196 struct  ip6stat {
197         uint64_t ip6s_total;            /* total packets received */
198         uint64_t ip6s_tooshort;         /* packet too short */
199         uint64_t ip6s_toosmall;         /* not enough data */
200         uint64_t ip6s_fragments;        /* fragments received */
201         uint64_t ip6s_fragdropped;      /* frags dropped(dups, out of space) */
202         uint64_t ip6s_fragtimeout;      /* fragments timed out */
203         uint64_t ip6s_fragoverflow;     /* fragments that exceeded limit */
204         uint64_t ip6s_forward;          /* packets forwarded */
205         uint64_t ip6s_cantforward;      /* packets rcvd for unreachable dest */
206         uint64_t ip6s_redirectsent;     /* packets forwarded on same net */
207         uint64_t ip6s_delivered;        /* datagrams delivered to upper level*/
208         uint64_t ip6s_localout;         /* total ip packets generated here */
209         uint64_t ip6s_odropped;         /* lost packets due to nobufs, etc. */
210         uint64_t ip6s_reassembled;      /* total packets reassembled ok */
211         uint64_t ip6s_atomicfrags;      /* atomic fragments */
212         uint64_t ip6s_fragmented;       /* datagrams successfully fragmented */
213         uint64_t ip6s_ofragments;       /* output fragments created */
214         uint64_t ip6s_cantfrag;         /* don't fragment flag was set, etc. */
215         uint64_t ip6s_badoptions;       /* error in option processing */
216         uint64_t ip6s_noroute;          /* packets discarded due to no route */
217         uint64_t ip6s_badvers;          /* ip6 version != 6 */
218         uint64_t ip6s_rawout;           /* total raw ip packets generated */
219         uint64_t ip6s_badscope;         /* scope error */
220         uint64_t ip6s_notmember;        /* don't join this multicast group */
221 #define IP6S_HDRCNT             256     /* headers count */
222         uint64_t ip6s_nxthist[IP6S_HDRCNT]; /* next header history */
223         uint64_t ip6s_m1;               /* one mbuf */
224 #define IP6S_M2MMAX             32
225         uint64_t ip6s_m2m[IP6S_M2MMAX]; /* two or more mbuf */
226         uint64_t ip6s_mext1;            /* one ext mbuf */
227         uint64_t ip6s_mext2m;           /* two or more ext mbuf */
228         uint64_t ip6s_exthdrtoolong;    /* ext hdr are not contiguous */
229         uint64_t ip6s_nogif;            /* no match gif found */
230         uint64_t ip6s_toomanyhdr;       /* discarded due to too many headers */
231
232         /*
233          * statistics for improvement of the source address selection
234          * algorithm:
235          * XXX: hardcoded 16 = # of ip6 multicast scope types + 1
236          */
237 #define IP6S_RULESMAX           16
238 #define IP6S_SCOPECNT           16
239         /* number of times that address selection fails */
240         uint64_t ip6s_sources_none;
241         /* number of times that an address on the outgoing I/F is chosen */
242         uint64_t ip6s_sources_sameif[IP6S_SCOPECNT];
243         /* number of times that an address on a non-outgoing I/F is chosen */
244         uint64_t ip6s_sources_otherif[IP6S_SCOPECNT];
245         /*
246          * number of times that an address that has the same scope
247          * from the destination is chosen.
248          */
249         uint64_t ip6s_sources_samescope[IP6S_SCOPECNT];
250         /*
251          * number of times that an address that has a different scope
252          * from the destination is chosen.
253          */
254         uint64_t ip6s_sources_otherscope[IP6S_SCOPECNT];
255         /* number of times that a deprecated address is chosen */
256         uint64_t ip6s_sources_deprecated[IP6S_SCOPECNT];
257
258         /* number of times that each rule of source selection is applied. */
259         uint64_t ip6s_sources_rule[IP6S_RULESMAX];
260 };
261
262 #ifdef _KERNEL
263 #include <sys/counter.h>
264
265 VNET_PCPUSTAT_DECLARE(struct ip6stat, ip6stat);
266 #define IP6STAT_ADD(name, val)  \
267     VNET_PCPUSTAT_ADD(struct ip6stat, ip6stat, name, (val))
268 #define IP6STAT_SUB(name, val)  IP6STAT_ADD(name, -(val))
269 #define IP6STAT_INC(name)       IP6STAT_ADD(name, 1)
270 #define IP6STAT_DEC(name)       IP6STAT_SUB(name, 1)
271 #endif
272
273 #ifdef _KERNEL
274 /* flags passed to ip6_output as last parameter */
275 #define IPV6_UNSPECSRC          0x01    /* allow :: as the source address */
276 #define IPV6_FORWARDING         0x02    /* most of IPv6 header exists */
277 #define IPV6_MINMTU             0x04    /* use minimum MTU (IPV6_USE_MIN_MTU) */
278
279 #ifdef __NO_STRICT_ALIGNMENT
280 #define IP6_HDR_ALIGNED_P(ip)   1
281 #else
282 #define IP6_HDR_ALIGNED_P(ip)   ((((intptr_t) (ip)) & 3) == 0)
283 #endif
284
285 VNET_DECLARE(int, ip6_defhlim);         /* default hop limit */
286 VNET_DECLARE(int, ip6_defmcasthlim);    /* default multicast hop limit */
287 VNET_DECLARE(int, ip6_forwarding);      /* act as router? */
288 VNET_DECLARE(int, ip6_use_deprecated);  /* allow deprecated addr as source */
289 VNET_DECLARE(int, ip6_rr_prune);        /* router renumbering prefix
290                                          * walk list every 5 sec.    */
291 VNET_DECLARE(int, ip6_mcast_pmtu);      /* enable pMTU discovery for multicast? */
292 VNET_DECLARE(int, ip6_v6only);
293 #define V_ip6_defhlim                   VNET(ip6_defhlim)
294 #define V_ip6_defmcasthlim              VNET(ip6_defmcasthlim)
295 #define V_ip6_forwarding                VNET(ip6_forwarding)
296 #define V_ip6_use_deprecated            VNET(ip6_use_deprecated)
297 #define V_ip6_rr_prune                  VNET(ip6_rr_prune)
298 #define V_ip6_mcast_pmtu                VNET(ip6_mcast_pmtu)
299 #define V_ip6_v6only                    VNET(ip6_v6only)
300
301 VNET_DECLARE(struct socket *, ip6_mrouter);     /* multicast routing daemon */
302 VNET_DECLARE(int, ip6_sendredirects);   /* send IP redirects when forwarding? */
303 VNET_DECLARE(int, ip6_maxfragpackets);  /* Maximum packets in reassembly
304                                          * queue */
305 extern int ip6_maxfrags;                /* Maximum fragments in reassembly
306                                          * queue */
307 VNET_DECLARE(int, ip6_maxfragbucketsize); /* Maximum reassembly queues per bucket */
308 VNET_DECLARE(int, ip6_maxfragsperpacket); /* Maximum fragments per packet */
309 VNET_DECLARE(int, ip6_accept_rtadv);    /* Acts as a host not a router */
310 VNET_DECLARE(int, ip6_no_radr);         /* No defroute from RA */
311 VNET_DECLARE(int, ip6_norbit_raif);     /* Disable R-bit in NA on RA
312                                          * receiving IF. */
313 VNET_DECLARE(int, ip6_rfc6204w3);       /* Accept defroute from RA even when
314                                            forwarding enabled */
315 VNET_DECLARE(int, ip6_log_interval);
316 VNET_DECLARE(time_t, ip6_log_time);
317 VNET_DECLARE(int, ip6_hdrnestlimit);    /* upper limit of # of extension
318                                          * headers */
319 VNET_DECLARE(int, ip6_dad_count);       /* DupAddrDetectionTransmits */
320 #define V_ip6_mrouter                   VNET(ip6_mrouter)
321 #define V_ip6_sendredirects             VNET(ip6_sendredirects)
322 #define V_ip6_maxfragpackets            VNET(ip6_maxfragpackets)
323 #define V_ip6_maxfragbucketsize         VNET(ip6_maxfragbucketsize)
324 #define V_ip6_maxfragsperpacket         VNET(ip6_maxfragsperpacket)
325 #define V_ip6_accept_rtadv              VNET(ip6_accept_rtadv)
326 #define V_ip6_no_radr                   VNET(ip6_no_radr)
327 #define V_ip6_norbit_raif               VNET(ip6_norbit_raif)
328 #define V_ip6_rfc6204w3                 VNET(ip6_rfc6204w3)
329 #define V_ip6_log_interval              VNET(ip6_log_interval)
330 #define V_ip6_log_time                  VNET(ip6_log_time)
331 #define V_ip6_hdrnestlimit              VNET(ip6_hdrnestlimit)
332 #define V_ip6_dad_count                 VNET(ip6_dad_count)
333
334 VNET_DECLARE(int, ip6_auto_flowlabel);
335 VNET_DECLARE(int, ip6_auto_linklocal);
336 #define V_ip6_auto_flowlabel            VNET(ip6_auto_flowlabel)
337 #define V_ip6_auto_linklocal            VNET(ip6_auto_linklocal)
338
339 VNET_DECLARE(int, ip6_use_tempaddr);    /* Whether to use temporary addresses */
340 VNET_DECLARE(int, ip6_prefer_tempaddr); /* Whether to prefer temporary
341                                          * addresses in the source address
342                                          * selection */
343 #define V_ip6_use_tempaddr              VNET(ip6_use_tempaddr)
344 #define V_ip6_prefer_tempaddr           VNET(ip6_prefer_tempaddr)
345
346 VNET_DECLARE(int, ip6_use_defzone);     /* Whether to use the default scope
347                                          * zone when unspecified */
348 #define V_ip6_use_defzone               VNET(ip6_use_defzone)
349
350 VNET_DECLARE(struct pfil_head *, inet6_pfil_head);
351 #define V_inet6_pfil_head       VNET(inet6_pfil_head)
352 #define PFIL_INET6_NAME         "inet6"
353
354 #ifdef IPSTEALTH
355 VNET_DECLARE(int, ip6stealth);
356 #define V_ip6stealth                    VNET(ip6stealth)
357 #endif
358
359 #ifdef EXPERIMENTAL
360 VNET_DECLARE(int, nd6_ignore_ipv6_only_ra);
361 #define V_nd6_ignore_ipv6_only_ra       VNET(nd6_ignore_ipv6_only_ra)
362 #endif
363
364 extern struct   pr_usrreqs rip6_usrreqs;
365 struct sockopt;
366
367 struct inpcb;
368
369 int     icmp6_ctloutput(struct socket *, struct sockopt *sopt);
370
371 struct in6_ifaddr;
372 void    ip6_init(void);
373 int     ip6proto_register(short);
374 int     ip6proto_unregister(short);
375
376 void    ip6_input(struct mbuf *);
377 void    ip6_direct_input(struct mbuf *);
378 void    ip6_freepcbopts(struct ip6_pktopts *);
379
380 int     ip6_unknown_opt(u_int8_t *, struct mbuf *, int);
381 int     ip6_get_prevhdr(const struct mbuf *, int);
382 int     ip6_nexthdr(const struct mbuf *, int, int, int *);
383 int     ip6_lasthdr(const struct mbuf *, int, int, int *);
384
385 extern int      (*ip6_mforward)(struct ip6_hdr *, struct ifnet *,
386     struct mbuf *);
387
388 int     ip6_process_hopopts(struct mbuf *, u_int8_t *, int, u_int32_t *,
389                                  u_int32_t *);
390 struct mbuf     **ip6_savecontrol_v4(struct inpcb *, struct mbuf *,
391             struct mbuf **, int *);
392 void    ip6_savecontrol(struct inpcb *, struct mbuf *, struct mbuf **);
393 void    ip6_notify_pmtu(struct inpcb *, struct sockaddr_in6 *, u_int32_t);
394 int     ip6_sysctl(int *, u_int, void *, size_t *, void *, size_t);
395
396 void    ip6_forward(struct mbuf *, int);
397
398 void    ip6_mloopback(struct ifnet *, struct mbuf *);
399 int     ip6_output(struct mbuf *, struct ip6_pktopts *,
400                         struct route_in6 *,
401                         int,
402                         struct ip6_moptions *, struct ifnet **,
403                         struct inpcb *);
404 int     ip6_ctloutput(struct socket *, struct sockopt *);
405 int     ip6_raw_ctloutput(struct socket *, struct sockopt *);
406 void    ip6_initpktopts(struct ip6_pktopts *);
407 int     ip6_setpktopts(struct mbuf *, struct ip6_pktopts *,
408         struct ip6_pktopts *, struct ucred *, int);
409 void    ip6_clearpktopts(struct ip6_pktopts *, int);
410 struct ip6_pktopts *ip6_copypktopts(struct ip6_pktopts *, int);
411 int     ip6_optlen(struct inpcb *);
412 int     ip6_deletefraghdr(struct mbuf *, int, int);
413 int     ip6_fragment(struct ifnet *, struct mbuf *, int, u_char, int,
414                         uint32_t);
415
416 int     route6_input(struct mbuf **, int *, int);
417
418 void    frag6_set_bucketsize(void);
419 void    frag6_init(void);
420 int     frag6_input(struct mbuf **, int *, int);
421 void    frag6_slowtimo(void);
422 void    frag6_drain(void);
423
424 void    rip6_init(void);
425 int     rip6_input(struct mbuf **, int *, int);
426 void    rip6_ctlinput(int, struct sockaddr *, void *);
427 int     rip6_ctloutput(struct socket *, struct sockopt *);
428 int     rip6_output(struct mbuf *, struct socket *, ...);
429 int     rip6_usrreq(struct socket *,
430             int, struct mbuf *, struct mbuf *, struct mbuf *, struct thread *);
431
432 int     dest6_input(struct mbuf **, int *, int);
433 int     none_input(struct mbuf **, int *, int);
434
435 int     in6_selectsrc_socket(struct sockaddr_in6 *, struct ip6_pktopts *,
436     struct inpcb *, struct ucred *, int, struct in6_addr *, int *);
437 int     in6_selectsrc_addr(uint32_t, const struct in6_addr *,
438     uint32_t, struct ifnet *, struct in6_addr *, int *);
439 int in6_selectroute(struct sockaddr_in6 *, struct ip6_pktopts *,
440         struct ip6_moptions *, struct route_in6 *, struct ifnet **,
441         struct rtentry **);
442 int     in6_selectroute_fib(struct sockaddr_in6 *, struct ip6_pktopts *,
443             struct ip6_moptions *, struct route_in6 *, struct ifnet **,
444             struct rtentry **, u_int);
445 u_int32_t ip6_randomid(void);
446 u_int32_t ip6_randomflowlabel(void);
447 void in6_delayed_cksum(struct mbuf *m, uint32_t plen, u_short offset);
448 #endif /* _KERNEL */
449
450 #endif /* !_NETINET6_IP6_VAR_H_ */