Commit Graph

65 Commits

Author SHA1 Message Date
Michael Mann 8b0e9c6672 Follow up for proto_tree_add_checksum.
Fill in the "gaps" so that all dissectors that verify checksums have both a
status and expert info field.

Also address comments from original proto_tree_add_checksum patch that didn't make it.

Ping-Bug: 8859
Change-Id: I2e6640108fd6bb218cb959fe9e4ba98a13e43a2f
Reviewed-on: https://code.wireshark.org/review/16590
Petri-Dish: Michael Mann <mmann78@netscape.net>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Anders Broman <a.broman58@gmail.com>
2016-07-27 03:40:02 +00:00
Michael Mann ad6fc87d64 Add proto_tree_add_checksum.
This is an attempt to standardize display/handling of checksum fields for all dissectors.
The main target is for dissectors that do validation, but dissectors that just report the
checksum were also included just to make them easier to find in the future.

Bug: 10620
Bug: 12058
Ping-Bug: 8859
Change-Id: Ia8abd86e42eaf8ed50de6b173409e914b17993bf
Reviewed-on: https://code.wireshark.org/review/16380
Petri-Dish: Michael Mann <mmann78@netscape.net>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Jeff Morriss <jeff.morriss.ws@gmail.com>
Reviewed-by: Michael Mann <mmann78@netscape.net>
2016-07-21 12:35:22 +00:00
Michael Mann 886e2bfbb9 Use some FT_BYTE "BASE"s in isis dissectors.
Change-Id: I59acb37250f6248e985482e4b972250e295fd638
Reviewed-on: https://code.wireshark.org/review/15469
Petri-Dish: Anders Broman <a.broman58@gmail.com>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Alexis La Goutte <alexis.lagoutte@gmail.com>
Reviewed-by: Anders Broman <a.broman58@gmail.com>
2016-05-18 03:39:11 +00:00
moshekaplan cd7026951b Fix a lot of typos and misspellings
Change-Id: I8512cfa1d424f82a873a0e0e1d22c7b075fdd7f3
Reviewed-on: https://code.wireshark.org/review/13069
Reviewed-by: Alexis La Goutte <alexis.lagoutte@gmail.com>
Petri-Dish: Alexis La Goutte <alexis.lagoutte@gmail.com>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Michael Mann <mmann78@netscape.net>
2016-01-08 20:04:56 +00:00
Michael Mann 443a7ed259 new_create_dissector_handle -> create_dissector_handle for dissector directory.
Some of the ASN.1 dissectors still generate a new_create_dissector_handle from the tool itself, so leave those for now.

Change-Id: Ic6e5803b1444d7ac24070949f5fd557909a5641f
Reviewed-on: https://code.wireshark.org/review/12484
Petri-Dish: Anders Broman <a.broman58@gmail.com>
Reviewed-by: Michael Mann <mmann78@netscape.net>
2015-12-09 12:37:36 +00:00
Alexis La Goutte 2f5849cc8c IS-IS: Add Instance ID TLV (RFC 6822)
Bug:11649
Change-Id: I852b0f93797ba9e67c2772f482182b1f0d753a43
Reviewed-on: https://code.wireshark.org/review/12254
Reviewed-by: Alexis La Goutte <alexis.lagoutte@gmail.com>
Petri-Dish: Alexis La Goutte <alexis.lagoutte@gmail.com>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Michael Mann <mmann78@netscape.net>
2015-11-28 19:07:04 +00:00
Alexis La Goutte d3e40e499a ISIS: Add Expert Info when undecoded/unknown CLV
Change-Id: I8048954cce6a370cc37faad62b657704f6ccef6a
Reviewed-on: https://code.wireshark.org/review/12255
Reviewed-by: Alexis La Goutte <alexis.lagoutte@gmail.com>
Petri-Dish: Alexis La Goutte <alexis.lagoutte@gmail.com>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Michael Mann <mmann78@netscape.net>
2015-11-28 19:04:48 +00:00
Michael Mann 921a844200 Remove use of APPEND_BOOLEAN_FLAG in favor of proto_tree_add_bitmask_with_flags.
The "flags" used in proto_tree_add_bitmask-like functions can provide the same functionality of APPEND_BOOLEAN_FLAG, so it simplifies the dissector.

