aboutsummaryrefslogtreecommitdiffstats
path: root/epan/dissectors/packet-btavctp.c
AgeCommit message (Collapse)AuthorFilesLines
2022-03-14Bluetooth: have BT specific global names contain bluetoothJaap Keuter1-3/+3
2021-07-21First pass pinfo->pool conversion, part 2Evan Huus1-1/+1
Automated find/replace of wmem_packet_scope() with pinfo->pool in all files where it didn't cause a build failure.
2019-07-26HTTPS (almost) everywhere.Guy Harris1-1/+1
Change all wireshark.org URLs to use https. Fix some broken links while we're at it. Change-Id: I161bf8eeca43b8027605acea666032da86f5ea1c Reviewed-on: https://code.wireshark.org/review/34089 Reviewed-by: Guy Harris <guy@alum.mit.edu>
2018-12-27Try to squeeze some bytes out of the frame_data structure.Guy Harris1-3/+3
Make the time stamp precision a 4-bit bitfield, so, when combined with the other bitfields, we have 32 bits. That means we put the flags at the same structure level as the time stamp precision, so they can be combined; that gets rid of an extra "flags." for references to the flags. Put the two pointers next to each other, and after a multiple of 8 bytes worth of other fields, so that there's no padding before or between them. It's still not down to 64 bytes, which is the next lower power of 2, so there's more work to do. Change-Id: I6f3e9d9f6f48137bbee8f100c152d2c42adb8fbe Reviewed-on: https://code.wireshark.org/review/31213 Petri-Dish: Guy Harris <guy@alum.mit.edu> Tested-by: Petri Dish Buildbot Reviewed-by: Guy Harris <guy@alum.mit.edu>
2018-02-12dissectors: use SPDX identifiers.Dario Lombardo1-13/+1
Change-Id: I92c94448e6641716d03158a5f332c8b53709423a Reviewed-on: https://code.wireshark.org/review/25756 Petri-Dish: Dario Lombardo <lomato@gmail.com> Reviewed-by: Anders Broman <a.broman58@gmail.com>
2018-01-06bluetooth: Group Bluetooth dissector preferencesStig Bjørlykke1-1/+1
Change-Id: Ib5360fcbfd8f6b2aee6b33ec7d9dc77362feb50e Reviewed-on: https://code.wireshark.org/review/25162 Petri-Dish: Stig Bjørlykke <stig@bjorlykke.org> Tested-by: Petri Dish Buildbot Reviewed-by: Anders Broman <a.broman58@gmail.com>
2016-09-02btavctp: rework the reassemble routine (CID 1355682).Dario Lombardo1-13/+6
The CID is about the lack of check of wmem_tree_lookup32_le() return value, but the old code worths a bit of rework. Change-Id: I3adb868d2baa1c8aea3f914f7fb9fdf75f222960 Reviewed-on: https://code.wireshark.org/review/17322 Petri-Dish: Dario Lombardo <lomato@gmail.com> Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org> Reviewed-by: Anders Broman <a.broman58@gmail.com>
2016-04-22Do not mix wmem and glib allocatorsPascal Quantin1-1/+1
Change-Id: I0e845668a1b9dbec93ea920a8585ecfe60f001d1 Reviewed-on: https://code.wireshark.org/review/15044 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>
2016-03-20Create call_data_dissector() to call data dissector.Michael Mann1-9/+6
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-3/+3
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>
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-10-17Bluetooth: Make dissectors independent of passed dataMichal Labedzki1-54/+45
If Bluetooth dissectors has additional data from previous layer - good. But if do not... try to decode as much as possible - probably using some "force" dissector preferences you can decode payload correctly. Change-Id: I6427afafb987ed3b9b751fd91616e670802b3542 Reviewed-on: https://code.wireshark.org/review/11021 Reviewed-by: Michal Labedzki <michal.labedzki@tieto.com>
2015-07-17Bluetooth: Add generic UUID table for DecodeByMichal Labedzki1-44/+27
Replace L2CAP Service, RFCOMM Service and AVCTP PID dissector table by shared Bluetooth Service UUID table. It also supports UUID16, UUID32 and UUID128 by hex-string, like for AVRCP: "110e". Change-Id: I473bc73d10939e8ed6dd55a6a92387c7a1ec125a Reviewed-on: https://code.wireshark.org/review/9678 Reviewed-by: Michal Labedzki <michal.labedzki@tieto.com>
2015-07-12Revert "[MSVC2015] TRy to fix Warnings turned errors."Anders Broman1-1/+6
This reverts commit 8d78077d0d931c6afee6d0e27b5df7c5477e21e5. Reverted as requested. Change-Id: I99461820d28215a52cc6bae6792f2892018d28b8 Reviewed-on: https://code.wireshark.org/review/9609 Reviewed-by: Anders Broman <a.broman58@gmail.com>
2015-06-04[MSVC2015] TRy to fix Warnings turned errors.Anders1-6/+1
Change-Id: I1156e66daad84004f4f7acae0175fcbb475db71a Reviewed-on: https://code.wireshark.org/review/8760 Reviewed-by: Anders Broman <a.broman58@gmail.com>
2015-03-02Bluetooth: Fix tools/checkAPI issuesMichal Labedzki1-2/+2
Change-Id: I8ffbd4a0da800594d9888f6a30612d4fc5273119 Reviewed-on: https://code.wireshark.org/review/7474 Petri-Dish: Michal Labedzki <michal.labedzki@tieto.com> Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org> Reviewed-by: Michal Labedzki <michal.labedzki@tieto.com>
2015-02-02Try to fix builbot OSX 10.5 buildbot false-positiveMichal Labedzki1-1/+1
Change-Id: If62eba937326ac5119bde97d9a827e165825b377 Reviewed-on: https://code.wireshark.org/review/6914 Reviewed-by: Michal Labedzki <michal.labedzki@tieto.com>
2015-02-02Bluetooth: Simplify to "UnknownDirection" in Info column when direction is ↵Michal Labedzki1-2/+1
unknown Change-Id: Ibad679c0b6c95d65389ce087f65b8f31cf3acd68 Reviewed-on: https://code.wireshark.org/review/6903 Petri-Dish: Michal Labedzki <michal.labedzki@tieto.com> Reviewed-by: Michal Labedzki <michal.labedzki@tieto.com>
2015-02-02Bluetooth: AVCTP: Improve IPID handlingMichal Labedzki1-7/+20
If profile is invalid (IPID=1) then add expert info. Change-Id: Id102e51eefe7e5e6314c3677468cb66573e5a893 Reviewed-on: https://code.wireshark.org/review/6900 Reviewed-by: Michal Labedzki <michal.labedzki@tieto.com>
2014-12-21Cleanup use of #includes in non-generated epan/dissector/*.cBill Meier1-1/+0
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-18Bluetooth: Add generic Bluetooth dissectorMichal Labedzki1-2/+2
Bluetooth dissector is used to add ability to filter all bluetooth payload from capture files (there are many transport like: hci_h4, hci_h1, hci_usb, hci_mon, btle). Also it is used to placeholder for all data tree used to store additional informations like bd_addrs, names, etc. Finally it is used to be one point for Bluetooth Endpoints/Conversation filtering what is enabled now. Also add Master/Slave Role and Connection Mode tracking. Change-Id: I67048080fb8ee16fa0f4ec429c1257de81ddd737 Reviewed-on: https://code.wireshark.org/review/5771 Petri-Dish: Michal Labedzki <michal.labedzki@tieto.com> Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org> Reviewed-by: Alexis La Goutte <alexis.lagoutte@gmail.com> Reviewed-by: Michal Labedzki <michal.labedzki@tieto.com>
2014-06-20Rename dissector_add_handle() to dissector_add_for_decode_as().Guy Harris1-1/+1
Hopefully that name makes it clear what the routiner's purpose is, and will encourage people to use it rather than using dissector_add_uint() with a bogus integer value. Change-Id: Ic5be456d0ad40b176aab01712ab7b13aed5de2a8 Reviewed-on: https://code.wireshark.org/review/2483 Reviewed-by: Guy Harris <guy@alum.mit.edu>
2014-06-19Revert "Fixup: tvb_ensure_length_remaining -> ↵Michael Mann1-1/+1
tvb_ensure_captured_length_remaining" See https://www.wireshark.org/lists/wireshark-dev/201406/msg00131.html This reverts commit 021e7afc9fcba09094d0e2143cc434a34e3b09dc. Change-Id: I0640eabce5ce8c4ff3a88ebf848b499f8bb8ed2f Reviewed-on: https://code.wireshark.org/review/2429 Reviewed-by: Michael Mann <mmann78@netscape.net>
2014-06-18Fixup: tvb_ensure_length_remaining -> tvb_ensure_captured_length_remainingDario Lombardo1-1/+1
Change-Id: I0228f3b6b7067bc0ce51f9d359f99fd18feb2b66 Reviewed-on: https://code.wireshark.org/review/2378 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-05-30Bluetooth: Avoid using macro GPOINTER_TO_UINT()Michal Labedzki1-4/+20
Fix warnings and try to inform user about unknown values in "Decode As". Also use define instead of magic number for Unknown L2CAP CIDs. Change-Id: Ie6f26a9e3330b84cef14bbf8861ffbdbdb789225 Reviewed-on: https://code.wireshark.org/review/1880 Reviewed-by: Michal Labedzki <michal.labedzki@tieto.com> Tested-by: Michal Labedzki <michal.labedzki@tieto.com>
2014-03-06Bluetooth: Avoid using find_dissector()Michal Labedzki1-4/+2
Also remove SVN $Id$ lines. Change-Id: I4f2925e6ad8dcfe4a62d879a2cef44447f8ae916 Reviewed-on: https://code.wireshark.org/review/476 Reviewed-by: Anders Broman <a.broman58@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-12Bluetooth/Ubertooth improvements. Bug 9606 ↵Michael Mann1-1/+2
(https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=9606) From Michal Labedzki 1. Bluetooth: Implement the rest of fields in Low Energy Link Layer dissector 2. Bluetooth: Merge all UUIDs together 3. Bluetooth: Extract LE Channel MAP to separate dissector 4. Ubertooth: Dissect CC2400 registers svn path=/trunk/; revision=54700
2013-12-02Reject the packet if data is NULL without doing anything else.Chris Maynard1-3/+5
svn path=/trunk/; revision=53732
2013-11-23Create the ability to have packet scoped "proto" data. Bug 9470 ↵Michael Mann1-4/+4
(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-20Provide "Decode As" functionality through dissectors themselves instead of ↵Michael Mann1-0/+26
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-02Bluetooth: Use dissector data instead of pinfo->private_data. Bug 7893 ↵Michael Mann1-15/+11
(https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=7893) From Michal Labedzki svn path=/trunk/; revision=53051
2013-10-29From didier gautheron: remove redundant or use faster col_xxx functionsBill Meier1-2/+2
- when the text parameter is constant col_add_str() and col_set_str() are equivalent but col_set_str() is faster. - same for replace col_append_fstr and col_append_str - remove col_clear() when it's redundant: + before a col_set/col_add if the dissector can't throw an exception. - replace col_append() after a col_clear() with faster col_add... or col_set https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=9344 svn path=/trunk/; revision=52948
2013-09-09More dissector table UI name changes (a continuation of r51904).Chris Maynard1-1/+1
svn path=/trunk/; revision=51907
2013-07-09Batch of filterable expert infos.Michael Mann1-2/+10
svn path=/trunk/; revision=50454
2013-06-20From Michal Labedzki viaEvan Huus1-16/+16
https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=8824 Convert bluetooth emem trees to wmem trees. Add modelines and fix indentation. Correct typo in wmem_tree.h that still referred to emem. svn path=/trunk/; revision=50076
2013-03-30From Michal Labedzki via ↵Evan Huus1-17/+10
https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=8509 Unify bluetooth direction handling (sent vs rcvd). svn path=/trunk/; revision=48661
2013-03-19From Michal Labedzki via ↵Pascal Quantin1-9/+12
https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=8416 : Remove C++ incompatibilities from Bluetooth dissectors and switch to wmem API svn path=/trunk/; revision=48414
2013-03-18From Michal Labedzki:Anders Broman1-1/+1
Be consistent in short name of protocols Use prefix "BT " in short name for all Bluetooth dissectors. A reason for that is protocol names start by "bt", Bluetooth dissectors can be easy identificated, also DecodeBy looks better (sorted). Please be note that "SDP" is reserved for different dissector, so using "BT SDP" is good choice. Also fix two naming mistakes. https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=8304 svn path=/trunk/; revision=48389
2013-03-18From Michal Labedzki:Anders Broman1-2/+3
Fix issues discovered by cppcheck Also use global OUI array in AVRCP. Thanks to Evan Huus for cppcheck. https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=8304 svn path=/trunk/; revision=48387
2013-03-17From beroset:Anders Broman1-14/+14
remove C++ incompatibilities https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=8416 svn path=/trunk/; revision=48356
2013-02-21Trivial cleanups:Evan Huus1-6/+6
- use a gboolean instead of an int where appropriate - comment out an unnecessary variable assignment - move some other assignments to before the address of the variable is taken; this makes the data flow more natural and cleans up some cppcheck warnings svn path=/trunk/; revision=47811
2013-02-21Minor Bluetooth fixesMichael Mann1-8/+8
1. Allow to DecodeBy payload over AVCTP 2. Fix L2CAP CID payload recognize after disc 3. Removed unneeded _U_ 4. Fall back to control channel in AVRCP 5. Fix time-tracking for passthrough and capability AVRCP commands From Michal Labedzki, bug 8367 (https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=8367) svn path=/trunk/; revision=47810
2013-02-21Fix AVCTP, AVRCP, HCI AVL and L2CP for multiple interfaces/adaptersMichael Mann1-29/+134
From Michal Labedzki, bug 8367 (https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=8367) svn path=/trunk/; revision=47809
2012-10-21From Michal Labedzki via ↵Pascal Quantin1-15/+17
https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=7675 : Fix improper use of negative value in AVCTP svn path=/trunk/; revision=45699
2012-10-09From Michal Labedzki:Anders Broman1-0/+13
[PATCH 15] Bluetooth: Add modelines https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=7639 svn path=/trunk/; revision=45422
2012-09-24packet-btavctp.c:107: warning: 'number_of_packets' may be used uninitialized ↵Anders Broman1-2/+2
in this function packet-btavctp.c:105: warning: 'pid' may be used uninitialized in this function svn path=/trunk/; revision=45100
2012-09-24From Michal Labedzki:Anders Broman1-0/+366
Add Bluetooth Protocol AVCTP. Supported version: 1.4. https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=7675 svn path=/trunk/; revision=45097