From Mike Duigou:

The enclosed patch corrects a problem where jxta elements were being added to the protocol tree for segments that did not contain complete jxta frames. This patch ensures that the jxta proto elements are only added those the segments that end a complete, assembled jxta frame.

The patch has been fuzz tested with a broad selection of jxta captures and ran successfully overnight for over 4000 iterations.


svn path=/trunk/; revision=21305
This commit is contained in:
Richard van der Hoff 2007-04-03 01:31:22 +00:00
parent 4d185950d7
commit 2c14858aef
1 changed files with 7 additions and 7 deletions

View File

@ -839,13 +839,6 @@ static int dissect_jxta_stream(tvbuff_t * tvb, packet_info * pinfo, proto_tree *
goto Common_Exit;
}
jxta_tree_item =
proto_tree_add_protocol_format(tree, proto_jxta, tvb, offset, -1, "JXTA" );
jxta_tree = proto_item_add_subtree(jxta_tree_item, ett_jxta);
/* Redo header processing, this time populating the tree. */
headers_len = dissect_jxta_message_framing(tvb, pinfo, jxta_tree, &content_length, &content_type);
available = tvb_reported_length_remaining(tvb, offset + headers_len);
if (available >= content_length) {
tvbuff_t *jxta_message_tvb = tvb_new_subset(tvb, offset + headers_len, (gint) content_length, (gint) content_length);
@ -857,6 +850,13 @@ static int dissect_jxta_stream(tvbuff_t * tvb, packet_info * pinfo, proto_tree *
port_type saved_port_type = PT_NONE;
gboolean dissected;
jxta_tree_item =
proto_tree_add_protocol_format(tree, proto_jxta, tvb, offset, -1, "JXTA" );
jxta_tree = proto_item_add_subtree(jxta_tree_item, ett_jxta);
/* Redo header processing, this time populating the tree. */
headers_len = dissect_jxta_message_framing(tvb, pinfo, jxta_tree, &content_length, &content_type);
tpt_conversation = get_tpt_conversation(pinfo, TRUE);
if (NULL != tpt_conversation) {