Change-Id: I7c87cbcc9b33588bc0eea6630e03b591f9f27fc8
Reviewed-on: https://code.wireshark.org/review/12145
Reviewed-by: Michael Mann <mmann78@netscape.net>
Petri-Dish: Michael Mann <mmann78@netscape.net>
Petri-Dish: Alexis La Goutte <alexis.lagoutte@gmail.com>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Alexis La Goutte <alexis.lagoutte@gmail.com>
2015-11-26 11:27:31 +00:00
Jim Young e3c46268be isis-hello: Fix typo "Srea" -> "Area"
Change-Id: Ia251638186857d6be6a07c25e77bbd7e72a14290
Reviewed-on: https://code.wireshark.org/review/11620
Reviewed-by: Anders Broman <a.broman58@gmail.com>
2015-11-07 07:46:00 +00:00
Jim Young 56d0127247 ISIS Hello: Restore correct dissection of SPB BVID
Commit 301a5b7cea introduced a small
regression with the dissection of the BVID.  BVID should be extracted
from the 12 most significant bits not the 12 least significant bits.
Make it so.

Change-Id: Idcf0492eea1f6cb7282641ae243aa7092e5a1418
Reviewed-on: https://code.wireshark.org/review/11472
Reviewed-by: Anders Broman <a.broman58@gmail.com>
2015-11-01 08:48:50 +00:00
Evan Huus 69cdfe9410 Remove another batch of deprecated tvb_length calls
Change-Id: Icfdde38e40cca05d0705a081153a4ea3e8782ee7
Reviewed-on: https://code.wireshark.org/review/9086
Reviewed-by: Evan Huus <eapache@gmail.com>
2015-06-24 04:30:35 +00:00
Evan Huus 8bc294c0d1 Replace more deprecated tvb_length calls
The return values of new-style dissectors always use the captured length, so
replace those automagically with sed.

Change-Id: Ic43072ee4a80d433cd4264444583a0e670adc26a
Reviewed-on: https://code.wireshark.org/review/9065
Reviewed-by: Evan Huus <eapache@gmail.com>
2015-06-23 18:25:52 +00:00
Guy Harris fdd6554ccd Rename the FT_BYTES separator types to SEP_ from BASE_.
There's no requirement for "display" field values to have names
beginning with BASE_; use SEP_, to indicate that they're separators.

(And, yes, we should introduce SEP_NONE, with a value of 0, and use it.)

While we're at it, fix BASE_SEMICOLON - the separator is a colon, not a
semicolon - and document SEP_SPACE in doc/README.dissector.

Change-Id: I856aafda2c60b8320dffe287f0deb06a9604a2bf
Reviewed-on: https://code.wireshark.org/review/6486
Reviewed-by: Guy Harris <guy@alum.mit.edu>
2015-01-11 00:27:28 +00:00
Michael Mann 553da37446 Create BASE_DOT, BASE_DASH, and BASE_SEMICOLON types for the FT_BYTES field type.
These "bases" will put a ".", "-", or ":" respectively between hexidecimal bytes in the field in packet view and display filter.  FT_BYTES with BASE_NONE will have no separator in the packet view, but continue to have the ':' as a separator in the display filter.

Converted the "string" hf_ entries that used tvb_fc_to_str as a string to use proto_tree_add_item with FT_BYTES/BASE_DOT type.

Converted applicable tvb_bytes_to_ep_str_punct() calls to use the new BASE values.

Change-Id: I2442185bb314d04a3ff2ba57883652ecd738b5f9
Reviewed-on: https://code.wireshark.org/review/6098
Reviewed-by: Michael Mann <mmann78@netscape.net>
2015-01-04 16:32:03 +00:00
Martin Mathieson 86ed26f0b8 Deleting unnecessary #includes from dissectors.
Third batch (packet-icmpv6.c -> packet-mac-lte.c).

Will look at cleaning up and committing script afterwards.

Change-Id: Ib91e36ad200db01c3000605f6a7a21125b96a640
Reviewed-on: https://code.wireshark.org/review/6018
Petri-Dish: Martin Mathieson <martin.r.mathieson@googlemail.com>
Reviewed-by: Martin Mathieson <martin.r.mathieson@googlemail.com>
2014-12-23 14:44:28 +00:00
Bill Meier b5d7b7ab6e Cleanup use of #includes in non-generated epan/dissector/*.c
Specifically:
- Set packet.h to be the first wireshark #include after
   config.h and "system" #includes.
   packet.h added as an #include in some cases when missing.
