]> The Tcpdump Group git mirrors - tcpdump/commitdiff
Add a #define for the OUI for LLC+SNAP-encapsulated Ethernet.
authorguy <guy>
Mon, 4 Jun 2001 05:47:13 +0000 (05:47 +0000)
committerguy <guy>
Mon, 4 Jun 2001 05:47:13 +0000 (05:47 +0000)
Treat LLC+SNAP packets with an OUI of 0x0000f8 the same way we treat
encapsulated Ethernet packets - that OUI is used by Cisco for some forms
of bridging.

llc.h
print-llc.c

diff --git a/llc.h b/llc.h
index 1981cbe970a13ffb67705de1de1103e9279831ab..768858f75bf707ec451fc82102b164f8028ac0fd 100644 (file)
--- a/llc.h
+++ b/llc.h
@@ -18,7 +18,7 @@
  * WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE IMPLIED WARRANTIES OF
  * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
  *
- * @(#) $Header: /tcpdump/master/tcpdump/llc.h,v 1.12 2001-05-10 02:57:57 fenner Exp $ (LBL)
+ * @(#) $Header: /tcpdump/master/tcpdump/llc.h,v 1.13 2001-06-04 05:47:13 guy Exp $ (LBL)
  */
 
 /*
@@ -125,6 +125,8 @@ struct llc {
 #define        LLCSAP_ISONS            0xfe
 #endif
 
-#define        OUI_CISCO       0x00000c
+#define        OUI_ENCAP_ETHER 0x000000        /* encapsulated Ethernet */
+#define        OUI_CISCO       0x00000c        /* Cisco protocols */
 #define        ETHERTYPE_CISCO_CDP     0x2000  /* Cisco Discovery Protocol */
-#define        OUI_APPLETALK   0x080007
+#define        OUI_CISCO_90    0x0000f8        /* Cisco bridging */
+#define        OUI_APPLETALK   0x080007        /* Appletalk */
index 5aa02dff7fcbd41b25e3213b1f31b1c440d60d7b..442305ae2df01435b057a5000b327d9ad5ca6e8f 100644 (file)
@@ -24,7 +24,7 @@
 
 #ifndef lint
 static const char rcsid[] =
-    "@(#) $Header: /tcpdump/master/tcpdump/print-llc.c,v 1.37 2001-05-10 02:57:57 fenner Exp $";
+    "@(#) $Header: /tcpdump/master/tcpdump/print-llc.c,v 1.38 2001-06-04 05:47:14 guy Exp $";
 #endif
 
 #ifdef HAVE_CONFIG_H
@@ -185,8 +185,14 @@ llc_print(const u_char *p, u_int length, u_int caplen,
                orgcode = EXTRACT_24BITS(&llc.llc_orgcode[0]);
                et = EXTRACT_16BITS(&llc.llc_ethertype[0]);
                switch (orgcode) {
-               case 0x000000:
-                       /* This is an encapsulated Ethernet packet */
+               case OUI_ENCAP_ETHER:
+               case OUI_CISCO_90:
+                       /*
+                        * This is an encapsulated Ethernet packet,
+                        * or a packet bridged by some piece of
+                        * Cisco hardware; the protocol ID is
+                        * an Ethernet protocol type.
+                        */
                        ret = ether_encap_print(et, p, length, caplen,
                            extracted_ethertype);
                        if (ret)