Commit Graph

66 Commits

Author SHA1 Message Date
Bill Meier 4c46725c2c Fix vi "modeline" so it works;
See https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=5748

svn path=/trunk/; revision=39074
2011-09-21 16:28:53 +00:00
Jeff Morriss 339136d1d0 Based on patch from Denis Ovsienko via
https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=6244 :

Fix typo: s/unkown/unknown/

svn path=/trunk/; revision=38561
2011-08-16 13:16:33 +00:00
Bill Meier b3c8baf2d5 Fix gcc 4.6 "set but not used [-Wunused-but-set-variable]" warnings
svn path=/trunk/; revision=37999
2011-07-13 18:42:40 +00:00
Chris Maynard c23afc424e As noted by Jaap Keuter on -dev, be sure to use message_size instead of
header->message_size for a correct host endianness comparison.


svn path=/trunk/; revision=37957
2011-07-11 00:17:08 +00:00
Stig Bjørlykke 8443bbbf75 Replace all strerror() with g_strerror().
Remove our local strerror implementation.
Mark strerror as locale unsafe API.

This fixes bug 5715.

svn path=/trunk/; revision=37812
2011-06-28 09:00:11 +00:00
Guy Harris 1718ab7691 If we get an unknown reply status, don't print a g_warning message -
just put the reply body, if any, into the protocol tree as a blob.  The
protocol tree will note that it's an unknown status.

svn path=/trunk/; revision=35414
2011-01-07 00:26:57 +00:00
Jeff Morriss 99bc06ceff Make some (preference) variables static.
svn path=/trunk/; revision=35134
2010-12-06 19:48:05 +00:00
Bill Meier af3d0b2bde Use value_string_ext fcns to access a value_string array.
svn path=/trunk/; revision=34726
2010-10-30 18:27:52 +00:00
Jeff Morriss 47e2d75820 Move some code (including the optional objects) into libwsutil
svn path=/trunk/; revision=33012
2010-05-28 20:19:55 +00:00
Jeff Morriss 729de1a635 As suggested in http://www.wireshark.org/lists/wireshark-dev/200809/msg00075.html
(as referenced in https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=2907 ) and
https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=3411 :

Write a new convenience routine for finding a conversation and, if it is not
found, create it.  The frame number and addresses are taken from pinfo (as is
the common case).

Use this function in a bunch of dissectors.

svn path=/trunk/; revision=32790
2010-05-13 18:28:34 +00:00
Bill Meier 381bfd9c01 Various fixes:
1. Make message flags field filterable;
2. Fix various (relatively small) memory leaks mostly by using "seasonal"
   memory (instead of using g_malloc/g_new) so that memory is properly freed
   each time a capture file is (re)read.
3. Add some code so that use of a nested CLEANUP_PUSH could be removed.
   (The nested CLEANUP_PUSH was causing a gcc -Wshadow warning).
4. Use ep_alloc'd memory in one case to simplify code.
5. Clean up some indentation.

svn path=/trunk/; revision=31758
2010-02-01 18:16:25 +00:00
Bill Meier 2241bbf094 Create "decompressed Content" tab in hex bytes pane only if decompression actually done.
This is a revision of  SVN #29086 which caused the 
"decompressed Content" tab in the hex bytes pane to always be displayed.

svn path=/trunk/; revision=31755
2010-02-01 16:18:18 +00:00
Bill Meier 1c11b9571e Use consistent indentation; Reformat a few hf[] array entries.
svn path=/trunk/; revision=31553
2010-01-18 18:00:23 +00:00
Anders Broman 1ad55d8c02 From Steve Osselton:
Fix for MIOP dissector for GIOP < 1.2.
https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=3892

svn path=/trunk/; revision=29805
2009-09-08 18:46:47 +00:00
Kovarththanan Rajaratnam 6444abbf7e Avoid 'cast to pointer from integer of different size'
svn path=/trunk/; revision=29511
2009-08-23 05:20:30 +00:00
Balint Reczey 035231b534 From Frederic Peters (made endian-aware by me):
fixed segfault with some GIOP packets

svn path=/trunk/; revision=29509
2009-08-22 22:46:41 +00:00
Kovarththanan Rajaratnam 8b515e9340 Switch a bunch of dissectors over to using tvb_new_subset_remaining()
svn path=/trunk/; revision=29446
2009-08-16 12:36:22 +00:00
Anders Broman 72d8e6ad54 From Steve Osselton:
GIOP dissector update for MIOP.
https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=3847

