/* * RFC2367 PF_KEYv2 Key management API message parser * Copyright (C) 1999 Richard Guy Briggs. * * 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. * * RCSID $Id: pfkey_v2_ext_bits.c,v 1.5 2000/06/02 22:54:14 rgb Exp $ */ /* * Template from klips/net/ipsec/ipsec/ipsec_parse.c. */ char pfkey_v2_ext_bits_c_version[] = "$Id: pfkey_v2_ext_bits.c,v 1.5 2000/06/02 22:54:14 rgb Exp $"; /* * Some ugly stuff to allow consistent debugging code for use in the * kernel and in user space */ #ifdef __KERNEL__ #include /* for printk */ #include /* kmalloc() */ #include /* error codes */ #include /* size_t */ #include /* mark_bh */ #include /* struct device, and other headers */ #include /* eth_type_trans */ #include /* struct iphdr */ #if defined(CONFIG_IPV6) || defined(CONFIG_IPV6_MODULE) #include #endif /* defined(CONFIG_IPV6) || defined(CONFIG_IPV6_MODULE) */ #else /* __KERNEL__ */ #include #include #include #endif #include #include #include unsigned int extensions_bitmaps[2/*in/out*/][2/*perm/req*/][SADB_MAX + 1/*ext*/] = { /* INBOUND EXTENSIONS */ { /* PERMITTED */ { /* SADB_RESERVED */ 0 , /* SADB_GETSPI */ 1<