aboutsummaryrefslogtreecommitdiffstats
path: root/epan/dissectors/packet-umts_fp.c
AgeCommit message (Collapse)AuthorFilesLines
2024-08-23Dissectors: Include what you use.Anders Broman1-0/+2
2024-07-27Use col_append_str for literal strings with no specifiersMartin Mathieson1-1/+1
2024-07-18epan: convert dissectors U to C99 typesAnders Broman1-654/+654
2024-06-17Fix some spelling errorsMartin Mathieson1-4/+4
2024-06-16epan: heuristic to pass void *data to dissectorJoakim Karlsson1-10/+10
Also updated some wrongly marked unused *data
2024-06-15epan: changed heur_dissector_t to boolJoakim Karlsson1-11/+11
used by heur_dissector_add(const char *name, heur_dissector_t dissector, ..
2024-04-05Remove init to zero for static variablesStig Bjørlykke1-1/+1
The C standard requires that objects with static storage duration is initialized to zero.
2024-03-31Switch our boolean preferences to boolGerald Combs1-5/+5
With the aid of a script, convert our boolean preferences from gboolean to bool. Ping #19116
2024-03-16epan: Remove subnum from frame_dataJohn Thacker1-9/+2
The RRC dissector is the only one which uses subnum, and fd->subnum always contains exactly the same information as the cur_tb member of the FP proto data (which is what the UMTS MAC and RLC dissectors use instead.) Switch the RRC dissector to use it as well, and remove subnum from frame data. Move the new TCP analysis override member (which probably can be a bitfield as well) near the bitfields in the frame_data struct to replace it, to save space when allocating the struct.
2024-02-25Fix lots of spellingsMartin Mathieson1-1/+1
2024-02-13check_spelling.py: add globsMartin Mathieson1-3/+3
2024-01-31Fix more spellings - mostly commentsMartin Mathieson1-1/+1
2024-01-31Fix some spelling errorsMartin Mathieson1-15/+15
2024-01-25Fix more FT_BOOLEAN items with no mask - set len to BASE_NONEMartin Mathieson1-1/+1
2023-11-20Remove init of proto variablesStig Bjørlykke1-172/+172
Remove init of proto, header field, expert info and subtree variables. This will reduces the binary size by approximate 1266320 bytes due to using .bss to zero-initialize the fields. The conversion is done using the tools/convert-proto-init.py script.
2023-11-17dissectors: Remove init of hf and ett variable arraysStig Bjørlykke1-4/+4
Manually remove init of hf and ett variable arrays because this cannot be easily done using the convert script.
2023-09-19Use `register_dissector()` for more protocolsDavid Perry1-3/+3
Changes several calls of `create_dissector_handle()` to instead call `register_dissector()` with a name for the dissector. This should handle all dissectors in `epan/` from `packet-p*` to `packet-v*`. This change allows affected dissectors to be findable by calls to `find_dissector()`. In turn, this opens up more command-line use for these protocols, including fuzzshark and rawshark, as well as lua use via `Dissector.get()`. Where needed, move the call from the protocol handoff function to the protocol register function, save the result in a static variable, and use that variable in the handoff function. There were some calls to `create_dissector_handle()` or `register_dissector()` which passed `-1` as the protocol argument. When I saw those I corrected them to pass the actual `proto_foo` identifier instead. Partially addresses #5612
2023-07-19Fix more item/call issuesMartin Mathieson1-2/+2
2023-05-28Label vs filter checkingMartin Mathieson1-2/+2
2022-12-30check_tfs: find entries that define value_string identical to common tfsMartin Mathieson1-8/+2
2022-12-12umts_fp: Handle absent checksums when there is no payloadJohn Thacker1-14/+24
3GPP TS 25.427 and TS 25.435 both say that the Payload CRC IE may only be present if the frame contains payload for E-DCH frames, even where the setup of the transport bearer indicated that the CRC would be present otherwise. So if there's no payload and the CRC is missing, treat that as missing-but-expected rather than marking the packet as malformed. Take the opportunity to switch to proto_tree_add_checksum, which handles all the various cases. Ping #8859
2022-11-22Fix some issues seen with cppcheckMartin Mathieson1-8/+8
2022-08-25Rename a bunch of things with "conversation".Guy Harris1-16/+16
A conversation in Wireshark might have two endpoints or might have no endpoints; few if any have one endpoint. Distinguish between conversations and endpoints.
2022-08-07UMTS FP: Fix flag in conversation_new callsDarienSpencer651-2/+2
2022-06-07umts_fp: Use correct find_conversation() and conversation_new() optionsStig Bjørlykke1-2/+2
Fix find_conversation() and conversation_new() options after they was changed/improved in commit 709593ee.
2022-05-15epan: Fix our conversation flagsGerald Combs1-2/+2
Make sure we pass NO_ADDR2 and NO_PORT2 to conversation_new and NO_ADDR_B and NO_PORT_B to find_conversation.
2021-12-22Corrects repeated words throughout the code.Moshe Kaplan1-1/+1
Repeated words were found with: egrep "(\b[a-zA-Z]+) +\1\b" . -Ir and then manually reviewed. Non-displayed strings (e.g., in comments) were also corrected, to ease future review.
2021-08-24[build] fix warnings for unused variablesLin Sun1-2/+2
2020-10-22UMTS FP: Fix the length of the DRT field.Martin Mathieson1-1/+1
2020-08-31More spelling fixes, last part of 2nd pass of dissectors.Martin Mathieson1-1/+1
2020-08-08Fix most remaining detected cases where item with wrong type is used.Martin Mathieson1-1/+1
Error: proto_tree_add_string(.., hf_ansi_a_lai_mcc, ...) called at epan/dissectors/packet-ansi_a.c:3656 with type FT_UINT8 (allowed types are {'FT_STRINGZPAD', 'FT_STRINGZ', 'FT_STRING'} ) Error: proto_tree_add_string(.., hf_ansi_a_lai_mnc, ...) called at epan/dissectors/packet-ansi_a.c:3666 with type FT_UINT8 (allowed types are {'FT_STRINGZPAD', 'FT_STRINGZ', 'FT_STRING'} ) Error: proto_tree_add_none_format(.., hf_bthci_evt_vendor_codecs_item, ...) called at epan/dissectors/packet-bthci_evt.c:4712 with type FT_UINT32 (allowed types are {'FT_NONE'} ) Error: proto_tree_add_string(.., hf_kademlia_tag_hash, ...) called at epan/dissectors/packet-edonkey.c:1100 with type FT_BYTES (allowed types are {'FT_STRINGZPAD', 'FT_STRINGZ', 'FT_STRING'} ) Error: proto_tree_add_string(.., hf_msmms_data_timing_pair, ...) called at epan/dissectors/packet-ms-mms.c:680 with type FT_NONE (allowed types are {'FT_STRINGZPAD', 'FT_STRINGZ', 'FT_STRING'} ) Error: proto_tree_add_float_format_value(.., hf_fp_tpc_po, ...) called at epan/dissectors/packet-umts_fp.c:2405 with type FT_UINT8 (allowed types are {'FT_FLOAT'} ) Change-Id: I1ed0276ad9c810ca6b1b01d581c3d73ae28fb9ad Reviewed-on: https://code.wireshark.org/review/38081 Petri-Dish: Martin Mathieson <martin.r.mathieson@googlemail.com> Tested-by: Petri Dish Buildbot Reviewed-by: Martin Mathieson <martin.r.mathieson@googlemail.com>
2020-08-02UMTS_FP: Treat frame_type as an unsigned number, and use #defines for values.Martin Mathieson1-67/+70
Change-Id: Ifad2e02ef6e710c67801ea8479495736bf310d29 Reviewed-on: https://code.wireshark.org/review/38020 Petri-Dish: Martin Mathieson <martin.r.mathieson@googlemail.com> Tested-by: Petri Dish Buildbot Reviewed-by: Guy Harris <gharris@sonic.net> Reviewed-by: Anders Broman <a.broman58@gmail.com>
2020-08-01FP: add unsigned item with _uint calls rather than _int()Martin Mathieson1-12/+12
Change-Id: I10197f5ff3cbde312f98d1a75337e1bdd0a473d7 Reviewed-on: https://code.wireshark.org/review/38015 Petri-Dish: Martin Mathieson <martin.r.mathieson@googlemail.com> Tested-by: Petri Dish Buildbot Reviewed-by: Martin Mathieson <martin.r.mathieson@googlemail.com>
2020-07-06umts_fp: Try to fix -Wpointer-sign warnings.Anders Broman1-12/+12
Change-Id: I649556aa97c34a653109caf1d0311b856a71bc09 Reviewed-on: https://code.wireshark.org/review/37728 Reviewed-by: Anders Broman <a.broman58@gmail.com>
2020-05-03Some more issues identified by PVS-Studio.Martin Mathieson1-6/+4
/opt/SourceCode/wireshark/epan/dissectors/packet-osc.c 367 err V562 It's odd to compare 0 or 1 with a value of 0. /opt/SourceCode/wireshark/epan/dissectors/packet-rpc.c 960 note V576 Incorrect format. Consider checking the eighth actual argument of the 'proto_tree_add_subtree_format' function. The SIGNED integer type argument is expected. /opt/SourceCode/wireshark/epan/dissectors/packet-rpc.c 980 note V576 Incorrect format. Consider checking the third actual argument of the 'proto_item_append_text' function. The SIGNED integer type argument is expected. /opt/SourceCode/wireshark/epan/dissectors/packet-rpc.c 2473 note V576 Incorrect format. Consider checking the fourth actual argument of the 'col_prepend_fstr' function. The SIGNED integer type argument is expected. /opt/SourceCode/wireshark/epan/dissectors/packet-rpc.c 2482 note V576 Incorrect format. Consider checking the fourth actual argument of the 'col_append_fstr' function. The SIGNED integer type argument is expected. /opt/SourceCode/wireshark/epan/dissectors/packet-rpc.c 2633 note V576 Incorrect format. Consider checking the fourth actual argument of the 'col_append_fstr' function. The SIGNED integer type argument is expected. /opt/SourceCode/wireshark/epan/dissectors/packet-rpc.c 2650 note V576 Incorrect format. Consider checking the fourth actual argument of the 'col_prepend_fstr' function. The SIGNED integer type argument is expected. /opt/SourceCode/wireshark/epan/dissectors/packet-stun.c 565 warn V1051 Consider checking for misprints. It's possible that the 'reported_length' should be checked here. /opt/SourceCode/wireshark/epan/dissectors/packet-umts_fp.c 4126 warn V1051 Consider checking for misprints. It's possible that the 'reported_length' should be checked here. /opt/SourceCode/wireshark/epan/dissectors/packet-umts_fp.c 4942 warn V1051 Consider checking for misprints. It's possible that the 'reported_length' should be checked here. /opt/SourceCode/wireshark/ui/voip_calls.c 1444 err V773 The 'comment' pointer was assigned values twice without releasing the memory. A memory leak is possible. /opt/SourceCode/wireshark/wsutil/filesystem.c 1531 err V773 The function was exited without releasing the 'files' pointer. A memory leak is possible. /opt/SourceCode/wireshark/wsutil/filesystem.c 1717 err V773 The function was exited without releasing the 'files' pointer. A memory leak is possible. Bug: 16335 Change-Id: I8df3ba6d070823dcb43c4152d9156358f701e8dc Reviewed-on: https://code.wireshark.org/review/37069 Petri-Dish: Guy Harris <gharris@sonic.net> Tested-by: Petri Dish Buildbot Reviewed-by: Guy Harris <gharris@sonic.net>
2020-03-07fp: add missing field name to tree itemDarien Spencer1-2/+2
Change-Id: I788c964f100039641d274d93ae7429dcc7733d7e Reviewed-on: https://code.wireshark.org/review/36313 Petri-Dish: Anders Broman <a.broman58@gmail.com> Tested-by: Petri Dish Buildbot Reviewed-by: Anders Broman <a.broman58@gmail.com>
2020-02-15Some issues spotted by PVS-Studio in bug 16335. Many more remainMartin Mathieson1-7/+5
Change-Id: If856e25af8e33eeef5b9e595f1f6820459892b17 Reviewed-on: https://code.wireshark.org/review/36110 Petri-Dish: Martin Mathieson <martin.r.mathieson@googlemail.com> Tested-by: Petri Dish Buildbot Reviewed-by: Anders Broman <a.broman58@gmail.com>
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>
2019-04-04epan: Convert our PROTO_ITEM_ macros to inline functions.Gerald Combs1-23/+23
Convert our various PROTO_ITEM_ macros to inline functions and document them. Change-Id: I070b15d4f70d2189217a177ee8ba2740be36327c Reviewed-on: https://code.wireshark.org/review/32706 Reviewed-by: Gerald Combs <gerald@wireshark.org> Petri-Dish: Gerald Combs <gerald@wireshark.org> Reviewed-by: Anders Broman <a.broman58@gmail.com>
2019-04-03FP: Fix ToA shown as unsignedDarien Spencer1-1/+1
The 'sign' bit was treated like a regular bit because of direct casting to a wider int type Change-Id: Id0f095fa9bda97ecbdfc32f3610271eeea86fc2e Reviewed-on: https://code.wireshark.org/review/32688 Petri-Dish: Anders Broman <a.broman58@gmail.com> Tested-by: Petri Dish Buildbot Reviewed-by: Anders Broman <a.broman58@gmail.com>
2019-03-26umts_fp: check number of frames before calling a subdissector.Dario Lombardo1-18/+53
Bug: 15615 Change-Id: I37cb8f9a4bccff2fee1bc482c41dc7a3c728fbe3 Reviewed-on: https://code.wireshark.org/review/32515 Petri-Dish: Anders Broman <a.broman58@gmail.com> Tested-by: Petri Dish Buildbot Reviewed-by: Anders Broman <a.broman58@gmail.com>
2018-10-15FP: Added E-DCH T1 heuristic dissectorDarien Spencer1-1/+197
Change-Id: I22a3ba4a7caab1e4885292e6d28b2bc3d1e22bb7 Reviewed-on: https://code.wireshark.org/review/30208 Petri-Dish: Anders Broman <a.broman58@gmail.com> Tested-by: Petri Dish Buildbot Reviewed-by: Anders Broman <a.broman58@gmail.com>
2018-09-24FP: Fix commentsDarien Spencer1-15/+10
Rephrasing, remove commented code/irrelevant remarks Change-Id: I4da5bae1b87cce97595d20ab8634a4c0f600536b Reviewed-on: https://code.wireshark.org/review/29798 Petri-Dish: Anders Broman <a.broman58@gmail.com> Tested-by: Petri Dish Buildbot Reviewed-by: Anders Broman <a.broman58@gmail.com>
2018-09-23FP: Fix Sub-Frame number dissectionDarien Spencer1-1/+1
For E-DCH TYPE 1 frames, the field showed in the tree was showing 1 bit instead of 3. Change-Id: Ia28b2a8381f02a0f636ccb47b95b707915b90ff8 Reviewed-on: https://code.wireshark.org/review/29793 Reviewed-by: Anders Broman <a.broman58@gmail.com>
2018-09-20FP: Show E-DCH entity in treeDarien Spencer1-0/+22
Change-Id: I28755b38b168bc30ea4dc1addba3d9b5b31b3870 Reviewed-on: https://code.wireshark.org/review/29761 Petri-Dish: Anders Broman <a.broman58@gmail.com> Tested-by: Petri Dish Buildbot Reviewed-by: Anders Broman <a.broman58@gmail.com>
2018-09-17FP: Remove #if 0'd codeDarien Spencer1-21/+0
Change-Id: I422cc21bec0b9b12747dfc0d370ec4cf479a6e25 Reviewed-on: https://code.wireshark.org/review/29682 Reviewed-by: Anders Broman <a.broman58@gmail.com>
2018-09-17FP: HS-DSCH - Use RLC mode from NBAPDarien Spencer1-3/+13
If found in NBAP, use the RLC Mode indicated and spare guessing by the MAC-d Flow ID. Change-Id: Ie46922d53863667db630957a771092bc5ad00912 Reviewed-on: https://code.wireshark.org/review/29686 Petri-Dish: Anders Broman <a.broman58@gmail.com> Tested-by: Petri Dish Buildbot Reviewed-by: Anders Broman <a.broman58@gmail.com>
2018-09-16FP: Fix trying to resolve out-of-range LCHIDDarien Spencer1-25/+45
LCHID value of 15 indicates 'BCCH or PCCH' over HSDSCH and hence the MAC Content shouldn't be resolve by the ID. Also, make separate 'c/t' and 'lchid' concepts in the dch conversation info parsing. Bug: 14889 Change-Id: I7a3a8556108caf60c527e4cb5241dfad4ea9a331 Reviewed-on: https://code.wireshark.org/review/29657 Reviewed-by: Pascal Quantin <pascal.quantin@gmail.com> Petri-Dish: Pascal Quantin <pascal.quantin@gmail.com> Tested-by: Petri Dish Buildbot Reviewed-by: Anders Broman <a.broman58@gmail.com>
2018-09-06FP: Show ToA expert info for non-dch channelsDarien Spencer1-7/+11
Also fix precision for DCH ToA value in ms. Change-Id: Iece72953d129a3c9bb4aa3c1bcbc745c799eecb6 Reviewed-on: https://code.wireshark.org/review/29419 Petri-Dish: Anders Broman <a.broman58@gmail.com> Tested-by: Petri Dish Buildbot Reviewed-by: Anders Broman <a.broman58@gmail.com>
2018-07-21FP: Fix wrong indexerDarien Spencer1-2/+6
Change-Id: Iba74c38336ba06d207444fda32376a8c3851b61d Reviewed-on: https://code.wireshark.org/review/28787 Petri-Dish: Pascal Quantin <pascal.quantin@gmail.com> Tested-by: Petri Dish Buildbot Reviewed-by: Pascal Quantin <pascal.quantin@gmail.com>