Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src/trunk]: src ipsec(4) interface supports rump now.



details:   https://anonhg.NetBSD.org/src/rev/e27e41be4b2f
branches:  trunk
changeset: 358625:e27e41be4b2f
user:      knakahara <knakahara%NetBSD.org@localhost>
date:      Wed Jan 10 11:02:41 2018 +0000

description:
ipsec(4) interface supports rump now.

diffstat:

 distrib/sets/lists/base/shl.mi              |   5 ++-
 distrib/sets/lists/comp/mi                  |   4 ++-
 distrib/sets/lists/comp/shl.mi              |   3 +-
 distrib/sets/lists/debug/mi                 |   3 +-
 distrib/sets/lists/debug/shl.mi             |   3 +-
 sys/rump/net/Makefile.rumpnetcomp           |   4 +-
 sys/rump/net/lib/libipsec/IPSEC.ioconf      |   7 ++++
 sys/rump/net/lib/libipsec/Makefile          |  15 ++++++++++
 sys/rump/net/lib/libipsec/ipsec_component.c |  42 +++++++++++++++++++++++++++++
 9 files changed, 79 insertions(+), 7 deletions(-)

diffs (180 lines):

diff -r e6f3d762110b -r e27e41be4b2f distrib/sets/lists/base/shl.mi
--- a/distrib/sets/lists/base/shl.mi    Wed Jan 10 10:56:30 2018 +0000
+++ b/distrib/sets/lists/base/shl.mi    Wed Jan 10 11:02:41 2018 +0000
@@ -1,4 +1,4 @@
-# $NetBSD: shl.mi,v 1.824 2017/10/25 06:32:59 kre Exp $
+# $NetBSD: shl.mi,v 1.825 2018/01/10 11:02:41 knakahara Exp $
 #
 # Note:        Don't delete entries from here - mark them as "obsolete" instead,
 #      unless otherwise stated below.
@@ -706,6 +706,9 @@
 ./usr/lib/librumpnet_gif.so                    base-rump-shlib         rump
 ./usr/lib/librumpnet_gif.so.0                  base-rump-shlib         rump
 ./usr/lib/librumpnet_gif.so.0.0                        base-rump-shlib         rump
+./usr/lib/librumpnet_ipsec.so                  base-rump-shlib         rump
+./usr/lib/librumpnet_ipsec.so.0                        base-rump-shlib         rump
+./usr/lib/librumpnet_ipsec.so.0.0              base-rump-shlib         rump
 ./usr/lib/librumpnet_l2tp.so                   base-rump-shlib         rump
 ./usr/lib/librumpnet_l2tp.so.0                 base-rump-shlib         rump
 ./usr/lib/librumpnet_l2tp.so.0.0               base-rump-shlib         rump
diff -r e6f3d762110b -r e27e41be4b2f distrib/sets/lists/comp/mi
--- a/distrib/sets/lists/comp/mi        Wed Jan 10 10:56:30 2018 +0000
+++ b/distrib/sets/lists/comp/mi        Wed Jan 10 11:02:41 2018 +0000
@@ -1,4 +1,4 @@
-#      $NetBSD: mi,v 1.2168 2018/01/10 10:56:30 knakahara Exp $
+#      $NetBSD: mi,v 1.2169 2018/01/10 11:02:41 knakahara Exp $
 #
 # Note: don't delete entries from here - mark them as "obsolete" instead.
 ./etc/mtree/set.comp                           comp-sys-root
@@ -3569,6 +3569,8 @@
 ./usr/lib/librumpnet_bridge_p.a                        comp-c-proflib          rump,profile
 ./usr/lib/librumpnet_gif.a                     comp-c-lib              rump
 ./usr/lib/librumpnet_gif_p.a                   comp-c-proflib          rump,profile
+./usr/lib/librumpnet_ipsec.a                   comp-c-lib              rump
+./usr/lib/librumpnet_ipsec_p.a                 comp-c-proflib          rump,profile
 ./usr/lib/librumpnet_l2tp.a                    comp-c-lib              rump
 ./usr/lib/librumpnet_l2tp_p.a                  comp-c-proflib          rump,profile
 ./usr/lib/librumpnet_local.a                   comp-c-lib              rump
