Main Page | Modules | Class List | Directories | File List | Class Members | File Members | Related Pages

libnet-structures.h

Go to the documentation of this file.
00001 /*
00002  *  $Id$
00003  *
00004  *  libnet-structures.h - Network routine library structures header file
00005  *
00006  *  Copyright (c) 1998, 1999, 2000 Mike D. Schiffman <mike@infonexus.com>
00007  *  All rights reserved.
00008  *
00009  * Redistribution and use in source and binary forms, with or without
00010  * modification, are permitted provided that the following conditions
00011  * are met:
00012  * 1. Redistributions of source code must retain the above copyright
00013  *    notice, this list of conditions and the following disclaimer.
00014  * 2. Redistributions in binary form must reproduce the above copyright
00015  *    notice, this list of conditions and the following disclaimer in the
00016  *    documentation and/or other materials provided with the distribution.
00017  *
00018  * THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND
00019  * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
00020  * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
00021  * ARE DISCLAIMED.  IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE
00022  * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
00023  * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
00024  * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
00025  * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
00026  * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
00027  * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
00028  * SUCH DAMAGE.
00029  *
00030  */
00031 
00032 #ifndef __LIBNET_STRUCTURES_H
00033 #define __LIBNET_STRUCTURES_H
00034 
00035 
00036 /*
00037  *  Port list chain structure
00038  */
00039 struct libnet_plist_chain
00040 {
00041     u_short node;                       /* node number */
00042     u_short bport;                      /* beggining port */
00043     u_short eport;                      /* terminating port */
00044     struct libnet_plist_chain *next;    /* next node in the list */
00045 };
00046 
00047 
00048 /*
00049  *  Low level packet interface struct
00050  */
00051 struct libnet_link_int
00052 {
00053     int fd;             /* link layer file descriptor */
00054     int linktype;       /* link type */
00055     int linkoffset;     /* link header size (offset till network layer) */
00056     u_char *device;     /* device name */
00057 };
00058 
00059 
00060 /*
00061  *  Arena structure.
00062  */
00063 struct libnet_arena
00064 {
00065     int tag;                /* arena tag */
00066     u_char *memory_pool;    /* the memory */
00067     u_long current;         /* the current amount of memory allocated */
00068     u_long size;            /* the size of the pool in bytes */
00069 };
00070 
00071 
00072 /*
00073  *  Interface selection stuff
00074  */
00075 struct libnet_ifaddr_list
00076 {
00077     u_long addr;
00078     char *device;
00079 };
00080 
00081 #endif  /* __LIBNET_STRUCTURES_H */
00082 
00083 /* EOF */

Generated on Sun May 14 14:51:19 2006 by  doxygen 1.4.2