diff options
author | Theo de Raadt <deraadt@cvs.openbsd.org> | 2015-01-19 16:49:06 +0000 |
---|---|---|
committer | Theo de Raadt <deraadt@cvs.openbsd.org> | 2015-01-19 16:49:06 +0000 |
commit | a78e2b641baf95cbcd529fd52efeb0b220d26f8e (patch) | |
tree | 54fa057bc90b46fca0fe35948b8afe82beaaff73 /sys/netinet | |
parent | f48adff126f4e4ff29b321d164eeeec70660eccb (diff) |
First step of hiding many kernel-only parts of <netinet/ip_ipsp.h>
under _KERNEL, and adjust the one consumer (netstat) so that it requests
the exposure. Will take a few more rounds to get this right.
ok mikeb
Diffstat (limited to 'sys/netinet')
-rw-r--r-- | sys/netinet/ip_ipsp.h | 14 |
1 files changed, 12 insertions, 2 deletions
diff --git a/sys/netinet/ip_ipsp.h b/sys/netinet/ip_ipsp.h index 6192a97136b..39258488cfc 100644 --- a/sys/netinet/ip_ipsp.h +++ b/sys/netinet/ip_ipsp.h @@ -1,4 +1,4 @@ -/* $OpenBSD: ip_ipsp.h,v 1.158 2014/12/23 03:24:08 tedu Exp $ */ +/* $OpenBSD: ip_ipsp.h,v 1.159 2015/01/19 16:49:05 deraadt Exp $ */ /* * The authors of this code are John Ioannidis (ji@tla.org), * Angelos D. Keromytis (kermit@csd.uch.gr), @@ -45,8 +45,10 @@ struct m_tag; /* IPSP global definitions. */ #include <sys/types.h> -#include <sys/queue.h> +#ifdef _KERNEL #include <sys/timeout.h> +#endif +#include <sys/queue.h> #include <netinet/in.h> union sockaddr_union { @@ -133,6 +135,8 @@ struct sockaddr_encap { #define IPSP_DIRECTION_IN 0x1 #define IPSP_DIRECTION_OUT 0x2 +#ifdef _KERNEL + #define sen_data Sen.Data #define sen_ip_src Sen.Sip4.Src #define sen_ip_dst Sen.Sip4.Dst @@ -182,6 +186,8 @@ struct ipsec_acquire { TAILQ_ENTRY(ipsec_acquire) ipa_inp_next; }; +#endif /* _KERNEL */ + struct ipsec_policy { struct sockaddr_encap ipo_addr; struct sockaddr_encap ipo_mask; @@ -219,6 +225,8 @@ struct ipsec_policy { TAILQ_ENTRY(ipsec_policy) ipo_list; /* List of all policies */ }; +#ifdef _KERNEL + #define IPSP_POLICY_NONE 0x0000 /* No flags set */ #define IPSP_POLICY_SOCKET 0x0001 /* Socket-attached policy */ #define IPSP_POLICY_STATIC 0x0002 /* Static policy */ @@ -377,6 +385,8 @@ struct tdb { /* tunnel descriptor block */ TAILQ_ENTRY(tdb) tdb_sync_entry; }; +#endif /* _KERNEL */ + struct tdb_ident { u_int32_t spi; union sockaddr_union dst; |