Commit Graph

644 Commits

Author SHA1 Message Date
Laurent Deniel e466de51ad Collapse/Expand All protocol tree added in Display menu.
svn path=/trunk/; revision=660
1999-09-11 12:38:18 +00:00
Guy Harris b32b29be35 "ascend_seek()" isn't used outside "ascend.c", so make it static to
"ascend.c".

svn path=/trunk/; revision=659
1999-09-11 07:07:41 +00:00
Guy Harris 0a4912e1d8 Include <string.h> to declare "memmove()".
svn path=/trunk/; revision=658
1999-09-11 06:51:28 +00:00
Guy Harris bac7494ff0 "ascend_read()" is local to "ascend.c" - declare it there, not in
"ascend.h".

svn path=/trunk/; revision=657
1999-09-11 06:49:42 +00:00
Guy Harris de7081f8ff Include "ascend.h" to declare "ascend_seek_read()".
"wtap_seek_read()" should return the value of "ascend_seek_read()" or
"wtap_def_seek_read()".

svn path=/trunk/; revision=656
1999-09-11 06:48:33 +00:00
Guy Harris 4c6f416754 "capture.c" doesn't do socket "ioctl"s any more - the code to do that is
now in "gtk/capture_dlg.c" - so it doesn't need to include
<sys/sockio.h> on, for example, Solaris...

...but "gtk/capture_dlg.c" does need to include it.

"gtk/capture_dlg.c" also may need to include "snprintf.h", as it uses
"snprintf()".

svn path=/trunk/; revision=655
1999-09-11 06:23:28 +00:00
Gerald Combs 72a668a88a Oops - forgot to commit the Ascend header decoder..
svn path=/trunk/; revision=654
1999-09-11 05:32:33 +00:00
Gerald Combs 70481fcc84 Add in ascend.c, ascend.h, ascend-grammar.y and ascend-scanner.l. These
read and parse the Lucent/Ascend trace output.

svn path=/trunk/; revision=653
1999-09-11 04:53:26 +00:00
Gerald Combs 9386f23fee Added support for Lucent/Ascend packet traces. The MAX and Pipeline router
family has a set of debug commands that allow you to log the traffic on a
WAN or dialup connection as text, e.g.

RECV-iguana:241:(task: B04E12C0, time: 1975358.50) 15 octets @ 8003D634
  [0000]: FF 03 00 3D C0 06 C9 96 2D 04 C1 72 00 05 B8

Created wtap_seek_read() which parses the textual data for and Ascend
trace, and does a normal fseek() and fread() for any other file type.
The fseek()/fread() pairs in file.c were replaced with the new function.

svn path=/trunk/; revision=652
1999-09-11 04:50:44 +00:00
Gerald Combs 078f9a67b9 Added support for PPP Multilink Protocol (MP). Modified dissect_ppp_stuff
to recognize and handle protocol field compression.

svn path=/trunk/; revision=651
1999-09-11 04:19:26 +00:00
Gilbert Ramirez 7a37324e12 Added ip, tcp, and udp to randpkt.
svn path=/trunk/; revision=650
1999-09-10 15:38:58 +00:00
Guy Harris dc298db578 Give "globals.h" an RCS ID and copyright/GPL notice.
Move some defines that would be used even by a non-GTK+-based Ethereal
from "gtk/main.h" to "globals.h".

Remove the byte-order #defines from "packet.h", as they're now in
"globals.h" (having been moved there from "gtk/main.h").

Fix up some files that use those #defines to include "globals.h".

"resolv.c" doesn't use any GTK stuff, so it needn't include <gtk/gtk.h>
nor "gtk/main.h" - it only did so to get the byte-order #defines for the
benefit of "packet-ipv6.h", and "packet-ipv6.h" now includes them
itself.

svn path=/trunk/; revision=649
1999-09-10 07:19:51 +00:00
Guy Harris f9f2bf9a28 Fix a comment, to reflect the demise of "ethereal.h".
svn path=/trunk/; revision=648
1999-09-10 07:09:35 +00:00
Guy Harris 046c060f98 We need to catch a "window delete" event for the preferences dialog box
- that event happens if, say, you nuke the dialog box from a window
manager - and call "delete" routines for each of the preferences tabs,
so that, for preferences tabs that include list widgets, we can set a
flag on the preferences tab widget telling the selection callback for
the list widget that the buttons it would normally set the sensitivity
of, based on whether any row in the list is selected or not, have Joined
the Choir Invisible, and therefore that we shouldn't change their
sensitivity because GTK+ will whine at us if we do, just as is the case
if we press the "OK" or "Cancel" button (which also cause the window to
go away).

