aboutsummaryrefslogtreecommitdiffstats
path: root/epan/dissectors/packet-rsvp.c
AgeCommit message (Collapse)AuthorFilesLines
2015-04-30Fix some cases where we're shifting a signed 1 left.Guy Harris1-15/+15
Shift 1U instead, to make sure it's unsigned; the result of, for example, the result of shifting a signed value left is undefined if the value times 2^{shift count} doesn't fit in the *signed* type of the shifted value. That means, in particular, that the result of shifting 1 left by {number of bits in an int - 1} is undefined. (In *practice*, it'll probably be -2^32, with the bit you want set, but that's not guaranteed, and GCC 5.1 seems not to like it.) Change-Id: I0d27565c382a04ceda9eec65f45a430ceb74cf53 Reviewed-on: https://code.wireshark.org/review/8255 Reviewed-by: Guy Harris <guy@alum.mit.edu>
2015-02-27Pass tvb and offset into print_nsap_net() and print_area() to "hide" the ↵Michael Mann1-4/+4
tvb_get_ptr call that dissectors are using. Change-Id: Ibc5a51be462d431b85b34cac7a358d736ec7b9db Reviewed-on: https://code.wireshark.org/review/7422 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>
2015-01-16SE_COPY_ADDRESS -> WMEM_COPY_ADDRESSMichael Mann1-1/+1
Copy addresses with wmem-scope instead of (forced) seasonal scope. All existing instances were converted to wmem_file_scope, but the flexibility is there for other scopes. Change-Id: I8e58837b9ef574ec7dd87e278470d7063ae8c1c2 Reviewed-on: https://code.wireshark.org/review/6564 Reviewed-by: Michael Mann <mmann78@netscape.net>
2015-01-15rsvp: fix typoEvan Huus1-1/+1
caught by test suite as: Duplicate field detected in call to proto_register_field_array: rsvp.call_attributes is already registered Change-Id: Ibf4ead3026b9930fb8f6ab07f0a5a4c299cedc35 Reviewed-on: https://code.wireshark.org/review/6544 Reviewed-by: Evan Huus <eapache@gmail.com>
2015-01-15RSVP: Add support of GMPLS Support for Metro Ethernet Forum and G.8011 (RFC ↵Miltos Patsiouras1-4/+348
6004) This document describes a method for controlling two specific types of Ethernet switching via Generalized Multi-Protocol Label Switching (GMPLS). This document supports the types of switching corresponding to the Ethernet services that have been defined in the context of the Metro Ethernet Forum (MEF) and International Telecommunication Union (ITU) G.8011. Specifically, switching in support of Ethernet private line and Ethernet virtual private line services are covered. Support for MEF- and ITU-defined parameters is also cover Bug: 7841 Change-Id: I12e12d01d497bd0e9703efcf6bd8ad100805bccc Change-Id: I180c095652604bc025ab81171dd8a042e0930f08 Reviewed-on: https://code.wireshark.org/review/5323 Reviewed-by: Alexis La Goutte <alexis.lagoutte@gmail.com>
2015-01-07tvb_bytes_to_ep_str -> tvb_bytes_to_strMichael Mann1-2/+2
Change-Id: I79c613cbdd8dc939dd4c29ebc477fb6eefd5bfc4 Reviewed-on: https://code.wireshark.org/review/6371 Petri-Dish: Michael Mann <mmann78@netscape.net> Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org> Reviewed-by: Michael Mann <mmann78@netscape.net>
2015-01-02tshark: Add endpoints statisticsMichael Mann1-1/+1
"stat name" has been official changed to "endpoints" for all dissectors, rather than a mixture of "host"/"endpoints" based on dissector. Change-Id: If34bcb5165b493948e784ba038ab202803a59843 Reviewed-on: https://code.wireshark.org/review/6154 Reviewed-by: Pascal Quantin <pascal.quantin@gmail.com> 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-24RSVP: fix display of unknown Juniper AttributAlexis La Goutte1-2/+2
Get "Trying to fetch an unsigned integer with length" when length > 4 Change-Id: If5e53b826d98f2c30253ea852754f856e1d29088 Reviewed-on: https://code.wireshark.org/review/6038 Reviewed-by: Anders Broman <a.broman58@gmail.com>
2014-12-24RSVP: Conversations / Endpoint: wrong filter when select a RSVP ↵Alexis La Goutte1-3/+14
conversations / endpoint (INVALID == a.x.y.z ...) Change-Id: I70f6afd41eefddb42829c3d5f890ea67dcd65537 Reviewed-on: https://code.wireshark.org/review/6037 Reviewed-by: Anders Broman <a.broman58@gmail.com>
2014-12-23RSVP: RECORD_ROUTE IPv4 Subobject Flags field incorrect decodingAlexis La Goutte1-3/+3
The Flags field within RSVP RECORD_ROUTE IPv4_Subobject is decoded incorrectly. Wireshark thinks that 0x10 bit represents Node-ID, but actually the Node-ID is encoded by bit 0x20 (per RFC 4561) Issue reported by Alexander Okonnikov Bug:10799 Change-Id: I48f6aa35c08945aacf8f2bb871a72b5927511948 Reviewed-on: https://code.wireshark.org/review/5944 Reviewed-by: Anders Broman <a.broman58@gmail.com>
2014-12-21Cleanup use of #includes in non-generated epan/dissector/*.cBill Meier1-5/+1
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-12rsvp: Convert encoding-arg ENC_NA to ENC_BIG_ENDIAN for all integer fieldsBill Meier1-93/+93
Change-Id: Ib0f863f08a3ef420832cc05e988b5bc64ff0b121 Reviewed-on: https://code.wireshark.org/review/5731 Reviewed-by: Bill Meier <wmeier@newsguy.com>
2014-12-11rsvp: Fix dup display-filter name possibly leading to crash if used.Bill Meier1-3/+3
Change-Id: I8b903fb1137800a84473a82cff9c45f965cb869f Reviewed-on: https://code.wireshark.org/review/5723 Reviewed-by: Bill Meier <wmeier@newsguy.com>
2014-12-01Use proto_tree_add_bitmask for groups of proto_tree_add_boolean.Michael Mann1-29/+14
Part 3 of many, but this concludes the strict conversion to proto_tree_add_bitmask. Patches to follow with use proto_tree_add_bitmask_xxx (some functions still need to be written) Change-Id: Ic2435667c6a7f1d40602124e5044954d2a296180 Reviewed-on: https://code.wireshark.org/review/5553 Reviewed-by: Michael Mann <mmann78@netscape.net> Petri-Dish: Michael Mann <mmann78@netscape.net> Reviewed-by: Anders Broman <a.broman58@gmail.com>
2014-12-01Update display filter names per checkfiltername.plMichael Mann1-3/+3
Change-Id: I7694a6f8d8ccec3109fb86ccefee5798de57757d Reviewed-on: https://code.wireshark.org/review/5548 Petri-Dish: Michael Mann <mmann78@netscape.net> Reviewed-by: Evan Huus <eapache@gmail.com> Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org> Reviewed-by: Michael Mann <mmann78@netscape.net>
2014-11-26Fix a number of dup hf[] filter-names probably resulting from cut/paste errs.Bill Meier1-1/+1
Change-Id: I9242300b2ace3155c1506b584a90f073100a305e Reviewed-on: https://code.wireshark.org/review/5512 Reviewed-by: Bill Meier <wmeier@newsguy.com>
2014-10-04RSVP: Fix Dead Store (Dead assignement/Dead increment) warning found by ClangAlexis La Goutte1-2/+0
Change-Id: Iccfeaa514cd60f02bb37e210c5f714bcb616521b Reviewed-on: https://code.wireshark.org/review/4461 Reviewed-by: Anders Broman <a.broman58@gmail.com>
2014-09-29Improve filterability of RSVP dissector.Michael Mann1-409/+453
Eliminated many, but not all proto_tree_add_text calls. Change-Id: Ic904a0019a9d5d64d47b562bd282f1e6fad617cb Reviewed-on: https://code.wireshark.org/review/4366 Petri-Dish: Michael Mann <mmann78@netscape.net> Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org> Reviewed-by: Michael Mann <mmann78@netscape.net>
2014-08-18Refactor "common" hostlist/endpoint table functionality.Michael Mann1-1/+24
This is very similar in architecture to the changes made to the Conversation table functionality. Since all conversations have endpoints/hostlists, the "registered" list is shared for both. Change-Id: Ie8c6910a68a1b3f27c5b18c4494f49b9404a7b31 Reviewed-on: https://code.wireshark.org/review/3214 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-08-09Clean up Internet checksum handling.Guy Harris1-2/+1
Add macros to set entries of a vec_t, one for use when you have a pointer to private data, and one for use when you have data in a tvbuff. The latter wraps the use of tvb_get_ptr(), so that you're not directly calling it in a dissector. Move ip_checksum() to epan/in_cksum.c, and add an ip_checksum_tvb() that wraps the use of tvb_get_ptr(). In the CARP dissector, give the length variable an unsigned type - there's no benefit to it being signed, and that requires some casts to be thrown around. In the DCCP dissector, check only against the coverage length to see if we have enough data, combine the "should we check the checksum?" check with the "*can* we check the checksum?" check in a single if, and throw a dissector assertion if the source network address type isn't IPv4 or IPv6. Get rid of inclues of <epan/in_cksum.h> in dissectors that don't use any of the Internet checksum routines. In the HIP dissector, make sure we have the data to calculate the checksum before doing so. Change-Id: I2f9674775dbb54c533d33082632809f7d32ec8ae Reviewed-on: https://code.wireshark.org/review/3517 Reviewed-by: Guy Harris <guy@alum.mit.edu>
2014-07-30Apply refactored "conversation" (tap) data to TShark.Michael Mann1-1/+1
I intentionally left the fields displayed alone (so they don't exactly match Wireshark GUI), because as Guy points out in bug 6310, not sure its A Bug or A Feature. But at least all types of conversations allowed are in sync with Wireshark GUI. Bug:6310 Change-Id: I722837df510a39dadc1f9a07a99275509516698c Reviewed-on: https://code.wireshark.org/review/3212 Petri-Dish: Michael Mann <mmann78@netscape.net> Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org> Reviewed-by: Michael Mann <mmann78@netscape.net>
2014-07-26Refactor "common" Conversation table functionality.Michael Mann1-0/+23
Refactor (non-GUI) conversation table functionality from gtk/Qt to epan. Also refactor "common GUI" conversation table functionality. The idea is to not have to modify the GUI when a dissector adds a new "conversation type" Change-Id: I11f08d0d7edd631218663ba4b902c4a4c849acda Reviewed-on: https://code.wireshark.org/review/3113 Reviewed-by: Gerald Combs <gerald@wireshark.org>
2014-07-11Restore some assignments of ti2 that were removed in the ↵Michael Mann1-15/+15
proto_tree_add_subtree[_format] conversion bug:10270 Change-Id: I40062065add1c6a08bdabc9dcbbe53afaafca035 Reviewed-on: https://code.wireshark.org/review/2997 Reviewed-by: Anders Broman <a.broman58@gmail.com>
2014-07-10Fix Uninitialized argument value found by Clang AnalyzerAlexis La Goutte1-5/+5
Change-Id: I3cdb7734302b3e879def71dfa48c4654999ae9d2 Reviewed-on: https://code.wireshark.org/review/2983 Reviewed-by: Anders Broman <a.broman58@gmail.com>
2014-07-08Fix Uninitialized argument value found by Clang AnalyzerAlexis La Goutte1-1/+1
Change-Id: Ia39d7b258a888c188ae7d87c3c907e2a0ad1d3f0 Reviewed-on: https://code.wireshark.org/review/2936 Reviewed-by: Anders Broman <a.broman58@gmail.com>
2014-07-07Squelch some compiler warnings.Guy Harris1-3/+3
Change-Id: I768bf577b3871171ab33f080c5a0099ac06718ce Reviewed-on: https://code.wireshark.org/review/2906 Reviewed-by: Guy Harris <guy@alum.mit.edu>
2014-07-06convert to proto_tree_add_subtree[_format]Michael Mann1-213/+133
Change-Id: Ia2567695ffed30c990eda3740b08bfab101cea96 Reviewed-on: https://code.wireshark.org/review/2883 Reviewed-by: Michael Mann <mmann78@netscape.net>
2014-07-02RSVP checksum is not required if integrity object is presentEvan Huus1-22/+24
Bug: 10219 Change-Id: I2da62ee184327b2bc42a264e1782db927460f5cf Reviewed-on: https://code.wireshark.org/review/2773 Reviewed-by: Alexis La Goutte <alexis.lagoutte@gmail.com> Reviewed-by: Anders Broman <a.broman58@gmail.com>
2014-06-19Revert "Fixup: tvb_* -> tvb_captured"Michael Mann1-3/+3
https://www.wireshark.org/lists/wireshark-dev/201406/msg00131.html This reverts commit 246fe2ca4c67d8c98caa84e2f57694f6322e2f96. Change-Id: Ib24bae0198c13a84bd7f731bf4af921212109a8f Reviewed-on: https://code.wireshark.org/review/2430 Reviewed-by: Michael Mann <mmann78@netscape.net>
2014-06-18Fixup: tvb_* -> tvb_capturedDario Lombardo1-3/+3
Change-Id: I9209c1271967405c34c1b6fa43e1726a4d3a5a3f Reviewed-on: https://code.wireshark.org/review/2377 Reviewed-by: Anders Broman <a.broman58@gmail.com>
2014-06-18Fixup: tvb_get_string(z) -> tvb_get_string(z)_encDario Lombardo1-2/+2
Change-Id: I63a3704effe3fcab01a193dc39b6a22e9f1cf3fe Reviewed-on: https://code.wireshark.org/review/2376 Reviewed-by: Anders Broman <a.broman58@gmail.com>
2014-06-07tvb_new_subset -> tvb_new_subset_length when length parameters are equal.Michael Mann1-1/+1
tvb_new_subset -> tvb_new_subset_remaining it appears that's what the intention is. Change-Id: I2334bbf3f10475b3c22391392fc8b6864454de2d Reviewed-on: https://code.wireshark.org/review/1999 Reviewed-by: Pascal Quantin <pascal.quantin@gmail.com>
2014-03-04Remove all $Id$ from top of fileAlexis La Goutte1-2/+0
(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-01-27Fix hf[] entries with refs to range_string arraysBill Meier1-7/+7
to add missing BASE_RANGE_STRING and to use RVALS instead of VALS. Fixes crashes in 'tshark -G values' and presumably also fixes crashes when used in a dissection. Introduced in SVN #54449. (I suspect that ' convert_proto_tree_add_text.pl' may need some work to handle range_strings). svn path=/trunk/; revision=54984
2014-01-26Fix encoding arg for RSVP dissector (with fix-encodings-args toolsAlexis La Goutte1-7/+7
svn path=/trunk/; revision=54963
2014-01-23From me for https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=9519 RSVP ↵Alexis La Goutte1-1/+48
dissector does not decode Session Object (1) C-type (13) message svn path=/trunk/; revision=54932
2013-12-26Fix Dead Store (Dead assignement/Dead increment) warning found by ClangAlexis La Goutte1-7/+0
svn path=/trunk/; revision=54458
2013-12-24Make many fields filterable. Used convert_proto_tree_add_text.pl to do a ↵Michael Mann1-722/+701
"first pass" at converting proto_tree_add_text calls since this dissector is the worse (ab)user (by volume) of proto_tree_add_text and the "coding style" is very conducive to having convert_proto_tree_add_text.pl correctly guessing the field info. Another pass or two of convert_proto_tree_add_text.pl (with more manual intervention) is needed to be a "proper" dissector, but it gets it off of the checkAPIs.pl "naughty list" in time for Christmas. svn path=/trunk/; revision=54449
2013-12-23Make C-type filterable.Michael Mann1-232/+191
If someone wanted to make more hf_ variables accompanied by a variety of value_strings for each category, they are certainly more than welcome. For now it just cuts down on the proto_tree_add_text (ab)use. "Comment out" unused hf_ variable found. svn path=/trunk/; revision=54425
2013-12-21Add missing includesJakub Zawadzki1-0/+1
svn path=/trunk/; revision=54332
2013-12-19Rename a couple of to_str functions to have ep_ in the name. This makes itEvan Huus1-9/+9
obvious that the returned string is ephemeral, and opens up the original names in the API for versions that take a wmem pool (and thus can work in any scope). svn path=/trunk/; revision=54249
2013-12-14Remove not needed ';'Jakub Zawadzki1-1/+1
svn path=/trunk/; revision=54088
2013-12-12The dissector table has never been used, and the name of the dissectorGuy Harris1-5/+0
table doesn't correspond to any obvious field, so I'm not sure why it needs to exist. Remove it. svn path=/trunk/; revision=53996
2013-11-22Create multiple dissection functions if packet_info->ipproto is used to ↵Michael Mann1-11/+28
distinguish behavior. svn path=/trunk/; revision=53504
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-23#if 0 numerous "unused const variables" (mostly value-string-arrays);Bill Meier1-0/+2
Also; fix a few "set but not used" warnings. svn path=/trunk/; revision=52780
2013-09-29As pointed out in bug 9127, tcpdump dissects Juniper AttributesJörg Mayer1-16/+166
quite well - reimplement that in Wireshark. There is room for improvement in this patch, e.g. use subtrees for the subattributes. svn path=/trunk/; revision=52278
2013-09-27Hack forJörg Mayer1-5/+74
https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=9127 With 6 unknown bytes leading to the two known values for the last two bytes this cannot yet be properly dissected. Dissect the one known case. More traces with additional properties required to get more sense into the first 6 bytes. svn path=/trunk/; revision=52233
2013-09-25Beginning to work on bug 9127 (Juniper proprietary TLV in RSVP):Jörg Mayer1-12/+50
- Print hexdump of unknown or vendor specific toplevel TLVs - Try to print the name of type 204 (something still missing) svn path=/trunk/; revision=52212
2013-09-22emem -> wmem conversion:Pascal Quantin1-2/+2
- ep_tvb_get_bits() -> wmem_packet_tvb_get_bits() - tvb_g_memdup()/ep_tvb_memdup() -> tvb_memdup() - tvb_fake_unicode()/tvb_get_ephemeral_faked_unicode() -> tvb_get_faked_unicode() - tvb_get_g_string()/tvb_get_ephemeral_string()/tvb_get_seasonal_string() -> tvb_get_string() - tvb_get_g_unicode_string()/tvb_get_ephemeral_unicode_string() -> tvb_get_unicode_string() - tvb_get_ephemeral_string_enc() -> tvb_get_string_enc() - update docs accordingly svn path=/trunk/; revision=52172