aboutsummaryrefslogtreecommitdiffstats
path: root/epan/dissectors/packet-h450.c
AgeCommit message (Collapse)AuthorFilesLines
2024-08-07Dissectors: Include what you use.Anders Broman1-0/+1
2024-07-05epan: Convert ASN.1 dissectors to C99Stig Bjørlykke1-11/+11
Ping #19116
2024-07-01ASN protocols: update APIs and generated code for boolMartin Mathieson1-129/+129
2024-04-14Switch some GLib-isms in asn2wrs.py to their C99 equivalentsGerald Combs1-134/+134
Update convert-glib-types.py to exclude quoted TRUE and FALSE strings. Regenerate our ASN.1 dissectors. Ping #19116
2024-03-14Tools: Add a quiet option to asn2wrsGerald Combs1-1/+1
Duplicate type and field names don't seem to be a big problem, so add a "-q" option to asn2wrs which suppresses those warnings. Use it in the "asn1" CMake target.
2023-11-02asn2wrs: Update to not initialize static proto valuesStig Bjørlykke1-488/+488
2023-08-08Convert asn2ws to generate C99 typesAnders Broman1-1/+1
2023-05-18epan: Add STRING_CASE_[IN]SENSITIVE for dissector tablesJohn Thacker1-3/+3
The last parameter of register_dissector_table() indicates the base for integer tables, indicates case sensitivity for string tables, and is ignored for other tables (FT_NONE, FT_GUID). It can be a little difficult to remember what the code is doing when reading it, and which of 0 and 1 is sensitive and which is insensitive (0 is sensitive, the default). Add STRING_CASE_SENSITIVE and STRING_CASE_INSENSITIVE. Check in tools/fix-encoding-args.pl for STRING-like tables that use BASE_NONE, TRUE, or FALSE, and convert them to the new values.
2023-05-09Use `register_dissector()` in ASN.1 dissectorsDavid Perry1-6/+8
2023-04-29PER, asn2wrs: Handle VAL_PTR for known multiplier string typesJohn Thacker1-3/+6
Have the single octet known multiplier string types (IA5String, NumericString, PrintableString, VisibleString, the yet unsupported ISO646String) support returning the tvb containing the item in a VAL_PTR if they don't have a permitted alphabet. We currently handle a VAL_PTR of one of those types if they do have a permitted alphabet. Note that this also applies to UTCTime and GeneralizedTime, since under the hood we treat those as VisibleStrings anyway. It does *not* apply to BMPString (UCS2) nor UniversalSTring (UCS4), even though those are known multiplier string types. This should fix handling of ENBname and MMEname in S1AP as well. Related to #19036
2023-02-20Check that value_string values fit into field widthMartin Mathieson1-1/+1
2022-11-30asn2wrs: disable template line directive by defaultJoakim Karlsson1-57/+0
Same as with !8955, To debug with line directive build with -DENABLE_DEBUG_A2W=ON flag
2022-11-30asn2wrs: disable line directive by defaultJoakim Karlsson1-5/+1
To debug with line directive build with -DENABLE_DEBUG_A2W=ON flag
2019-04-04epan: Convert our PROTO_ITEM_ macros to inline functions.Gerald Combs1-4/+4
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>
2018-02-18ASN.1: update auto generated dissectorsPascal Quantin1-9/+9
Change-Id: Ic73e72b3d2e7590eaed07f6eb30f74f4303e7a65 Reviewed-on: https://code.wireshark.org/review/25880 Petri-Dish: Pascal Quantin <pascal.quantin@gmail.com> Tested-by: Petri Dish Buildbot Reviewed-by: Pascal Quantin <pascal.quantin@gmail.com>
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-08-31Don't do any Decode As stuff for dissector tables not used with Decode As.Guy Harris1-6/+6
Have all dissector tables have a "supports Decode As" flag, which defaults to FALSE, and which is set to TRUE if a register_decode_as() refers to it. When adding a dissector to a dissector table with a given key, only add it for Decode As if the dissector table supports it. For non-FT_STRING dissector tables, always check for multiple entries for the same protocol with different dissectors, and report an error if we found them. This means there's no need for the creator of a dissector table to specify whether duplicates of that sort should be allowed - we always do the check when registering something for "Decode As" (in a non-FT_STRING dissector table), and just don't bother registering anything for "Decode As" if the dissector table doesn't support "Decode As", so there's no check done for those dissector tables. Change-Id: I4a1fdea3bddc2af27a65cfbca23edc99b26c0eed Reviewed-on: https://code.wireshark.org/review/17402 Petri-Dish: Guy Harris <guy@alum.mit.edu> Reviewed-by: Guy Harris <guy@alum.mit.edu>
2016-03-17Associate dissector tables and heuristic subdissector lists with a protocol.Michael Mann1-6/+6
This will make it easier to determine protocol dependencies. Some LLC OUI dissector tables didn't have an associated protocol, so they were left without one (-1 used) Change-Id: I6339f16476510ef3f393d6fb5d8946419bfb4b7d Reviewed-on: https://code.wireshark.org/review/14446 Reviewed-by: Michael Mann <mmann78@netscape.net>
2016-03-13Move /asn1 to /epan/dissectorsJoão Valverde1-22/+22
Change-Id: I1208fe3c2ba428995526f561e8f792b8d871e9a9 Reviewed-on: https://code.wireshark.org/review/14388 Reviewed-by: Pascal Quantin <pascal.quantin@gmail.com> Petri-Dish: Pascal Quantin <pascal.quantin@gmail.com> Reviewed-by: João Valverde <j@v6e.pt>
2016-01-14Rename new_dissector_t to dissector_t.Guy Harris1-3/+3
There are no longer any "old" dissectors, so "new_" is redundant. Change-Id: I5fee51228c2a8562166f5991e1f30c2c697e45c8 Reviewed-on: https://code.wireshark.org/review/13273 Reviewed-by: Guy Harris <guy@alum.mit.edu>
2015-12-09"new" dissector API -> dissector API for ASN.1 dissectors.Michael Mann1-4/+4
Change-Id: I7b794cba2feda2cae40411e2b1cb9fb091d08220 Reviewed-on: https://code.wireshark.org/review/12480 Reviewed-by: Michael Mann <mmann78@netscape.net>
2015-11-04Don't allow multiple registrations of a protocol in dissector tables.Michael Mann1-6/+6
The target here is the Decode As dialog where protocols have multiple registrations into a dissector table and that shows up as multiple entries in the Decode As dialog list with the same name so users are unsure which "dissector" they are choosing. The "default" behavior (done in this commit) is to not allow duplicates for a dissector table, whether its part of Decode As or not. It's just ENFORCED for Decode As. Bug: 3949 Change-Id: Ibe14fa61aaeca0881f9cc39b78799e314b5e8127 Reviewed-on: https://code.wireshark.org/review/11405 Petri-Dish: Michael Mann <mmann78@netscape.net> Reviewed-by: Michael Mann <mmann78@netscape.net>
2015-04-08Replace deprecated tvb_length with tvb_reported_length.AndersBroman1-9/+9
Change-Id: I45d2ae41da823c50ba383a8e2aaec570ee3ad842 Reviewed-on: https://code.wireshark.org/review/7979 Reviewed-by: Anders Broman <a.broman58@gmail.com>
2014-12-23asn1 generated dissectors: cleanup #include usageBill Meier1-10/+9
Change-Id: I36b2731d67f9345d2fd0c23800bba7d2be94c387 Reviewed-on: https://code.wireshark.org/review/6008 Reviewed-by: Bill Meier <wmeier@newsguy.com>
2014-08-09Eliminate (almost all) proto_tree_add_text calls from ASN.1 dissectors.Michael Mann1-12/+26
This mostly involved adding expert info capabilities to many of the dissectors so that they could correctly flag error conditions. Only remaining proto_tree_add_text calls are in H248.cnf, which has a convoluted way of using hf_ data to make its tree. Change-Id: I6412150c2ec1977d7fa38f3f0ed416680bdfb141 Reviewed-on: https://code.wireshark.org/review/3500 Petri-Dish: Michael Mann <mmann78@netscape.net> Reviewed-by: Michael Mann <mmann78@netscape.net>
2014-06-19Revert "Fixup: tvb_* -> tvb_captured"Michael Mann1-9/+9
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-9/+9
Change-Id: I9209c1271967405c34c1b6fa43e1726a4d3a5a3f Reviewed-on: https://code.wireshark.org/review/2377 Reviewed-by: Anders Broman <a.broman58@gmail.com>
2014-02-18Remove $Id$ from the ASN.1 dissectors and regenerate them.Jeff Morriss1-13/+11
Change-Id: Ie476c6f82f318188b41ed922b92c6fec119ea954 Reviewed-on: https://code.wireshark.org/review/244 Reviewed-by: Jeff Morriss <jeff.morriss.ws@gmail.com> Tested-by: Jeff Morriss <jeff.morriss.ws@gmail.com>
2013-12-12Reject the packet if data is NULL. Remove _U_ where data is actually used. ↵Chris Maynard1-14/+23
For now, leave the DISSECTOR_ASSERT's since both get_rose_ctx() and get_asn1_ctx() also check signatures. (Arguably it's the responsibility of the dissector passing this information to set the signature correctly so if there's an invalid signature, the bug is with the calling dissector and not with the one receiving the invalid signature.) svn path=/trunk/; revision=53964
2013-12-09- Forward declaration of register functions.Anders Broman1-9/+13
svn path=/trunk/; revision=53876
2013-11-03Have rose_ctx_t passed into subdissectors instead of using pinfo->private_data.Michael Mann1-9/+9
svn path=/trunk/; revision=53061
2013-05-27Postfix FT_NONE fields with "_element" string to reduce number of ↵Pascal Quantin1-153/+153
incompatible filters in ASN.1 dissectors https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=2402 svn path=/trunk/; revision=49599
2013-04-11Update the ASN.1 based dissectors following the changes done in r48812Pascal Quantin1-2/+2
svn path=/trunk/; revision=48820
2013-03-29Rename value string (and similar) functions to use a consistent pattern. ThisEvan Huus1-3/+3
was done using textual search+replace, not anything syntax-aware, so presumably it got most comments as well (except where there were typos). Use a consistent coding style, and make proper use of the WS_DLL_* defines. Group the functions appropriately in the header. I ended up getting rid of most of the explanatory comments since many of them duplicated what was in the value_string.c file (and were out of sync with the recent updates I made to those in r48633). Presumably most of the comments should be in the .h file not the .c file, but there's enough churn ahead that it's not worth fixing yet. Part of https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=8467 svn path=/trunk/; revision=48634
2013-02-26Fix spelling/typos found using a list of commonly misspelled words.Bill Meier1-23/+23
The misspellings were mostly in comments but some were in text strings visible to the user. svn path=/trunk/; revision=47899
2012-09-24Regenerate asn.1 dissectors.Jakub Zawadzki1-9/+9
svn path=/trunk/; revision=45110
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-10Regenerate all asn.1 dissectors.Jakub Zawadzki1-90/+90
svn path=/trunk/; revision=44861
2012-06-28Update Free Software Foundation address.Jakub Zawadzki1-1/+1
(COPYING will be updated in next commit) svn path=/trunk/; revision=43536
2012-05-07Get rid of remaining Booleans-as-encoding-arguments inGuy Harris1-1/+1
proto_tree_add_item() calls. svn path=/trunk/; revision=42489
2011-10-15Update generated ASN1 *.[hc] files after recent work done by Jeff Morriss;Bill Meier1-1/+1
The only change in each file is in a comment showing the asn2wrs cmd used to build that file. svn path=/trunk/; revision=39427
2011-05-13Regenerate ASN.1 dissectors to update the #line directive.Stig Bjørlykke1-21/+21
svn path=/trunk/; revision=37118
2010-12-20Rename the routines that handle dissector tables with unsigned integerGuy Harris1-3/+3
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-05-11Add a little more code to avoid not-very-useful blurbs:Jeff Morriss1-35/+35
- Change spaces in the name to underscores before comparing it to the blurb. - Check if the type simply as T_ prepended to the name. - Don't put in a blurb of "NULL". and regenerate the dissectors. svn path=/trunk/; revision=32748
2010-05-11Regenerate a few of the ASN.1 dissectorsJeff Morriss1-348/+348
svn path=/trunk/; revision=32742
2010-04-07#include <string.h> and/or #include <stdio.h> not needed.Bill Meier1-10/+9
svn path=/trunk/; revision=32417
2010-04-06#include <stdio.h> not needed.Bill Meier1-10/+9
svn path=/trunk/; revision=32405
2009-11-22Handle lenght restriction extension of restricted strings.Anders Broman1-6/+6
Fixes https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=4251 svn path=/trunk/; revision=31047
2009-06-26Re-generate asn1 dissectors after hf_register_info cleanup.Stig Bjørlykke1-7/+7
svn path=/trunk/; revision=28848
2009-06-18From Kovarththanan Rajaratnam via bug 3548:Stig Bjørlykke1-14/+14
(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