root / slirp / icmp_var.h @ 40d0591e
History | View | Annotate | Download (2.7 kB)
1 | f0cbd3ec | bellard | /*
|
---|---|---|---|
2 | f0cbd3ec | bellard | * Copyright (c) 1982, 1986, 1993
|
3 | f0cbd3ec | bellard | * The Regents of the University of California. All rights reserved.
|
4 | f0cbd3ec | bellard | *
|
5 | f0cbd3ec | bellard | * Redistribution and use in source and binary forms, with or without
|
6 | f0cbd3ec | bellard | * modification, are permitted provided that the following conditions
|
7 | f0cbd3ec | bellard | * are met:
|
8 | f0cbd3ec | bellard | * 1. Redistributions of source code must retain the above copyright
|
9 | f0cbd3ec | bellard | * notice, this list of conditions and the following disclaimer.
|
10 | f0cbd3ec | bellard | * 2. Redistributions in binary form must reproduce the above copyright
|
11 | f0cbd3ec | bellard | * notice, this list of conditions and the following disclaimer in the
|
12 | f0cbd3ec | bellard | * documentation and/or other materials provided with the distribution.
|
13 | f0cbd3ec | bellard | * 3. All advertising materials mentioning features or use of this software
|
14 | f0cbd3ec | bellard | * must display the following acknowledgement:
|
15 | f0cbd3ec | bellard | * This product includes software developed by the University of
|
16 | f0cbd3ec | bellard | * California, Berkeley and its contributors.
|
17 | f0cbd3ec | bellard | * 4. Neither the name of the University nor the names of its contributors
|
18 | f0cbd3ec | bellard | * may be used to endorse or promote products derived from this software
|
19 | f0cbd3ec | bellard | * without specific prior written permission.
|
20 | f0cbd3ec | bellard | *
|
21 | f0cbd3ec | bellard | * THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
|
22 | f0cbd3ec | bellard | * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
|
23 | f0cbd3ec | bellard | * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
|
24 | f0cbd3ec | bellard | * ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
|
25 | f0cbd3ec | bellard | * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
|
26 | f0cbd3ec | bellard | * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
|
27 | f0cbd3ec | bellard | * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
|
28 | f0cbd3ec | bellard | * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
|
29 | f0cbd3ec | bellard | * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
|
30 | f0cbd3ec | bellard | * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
|
31 | f0cbd3ec | bellard | * SUCH DAMAGE.
|
32 | f0cbd3ec | bellard | *
|
33 | f0cbd3ec | bellard | * @(#)icmp_var.h 8.1 (Berkeley) 6/10/93
|
34 | f0cbd3ec | bellard | * icmp_var.h,v 1.4 1995/02/16 00:27:40 wollman Exp
|
35 | f0cbd3ec | bellard | */
|
36 | f0cbd3ec | bellard | |
37 | f0cbd3ec | bellard | #ifndef _NETINET_ICMP_VAR_H_
|
38 | f0cbd3ec | bellard | #define _NETINET_ICMP_VAR_H_
|
39 | f0cbd3ec | bellard | |
40 | f0cbd3ec | bellard | /*
|
41 | f0cbd3ec | bellard | * Variables related to this implementation
|
42 | f0cbd3ec | bellard | * of the internet control message protocol.
|
43 | f0cbd3ec | bellard | */
|
44 | f0cbd3ec | bellard | struct icmpstat {
|
45 | f0cbd3ec | bellard | /* statistics related to input messages processed */
|
46 | f0cbd3ec | bellard | u_long icps_received; /* #ICMP packets received */
|
47 | f0cbd3ec | bellard | u_long icps_tooshort; /* packet < ICMP_MINLEN */
|
48 | f0cbd3ec | bellard | u_long icps_checksum; /* bad checksum */
|
49 | f0cbd3ec | bellard | u_long icps_notsupp; /* #ICMP packets not supported */
|
50 | f0cbd3ec | bellard | u_long icps_badtype; /* #with bad type feild */
|
51 | f0cbd3ec | bellard | u_long icps_reflect; /* number of responses */
|
52 | f0cbd3ec | bellard | }; |
53 | f0cbd3ec | bellard | |
54 | f0cbd3ec | bellard | /*
|
55 | f0cbd3ec | bellard | * Names for ICMP sysctl objects
|
56 | f0cbd3ec | bellard | */
|
57 | f0cbd3ec | bellard | #define ICMPCTL_MASKREPL 1 /* allow replies to netmask requests */ |
58 | f0cbd3ec | bellard | #define ICMPCTL_STATS 2 /* statistics (read-only) */ |
59 | f0cbd3ec | bellard | #define ICMPCTL_MAXID 3 |
60 | f0cbd3ec | bellard | |
61 | f0cbd3ec | bellard | #define ICMPCTL_NAMES { \
|
62 | f0cbd3ec | bellard | { 0, 0 }, \ |
63 | f0cbd3ec | bellard | { "maskrepl", CTLTYPE_INT }, \
|
64 | f0cbd3ec | bellard | { "stats", CTLTYPE_STRUCT }, \
|
65 | f0cbd3ec | bellard | } |
66 | f0cbd3ec | bellard | |
67 | f0cbd3ec | bellard | extern struct icmpstat icmpstat; |
68 | f0cbd3ec | bellard | |
69 | f0cbd3ec | bellard | #endif |