Fix for bug 5422:
authorjake <jake@f5534014-38df-0310-8fa8-9805f1628bb7>
Sat, 20 Nov 2010 18:14:30 +0000 (18:14 +0000)
committerjake <jake@f5534014-38df-0310-8fa8-9805f1628bb7>
Sat, 20 Nov 2010 18:14:30 +0000 (18:14 +0000)
Add support for dissecting SLL type 0x03 frames.

git-svn-id: http://anonsvn.wireshark.org/wireshark/trunk@34987 f5534014-38df-0310-8fa8-9805f1628bb7

epan/dissectors/packet-eth.c
epan/dissectors/packet-sll.c
epan/dissectors/packet-sll.h

index 3a4d31ec52fa894bf4e41a6c610f6b8d28ab1391..2f35619dbfe2f72aa36b5e9a4c753e70e2987998 100644 (file)
@@ -36,6 +36,7 @@
 #include "packet-ipx.h"
 #include "packet-isl.h"
 #include "packet-llc.h"
+#include "packet-sll.h"
 #include <epan/crc32.h>
 #include <epan/tap.h>
 #include <epan/expert.h>
@@ -755,6 +756,8 @@ proto_reg_handoff_eth(void)
        dissector_add("chdlctype", ETHERTYPE_ETHBRIDGE, eth_withoutfcs_handle);
        dissector_add("gre.proto", ETHERTYPE_ETHBRIDGE, eth_withoutfcs_handle);
 
+       dissector_add("sll.ltype", LINUX_SLL_P_ETHERNET, eth_withoutfcs_handle);
+
        /*
         * This is to handle the output for the Cisco CMTS "cable intercept"
         * command - it encapsulates Ethernet frames in UDP packets, but
index 4907bea69bb56e391acd44269a0df5f95b562c2a..902e53db0acb751f9152c17542a5f08b4bb6f626 100644 (file)
@@ -33,6 +33,7 @@
 #include "packet-sll.h"
 #include "packet-ipx.h"
 #include "packet-llc.h"
+#include "packet-eth.h"
 #include "packet-ppp.h"
 #include "packet-gre.h"
 #include <epan/addr_resolv.h>
@@ -78,6 +79,7 @@ static const value_string packet_type_vals[] = {
 
 static const value_string ltype_vals[] = {
        { LINUX_SLL_P_802_3,    "Raw 802.3" },
+       { LINUX_SLL_P_ETHERNET, "Ethernet" },
        { LINUX_SLL_P_802_2,    "802.2 LLC" },
        { LINUX_SLL_P_PPPHDLC,  "PPP (HDLC)" },
        { 0,                    NULL }
@@ -111,6 +113,13 @@ capture_sll(const guchar *pd, int len, packet_counts *ld)
                        capture_llc(pd, len, SLL_HEADER_SIZE, ld);
                        break;
 
+               case LINUX_SLL_P_ETHERNET:
+                       /*
+                        * Ethernet.
+                        */
+                       capture_eth(pd, SLL_HEADER_SIZE, len, ld);
+                       break;
+
                case LINUX_SLL_P_802_3:
                        /*
                         * Novell IPX inside 802.3 with no 802.2 LLC
index 35b893cc7bd932a9509f3d8a2261be977a786a84..5fd17b2b9ab5c1f505e2f5d42f25ff942feff378 100644 (file)
@@ -28,6 +28,7 @@
  * The LINUX_SLL_ values for "sll_protocol".
  */
 #define LINUX_SLL_P_802_3      0x0001  /* Novell 802.3 frames without 802.2 LLC header */
+#define LINUX_SLL_P_ETHERNET   0x0003  /* Ethernet */
 #define LINUX_SLL_P_802_2      0x0004  /* 802.2 frames (not D/I/X Ethernet) */
 #define LINUX_SLL_P_PPPHDLC    0x0007  /* PPP HDLC frames */