xref: /freebsd/contrib/tcpdump/af.c (revision 27df3f5dddcc52e19be97c5e876161208987d4f1)
1b5bfcb5dSMax Laier /*
2b5bfcb5dSMax Laier  * Copyright (c) 1998-2006 The TCPDUMP project
3b5bfcb5dSMax Laier  *
4b5bfcb5dSMax Laier  * Redistribution and use in source and binary forms, with or without
5b5bfcb5dSMax Laier  * modification, are permitted provided that: (1) source code
6b5bfcb5dSMax Laier  * distributions retain the above copyright notice and this paragraph
7b5bfcb5dSMax Laier  * in its entirety, and (2) distributions including binary code include
8b5bfcb5dSMax Laier  * the above copyright notice and this paragraph in its entirety in
9b5bfcb5dSMax Laier  * the documentation or other materials provided with the distribution.
10b5bfcb5dSMax Laier  * THIS SOFTWARE IS PROVIDED ``AS IS'' AND
11b5bfcb5dSMax Laier  * WITHOUT ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, WITHOUT
12b5bfcb5dSMax Laier  * LIMITATION, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
13b5bfcb5dSMax Laier  * FOR A PARTICULAR PURPOSE.
14b5bfcb5dSMax Laier  *
15b5bfcb5dSMax Laier  * Original code by Hannes Gredler (hannes@juniper.net)
16b5bfcb5dSMax Laier  */
17b5bfcb5dSMax Laier 
18b5bfcb5dSMax Laier #ifndef lint
19b5bfcb5dSMax Laier static const char rcsid[] _U_ =
20a5779b6eSRui Paulo     "@(#) $Header: /tcpdump/master/tcpdump/af.c,v 1.3 2006-03-23 14:58:44 hannes Exp $ (LBL)";
21b5bfcb5dSMax Laier #endif
22b5bfcb5dSMax Laier 
23b5bfcb5dSMax Laier #ifdef HAVE_CONFIG_H
24b5bfcb5dSMax Laier #include "config.h"
25b5bfcb5dSMax Laier #endif
26b5bfcb5dSMax Laier 
27b5bfcb5dSMax Laier #include <tcpdump-stdinc.h>
28b5bfcb5dSMax Laier #include "interface.h"
29b5bfcb5dSMax Laier #include "af.h"
30b5bfcb5dSMax Laier 
31*27df3f5dSRui Paulo const struct tok af_values[] = {
32b5bfcb5dSMax Laier     { 0,                      "Reserved"},
33b5bfcb5dSMax Laier     { AFNUM_INET,             "IPv4"},
34b5bfcb5dSMax Laier     { AFNUM_INET6,            "IPv6"},
35b5bfcb5dSMax Laier     { AFNUM_NSAP,             "NSAP"},
36b5bfcb5dSMax Laier     { AFNUM_HDLC,             "HDLC"},
37b5bfcb5dSMax Laier     { AFNUM_BBN1822,          "BBN 1822"},
38b5bfcb5dSMax Laier     { AFNUM_802,              "802"},
39b5bfcb5dSMax Laier     { AFNUM_E163,             "E.163"},
40b5bfcb5dSMax Laier     { AFNUM_E164,             "E.164"},
41b5bfcb5dSMax Laier     { AFNUM_F69,              "F.69"},
42b5bfcb5dSMax Laier     { AFNUM_X121,             "X.121"},
43b5bfcb5dSMax Laier     { AFNUM_IPX,              "Novell IPX"},
44b5bfcb5dSMax Laier     { AFNUM_ATALK,            "Appletalk"},
45b5bfcb5dSMax Laier     { AFNUM_DECNET,           "Decnet IV"},
46b5bfcb5dSMax Laier     { AFNUM_BANYAN,           "Banyan Vines"},
47b5bfcb5dSMax Laier     { AFNUM_E164NSAP,         "E.164 with NSAP subaddress"},
48b5bfcb5dSMax Laier     { AFNUM_L2VPN,            "Layer-2 VPN"},
49b5bfcb5dSMax Laier     { AFNUM_VPLS,             "VPLS"},
50b5bfcb5dSMax Laier     { 0, NULL},
51b5bfcb5dSMax Laier };
52b5bfcb5dSMax Laier 
53*27df3f5dSRui Paulo const struct tok bsd_af_values[] = {
54b5bfcb5dSMax Laier     { BSD_AFNUM_INET, "IPv4" },
55b5bfcb5dSMax Laier     { BSD_AFNUM_NS, "NS" },
56b5bfcb5dSMax Laier     { BSD_AFNUM_ISO, "ISO" },
57b5bfcb5dSMax Laier     { BSD_AFNUM_APPLETALK, "Appletalk" },
58b5bfcb5dSMax Laier     { BSD_AFNUM_IPX, "IPX" },
59b5bfcb5dSMax Laier     { BSD_AFNUM_INET6_BSD, "IPv6" },
60b5bfcb5dSMax Laier     { BSD_AFNUM_INET6_FREEBSD, "IPv6" },
61b5bfcb5dSMax Laier     { BSD_AFNUM_INET6_DARWIN, "IPv6" },
62b5bfcb5dSMax Laier     { 0, NULL}
63b5bfcb5dSMax Laier };
64