Commit Graph

37 Commits

Author SHA1 Message Date
Jakub Zawadzki 5ac6474c94 Rename some of pint.h macros to match common style (bits number on the end).
pntohs  -> pntoh16
   pntohl  -> pntoh32
   pletohs -> pletoh16
   pletohl -> pletoh32
   phtons  -> phton16
   phtonl  -> phton32


svn path=/trunk/; revision=53652
2013-11-29 18:59:06 +00:00
Michael Mann bf9fdc8e8f Bugfix timestamp formatting of Gigamon trailer. Bug 9433 (https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=9433)
From Sandeep Dahiya

svn path=/trunk/; revision=53646
2013-11-29 14:55:49 +00:00
Michael Mann f34e11fabe Convert ethertype() function into a pure dissector. Bug 9454 (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-20 02:28:14 +00:00
Jakub Zawadzki c9b2ee3768 include <wsutil/pint.h> only when needed.
svn path=/trunk/; revision=53196
2013-11-09 15:44:29 +00:00
Michael Mann 9e3f9b449f expert_add_info_format_text -> expert_add_info_format
svn path=/trunk/; revision=51852
2013-09-09 00:44:09 +00:00
Michael Mann 0c49b4d872 Add filterable expert info to dissect_802_3() and clean up the shrapnel.
svn path=/trunk/; revision=51761
2013-09-05 01:39:35 +00:00
Michael Mann 5bc22a25df Batch of filterable expert infos.
svn path=/trunk/; revision=49584
2013-05-26 03:29:07 +00:00
Anders Broman cacddebdb7 From Sandeep Dahiya:
Extend the value_string that show the platform from where the packet was captured.

https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=8624

svn path=/trunk/; revision=49133
2013-05-02 05:16:09 +00:00
Anders Broman dd33c46501 Improve heuristics for gmtrailer.
svn path=/trunk/; revision=48255
2013-03-11 19:32:33 +00:00
Chris Maynard c56910aa70 Fix CID 967205: Unused pointer value.
svn path=/trunk/; revision=47061
2013-01-14 15:09:12 +00:00
Guy Harris ef9384ff60 Fix uninitialized variable.
svn path=/trunk/; revision=47037
2013-01-11 20:25:05 +00:00
Guy Harris ebdc5f8d55 Get rid of unused variable.
svn path=/trunk/; revision=47035
2013-01-11 20:08:43 +00:00
Michael Mann 660e028212 Add support for expanded Gigamon Trailer format
from Sandeep Dahiya, bug 8191 (https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=8191)

svn path=/trunk/; revision=47033
2013-01-11 19:20:39 +00:00
Bill Meier 7cd0417af5 Fix numerous instances of a variable/parameter name "shadowing" a library function name;
(At least some (gcc ?) compilers give a "shadow" warning for these).

svn path=/trunk/; revision=46402
2012-12-05 15:56:36 +00:00
Jeff Morriss 2552c750e5 We always HAVE_CONFIG_H so don't bother checking whether we have it or not.
svn path=/trunk/; revision=45017
2012-09-20 02:03:38 +00:00
Jakub Zawadzki 5a8783f5b1 Initial commit to support yet another method of passing data between dissectors.
Add new parameter 'data' to heur_dissector_t and new_dissector_t, for now it's always NULL

svn path=/trunk/; revision=44860
2012-09-10 21:40:21 +00:00
Bill Meier 638d74d43f Use val_to_str_const() where appropriate;
Also (for a few files):
- create/use some extended value strings;
- remove unneeded #include files;
- remove unneeded variable initialization;
- re-order fcns slightly so prefs_reg_handoff...() at end, etc

svn path=/trunk/; revision=44438
2012-08-10 22:55:02 +00:00
Jakub Zawadzki bf81b42e1e Update Free Software Foundation address.
(COPYING will be updated in next commit)

svn path=/trunk/; revision=43536
2012-06-28 22:56:06 +00:00
Anders Broman 24d2178eb7 From Sandeep Dahiya.
Add support for Gigamon timestamp trailer (different from existing Gigamon header format).

https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=7365

svn path=/trunk/; revision=43346
2012-06-19 06:18:30 +00:00
Bill Meier 794757ae8f For proto_tree_add_item(..., proto_xxx, ...)use ENC_NA as the encoding arg.
Also: remove trailing whitespace for a number of files.

svn path=/trunk/; revision=39503
2011-10-21 02:10:19 +00:00
Bill Meier b666d5ca18 Fix some proto_tree_add_item() FT_ABSOLUTE_TIME encoding parameters:
Again: a tip o'the hat to Guy.


svn path=/trunk/; revision=39383
2011-10-12 14:12:36 +00:00
Bill Meier 4e57694d4a Convert 'encoding' parameter of certain proto_tree_add_item() calls in non-autogenerated epan/dissectors:
Specifically:  Replace FALSE|0 and TRUE|1 by ENC_BIG_ENDIAN|ENC_LITTLE_ENDIAN as
 the encoding parameter for proto_tree_add_item() calls which directly reference
 an item in hf[] which has a type of:
    FT_UINT8
    FT_UINT16
    FT_UINT24
    FT_UINT32
    FT_UINT64
    FT_INT8
    FT_INT16
    FT_INT24
    FT_INT32
    FT_INT64
    FT_FLOAT
    FT_DOUBLE


svn path=/trunk/; revision=39288
2011-10-06 03:35:44 +00:00
Bill Meier 94f36ca4ff Use ENC_NA as encoding for proto_tree_add_item() calls which directly reference an hf item (in hf[] with types:
FT_NONE
   FT_BYTES
   FT_IPV6
   FT_IPXNET
   FT_OID

Note: Encoding field set to ENC_NA only if the field was previously TRUE|FALSE|ENC_LITTLE_ENDIAN|ENC_BIG_ENDIAN

svn path=/trunk/; revision=39260
2011-10-04 22:44:31 +00:00
Guy Harris a8bc4a0d13 Rename the routines that handle dissector tables with unsigned integer
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-20 05:35:29 +00:00
Jeff Morriss 0267a5293d Fix an error in a comment I added last week.
svn path=/trunk/; revision=34480
2010-10-11 20:16:35 +00:00
Jeff Morriss 7321549932 Don't use a TRY/CATCH block just to ignore any exceptions thrown by
tvb_get_ntohs(): check the remaining tvb length instead.

svn path=/trunk/; revision=34435
2010-10-08 17:37:19 +00:00
Anders Broman 97d69446ea From tieuthunhi:
Add new time source for Gigamon header.
https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=5210

svn path=/trunk/; revision=34114
2010-09-14 14:43:56 +00:00
Gerald Combs b4a8226906 Check our field lengths. Should fix the recent randpkt errors.
svn path=/trunk/; revision=33481
2010-07-09 20:27:02 +00:00
Bill Meier c3f91fd021 Strengthen test for Gigamon trailer;
Change some indentation/spacing.

svn path=/trunk/; revision=33293
2010-06-23 00:04:37 +00:00
Bill Meier 875223e53e Ensure no exceptions thrown while checking for Gigamon trailer.
(Builds upon the previous commit by Anders).

svn path=/trunk/; revision=33291
2010-06-22 15:33:27 +00:00
Anders Broman 017e4d0dc0 If the trailer is less than 4 bytes it's not a Gigamon hdr.
svn path=/trunk/; revision=33287
2010-06-22 13:29:33 +00:00
Stig Bjørlykke a0e759ca9b Corrected copyright header.
svn path=/trunk/; revision=33276
2010-06-21 11:28:52 +00:00
Martin Mathieson e530123963 Added volatile to 'offset' (needed by my version of gcc).
svn path=/trunk/; revision=33275
2010-06-21 09:41:57 +00:00
Guy Harris 0b50e9c953 Properly terminate gmhdr_ftype_timestamp[].
svn path=/trunk/; revision=33273
2010-06-20 22:36:32 +00:00
Guy Harris 15f156c680 Mark pinfo as unused.
svn path=/trunk/; revision=33272
2010-06-20 21:43:52 +00:00
Bill Meier b9d5679284 More rework of the code:
- Refactor to use a separate function for common code;
 - Prefs callback not required;
 - Use val_to_str(...);
 - Fix issues relating to incorrect bytes highlighted in the hex view;

svn path=/trunk/; revision=33271
2010-06-20 21:18:48 +00:00
Stig Bjørlykke 41b8508c73 From tieuthunhi via bug 4887:
Add support for Gigamon headers (timestamp, source port, length, etc)
that are inserted by Gigamon network equipments.

From me:
Various cleanup:
- Register to "eth.trailer" heuristics for trailer.
- Use standard dumping of timestamp.
- Rewrote gmhdr_plfm_str handling.
- Dump srcport details in a subtree.
- Removed packte-gmhdr.h.
- Ensure the while-loop will end.

svn path=/trunk/; revision=33256
2010-06-19 01:43:11 +00:00