Commit Graph

4734 Commits

Author SHA1 Message Date
Guy Harris 45dc78bd7d Support for BSD Compress, MVRCA, and Deflate compression options in
CCP, from Motonori Shindo.

svn path=/trunk/; revision=4530
2002-01-11 21:37:10 +00:00
Gilbert Ramirez 41f20b3449 From Guy Harris, after checking his Python code.
Some compilers don't mind zero-length arrays, but MSVC++ 6.0 does.

"ncp2222.py" was generating a zero-length "ett[]" array.  Make it generate
the "ett[]" array and the call to "proto_register_subtree_array()"
only if the list of items for "ett[]" is non-empty CVS:

svn path=/trunk/; revision=4529
2002-01-11 14:33:04 +00:00
Guy Harris 51cb58401f "void" values cannot be returned, even by a "void" function.
The "downstream" flag is a Boolean; treat it as such.

svn path=/trunk/; revision=4528
2002-01-11 11:07:21 +00:00
Guy Harris e8297af92b Declare "capture()" appropriately.
svn path=/trunk/; revision=4527
2002-01-11 11:04:03 +00:00
Guy Harris 4b6951cd89 Put in a comment giving various Internet Draft names for ICMPv6 stuff we
handle.

svn path=/trunk/; revision=4526
2002-01-11 09:19:54 +00:00
Guy Harris 13b58598b3 Fix some more signed vs. unsigned issues.
svn path=/trunk/; revision=4525
2002-01-11 09:12:26 +00:00
Guy Harris dce2c4c283 Update the man page to reflect user interface changes.
svn path=/trunk/; revision=4524
2002-01-11 09:02:15 +00:00
Guy Harris 1aadf9cfc2 Label the window popped up by "Capture->Start" "Capture Options", not
"Capture Preferences", to avoid confusion with the "Capture" item in the
"Preferences" dialog (which sets the initial default values for the
"Capture Options" dialog).

svn path=/trunk/; revision=4523
2002-01-11 08:55:02 +00:00
Guy Harris 30a043931e From Jirka Novak:
Support for generating filter expressions based on packet list
	    column values
	Support for adding filter expressions generated from column or
	    protocol tree field values to the current expression rather
	    than replacing the current expression

svn path=/trunk/; revision=4522
2002-01-11 08:21:02 +00:00
Guy Harris feb5791d6a Have a routine to create a scrolled window, set its vertical scrollbar
preference, and add it to the list of scrolled windows; call that
routine to create scrolled windows, rather than creating it and calling
other routines to do the other two operations.

As "set_scrollbar_placement_all()" and "set_ctree_styles_all()" always
set the styles to match the user's preference, don't have them take an
argument, have them just use the user's preference settings.

Get rid of unnecessary includes of "prefs_dlg.h", replacing them with
includes of "prefs.h" if necessary.  Don't have "prefs_dlg.h" include
"prefs.h" - its sole purpose is to declare routines defined in
"prefs_dlg.c" - and add any additional includes of "prefs.h" this
requires.

Get rid of unnecessary includes of "prefs.h" and "gtkglobals.h".

Fix up white space.

svn path=/trunk/; revision=4521
2002-01-11 07:40:32 +00:00
Guy Harris e592fa4a6b Have routines to create GtkCTrees, set their line and expander style
based on the user's UI preferences, and add them to a list of GtkCTrees.
Use those routines to create all GtkCTrees.

Have a routine to update the preferences for all of those GtkCTrees.
Call that routine whenever the preferences change.

Label the line and expander style preferences as "Tree line style" and
"Tree expander style", as they no longer apply only to protocol trees.

Move the routines to maintain a list of scrolled windows, and to update
scrollbar placement for scrolled windows, to "ui_util.c".

svn path=/trunk/; revision=4520
2002-01-11 06:43:18 +00:00
Guy Harris fc53c2b7b3 Oh, what the heck, write out FDDI and bit-swapped FDDI as the same type
in Sniffer Classic files; there's nothing we can do about those
platforms that bit-swap FDDI addresses before handing them to DLPI or
whatever, so we'll just let people live with wrong FDDI addresses (or
maybe someday put in code to bit-swap them before writing them out to
the capture file).

