summaryrefslogtreecommitdiffstats
path: root/sys/net/if_enc.h
diff options
context:
space:
mode:
authorae <ae@FreeBSD.org>2015-11-25 07:31:59 +0000
committerae <ae@FreeBSD.org>2015-11-25 07:31:59 +0000
commitd81208c9488e0efbf99f327d11bbd7bc055c5b1b (patch)
tree180d9bca9c02ba401375a447b28937f28cfb981d /sys/net/if_enc.h
parentda001d5bf7a7acfef070a8f605c3ec452d374d09 (diff)
downloadFreeBSD-src-d81208c9488e0efbf99f327d11bbd7bc055c5b1b.zip
FreeBSD-src-d81208c9488e0efbf99f327d11bbd7bc055c5b1b.tar.gz
Overhaul if_enc(4) and make it loadable in run-time.
Use hhook(9) framework to achieve ability of loading and unloading if_enc(4) kernel module. INET and INET6 code on initialization registers two helper hooks points in the kernel. if_enc(4) module uses these helper hook points and registers its hooks. IPSEC code uses these hhook points to call helper hooks implemented in if_enc(4).
Diffstat (limited to 'sys/net/if_enc.h')
-rw-r--r--sys/net/if_enc.h9
1 files changed, 8 insertions, 1 deletions
diff --git a/sys/net/if_enc.h b/sys/net/if_enc.h
index 59a55fc..941ed12 100644
--- a/sys/net/if_enc.h
+++ b/sys/net/if_enc.h
@@ -30,6 +30,13 @@
#ifndef _NET_IF_ENC_H
#define _NET_IF_ENC_H
-extern struct ifnet *encif;
+struct ipsec_ctx_data {
+ struct mbuf **mp;
+ struct secasvar *sav;
+ uint8_t af;
+#define IPSEC_ENC_BEFORE 0x01
+#define IPSEC_ENC_AFTER 0x02
+ uint8_t enc;
+};
#endif /* _NET_IF_ENC_H */
OpenPOWER on IntegriCloud