diff -r e6f3d762110b -r e27e41be4b2f distrib/sets/lists/comp/shl.mi
--- a/distrib/sets/lists/comp/shl.mi    Wed Jan 10 10:56:30 2018 +0000
+++ b/distrib/sets/lists/comp/shl.mi    Wed Jan 10 11:02:41 2018 +0000
@@ -1,4 +1,4 @@
-# $NetBSD: shl.mi,v 1.309 2017/11/04 16:21:49 kamil Exp $
+# $NetBSD: shl.mi,v 1.310 2018/01/10 11:02:41 knakahara Exp $
 #
 # Note: don't delete entries from here - mark them as "obsolete" instead.
 #
@@ -219,6 +219,7 @@
 ./usr/lib/librumpnet_bpfjit_pic.a              comp-c-piclib           picinstall,rump,sljit
 ./usr/lib/librumpnet_bridge_pic.a              comp-c-piclib           picinstall,rump
 ./usr/lib/librumpnet_gif_pic.a                 comp-c-piclib           picinstall,rump
+./usr/lib/librumpnet_ipsec_pic.a               comp-c-piclib           picinstall,rump
 ./usr/lib/librumpnet_l2tp_pic.a                        comp-c-piclib           picinstall,rump
 ./usr/lib/librumpnet_local_pic.a               comp-c-piclib           picinstall,rump
 ./usr/lib/librumpnet_net80211_pic.a            comp-c-piclib           picinstall,rump
diff -r e6f3d762110b -r e27e41be4b2f distrib/sets/lists/debug/mi
--- a/distrib/sets/lists/debug/mi       Wed Jan 10 10:56:30 2018 +0000
+++ b/distrib/sets/lists/debug/mi       Wed Jan 10 11:02:41 2018 +0000
@@ -1,4 +1,4 @@
-# $NetBSD: mi,v 1.233 2018/01/09 03:31:13 christos Exp $
+# $NetBSD: mi,v 1.234 2018/01/10 11:02:41 knakahara Exp $
 ./etc/mtree/set.debug                           comp-sys-root
 ./usr/lib                                      comp-sys-usr            compatdir
 ./usr/lib/i18n/libBIG5_g.a                     comp-c-debuglib         debuglib,compatfile
@@ -211,6 +211,7 @@
 ./usr/lib/librumpnet_bridge_g.a                        comp-c-debuglib         debuglib,rump
 ./usr/lib/librumpnet_g.a                       comp-c-debuglib         debuglib,compatfile,rump
 ./usr/lib/librumpnet_gif_g.a                   comp-c-debuglib         debuglib,rump
+./usr/lib/librumpnet_ipsec_g.a                 comp-c-debuglib         debuglib,rump
 ./usr/lib/librumpnet_l2tp_g.a                  comp-c-debuglib         debuglib,rump
 ./usr/lib/librumpnet_local_g.a                 comp-c-debuglib         debuglib,rump
 ./usr/lib/librumpnet_net80211_g.a              comp-c-debuglib         debuglib,rump
diff -r e6f3d762110b -r e27e41be4b2f distrib/sets/lists/debug/shl.mi
--- a/distrib/sets/lists/debug/shl.mi   Wed Jan 10 10:56:30 2018 +0000
+++ b/distrib/sets/lists/debug/shl.mi   Wed Jan 10 11:02:41 2018 +0000
@@ -1,4 +1,4 @@
-# $NetBSD: shl.mi,v 1.187 2017/11/04 16:21:49 kamil Exp $
+# $NetBSD: shl.mi,v 1.188 2018/01/10 11:02:41 knakahara Exp $
 ./usr/lib/libbfd_g.a                                           comp-c-debuglib debuglib,compatfile,binutils
 ./usr/libdata/debug/lib                                                base-sys-usr    debug,dynamicroot,compatdir
 ./usr/libdata/debug/lib/libblacklist.so.0.0.debug              comp-sys-debug  debug,dynamicroot
@@ -241,6 +241,7 @@
 ./usr/libdata/debug/usr/lib/librumpnet_bpfjit.so.0.0.debug     comp-rump-debug debug,rump,sljit
 ./usr/libdata/debug/usr/lib/librumpnet_bridge.so.0.0.debug     comp-rump-debug debug,rump
 ./usr/libdata/debug/usr/lib/librumpnet_gif.so.0.0.debug                comp-rump-debug debug,rump
+./usr/libdata/debug/usr/lib/librumpnet_ipsec.so.0.0.debug      comp-rump-debug debug,rump
 ./usr/libdata/debug/usr/lib/librumpnet_l2tp.so.0.0.debug       comp-rump-debug debug,rump
 ./usr/libdata/debug/usr/lib/librumpnet_local.so.0.0.debug      comp-rump-debug debug,rump
 ./usr/libdata/debug/usr/lib/librumpnet_net.so.0.0.debug                comp-rump-debug debug,rump