- Remove some #includes included (directly/indirectly) in
   packet.h. E.g., glib.h.
   (Done only for those files including packet.h).
- As needed, move "system" #includes to be after config.h and
   before wireshark #includes.
- Rework various #include file specifications for consistency.
- Misc.

Change-Id: Ifaa1a14b50b69fbad38ea4838a49dfe595c54c95
Reviewed-on: https://code.wireshark.org/review/5923
Petri-Dish: Alexis La Goutte <alexis.lagoutte@gmail.com>
Reviewed-by: Bill Meier <wmeier@newsguy.com>
2014-12-21 05:46:22 +00:00
Bill Meier f412c9a01a Use ENC_BIG_ENDIAN when fetching FT_U?INT8 fields ...
(for some dissectors which fetch all other integral fields using
   ENC_BIG_ENDIAN).

Change-Id: Ic18e3172aad76af12b12d6732c88497be22aed56
Reviewed-on: https://code.wireshark.org/review/5748
Reviewed-by: Bill Meier <wmeier@newsguy.com>
2014-12-13 18:45:56 +00:00
Michael Mann 301a5b7cea Eliminate proto_tree_add_text from some dissectors.
Change-Id: I44cc6b70ec4dfc565934da499f46fca60a4ded93
Reviewed-on: https://code.wireshark.org/review/5524
Reviewed-by: Michael Mann <mmann78@netscape.net>
Petri-Dish: Michael Mann <mmann78@netscape.net>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Anders Broman <a.broman58@gmail.com>
2014-12-09 05:57:41 +00:00
Michael Mann 4f9af8608c Use proto_tree_add_bitmask for groups of proto_tree_add_boolean.
Part 2 of many

Change-Id: I50815e7738b011382392f3078a7107d3d9eec4ec
Reviewed-on: https://code.wireshark.org/review/5542
Reviewed-by: Michael Mann <mmann78@netscape.net>
Petri-Dish: Michael Mann <mmann78@netscape.net>
Reviewed-by: Anders Broman <a.broman58@gmail.com>
2014-12-01 08:52:03 +00:00
Alexis La Goutte 6c93cc4edb Fix Dead Store (Dead assignement/Dead increment) warning found by Clang
Change-Id: I32ca31b879ccc458f12f37375c32bc089978b114
Reviewed-on: https://code.wireshark.org/review/3933
Reviewed-by: Evan Huus <eapache@gmail.com>
2014-08-31 20:20:38 +00:00
Marian Durkovic d3c649b482 TRILL ISIS: Implement all RFC7176 section 2.2 SubTLVs
Bug:10391
Change-Id: Ibdf3e4964668a57362b6d25ef4ae106d368f0e69
Reviewed-on: https://code.wireshark.org/review/3668
Reviewed-by: Alexis La Goutte <alexis.lagoutte@gmail.com>
2014-08-25 14:31:01 +00:00
Marian Ďurkovič 76a674f0cf TRILL ISIS: Implement TRILL Neighbor TLV (145)
Change-Id: I1b17b0ef26150fdc68b966f4837953f9832883cb
Reviewed-on: https://code.wireshark.org/review/3717
Petri-Dish: Anders Broman <a.broman58@gmail.com>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Anders Broman <a.broman58@gmail.com>
2014-08-22 10:56:19 +00:00
Marian Ďurkovič 8670d9fdfe TRILL ISIS: Unify MTID presentation in all cases
Change-Id: I66eb683d6b1f9dccae3e566ad4dd4cfd18b81ddb
Reviewed-on: https://code.wireshark.org/review/3713
Reviewed-by: Evan Huus <eapache@gmail.com>
2014-08-19 18:34:19 +00:00
Guy Harris e926023a9c Squelch unused parameter warnings.
Change-Id: I3bf3c0500bf27e6f1a3c1df57f3141ea34692304
Reviewed-on: https://code.wireshark.org/review/3683
Reviewed-by: Guy Harris <guy@alum.mit.edu>
2014-08-18 03:59:24 +00:00
Marian Durkovic 4095bbf9e8 Make TRILL NEIGHBOR TLV (145) known to ISIS dissector
Update RFC references

