Commit Graph

75 Commits

Author SHA1 Message Date
Pascal Quantin 75dd452b24 Fix https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=7801 :
Ensure that the sub-type length is at least 2 (for sub-type and length fields).
Prevents an infinite loop when the length equals 0.

svn path=/trunk/; revision=45337
2012-10-06 10:01:59 +00:00
Michael Mann b89a06a3e1 replaced decode_boolean_bitfield calls with itemized filters
svn path=/trunk/; revision=45059
2012-09-23 00:12:14 +00:00
Jeff Morriss 2552c750e5 We always HAVE_CONFIG_H so don't bother checking whether we have it or not.
svn path=/trunk/; revision=45017
2012-09-20 02:03:38 +00:00
Jakub Zawadzki 5a8783f5b1 Initial commit to support yet another method of passing data between dissectors.
Add new parameter 'data' to heur_dissector_t and new_dissector_t, for now it's always NULL

svn path=/trunk/; revision=44860
2012-09-10 21:40:21 +00:00
Bill Meier 638d74d43f Use val_to_str_const() where appropriate;
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-08-10 22:55:02 +00:00
Jakub Zawadzki b18e880040 Update FSF address - part II.
svn path=/trunk/; revision=43538
2012-06-28 23:18:38 +00:00
Anders Broman b69547925f Get rid of a couple of warnings.
svn path=/trunk/; revision=43066
2012-06-04 13:52:46 +00:00
Anders Broman 9f3c1e5add the blurb for field /"PCF IP Address/" (/"a11.ext.ase.pcfip/") matches the field name in packet-3g-a11.c
svn path=/trunk/; revision=42215
2012-04-23 18:55:19 +00:00
Bill Meier 8819fa284c Replace hf[] "duplicate blurbs" by NULL;
Use consistent indentation (replace 4-space tabs by spaces);
Use consistent formatting style.

svn path=/trunk/; revision=42211
2012-04-23 16:23:57 +00:00
Alexis La Goutte ba4c8fdbc3 Fix some Dead Store (Dead assignement/Dead increment) Warning found by Clang
svn path=/trunk/; revision=41313
2012-03-02 11:08:49 +00:00
Chris Maynard 043f5f71d0 Fix Coverity CID 1342: UNUSED_VALUE
svn path=/trunk/; revision=40315
2011-12-28 17:02:43 +00:00
Anders Broman 35e767e28a Dissect Service Option Profile.
svn path=/trunk/; revision=40297
2011-12-27 10:15:00 +00:00
Anders Broman fdef15ed5e Revisit the spec, value is 16 bits.
svn path=/trunk/; revision=40289
2011-12-25 11:48:31 +00:00
Anders Broman c4a88586f3 Use packet-radius.c to dissect embedded AVP:s.
svn path=/trunk/; revision=40288
2011-12-25 11:25:39 +00:00
Anders Broman 295c3424c8 Use item lenght when dissecting Additional Session Info.
svn path=/trunk/; revision=40283
2011-12-22 22:31:26 +00:00
Chris Maynard 6705890aa1 Add some additional links to more up to date specfications.
svn path=/trunk/; revision=40254
2011-12-20 18:18:08 +00:00
Anders Broman ed8927d316 Fix GRE Key entry
svn path=/trunk/; revision=39729
2011-11-03 22:01:05 +00:00
Bill Meier 794757ae8f For proto_tree_add_item(..., proto_xxx, ...)use ENC_NA as the encoding arg.
Also: remove trailing whitespace for a number of files.

