Home | History | Annotate | Line # | Download | only in libnpftest
npf_test.h revision 1.3.2.4
      1 /*	$NetBSD: npf_test.h,v 1.3.2.4 2012/08/13 17:49:53 riz Exp $	*/
      2 
      3 /*
      4  * Public Domain.
      5  */
      6 
      7 #ifndef _LIB_NPF_TEST_H_
      8 #define _LIB_NPF_TEST_H_
      9 
     10 #include <sys/types.h>
     11 #include <sys/mbuf.h>
     12 
     13 #include <netinet/in_systm.h>
     14 #include <netinet/in.h>
     15 #include <netinet6/in6.h>
     16 
     17 #include <netinet/ip.h>
     18 #include <netinet/ip6.h>
     19 #include <netinet/tcp.h>
     20 #include <netinet/udp.h>
     21 #include <netinet/ip_icmp.h>
     22 
     23 #include <net/if.h>
     24 #include <net/if_ether.h>
     25 #include <net/ethertypes.h>
     26 
     27 int		npf_test_load(const void *);
     28 unsigned	npf_test_addif(const char *, unsigned, bool);
     29 unsigned	npf_test_getif(const char *);
     30 int		npf_test_handlepkt(const void *, size_t, unsigned,
     31 		    bool, int64_t *);
     32 
     33 struct mbuf *	mbuf_getwithdata(const void *, size_t);
     34 struct mbuf *	mbuf_construct_ether(int);
     35 struct mbuf *	mbuf_construct(int);
     36 struct mbuf *	mbuf_construct6(int);
     37 void *		mbuf_return_hdrs(struct mbuf *, bool, struct ip **);
     38 void		mbuf_icmp_append(struct mbuf *, struct mbuf *);
     39 
     40 bool		npf_nbuf_test(bool);
     41 bool		npf_processor_test(bool);
     42 bool		npf_table_test(bool);
     43 bool		npf_state_test(bool);
     44 
     45 bool		npf_rule_test(bool);
     46 bool		npf_nat_test(bool);
     47 
     48 #endif
     49