Can we just do this in the "window delete" handler?  I.e., does that get
called if we explicitly destroy the widget?  Or should we catch a
"destroy" event instead?

(There must be a better way to do this....)

svn path=/trunk/; revision=647
1999-09-10 06:53:32 +00:00
Guy Harris 7e1ce9e122 Make stuff used only in "filter_prefs.c" static to it.
svn path=/trunk/; revision=646
1999-09-10 06:01:02 +00:00
Gilbert Ramirez c2bf152b01 Added random packet generator.
svn path=/trunk/; revision=645
1999-09-10 05:15:17 +00:00
Guy Harris e425e372ca Have "fddifc_to_str()" return "Unknown frame type" for a frame type it
doesn't know about, and eliminate the check in "dissect_fddi()" where we
check if its return value was NULL and, if so, print "Unknown frame
type".

svn path=/trunk/; revision=644
1999-09-10 04:53:14 +00:00
Gilbert Ramirez b0bd01b53f Changed default return value of fddifc_to_str from NULL to "". The value
is passed to col_add_str, which is then passed to strncpy, which, at least
in glibc 2.1, doesn't like NULL pointers passed to it in lieu of empty
strings.

svn path=/trunk/; revision=643
1999-09-10 03:16:08 +00:00
Guy Harris 92c4f1d830 Expand the message printed if "configure" can't find "net/bpf.h" to
remind you that if you've installed "libpcap" from source, you have to
do "make install-incl" as well.

svn path=/trunk/; revision=642
1999-09-09 21:29:58 +00:00
Gilbert Ramirez ca61d69c63 Removed two cases where protocol decoding assumed that the data in the
packets were correct. Bad packets could cause segfaults.

svn path=/trunk/; revision=641
1999-09-09 04:47:17 +00:00
Guy Harris d32b5f829f Put RCS IDs (and a copyright notice and GPL notice) in several files,
and fix up the introductory comment on some other files.

svn path=/trunk/; revision=640
1999-09-09 04:25:49 +00:00
Guy Harris 338f3ff2ad Put in an RCS ID (and a copyright notice and GPL notice; unfortunately,
this causes "Makefile.in" to have two GPL notices - "Makefile.in" and
the "Makefile" generated from it are generated files, so maybe that's
OK).

svn path=/trunk/; revision=639
1999-09-09 03:55:49 +00:00
Guy Harris cb2428cc6c Put in an RCS ID (and a copyright notice and GPL notice; unfortunately,
this causes "Makefile.in" to have two GPL notices - "Makefile.in" and
the "Makefile" generated from it are generated files, so maybe that's
OK).

svn path=/trunk/; revision=638
1999-09-09 03:45:57 +00:00
Gilbert Ramirez fee5f126ff I forgot to include this file move in my last commit.
svn path=/trunk/; revision=637
1999-09-09 03:35:32 +00:00
Gilbert Ramirez 8617c58f3c More shuffling of GTK-related routines to gtk subdirectory.
svn path=/trunk/; revision=636
1999-09-09 03:32:03 +00:00
Gilbert Ramirez 3c49e45cf7 More shuffling of GTK-related files to gtk subdirectory.
svn path=/trunk/; revision=635
1999-09-09 02:42:40 +00:00
Guy Harris 28009b86d2 Don't include in the list of interfaces offered by the "capture" dialog
box interfaces we can't open; this filters out loopback interfaces on
e.g. Solaris (which you can't get at with a DLPI device, so you can't
capture traffic on them), and also means we don't report *any*
interfaces if you don't have permission to open any (which means you
don't have permission to capture packets).

If we don't find any interfaces, pop up a message box saying so.

Free up the interface "ioctl" buffer, and close the socket we were
using, before returning from "get_interface_list()".

If "get_interface_list()" returns a null pointer (meaning it failed),
don't pop up the "capture" dialog box.

