Commit Graph

48 Commits

Author SHA1 Message Date
Guy Harris 5344a43575 Fix up the display of the "ncp.nds_time_filter" field.
svn path=/trunk/; revision=6852
2003-01-06 02:13:01 +00:00
Guy Harris 59932f2722 Don't cast away constness, and fix variable and structure member
qualifiers as necessary to ensure that we don't have to.

"strcmp()", "strcasecmp()", and "memcmp()" don't return booleans; don't
test their results as if they did.

Use "guint8", not "guchar", for a pointer to (one or more) 8-bit bytes.

Update Michael Tuexen's e-mail address.

svn path=/trunk/; revision=6726
2002-12-02 23:43:30 +00:00
Guy Harris d97d0803b3 Put in a note about the completion code not appearing to be present in
replies to continuation messages (or, at least, not present in the
obvious place).

svn path=/trunk/; revision=6470
2002-10-22 08:24:39 +00:00
Guy Harris c9900e6390 From Greg Morris:
Various NDS dissector enhancements including NDS verb 0x07, and
	proper ping flags for NDS ping version 10 request.

	Updated error codes for several NCP reply packets.

	NDPS enhancements.

svn path=/trunk/; revision=6463
2002-10-21 18:56:52 +00:00
Guy Harris 62e7954c94 Get rid of all places where "vstring" is set to point to a null string
constant, as that won't work with "get_string()" (it'll try to overwrite
the constant, and either crash, trash memory, or both).

svn path=/trunk/; revision=6460
2002-10-19 20:28:54 +00:00
Guy Harris b619b0410b From Greg Morris: put a buffer into "nw_uni_t", and make "get_string()"
fill that in.

svn path=/trunk/; revision=6456
2002-10-19 01:05:44 +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
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 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 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 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 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 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 b3af4098d2 Don't attach the string for an NDS error to the completion code - attach
the string for the completion code.  Do put the string for the NDS error
into the summary line, however.

Don't clear the NDS error code if we can't translate it to a string.

svn path=/trunk/; revision=6400
2002-10-10 03:58:47 +00:00
Guy Harris 9a4b466497 "#if 0" out the code in "get_string()", as it will probably cause
crashes on many platforms, and other random behavior on others.

Don't create a temporary tree with an NCP tree underneath it if we
already have an NCP tree; we don't want the results of a dissection to
be stuck in an invisible temporary tree if we're supposed to be
generating a protocol tree.

svn path=/trunk/; revision=6399
2002-10-10 03:25:47 +00:00
Guy Harris 9934126755 From cjs 2895: get rid of C++ comments, so IBM's Visual Age C compiler
can compile the code.

Note that Bill Fumerola rewrote the Cisco NetFlow dissector.

Update a bunch of addresses in the Ethereal man page, and put some
missing addresses in.

svn path=/trunk/; revision=6380
2002-10-08 19:19:00 +00:00
Guy Harris 488f1216ad Make some variables unsigned to remove some compiler warnings.
svn path=/trunk/; revision=6377
2002-10-08 08:58:55 +00:00
Jörg Mayer 011a6aafde Warning fixes for the ncp code by Greg Morris and J�rg Mayer.
svn path=/trunk/; revision=6338
2002-09-26 02:08:21 +00:00
Jörg Mayer 8c3a0d068f Greg Morris:
This update adds NCP 87/66.
Also add additional error codes, added hf_definition for super class
(NDS). Cleaned up some unused variables (Warnings when building
Ethereal). Fixed NCP type 0x9999 (server busy packets to echo
information to summary information), Added subtree format to NDS
dissector to cleanup display.

svn path=/trunk/; revision=6331
2002-09-25 00:37:01 +00:00
Gerald Combs a4cace5463 Fix some (but not all) compiler warnings.
svn path=/trunk/; revision=6317
2002-09-22 17:39:00 +00:00
Gerald Combs c9cdfff342 From Greg Morris: More NDS decodes.
Fix a typo in get_string().

svn path=/trunk/; revision=6313
2002-09-22 15:46:42 +00:00
Guy Harris 0aeae83ddc NDS fragment handles are 32 bits, according to Greg Morris.
svn path=/trunk/; revision=6084
2002-08-25 21:41:12 +00:00
Guy Harris ab89806eab Give the NDS Verb field a value_string table, so you can filter on it
without having to know the numerical values for the verbs.

Use that table to convert the verb value to a verb name.

Fix indentation.

svn path=/trunk/; revision=6075
2002-08-23 22:44:57 +00:00
Guy Harris 149f19d372 Note to the person who checked in the previous change: that's "already
have", not "don't have". :-)

svn path=/trunk/; revision=6074
2002-08-23 22:15:51 +00:00
Guy Harris 5357337904 In "dissect_nds_request()", if we already have a tree into which to put
items, don't create the temporary tree.

