aboutsummaryrefslogtreecommitdiffstats
path: root/epan/dissectors/packet-ipmi-transport.c
AgeCommit message (Collapse)AuthorFilesLines
2022-02-15Tools: Fix fix-encoding-args.pl ASCII string validationJoão Valverde1-20/+20
Do not require a useless ENC_NA parameter for string encodings. FT_STRING and FT_STRINGZ types don't have any ndianness. Follow-up to 6ec429622c9258eefd388caf21ce92ab5b9f54b4.
2021-12-19Replace g_snprintf() with snprintf() (dissectors)João Valverde1-3/+3
Use macros from inttypes.h with format strings.
2020-10-03Fix more filter field strings.Martin Mathieson1-1/+1
These appear to be copy/paste errors detected by running ./tools/check_typed_item_calls.py --consecutive Quite a few issues still remain after this batch.
2020-08-29Fix more spelling errors in dissector strings.Martin Mathieson1-3/+3
A second batch of spelling errors, detected using a script that uses pyspellcheck and a Wireshark-specific dictionary file. I will take at least one more pass through the dissectors, as further improvements are made to the script.
2020-06-19Fix the type of arrays of pointers to hf_ values for bitfield routines.Guy Harris1-96/+96
The static arrays are supposed to be arrays of const pointers to int, not arrays of non-const pointers to const int. Fixing that means some bugs (scribbling on what's *supposed* to be a const array) will be caught (see packet-ieee80211-radiotap.c for examples, the first of which inspired this change and the second of which was discovered while testing compiles with this change), and removes the need for some annoying casts. Also make some of those arrays static while we're at it. Update documentation and dissector-generator tools. Change-Id: I789da5fc60aadc15797cefecfd9a9fbe9a130ccc Reviewed-on: https://code.wireshark.org/review/37517 Petri-Dish: Guy Harris <gharris@sonic.net> 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>
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>
2015-02-27Add dissector for "Bad Password Threshold" IPMI LAN configuration parameter.Dmitry Bazhenov1-2/+635
Add dissectors for IPv6-related IPMI LAN configuration parameters. Bug:11012 Change-Id: I9b7380d2451acb6d68a03361e26dc3a6ebc129a0 Reviewed-on: https://code.wireshark.org/review/7404 Reviewed-by: Alexis La Goutte <alexis.lagoutte@gmail.com> Tested-by: Alexis La Goutte <alexis.lagoutte@gmail.com> Reviewed-by: Michael Mann <mmann78@netscape.net>
2015-02-26Fix a couple of bugs in IPMI dissector:Dmitry Bazhenov1-2/+2
* Fix incorrect offset for Block Selector field in Get LAN Configuration Parameter request. * Expect 0x83 completion code ("Attempt to read write-only parameter") for Get LAN Configuration Parameter command instead of Set LAN Configuration Parameter command. Change-Id: I5be37c5f96db91b70329bfce906ce76f7b8b6958 Reviewed-on: https://code.wireshark.org/review/7403 Reviewed-by: Alexis La Goutte <alexis.lagoutte@gmail.com>
2015-02-18Add a CF_FUNC macro for casting BASE_CUSTOM functions.Gerald Combs1-37/+37
Add a CF_FUNC macro to match VALS, TFS, etc. This should help us to avoid the following warning: warning: ISO C forbids initialization between function pointer and 'void *' [-Wpedantic] We could start adding DIAG_OFF+DIAG_ON everywhere but this seems to be more consistent with the other macros in proto.h. Update each instance of BASE_CUSTOM to use CF_FUNC. Adjust a dummy variable name generated by asn2wrs.py that was triggering an invalid error in checkhf.pl. Fix an encoding arguement in packet-elasticsearch.c found by fix-encoding-args.pl. Change-Id: Id0e75076c2d71736639d486f47b87bab84e07d22 Reviewed-on: https://code.wireshark.org/review/7150 Reviewed-by: Gerald Combs <gerald@wireshark.org>
2014-08-16Fix warning: no previous prototype for ... [-Wmissing-prototypes]Alexis La Goutte1-0/+2
Change-Id: I6790a6c990bd531362171742b938c9f26cb2e1d5 Reviewed-on: https://code.wireshark.org/review/3636 Reviewed-by: Anders Broman <a.broman58@gmail.com>
2014-08-10Eliminate proto_tree_add_text from some dissectors.Michael Mann1-28/+45
Other minor cleanup while in the neighborhood. Change-Id: Ib76f4a9f89b5933425760af0a980c6a549031b8f Reviewed-on: https://code.wireshark.org/review/3537 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-06-29proto_tree_add_subtree[_format]Michael Mann1-4/+2
Change-Id: I7e016f10fcfdc0523bf2fe8c11295c0334f7c332 Reviewed-on: https://code.wireshark.org/review/2694 Reviewed-by: Michael Mann <mmann78@netscape.net>
2014-06-16Have ipmi "dissectors" register through the build process instead of "manually"Michael Mann1-1/+1
Change-Id: I6d6d32e8a1bc21dee9bf52b502e1a02e9511ecb2 Reviewed-on: https://code.wireshark.org/review/2253 Reviewed-by: Dmitry Bazhenov <dima_b@pigeonpoint.com> Reviewed-by: Evan Huus <eapache@gmail.com> Reviewed-by: Michael Mann <mmann78@netscape.net>
2014-06-06IPMI trace dissector (without PCAP-dependent part).U-beauty\bdn1-38/+36
Added KCS and TMode protocol dissectors. Request/response logic has been revised. Saved request data logic has been revised. Added Get Message command response dissector. Added missing PICMG command dissectors. Added new PICMG command dissectors. Added new PPS OEM command entries. Added VITA 46.11 command dissectors. From: Bill Meier: - refs to value_strings/range_strings in hf[] entries, by convention, should use VALS/RVALS macros; - refs to true_false_strings should use TFS(&...) macro. also: true_false_string definitions should not be defined as arrays. - remove some unneeded #includes (packet-ipmi.c). - Do some re-indentation. - Add editor-modelines as needed. bug: 10004 Change-Id: Ib269b35784c0b70892d1e0111bcfb483ea64092c Reviewed-on: https://code.wireshark.org/review/1185 Reviewed-by: Anders Broman <a.broman58@gmail.com>
2014-06-03packet-ipmi...: Various cleanups:Bill Meier1-54/+67
- refs to value_strings in hf[] entries, by convention, should use VALS macro; - add editor-modelines as needed; Fix some indentation. Change-Id: Iaa0196bab6de066ed68a2755b69b07fadd33e498 Reviewed-on: https://code.wireshark.org/review/1927 Reviewed-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-05-03Remove global packet_info* current_pinfoMichael Mann1-25/+25
svn path=/trunk/; revision=49143
2013-01-31Comment out unused hf[] entries & etc.Bill Meier1-1/+3
(found by checkhf) svn path=/trunk/; revision=47389
2012-09-20We always HAVE_CONFIG_H so don't bother checking whether we have it or not.Jeff Morriss1-2/+0
svn path=/trunk/; revision=45017
2012-08-10Use val_to_str_const() where appropriate;Bill Meier1-4/+4
Also (for a few files): - create/use some extended value strings; - remove unneeded #include files; - remove unneeded variable initialization; - re-order fcns slightly so prefs_reg_handoff...() at end, etc svn path=/trunk/; revision=44438
2012-05-04AFAICT sys/types.h & netinet/in.h #includes are not needed for these files.Bill Meier1-4/+0
(Let's see if any of the buildbots give any errors). Also: remove trailing whitespace on lines. svn path=/trunk/; revision=42429
2011-12-22Use ENC_LITTLE_ENDIAN instead of TRUE as endian argument to ↵Chris Maynard1-96/+96
proto_tree_add_bitmask_text(). svn path=/trunk/; revision=40271
2011-10-20Use ENC_NA as proto_tree_add_item() encoding arg for FT_ETHER hf[] field type.Bill Meier1-6/+6
(Some minor whitespace cleanup). svn path=/trunk/; revision=39488
2011-10-16Do some conversions of proto_tree_add_item() 'encoding' arg.Bill Meier1-1/+1
(previously missed). 57 FT_BOOLEAN: FALSE-->ENC_BIG_ENDIAN 31 FT_BOOLEAN: TRUE-->ENC_LITTLE_ENDIAN 10 FT_BYTES: ENC_BIG_ENDIAN-->ENC_NA 1 FT_BYTES: ENC_LITTLE_ENDIAN-->ENC_NA 21 FT_BYTES: FALSE-->ENC_NA 2 FT_BYTES: TRUE-->ENC_NA 2 FT_IPXNET: ENC_BIG_ENDIAN-->ENC_NA 6 FT_IPv6: ENC_BIG_ENDIAN-->ENC_NA 1 FT_IPv6: FALSE-->ENC_NA 6 FT_NONE: ENC_BIG_ENDIAN-->ENC_NA 19 FT_NONE: FALSE-->ENC_NA 3 FT_NONE: TRUE-->ENC_NA 1 FT_STRING: ENC_BIG_ENDIAN-->ENC_ASCII|ENC_NA 1 FT_STRING: ENC_LITTLE_ENDIAN-->ENC_ASCII|ENC_NA 5 FT_STRING: FALSE-->ENC_ASCII|ENC_NA 1 FT_STRING: TRUE-->ENC_ASCII|ENC_NA 4 FT_STRINGZ: ENC_NA-->ENC_ASCII|ENC_NA 8 FT_STRINGZ: FALSE-->ENC_ASCII|ENC_NA 1 FT_INT32: FALSE-->ENC_BIG_ENDIAN 1 FT_INT32: TRUE-->ENC_LITTLE_ENDIAN 11 FT_UINT8: 0-->ENC_BIG_ENDIAN 111 FT_UINT8: FALSE-->ENC_BIG_ENDIAN 17 FT_UINT8: TRUE-->ENC_LITTLE_ENDIAN 1 FT_UINT16: 0-->ENC_BIG_ENDIAN 68 FT_UINT16: FALSE-->ENC_BIG_ENDIAN 18 FT_UINT16: TRUE-->ENC_LITTLE_ENDIAN 4 FT_UINT24: FALSE-->ENC_BIG_ENDIAN 70 FT_UINT32: FALSE-->ENC_BIG_ENDIAN 1 FT_UINT32: TRUE-->ENC_LITTLE_ENDIAN 4 FT_UINT64: FALSE-->ENC_BIG_ENDIAN 1 FT_UINT64: TRUE-->ENC_LITTLE_ENDIAN 1 FT_UINT_STRING: FALSE-->ENC_ASCII|ENC_BIG_ENDIAN svn path=/trunk/; revision=39442
2011-10-15Convert proto_tree_add_item() 'encoding' arg for field types FT_STRING, ↵Bill Meier1-20/+20
FT_STRINGZ, FT_UINT_STRING as follows: 1. If there's no character encoding (ENC_ASCII, ...) specified then use ENC_ASCII. 2. For all but FT_UINT_STRING, always use ENC_NA (replacing any existing True/1/FALSE/0 /ENC_BIG_ENDIAN/ENC_LITTLE_ENDIAN). svn path=/trunk/; revision=39426
2011-10-10 Convert 'encoding' parameter of certain proto_tree_add_item() calls in ↵Bill Meier1-12/+12
non-autogenerated epan/dissectors: Specifically: Replace FALSE|0 and TRUE|1 by ENC_BIG_ENDIAN|ENC_LITTLE_ENDIAN as the encoding parameter for proto_tree_add_item() calls which directly reference an item in hf[] which has a type of: FT_BOOLEAN FT_IPv4 FT_EUI64 FT_GUID FT_UINT_STRING Also: For type FT_ITv6 use ENC_NA. (This was missed in SVN #39260) svn path=/trunk/; revision=39328
2011-10-06Convert 'encoding' parameter of certain proto_tree_add_item() calls in ↵Bill Meier1-61/+61
non-autogenerated epan/dissectors: Specifically: Replace FALSE|0 and TRUE|1 by ENC_BIG_ENDIAN|ENC_LITTLE_ENDIAN as the encoding parameter for proto_tree_add_item() calls which directly reference an item in hf[] which has a type of: FT_UINT8 FT_UINT16 FT_UINT24 FT_UINT32 FT_UINT64 FT_INT8 FT_INT16 FT_INT24 FT_INT32 FT_INT64 FT_FLOAT FT_DOUBLE svn path=/trunk/; revision=39288
2011-10-04Use ENC_NA as encoding for proto_tree_add_item() calls which directly ↵Bill Meier1-12/+12
reference an hf item (in hf[] with types: FT_NONE FT_BYTES FT_IPV6 FT_IPXNET FT_OID Note: Encoding field set to ENC_NA only if the field was previously TRUE|FALSE|ENC_LITTLE_ENDIAN|ENC_BIG_ENDIAN svn path=/trunk/; revision=39260
2009-08-28Fix if test in fcn rs11():Bill Meier1-1/+1
return if either (as opposed to both) of the required sparameters is not present; (Found by clang scan-build). svn path=/trunk/; revision=29600
2009-06-18From Kovarththanan Rajaratnam via bug 3548:Stig Bjørlykke1-284/+284
(1) Trailing/leading spaces are removed from 'name's/'blurb's (2) Duplicate 'blurb's are replaced with NULL (3) Empty ("") 'blurb's are replaced with NULL (4) BASE_NONE, NULL, 0x0 are used for 'display', 'strings' and 'bitmask' fields for FT_NONE, FT_BYTES, FT_IPv4, FT_IPv6, FT_ABSOLUTE_TIME, FT_RELATIVE_TIME, FT_PROTOCOL, FT_STRING and FT_STRINGZ field types (5) Only allow non-zero value for 'display' if 'bitmask' is non-zero svn path=/trunk/; revision=28770
2009-04-07Use some default true_false_string's.Bill Meier1-42/+38
svn path=/trunk/; revision=27983
2008-08-06From Alexey Neyman :Anders Broman1-0/+3197
(Note just checking in the new files not yet added to the build process on purpose the changes to packet-ipmi.c is also not done yet - Anders). Generic changes: - IPMI session wrapper dissection has been separated from the dissection of IPMI itself. This will allow for possible dissection of captures directly from IPMB (as the IPMB messages lack the IPMI session wrapper). IPMI changes: - Implemented request-response matching for IPMI sessions. This makes easy serves two purposes: first, it allows for easy location of response to a certain request and vice versa. Second, it allows for dissection of responses where response format depends on the request data. - IPMI dissector can now dissect much broader set of commands. - Command-specific completion codes are now handled. - The dissector is able to parse IPMI commands embedded into other IPMI commands (for now, only Send Message; Get Message and Forward Message can be implemented later). Such embedded commands also matched with responses to them. svn path=/trunk/; revision=25948