Change-Id: I977190e6bfce2c27d33f940d058be3be6a5ef3c0
Reviewed-on: https://code.wireshark.org/review/3669
Reviewed-by: Michael Mann <mmann78@netscape.net>
2014-08-18 00:51:45 +00:00
Marian Durkovic 762e762668 Fix TRILL ISIS Hellos:
- MT Port Capability TLVs are present in L1 Hellos
- unify texts

Change-Id: I3dade81ad4487620a8e46e0b242bbbffbb6c2d49
Reviewed-on: https://code.wireshark.org/review/3659
Reviewed-by: Evan Huus <eapache@gmail.com>
2014-08-16 22:02:19 +00:00
Alexis La Goutte 143cdf12d3 ISIS: Add type and length to CLV
Change-Id: If6dc8e3a9328571ccdb106b0aabc617889c434c7
Reviewed-on: https://code.wireshark.org/review/3465
Reviewed-by: Evan Huus <eapache@gmail.com>
2014-08-08 13:19:23 +00:00
Alexis La Goutte 53b209650b Add Modelines and fix indent
Change-Id: I7abb415bccff4de846ab273eed3e3b2a434d94b7
Reviewed-on: https://code.wireshark.org/review/3455
Reviewed-by: Anders Broman <a.broman58@gmail.com>
2014-08-06 10:48:33 +00:00
Matthieu Texier 45f3deed0b Fixing indentation with tabs in isis dissector
Change-Id: I4f6296f1cb988dca8c94ca5089ff6aa03439da32
Reviewed-on: https://code.wireshark.org/review/3333
Reviewed-by: Evan Huus <eapache@gmail.com>
2014-08-01 22:55:59 +00:00
Michael Mann e8a8d62dc3 proto_tree_add_subtree[_format]
Change-Id: I7e016f10fcfdc0523bf2fe8c11295c0334f7c332
Reviewed-on: https://code.wireshark.org/review/2694
Reviewed-by: Michael Mann <mmann78@netscape.net>
2014-06-29 14:52:33 +00:00
Michael Mann 14824e6adf Revert "Fixup: tvb_* -> tvb_captured"
https://www.wireshark.org/lists/wireshark-dev/201406/msg00131.html

This reverts commit 246fe2ca4c.

Change-Id: Ib24bae0198c13a84bd7f731bf4af921212109a8f
Reviewed-on: https://code.wireshark.org/review/2430
Reviewed-by: Michael Mann <mmann78@netscape.net>
2014-06-19 18:25:59 +00:00
Dario Lombardo 246fe2ca4c Fixup: tvb_* -> tvb_captured
Change-Id: I9209c1271967405c34c1b6fa43e1726a4d3a5a3f
Reviewed-on: https://code.wireshark.org/review/2377
Reviewed-by: Anders Broman <a.broman58@gmail.com>
2014-06-18 14:14:58 +00:00
Guy Harris 16b26b8e5f Put the system ID in the top-level items for neighbors.
Add a tvb_print_system_id() routine, and use that in various ISIS
dissectors, while we're at it.

Change-Id: I31b6b9ea8faf2b4849f974ec7ed27fbdd14b91ef
Reviewed-on: https://code.wireshark.org/review/1145
Reviewed-by: Guy Harris <guy@alum.mit.edu>
2014-04-14 22:43:25 +00:00
Alexis La Goutte abc6fb24fa Fix some code remove by 296591399f
(Copyright or info about file...)

Change-Id: I90ba8b1c3ec8406b0c3365a69a8555837fc4bbb1
Reviewed-on: https://code.wireshark.org/review/515
Reviewed-by: Alexis La Goutte <alexis.lagoutte@gmail.com>
Tested-by: Alexis La Goutte <alexis.lagoutte@gmail.com>
2014-03-05 09:25:47 +00:00
Alexis La Goutte 296591399f Remove all $Id$ from top of file
(Using sed : sed -i '/^ \* \$Id\$/,+1 d')

Fix manually some typo (in export_object_dicom.c and crc16-plain.c)

