Commit Graph

6567 Commits

Author SHA1 Message Date
Guy Harris c7cacdf4b7 Add an AT_ARCNET address type for ARCNET addresses, and have the ARCNET
dissector set the source and destination link-layer addresses.

svn path=/trunk/; revision=6452
2002-10-18 21:40:13 +00:00
Guy Harris 1a25bf1cfd Get rid of (probably-)unnecessary #includes.
svn path=/trunk/; revision=6451
2002-10-18 21:10:38 +00:00
Guy Harris 27df774d0b From Peter Fales: ARCNET support.
Sort the lists of dissectors in the DISSECTOR_SRC macros in
"Makefile.am" and "Makefile.nmake".

svn path=/trunk/; revision=6450
2002-10-18 21:00:01 +00:00
Guy Harris 5b99f89521 From Didier Gautheron: better AFP 3.x dissector.
svn path=/trunk/; revision=6449
2002-10-17 22:38:19 +00:00
Guy Harris 18dd6eff9e Flag fragment overlaps when reassembling based on sequence number, and,
when displaying the fragment tree for reassembly based on sequence
number, show the correct offset.

svn path=/trunk/; revision=6448
2002-10-17 21:14:17 +00:00
Guy Harris 3618a128a6 Put in a missing check for fragment overlaps, and add an assertion to
check for bogus dfpos values before using the value.

svn path=/trunk/; revision=6447
2002-10-17 20:51:35 +00:00
Guy Harris 9ce0f18987 Put in a note telling people not to use "long" for 32-bit quantities.
svn path=/trunk/; revision=6446
2002-10-17 20:05:04 +00:00
Guy Harris 0bba015d3e Don't use "unsigned long" when you mean "unsigned 32-bit integer", as
"unsigned long" is an unsigned *64-bit* integer on many platforms.

While we're at it, use "guint8" rather than "unsigned char" for
"unsigned 8-bit integer", and use "guint16" rather than "unsigned short"
for "unsigned 16-bit integer".

Make the seconds field of a libpcap time stamp signed, as it's supposed
to be.

svn path=/trunk/; revision=6445
2002-10-17 20:02:00 +00:00
Michael Tüxen e87b15d031 Fixed a bug on 64 bit machines in the CRC32C algorithm. Thanks to
Jerome Forissier.

svn path=/trunk/; revision=6444
2002-10-17 18:44:10 +00:00
Guy Harris 5b77ebc32d From Ronnie Sahlberg: use the frame number of a TCP segment, rather than
its starting sequence number, as the "fragment ID" when reassembling,
and include the source and destination port numbers in a
"tcp_segment_key" structure and use that as part of the key in the hash
table for segments, so that we don't get spoofed by segments in two
directions in the same conversation, or by segments in two separate
conversations between the same hosts, having the same starting sequence
number (which is not unlikely to happen if relative sequence numbers are
being used).

svn path=/trunk/; revision=6443
2002-10-17 02:19:29 +00:00
Guy Harris 79308de612 From Ronnie Sahlberg: don't have the tap code do a dissection, leave
that up to its callers, so only one dissection need be done when reading
a capture file.

svn path=/trunk/; revision=6442
2002-10-17 02:11:20 +00:00
Guy Harris 9fb669df43 The Boolean field for EndVerifyAck messages was missing, causing a crash
if such a message (or something that happened to look enough like such a
message) was ever seen.

svn path=/trunk/; revision=6441
2002-10-17 01:29:30 +00:00
Guy Harris b99f379f55 From Ulf Lamping: show total running time of capture in capture progress
dialog box.

svn path=/trunk/; revision=6440
2002-10-16 23:34:52 +00:00
Guy Harris 97222e340b Clean up white space.
Clean up the stuff to handle MVTYPE_PROC_ENTRY_SPECIFIERS a bit, and put
in comments explaining what's going on for that and MVTYPE_ATTR_REQUEST.

svn path=/trunk/; revision=6439
2002-10-16 23:24:21 +00:00
Guy Harris f27452006f Use #defines for multivalue types.
svn path=/trunk/; revision=6438
2002-10-16 23:04:53 +00:00
Guy Harris 84b245903c Make some counters 32-bit, as the upper limit on the loop in which
they're used is 32-bit.

Use "%u" rather than "%d" to print unsigned values.

svn path=/trunk/; revision=6437
2002-10-16 22:44:58 +00:00
Guy Harris 11b8825bcb Use #defines for vtype values, rather than numbers.
svn path=/trunk/; revision=6436
2002-10-16 22:20:30 +00:00
Guy Harris cd747aaeba Make arrays of "nds_val" structures rather than declaring a bunch of
individual structures, and initialize them, and put them into
the protocol tree, in a loop.

svn path=/trunk/; revision=6435
2002-10-16 21:57:24 +00:00
Gilbert Ramirez 1ba73660c0 Make the dfilter code support multiple header_field_info's with
the same name (abbreviation). Thus, if multiple protocols or fields
are registered with the same name, you can still filter on the name
and have the filtering work as expected.