svn path=/trunk/; revision=4519
2002-01-11 02:51:31 +00:00
Guy Harris a4d560eb5b From Nagarjuna Venna: only display the reason in BYE RTCP packets if
it's present.

svn path=/trunk/; revision=4518
2002-01-10 22:21:14 +00:00
Guy Harris 43caedd1f9 From Irfan Khan: don't use bitfields.
svn path=/trunk/; revision=4517
2002-01-10 22:07:49 +00:00
Guy Harris 381c21783e As per a comment from Ronnie Sahlberg, display TCP sequence numbers in
the list of segments in a desegmented PDU as unsigned, rather than
signed.

Fix some other displays of unsigned quantities with "%d" while we're at
it.

svn path=/trunk/; revision=4516
2002-01-10 11:27:57 +00:00
Guy Harris 65b96f652d Fix more unsigned items to be displayed with "%u" rather than "%d", as
per Martti Kuparinen's comments.

svn path=/trunk/; revision=4515
2002-01-10 11:21:21 +00:00
Guy Harris b3f81eb30c Separate the promiscuous mode, "Update list of packets in real time",
and "Automatic scrolling in live capture" options from the preference
settings for them, so that the preference settings affect the initial
values of those options, but changing those values in a capture don't
affect the preferences, and don't automatically get saved when you save
the preferences.

If we're building without libpcap, don't have an "Automatic scrolling in
live capture" option anywhere.

svn path=/trunk/; revision=4514
2002-01-10 11:05:50 +00:00
Guy Harris d663cdb4a1 Fix some problems with building Ethereal/Tethereal without libpcap.
Get rid of a #include I'd #if 0'ed out.

svn path=/trunk/; revision=4513
2002-01-10 09:51:23 +00:00
Guy Harris 60c8a87e44 The filetime is an unsigned quantity, so display it with %u, as per
Martti Kuparinen's comment.

svn path=/trunk/; revision=4512
2002-01-10 09:49:35 +00:00
Guy Harris 09b62420e7 Don't break out of a loop from inside TRY clause; set a flag and break
after the ENDTRY.

svn path=/trunk/; revision=4511
2002-01-10 08:06:25 +00:00
Guy Harris 9357047df5 Add a preferences page for capture preferences, so that the user can
directly edit the capture preferences, rather than only being able to
set them implicitly from the values for the most recent capture.

Add a preferences item for the interface on which to capture.

Get rid of some unused variables.

svn path=/trunk/; revision=4510
2002-01-10 07:43:39 +00:00
Gilbert Ramirez f7265ba975 Allow NCP types to define bitfields. In order to implement
sub-trees, I added new functions to ptvcursor:

	ptvcursor_add_no_advance()
	ptvcursor_tvbuff()
	ptvcursor_current_offset()

Note that no NCP type that actually uses bitfields has been
checked in yet.

svn path=/trunk/; revision=4509
2002-01-10 04:44:34 +00:00
Guy Harris aa36cec9df SCSI dissector, and changes to make the iSCSI dissector use it, from
Dinesh Dutt.

svn path=/trunk/; revision=4508
2002-01-10 01:28:45 +00:00
Gilbert Ramirez 573f3fb04a Provide a --disable-usr-local flag to configure so that
-I/usr/local/include and -L/usr/local/lib aren't automatically added
to the build flags.

svn path=/trunk/; revision=4507
2002-01-09 23:21:55 +00:00
Guy Harris bd42a598db HMIPv6 fix, from Martti Kuparinen.
svn path=/trunk/; revision=4506
2002-01-09 19:13:03 +00:00
Guy Harris aa0459d3c2 Add DHCPv6 dissector to Windows build.
svn path=/trunk/; revision=4505
2002-01-09 02:55:38 +00:00
Jun-ichiro itojun Hagino 7cfaf110e6 DHCPv6 dissector, based on draft-ietf-dhc-dhcpv6-22.txt.
note that protocol constants are subject to change.
(packet format is also subject to change.  but 22 draft should go
to wg last call very soon, and I really hope it to be the final one...)

svn path=/trunk/; revision=4504
2002-01-09 02:51:46 +00:00
Guy Harris 5e7698f322 From Marc Milgram: all packets in DBS Etherwatch and VMS TCPIPTRACE
captures are IP packets, so make the file encapsulation
WTAP_ENCAP_RAW_IP rather than WTAP_ENCAP_PER_PACKET, so you can save
those captures in other formats.