svn path=/trunk/; revision=39503
2011-10-21 02:10:19 +00:00
Bill Meier 126aa85393 Convert proto_tree_add_item() 'encoding' arg for field types FT_STRING, 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-15 18:46:26 +00:00
Bill Meier 67dda34221 Fix benign bugs wherein proto_tree_add_uint() was intended instead of proto_tree_add_item();
(Replaces changes made in SVN #39351).

svn path=/trunk/; revision=39361
2011-10-11 15:39:47 +00:00
Bill Meier ee395460d0 Fix benign bugs in some proto_tree_add_item() 'encoding' args;
svn path=/trunk/; revision=39351
2011-10-10 23:36:07 +00:00
Guy Harris 0bb00a2e64 RFC 4282 says the NAI is UTF-8.
svn path=/trunk/; revision=39042
2011-09-19 10:17:27 +00:00
Guy Harris 38b78a16a3 Some probably-erroneous TRUEs as the last argument to
proto_tree_add_item(); the items were one byte long, so the byte order
is irrelevant.

svn path=/trunk/; revision=39040
2011-09-19 09:55:36 +00:00
Guy Harris b117a8ba32 Use ENC_BIG_ENDIAN instead of FALSE in proto_tree_add_item() calls for
integral values.

For the Network Access Identifier, use ENC_UTF_8.

svn path=/trunk/; revision=39039
2011-09-19 09:52:37 +00:00
Guy Harris 9788778543 Add ett_a11_rqi_grantedqos to the list of ett_ values to be allocated.
Clean up indentation.

svn path=/trunk/; revision=37906
2011-07-05 21:11:58 +00:00
Stephen Fisher af0e8c25d0 Fix Unix compilation error...
packet-3g-a11.c:135: warning: 'hf_a11_fqi_granted_qos' defined but not used

... by removing definition


svn path=/trunk/; revision=37575
2011-06-06 19:49:31 +00:00
Anders Broman c56d401c35 On behalf of Ericsson - enhance A11 dissection.
svn path=/trunk/; revision=37573
2011-06-06 19:17:32 +00:00
Jeff Morriss 9d03ce44f4 Eliminate redundant blurbs
svn path=/trunk/; revision=37055
2011-05-11 01:06:37 +00:00
Gerald Combs a79777beaf Make sure we set a variable.
svn path=/trunk/; revision=37044
2011-05-10 16:05:14 +00:00
Anders Broman d88c7ff3f9 On behalf of Ericsson update the A11 dissector.
svn path=/trunk/; revision=37041
2011-05-10 15:20:09 +00:00
Chris Maynard 75deae992a Revert r24047. Fixes bug 5822.
svn path=/trunk/; revision=36642
2011-04-14 13:58:40 +00:00
Gerald Combs 1b0516a27e Fix various Visual C++ analysis warnings.
svn path=/trunk/; revision=35985
2011-02-17 19:43:16 +00:00
Guy Harris 4f7ae8bf3a For FT_{ABSOLUTE,RELATIVE}_TIME, make the rest of the encoding
orthogonal to the byte order.

This means that we can't just test for a non-zero encoding to determine
whether the format is big-endian or little-endian when we set the
field's endianness flag; instead, for the types where we accept any
non-zero value as meaning "litle-endian", map it to ENC_LITTLE_ENDIAN.

When we use ENC_TIME_NTP, OR in the byte order flag.  While we're at it,
in the dissectors that used ENC_TIME_NTP, update all the other encoding
items in proto_tree_add_item() calls to use the appropriate ENC_ value.

svn path=/trunk/; revision=35841
2011-02-07 08:18:12 +00:00
Jeff Morriss 8fc6e28b6a Add support for passing NTP times to proto_tree_add_item() by specifying
an encoding of ENC_TIME_NTP.

This increases the number of decimal places shown for NTP times (from 6 to 9),
so round the value to the nearest microsecond.  (I can't tell if NTP times are
ever more precise than a microsecond--this rounding is mainly to be closer to
the old behavior.)

Use proto_tree_add_item() for some NTP times.

svn path=/trunk/; revision=35840
2011-02-07 03:31:40 +00:00
Jeff Morriss a167206685 Introduce, and start using, tvb_ip_to_str() and tvb_ip6_to_str(). These
do the same as the non-tvb equivalents but take a TVB and an offset instead
of a pointer to an array of bytes.

Their purpose is to prevent (many) dissectors from doing:
ip_to_str(tvb_get_ptr(...)).

(About the names and the location: I like the names as they are but the names
imply that they should live in tvbuff.c.  That would make some sense but
I didn't want to pull to_str.h into tvbuff.c...)

svn path=/trunk/; revision=35519
2011-01-13 15:53:30 +00:00
Guy Harris a8bc4a0d13 Rename the routines that handle dissector tables with unsigned integer
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-12-20 05:35:29 +00:00
Bill Meier 7219ee2a49 Use val_to_str_ext() & friends to access sminmpec_values[];
Also: packet-nhrp.c: #include sminmpec.h not req'd;

svn path=/trunk/; revision=34143
2010-09-17 04:51:21 +00:00
Anders Broman aaa917be72 remove check_col
svn path=/trunk/; revision=32089
2010-03-03 13:52:17 +00:00
Stig Bjørlykke f14b274ec2 Removed unused assignments.
svn path=/trunk/; revision=30894
2009-11-09 14:35:27 +00:00
Bill Meier ce75ae1292 Upon 2nd thought: revert changes I made to remove 'if(checkcol(...)' around col_add_fstr(...)
svn path=/trunk/; revision=30134
2009-09-25 01:22:08 +00:00
Bill Meier 95bf560727 Misc cleanup;
- Remove no longer needed usage of check_col();
- Add some defensive coding;
- Change a few guints to gints;
- Add parentheses to a few expressions;
- Use consistent indentation.

svn path=/trunk/; revision=29655
2009-09-01 17:17:14 +00:00
Kovarththanan Rajaratnam 0a5b014cec Don't guard col_clear with col_check
svn path=/trunk/; revision=29344
2009-08-09 07:36:13 +00:00
Kovarththanan Rajaratnam e971354a54 Don't guard col_set_str (COL_PROTOCOL) with col_check
svn path=/trunk/; revision=29340
2009-08-09 06:26:46 +00:00
Stig Bjørlykke b228488bc0 From Kovarththanan Rajaratnam via bug 3548:
(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-06-18 21:30:42 +00:00
Guy Harris e98e65977f Get rid of uses of size_t; they're not necessary, and it causes a pile
of 64-bit-to-32-bit conversion warnings in LLP64 environments such as
Win64.

svn path=/trunk/; revision=27781
2009-03-18 20:41:45 +00:00
Jaap Keuter d6758efd12 From Michael Lum:
Added support the the Capabilities Information and Capabilities Information Ack 
messages along with the MEID attribute.

svn path=/trunk/; revision=27207
2009-01-10 11:21:36 +00:00
Bill Meier a8f30cbca1 Fix some typos and spelling (mostly in text strings)
svn path=/trunk/; revision=27037
2008-12-17 17:23:37 +00:00
Bill Meier e0501b75d3 Remove unnecessary #includes
svn path=/trunk/; revision=26481
2008-10-16 14:34:20 +00:00
Bill Meier be5a1aa111 Move a buffer from the stack & do some minor cleanup
svn path=/trunk/; revision=26073
2008-08-25 16:42:09 +00:00
Guy Harris ef86058bfe For a character string, use an array of char, not an array of guint8
(the characters are all digits), and, to point to it, use a pointer to
char rather than a pointer to guint8.

svn path=/trunk/; revision=25394
2008-05-29 23:53:19 +00:00