svn path=/trunk/; revision=6073
2002-08-23 22:08:50 +00:00
Gilbert Ramirez 34180e1bf2 From Greg Morris:
1. Secret Store Services (NCP 94) (ncp2222.py)
2. NMAS (NCP 92) (ncp2222.py)
3. NDS information in summary screen (packet-ncp.c & packet-ncp2222.inc)
4. Sever broadcast packets (NCP type 0xbbbb) to notify workstation to clear op-lock (packet-ncp.c)
5. Large Internet Packets (LIP) (packet-ncp.c)
6. Unicode Support. (unicode_to_string function in packet-ncp2222.inc & ncp2222.py)

svn path=/trunk/; revision=6069
2002-08-23 17:47:31 +00:00
Guy Harris e1b2d0ef85 Move the #defines for NCP packet types to "packet-ncp-int.h", and use
them in "packet-ncp2222.inc".

The page at

	http://www.odyssea.com/whats_new/tcpipnet/tcpipnet.html

indicates that a positive ACK (0x9999) NCP packet has the same
completion code and connection status fields as a reply (0x3333) packet
(but nothing after them); hand "dissect_ncp_reply()" the packet type as
one of its arguments, and have it handle positive ACK packets as well as
reply packets.

It also indicates that bit 4 of the connection status indicates that the
server is unavailable, and the page at

	http://www.unm.edu/~network/presentations/course/appendix/appendix_f/tsld088.htm

speaks of that and of the significance of other bits; put a comment in
"ncp2222.py", before the "hf_ncp_connection_status" field, about that.

From looking at a capture, it appears that a "destroy service
connection" (0x5555) packet should be treated like a "create service
connection" (0x1111) packet and be handed to "dissect_ncp_request()".

Note that perhaps watchdog packets should be handled by
"dissect_ncp_reply()" as well.

svn path=/trunk/; revision=5489
2002-05-16 09:59:52 +00:00
Gilbert Ramirez 0df97ac2b6 For response packets, add a field showing the number of the frame
containing the request packet.

svn path=/trunk/; revision=5485
2002-05-16 03:31:34 +00:00
Guy Harris d64506ff6d Put in a note about date and time formats.
svn path=/trunk/; revision=5451
2002-05-11 23:04:53 +00:00
Gilbert Ramirez 41cc7f0707 Merge the work in Novell_NCP_branch into the mainline code.
A little work still needs to be done on the new NCP dissector -- make
some of the COL_INFO texts more useful, handle a Unicode issue, and
modify some of the cases that use "request conditions".
But the NCP dissector as it stands is very usable now.

Note: I didn't merge in the PROTO_LENGTH_UNTIL_END macro... I wanted
to think about the various possible macros and review an email conversation
I had with Guy on the subject.

svn path=/trunk/; revision=5432
2002-05-09 23:50:34 +00:00
Gilbert Ramirez 3d7d008703 Remove unused variable.
svn path=/trunk/; revision=5094
2002-04-04 03:51: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
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 23319ff023 Move the pointer to the "column_info" structure in the "frame_data"
structure to the "packet_info" structure; only stuff that's permanently
stored with each frame should be in the "frame_data" structure, and the
"column_info" structure is not guaranteed to hold the column values for
that frame at all times - it was only in the "frame_data" structure so
that it could be passed to dissectors, and, as all dissectors are now
passed a pointer to a "packet_info" structure, it could just as well be
put in the "packet_info" structure.

That saves memory, by shrinking the "frame_data" structure (there's one
of those per frame), and also lets us clean up the code a bit.

svn path=/trunk/; revision=4370
2001-12-10 00:26:21 +00:00
Gilbert Ramirez f14a6b8b91 Hopefully the last time I have to change my e-mail address.
svn path=/trunk/; revision=4199
2001-11-13 23:55:44 +00:00
Guy Harris 3388bde488 Instead of having a single datum attached to a conversation, have a list
of protocol-id-plus-datum pairs, so that multiple protocols can attach
information to the same conversation.

Dissectors that attach information to a conversation should not assume
that if they find a conversation it has one of its data attached to it;
the conversation might've been created by another dissector.

svn path=/trunk/; revision=3901
2001-09-03 10:33:12 +00:00
Gilbert Ramirez c70cdb456f Handle a few of the NCP types from the traces sent in by Pete,
<psailor@uswest.net>

svn path=/trunk/; revision=3617
2001-06-28 02:42:48 +00:00
Guy Harris 563f86ee5e Support for conversations with "wildcard" destination addresses, from
Jeff Foster.

svn path=/trunk/; revision=2523
2000-10-21 05:52:28 +00:00
Gilbert Ramirez 28ac31a634 Move #included C code from an *.h file to an *.inc file.
svn path=/trunk/; revision=2456
2000-09-22 16:37:50 +00:00