svn path=/trunk/; revision=4503
2002-01-08 22:30:29 +00:00
Guy Harris 3ecfaeedb5 Don't process a color filter if there's no filter associated with it.
Don't put a color filter into the list of color filters if we can't
allocate the colors for the filter.

Clean up white space.

svn path=/trunk/; revision=4502
2002-01-08 21:35:17 +00:00
Guy Harris d778d70b03 From M.C. van den Bovenkamp: 00:B0:D0 now belongs to Dell. (The IEEE
OUI listing from

	http://standards.ieee.org/regauth/oui/oui.txt

agrees with that.)

svn path=/trunk/; revision=4501
2002-01-08 20:58:14 +00:00
Guy Harris e1cee75f02 From Tom Uijldert: fix to supply a non-null string argument to
"proto_tree_add_string_format()", so the item has a value, and so that
Ethereal doesn't just crash.

Get rid of some uses of "tvb_length()" - use "tvb_reported_length()", or
-1, instead (so that we don't quit when we run out of captured data).

Use "g_warning()", as other dissectors do, for reporting problems with
packets.  (They should really put it into the protocol tree, instead,
but that's another matter....)

svn path=/trunk/; revision=4500
2002-01-08 20:51:16 +00:00
Guy Harris c78cb46c0e Use "proto_tree_add_item()", not "proto_tree_add_bytes()", to add an
item for extra data at the end of the Transaction2 request parameters.

svn path=/trunk/; revision=4499
2002-01-08 20:11:57 +00:00
Guy Harris 12d566c0ac Add a routine to kill a capture child if it exists, so that if we exit
(by deleting the main window or selecting File->Quit or typing ^Q) while
an "Update list of packets in real time" capture is in progress, we can
abort the capture.

Arrange that "fork_child" is -1 when there is no capture child, so said
routine knows when it can kill the child.

When we exit, kill off any capture child, using that routine, and, if
we're exiting due to a request to delete the main window and, if a read
is in progress (from an "Update list of packets in real time" capture),
don't delete the main window - just set the "Read aborted" flag, so that
the code doing the read will see that flag (it will be called because
the pipe to the capture child is closed due to the child exiting) will
see that and clean up and exit itself.

svn path=/trunk/; revision=4498
2002-01-08 09:32:15 +00:00
Guy Harris 86a251065d If a ReportedBoundsError exception occurs, report it as a "malformed
packet" rather than a "malformed frame" - the packet in question might
be part of a link-layer frame or might span more than one link-layer
frame.

svn path=/trunk/; revision=4497
2002-01-08 07:17:55 +00:00
Guy Harris 8fa2aef40e Use "%u", not "%d", to print unsigned quantities.
svn path=/trunk/; revision=4496
2002-01-08 07:14:08 +00:00
Guy Harris 4e08507d23 Match requests and responses using both the MID and the PID; the SNIA
CIFS draft spec speaks of both being used:

	The multiplex ID (Mid) is used along with the Pid to allow
	multiplexing the single client and server connection among the
	client's multiple processes, threads, and requests per thread.
	Clients may have many outstanding requests (up to the negotiated
	number, MaxMpxCount) at one time.  Servers MAY respond to
	requests in any order, but a response message MUST always
	contain the same Mid and Pid values as the corresponding request
	message.  The client MUST NOT have multiple outstanding requests
	to a server with the same Mid and Pid.

and I have seen a capture where more than one PID is used on a given
connection and where the same MID is used with two different PIDs.

Get rid of the "mid" field in the "smb_info_t" structure - the MID is
not used outside "dissect_smb()".

svn path=/trunk/; revision=4495
2002-01-08 05:52:05 +00:00
Guy Harris 7519e9b831 Vendor ID lookup fix, from David Frascone.
svn path=/trunk/; revision=4494
2002-01-07 20:05:20 +00:00
Guy Harris f13c5b2154 Updates from Tim Potter.
svn path=/trunk/; revision=4493
2002-01-07 19:55:48 +00:00
Guy Harris e35851244c Clean up white space.
svn path=/trunk/; revision=4492
2002-01-07 01:05:33 +00:00
Guy Harris 7849c3c4f9 Catch ReportedBoundsError exceptions when dissecting an RPC-over-TCP
call/reply, and report the error but don't re-throw the exception; that
way, we can continue to dissect additional RPC messages in the frame or
reassembled chunk of data, even if one of them happens to be too short
for what's in it.

svn path=/trunk/; revision=4491
2002-01-07 00:59:26 +00:00
Guy Harris 56a9c7ba63 Shuffle a comment, and clean up white space.
svn path=/trunk/; revision=4490
2002-01-07 00:57:46 +00:00
Guy Harris 5571f3e40b Catch ReportedBoundsError exceptions when dissecting the payload of an
NBSS session message, and report the error but don't re-throw the
exception; that way, we can continue to dissect additional NBSS messages
in the frame or reassembled chunk of data, even if one of them happens
to be too short for what's in it.

svn path=/trunk/; revision=4489
2002-01-07 00:16:32 +00:00
Guy Harris 5ae8fe3b8f There's no need for two separate "Extension Length" fields - you can
add a 1-byte item for a FT_UINT16 field.

Don't create a separate tvbuff for the extensions, just use the tvbuff
handed to us and start dissecting at the beginning of the extensions.

Use the reported length, not the captured length, to indicate how much
to dissect, so that if the frame was cut short by the snapshot length,
we throw a "Short Frame" exception.

Use "proto_tree_add_item()", not "proto_tree_add_bytes()", to add an
item for the data in an unknown extension.

svn path=/trunk/; revision=4488
2002-01-05 22:09:17 +00:00
Guy Harris 8c464ca6cc Fix a typo.
svn path=/trunk/; revision=4487
2002-01-05 21:49:36 +00:00
Guy Harris 8289dd46d2 From Ronnie Sahlberg: use size from encapsulation instead of how many
bytes were dissected since there can be padding bytes after the ndmp pdu
and to the end of what size said it would be, and some other cleanups.

svn path=/trunk/; revision=4486
2002-01-05 20:08:47 +00:00
Guy Harris ba74898e8c Additional sanity checks, from Ronnie Sahlberg.
svn path=/trunk/; revision=4485
2002-01-05 20:05:53 +00:00
Gilbert Ramirez 0b9b02c6ea Long NCP traces can easily have many packets whose "uniqueness"
variables wrap-around. Since the request/reply packets are related via
a hash based on these uniqueness variables, long NCP traces can
have mis-matches reqeust/reply records.

Thus, only do the hash-lookup for the reply packet during the first
sequential scan of the trace file. Once the pertinent info is found,
store it in the packet's private data area.

Since the memory allocated for the hash and for the structures that make
up the keys are no longer needed after the first sequential run through
the trace file, arrange to free that memory after the first sequential
run. Similar to the register_init_routine() that allows dissectors
to register callbacks for calling *before* a capture file is loaded,
set up a register_postseq_cleanup_routine() function that allows
dissectors to register callbacks for calling *after* the first
sequential run-through of the trace file is made. This is not
a *final* cleanup callback, since Ethereal will still have that trace file
open for random-access reading.

I didn't have tethereal call postseq_cleanup_all_protocols() since
tethereal doesn't keep the trace file open for random-access reading.
I could easily be swayed to make tethereal call that function, however.

svn path=/trunk/; revision=4484
2002-01-05 04:12:17 +00:00
Guy Harris 3ed03cadf6 Further updates from Ronnie Sahlberg.
svn path=/trunk/; revision=4483
2002-01-04 23:53:40 +00:00
Guy Harris e0593df4a7 If the "parent directory" of what would be the personal configuration
file directory is just a drive letter (e.g., if the directory is
"c:\Ethereal"), don't "stat()" it to see if it exists (as that'll fail,
falsely leading us to believe it needs to be created; the attempt to do
so will fail), just assume it exists.

svn path=/trunk/; revision=4482
2002-01-04 21:50:26 +00:00
Guy Harris cb489a92bb From Hamish Moffatt:
Additional Windows Makefile dependencies, so more stuff gets
	built as needed.

	Additional stuff cleaned up by "make clean" (well, "nmake -f
	makefile.nmake clean", anyway)

	Make PDB_FILE be "vc*.pdb", so it referes to the PDB files
	either for VC++ 5.0 or VC++ 6.0.

svn path=/trunk/; revision=4481
2002-01-04 21:20:20 +00:00