Commit Graph

2990 Commits

Author SHA1 Message Date
Guy Harris bde0b86caf X.25-over-LLC support, from Paul Ionescu.
svn path=/trunk/; revision=2829
2001-01-05 19:07:38 +00:00
Guy Harris 499a830af6 DEC LANBridge Spanning Tree Protocol support, from Paul Ionescu.
Put "packet-lapbether.c" into "Makefile.nmake".

svn path=/trunk/; revision=2828
2001-01-05 19:00:37 +00:00
Guy Harris 9e392235ca Clear the Info column before fetching anything from the packet, so that
if we throw an exception, the stuff from the Token-Ring protocol isn't
still there.

svn path=/trunk/; revision=2827
2001-01-05 08:59:16 +00:00
Guy Harris b31b5b697b Clear the Info column before fetching anything from the packet, so that
if we throw an exception, the stuff from the protocol atop which LLC
runs isn't still there.

svn path=/trunk/; revision=2826
2001-01-05 08:43:30 +00:00
Guy Harris 40a0f2b3f0 Set "pinfo->current_proto" once we've decided it's an H1 packet.
Fix the indentation.

svn path=/trunk/; revision=2825
2001-01-05 08:34:35 +00:00
Gilbert Ramirez fd7367e9b2 Doesn't need #include "dfilter.h"
svn path=/trunk/; revision=2824
2001-01-04 04:56:20 +00:00
Gilbert Ramirez bb6df3b8c2 Doesn't need #include "dfilter.h"
svn path=/trunk/; revision=2823
2001-01-04 04:44:02 +00:00
Guy Harris 38d2f3afc3 Make the PPP-over-Ethernet discovery and session protocols registered
protocols.

svn path=/trunk/; revision=2822
2001-01-04 04:15:30 +00:00
Guy Harris b443a9295a Don't define "promisc_mode" if we weren't built with libpcap support.
svn path=/trunk/; revision=2821
2001-01-04 00:16:43 +00:00
Olivier Abad 19a997a7ad - replace x25 with x.25 in all protocol fields
- displays the GFI (the a/q/d bits and modulo are displayed in a subtree of
  the GFI)
- correctly dissect the first bit of the GFI : Address bit in call set-up
  and clearing packets, Qualifier bit in data packets.

svn path=/trunk/; revision=2820
2001-01-03 23:30:50 +00:00
Guy Harris a723a48355 Tvbuffify the BOOTP/DHCP dissector.
svn path=/trunk/; revision=2819
2001-01-03 22:49:06 +00:00
Guy Harris 5c41d2e842 "hf_sna_rh_csi" is now an FT_UINT8 field, so add it with
"proto_tree_add_uint()", not "proto_tree_add_boolean()".

svn path=/trunk/; revision=2818
2001-01-03 21:52:40 +00:00
Gilbert Ramirez 5b7f184296 Ensure that all value_string arrays end in {0, NULL}. Dissectors got away
with not terminating their arrays because they knew the limits of the
value used to look up strings in the value_string array, but the
dfilter_expr_dlg does not know these limits and must rely on the terminating
{0, NULL} record.

Also, in SNA fixed a bug in which a field should have been defined as FT_UINT8
but was defined as FT_BOOLEAN.

In WTP, fixed a value string which had duplicate keys.

svn path=/trunk/; revision=2817
2001-01-03 16:41:08 +00:00
Guy Harris b151ddecbb Have the TR MAC and LLC dissectors register themselves, make them
static, and have other dissectors call them through handles.

svn path=/trunk/; revision=2816
2001-01-03 10:34:42 +00:00
Guy Harris b92ebd4a23 Register the WSP dissector, make it static, and have the WTP dissector
call it through a handle.

svn path=/trunk/; revision=2815
2001-01-03 08:42:48 +00:00
Guy Harris bf94988818 Make the Zebra dissector, and a routine it uses, static, as they're not
called directly from outside "packet-zebra.c".

svn path=/trunk/; revision=2814
2001-01-03 08:26:40 +00:00
Guy Harris 6d7aa5a618 Update the README.developer file to reflect the recent changes to
"proto_register_protocol()" and the addition of
"prefs_register_module()".