Change-Id: I4c1ae68d1c4afeace8cb195b53c715cf9e1227a8
Reviewed-on: https://code.wireshark.org/review/497
Reviewed-by: Anders Broman <a.broman58@gmail.com>
2014-03-04 14:27:33 +00:00
Bill Meier 93fe4d53e2 Remove trailing whitespace.
Change-Id: Ia03a1cd4590aceda30ead4aa93ad413d90c6aea6
Reviewed-on: https://code.wireshark.org/review/372
Reviewed-by: Bill Meier <wmeier@newsguy.com>
Tested-by: Bill Meier <wmeier@newsguy.com>
2014-02-25 16:36:38 +00:00
Anders Broman 451c30ef81 Fix [-Wmissing-prototypes]
svn path=/trunk/; revision=54528
2014-01-01 12:17:57 +00:00
Michael Mann 7ec4582b4f Add FT_SYSTEM_ID type and convert the dissectors that use print_system_id with FT_BYTES to now use FT_SYSTEM_ID type.
svn path=/trunk/; revision=54383
2013-12-23 15:18:48 +00:00
Pascal Quantin 18f68cae7e Try to pacify buildbots
svn path=/trunk/; revision=54369
2013-12-22 20:12:31 +00:00
Michael Mann 89786cc8c7 Overhaul the ISIS dissectors
1. Make real dissectors and call dissector_try_uint_new for each "isis.type"
2. Use make_register script for dissector initialization
3. Replace isis_dissect_unknown() with real expert info
4. Use convert_proto_tree_add_text.pl to make many more filterable items and gets some files off of the checkAPIs.pl naughty list.
5. Remove (now unnecessary) dissector specific header files
6. Do some reordering of functions to eliminate the need for function declarations.

Additional whitespace formatting and modelines should probably be applied to all of these dissectors.

Used capture files from bug 5354 (https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=5354) and bug 1792 (https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=1792) for fuzztesting.

svn path=/trunk/; revision=54367
2013-12-22 18:18:12 +00:00
Michael Mann e6f1bd9056 Convert several proto_tree_add_bytes_format calls to proto_tree_add_bytes_format_value.
svn path=/trunk/; revision=52272
2013-09-29 18:19:29 +00:00
Alexis La Goutte e4e084c5a1 Fix some Dead Store (Dead assignement/Dead increment) Warning found by Clang
svn path=/trunk/; revision=51657
2013-09-02 23:11:20 +00:00
Michael Mann 0f0c111119 Remove check_col() and the occasional tree.
svn path=/trunk/; revision=49920
2013-06-14 01:02:11 +00:00
Bill Meier 1823aa007c it's ==> its & its ==> it's as needed.
svn path=/trunk/; revision=47891
2013-02-26 01:06:19 +00:00
Bill Meier c439b805e2 Comment out unused hf[] entries & etc.
(found by checkhf)

svn path=/trunk/; revision=47389
2013-01-31 17:55:31 +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 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
Chris Maynard cd7c8f671b Fix Coverity CID 700177 Unused pointer value.
svn path=/trunk/; revision=42849
2012-05-25 02:51:23 +00:00
pascal 20793cc947 From gyanesh via https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=7262 :
Digest details display issue in SPB Digest subtlv (ISIS hello pdu)

svn path=/trunk/; revision=42712
2012-05-19 10:35:43 +00:00
Anders Broman e01d3b549e From "oss.2nerds":
IEEE P802.1aq/D3.6 and the corresponding IETF draft
(http://tools.ietf.org/html/draft-ietf-isis-ieee-aq-05) defines a series of new
ISIS TLVs for the shortest-path-bridging protocol.

The attached patch file contains a simple dissector for one such TLV (the
MT-Port-Cap TLV) and several corresponding sub-TLVs (mcid, aux_mcid, digest,
and b-vid).  The digest sub-TLV dissector has not been exercised because no
suitable capture files are available (the digest sub-TLV seems not to be widely
implemented at this point in time).

Note that the codepoints mentioned in the IETF draft have changed.  The
IANA-assigned codepoints are further described in these pages:

http://www.ietf.org/mail-archive/web/spb-isis/current/msg00007.html
http://www.iana.org/assignments/isis-tlv-codepoints/isis-tlv-codepoints.xml#tlv-143

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

svn path=/trunk/; revision=42385
2012-05-02 14:23:35 +00:00