svn path=/trunk/; revision=6434
2002-10-16 16:32:59 +00:00
Gerald Combs e0cf132365 Add support for building randpkt under Windows.
svn path=/trunk/; revision=6433
2002-10-16 14:45:27 +00:00
Guy Harris 103fafbb74 Make a routine to check for NTLMSSP authentication and to do the NTLMSSP
dissection if found, with a table of headers that indicate NTLMSSP
authentication.

Add some more headers to that table.

Constify the code a bit.

svn path=/trunk/; revision=6432
2002-10-15 22:28:35 +00:00
Guy Harris ddf3c6140b Fully initialize an ncp_req_hash_value after allocating it.
svn path=/trunk/; revision=6431
2002-10-15 17:31:20 +00:00
Guy Harris a03e90ad09 From Hannes Gredler: dissect the graceful restart capability in BGP OPEN
messages.

svn path=/trunk/; revision=6430
2002-10-15 17:19:06 +00:00
Guy Harris 01bd6435e4 We'll be building a protocol tree for all NDS Ping packets, so we can
just wrap the entire dissection in an "if", as was done before.
(Actually, we can just skip the "if" entirely, I guess....)

svn path=/trunk/; revision=6429
2002-10-15 07:47:57 +00:00
Guy Harris 35eba08c92 Set the "req_nds_flags" field for an NDS Ping request regardless of
whether we're building a protocol tree or not.

Set the separator if we put "Revision" into the summary.

Check for a remaining length >= 8, not > 8, to check for an NDS version
10 or later ping, and check the reported length, not the captued length.

svn path=/trunk/; revision=6428
2002-10-15 07:36:16 +00:00
Guy Harris d54e50d6a2 From Jason House: include <winsock2.h> early in "wtap-int.h" on Win32
builds with zlib - "zlib.h", alas, includes <winsock.h>, and you can't
include <winsock.h> before including <winsock2.h> (at least you can
include <winsock2.h> before including <winsock.h>; thank heaven for
small favors).

svn path=/trunk/; revision=6427
2002-10-15 05:38:01 +00:00
Guy Harris f0269dd749 Squelch some compiler warnings.
svn path=/trunk/; revision=6426
2002-10-15 05:29:48 +00:00
Guy Harris 86576ce6ac When registering a protocol, make sure there are no other protocols with
the same long name, short name, or filter name, and abort if there are.

Fix the duplicate names that found (and another name error found while
fixing one of those errors).

svn path=/trunk/; revision=6425
2002-10-15 05:21:07 +00:00
Guy Harris e0e7122674 Add a new port type, PT_IPX, for IPX socket numbers; set "pinfo->ptype",
"pinfo->srcport", and "pinfo->destport" appropriately in the IPX
dissector.  Add support for PT_IPX port types in display columns.

Have an "spx.socket" dissector table, similar to the "ipx.socket"
dissector table, and have the SPX dissector use that, with the IPX
socket numbers from "pinfo->srcport" and "pinfo->destport", so that
dissectors for protocols that run atop SPX can register with particular
socket numbers.  (Think of it as similar to what would have been the
case had the IP header had 16-bit source and destination port numbers,
and had TCP and UDP used those port numbers rather than having port
numbers in their headers.)  Also, have the SPX dissector dissect
subprotocols regardless of whether we're building a protocol tree or not.

Use the dissector handle for the IPX message dissector for both IPX
socket numbers; there's no need to create separate handles for both
registrations.

Have NDPS register as a subdissector of the SPX dissector, using
"spx.socket", and get rid of the duplicate SPX dissection in the NDPS
dissector.

Make the NDPS dissector set the columns regardless of whether a protocol
tree is being built, and clean up the dissector (fixing some bugs).

Get rid of unneeded includes in "packet-ndps.c".

svn path=/trunk/; revision=6424
2002-10-15 04:31:00 +00:00
Guy Harris ab89e89f78 Fix the file name in the initial comment.
Fix a typo in Gerald's e-mail address.

svn path=/trunk/; revision=6423
2002-10-15 04:26:24 +00:00
Guy Harris 87226d31a3 Fix a typo in Gerald's e-mail address.
svn path=/trunk/; revision=6422
2002-10-15 04:25:42 +00:00
Gerald Combs efe9c01caf Fix more typing issues. Pull the marker, length, and type individually
instead of copying them into a struct.  Remove the "bgp" struct, as it is
no longer used.  Gracefuly (more than before, at least) handle a zero
packet length.

svn path=/trunk/; revision=6421
2002-10-15 03:47:47 +00:00
Gerald Combs 9afeafe88e Fix signed/unsigned type mismatches, as pointed out by Silvio.
Add BGP output to randpkt.