svn path=/trunk/; revision=634
1999-09-08 05:41:25 +00:00
Guy Harris cde9b4699c Add in a bunch of changes based on the IBM specification for the NetBIOS
Frame protocol (that being what this dissects).

If you're cutting up something into bitfields, the bitfield dissection
returned by "dissect_bitfield_XXX()" should be the first text on the
line - if not, then if the text items that come before the various
bitfields aren't all the same length, the bits don't line up.

Cope with packets from one of Gilbert's captures, where the sender
"name" in some NBF datagrams isn't a NetBIOS name, it's 10 octets of 0
followed by a MAC address!

The "name type" in the "Data2" field of NBF frames is 0x00 for unique
names and 0x01 for group names, not a "16th character of a NetBIOS name"
name type.

Fix up various other things.

svn path=/trunk/; revision=633
1999-09-03 07:20:15 +00:00
Guy Harris 37af231761 Add in a pile of additional packet formats from
http://ourworld.compuserve.com/homepages/TimothyDEvans/contents.htm

Assorted minor cleanups.

svn path=/trunk/; revision=632
1999-09-03 04:37:11 +00:00
Guy Harris fdc29358f3 Stuff to IPX socket 0x0455 (NetBIOS), and to sockets 0x0551 and 0x0553
(NWLink), are sufficiently different that they should be handled in
different routines.

Change the decode to match NetMon a bit more.

svn path=/trunk/; revision=631
1999-09-03 03:22:19 +00:00
Guy Harris 27c0d2d022 Use "process_netbios_name()", rather than "canonicalize_netbios_name()",
to turn NetBIOS names into a nice printable form.

Put the description of NetBIOS name types into places where it fits;
have "packet-netbios.c" export a routine to interpret them.

svn path=/trunk/; revision=630
1999-09-03 01:43:09 +00:00
Guy Harris dec805ba0d Dissect the name type flag in NBIPX name service packets (at least
according to what NetMon thinks the bits are).

svn path=/trunk/; revision=629
1999-09-03 00:38:50 +00:00
Guy Harris 3d7691d432 Add a bunch more NetBIOS name types.
That makes the space of name types even more sparse; use "val_to_str()"
to decode them, rather than an indexed table.

Make a "process_netbios_name()" routine that shows non-printable
characters in NetBIOS names as <XX>, where "XX" is the value of the
character in hex (the way Network Monitor does), and have
"get_netbios_name()" use it (NetBIOS-over-TCP will be made to use it in
the future).

When displaying NetBIOS names, include the name type character at the
end, in angle brackets, the way Network Monitor does (show it in hex
even if it *is* printable - 0x20 is 0x20, not "space", in that context).

svn path=/trunk/; revision=628
1999-09-03 00:24:40 +00:00
Guy Harris f9a1fea17c Have the IPX code set "pi.len" and "pi.captured_len" based on the length
in the IPX header, and have the dissectors it calls use it rather than
being passed the length as an argument.

Treat both packet type 20 ("WAN Broadcast") and 4 ("IPX", although 3 is
also "IPX", according to Network Monitor) as potentially being NetBIOS
packets.

The packet types for the IPX NetBIOS socket (0x0455) and the NWLink
sockets (0x0551 and 0x0553) are different (perhaps because there's one
socket for the 0x0455 NBIPX, so you have to do name service and datagram
service and have the packet types distinguish them, but NWLink has
separate sockets for name service and datagram service).

The packet type for name service and for datagram service are at
*different locations* in the packet, which is unfortunate if you want to
use the packet type to distinguish name service and datagram service
packets.  Use the packet length, for now, to distinguish them, with
socket 0x0455.

Dissect datagram packets differently from name service packets.

Export "packet-netbios.c"'s "netbios_add_name()" routine, and use it
when dissecting NBIPX packets as well.

Label NBIPX packets as "NBIPX" rather than "NetBIOS".

svn path=/trunk/; revision=627
1999-09-02 23:17:58 +00:00
Guy Harris c135be4e53 When skipping over the padding at the end of a record in a capture file,
don't seek around it - some implementations of the standard I/O library
routines (e.g., the ones in Solaris 2.5.1, at least) appear not to be
clever enough to handle seeks that occur within the buffer by moving the
current buffer position; instead, they do a seek on the underlying file
descriptor *and* appear to throw out the buffer, forcing them to do
another read.