diff -r e6f3d762110b -r e27e41be4b2f sys/rump/net/Makefile.rumpnetcomp
--- a/sys/rump/net/Makefile.rumpnetcomp Wed Jan 10 10:56:30 2018 +0000
+++ b/sys/rump/net/Makefile.rumpnetcomp Wed Jan 10 11:02:41 2018 +0000
@@ -1,10 +1,10 @@
-#      $NetBSD: Makefile.rumpnetcomp,v 1.19 2017/05/27 21:02:56 bouyer Exp $
+#      $NetBSD: Makefile.rumpnetcomp,v 1.20 2018/01/10 11:02:42 knakahara Exp $
 #
 
 .include <bsd.own.mk>
 
 RUMPNETCOMP=   agr bridge net net80211 netbt netcan netinet netinet6 netipsec
-RUMPNETCOMP+=  gif netmpls npf l2tp local pppoe shmif tap tun vlan
+RUMPNETCOMP+=  gif ipsec netmpls npf l2tp local pppoe shmif tap tun vlan
 
 .if ${MKSLJIT} != "no" || make(rumpdescribe)
 RUMPNETCOMP+=  bpfjit
diff -r e6f3d762110b -r e27e41be4b2f sys/rump/net/lib/libipsec/IPSEC.ioconf
--- /dev/null   Thu Jan 01 00:00:00 1970 +0000
+++ b/sys/rump/net/lib/libipsec/IPSEC.ioconf    Wed Jan 10 11:02:41 2018 +0000
@@ -0,0 +1,7 @@
+#      $NetBSD: IPSEC.ioconf,v 1.1 2018/01/10 11:02:42 knakahara Exp $
+
+ioconf         ipsec
+
+include                "conf/files"
+
+pseudo-device   ipsecif
diff -r e6f3d762110b -r e27e41be4b2f sys/rump/net/lib/libipsec/Makefile
--- /dev/null   Thu Jan 01 00:00:00 1970 +0000
+++ b/sys/rump/net/lib/libipsec/Makefile        Wed Jan 10 11:02:41 2018 +0000
@@ -0,0 +1,15 @@
+#      $NetBSD: Makefile,v 1.1 2018/01/10 11:02:42 knakahara Exp $
+#
+
+.PATH: ${.CURDIR}/../../../../net ${.CURDIR}/../../../../netipsec
+
+LIB=   rumpnet_ipsec
+COMMENT= ipsec interface
+
+IOCONF=        IPSEC.ioconf
+SRCS=  if_ipsec.c ipsecif.c
+
+SRCS+= ipsec_component.c
+
+.include <bsd.lib.mk>
+.include <bsd.klinks.mk>
diff -r e6f3d762110b -r e27e41be4b2f sys/rump/net/lib/libipsec/ipsec_component.c
--- /dev/null   Thu Jan 01 00:00:00 1970 +0000
+++ b/sys/rump/net/lib/libipsec/ipsec_component.c       Wed Jan 10 11:02:41 2018 +0000
@@ -0,0 +1,42 @@
+/*     $NetBSD: ipsec_component.c,v 1.1 2018/01/10 11:02:42 knakahara Exp $    */
+
+/*
+ * Copyright (c) 2017 Internet Initiative Japan Inc.
+ * All rights reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions
+ * are met:
+ * 1. Redistributions of source code must retain the above copyright
+ *    notice, this list of conditions and the following disclaimer.
+ * 2. Redistributions in binary form must reproduce the above copyright
+ *    notice, this list of conditions and the following disclaimer in the
+ *    documentation and/or other materials provided with the distribution.
+ *
+ * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS
+ * OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
+ * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
+ * DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE
+ * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
+ * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
+ * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
+ * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
+ * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
+ * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
+ * SUCH DAMAGE.
+ */
+
+#include <sys/cdefs.h>
+__KERNEL_RCSID(0, "$NetBSD: ipsec_component.c,v 1.1 2018/01/10 11:02:42 knakahara Exp $");
+
+#include <sys/param.h>
+
+#include <rump-sys/kern.h>
+
+int ipsecifattach(int);
+
+RUMP_COMPONENT(RUMP_COMPONENT_NET_IF)
+{
+
+       ipsecifattach(0);
+}



Home | Main Index | Thread Index | Old Index