aboutsummaryrefslogtreecommitdiffstats
path: root/epan/dissectors/packet-iso8583.c
AgeCommit message (Collapse)AuthorFilesLines
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>
2016-10-15Eliminate a global variable.Guy Harris1-11/+14
Have the packet length be a local variable, and pass it to routines. Yes, that means we fetch it twice - no great loss. Change-Id: Id9f95b3d8a19bf235d6b19993165e0f73a2e5732 Reviewed-on: https://code.wireshark.org/review/18211 Reviewed-by: Guy Harris <guy@alum.mit.edu>
2016-10-15Fix bin2hex().Guy Harris1-3/+3
It was repeatedly overwriting the first character in the buffer, rather than appending characters. Change-Id: Ie34d194d69ac3d685416323c93764aa401d78faa Reviewed-on: https://code.wireshark.org/review/18209 Reviewed-by: Guy Harris <guy@alum.mit.edu>
2016-10-13iso8583: use unsigned and fix bug in conversion routine.Dario Lombardo1-9/+9
Change-Id: I0ba30bda3abec004f51f9402d65c38b3b1081113 Reviewed-on: https://code.wireshark.org/review/18144 Petri-Dish: Dario Lombardo <lomato@gmail.com> Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org> Reviewed-by: Paulo Roberto Brandão <betobrandao@gmail.com> Reviewed-by: Dario Lombardo <lomato@gmail.com>
2016-10-08Combine Decode As and port preferences for tcp.port dissector table.Michael Mann1-26/+4
This patch introduces new APIs to allow dissectors to have a preference for a (TCP) port, but the underlying data is actually part of Decode As functionality. For now the APIs are intentionally separate from the regular APIs that register a dissector within a dissector table. It may be possible to eventually combine the two so that all dissectors that register with a dissector table have an opportunity to "automatically" have a preference to adjust the "table value" through the preferences dialog. The tcp.port dissector table was used as the guinea pig. This will eventually be expanded to other dissector tables as well (most notably UDP ports). Some dissectors that "shared" a TCP/UDP port preference were also converted. It also removed the need for some preference callback functions (mostly when the callback function was the proto_reg_handoff function) so there is cleanup around that. Dissectors that has a port preference whose default was 0 were switched to using the dissector_add_for_decode_as_with_preference API rather than dissector_add_uint_with_preference Also added comments for TCP ports used that aren't IANA registered. Change-Id: I99604f95d426ad345f4b494598d94178b886eb67 Reviewed-on: https://code.wireshark.org/review/17724 Reviewed-by: Michael Mann <mmann78@netscape.net>
2016-10-08iso8583: use ws_strtoi function.Dario Lombardo1-7/+4
Change-Id: Icbf98fe1754984cde137dffd98ae6e24ca34081d Reviewed-on: https://code.wireshark.org/review/18114 Petri-Dish: Dario Lombardo <lomato@gmail.com> Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org> Reviewed-by: Michael Mann <mmann78@netscape.net>
2016-03-31Squelch a "not allowed in C++" warning.Guy Harris1-1/+1
Change-Id: I2accdb7fe02072853a5ec9cae84403f3224dfada Reviewed-on: https://code.wireshark.org/review/14718 Reviewed-by: Guy Harris <guy@alum.mit.edu>
2016-03-31Clean up some stuff.Guy Harris1-22/+23
Have bin2hex() wmem_allocate the buffer, so it can be used the same way that tvb_get_string_enc() is used. Don't bother checking whether NIBBLE_2_ASCHEX() returns an ASCII hex digit character or not - it returns either a value in the ASCII range of '0' through '9' or in the range 'A' through 'F', all of which are ASCII hex digits. Fix get_bit() to set *length to 0 if the string we're returning is empty. Change-Id: Id331cfd0ab34d45892f98d228dc793a1e93d84e5 Reviewed-on: https://code.wireshark.org/review/14717 Reviewed-by: Guy Harris <guy@alum.mit.edu>
2016-03-13ISO 8583-1 dissector initial importPaulo Roberto Brandão1-0/+1405
Initial import of source code for the dissector of the ISO 8583-1 'financial transaction card originated messages - Interchange message specification' standard. Bug: 12244 Change-Id: I24804cab4a93131ec9afa307844ad62eb2e01089 Reviewed-on: https://code.wireshark.org/review/14311 Petri-Dish: João Valverde <j@v6e.pt> Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org> Reviewed-by: Alexis La Goutte <alexis.lagoutte@gmail.com>