Instead, read it into a buffer.

svn path=/trunk/; revision=626
1999-09-02 00:14:06 +00:00
Guy Harris b87ec88778 When reading packets from a capture file, don't seek around record
header fields we don't look at - some implementations of the standard
I/O library routines (e.g., the ones in Solaris 2.5.1, at least) appear
not to be clever enough to handle seeks that occur within the buffer by
moving the current buffer position; instead, they do a seek on the
underlying file descriptor *and* appear to throw out the buffer, forcing
them to do another read.

Instead, read the entire record header into a structure, and pick the
relevant bits out of it.

Also, skip over the FCS in LAPB captures by reading it rather than
seeking around it (should we put it in the pseudo-header?).

svn path=/trunk/; revision=625
1999-09-01 23:53:58 +00:00
Guy Harris bb12ec7ba1 Bert Driehuis' patch to add a "--with-ucdsnmp" option that specifies the
directory in which the UCD SNMP library is found (and to check for the
UCD SNMP stuff in "$prefix" if "$prefix" isn't "/usr/local"), and to
have "Makefile.am" use "$(MAKE)" rather than "make".

svn path=/trunk/; revision=624
1999-09-01 22:59:48 +00:00
Gilbert Ramirez 65c3e8d9bf Moved GTK-dependent routines for file dialogues, print dialogues, print
preferences, and menus to gtk subdirectory.

svn path=/trunk/; revision=623
1999-09-01 03:04:24 +00:00
Guy Harris 25502bc8fc Bert Driehuis' patch to handle "libpcap" stuff being installed in
subdirectories of "$prefix", if "$prefix" is neither "/usr" nor
"/usr/local".

svn path=/trunk/; revision=622
1999-08-31 23:24:25 +00:00
Guy Harris fa1930a89c We now use "snprintf()" in "dissect_ip_tcp_options()", so we may need to
include "snprintf.h" to declare it.

svn path=/trunk/; revision=621
1999-08-31 23:21:29 +00:00
Guy Harris 9d14dfd6a9 Fix, from Bert Driehuis, to the stuff that checks for BSD/OS.
svn path=/trunk/; revision=620
1999-08-31 22:36:20 +00:00
Guy Harris 81cda54d24 Olivier Abad's fix to the problem where some capture files appeared to
be truncated - treat a record with a data length of 0 as an end of file.

svn path=/trunk/; revision=619
1999-08-31 17:40:49 +00:00
Gilbert Ramirez 4b5b164ab4 Packaging fix for doc subdirectory changes.
svn path=/trunk/; revision=617
1999-08-31 06:26:12 +00:00
Gilbert Ramirez 978375cc2b Added info about Linux libpcap misbehavior, and where to download the libpcap
patch.

svn path=/trunk/; revision=616
1999-08-31 06:09:25 +00:00
Gilbert Ramirez cc7387e116 Removed hacked-up doc/Makefile.in, and replaced it with simple doc/Makefile.am.
svn path=/trunk/; revision=615
1999-08-31 05:58:48 +00:00
Gilbert Ramirez bf20c06bea Changed gtk subdirectory to use only Makefile.am, and not have a configure
script. The configuration is faster this way. Also, moved version to 0.7.3.

svn path=/trunk/; revision=614
1999-08-31 05:52:08 +00:00
Guy Harris 2f1f2b08ed Convert the seconds value to the right byte order before using it at
all, not just before the third time you use it....

svn path=/trunk/; revision=613
1999-08-31 00:25:19 +00:00
Guy Harris d6147cd00a Fixes from Olivier Abad to the code to maintain "wth->data_offset".
Use "pletohs()" and "pletohl()" to access 16-bit and 32-bit fields in
the file and packet headers, as those fields are little-endian.

svn path=/trunk/; revision=612
1999-08-30 20:40:13 +00:00
Gilbert Ramirez 6edb400771 Now that FT_BOOLEAN display filter fields are treated differently (only
their existence is checked), some FT_BOOLEAN-related functions in dfilter.c
are no longer called. So I removed them.

svn path=/trunk/; revision=611
1999-08-30 16:01:42 +00:00
Gilbert Ramirez fc7bf366a3 Fixed problem with not being able to filt on field values.
svn path=/trunk/; revision=610
1999-08-30 15:51:44 +00:00