aboutsummaryrefslogtreecommitdiffstats
path: root/epan/dissectors/packet-p_mul.c
AgeCommit message (Collapse)AuthorFilesLines
2017-04-19P_Mul: Convert GHashtable -> wmem_map to fix memleaksMichael Mann1-51/+30
Change-Id: I7bdd0a483d9744780c18b45ab9fad3de3ed238de Ping-Bug: 13120 Reviewed-on: https://code.wireshark.org/review/21215 Petri-Dish: Peter Wu <peter@lekensteyn.nl> Reviewed-by: Michael Mann <mmann78@netscape.net> Reviewed-by: Peter Wu <peter@lekensteyn.nl>
2017-01-29Register reassembly tablesMichael Mann1-3/+2
Register all reassembly tables with a central unit, allowing the central unit to have the callback that initializes and destroys the reassembly tables, rather than have dissectors do it individually. Change-Id: Ic92619c06fb5ba6f1c3012f613cae14982e101d4 Reviewed-on: https://code.wireshark.org/review/19834 Petri-Dish: Michael Mann <mmann78@netscape.net> Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org> Reviewed-by: Michael Mann <mmann78@netscape.net>
2016-10-13Convert most UDP dissectors to use "auto" preferences.Michael Mann1-26/+3
Similar to the "tcp.port" changes in I99604f95d426ad345f4b494598d94178b886eb67, convert dissectors that use "udp.port". More cleanup done on dissectors that use both TCP and UDP dissector tables, so that less preference callbacks exist. Change-Id: If07be9b9e850c244336a7069599cd554ce312dd3 Reviewed-on: https://code.wireshark.org/review/18120 Petri-Dish: Michael Mann <mmann78@netscape.net> Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org> Reviewed-by: Michael Mann <mmann78@netscape.net>
2016-03-20Create call_data_dissector() to call data dissector.Michael Mann1-4/+1
This saves many dissectors the need to find the data dissector and store a handle to it. There were also some that were finding it, but not using it. For others this was the only reason for their handoff function, so it could be eliminated. Change-Id: I5d3f951ee1daa3d30c060d21bd12bbc881a8027b Reviewed-on: https://code.wireshark.org/review/14530 Petri-Dish: Michael Mann <mmann78@netscape.net> Reviewed-by: Michael Mann <mmann78@netscape.net>
2016-01-25Move the proto data stuff out of frame_data.[ch].Guy Harris1-0/+1
It's not tied to the frame_data structure any more, so it belongs by itself. Clean up some #includes while we're at it; in particular, frame_data.h doesn't use anything related to tvbuffs, so don't have it gratuitiously include tvbuff.h. Change-Id: Ic32922d4a3840bac47007c5d4c546b8842245e0c Reviewed-on: https://code.wireshark.org/review/13518 Reviewed-by: Guy Harris <guy@alum.mit.edu>
2016-01-24Add the packet number to the packet_info structure, and use it.Guy Harris1-6/+6
That removes most of the uses of the frame number field in the frame_data structure. Change-Id: Ie22e4533e87f8360d7c0a61ca6ffb796cc233f22 Reviewed-on: https://code.wireshark.org/review/13509 Reviewed-by: Guy Harris <guy@alum.mit.edu>
2016-01-23Add more fields to packet_info structure and use them.Guy Harris1-12/+12
Add fields for the absolute time stamp (and another field for a presence flag for the absolute time stamp) and the packet encapsulation for the packet. This lets us remove the field for the packet encapsulation in the frame_data structure; do so. Change-Id: Ifb910a9a192414e2a53086f3f7b97f39ed36aa39 Reviewed-on: https://code.wireshark.org/review/13499 Reviewed-by: Guy Harris <guy@alum.mit.edu>
2015-12-09new_register_dissector -> register_dissector for dissector directory.Michael Mann1-1/+1
Change-Id: Ie39ef054a4a942687bd079f3a4d8c2cc55d5f22c Reviewed-on: https://code.wireshark.org/review/12485 Petri-Dish: Michael Mann <mmann78@netscape.net> Reviewed-by: Michael Mann <mmann78@netscape.net>
2015-11-14p_mul: Fixed ack framenum links.Stig Bjørlykke1-3/+11
The ack symbol is for the Address PDU beeing acked. Also use the DUP_ACK symbol for P_Mul's Ack-Ack. Change-Id: I3da616e95e9c2cf889b1e4e4c0570ab0c276a2d2 Reviewed-on: https://code.wireshark.org/review/11819 Petri-Dish: Stig Bjørlykke <stig@bjorlykke.org> Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org> Reviewed-by: Alexis La Goutte <alexis.lagoutte@gmail.com>
2015-11-13p_mul: Enhance ack framenum links.Stig Bjørlykke1-1/+1
Change-Id: I084b43fcd8419741c2de007bd03fc04532346813 Reviewed-on: https://code.wireshark.org/review/11797 Reviewed-by: Stig Bjørlykke <stig@bjorlykke.org>
2015-11-04Don't include "file.h" if you don't need it.Guy Harris1-0/+2
It ends up dragging in libwireshark headers, which programs not linking with libwireshark shouldn't do. In particular, including <epan/address.h> causes some functions that refer to libwireshark functions to be defined if the compiler doesn't handle "static inline" the way GCC does, and you end up requiring libwireshark even though you shouldn't require it. Move plurality() to wsutil/str_util.h, so that non-libwireshark code can get it without include epan/packet.h. Fix includes as necessary. Change-Id: Ie4819719da4c2b349f61445112aa419e99b977d3 Reviewed-on: https://code.wireshark.org/review/11545 Reviewed-by: Guy Harris <guy@alum.mit.edu>
2015-11-03Remaining ADDRESS macro to address function conversionsJoão Valverde1-7/+7
Change-Id: I8bc9af431e70243b05f4f0ce8c2b8ee451383788 Reviewed-on: https://code.wireshark.org/review/11463 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-10-22Use address functions instead of ADDRESS macros in asn1 and epanGerald Combs1-1/+1
Replace CMP_ADDRESS, COPY_ADDRESS, et al with their lower-case equivalents in the asn1 and epan directories. Change-Id: I4043b0931d4353d60cffbd829e30269eb8d08cf4 Reviewed-on: https://code.wireshark.org/review/11200 Petri-Dish: Michal Labedzki <michal.labedzki@tieto.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-07-03Split four more init routines into init/cleanupPeter Wu1-10/+9
Three of them are trivial movements, the smb-sidsnooping is an odd one. Ronnie Sahlberg disabled the sid_name_snooping feature on 9 July 2007. There is a preference to override it though... For now add a TODO marker and ensure that the hash tables are always initialized. Change-Id: I61f5e215c9fa72a6785fb48eaa2d50c1975d7483 Reviewed-on: https://code.wireshark.org/review/9227 Reviewed-by: Michael Mann <mmann78@netscape.net>
2015-06-23Remove more deprecated tvb_length callsEvan Huus1-4/+4
Change-Id: Ie137e6f4e20fe26b1a4d9510e267896219c1c631 Reviewed-on: https://code.wireshark.org/review/9075 Reviewed-by: Evan Huus <eapache@gmail.com>
2015-01-16SE_COPY_ADDRESS -> WMEM_COPY_ADDRESSMichael Mann1-3/+3
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-07SET_ADDRESS -> TVB_SET_ADDRESS to "hide" some of the tvb_get_ptr use.Michael Mann1-9/+5
Not all changes were able to remove their corresponding tvb_get_ptr, because there are other API dependent on the (tvb_get)pointer, but future iterations optimizing those other APIs will then be able to remove it. Change-Id: Id7cefd440b81834de1d1aace7cd0789b1c871a22 Reviewed-on: https://code.wireshark.org/review/6358 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-06p_mul: Indicate if fletcher algorithm is used.Stig Bjørlykke1-2/+9
The first version of ACP 142 uses the fletcher algorithm for checksum. Indicate if this (now old variant) checksum is used. Change-Id: Id6f3e7ecfcde022b339bdb956cd6f642a917076a Reviewed-on: https://code.wireshark.org/review/6342 Reviewed-by: Stig Bjørlykke <stig@bjorlykke.org>
2015-01-06s5066sis: Consume transport layer data in S5066sisRicardo Cristian Ramirez1-0/+2
S5066 spec describes a transport layer for some clients like Acp 142 and DMP but not for all of them. Since RCOP/UDOP header definition are given in S'5066 specification, consuming these header bytes in S'5066 SIS dissector may be appropriate Bug: 10827 Change-Id: Iffdf5d567e1a417ccbafdac919f5a5200159d31b Reviewed-on: https://code.wireshark.org/review/6292 Reviewed-by: Stig Bjørlykke <stig@bjorlykke.org> Tested-by: Stig Bjørlykke <stig@bjorlykke.org>
2014-12-28p_mul: Added checksum from ACP 142(A)Stig Bjørlykke1-10/+17
Bug: 10807 Change-Id: Ifd1ea5d67b65a7e7997458785fff95cc471e0dbc Reviewed-on: https://code.wireshark.org/review/6076 Petri-Dish: Stig Bjørlykke <stig@bjorlykke.org> Reviewed-by: Stig Bjørlykke <stig@bjorlykke.org> Tested-by: Stig Bjørlykke <stig@bjorlykke.org>
2014-12-23Deleting unnecessary #includes from dissectors.Martin Mathieson1-2/+0
Fourth batch (packet-mac-lte.c -> packet-rtp.c). Will look at cleaning up and committing script afterwards. Change-Id: Id921f07f4b274f0cfb77ce81abe4a285fdb8b644 Reviewed-on: https://code.wireshark.org/review/6023 Petri-Dish: Martin Mathieson <martin.r.mathieson@googlemail.com> Reviewed-by: Martin Mathieson <martin.r.mathieson@googlemail.com>
2014-12-21Cleanup use of #includes in non-generated epan/dissector/*.cBill Meier1-2/+2
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-07-05convert to proto_tree_add_subtree[_format]Michael Mann1-6/+3
Change-Id: I8df48b25de784a48a25f0e48aac1e1545ed92c35 Reviewed-on: https://code.wireshark.org/review/2865 Reviewed-by: Michael Mann <mmann78@netscape.net>
2014-06-20Revert part of svn revision 52045 (git b38ee917)Stig Bjørlykke1-2/+2
This fix does change the format printed for values using bitmasks (because the bit values are printed first) and is not always wanted in this dissectors (because of readability). We should have a better way of doing what I want in this dissectors, so I'll have a look at this later. Change-Id: I2477aa6b1d0c42a7ad5848bba3cb74dce3bba1f0 Reviewed-on: https://code.wireshark.org/review/2485 Reviewed-by: Stig Bjørlykke <stig@bjorlykke.org>
2014-06-19Revert "Fixup: tvb_* -> tvb_captured"Michael Mann1-4/+4
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-4/+4
Change-Id: I9209c1271967405c34c1b6fa43e1726a4d3a5a3f Reviewed-on: https://code.wireshark.org/review/2377 Reviewed-by: Anders Broman <a.broman58@gmail.com>
2014-06-16Add a cast to satisfy the buildbots.Jeff Morriss1-1/+1
Change-Id: I1c128db8a8b0cbbef01a26f7b3a50ed2b59af229 Reviewed-on: https://code.wireshark.org/review/2279 Reviewed-by: Jeff Morriss <jeff.morriss.ws@gmail.com> Tested-by: Jeff Morriss <jeff.morriss.ws@gmail.com>
2014-06-16Register P_Mul as new-style dissectorStig Bjørlykke1-2/+4
Change-Id: Ic1f85475223d5ba36d9aa4ae617d6db450940fae Reviewed-on: https://code.wireshark.org/review/2268 Reviewed-by: Stig Bjørlykke <stig@bjorlykke.org>
2014-06-16Do not handle P_Mul packet as ASCII string when calculating checksum.Stig Bjørlykke1-1/+1
This bug was introduced when rewriting tvb_get_string() to handle encoding (and thus handling ASCII string different). Change-Id: Ic107d7b9e2f63aea33fdf55b9c20c22202f7b458 Reviewed-on: https://code.wireshark.org/review/2270 Reviewed-by: Stig Bjørlykke <stig@bjorlykke.org> (cherry picked from commit fb0266fb244bf444a2801ee7ffc983f5a58621de) Reviewed-on: https://code.wireshark.org/review/2267
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-27(Trivial) Fix spellling in a comment.Bill Meier1-1/+1
svn path=/trunk/; revision=54982
2013-12-14Fix [-Wmissing-prototypes]Jakub Zawadzki1-2/+3
svn path=/trunk/; revision=54095
2013-12-12(Trivial)Bill Meier1-6/+6
- Fix indentation to match editor modelines (tabs-->spaces); - Rework/add some whitespace; svn path=/trunk/; revision=53978
2013-11-23Create the ability to have packet scoped "proto" data. Bug 9470 ↵Michael Mann1-2/+2
(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-09-30Convert proto_tree_add_uint64_format calls to ↵Michael Mann1-3/+3
proto_tree_add_uint64_format_value where appropriate. svn path=/trunk/; revision=52299
2013-09-29Convert several proto_tree_add_bytes_format calls to ↵Michael Mann1-2/+2
proto_tree_add_bytes_format_value. svn path=/trunk/; revision=52272
2013-09-22emem -> wmem conversion:Pascal Quantin1-1/+1
- 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
2013-09-16Convert each of the address.h macros to inline functions. Gerald Combs1-3/+3
Document each function. Note that we now call tvb_get_ptr() before modifying the address in tvb_set_address() and tvb_set_address_hf(). The caller doesn't have to worry about doing that any more. Add add_address_to_hash64(). svn path=/trunk/; revision=52106
2013-09-15A few more dissectors converted to wmemPascal Quantin1-17/+18
svn path=/trunk/; revision=52071
2013-09-15Convert proto_tree_add_uint_format to proto_tree_add_uint_format_value if ↵Michael Mann1-10/+8
hf_ field name is the first part of the formatted string. This was done with a perl script on the dissectors directory (packet-*.c), followed by manual inspection of the output. The manual inspection yielded a few cases that really should have been proto_tree_add_uint or proto_tree_add_item, so I updated them accordingly. The script didn't catch as many as I would have liked, but it's a start. The most common (ab)use of proto_tree_add_uint_format was for appending strings to CRC/checksum values to note good or bad CRC/checksum. svn path=/trunk/; revision=52045
2013-09-09expert_add_info_format_text -> expert_add_info_formatMichael Mann1-3/+3
svn path=/trunk/; revision=51852
2013-09-07Batch of filterable expert infoMichael Mann1-54/+47
svn path=/trunk/; revision=51823
2013-08-27Use dissector_delete_uint_range/dissector_add_uint_rangeAnders Broman1-12/+2
svn path=/trunk/; revision=51540
2013-08-05Keep result of [new_]register_dissector in some dissectors.Jakub Zawadzki1-2/+3
svn path=/trunk/; revision=51156
2013-07-17Remove fragment_data, add fragment_head, fragment_item - for now alias it to ↵Jakub Zawadzki1-1/+1
the same structure. This is begin of work to split fragment head and fragments items. svn path=/trunk/; revision=50708
2013-06-14Remove check_col() and the occasional tree.Michael Mann1-38/+33
svn path=/trunk/; revision=49921
2013-05-12Add the posibillity to use a key for per-packet-data.Anders Broman1-2/+2
svn path=/trunk/; revision=49259
2013-03-24Don't cast away constness.Guy Harris1-3/+3
svn path=/trunk/; revision=48536
2013-03-22Don't wire into the reassembly code the notion that reassemblies shouldGuy Harris1-10/+8
be done on flows from one address to another; reassembly for protocols running atop TCP should be done on flows from one TCP endpoint to another. We do this by: adding "reassembly table" as a data structure; associating hash tables for both in-progress reassemblies and completed reassemblies with that data structure (currently, not all reassemblies use the latter; they might keep completed reassemblies in the first table); having functions to create and destroy keys in that table; offering standard routines for doing address-based and address-and-port-based flow processing, so that dissectors not needing their own specialized flow processing can just use them. This fixes some mis-reassemblies of NIS YPSERV YPALL responses (where the second YPALL response is processed as if it were a continuation of a previous response between different endpoints, even though said response is already reassembled), and also allows the DCE RPC-specific stuff to be moved out of epan/reassembly.c into the DCE RPC dissector. svn path=/trunk/; revision=48491
2013-03-18From beroset:Anders Broman1-13/+13
remove C++ incompatibilities https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=8416 svn path=/trunk/; revision=48384