/* * IPSEC interface configuration * Copyright (C) 1996 John Ioannidis. * Copyright (C) 1998, 1999, 2000, 2001 Richard Guy Briggs. * Copyright (C) 2006 Michael Richardson * * This program is free software; you can redistribute it and/or modify it * under the terms of the GNU General Public License as published by the * Free Software Foundation; either version 2 of the License, or (at your * option) any later version. See . * * This program is distributed in the hope that it will be useful, but * WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY * or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License * for more details. */ #include #include #include /* system() */ #include /* getuid() */ #include #include /* ioctl() */ #include #ifdef NET_21 /* from libreswan.h */ #include #include #endif /* NET_21 */ /* from libreswan.h */ #if 0 #include #else #include #endif #include #include #include #include #include #include "socketwrapper.h" #include "lswlog.h" #include "libreswan/pfkey.h" #include "libreswan/pfkeyv2.h" #include "pfkey_help.h" #include "libreswan/ipsec_tunnel.h" char *progname; static void usage(char *name) { fprintf(stdout, "%s --create \n", name); fprintf(stdout, "%s --delete \n", name); fprintf(stdout, "%s --attach --virtual --physical \n", name); fprintf(stdout, "%s --detach --virtual \n", name); fprintf(stdout, "%s --clear\n", name); fprintf(stdout, "%s --help\n", name); fprintf(stdout, "%s --version\n", name); fprintf(stdout, "%s\n", name); fprintf(stdout, " [ --debug ] is optional to any %s command.\n", name); fprintf(stdout, " [ --label