svn path=/trunk/; revision=2813
2001-01-03 08:00:01 +00:00
Guy Harris 3613c121fe Add a new "prefs_register_protocol()" routine, which is like
"prefs_register_module()" except that it takes a protocol index as
returned by "proto_register_protocol()" as its first argument, rather
than taking two character strings as arguments as its first two
arguments, and uses the protocol's abbreviation as the name to use for
preferences in the preferences file and the "-o" flag and uses the
protocol's short name as the name to use in the tabs in the
"Edit->Preferences" window.

svn path=/trunk/; revision=2812
2001-01-03 07:53:48 +00:00
Guy Harris fee98dd944 Have "proto_register_protocol()" build a list of data structures for
protocols, in addition to adding structures to the list of filterable
fields.  Give it an extra argument that specifies a "short name" for the
protocol, for use in such places as

	pinfo->current_proto;

	the dialog box for constructing filters;

	the preferences tab for the protocol;

and so on (although we're not yet using it in all those places).

Make the preference name that appears in the preferences file and the
command line for the DIAMETER protocol "diameter", not "Diameter"; the
convention is that the name in question be all-lower-case.

Make some routines and variables that aren't exported static.

Update a comment in the ICP dissector to make it clear that the
dissector won't see fragments other than the first fragment of a
fragmented datagram.

svn path=/trunk/; revision=2811
2001-01-03 07:37:29 +00:00
Guy Harris 0e7c1de08a Have "proto_register_protocol()" build a list of data structures for
protocols, in addition to adding structures to the list of filterable
fields.  Give it an extra argument that specifies a "short name" for the
protocol, for use in such places as

	pinfo->current_proto;

	the dialog box for constructing filters;

	the preferences tab for the protocol;

and so on (although we're not yet using it in all those places).

Make the preference name that appears in the preferences file and the
command line for the DIAMETER protocol "diameter", not "Diameter"; the
convention is that the name in question be all-lower-case.

Make some routines and variables that aren't exported static.

Update a comment in the ICP dissector to make it clear that the
dissector won't see fragments other than the first fragment of a
fragmented datagram.

svn path=/trunk/; revision=2810
2001-01-03 06:56:03 +00:00
Richard Sharpe 6c75aa83f9 Fix a damn stupid mistake that stopped us seeing all the bits in the flags on a NetServerEnum2 request.
svn path=/trunk/; revision=2809
2001-01-03 04:37:07 +00:00
Guy Harris c3211e8eeb Support for HTTP methods added by GENA (the uPnP protocol), and for the
HTTP-based SSDP protocol, from David Hampton.

svn path=/trunk/; revision=2808
2001-01-03 03:40:29 +00:00
Guy Harris e87346151d Base the decision of whether selecting an entry in the value list sets
the value entry on the type of the field, not on whether the value entry
is visible; the value entry is hidden, in "field_select_row_cb()", after
"build_boolean_values()" is called, and building the list in
"build_boolean_values()" will cause an entry in that list to be
selected, and "value_list_sel_cb()" will be called as a result, so it
can't correctly base its decision on whether to set the value entry on
whether the entry is visible, as it's not yet been made invisible.

Fix a comment.

svn path=/trunk/; revision=2807
2001-01-02 19:54:50 +00:00
Guy Harris 51aceed165 Don't show "Text" as one of the available fields.
svn path=/trunk/; revision=2806
2001-01-02 19:38:20 +00:00
Guy Harris 88d157ef96 Add a dialog box for constructing expressions that test a field in the
display tree, based on Jeff Foster's dialog box for selecting fields.

Make the dialog box for browsing filters into a dialog box for
constructing filters; make the "Apply" button and the "OK" button apply
the filter in the text entry box in the dialog, not the currently
selected filter (selecting a filter puts it in that text entry box, but
the user may edit it afterwards, or may use the aforementioned dialog
box to construct a filter not in the list).

Get rid of extra declarations of "m_r_font" and "m_b_font" in
"proto_draw.c"; they're declared in "gtk/gtkglobals.h", which it includes.

svn path=/trunk/; revision=2805
2001-01-02 01:32:21 +00:00
Richard Sharpe d2f2cc6bf6 A small fix to ensure that all servers/workgroups show up ... Last one
was not being picked up ...

Will have to add proper state keeping code soon ...

svn path=/trunk/; revision=2804
2001-01-01 01:44:46 +00:00
Jun-ichiro itojun Hagino f4d523b96f understand TCP MD5 signature. Greg Hankins <gregh@twoguys.org>
svn path=/trunk/; revision=2803
2000-12-30 05:23:56 +00:00
Guy Harris f18cff183c Tvbuffify the MAPI dissector.
svn path=/trunk/; revision=2802
2000-12-29 05:15:37 +00:00
Guy Harris 02380babc1 Fix up some calls in which I didn't replace "NullTVB" with "tvb".
svn path=/trunk/; revision=2801
2000-12-29 04:41:30 +00:00
Guy Harris 5bcb17c724 If we get an exception when dissecting a packet, append "[Short Frame]"
or "[Malformed Frame]" to the Info column.

Make some dissectors set the Protocol column and clear the Info column
before fetching anything from the tvbuff they were handed, so that if
the frame is short or malformed, it'll be marked as being the right
top-level protocol, and the Info column won't have cruft left over from
the previous protocol.

svn path=/trunk/; revision=2800
2000-12-29 04:16:57 +00:00
Guy Harris 00828b3f2b "dissect_lapb()" is static to "packet-lapb.c", so it can't be directly
called by "dissect_lapbether()".  "packet-lapbether.c" included
"packet-lapb.h", to get "dissect_lapb()" declared, but that header file
doesn't exist.

Dissectors should call other dissectors indirectly, so have the LAPB
dissector register itself and have the LAPB-over-Ethernet dissector get
that handle and call the LAPB dissector through that handle, rather than
making the LAPB dissector non-static and adding a "packet-lapb.h" header
to declare it.

Remove some unnecessary includes from "packet-lapbether.c".

svn path=/trunk/; revision=2799
2000-12-29 02:27:21 +00:00
Guy Harris 1d3ed65598 Tvbuffify the IMAP dissector.
svn path=/trunk/; revision=2798
2000-12-29 02:19:14 +00:00
Richard Sharpe b226f348ad Modify X.25 dissector to accept a search string of x.25 and ex.25, not x25 and ex25.
svn path=/trunk/; revision=2797
2000-12-29 01:27:35 +00:00
Richard Sharpe d481cd7b3f Added a LAPBETHER dissector as per Guy's wishes ... :-)
Damn, took more than half an hour :-(

svn path=/trunk/; revision=2796
2000-12-29 01:06:24 +00:00
Guy Harris bc40aeeade When creating a subset tvbuff with lengths that don't run to the end of
the parent tvbuff, we have to set "pinfo->len" and "pinfo->captured_len"
unless we know for certain that *no* old-style dissectors will be called
later, because old-style dissectors get their length information from
"pi.len" and "pi.captured_len".

svn path=/trunk/; revision=2795
2000-12-29 00:51:52 +00:00
Guy Harris 3e876653f3 Tvbuffify the PPTP dissector.
svn path=/trunk/; revision=2794
2000-12-29 00:35:51 +00:00
Guy Harris 11e59a0078 Updates from Ed Warnicke.
svn path=/trunk/; revision=2793
2000-12-28 10:10:17 +00:00
Guy Harris d13901155d Tvbuffify the CDP, CGMP, ISL, and VTP dissectors.
Add a new subdissector table in the LLC dissector for protocol IDs with
a Cisco OUI, and register the CDP, CGMP, and VTMP dissectors in that
table, rather than calling them via a switch statement.

Register the ISL dissector by name, and have the Ethernet dissector call
it via a handle.

Fix the handling of the checksum field in the CDP dissector.

The strings in CDP are counted, not null-terminated; treat them as such.

Fix the handling of the encapsulated frame CRC, and the encapsulated
frame, in the ISL dissector, at least for Ethernet frames; it may not be
correct for encapsulated Token Ring frames.

svn path=/trunk/; revision=2792
2000-12-28 09:49:09 +00:00
Jun-ichiro itojun Hagino f69876eece >This patch adds a missing capabilities NOTIFICATION message, and support for
>RFC2385 (Protection of BGP Sessions via the TCP MD5 Signature Option).
From: Greg Hankins <gregh@twoguys.org>

svn path=/trunk/; revision=2791
2000-12-28 05:13:14 +00:00
Guy Harris 4f5e161fe2 It turns out that the read timeout in Solaris's "bufmod" STREAMS module
doesn't work like the read timeout in BPF - the timer doesn't start
until at least one packet has arrived.

I think that's the way read timeouts should work on *all* packet capture
mechanisms, but it does mean that Solaris will, on a quiet net, exhibit
the same symptoms that Linux used to exhibit before we put in a
"select()" call to wait until either packets arrive or a timer expires -
the "pcap_dispatch()" call blocks until a packet arrives, so the display
doesn't get updated and Ethereal doesn't respond to user input until a
packet arrives.

Furthermore, Linux isn't the only OS that lacks any read timeout
on its packet capture mechanism; the others will also have that problem.

We therefore do the "select()" on *all* platforms other than the BSDs
(where the timer starts when the read is done, and can be used for
polling); I don't know whether it's necessary on Digital UNIX, but I
suspect it's necessary on SunOS 4.x (as the 5.x "bufmod" is probably
derived from the 4.x one, and the 5.x one, as per the above, starts the
timer when a packet arrives), and it may even be necessary on 3.x, those
(BSD, SunOS including 5.x, and Digital UNIX) apparently being the only
UNIXes that appear to have such a read timeout.

svn path=/trunk/; revision=2790
2000-12-28 01:44:19 +00:00
Guy Harris 9474f32fbf Always put the packet type in the Info column.
svn path=/trunk/; revision=2789
2000-12-28 00:44:49 +00:00
Guy Harris f6782c1ebe If the capture child process exits unexpectedly, give more information
on it, such as the exit status if it exited "normally" but unexpectedly.

On UNIX systems, #define the various POSIX <sys/wait.h> macros (and the
non-POSIX WCOREDUMP()" macro) if they're not defined by <sys/wait.h> (or
if we don't have <sys/wait.h>), and use them to dissect the exit status.

svn path=/trunk/; revision=2788
2000-12-27 22:35:48 +00:00
Guy Harris 11b24c6094 Tvbuffify the RIP and OSPF dissectors.
Change them to use facilities in Ethereal that were probably not present
when they were originally written, e.g. routines to fetch 24-bit
integers and to dump a bunch of raw bytes in hex.

Redo them to extract data from the packet as they dissect it, rather
than extracting an entire data structure at once; that way, it may be
able to dissect a structure not all of which is in the packet.

Dissect a bit more of the type-of-service metrics etc. in OSPF packets.

Make "tvb_length_remaining()" return a "gint", not a "guint"; it returns
-1 if the offset is past the end of the tvbuff.

Add a "tvb_reported_length_remaining()" routine, similar to
"tvb_length_remaining()".  Use it instead of just subtracting an offset
from "tvb_reported_length()".

svn path=/trunk/; revision=2787
2000-12-27 12:48:27 +00:00
Guy Harris 7e8b1d3a10 Get rid of extra blanks in strings.
"tvb_length_remaining()" will return -1 if the offset argument is past
the end of the tvbuff; check for values > 0, not values != 0, when
checking to see if there's extra garbage at the end of the packet.

svn path=/trunk/; revision=2786
2000-12-27 12:38:08 +00:00
Nathan Neulinger 79434f2dcf added KRB-ERROR response dissection
svn path=/trunk/; revision=2785
2000-12-26 16:44:43 +00:00
Nathan Neulinger 5242bfc924 add tethereal_static
svn path=/trunk/; revision=2784
2000-12-26 16:44:16 +00:00
Guy Harris d46aa3d576 Add a new "tvb_strsize()" routine, which finds the size of a
NUL-terminated string, starting at a given offset.  The size includes
the terminating NUL.  If it doesn't find the terminating NUL, it throws
the appropriate exception, as either there's no terminating NUL in the
packet or there is but it's past the end of the captured data in the
packet.

Use that routine in the TFTP dissector.  As it throws an exception if
the string isn't NUL-terminated, we can just use "%s" to print option
strings; we don't need to use "%.*s" with a string length.

svn path=/trunk/; revision=2783
2000-12-25 23:48:16 +00:00
Guy Harris cac14407f4 Preferences shouldn't supposed to have blanks in their names - it can
make it a bit of a pain to set their values on the command line (you
have to quote the name).  Use underscores instead.

Give the gateway and callagent port preferences different names.

Fix up the text descriptions and labels for those preferences.

svn path=/trunk/; revision=2782
2000-12-25 09:37:35 +00:00
Guy Harris 6de8fb2070 If a PrincipalName has at least one name-string, put the first of the
name strings into the top-level tree item for the PrincipalName, along
the lines of what was done earlier.

svn path=/trunk/; revision=2781
2000-12-25 06:59:33 +00:00
Jun-ichiro itojun Hagino b56e34d396 bgp route refresh/MP capability option.
Greg Hankins <gregh@twoguys.org>

svn path=/trunk/; revision=2780
2000-12-25 05:28:40 +00:00