aboutsummaryrefslogtreecommitdiffstats
path: root/epan/dissectors/packet-batadv.c
AgeCommit message (Collapse)AuthorFilesLines
2014-12-13Use ENC_BIG_ENDIAN when fetching FT_U?INT8 fields ...Bill Meier1-2/+2
(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-11-29Use proto_tree_add_bitmask for groups of proto_tree_add_boolean.Michael Mann1-87/+73
Part 1 of many Change-Id: I77a5789ac23388e6a5f8098dc398592f39638124 Reviewed-on: https://code.wireshark.org/review/5532 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-11-17BATMAN: fix indent and encoding argsAlexis La Goutte1-79/+79
use tabs for indent and use fix-encoding-args tools Change-Id: I5e066c6cbc429021cf21a55d5ffd5b60718ad5f8 Reviewed-on: https://code.wireshark.org/review/5340 Reviewed-by: Michael Mann <mmann78@netscape.net> Reviewed-by: Evan Huus <eapache@gmail.com>
2014-11-16BATMAN: Fix Dead Store (Dead assignement/Dead increment) warning found by ClangAlexis La Goutte1-1/+1
Change-Id: I6cfabc18921397002a2303f3511fa51bf5b41956 Reviewed-on: https://code.wireshark.org/review/5341 Reviewed-by: Michael Mann <mmann78@netscape.net>
2014-11-14batadv: Add dissector support for batadv v15Sven Eckelmann1-10/+1619
The packet format for batman-adv v15 supports: * Complete reordered packet type ids * reordered flags * type-version-length-value data containers * new types for coding packets and unicast transfer of TVLVs * dropped packet types for vis, translation table query and roaming * reordered packet formats * transparent fragmentation of batadv packets Change-Id: I9e6733f9dd6b54eeecda19cf570599161d28b46e Signed-off-by: Sven Eckelmann <sven@open-mesh.com> Signed-off-by: Simon Wunderlich <simon@open-mesh.com> Reviewed-on: https://code.wireshark.org/review/5175 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-11-08batadv: Add missing padding to batadv_unicast_4addr_v14Sven Eckelmann1-1/+6
The already frozen packet format of batman-adv for Linux 3.5 was rejected by David S. Miller. The 4addr format v14 was therefore changed after the freeze and published in his final form in Linux 3.8. Change-Id: I519476c4c6d62b403e197fae6a853d9bbe61f9bc Signed-off-by: Sven Eckelmann <sven@open-mesh.com> Signed-off-by: Simon Wunderlich <simon@open-mesh.com> Reviewed-on: https://code.wireshark.org/review/5174 Reviewed-by: Michael Mann <mmann78@netscape.net>
2014-09-19Add editor modelines; Adjust indentation as needed.Bill Meier1-2/+15
Change-Id: Ie8d4056ab706bbc85c8247682b1a64ea98bc89f2 Reviewed-on: https://code.wireshark.org/review/4185 Reviewed-by: Bill Meier <wmeier@newsguy.com>
2014-09-19Do encoding-arg changes (all benign)Bill Meier1-1/+1
For: - FT_BYTES: Always use just ENC_NA - integral/floating (other than FT_[U]INT8): Do ENC_NA --> ENC_BIG_ENDIAN Also: - FT_UINT... --> FT_UINT8 in a few cases (to match proto_tree_add_item...) - Change one case of incorrect '||' to '|' Change-Id: I427e0e61618ff8faf55691c8a695930f67d455b0 Reviewed-on: https://code.wireshark.org/review/4184 Reviewed-by: Bill Meier <wmeier@newsguy.com>
2014-08-03Eliminate proto_tree_add_text from some dissectors.Michael Mann1-6/+30
Change-Id: I398e9cf4f6882e76644aa758e12c39a39159e95f Reviewed-on: https://code.wireshark.org/review/3319 Petri-Dish: Michael Mann <mmann78@netscape.net> Petri-Dish: Evan Huus <eapache@gmail.com> Reviewed-by: Michael Mann <mmann78@netscape.net>
2014-06-22convert to proto_tree_add_subtree[_format]Michael Mann1-4/+3
Change-Id: Ib60ca75b7da8cfa21cfe2999c9b9448a02c332df Reviewed-on: https://code.wireshark.org/review/2560 Tested-by: Michael Mann <mmann78@netscape.net> Reviewed-by: Michael Mann <mmann78@netscape.net>
2014-06-19Revert "Fixup: tvb_* -> tvb_captured"Michael Mann1-26/+26
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-26/+26
Change-Id: I9209c1271967405c34c1b6fa43e1726a4d3a5a3f Reviewed-on: https://code.wireshark.org/review/2377 Reviewed-by: Anders Broman <a.broman58@gmail.com>
2014-06-07tvb_new_subset -> tvb_new_subset_length when length parameters are equal.Michael Mann1-25/+25
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-25Grab-bag of dead initializers and two actual bugs.Evan Huus1-2/+2
All caught by cppcheck. The two (semi)-interesting bugs are: - in asn1/atn-cpdlc/packet-atn-cpdlc-template.c where the break statement should have been inside the brace, causing potential control-flow weirdness with exceptions - in epan/dissectors/packet-ieee80211.c where the bounds check for tag_len did not match the expert info given Change-Id: Ie173fb8d917aabb9b4571435d671d6f16e1c7569 Reviewed-on: https://code.wireshark.org/review/1793 Reviewed-by: Alexis La Goutte <alexis.lagoutte@gmail.com> Reviewed-by: Evan Huus <eapache@gmail.com>
2014-03-07(Benign) Don't use "address-of" operator on arg of VALS() (not that it makes ↵Bill Meier1-2/+2
any actual difference).. Change-Id: I0766d0f130648aaa5a58d9f4062fa24e898cbdc3 Reviewed-on: https://code.wireshark.org/review/545 Reviewed-by: Bill Meier <wmeier@newsguy.com> Tested-by: Bill Meier <wmeier@newsguy.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>
2013-09-12Convert a few more dissectors to wmemPascal Quantin1-22/+23
svn path=/trunk/; revision=51991
2013-07-17Remove fragment_data, add fragment_head, fragment_item - for now alias it to ↵Jakub Zawadzki1-2/+2
the same structure. This is begin of work to split fragment head and fragments items. svn path=/trunk/; revision=50708
2013-03-22Don't wire into the reassembly code the notion that reassemblies shouldGuy Harris1-12/+9
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-14[-Wmissing-prototypes]Anders Broman1-22/+23
explicit casts. svn path=/trunk/; revision=48302
2012-09-20We always HAVE_CONFIG_H so don't bother checking whether we have it or not.Jeff Morriss1-3/+1
svn path=/trunk/; revision=45017
2012-09-07From Robert Bullen via ↵Jeff Morriss1-0/+2
https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=7683 : The reassembled fragments tree in the Packet Details view is awesome, but it lacks one thing: a field that exposes the reassembled data. tcp.data already exists for exposing a single TCP segment's payload as a byte array. It would be handy to have something similar for a single application layer PDU when TCP segment reassembly is involved. I propose tcp.reassembled.data, named and placed after the already existing field tcp.reassembled.length. My primary use case for this feature is outputting tcp.reassembled.data with tshark for further processing with a script. The attached patch implements this very feature. Because the reassembled fragment tree code is general purpose, i.e. not specific to just TCP, any dissector that relies upon it can add a similar field very cheaply. In that vein I've also implemented ip.reassembled.data and ipv6.reassembled.data, which expose reassembled fragment data as a single byte stream for IPv4 and IPv6, respectively. All other protocols that use the reassembly code have been left alone, other than inserting NULL into their initializer lists for the newly introduced struct field reassemble.h:fragment_items.hf_reassembled_data. svn path=/trunk/; revision=44802
2012-07-13tvb_length_remaining() can return -1, so don't assign its return value to an ↵Chris Maynard1-50/+47
unsigned integer and don't check it against non-zero but greater than zero. svn path=/trunk/; revision=43699
2012-06-18From Sven Eckelmann via ↵Pascal Quantin1-0/+7
https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=7375 : Add support for not_best_next_hop flag in B.A.T.M.A.N. Advanced v14 svn path=/trunk/; revision=43332
2012-03-29From Sven Eckelmann via https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=7009Alexis La Goutte1-9/+181
Add support for 4addr unicast packets Add support for 4addr unicast packets packets that will be supported in linux 3.5. svn path=/trunk/; revision=41826
2012-03-06Fix benign issue: For FT_BOOLEAN fields with a zero bitmask, use BASE_NONE ↵Bill Meier1-4/+4
for 'display' svn path=/trunk/; revision=41385
2011-10-21For proto_tree_add_item(..., proto_xxx, ...)use ENC_NA as the encoding arg.Bill Meier1-25/+25
Also: remove trailing whitespace for a number of files. svn path=/trunk/; revision=39503
2011-09-26Get rid of check_col, while at it set ENC.Anders Broman1-150/+142
svn path=/trunk/; revision=39146
2011-07-08%u suffices, as varargs are widened. (It aslso doesn't cause Clang toGuy Harris1-2/+2
complain.) svn path=/trunk/; revision=37933
2011-07-05From Sven Eckelmann:Anders Broman1-1/+1175
Add support for v14 https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=6046 svn path=/trunk/; revision=37901
2011-07-05From Sven Eckelmann:Anders Broman1-42/+42
Rename HNA to TT to use the same names as upstream. https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=6046 svn path=/trunk/; revision=37900
2011-07-04From Sven Eckelmann:Anders Broman1-4/+4
Fix size of unicast fragment packet in v12. https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=5658 svn path=/trunk/; revision=37897
2011-07-04From Sven Eckelmann:Anders Broman1-3/+0
Remove unused length_remaining. https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=5658 svn path=/trunk/; revision=37896
2011-07-04From Sven Eckelmann:Anders Broman1-139/+121
Unify handling of NULL-tree in dissection routines. https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=5658 svn path=/trunk/; revision=37894
2011-05-23Delete unused header field entries found by running checkhf.pl.Chris Maynard1-15/+3
svn path=/trunk/; revision=37353
2011-05-23From Micheal Mann via bug 2794: Fix some display filter field names.Chris Maynard1-2/+2
svn path=/trunk/; revision=37351
2011-05-14From Sven Eckelmann via ↵Jeff Morriss1-1/+295
https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=5658 : Add support for v12 fragmented unicast. svn path=/trunk/; revision=37143
2011-05-14From Sven Eckelmann via ↵Jeff Morriss1-44/+54
https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=5658 : Read unchanged packets of v12 as v10 packets Read unchanged packets of v13 as v11 packets Use version in packet type definitions svn path=/trunk/; revision=37142
2011-02-16Use tvb_ether_to_str() when it can eliminate a tvb_get_ptr() call.Jeff Morriss1-3/+1
svn path=/trunk/; revision=35960
2011-02-07Fix bug #5657: Update my mail address Stephen Fisher1-1/+1
svn path=/trunk/; revision=35868
2010-12-20Rename the routines that handle dissector tables with unsigned integerGuy Harris1-2/+2
keys to have _uint in their names, to match the routines that handle dissector tables with string keys. (Using _port can confuse people into thinking they're intended solely for use with TCP/UDP/etc. ports when, in fact, they work better for things such as Ethernet types, where the binding of particular values to particular protocols are a lot stronger.) svn path=/trunk/; revision=35224
2010-10-31Corrected abbrev for Source and Destination.Stig Bjørlykke1-2/+2
svn path=/trunk/; revision=34733
2010-07-06From Sven Eckelmann:Anders Broman1-26/+62
Dissector/packet-batadv: Add support for icmp rr. https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=4922 svn path=/trunk/; revision=33444
2010-07-01From Sven Eckelmann: Fix size of seqno in icmp packetsBill Meier1-5/+5
See Bug #4921: https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=4921 svn path=/trunk/; revision=33405
2010-07-01From Sven Eckelmann: Add support for v11 packet formatBill Meier1-0/+125
"Please add support for v11 ogm packets used in linux 2.6.36" See: Bug #4920: https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=4920 svn path=/trunk/; revision=33404
2010-06-03From Sven Eckelmann: Change recursion for aggregated packets to iteration.Bill Meier1-286/+243
See Bug #2631: https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=2631 svn path=/trunk/; revision=33075
2010-06-03From: Sven Eckelmann:Add support for v10 packet formatBill Meier1-17/+395
"v10 of the packet format was added recently and could be added to the wireshark dissector" See: Bug #4833: https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=4833 From me: - Fix a compile error: ...version=tvb_get_ntohs... - Fix a missing = NULL. svn path=/trunk/; revision=33066
2010-06-03Add back a few 'if (check_col()...' removed by me in a previous commit.Bill Meier1-12/+15
Possibly it's better to use an 'if (checkcol()' if the enclosed call to 'col_...' has "complex" arguments. svn path=/trunk/; revision=33064
2010-06-02From Sven Eckelmann: Fix endless recursive loopBill Meier1-0/+24
See Bug #2631: https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=2631 svn path=/trunk/; revision=33060
2010-06-02Misc changes:Bill Meier1-35/+36
- Clear info col before beginning dissection; - Remove some uneeded forward declarations; - Remove some ... = NULL initializers; - Display protocol as BATADV_??? if unknown type; - '(gwflags & 0x7C) >> 3' ==> '(gwflags & 0x78) >> 3' svn path=/trunk/; revision=33057