svn path=/trunk/; revision=29369
2009-08-10 19:53:12 +00:00
Kovarththanan Rajaratnam 6110a96f68 Don't guard col_set_str (COL_INFO/COL_PROTOCOL) with col_check
svn path=/trunk/; revision=29345
2009-08-09 07:59:51 +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
Gerald Combs e3be7b8b25 Check to see if tvb_child_uncompress returns NULL. Fixes bug 3705.
svn path=/trunk/; revision=29086
2009-07-13 20:12:53 +00:00
Stig Bjørlykke 0437f102c3 From Kovarththanan Rajaratnam:
More FT_XXX cleanup.

svn path=/trunk/; revision=28971
2009-07-07 09:02:59 +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
Anders Broman 5f538e901d Apply some of the patches from:
http://wiki.wireshark.org/Development/Optimization

svn path=/trunk/; revision=28362
2009-05-14 19:11:43 +00:00
Bill Meier 79a1441582 FT_BOOLEAN fields w/o bitmasks really should use BASE_NONE (not BASE_DEC,...).
svn path=/trunk/; revision=28317
2009-05-08 20:35:57 +00:00
Anders Broman 8611ec5f5e More size_t casts.
svn path=/trunk/; revision=27879
2009-03-29 12:07:30 +00:00
Anders Broman c1e511b92e From Alvaro Vega Garcia:
Support ZIOP and MIOP (specialized CORBA protocols).
https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=3238

svn path=/trunk/; revision=27589
2009-03-03 19:51:08 +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 a042c3aedd Small changes related to proto_register & proto_reg_handoff
- Move find_dissector_table(...) to proto_reg_handoff;
 - Use dissactor_add_handle instead of registering the dissector to tcp port 0;
 - Use find_dissector when appropriate.


svn path=/trunk/; revision=26767
2008-11-13 01:31:57 +00:00
Stig Bjørlykke bd08ae7ee6 Fix some "format not a string literal and no format arguments" warnings.
svn path=/trunk/; revision=26647
2008-10-31 15:11:57 +00:00
Bill Meier 51a5c82e9d Fix bug #3017: remove un-necessary code (and thus fix a small memory leak)
svn path=/trunk/; revision=26626
2008-10-30 19:41:27 +00:00
Anders Broman 8e5509273f "Response flags" in GIOP Request is misinterpreted
Fixes https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=2800

svn path=/trunk/; revision=26177
2008-09-11 19:33:07 +00:00
Jeff Morriss a5cee04fad Move the file utility functions from wiretap to libwsutil so that
libwireshark (and the plugins using those functions) do not depend on
wiretap on Windows.

While doing that, rename the eth_* functions to ws_*.

svn path=/trunk/; revision=25354
2008-05-22 15:46:27 +00:00
Anders Broman 63c5c71cf8 Remove:
#ifdef NEED_G_ASCII_STRCASECMP_H
#include "g_ascii_strcasecmp.h"
#endif

svn path=/trunk/; revision=24859
2008-04-09 05:36:08 +00:00
Anders Broman 1c5dddbd68 Unkomment the now fixed value string...
svn path=/trunk/; revision=24412
2008-02-21 23:08:19 +00:00
Guy Harris 63c7c6d476 Put back the use of g_ascii_strcasecmp(), so we don't get rudely
surprised by, for example, "i" not comparing equal to "I" in Turkish
locales.

Make gMessageType local - it's not used as a global variable.  Also,
make it a pointer to const, so that we don't have to cast away the
constness.

dissect_giop_fragment() doesn't use the "header" argument, so get rid of
it.

Clean up indentation a bit.

The first element of a value_string is the value, and the second
argument is the string; fix up the initialization of the table of code
set values.

Fix a proto_tree_add_text() call to match the format and the arguments.

svn path=/trunk/; revision=24411
2008-02-21 22:11:08 +00:00
Anders Broman 39f12ecc1d From Wolf Neumann:
GIOP reassembly fails when first packet of a PDU is received Out-of-Order

http://bugs.wireshark.org/bugzilla/show_bug.cgi?id=1453

The patch changed to use value_string but not all values included in the current value_string.

svn path=/trunk/; revision=24410
2008-02-21 20:45:09 +00:00
Guy Harris 9c89cdaaa3 strcasecmp(), strncasecmp(), g_strcasecmp(), and g_strncasecmp() delenda
est.  Use g_ascii_strcasecmp() and g_ascii_strncasecmp(), and supply our
own versions if they're missing from GLib (as is the case with GLib
1.x).

