aboutsummaryrefslogtreecommitdiffstats
path: root/epan/dissectors/packet-ethertype.c
AgeCommit message (Collapse)AuthorFilesLines
2013-11-23Create the ability to have packet scoped "proto" data. Bug 9470 ↵Michael Mann1-3/+3
(https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=9470) I'm not sold on the name or module the proto_data functions live in, but I believe the function arguments are solid and gives us the most flexibility for the future. And search/replace of a function name is easy enough to do. The big driving force for getting this in sooner rather than later is the saved memory on ethernet packets (and IP packets soon), that used to have file_scope() proto data when all it needed was packet_scope() data (technically packet_info->pool scoped), strictly for Decode As. All dissectors that use p_add_proto_data() only for Decode As functionality have been converted to using packet_scope(). All other dissectors were converted to using file_scope() which was the original scope for "proto" data. svn path=/trunk/; revision=53520
2013-11-21Widen the Ethertype to a guint, to avoid compiler warnings.Guy Harris1-1/+1
Fix indentation while we're at it. svn path=/trunk/; revision=53493
2013-11-21Remove ethertype, mpls_label and ppids from packet_info structure.Michael Mann1-3/+4
The information was converted to "proto" data within their respective dissectors strictly for use in "Decode As". svn path=/trunk/; revision=53489
2013-11-20Provide "Decode As" functionality through dissectors themselves instead of ↵Michael Mann1-4/+24
the GUI. Bug 9450 (https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=9450) The basic idea behind this design is to have dissectors register with a "decode as list" with their name and dissector table. When "Decode As" dialog is launched, any "registered" dissector found in the packet will cause a tab to be created in the dialog. This patch includes just the dissector portion of the functionality (minus packet-dcerpc.[ch] because it has hooks to the current GUI) svn path=/trunk/; revision=53445
2013-11-20Convert ethertype() function into a pure dissector. Bug 9454 ↵Michael Mann1-16/+27
(https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=9454) The main driving force for this was my new Decode As functionality (https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=9450) that wants a dissector/subdissector table relationship for all dissectors wanting to use Decode As functionality. The ethertype() function provides the value to the "ethertype" subdissector table, so I think it should be matched to a dissector. Only odd side effect is the display filter of "ethertype" returns no packets because there is no "item" associated with the dissector. svn path=/trunk/; revision=53443
2013-11-10Add missing includes in order to remove exceptions.h from proto.h (next commit).Jakub Zawadzki1-0/+1
svn path=/trunk/; revision=53230
2013-10-21Remove if (fh_tree) checks as add_ethernet_trailer() calls such functions as ↵Chris Maynard1-3/+0
dissector_try_heuristic(), expert_add_info(), and col_append_str(), which all need to be called whether fh_tree is NULL or not. #BACKPORT(1.10,1.8) svn path=/trunk/; revision=52738
2013-10-18Beginnings of Motrola's MiNT protocol.Jörg Mayer1-0/+1
Most important missing item: Fill in the test functions to avoid using all packets to the (fixed) ports. svn path=/trunk/; revision=52669
2013-08-07From Vaibhav Katkade via ↵Jeff Morriss1-0/+1
https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=9011 : Add support for the Cisco MetaData (0x8909) ethertype. From me: Don't try to register the "eth.type" abbreviation; use "cmd.type" instead. Add SVN id. Clean up trailing white space and fix up some indentation. Don't declare a variable static that need not be. svn path=/trunk/; revision=51198
2013-03-29Rename value string (and similar) functions to use a consistent pattern. ThisEvan Huus1-1/+1
was done using textual search+replace, not anything syntax-aware, so presumably it got most comments as well (except where there were typos). Use a consistent coding style, and make proper use of the WS_DLL_* defines. Group the functions appropriately in the header. I ended up getting rid of most of the explanatory comments since many of them duplicated what was in the value_string.c file (and were out of sync with the recent updates I made to those in r48633). Presumably most of the comments should be in the .h file not the .c file, but there's enough churn ahead that it's not worth fixing yet. Part of https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=8467 svn path=/trunk/; revision=48634
2013-03-17[-Wmissing-prototypes]Anders Broman1-0/+4
Use explicit casts. svn path=/trunk/; revision=48347
2013-02-27Move show_exception() and show_reported_bounds_error() toGuy Harris1-30/+12
epan/show_exception.c, as it's used outside epan/dissectors/packet-frame.c. Update their callers to include <epan/show_exception.h> to get their declaration. Add a CATCH_NONFATAL_ERRORS macro that catches all exceptions that, if there's more stuff in the packet to dissect after the dissector call that threw the exception, doesn't mean you shouldn't go ahead and dissect that stuff. Use it in all those cases, including ones where BoundsError was inappropriately being caught (you want those passed up to the top level, so that the packet is reported as having been cut short in the capture process). Add a CATCH_BOUNDS_ERRORS macro that catches all exceptions that correspond to running past the end of the data for a tvbuff; use it rather than explicitly catching those exceptions individually, and rather than just catching all exceptions (the only place that DissectorError should be caught, for example, is at the top level, so dissector bugs show up in the protocol tree). Don't catch and then immediately rethrow exceptions without doing anything else; just let the exceptions go up to the final catcher. Use show_exception() to report non-fatal errors, rather than doing it yourself. If a dissector is called from Lua, catch all non-fatal errors and use show_exception() to report them rather than catching only ReportedBoundsError and adding a proto_malformed item. Don't catch exceptions when constructing a trailer tvbuff in packet-ieee8023.c - just construct it after the payload has been dissected, and let whatever exceptions that throws be handled at the top level. Avoid some TRY/CATCH/ENDTRY cases by using checks such as tvb_bytes_exist() before even looking in the tvbuff. svn path=/trunk/; revision=47924
2013-02-16Add Ethertype for Network Controller Sideband InterfaceJörg Mayer1-0/+1
svn path=/trunk/; revision=47691
2012-12-27Add Media Independent Handover Protocol ethertypeAnders Broman1-0/+1
svn path=/trunk/; revision=46801
2012-11-06Add ETHERTYPE_ATMOEAnders Broman1-0/+1
svn path=/trunk/; revision=45951
2012-09-20We always HAVE_CONFIG_H so don't bother checking whether we have it or not.Jeff Morriss1-3/+1
svn path=/trunk/; revision=45017
2012-08-02From Richard Stearn: add support for BPQ (AX.25 on Ethernet).Guy Harris1-0/+5
svn path=/trunk/; revision=44232
2012-07-20Add some relevant ethertypes.Jaap Keuter1-0/+4
svn path=/trunk/; revision=43850
2012-04-26Whitespace cleanup: Indentation, trailing, ...Bill Meier1-169/+169
svn path=/trunk/; revision=42266
2011-10-31From Martin Renold via https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=5730Alexis La Goutte1-1/+2
Dissector for HSR and PRP-1 Here is a patch that adds a dissector for HSR and for PRP-1. Both protocols are defined in IEC62439 Part 3. (High-availability Seamless Redundancy / Parallel Redundancy Protocol) The existing PRP dissector has been refactored to support both the old PRP (now called PRP-0) and the new PRP-1. There are three distinct dissectors: - HSR (ethertype 892F) - HSR/PRP supervision (ethertype 88FB) - PRP-0 and PRP-1 (trailer dissector; disabled by default) From me : * Fix Clang Warning * Add modification for CMakeLists.txt svn path=/trunk/; revision=39692
2011-09-23Remove code commited by misstake.Anders Broman1-13/+2
svn path=/trunk/; revision=39101
2011-09-23Revert Revision 34838 "Resolve bug #2254: Migrate the 802.1q VLAN dissector ↵Anders Broman1-3/+15
into the Ethernet II." as this causes a lot of problems. See https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=5680 https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=6305 https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=6366 Original bug: https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=2254 svn path=/trunk/; revision=39100
2011-09-07Add ethertype #8903Anders Broman1-0/+1
svn path=/trunk/; revision=38912
2011-06-23From Dejan Bucar:Jaap Keuter1-0/+1
Added support new multicore header in the LINX Ethernet protocol. Added linx/tcp. svn path=/trunk/; revision=37777
2011-05-25From Florian Fainelli:Anders Broman1-0/+1
Patch adding the Homeplug AV ethertype. Part of https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=5943 svn path=/trunk/; revision=37388
2011-05-12From Johannes Jochen via ↵Jeff Morriss1-0/+1
https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=5900 : I have created a dissector for the Multiple MAC Registration Protocol based on the exiting dissector of the Multiple Stream Reservation Protocol (bugzilla id: 4757 ) You can found the documentation of the Protocol here: http://standards.ieee.org/getieee802/download/802.1ak-2007.pdf It's also includes the corrections of the protocol you will found here: http://standards.ieee.org/getieee802/download/802.1Q-2005_Cor1-2008.pdf svn path=/trunk/; revision=37104
2011-04-06Add RoHC to the ethertypes.Anders Broman1-1/+2
svn path=/trunk/; revision=36499
2010-12-20Rename the routines that handle dissector tables with unsigned integerGuy Harris1-1/+1
keys to have _uint in their names, to match the routines that handle dissector tables with string keys. (Using _port can confuse people into thinking they're intended solely for use with TCP/UDP/etc. ports when, in fact, they work better for things such as Ethernet types, where the binding of particular values to particular protocols are a lot stronger.) svn path=/trunk/; revision=35224
2010-12-16From Jouni Malinen:Anders Broman1-0/+1
Add support for dissecting TDLS (IEEE 802.11z) frames. These are mostly used as Action frames that are encapsulated in Data frames (to go through any AP). https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=5493 svn path=/trunk/; revision=35208
2010-11-10Resolve bug #2254: Migrate the 802.1q VLAN dissector into the Ethernet II.Stephen Fisher1-2/+1
svn path=/trunk/; revision=34838
2010-11-02From Daniel Ginsburg:Jaap Keuter1-0/+1
draft-ietf-isis-ext-eth specifies an extension to current Ethernet Frame specifications for hardware and frame format to support payloads greater than 1500 Bytes for Type interpretation and Length interpretation frames. The extension introduced by draft-ietf-isis-ext-eth is currently used by Cisco Systems' IS-IS routing protocol implementation when running IS-IS over Ethernet links with large MTU. svn path=/trunk/; revision=34748
2010-10-08Restore pinfo->private_data after an exception was thrown by a subdissector.Jeff Morriss1-15/+18
This is necessary in case a subdissector had changed it but was unable to restore it (due to the exception). Remove check_col(). svn path=/trunk/; revision=34436
2010-09-22From Lukasz Kotasa via bug 5248:Stig Bjørlykke1-0/+1
Added ETHERTYPE_WAI. svn path=/trunk/; revision=34180
2010-08-03From Slava:Anders Broman1-0/+1
Infiniband RoCE dissection. https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=5060 svn path=/trunk/; revision=33702
2010-06-23From Haakon Nessjoen: New dissector for Digiums TDMoE protocolBill Meier1-0/+1
From me: A few minor changes: - col-clear() not req'd; - Use 'gint32 length' rather than 'guint8 length'; - Use ENC_NA instead of FALSE/TRUE in two cases; - Move global tdmoe_handle to be local to proto_reg_handoff... svn path=/trunk/; revision=33307
2010-06-19Use top level tree when using dissectors from "eth.trailer" heuristics.Stig Bjørlykke1-4/+4
svn path=/trunk/; revision=33255
2010-06-18Add the Gigamon ethertype.Anders Broman1-0/+1
svn path=/trunk/; revision=33250
2010-05-24Move VLAN and ARP closer to the top.Anders Broman1-2/+2
svn path=/trunk/; revision=32927
2010-05-17From Torrey Atcitty: IEEE 1722(AVB Transport Protocol) DissectorBill Meier1-0/+1
See Bug #4764 (https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=4764) svn path=/trunk/; revision=32841
2010-05-14From Torrey Atcitty: IEEE 802.1Qat (Multiple Stream Reservation Protocol) ↵Bill Meier1-0/+1
dissector See: Bug #4757: https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=4757 svn path=/trunk/; revision=32816
2010-04-05From David Aggeler:Anders Broman1-0/+1
Added 0x88DE to etypes.h Added ETHERTYPE_VMLAB https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=4186 svn path=/trunk/; revision=32378
2010-01-03Reformat value_string, its comments and whitespace.Stephen Fisher1-91/+92
svn path=/trunk/; revision=31415
2009-11-24From Juha Siltanen :Jaap Keuter1-0/+1
This is a patch for a new dissector that decodes Nokia Siemens Networks' proprietary Flow Layer Internal Protocol (Ethertype 0x8901). svn path=/trunk/; revision=31069
2009-08-26From dragonlinux:Anders Broman1-0/+4
Add QNX OS VER 6's qnet ethernet protocol number. https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=3934 svn path=/trunk/; revision=29558
2009-08-16Switch a bunch of dissectors over to using tvb_new_subset_remaining()Kovarththanan Rajaratnam1-2/+2
svn path=/trunk/; revision=29446
2009-07-09From Joakim Wiberg:Anders Broman1-1/+2
Device Level Ring protocol addition. https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=3685 With some minor changes (blurb NULL whem text equal). svn path=/trunk/; revision=29044
2009-05-05The only callers of ethertype() should be dissectors for protocols withGuy Harris1-4/+3
Ethernet-type trailers; no callers are left that don't at least purport to care about them. svn path=/trunk/; revision=28284
2009-04-13Add XiMeta Technology's ethertype.Anders Broman1-7/+8
(https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=3392) svn path=/trunk/; revision=28040
2008-12-10From Benjamin Roch:Jaap Keuter1-0/+1
This contains the source for dissecting TTEthernet packets (including Protocol Control Frames) conforming to our TTEthernet specification as dissector for Wireshark. svn path=/trunk/; revision=26955
2008-11-22From Peter (bug 2942):Stig Bjørlykke1-1/+1
Allow optimalization with -ftracer. svn path=/trunk/; revision=26822