aboutsummaryrefslogtreecommitdiffstats
path: root/epan/dissectors/packet-lisp.c
AgeCommit message (Collapse)AuthorFilesLines
2020-10-23LISP: add support for vendor specific LCAFLorand Jakab1-26/+92
Specified by the IETF LISP WG: https://tools.ietf.org/html/draft-ietf-lisp-vendor-lcaf
2020-05-26LISP: add support for Distinguished Name AFI in LCAFsLorand Jakab1-0/+67
Distinguished Name (AFI 17) is not a widely used address family, but there is ongoing work in the LISP IETF working group to standardize its use within the LISP control plane protocol. The encoding is quite simple, it's just a zero-terminated ASCII string. Details can be found in the following IETF draft: https://tools.ietf.org/html/draft-farinacci-lisp-name-encoding A previous patch (https://code.wireshark.org/review/36892) added support for DN in simple AFI usages. This patch add support for DN within the LISP Canonical Address Format (LCAF) usage. Change-Id: Ic2dbbd1e36e2eabb91202c04eb86fdf151fe9928 Reviewed-on: https://code.wireshark.org/review/37275 Petri-Dish: Alexis La Goutte <alexis.lagoutte@gmail.com> Tested-by: Petri Dish Buildbot Reviewed-by: Anders Broman <a.broman58@gmail.com>
2020-04-22LISP: add support for Distinguished Name AFILorand Jakab1-4/+33
Distinguished Name (AFI 17) is not a widely used address family, but there is ongoing work in the LISP IETF working group to standardize its use within the LISP control plane protocol. The encoding is quite simple, it's just a zero-terminated ASCII string. Details can be found in the following IETF draft: https://tools.ietf.org/html/draft-farinacci-lisp-name-encoding Change-Id: I701f54d0c5e95b14ad48030935eb059bd68c9a0e Reviewed-on: https://code.wireshark.org/review/36892 Reviewed-by: Alexis La Goutte <alexis.lagoutte@gmail.com> Petri-Dish: Alexis La Goutte <alexis.lagoutte@gmail.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>
2018-11-16LISP: Switch to proto_tree_add_subtree_format()Lorand Jakab1-29/+6
When the LISP dissector was initially written, it followed a different pattern for adding subtrees with a text label, which needs to be modified while dissecting: proto_tree_add_item() + proto_item_append_text() + proto_item_add_subtree(). This commit updates the code to use the more elegant proto_tree_add_subtree_format() call. Change-Id: Icb6424be3c9cdecbfe9bb5aa2d39f3ad3d1499e0 Signed-off-by: Lorand Jakab <ljakab@ac.upc.edu> Reviewed-on: https://code.wireshark.org/review/30655 Petri-Dish: Pascal Quantin <pascal.quantin@gmail.com> Tested-by: Petri Dish Buildbot Reviewed-by: Pascal Quantin <pascal.quantin@gmail.com>
2018-11-14LISP: Fix action bits decodingLorand Jakab1-1/+7
Change-Id: I76f5e10fbc5ca0071d1444e31ce4c8fba639c3bc Signed-off-by: Lorand Jakab <ljakab@ac.upc.edu> Reviewed-on: https://code.wireshark.org/review/30630 Petri-Dish: Anders Broman <a.broman58@gmail.com> Tested-by: Petri Dish Buildbot Reviewed-by: Anders Broman <a.broman58@gmail.com>
2018-08-03LISP: add support for Reliable Transport messagesLorand Jakab1-56/+30
These messages are defined in [0], and are used in some deployed products already. [0] https://tools.ietf.org/html/draft-kouvelas-lisp-map-server-reliable-transport-04 Change-Id: Idfbc777175c1596d3e0fa1df39602a68ee1c488f Signed-off-by: Lorand Jakab <ljakab@ac.upc.edu> Reviewed-on: https://code.wireshark.org/review/28503 Petri-Dish: Alexis La Goutte <alexis.lagoutte@gmail.com> Tested-by: Petri Dish Buildbot Reviewed-by: Alexis La Goutte <alexis.lagoutte@gmail.com> Reviewed-by: Anders Broman <a.broman58@gmail.com>
2018-06-08LISP: Decode AFNUM_802 as AFNUM_EUI48Lorand Jakab1-0/+13
Some LISP implementations use the AFI value 6 (RFC 1700) for MAC addresses instead of AFI value 16389 (RFC 7042). This patch allows correct decoding of both. Change-Id: I12c3d6b90fd8a85911f76dec5448e6a2e237e797 Signed-off-by: Lorand Jakab <ljakab@ac.upc.edu> Reviewed-on: https://code.wireshark.org/review/28115 Petri-Dish: Anders Broman <a.broman58@gmail.com> Tested-by: Petri Dish Buildbot Reviewed-by: Anders Broman <a.broman58@gmail.com>
2018-02-12dissectors: use SPDX identifiers.Dario Lombardo1-14/+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-13Convert most UDP dissectors to use "auto" preferences.Michael Mann1-1/+1
Similar to the "tcp.port" changes in I99604f95d426ad345f4b494598d94178b886eb67, convert dissectors that use "udp.port". More cleanup done on dissectors that use both TCP and UDP dissector tables, so that less preference callbacks exist. Change-Id: If07be9b9e850c244336a7069599cd554ce312dd3 Reviewed-on: https://code.wireshark.org/review/18120 Petri-Dish: Michael Mann <mmann78@netscape.net> Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org> Reviewed-by: Michael Mann <mmann78@netscape.net>
2016-03-20Create call_data_dissector() to call data dissector.Michael Mann1-14/+12
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-03-20Manually add protocol dependencies derived from find_dissector.Michael Mann1-2/+2
Started by grepping call_dissector_with_data, call_dissector_only and call_dissector and traced the handles passed into them to a find_dissector within the dissector. Then replaced find_dissector with find_dissector_add_dependency and added the protocol id from the dissector. "data" dissector was not considered to be a dependency. Change-Id: I15d0d77301306587ef8e7af5876e74231816890d Reviewed-on: https://code.wireshark.org/review/14509 Petri-Dish: Michael Mann <mmann78@netscape.net> Reviewed-by: Michael Mann <mmann78@netscape.net>
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-16Add DEGREE SIGN character to utf8_entities.h and use it.Guy Harris1-4/+7
Add a #define giving the UTF-8 sequence for DEGREE SIGN, and use it in packet-synphasor.c rather than having it define its own version. Use it in some other places rather than a string of two octal values. Change-Id: Ic0f3b23ae0165c9824d89304d683f45bce31dced Reviewed-on: https://code.wireshark.org/review/11102 Reviewed-by: Guy Harris <guy@alum.mit.edu>
2014-12-28Replace ip6_to_str and ip6_guint8_to_str with address_to_str and tvb_ip_to_str.Michael Mann1-3/+1
Change-Id: I1d258923a7a63539ec8456d3e306bca5016a1e4b Reviewed-on: https://code.wireshark.org/review/6060 Petri-Dish: Michael Mann <mmann78@netscape.net> Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org> Reviewed-by: Pascal Quantin <pascal.quantin@gmail.com> Reviewed-by: Michael Mann <mmann78@netscape.net>
2014-12-26Replace ip_to_str with [ep_]address_to_str and tvb_ip_to_str.Michael Mann1-3/+1
Change-Id: I40d0c8253743183aecef252040b7dd6742ae5c71 Reviewed-on: https://code.wireshark.org/review/5934 Reviewed-by: Michael Mann <mmann78@netscape.net>
2014-12-23Deleting unnecessary #includes from dissectors.Martin Mathieson1-1/+0
Third batch (packet-icmpv6.c -> packet-mac-lte.c). Will look at cleaning up and committing script afterwards. Change-Id: Ib91e36ad200db01c3000605f6a7a21125b96a640 Reviewed-on: https://code.wireshark.org/review/6018 Petri-Dish: Martin Mathieson <martin.r.mathieson@googlemail.com> Reviewed-by: Martin Mathieson <martin.r.mathieson@googlemail.com>
2014-12-21Cleanup use of #includes in non-generated epan/dissector/*.cBill Meier1-2/+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-13Use ENC_BIG_ENDIAN when fetching FT_U?INT8 fields ...Bill Meier1-16/+16
(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-09-19Do encoding-arg changes (all benign)Bill Meier1-2/+2
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-07-06Add printf-format annotations, fix garbagePeter Wu1-4/+4
The WRETH dissector showed up some garbage in the column display. Upon further inspection, it turns out that the format string had a trailing percent sign which caused (unsigned)-1 to be returned by g_printf_string_upper_bound (in emem_strdup_vprintf). Then ep_alloc is called with (unsigned)-1 + 1 = 0 memory, no wonder that garbage shows up. ASAN could not even catch this error because EP is in charge of this. So, start adding G_GNUC_PRINTF annotations in each header that uses the "fmt" or "format" paramters (grepped + awk). This revealed some other errors. The NCP2222 dissector was missing a format string (not a security vuln though). Many dissectors used val_to_str with a constant (but empty) string, these have been replaced by val_to_str_const. ASN.1 dissectors were regenerated for this. Minor: the mate plugin used "%X" instead of "%p" for a pointer type. The ncp2222 dissector and wimax plugin gained modelines. Change-Id: I7f3f6a3136116f9b251719830a39a7b21646f622 Reviewed-on: https://code.wireshark.org/review/2881 Reviewed-by: Evan Huus <eapache@gmail.com>
2014-05-25Grab-bag of dead initializers and two actual bugs.Evan Huus1-10/+10
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-05-23LISP : error: declaration of 'address' shadows a global declaration ↵Alexis La Goutte1-4/+4
[-Werror=shadow] Change-Id: I3f490ec40ae3241e9836e0914d43424ff9565fb5 Reviewed-on: https://code.wireshark.org/review/1744 Reviewed-by: Alexis La Goutte <alexis.lagoutte@gmail.com>
2014-05-23Dissect Nonce Locator LCAFLorand Jakab1-1/+102
Change-Id: I23f05cf3a0bc43baac4c4c31f5ce0dc0dffcade1 Signed-off-by: Lorand Jakab <ljakab@ac.upc.edu> Reviewed-on: https://code.wireshark.org/review/1745 Reviewed-by: Alexis La Goutte <alexis.lagoutte@gmail.com>
2014-05-23Dissect AS Number LCAFLorand Jakab1-1/+99
Change-Id: I03c839a23c037a4d7da63d74e5407f0470301697 Signed-off-by: Lorand Jakab <ljakab@ac.upc.edu> Reviewed-on: https://code.wireshark.org/review/1742 Reviewed-by: Anders Broman <a.broman58@gmail.com>
2014-05-21Dissect Multicast Group Membership Information LCAFLorand Jakab1-4/+222
Bug: 10126 Change-Id: I81d643978d663d6905070d3cd7e751286c316fcd Signed-off-by: Lorand Jakab <ljakab@ac.upc.edu> Reviewed-on: https://code.wireshark.org/review/1716 Reviewed-by: Alexis La Goutte <alexis.lagoutte@gmail.com>
2014-05-21LISP: Add support for MAC address AFILorand Jakab1-11/+106
Change-Id: I105ba5a9623d482c912c94d2c21a1c02d869db56 Signed-off-by: Lorand Jakab <ljakab@ac.upc.edu> Reviewed-on: https://code.wireshark.org/review/1715 Reviewed-by: Alexis La Goutte <alexis.lagoutte@gmail.com>
2014-05-21Dissect Replication List Entries LCAFLorand Jakab1-0/+134
Bug: 10124 Change-Id: Ided4fff8259bbf1b5cb4b5209be6e3931ab09fe5 Signed-off-by: Lorand Jakab <ljakab@ac.upc.edu> Reviewed-on: https://code.wireshark.org/review/1711 Reviewed-by: Alexis La Goutte <alexis.lagoutte@gmail.com> Tested-by: Alexis La Goutte <alexis.lagoutte@gmail.com>
2014-05-21Add value to correct tree in Key/Value LCAFLorand Jakab1-4/+4
Change-Id: Icd4ae54bff25e30406c70739c6c799db2484255b Signed-off-by: Lorand Jakab <ljakab@ac.upc.edu> Reviewed-on: https://code.wireshark.org/review/1713 Reviewed-by: Alexis La Goutte <alexis.lagoutte@gmail.com>
2014-05-21Dissect Source/Destination 2-Tuple Lookups LCAFLorand Jakab1-0/+167
Change-Id: I0e8595ab5cf5385a7fda636a1804b0788f9eb869 Signed-off-by: Lorand Jakab <ljakab@ac.upc.edu> Reviewed-on: https://code.wireshark.org/review/1707 Reviewed-by: Michael Mann <mmann78@netscape.net>
2014-05-20Update ELP LCAF dissection to new draft revisionLorand Jakab1-8/+9
There was a change in the ELP LCAF packet format between draft-ietf-lisp-lcaf revisions -03 and -04 reversing the flags and AFI fields, to be more consistent with other LCAF types. http://tools.ietf.org/rfcdiff?difftype=--hwdiff&url2=draft-ietf-lisp-lcaf-04.txt Change-Id: I2c572050f413696f2d388969e7db24238783bd56 Signed-off-by: Lorand Jakab <ljakab@ac.upc.edu> Reviewed-on: https://code.wireshark.org/review/1704 Reviewed-by: Alexis La Goutte <alexis.lagoutte@gmail.com>
2014-05-20Dissect Key/Value Address Pair LCAFLorand Jakab1-2/+139
Change-Id: Ic1640a823816c5cd225c573147ff9b6b8c88879e Signed-off-by: Lorand Jakab <ljakab@ac.upc.edu> Reviewed-on: https://code.wireshark.org/review/1702 Reviewed-by: Alexis La Goutte <alexis.lagoutte@gmail.com> Reviewed-by: Anders Broman <a.broman58@gmail.com>
2014-04-28Fix issues reported by clang-analyzerLorand Jakab1-6/+2
Change-Id: Iefb52c674be99af167eef7b2eba249607c1dfefd Signed-off-by: Lorand Jakab <ljakab@ac.upc.edu> Reviewed-on: https://code.wireshark.org/review/1406 Reviewed-by: Anders Broman <a.broman58@gmail.com>
2014-04-26Dissect all details in NAT-T LCAF type...Lorand Jakab1-11/+55
... and remove last remaining proto_tree_add_text() calls! Change-Id: I22e5446a06c22ba1f30f342b21f7676641a7f2e7 Signed-off-by: Lorand Jakab <ljakab@ac.upc.edu> Reviewed-on: https://code.wireshark.org/review/1352 Reviewed-by: Michael Mann <mmann78@netscape.net>
2014-04-25Dissect all details in ELP LCAF type...Lorand Jakab1-12/+94
... and remove more of the remaining proto_tree_add_text() calls. Change-Id: I0286af7fd6953b9276c15b3e7ce7d80c1bd39e8a Signed-off-by: Lorand Jakab <ljakab@ac.upc.edu> Reviewed-on: https://code.wireshark.org/review/1350 Reviewed-by: Anders Broman <a.broman58@gmail.com>
2014-04-25Fix encodings (found by fix-encoding-args.pl)Lorand Jakab1-5/+5
Change-Id: I9bbdf61b6ac0b24dea4993f07b2608538ef220b2 Signed-off-by: Lorand Jakab <ljakab@ac.upc.edu> Reviewed-on: https://code.wireshark.org/review/1336 Reviewed-by: Anders Broman <a.broman58@gmail.com>
2014-04-24Improve Instance ID LCAF type handlingLorand Jakab1-19/+95
Change-Id: I66b1f4746b67ff88c56c4127647c4baa2d504a93 Signed-off-by: Lorand Jakab <ljakab@ac.upc.edu> Reviewed-on: https://code.wireshark.org/review/1325 Reviewed-by: Alexis La Goutte <alexis.lagoutte@gmail.com> Reviewed-by: Anders Broman <a.broman58@gmail.com>
2014-04-24Fix warning: declaration of 'address' shadows a global declaration.AndersBroman1-4/+4
Change-Id: I0be594aca0e8fac3c55492f6c168b0b8c13e63e5 Reviewed-on: https://code.wireshark.org/review/1324 Reviewed-by: Anders Broman <a.broman58@gmail.com>
2014-04-24Add support for Geo Coordinates LCAF typeLorand Jakab1-12/+253
Additionally, improve the way LCAF top-level tree item shows details from the information gathered later, including for AFI List LCAF types. For someone interested just in the summary from an LCAF type, this can save one or two clicks opening subrees. Change-Id: I40ea05ddf922bcb2a2a934f5e791f87133ca32cc Signed-off-by: Lorand Jakab <ljakab@ac.upc.edu> Reviewed-on: https://code.wireshark.org/review/1323 Reviewed-by: Anders Broman <a.broman58@gmail.com>
2014-04-24Fix Warning: Found soft-deprecated APIs in epan/dissectors/packet-lisp.c: ↵Alexis La Goutte1-4/+4
tvb_length and also fix warning found by fix-encodings-args Change-Id: I20193d9f2700e8ede439dcc848390ff7672239b3 Reviewed-on: https://code.wireshark.org/review/1318 Reviewed-by: Alexis La Goutte <alexis.lagoutte@gmail.com>
2014-04-24Improve LCAF handlingLorand Jakab1-55/+130
Also, remove some more proto_tree_add_text() occurrences. Change-Id: Ie46e16308b95f190229c22d06c5235ea3464394a Signed-off-by: Lorand Jakab <ljakab@ac.upc.edu> Reviewed-on: https://code.wireshark.org/review/1317 Reviewed-by: Anders Broman <a.broman58@gmail.com>
2014-04-23Fix LISP dissectior regressions introduced in 1.11Lorand Jakab1-63/+73
This patch fixes dissection of some fields and restores some of the output before the dissector was updated not to use proto_tree_add_text() calls. While at it improve the consistency in the code. Change-Id: Ic30e60de1382f4325bd75e814444205f2fc5a359 Signed-off-by: Lorand Jakab <ljakab@ac.upc.edu> Reviewed-on: https://code.wireshark.org/review/1283 Reviewed-by: Alexis La Goutte <alexis.lagoutte@gmail.com> Tested-by: Alexis La Goutte <alexis.lagoutte@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>
2013-12-14Fix warningsJakub Zawadzki1-0/+3
svn path=/trunk/; revision=54089
2013-11-09Include <epan/to_str.h> only when needed.Jakub Zawadzki1-0/+1
svn path=/trunk/; revision=53189
2013-09-15More wmem conversion (leaving uat related functions aside)Pascal Quantin1-1/+2
svn path=/trunk/; revision=52055
2013-09-09expert_add_info_format_text -> expert_add_info_formatMichael Mann1-12/+12
svn path=/trunk/; revision=51852
2013-09-02Batch of filterable expert info.Michael Mann1-12/+18
svn path=/trunk/; revision=51688
2013-09-01Remove expert_add_undecoded_item in favor of proto_tree_add_expert.Michael Mann1-2/+11
svn path=/trunk/; revision=51632
2013-08-07Enhance LISP Dissector (Mapping, Locator and Record type...)Alexis La Goutte1-29/+36
Convert proto_tree_add_text calls to proto_tree_add_item (the end of my original commit...) svn path=/trunk/; revision=51187