In the code to build the list of named fields for Diameter, don't use
g_strdown(); do our own g_ascii_-style upper-case to lower-case mapping
in the hash function and use g_ascii_strcasecmp() in the compare
function.

We do this because there is no guarantee that toupper(), tolower(), and
functions that use them will, for example, map between "I" and "i" in
all locales; in Turkish locales, for example, there are, in both
upper case and lower case, versions of "i" with and without a dot, and
the upper-case version of "i" is "I"-with-a-dot and the lower-case
version of "I" is "i"-without-a-dot.  This causes strings that should
match not to match.

This finishes fixing bug 2010 - an earlier checkin prevented the crash
(as there are other ways to produce the same crash, e.g. a bogus
dictionary.xml file), but didn't fix the case-insensitive string matching.

svn path=/trunk/; revision=23623
2007-11-27 18:52:51 +00:00
Anders Broman a07530ab2b From Steve Osselton:
The GIOP Fragment message type was added as of GIOP 1.1. However the Fragment
message header (containing a request id) was only added as of GIOP 1.2. The
GIOP Fragment dissector incorrectly attempts to process the request id for a
version 1.1 request.

To fix add a version check to the dissect_giop_fragment function in
packet-giop.c:

svn path=/trunk/; revision=23289
2007-10-27 15:38:22 +00:00
Anders Broman 1950ffc214 Apply the small performance enhancment patches for:
- if offset is 0, tvb_length is the same as tvb_length_remaining, just faster.
Replace 
- col_append_fstr() with faster  col_append_str() 
- col_add_str() with col_set_str()
when it's safe

svn path=/trunk/; revision=23252
2007-10-23 05:50:00 +00:00
Jeff Morriss 853e791444 Change more fopen() to eth_fopen() to finish fixing bug 1827:
http://bugs.wireshark.org/bugzilla/show_bug.cgi?id=1827

Update README.developer to tell developers not to use fopen() and friends
directly.

svn path=/trunk/; revision=23206
2007-10-16 15:43:18 +00:00
Jaap Keuter 647446dadf Fix for bug 1541. Adjust offset for long longs by 8, not by 4.
svn path=/trunk/; revision=21496
2007-04-22 10:29:47 +00:00
Sebastien Tandel 68ad2f4b9b fix MacOSX gcc-3.3 warnings about unused tfs/value_string variables
most have been tagged unused (few have been deleted if dissector has not been
modified since a long time)

move packet-ssl-utils.c to DISSECTOR_SRC


svn path=/trunk/; revision=21431
2007-04-14 14:01:53 +00:00
Jeff Morriss 109388d263 Clean up some more warnings: unused variables, unitialized variables, wrong format (%ld instead of %d) in packet-sccp.c
svn path=/trunk/; revision=21167
2007-03-24 13:46:41 +00:00
Jaap Keuter 79b23d4856 Fix for bug 1272.
Check length remaining before aligning.

svn path=/trunk/; revision=20198
2006-12-22 14:48:51 +00:00
Ronnie Sahlberg 2d1bb39121 change the signature for the get_pdu_len() function pointer passed to tcp_dissect_pdus() to also include a packet_info pointer.
there are many reasons why some protocols actually need to be able to access the pinfo structure while determining the pdu size



svn path=/trunk/; revision=19751
2006-10-31 09:29:07 +00:00
Ronnie Sahlberg feab79e328 change a whole bunch of ethereal into wireshark
svn path=/trunk/; revision=18196
2006-05-21 04:49:01 +00:00
Anders Broman a70b907c4a Handle 64bits signed/unsigned integers and get rid of some extra LF:s.
svn path=/trunk/; revision=17911
2006-04-19 18:59:29 +00:00
Jaap Keuter 96d739b790 From W. Borgert:
Currently, the filename IOR.txt is hardcoded into ethereal.
The patch allows the user to change it. Thanks for applying!

svn path=/trunk/; revision=17894
2006-04-18 10:04:18 +00:00
Anders Broman 1c26abfe29 From W. Borgert:
the attached patch enables the explicit GIOP dissection. This fixes erronous decoding, if methods of two different CORBA interfaces have the same name, which happens frequently.

The generated GIOP plugins (CosEvent, CosNaming, Parlay, Tango) need to be re-generated to make use of the fix.

svn path=/trunk/; revision=17880
2006-04-16 23:16:46 +00:00