svn path=/trunk/; revision=6420
2002-10-15 02:29:54 +00:00
Guy Harris e0a7988e6d From Thierry Pelle: IPv6CP support.
svn path=/trunk/; revision=6419
2002-10-14 23:23:20 +00:00
Olivier Abad ec3cb87a27 Another problem found by valgrind :
in continue_tail_cap_file, the following test :
else if (*err != 0)
sometimes reads uninitialized memory (so the test might be incorrect).

We now set *err to 0 at the beginning of the function.

svn path=/trunk/; revision=6418
2002-10-14 19:59:51 +00:00
Olivier Abad 75fb72f86e 1- We were writing 1 byte past the end of the buffer in register_tap
(bug found with valgrind) :
  td->name = malloc(strlen(name));
  strcpy(td->name, name);

Replaced with :
  td->name = g_strdup(name);

2 - Use g_malloc instead of malloc (both were used).

svn path=/trunk/; revision=6417
2002-10-14 19:45:08 +00:00
Guy Harris 63d65a3f69 From Ulf Lamping: count ARP packets in capture progress dialog box.
svn path=/trunk/; revision=6416
2002-10-14 17:33:50 +00:00
Guy Harris a236ba90d0 From Mike Frisch: fix problems with SETCLIENTID and SETCLIENTID_REPLY
decoding.

svn path=/trunk/; revision=6415
2002-10-14 17:08:53 +00:00
Guy Harris 6af349418a Create the temporary tree if we're *not* building a protocol tree
already, not if we *are*.

svn path=/trunk/; revision=6414
2002-10-14 16:47:56 +00:00
Guy Harris f58cd0bd5c Fetch the pointer to a string before allocating memory for the string,
so that if the string length is bogus and large, we'll throw an
exception in "tvb_get_ptr()" rather than crashing when we fail to
allocate the memory.

svn path=/trunk/; revision=6413
2002-10-11 21:58:25 +00:00
Guy Harris e4b32038a7 Make the flag buffer in "dissect_ping_req()" large enough to hold the
longest possible flag string.

Don't create a temporary protocol tree unless we're not filling in a
protocol tree.

The NDS version isn't present in NDS pings prior to version 10; dissect
it only if it's present.

svn path=/trunk/; revision=6412
2002-10-11 21:52:11 +00:00
Guy Harris b348f66dd4 Note that "dissect_ping_req()" duplicates a bunch of stuff in
"dissect_ncp_request()".

Fix "dissect_ping_req()" to properly put the NDS version in a ping
request into the tree (although that field isn't present in the ping
requests I've seen, so perhaps it's only in NDS version 10 and later),
as big-endian (change FALSE to TRUE if it's little-endian).

Get rid of the unused "ncp_nds_verb" variable (set, but not used) in
"dissect_ncp_common()".

Call "dissect_ping_req()" from "dissect_ncp_common()" again.

svn path=/trunk/; revision=6411
2002-10-11 19:36:13 +00:00
Guy Harris 4f471acc34 Fix some spelling errors.
svn path=/trunk/; revision=6410
2002-10-10 23:52:51 +00:00
Guy Harris cda87c4a51 Mark some fields as NDS fields.
svn path=/trunk/; revision=6409
2002-10-10 23:41:27 +00:00
Guy Harris 15c6ff4f2f Rename "ncp.nds_string" to "ncp.nds_tree_name", as it's not a generic
string, it's a tree name (as the field's display name suggests).

Get rid of the unused "ncp.nds_string_value" field.

Fix up the names of some fields, and use "proto_tree_add_uint()" rather
than "proto_tree_add_uint_format()" to add them to the protocol tree.

svn path=/trunk/; revision=6408
2002-10-10 23:32:01 +00:00
Guy Harris ce4a4b3149 Fix up the handling of bitfields in NDS messages - get rid of extra
blanks, and don't put the list of flag values in if no bits are set.

svn path=/trunk/; revision=6407
2002-10-10 23:06:00 +00:00
Guy Harris c0baecc0bb "tm_isdst" must be set to -1 before "mktime()" is called, so that
"mktime()" bases the DST-vs-non-DST decision on the date/time and on the
current time zone.

svn path=/trunk/; revision=6406
2002-10-10 21:47:12 +00:00
Guy Harris ccab7497b2 "proto_tree_add_string_format()" requires that the string value be
passed as an argument before the format string; fix some calls to do so.

svn path=/trunk/; revision=6405
2002-10-10 21:24:59 +00:00
Guy Harris d6377805f5 When deciding whether to put "NDS" into the protocol field in the packet
list, check whether the protocol field is enabled, not whether the info
field is enabled.  Update the protocol field before trying to look at
the packet, so it gets updated even for short packets.

Only parse service reply packets as NDS packets; don't parse positive
ack packets that way.

svn path=/trunk/; revision=6404
2002-10-10 21:08:45 +00:00
Guy Harris 6ea504c2e2 Remove an extra blank in the Connection Control field display.
svn path=/trunk/; revision=6403
2002-10-10 21:05:05 +00:00