ip.h revision 61295d7d43bad84b52068f08d8d2339d0ae9fe06
af062818b47340eef15700d2f0211576ba3506eevboxsync * Copyright (c) 1982, 1986, 1993
af062818b47340eef15700d2f0211576ba3506eevboxsync * The Regents of the University of California. All rights reserved.
af062818b47340eef15700d2f0211576ba3506eevboxsync * Redistribution and use in source and binary forms, with or without
af062818b47340eef15700d2f0211576ba3506eevboxsync * modification, are permitted provided that the following conditions
af062818b47340eef15700d2f0211576ba3506eevboxsync * 1. Redistributions of source code must retain the above copyright
af062818b47340eef15700d2f0211576ba3506eevboxsync * notice, this list of conditions and the following disclaimer.
af062818b47340eef15700d2f0211576ba3506eevboxsync * 2. Redistributions in binary form must reproduce the above copyright
af062818b47340eef15700d2f0211576ba3506eevboxsync * notice, this list of conditions and the following disclaimer in the
af062818b47340eef15700d2f0211576ba3506eevboxsync * documentation and/or other materials provided with the distribution.
af062818b47340eef15700d2f0211576ba3506eevboxsync * 3. All advertising materials mentioning features or use of this software
af062818b47340eef15700d2f0211576ba3506eevboxsync * must display the following acknowledgement:
af062818b47340eef15700d2f0211576ba3506eevboxsync * This product includes software developed by the University of
af062818b47340eef15700d2f0211576ba3506eevboxsync * California, Berkeley and its contributors.
af062818b47340eef15700d2f0211576ba3506eevboxsync * 4. Neither the name of the University nor the names of its contributors
b955672b950093ff7416d1269dd4d3b69983bd8fvboxsync * may be used to endorse or promote products derived from this software
b955672b950093ff7416d1269dd4d3b69983bd8fvboxsync * without specific prior written permission.
4b9d6701570cb98fd36e209314239d104ec584d3vboxsync * THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
b955672b950093ff7416d1269dd4d3b69983bd8fvboxsync * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
b955672b950093ff7416d1269dd4d3b69983bd8fvboxsync * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
b955672b950093ff7416d1269dd4d3b69983bd8fvboxsync * ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
b955672b950093ff7416d1269dd4d3b69983bd8fvboxsync * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
b955672b950093ff7416d1269dd4d3b69983bd8fvboxsync * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
ee6bcfc59fe3b0230aad85e2ef63d0402b7719b2vboxsync * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
af062818b47340eef15700d2f0211576ba3506eevboxsync * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
af062818b47340eef15700d2f0211576ba3506eevboxsync * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
af062818b47340eef15700d2f0211576ba3506eevboxsync * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
af062818b47340eef15700d2f0211576ba3506eevboxsync * SUCH DAMAGE.
af062818b47340eef15700d2f0211576ba3506eevboxsync * @(#)ip.h 8.1 (Berkeley) 6/10/93
af062818b47340eef15700d2f0211576ba3506eevboxsync * ip.h,v 1.3 1994/08/21 05:27:30 paul Exp
af062818b47340eef15700d2f0211576ba3506eevboxsync * Definitions for internet protocol version 4.
af062818b47340eef15700d2f0211576ba3506eevboxsync * Per RFC 791, September 1981.
af062818b47340eef15700d2f0211576ba3506eevboxsync * Structure of an internet header, naked of options.
af062818b47340eef15700d2f0211576ba3506eevboxsync#define IP_OFFMASK 0x1fff /* mask for fragmenting bits */
af062818b47340eef15700d2f0211576ba3506eevboxsync#define IP_MAXPACKET 65535 /* maximum packet size */
af062818b47340eef15700d2f0211576ba3506eevboxsync * Definitions for IP type of service (ip_tos)
af062818b47340eef15700d2f0211576ba3506eevboxsync * Definitions for options.
af062818b47340eef15700d2f0211576ba3506eevboxsync * Offsets to fields in options other than EOL and NOP.
af062818b47340eef15700d2f0211576ba3506eevboxsync * Time stamp option structure.
af062818b47340eef15700d2f0211576ba3506eevboxsync uint8_t ipt_len; /* size of structure (variable) */
af062818b47340eef15700d2f0211576ba3506eevboxsync/* flag bits for ipt_flg */
af062818b47340eef15700d2f0211576ba3506eevboxsync#define IPOPT_TS_TSANDADDR 1 /* timestamps and addresses */
af062818b47340eef15700d2f0211576ba3506eevboxsync#define IPOPT_TS_PRESPEC 3 /* specified modules only */
af062818b47340eef15700d2f0211576ba3506eevboxsync/* bits for security (not byte swapped) */
af062818b47340eef15700d2f0211576ba3506eevboxsync * Internet implementation parameters.
af062818b47340eef15700d2f0211576ba3506eevboxsync#define MAXTTL 255 /* maximum time to live (seconds) */
af062818b47340eef15700d2f0211576ba3506eevboxsync#define IPDEFTTL 64 /* default ttl, from RFC 1340 */
af062818b47340eef15700d2f0211576ba3506eevboxsync#define IPFRAGTTL 60 /* time to live for frags, slowhz */
af062818b47340eef15700d2f0211576ba3506eevboxsync#define IP_MSS 576 /* default maximum segment size */
af062818b47340eef15700d2f0211576ba3506eevboxsync#ifdef HAVE_SYS_TYPES32_H /* Overcome some Solaris 2.x junk */
# if !defined(VBOX_WITH_BSD_REASS)
struct ipovly
#if !defined(VBOX_WITH_BSD_REASS)
struct ipq_t
#ifndef VBOX_WITH_BSD_REASS
#ifndef VBOX_WITH_BSD_REASS
#ifdef VBOX_WITH_BSD_REASS
#define IPREASS_HASH(x,y) \
struct ipasfrag
#ifdef WORDS_BIGENDIAN
# ifdef _MSC_VER
# ifdef _MSC_VER
struct ipoption
struct ipstat_t