Add conversation endpoint type

For the moment this mirrors the port_type enumeration (PT_XXX), but the
intent is to move away from using "port types", eliminating most (if not
all)

Added conversation_pt_to_endpoint_type() so that conversations deal with the
correct enumeration.  This is for dissector that use pinfo->ptype as input
to conversation APIs.  Explicit use of port types are converted to using
ENDPOINT_XXX type.

Change-Id: Ia0bf553a3943b702c921f185407e03ce93ebf0ef
Reviewed-on: https://code.wireshark.org/review/24166
Petri-Dish: Michael Mann <mmann78@netscape.net>
Tested-by: Petri Dish Buildbot
Reviewed-by: Michael Mann <mmann78@netscape.net>
This commit is contained in:
Michael Mann 2017-10-29 10:12:59 -04:00
parent 1bc6d4e965
commit abfb644117
92 changed files with 499 additions and 467 deletions

View File

@ -162,6 +162,7 @@ libwireshark.so.0 libwireshark0 #MINVER#
conversation_key_port1@Base 2.5.0
conversation_key_port2@Base 2.5.0
conversation_new@Base 1.9.1
conversation_pt_to_endpoint_type@Base 2.5.0
conversation_set_dissector@Base 1.9.1
conversation_set_dissector_from_frame_number@Base 2.0.0
conversation_table_get_num@Base 1.99.0

View File

@ -362,10 +362,10 @@ typedef enum {
PT_UDP, /* UDP */
PT_DCCP, /* DCCP */
PT_IPX, /* IPX sockets */
PT_NCP, /* NCP connection */
PT_NCP, /* NCP connection - XXX REMOVE XXX */
PT_EXCHG, /* Fibre Channel exchange */
PT_DDP, /* DDP AppleTalk connection */
PT_SBCCS, /* FICON */
PT_SBCCS, /* FICON - XXX REMOVE XXX */
PT_IDP, /* XNS IDP sockets */
PT_TIPC, /* TIPC PORT */
PT_USB, /* USB endpoint 0xffff means the host */

View File

@ -40,7 +40,7 @@ struct conversation_key {
struct conversation_key *next;
address addr1;
address addr2;
port_type ptype;
endpoint_type etype;
guint32 port1;
guint32 port2;
};
@ -90,7 +90,7 @@ conversation_create_from_template(conversation_t *conversation, const address *a
* CONVERSATION_TEMPLATE bit is set for a connection oriented protocol.
*/
if(conversation->options & CONVERSATION_TEMPLATE &&
conversation->key_ptr->ptype != PT_UDP)
conversation->key_ptr->etype != ENDPOINT_UDP)
{
/*
* Set up a new options mask where the conversation template bit and the
@ -113,7 +113,7 @@ conversation_create_from_template(conversation_t *conversation, const address *a
new_conversation_from_template =
conversation_new(conversation->setup_frame,
&conversation->key_ptr->addr1, addr2,
conversation->key_ptr->ptype, conversation->key_ptr->port1,
conversation->key_ptr->etype, conversation->key_ptr->port1,
port2, options);
}
else if(conversation->options & NO_PORT2)
@ -125,7 +125,7 @@ conversation_create_from_template(conversation_t *conversation, const address *a
new_conversation_from_template =
conversation_new(conversation->setup_frame,
&conversation->key_ptr->addr1, &conversation->key_ptr->addr2,
conversation->key_ptr->ptype, conversation->key_ptr->port1,
conversation->key_ptr->etype, conversation->key_ptr->port1,
port2, options);
}
else if(conversation->options & NO_ADDR2)
@ -137,7 +137,7 @@ conversation_create_from_template(conversation_t *conversation, const address *a
new_conversation_from_template =
conversation_new(conversation->setup_frame,
&conversation->key_ptr->addr1, addr2,
conversation->key_ptr->ptype, conversation->key_ptr->port1,
conversation->key_ptr->etype, conversation->key_ptr->port1,
conversation->key_ptr->port2, options);
}
else
@ -207,7 +207,7 @@ conversation_match_exact(gconstpointer v, gconstpointer w)
const conversation_key_t v1 = (const conversation_key_t)v;
const conversation_key_t v2 = (const conversation_key_t)w;
if (v1->ptype != v2->ptype)
if (v1->etype != v2->etype)
return 0; /* different types of port */
/*
@ -291,7 +291,7 @@ conversation_match_no_addr2(gconstpointer v, gconstpointer w)
const conversation_key_t v1 = (const conversation_key_t)v;
const conversation_key_t v2 = (const conversation_key_t)w;
if (v1->ptype != v2->ptype)
if (v1->etype != v2->etype)
return 0; /* different types of port */
/*
@ -355,7 +355,7 @@ conversation_match_no_port2(gconstpointer v, gconstpointer w)
const conversation_key_t v1 = (const conversation_key_t)v;
const conversation_key_t v2 = (const conversation_key_t)w;
if (v1->ptype != v2->ptype)
if (v1->etype != v2->etype)
return 0; /* different types of port */
/*
@ -417,7 +417,7 @@ conversation_match_no_addr2_or_port2(gconstpointer v, gconstpointer w)
const conversation_key_t v1 = (const conversation_key_t)v;
const conversation_key_t v2 = (const conversation_key_t)w;
if (v1->ptype != v2->ptype)
if (v1->etype != v2->etype)
return 0; /* different types of port */
/*
@ -606,8 +606,8 @@ conversation_remove_from_hashtable(wmem_map_t *hashtable, conversation_t *conv)
* when searching for this conversation.
*/
conversation_t *
conversation_new(const guint32 setup_frame, const address *addr1, const address *addr2, const port_type ptype,
const guint32 port1, const guint32 port2, const guint options)
conversation_new(const guint32 setup_frame, const address *addr1, const address *addr2,
const endpoint_type etype, const guint32 port1, const guint32 port2, const guint options)
{
/*
DISSECTOR_ASSERT(!(options | CONVERSATION_TEMPLATE) || ((options | (NO_ADDR2 | NO_PORT2 | NO_PORT2_FORCE))) &&
@ -638,7 +638,7 @@ conversation_new(const guint32 setup_frame, const address *addr1, const address
new_key = wmem_new(wmem_file_scope(), struct conversation_key);
copy_address_wmem(wmem_file_scope(), &new_key->addr1, addr1);
copy_address_wmem(wmem_file_scope(), &new_key->addr2, addr2);
new_key->ptype = ptype;
new_key->etype = etype;
new_key->port1 = port1;
new_key->port2 = port2;
@ -741,7 +741,7 @@ conversation_set_addr2(conversation_t *conv, const address *addr)
*/
static conversation_t *
conversation_lookup_hashtable(wmem_map_t *hashtable, const guint32 frame_num, const address *addr1, const address *addr2,
const port_type ptype, const guint32 port1, const guint32 port2)
const endpoint_type etype, const guint32 port1, const guint32 port2)
{
conversation_t* convo=NULL;
conversation_t* match=NULL;
@ -754,7 +754,7 @@ conversation_lookup_hashtable(wmem_map_t *hashtable, const guint32 frame_num, co
*/
key.addr1 = *addr1;
key.addr2 = *addr2;
key.ptype = ptype;
key.etype = etype;
key.port1 = port1;
key.port2 = port2;
@ -820,7 +820,7 @@ conversation_lookup_hashtable(wmem_map_t *hashtable, const guint32 frame_num, co
* otherwise, we found no matching conversation, and return NULL.
*/
conversation_t *
find_conversation(const guint32 frame_num, const address *addr_a, const address *addr_b, const port_type ptype,
find_conversation(const guint32 frame_num, const address *addr_a, const address *addr_b, const endpoint_type etype,
const guint32 port_a, const guint32 port_b, const guint options)
{
conversation_t *conversation;
@ -836,14 +836,14 @@ find_conversation(const guint32 frame_num, const address *addr_a, const address
DPRINT(("trying exact match"));
conversation =
conversation_lookup_hashtable(conversation_hashtable_exact,
frame_num, addr_a, addr_b, ptype,
frame_num, addr_a, addr_b, etype,
port_a, port_b);
/* Didn't work, try the other direction */
if (conversation == NULL) {
DPRINT(("trying opposite direction"));
conversation =
conversation_lookup_hashtable(conversation_hashtable_exact,
frame_num, addr_b, addr_a, ptype,
frame_num, addr_b, addr_a, etype,
port_b, port_a);
}
if ((conversation == NULL) && (addr_a->type == AT_FC)) {
@ -852,7 +852,7 @@ find_conversation(const guint32 frame_num, const address *addr_a, const address
*/
conversation =
conversation_lookup_hashtable(conversation_hashtable_exact,
frame_num, addr_b, addr_a, ptype,
frame_num, addr_b, addr_a, etype,
port_a, port_b);
}
DPRINT(("exact match %sfound",conversation?"":"not "));
@ -877,14 +877,14 @@ find_conversation(const guint32 frame_num, const address *addr_a, const address
DPRINT(("trying wildcarded dest address"));
conversation =
conversation_lookup_hashtable(conversation_hashtable_no_addr2,
frame_num, addr_a, addr_b, ptype, port_a, port_b);
frame_num, addr_a, addr_b, etype, port_a, port_b);
if ((conversation == NULL) && (addr_a->type == AT_FC)) {
/* In Fibre channel, OXID & RXID are never swapped as
* TCP/UDP ports are in TCP/IP.
*/
conversation =
conversation_lookup_hashtable(conversation_hashtable_no_addr2,
frame_num, addr_b, addr_a, ptype,
frame_num, addr_b, addr_a, etype,
port_a, port_b);
}
if (conversation != NULL) {
@ -900,7 +900,7 @@ find_conversation(const guint32 frame_num, const address *addr_a, const address
* address, unless the CONVERSATION_TEMPLATE option is set.)
*/
DPRINT(("wildcarded dest address match found"));
if (!(conversation->options & NO_ADDR_B) && ptype != PT_UDP)
if (!(conversation->options & NO_ADDR_B) && etype != ENDPOINT_UDP)
{
if(!(conversation->options & CONVERSATION_TEMPLATE))
{
@ -929,7 +929,7 @@ find_conversation(const guint32 frame_num, const address *addr_a, const address
DPRINT(("trying dest addr:port as source addr:port with wildcarded dest addr"));
conversation =
conversation_lookup_hashtable(conversation_hashtable_no_addr2,
frame_num, addr_b, addr_a, ptype, port_b, port_a);
frame_num, addr_b, addr_a, etype, port_b, port_a);
if (conversation != NULL) {
/*
* If this is for a connection-oriented
@ -940,7 +940,7 @@ find_conversation(const guint32 frame_num, const address *addr_a, const address
* conversation.
*/
DPRINT(("match found"));
if (ptype != PT_UDP) {
if (etype != ENDPOINT_UDP) {
if(!(conversation->options & CONVERSATION_TEMPLATE))
{
conversation_set_addr2(conversation, addr_a);
@ -973,14 +973,14 @@ find_conversation(const guint32 frame_num, const address *addr_a, const address
DPRINT(("trying wildcarded dest port"));
conversation =
conversation_lookup_hashtable(conversation_hashtable_no_port2,
frame_num, addr_a, addr_b, ptype, port_a, port_b);
frame_num, addr_a, addr_b, etype, port_a, port_b);
if ((conversation == NULL) && (addr_a->type == AT_FC)) {
/* In Fibre channel, OXID & RXID are never swapped as
* TCP/UDP ports are in TCP/IP
*/
conversation =
conversation_lookup_hashtable(conversation_hashtable_no_port2,
frame_num, addr_b, addr_a, ptype, port_a, port_b);
frame_num, addr_b, addr_a, etype, port_a, port_b);
}
if (conversation != NULL) {
/*
@ -995,7 +995,7 @@ find_conversation(const guint32 frame_num, const address *addr_a, const address
* unless the CONVERSATION_TEMPLATE option is set.)
*/
DPRINT(("match found"));
if (!(conversation->options & NO_PORT_B) && ptype != PT_UDP)
if (!(conversation->options & NO_PORT_B) && etype != ENDPOINT_UDP)
{
if(!(conversation->options & CONVERSATION_TEMPLATE))
{
@ -1024,7 +1024,7 @@ find_conversation(const guint32 frame_num, const address *addr_a, const address
DPRINT(("trying dest addr:port as source addr:port and wildcarded dest port"));
conversation =
conversation_lookup_hashtable(conversation_hashtable_no_port2,
frame_num, addr_b, addr_a, ptype, port_b, port_a);
frame_num, addr_b, addr_a, etype, port_b, port_a);
if (conversation != NULL) {
/*
* If this is for a connection-oriented
@ -1035,7 +1035,7 @@ find_conversation(const guint32 frame_num, const address *addr_a, const address
* conversation.
*/
DPRINT(("match found"));
if (ptype != PT_UDP)
if (etype != ENDPOINT_UDP)
{
if(!(conversation->options & CONVERSATION_TEMPLATE))
{
@ -1063,7 +1063,7 @@ find_conversation(const guint32 frame_num, const address *addr_a, const address
DPRINT(("trying wildcarding dest addr:port"));
conversation =
conversation_lookup_hashtable(conversation_hashtable_no_addr2_or_port2,
frame_num, addr_a, addr_b, ptype, port_a, port_b);
frame_num, addr_a, addr_b, etype, port_a, port_b);
if (conversation != NULL) {
/*
* If this is for a connection-oriented protocol:
@ -1079,7 +1079,7 @@ find_conversation(const guint32 frame_num, const address *addr_a, const address
* second port for this conversation.
*/
DPRINT(("match found"));
if (ptype != PT_UDP)
if (etype != ENDPOINT_UDP)
{
if(!(conversation->options & CONVERSATION_TEMPLATE))
{
@ -1101,7 +1101,7 @@ find_conversation(const guint32 frame_num, const address *addr_a, const address
* valid conversation than what is being searched using
* addr_a, port_a.
*/
if (ptype != PT_IBQP)
if (etype != ENDPOINT_IBQP)
{
/*
@ -1117,11 +1117,11 @@ find_conversation(const guint32 frame_num, const address *addr_a, const address
if (addr_a->type == AT_FC)
conversation =
conversation_lookup_hashtable(conversation_hashtable_no_addr2_or_port2,
frame_num, addr_b, addr_a, ptype, port_a, port_b);
frame_num, addr_b, addr_a, etype, port_a, port_b);
else
conversation =
conversation_lookup_hashtable(conversation_hashtable_no_addr2_or_port2,
frame_num, addr_b, addr_a, ptype, port_b, port_a);
frame_num, addr_b, addr_a, etype, port_b, port_a);
if (conversation != NULL) {
/*
* If this is for a connection-oriented protocol, set the
@ -1133,7 +1133,7 @@ find_conversation(const guint32 frame_num, const address *addr_a, const address
* conversation.
*/
DPRINT(("match found"));
if (ptype != PT_UDP)
if (etype != ENDPOINT_UDP)
{
if(!(conversation->options & CONVERSATION_TEMPLATE))
{
@ -1213,13 +1213,13 @@ conversation_get_dissector(conversation_t *conversation, const guint32 frame_num
* this function returns FALSE.
*/
gboolean
try_conversation_dissector(const address *addr_a, const address *addr_b, const port_type ptype,
try_conversation_dissector(const address *addr_a, const address *addr_b, const endpoint_type etype,
const guint32 port_a, const guint32 port_b, tvbuff_t *tvb, packet_info *pinfo,
proto_tree *tree, void* data)
{
conversation_t *conversation;
conversation = find_conversation(pinfo->num, addr_a, addr_b, ptype, port_a,
conversation = find_conversation(pinfo->num, addr_a, addr_b, etype, port_a,
port_b, 0);
if (conversation != NULL) {
@ -1255,7 +1255,7 @@ find_conversation_pinfo(packet_info *pinfo, const guint options)
/* Have we seen this conversation before? */
if((conv = find_conversation(pinfo->num, &pinfo->src, &pinfo->dst,
pinfo->ptype, pinfo->srcport,
conversation_pt_to_endpoint_type(pinfo->ptype), pinfo->srcport,
pinfo->destport, options)) != NULL) {
DPRINT(("found previous conversation for frame #%d (last_frame=%d)",
pinfo->num, conv->last_frame));
@ -1285,7 +1285,7 @@ find_or_create_conversation(packet_info *pinfo)
pinfo->num));
DINDENT();
conv = conversation_new(pinfo->num, &pinfo->src,
&pinfo->dst, pinfo->ptype,
&pinfo->dst, conversation_pt_to_endpoint_type(pinfo->ptype),
pinfo->srcport, pinfo->destport, 0);
DENDENT();
}
@ -1343,6 +1343,51 @@ conversation_key_port2(const conversation_key_t key)
return key->port2;
}
WS_DLL_PUBLIC
endpoint_type conversation_pt_to_endpoint_type(port_type pt)
{
switch (pt)
{
case PT_NONE:
return ENDPOINT_NONE;
case PT_SCTP:
return ENDPOINT_SCTP;
case PT_TCP:
return ENDPOINT_TCP;
case PT_UDP:
return ENDPOINT_UDP;
case PT_DCCP:
return ENDPOINT_DCCP;
case PT_IPX:
return ENDPOINT_IPX;
case PT_NCP:
return ENDPOINT_NCP;
case PT_EXCHG:
return ENDPOINT_EXCHG;
case PT_DDP:
return ENDPOINT_DDP;
case PT_IDP:
return ENDPOINT_IDP;
case PT_TIPC:
return ENDPOINT_TIPC;
case PT_USB:
return ENDPOINT_USB;
case PT_I2C:
return ENDPOINT_I2C;
case PT_IBQP:
return ENDPOINT_IBQP;
case PT_SBCCS:
return ENDPOINT_SBCCS;
case PT_BLUETOOTH:
return ENDPOINT_BLUETOOTH;
case PT_TDMOP:
return ENDPOINT_TDMOP;
}
DISSECTOR_ASSERT(FALSE);
return ENDPOINT_NONE;
}
gchar*
conversation_get_html_hash(const conversation_key_t key)
{

View File

@ -57,6 +57,27 @@ extern "C" {
#include "packet.h" /* for conversation dissector type */
/* Types of port numbers Wireshark knows about. */
typedef enum {
ENDPOINT_NONE, /* no endpoint */
ENDPOINT_SCTP, /* SCTP */
ENDPOINT_TCP, /* TCP */
ENDPOINT_UDP, /* UDP */
ENDPOINT_DCCP, /* DCCP */
ENDPOINT_IPX, /* IPX sockets */
ENDPOINT_NCP, /* NCP connection */
ENDPOINT_EXCHG, /* Fibre Channel exchange */
ENDPOINT_DDP, /* DDP AppleTalk connection */
ENDPOINT_SBCCS, /* FICON */
ENDPOINT_IDP, /* XNS IDP sockets */
ENDPOINT_TIPC, /* TIPC PORT */
ENDPOINT_USB, /* USB endpoint 0xffff means the host */
ENDPOINT_I2C,
ENDPOINT_IBQP, /* Infiniband QP number */
ENDPOINT_BLUETOOTH,
ENDPOINT_TDMOP
} endpoint_type;
/**
* Data structure representing a conversation.
*/
@ -104,7 +125,7 @@ extern void conversation_epan_reset(void);
* when searching for this conversation.
*/
WS_DLL_PUBLIC conversation_t *conversation_new(const guint32 setup_frame, const address *addr1, const address *addr2,
const port_type ptype, const guint32 port1, const guint32 port2, const guint options);
const endpoint_type etype, const guint32 port1, const guint32 port2, const guint options);
/**
* Given two address/port pairs for a packet, search for a conversation
@ -143,7 +164,7 @@ WS_DLL_PUBLIC conversation_t *conversation_new(const guint32 setup_frame, const
* otherwise, we found no matching conversation, and return NULL.
*/
WS_DLL_PUBLIC conversation_t *find_conversation(const guint32 frame_num, const address *addr_a, const address *addr_b,
const port_type ptype, const guint32 port_a, const guint32 port_b, const guint options);
const endpoint_type etype, const guint32 port_a, const guint32 port_b, const guint options);
/** A helper function that calls find_conversation() using data from pinfo
* The frame number and addresses are taken from pinfo.
@ -183,7 +204,7 @@ WS_DLL_PUBLIC dissector_handle_t conversation_get_dissector(conversation_t *conv
* this function returns FALSE.
*/
extern gboolean
try_conversation_dissector(const address *addr_a, const address *addr_b, const port_type ptype,
try_conversation_dissector(const address *addr_a, const address *addr_b, const endpoint_type etype,
const guint32 port_a, const guint32 port_b, tvbuff_t *tvb, packet_info *pinfo,
proto_tree *tree, void* data);
@ -204,6 +225,13 @@ wmem_map_t * get_conversation_hashtable_no_port2(void);
WS_DLL_PUBLIC
wmem_map_t *get_conversation_hashtable_no_addr2_or_port2(void);
/* Temporary function to handle port_type to endpoint_type conversion
For now it's a 1-1 mapping, but the intention is to remove
many of the port_type instances in favor of endpoint_type
*/
WS_DLL_PUBLIC
endpoint_type conversation_pt_to_endpoint_type(port_type pt);
WS_DLL_PUBLIC guint
conversation_hash_exact(gconstpointer v);

View File

@ -581,9 +581,9 @@ IsupNumber/nationalStandardPartyNumber isupNationalStandardPartyNumber
return offset;
}
conv=find_conversation(actx->pinfo->num, &src_addr, &src_addr, PT_TCP, ip_port, ip_port, NO_ADDR_B|NO_PORT_B);
conv=find_conversation(actx->pinfo->num, &src_addr, &src_addr, ENDPOINT_TCP, ip_port, ip_port, NO_ADDR_B|NO_PORT_B);
if(!conv){
conv=conversation_new(actx->pinfo->num, &src_addr, &src_addr, PT_TCP, ip_port, ip_port, NO_ADDR2|NO_PORT2);
conv=conversation_new(actx->pinfo->num, &src_addr, &src_addr, ENDPOINT_TCP, ip_port, ip_port, NO_ADDR2|NO_PORT2);
conversation_set_dissector(conv, h245_handle);
}
}

View File

@ -364,10 +364,10 @@ AuthorizationData/_item/ad-type STRINGS=VALS(krb5_ad_types)
* http://www.ietf.org/internet-drafts/draft-ietf-krb-wg-kerberos-clarifications-07.txt
*/
if (actx->pinfo->destport == UDP_PORT_KERBEROS && actx->pinfo->ptype == PT_UDP) {
conversation = find_conversation(actx->pinfo->num, &actx->pinfo->src, &actx->pinfo->dst, PT_UDP,
conversation = find_conversation(actx->pinfo->num, &actx->pinfo->src, &actx->pinfo->dst, ENDPOINT_UDP,
actx->pinfo->srcport, 0, NO_PORT_B);
if (conversation == NULL) {
conversation = conversation_new(actx->pinfo->num, &actx->pinfo->src, &actx->pinfo->dst, PT_UDP,
conversation = conversation_new(actx->pinfo->num, &actx->pinfo->src, &actx->pinfo->dst, ENDPOINT_UDP,
actx->pinfo->srcport, 0, NO_PORT2);
conversation_set_dissector(conversation, kerberos_handle_udp);
}

View File

@ -836,7 +836,7 @@ private_data_set_transport_format_set_type(actx->pinfo, NBAP_CPCH);
set_address(&dst_addr, AT_IPv4, 4, &transportLayerAddress_ipv4);
conversation = conversation_new(actx->pinfo->num, &dst_addr, &null_addr, PT_UDP, bindingID, 0, NO_ADDR2|NO_PORT2);
conversation = conversation_new(actx->pinfo->num, &dst_addr, &null_addr, ENDPOINT_UDP, bindingID, 0, NO_ADDR2|NO_PORT2);
conversation_set_dissector(conversation, fp_handle);
@ -938,7 +938,7 @@ private_data_set_num_items(actx->pinfo, 1);
set_address(&dst_addr, AT_IPv4, 4, &transportLayerAddress_ipv4);
conversation = conversation_new(actx->pinfo->num, &dst_addr, &null_addr, PT_UDP, bindingID, 0, NO_ADDR2|NO_PORT2);
conversation = conversation_new(actx->pinfo->num, &dst_addr, &null_addr, ENDPOINT_UDP, bindingID, 0, NO_ADDR2|NO_PORT2);
/* Set dissector */
conversation_set_dissector(conversation, fp_handle);
@ -1048,7 +1048,7 @@ private_data_set_transport_format_set_type(actx->pinfo, NBAP_CPCH);
set_address(&dst_addr, AT_IPv4, 4, &transportLayerAddress_ipv4);
conversation = conversation_new(actx->pinfo->num, &dst_addr, &null_addr, PT_UDP, bindingID, 0, NO_ADDR2|NO_PORT2);
conversation = conversation_new(actx->pinfo->num, &dst_addr, &null_addr, ENDPOINT_UDP, bindingID, 0, NO_ADDR2|NO_PORT2);
/* Set dissector */
conversation_set_dissector(conversation, fp_handle);
@ -1290,14 +1290,14 @@ private_data_set_dch_id(actx->pinfo, 0xFFFFFFFF);
set_address(&dst_addr, AT_IPv4, 4, &transportLayerAddress_ipv4);
conversation = find_conversation(actx->pinfo->num,&dst_addr,
&null_addr, PT_UDP,private_data_get_binding_id_port(actx->pinfo),
conversation = find_conversation(actx->pinfo->num, &dst_addr,
&null_addr, ENDPOINT_UDP, private_data_get_binding_id_port(actx->pinfo),
0, NO_ADDR_B|NO_PORT_B);
if (conversation == NULL) {
/* It's not part of any conversation - create a new one. */
conversation = conversation_new(actx->pinfo->num, &dst_addr,
&null_addr, PT_UDP,private_data_get_binding_id_port(actx->pinfo),
&null_addr, ENDPOINT_UDP, private_data_get_binding_id_port(actx->pinfo),
0, NO_ADDR2|NO_PORT2);
/* Set dissector */
@ -1407,8 +1407,8 @@ private_data_set_binding_id_port(actx->pinfo, 0);
set_address(&dst_addr, AT_IPv4, 4, &transportLayerAddress_ipv4);
conversation = find_conversation(actx->pinfo->num,&dst_addr,
&null_addr, PT_UDP, bindingID,
conversation = find_conversation(actx->pinfo->num, &dst_addr,
&null_addr, ENDPOINT_UDP, bindingID,
0, NO_ADDR_B|NO_PORT_B);
if (conversation) {
umts_fp_conversation_info = (umts_fp_conversation_info_t*)conversation_get_proto_data(conversation, proto_fp);
@ -1423,7 +1423,7 @@ private_data_set_binding_id_port(actx->pinfo, 0);
/* It's not part of any conversation - create a new one. */
conversation = conversation_new(actx->pinfo->num, &dst_addr,
&null_addr, PT_UDP, bindingID,
&null_addr, ENDPOINT_UDP, bindingID,
0, NO_ADDR2|NO_PORT2);
/* Set dissector */
@ -1518,8 +1518,7 @@ nbap_edch_channel_info = private_data_get_nbap_edch_channel_info(actx->pinfo);
e_dch_macdflow_id = private_data_get_e_dch_macdflow_id(actx->pinfo);
clear_address(&null_addr);
p_conv = find_conversation(actx->pinfo->num, &nbap_edch_channel_info[e_dch_macdflow_id].crnc_address, &null_addr,
PT_UDP,
nbap_edch_channel_info[e_dch_macdflow_id].crnc_port, 0, NO_ADDR_B);
ENDPOINT_UDP, nbap_edch_channel_info[e_dch_macdflow_id].crnc_port, 0, NO_ADDR_B);
if(!p_conv)
return offset;
@ -1585,8 +1584,8 @@ private_data_set_binding_id_port(actx->pinfo, 0);
set_address(&dst_addr, AT_IPv4, 4, &transportLayerAddress_ipv4);
old_conversation = find_conversation(actx->pinfo->num,&dst_addr,
&null_addr, PT_UDP, bindingID,
old_conversation = find_conversation(actx->pinfo->num, &dst_addr,
&null_addr, ENDPOINT_UDP, bindingID,
0, NO_ADDR_B|NO_PORT_B);
if(old_conversation){
@ -1601,7 +1600,7 @@ private_data_set_binding_id_port(actx->pinfo, 0);
/* It's not part of any conversation - create a new one. */
conversation = conversation_new(actx->pinfo->num, &dst_addr,
&null_addr, PT_UDP, bindingID,
&null_addr, ENDPOINT_UDP, bindingID,
0, NO_ADDR2|NO_PORT2);
/* Set dissector */
@ -1710,8 +1709,7 @@ private_data_set_num_items(actx->pinfo, 1);
/* Check if we have conversation info */
clear_address(&null_addr);
p_conv = find_conversation(actx->pinfo->num, &nbap_edch_channel_info[e_dch_macdflow_id].crnc_address, &null_addr,
PT_UDP,
nbap_edch_channel_info[e_dch_macdflow_id].crnc_port, 0, NO_ADDR_B);
ENDPOINT_UDP, nbap_edch_channel_info[e_dch_macdflow_id].crnc_port, 0, NO_ADDR_B);
if(!p_conv)
return offset;
@ -1987,15 +1985,14 @@ nbap_hsdsch_channel_info = private_data_get_nbap_hsdsch_channel_info(actx->pinfo
address_to_str (wmem_packet_scope(), &(nbap_hsdsch_channel_info[i].crnc_address)),
nbap_hsdsch_channel_info[i].crnc_port);
conversation = find_conversation(actx->pinfo->num, &(nbap_hsdsch_channel_info[i].crnc_address), &null_addr,
PT_UDP,
nbap_hsdsch_channel_info[i].crnc_port, 0, NO_ADDR_B);
ENDPOINT_UDP, nbap_hsdsch_channel_info[i].crnc_port, 0, NO_ADDR_B);
if (conversation == NULL) {
/* It's not part of any conversation - create a new one. */
nbap_debug("Frame %%u HSDSCH-MACdFlows-Information: Set up conv on Port %%u", actx->pinfo->num, nbap_hsdsch_channel_info[i].crnc_port);
conversation = conversation_new(actx->pinfo->num, &(nbap_hsdsch_channel_info[i].crnc_address),
&null_addr, PT_UDP, nbap_hsdsch_channel_info[i].crnc_port,
&null_addr, ENDPOINT_UDP, nbap_hsdsch_channel_info[i].crnc_port,
0, NO_ADDR2|NO_PORT2);
/* Set dissector */
@ -2117,8 +2114,7 @@ nbap_hsdsch_channel_info = private_data_get_nbap_hsdsch_channel_info(actx->pinfo
address_to_str (wmem_packet_scope(), &(nbap_hsdsch_channel_info[i].crnc_address)),
nbap_hsdsch_channel_info[i].crnc_port);
conversation = find_conversation(actx->pinfo->num, &(nbap_hsdsch_channel_info[i].crnc_address), &null_addr,
PT_UDP,
nbap_hsdsch_channel_info[i].crnc_port, 0, NO_ADDR_B);
ENDPOINT_UDP, nbap_hsdsch_channel_info[i].crnc_port, 0, NO_ADDR_B);
if (conversation == NULL) {
@ -2126,7 +2122,7 @@ nbap_hsdsch_channel_info = private_data_get_nbap_hsdsch_channel_info(actx->pinfo
nbap_debug(" Set up conv on Port %%u", nbap_hsdsch_channel_info[i].crnc_port);
conversation = conversation_new(actx->pinfo->num, &(nbap_hsdsch_channel_info[i].crnc_address),
&null_addr, PT_UDP, nbap_hsdsch_channel_info[i].crnc_port,
&null_addr, ENDPOINT_UDP, nbap_hsdsch_channel_info[i].crnc_port,
0, NO_ADDR2|NO_PORT2);
/* Set dissector */
@ -2261,12 +2257,11 @@ int i;
if (nbap_common_channel_info[i].crnc_port != 0){
conversation = find_conversation(actx->pinfo->num, &(nbap_common_channel_info[i].crnc_address), &null_addr,
PT_UDP,
nbap_common_channel_info[i].crnc_port, 0, NO_ADDR_B);
ENDPOINT_UDP, nbap_common_channel_info[i].crnc_port, 0, NO_ADDR_B);
if (conversation == NULL) {
conversation = conversation_new(actx->pinfo->num, &(nbap_common_channel_info[i].crnc_address),
&null_addr, PT_UDP, nbap_common_channel_info[i].crnc_port,
&null_addr, ENDPOINT_UDP, nbap_common_channel_info[i].crnc_port,
0, NO_ADDR2|NO_PORT2);
/* Set dissector */
@ -2365,8 +2360,7 @@ nbap_hsdsch_channel_info = private_data_get_nbap_hsdsch_channel_info(actx->pinfo
for (i = 0; i < maxNrOfMACdFlows; i++) {
if (nbap_hsdsch_channel_info[i].crnc_port != 0){
conversation = find_conversation(actx->pinfo->num, &(nbap_hsdsch_channel_info[i].crnc_address), &null_addr,
PT_UDP,
nbap_hsdsch_channel_info[i].crnc_port, 0, NO_ADDR_B);
ENDPOINT_UDP, nbap_hsdsch_channel_info[i].crnc_port, 0, NO_ADDR_B);
if(conversation != NULL){
umts_fp_conversation_info = (umts_fp_conversation_info_t *)conversation_get_proto_data(conversation, proto_fp);
DISSECTOR_ASSERT(umts_fp_conversation_info != NULL);

View File

@ -847,12 +847,12 @@ static void add_hsdsch_bind(packet_info *pinfo){
clear_address(&null_addr);
for (i = 0; i < maxNrOfMACdFlows; i++) {
if (nbap_hsdsch_channel_info[i].crnc_port != 0){
conversation = find_conversation(pinfo->num, &(nbap_hsdsch_channel_info[i].crnc_address), &null_addr, PT_UDP,
conversation = find_conversation(pinfo->num, &(nbap_hsdsch_channel_info[i].crnc_address), &null_addr, ENDPOINT_UDP,
nbap_hsdsch_channel_info[i].crnc_port, 0, NO_ADDR_B);
if (conversation == NULL) {
/* It's not part of any conversation - create a new one. */
conversation = conversation_new(pinfo->num, &(nbap_hsdsch_channel_info[i].crnc_address), &null_addr, PT_UDP,
conversation = conversation_new(pinfo->num, &(nbap_hsdsch_channel_info[i].crnc_address), &null_addr, ENDPOINT_UDP,
nbap_hsdsch_channel_info[i].crnc_port, 0, NO_ADDR2|NO_PORT2);
/* Set dissector */

View File

@ -278,9 +278,7 @@ ros_match_call_response(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, gui
conversation_t *conversation;
/* first see if we have already matched this */
conversation = find_conversation(pinfo->num, &pinfo->src, &pinfo->dst,
pinfo->ptype, pinfo->srcport,
pinfo->destport, 0);
conversation = find_conversation_pinfo(pinfo, 0);
if (conversation == NULL)
return NULL;

View File

@ -1039,7 +1039,7 @@ HNBName TYPE=FT_STRING DISPLAY=STR_UNICODE
/* Finding FP conversation info */
p_conv = (conversation_t *)find_conversation(actx->pinfo->num, &actx->pinfo->net_dst, &actx->pinfo->net_src,
actx->pinfo->ptype,
conversation_pt_to_endpoint_type(actx->pinfo->ptype),
actx->pinfo->destport, actx->pinfo->srcport, NO_ADDR_B);
/* If the current FP channel is FACH, Adding the C-RNTI / U-RNTI match to the FACH's RNTIs map*/

View File

@ -2033,10 +2033,10 @@ dissect_snmp(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, void *data _U_
* wildcarded, and give it the SNMP dissector as a dissector.
*/
if (pinfo->destport == UDP_PORT_SNMP) {
conversation = find_conversation(pinfo->num, &pinfo->src, &pinfo->dst, PT_UDP,
conversation = find_conversation(pinfo->num, &pinfo->src, &pinfo->dst, ENDPOINT_UDP,
pinfo->srcport, 0, NO_PORT_B);
if( (conversation == NULL) || (conversation_get_dissector(conversation, pinfo->num)!=snmp_handle) ) {
conversation = conversation_new(pinfo->num, &pinfo->src, &pinfo->dst, PT_UDP,
conversation = conversation_new(pinfo->num, &pinfo->src, &pinfo->dst, ENDPOINT_UDP,
pinfo->srcport, 0, NO_PORT2);
conversation_set_dissector(conversation, snmp_handle);
}

View File

@ -223,14 +223,14 @@ void t38_add_address(packet_info *pinfo,
* Check if the ip address and port combination is not
* already registered as a conversation.
*/
p_conversation = find_conversation( setup_frame_number, addr, &null_addr, PT_UDP, port, other_port,
p_conversation = find_conversation( setup_frame_number, addr, &null_addr, ENDPOINT_UDP, port, other_port,
NO_ADDR_B | (!other_port ? NO_PORT_B : 0));
/*
* If not, create a new conversation.
*/
if ( !p_conversation || p_conversation->setup_frame != setup_frame_number) {
p_conversation = conversation_new( setup_frame_number, addr, &null_addr, PT_UDP,
p_conversation = conversation_new( setup_frame_number, addr, &null_addr, ENDPOINT_UDP,
(guint32)port, (guint32)other_port,
NO_ADDR2 | (!other_port ? NO_PORT2 : 0));
}
@ -418,13 +418,13 @@ init_t38_info_conv(packet_info *pinfo)
/* find the conversation used for Reassemble and Setup Info */
p_conv = find_conversation(pinfo->num, &pinfo->net_dst, &pinfo->net_src,
pinfo->ptype,
conversation_pt_to_endpoint_type(pinfo->ptype),
pinfo->destport, pinfo->srcport, NO_ADDR_B | NO_PORT_B);
/* create a conv if it doen't exist */
if (!p_conv) {
p_conv = conversation_new(pinfo->num, &pinfo->net_src, &pinfo->net_dst,
pinfo->ptype, pinfo->srcport, pinfo->destport, NO_ADDR_B | NO_PORT_B);
conversation_pt_to_endpoint_type(pinfo->ptype), pinfo->srcport, pinfo->destport, NO_ADDR_B | NO_PORT_B);
/* Set dissector */
conversation_set_dissector(p_conv, t38_udp_handle);

View File

@ -288,7 +288,6 @@ typedef struct
{
address * addr1;
address * addr2;
port_type ptype;
guint16 port1;
guint16 port2;
} aeron_conversation_info_t;
@ -397,10 +396,10 @@ static aeron_transport_t * aeron_transport_add(const aeron_conversation_info_t *
conversation_t * conv;
wmem_map_t * session_map;
conv = find_conversation(frame, cinfo->addr1, cinfo->addr2, cinfo->ptype, cinfo->port1, cinfo->port2, 0);
conv = find_conversation(frame, cinfo->addr1, cinfo->addr2, ENDPOINT_UDP, cinfo->port1, cinfo->port2, 0);
if (conv == NULL)
{
conv = conversation_new(frame, cinfo->addr1, cinfo->addr2, cinfo->ptype, cinfo->port1, cinfo->port2, 0);
conv = conversation_new(frame, cinfo->addr1, cinfo->addr2, ENDPOINT_UDP, cinfo->port1, cinfo->port2, 0);
}
if (frame > conv->last_frame)
{
@ -676,17 +675,7 @@ static char * aeron_format_transport_uri(const aeron_conversation_info_t * cinfo
{
wmem_strbuf_t * uri;
uri = wmem_strbuf_new(wmem_packet_scope(), "aeron:");
switch (cinfo->ptype)
{
case PT_UDP:
wmem_strbuf_append(uri, "udp");
break;
default:
wmem_strbuf_append(uri, "unknown");
break;
}
wmem_strbuf_append_c(uri, '?');
uri = wmem_strbuf_new(wmem_packet_scope(), "aeron:udp?");
if (aeron_is_address_multicast(cinfo->addr2))
{
switch (cinfo->addr2->type)
@ -858,7 +847,6 @@ static aeron_conversation_info_t * aeron_setup_conversation_info(const packet_in
int addr_len = pinfo->dst.len;
cinfo = wmem_new0(wmem_packet_scope(), aeron_conversation_info_t);
cinfo->ptype = pinfo->ptype;
switch (pinfo->dst.type)
{
case AT_IPv4:

View File

@ -858,7 +858,7 @@ dissect_atp(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, void* data _U_)
call_dissector_with_data(sub, new_tvb, pinfo, tree, &aspinfo);
conversation_set_dissector(conversation, sub);
}
else if (!try_conversation_dissector(&pinfo->src, &pinfo->dst, pinfo->ptype,
else if (!try_conversation_dissector(&pinfo->src, &pinfo->dst, conversation_pt_to_endpoint_type(pinfo->ptype),
pinfo->srcport, pinfo->destport, new_tvb,pinfo, tree, &aspinfo)) {
call_data_dissector(new_tvb, pinfo, tree);

View File

@ -2393,7 +2393,7 @@ get_conversation(packet_info *pinfo,
conversation = find_conversation(pinfo->num,
src_addr, dst_addr,
pinfo->ptype,
ENDPOINT_BLUETOOTH,
src_endpoint, dst_endpoint, 0);
if (conversation) {
return conversation;
@ -2401,7 +2401,7 @@ get_conversation(packet_info *pinfo,
conversation = conversation_new(pinfo->num,
src_addr, dst_addr,
pinfo->ptype,
ENDPOINT_BLUETOOTH,
src_endpoint, dst_endpoint, 0);
return conversation;
}

View File

@ -285,7 +285,7 @@ find_or_create_conversation_noaddrb(packet_info *pinfo, gboolean request)
}
/* Have we seen this conversation before? */
if((conv = find_conversation(pinfo->num, addr_a, addr_b,
pinfo->ptype, port_a,
conversation_pt_to_endpoint_type(pinfo->ptype), port_a,
port_b, NO_ADDR_B|NO_PORT_B)) != NULL) {
if (pinfo->num > conv->last_frame) {
conv->last_frame = pinfo->num;
@ -293,7 +293,7 @@ find_or_create_conversation_noaddrb(packet_info *pinfo, gboolean request)
} else {
/* No, this is a new conversation. */
conv = conversation_new(pinfo->num, &pinfo->src,
&pinfo->dst, pinfo->ptype,
&pinfo->dst, conversation_pt_to_endpoint_type(pinfo->ptype),
pinfo->srcport, pinfo->destport, NO_ADDR_B|NO_PORT_B);
}
return conv;

View File

@ -249,7 +249,7 @@ decode_dccp_ports(tvbuff_t *tvb, int offset, packet_info *pinfo,
* determine if this packet is part of a conversation and call dissector
* for the conversation if available
*/
if (try_conversation_dissector(&pinfo->src, &pinfo->dst, PT_DCCP, sport,
if (try_conversation_dissector(&pinfo->src, &pinfo->dst, ENDPOINT_DCCP, sport,
dport, next_tvb, pinfo, tree, NULL)) {
return;
}

View File

@ -758,7 +758,7 @@ dcerpc_add_conv_to_bind_table(decode_dcerpc_bind_values_t *binding)
0,
&binding->addr_a,
&binding->addr_b,
binding->ptype,
conversation_pt_to_endpoint_type(binding->ptype),
binding->port_a,
binding->port_b,
0);
@ -768,7 +768,7 @@ dcerpc_add_conv_to_bind_table(decode_dcerpc_bind_values_t *binding)
0,
&binding->addr_a,
&binding->addr_b,
binding->ptype,
conversation_pt_to_endpoint_type(binding->ptype),
binding->port_a,
binding->port_b,
0);

View File

@ -5733,17 +5733,17 @@ static int dissect_dof_udp(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree,
} */
/* Register the source address as being DPS for the sender UDP port. */
conversation = find_conversation(pinfo->fd->num, &pinfo->src, &pinfo->dst, pinfo->ptype, pinfo->srcport, pinfo->destport, NO_ADDR_B | NO_PORT_B);
conversation = find_conversation(pinfo->fd->num, &pinfo->src, &pinfo->dst, conversation_pt_to_endpoint_type(pinfo->ptype), pinfo->srcport, pinfo->destport, NO_ADDR_B | NO_PORT_B);
if (!conversation)
{
conversation = conversation_new(pinfo->fd->num, &pinfo->src, &pinfo->dst, pinfo->ptype, pinfo->srcport, pinfo->destport, NO_ADDR_B | NO_PORT_B);
conversation = conversation_new(pinfo->fd->num, &pinfo->src, &pinfo->dst, conversation_pt_to_endpoint_type(pinfo->ptype), pinfo->srcport, pinfo->destport, NO_ADDR_B | NO_PORT_B);
conversation_set_dissector(conversation, dof_udp_handle);
}
/* Find or create the conversation for this transport session. For UDP, the transport session is determined entirely by the
* server port. This assumes that the first packet seen is from a client to the server.
*/
conversation = find_conversation(pinfo->fd->num, &pinfo->dst, &pinfo->src, PT_UDP, pinfo->destport, pinfo->srcport, NO_ADDR_B | NO_PORT_B);
conversation = find_conversation(pinfo->fd->num, &pinfo->dst, &pinfo->src, ENDPOINT_UDP, pinfo->destport, pinfo->srcport, NO_ADDR_B | NO_PORT_B);
if (conversation)
{
/* TODO: Determine if this is valid or not. */
@ -5752,7 +5752,7 @@ static int dissect_dof_udp(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree,
}
if (!conversation)
conversation = conversation_new(pinfo->fd->num, &pinfo->dst, &pinfo->src, PT_UDP, pinfo->destport, pinfo->srcport, NO_ADDR2 | NO_PORT2 | CONVERSATION_TEMPLATE);
conversation = conversation_new(pinfo->fd->num, &pinfo->dst, &pinfo->src, ENDPOINT_UDP, pinfo->destport, pinfo->srcport, NO_ADDR2 | NO_PORT2 | CONVERSATION_TEMPLATE);
transport_session = (udp_session_data *)conversation_get_proto_data(conversation, proto_2008_1_dof_udp);
if (transport_session == NULL)

View File

@ -819,22 +819,22 @@ dissect_eap(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, void *data _U_)
*/
if (!eap_maybe_from_server(pinfo, eap_code, FALSE)) {
conversation = find_conversation(pinfo->num, &pinfo->dst, &pinfo->src,
pinfo->ptype, pinfo->destport,
conversation_pt_to_endpoint_type(pinfo->ptype), pinfo->destport,
0, NO_PORT_B);
}
if (conversation == NULL && eap_maybe_from_server(pinfo, eap_code, TRUE)) {
conversation = find_conversation(pinfo->num, &pinfo->src, &pinfo->dst,
pinfo->ptype, pinfo->srcport,
conversation_pt_to_endpoint_type(pinfo->ptype), pinfo->srcport,
0, NO_PORT_B);
}
if (conversation == NULL) {
if (!eap_maybe_from_server(pinfo, eap_code, FALSE)) {
conversation = conversation_new(pinfo->num, &pinfo->dst, &pinfo->src,
pinfo->ptype, pinfo->destport,
conversation_pt_to_endpoint_type(pinfo->ptype), pinfo->destport,
0, NO_PORT2);
} else {
conversation = conversation_new(pinfo->num, &pinfo->src, &pinfo->dst,
pinfo->ptype, pinfo->srcport,
conversation_pt_to_endpoint_type(pinfo->ptype), pinfo->srcport,
0, NO_PORT2);
}
}

View File

@ -1134,10 +1134,10 @@ enip_open_cip_connection( packet_info *pinfo, cip_conn_info_t* connInfo)
/* similar logic to find_or_create_conversation(), but since I/O traffic
is on UDP, the pinfo parameter doesn't have the correct information */
if ((conversation = find_conversation(pinfo->num, &pinfo->dst, &dest_address,
PT_UDP, connInfo->O2T.port, 0, NO_PORT_B)) == NULL) {
ENDPOINT_UDP, connInfo->O2T.port, 0, NO_PORT_B)) == NULL) {
conversation = conversation_new(pinfo->num, &pinfo->dst, &dest_address,
PT_UDP, connInfo->O2T.port, 0, NO_PORT2);
ENDPOINT_UDP, connInfo->O2T.port, 0, NO_PORT2);
}
enip_info = (enip_conv_info_t *)conversation_get_proto_data(conversation, proto_enip);
@ -1155,10 +1155,10 @@ enip_open_cip_connection( packet_info *pinfo, cip_conn_info_t* connInfo)
or ports aren't equal, a separate conversation must be generated */
dest_address.data = connInfo->T2O.ipaddress.data;
if ((conversationTO = find_conversation(pinfo->num, &pinfo->src, &dest_address,
PT_UDP, connInfo->T2O.port, 0, NO_PORT_B)) == NULL) {
ENDPOINT_UDP, connInfo->T2O.port, 0, NO_PORT_B)) == NULL) {
conversationTO = conversation_new(pinfo->num, &pinfo->src,
&dest_address, PT_UDP,
&dest_address, ENDPOINT_UDP,
connInfo->T2O.port, 0, NO_PORT2);
}
@ -1317,7 +1317,7 @@ enip_get_io_connid(packet_info *pinfo, guint32 connid, enum enip_connid_type* pc
*/
conversation = find_conversation(pinfo->num,
&pinfo->src, &pinfo->dst,
pinfo->ptype,
conversation_pt_to_endpoint_type(pinfo->ptype),
pinfo->destport, 0, NO_PORT_B);
if (conversation == NULL)

View File

@ -2184,7 +2184,7 @@ epl_get_convo(packet_info *pinfo, int opts)
node_addr = &epl_placeholder_mac;
if ((epan_convo = find_conversation(pinfo->num, node_addr, node_addr,
pinfo->ptype, node_port, node_port, NO_ADDR_B|NO_PORT_B)))
conversation_pt_to_endpoint_type(pinfo->ptype), node_port, node_port, NO_ADDR_B|NO_PORT_B)))
{
/* XXX Do I need to check setup_frame != pinfo->num in order to not
* create unnecessary new conversations?
@ -2201,7 +2201,7 @@ epl_get_convo(packet_info *pinfo, int opts)
{
new_convo_creation:
epan_convo = conversation_new(pinfo->num, node_addr, node_addr,
pinfo->ptype, node_port, node_port, NO_ADDR2|NO_PORT2);
conversation_pt_to_endpoint_type(pinfo->ptype), node_port, node_port, NO_ADDR2|NO_PORT2);
}
convo = (struct epl_convo*)conversation_get_proto_data(epan_convo, proto_epl);

View File

@ -258,7 +258,7 @@ dissect_epmd_response(packet_info *pinfo, tvbuff_t *tvb, gint offset, proto_tree
}
col_append_fstr(pinfo->cinfo, COL_INFO, " %s port=%d", name, port);
if (!pinfo->fd->flags.visited) {
conv = conversation_new(pinfo->num, &pinfo->src, &pinfo->dst, PT_TCP, port, 0, NO_PORT2);
conv = conversation_new(pinfo->num, &pinfo->src, &pinfo->dst, ENDPOINT_TCP, port, 0, NO_PORT2);
conversation_set_dissector(conv, edp_handle);
}
break;

View File

@ -1713,11 +1713,11 @@ dissect_fcdns (tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, void* data)
if ((opcode != FCCT_MSG_ACC) && (opcode != FCCT_MSG_RJT)) {
conversation = find_conversation (pinfo->num, &pinfo->src, &pinfo->dst,
pinfo->ptype, fchdr->oxid,
conversation_pt_to_endpoint_type(pinfo->ptype), fchdr->oxid,
fchdr->rxid, NO_PORT2);
if (!conversation) {
conversation = conversation_new (pinfo->num, &pinfo->src, &pinfo->dst,
pinfo->ptype, fchdr->oxid,
conversation_pt_to_endpoint_type(pinfo->ptype), fchdr->oxid,
fchdr->rxid, NO_PORT2);
}
@ -1747,7 +1747,7 @@ dissect_fcdns (tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, void* data)
else {
/* Opcode is ACC or RJT */
conversation = find_conversation (pinfo->num, &pinfo->src, &pinfo->dst,
pinfo->ptype, fchdr->oxid,
conversation_pt_to_endpoint_type(pinfo->ptype), fchdr->oxid,
fchdr->rxid, NO_PORT2);
isreq = 0;
if (!conversation) {

View File

@ -1868,12 +1868,12 @@ dissect_fcels (tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, void* data)
options = NO_PORT2;
}
conversation = find_conversation (pinfo->num, &pinfo->dst, &pinfo->src,
pinfo->ptype, fchdr->oxid,
conversation_pt_to_endpoint_type(pinfo->ptype), fchdr->oxid,
fchdr->rxid, options);
if (!conversation) {
conversation = conversation_new (pinfo->num, &pinfo->dst, &pinfo->src,
pinfo->ptype, fchdr->oxid,
conversation_pt_to_endpoint_type(pinfo->ptype), fchdr->oxid,
fchdr->rxid, options);
}
@ -1903,7 +1903,7 @@ dissect_fcels (tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, void* data)
options = NO_PORT2;
conversation = find_conversation (pinfo->num, &pinfo->dst, &pinfo->src,
pinfo->ptype, fchdr->oxid,
conversation_pt_to_endpoint_type(pinfo->ptype), fchdr->oxid,
fchdr->rxid, options);
if (!conversation) {
/* FLOGI has two ways to save state: without the src and using just
@ -1925,7 +1925,7 @@ dissect_fcels (tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, void* data)
addrdata[2] = dstfc[2];
set_address (&dstaddr, AT_FC, 3, addrdata);
conversation = find_conversation (pinfo->num, &dstaddr, &pinfo->src,
pinfo->ptype, fchdr->oxid,
conversation_pt_to_endpoint_type(pinfo->ptype), fchdr->oxid,
fchdr->rxid, options);
}
@ -1933,7 +1933,7 @@ dissect_fcels (tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, void* data)
/* Finally check for FLOGI with both NO_PORT2 and NO_ADDR2 set */
options = NO_ADDR2 | NO_PORT2;
conversation = find_conversation (pinfo->num, &pinfo->src, &pinfo->dst,
pinfo->ptype, fchdr->oxid,
conversation_pt_to_endpoint_type(pinfo->ptype), fchdr->oxid,
fchdr->rxid, options);
if (!conversation) {
if (tree && (opcode == FC_ELS_ACC)) {

View File

@ -713,11 +713,11 @@ dissect_fcfcs (tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, void* data)
if ((opcode != FCCT_MSG_ACC) && (opcode != FCCT_MSG_RJT)) {
conversation = find_conversation (pinfo->num, &pinfo->src, &pinfo->dst,
pinfo->ptype, fchdr->oxid,
conversation_pt_to_endpoint_type(pinfo->ptype), fchdr->oxid,
fchdr->rxid, NO_PORT2);
if (!conversation) {
conversation = conversation_new (pinfo->num, &pinfo->src, &pinfo->dst,
pinfo->ptype, fchdr->oxid,
conversation_pt_to_endpoint_type(pinfo->ptype), fchdr->oxid,
fchdr->rxid, NO_PORT2);
}
@ -747,7 +747,7 @@ dissect_fcfcs (tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, void* data)
else {
/* Opcode is ACC or RJT */
conversation = find_conversation (pinfo->num, &pinfo->src, &pinfo->dst,
pinfo->ptype, fchdr->oxid,
conversation_pt_to_endpoint_type(pinfo->ptype), fchdr->oxid,
fchdr->rxid, NO_PORT2);
isreq = 0;
if (!conversation) {

View File

@ -536,11 +536,11 @@ dissect_fcfzs(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, void* data)
if ((opcode != FCCT_MSG_ACC) && (opcode != FCCT_MSG_RJT)) {
conversation = find_conversation(pinfo->num, &pinfo->src, &pinfo->dst,
pinfo->ptype, fchdr->oxid,
conversation_pt_to_endpoint_type(pinfo->ptype), fchdr->oxid,
fchdr->rxid, NO_PORT2);
if (!conversation) {
conversation = conversation_new(pinfo->num, &pinfo->src, &pinfo->dst,
pinfo->ptype, fchdr->oxid,
conversation_pt_to_endpoint_type(pinfo->ptype), fchdr->oxid,
fchdr->rxid, NO_PORT2);
}
@ -571,7 +571,7 @@ dissect_fcfzs(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, void* data)
else {
/* Opcode is ACC or RJT */
conversation = find_conversation(pinfo->num, &pinfo->src, &pinfo->dst,
pinfo->ptype, fchdr->oxid,
conversation_pt_to_endpoint_type(pinfo->ptype), fchdr->oxid,
fchdr->rxid, NO_PORT2);
isreq = FALSE;
if (!conversation) {

View File

@ -687,7 +687,7 @@ static int dissect_fc_sbccs (tvbuff_t *tvb, packet_info *pinfo,
/* Retrieve conversation state to determine expected payload */
conversation = find_conversation (pinfo->num, &pinfo->src, &pinfo->dst,
PT_SBCCS, ch_cu_id, dev_addr, 0);
ENDPOINT_SBCCS, ch_cu_id, dev_addr, 0);
if (conversation) {
#if 0
@ -701,7 +701,7 @@ static int dissect_fc_sbccs (tvbuff_t *tvb, packet_info *pinfo,
conversation =
#endif
conversation_new (pinfo->num, &pinfo->src, &pinfo->dst,
PT_SBCCS, ch_cu_id, dev_addr, 0);
ENDPOINT_SBCCS, ch_cu_id, dev_addr, 0);
#if 0
task_key.conv_id = conversation->index;
task_key.task_id = ccw;

View File

@ -1692,11 +1692,11 @@ dissect_fcswils(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, void* data)
/* Register conversation if this is not a response */
if ((opcode != FC_SWILS_SWACC) && (opcode != FC_SWILS_SWRJT)) {
conversation = find_conversation(pinfo->num, &pinfo->src, &pinfo->dst,
pinfo->ptype, fchdr->oxid,
conversation_pt_to_endpoint_type(pinfo->ptype), fchdr->oxid,
fchdr->rxid, NO_PORT2);
if (!conversation) {
conversation = conversation_new(pinfo->num, &pinfo->src, &pinfo->dst,
pinfo->ptype, fchdr->oxid,
conversation_pt_to_endpoint_type(pinfo->ptype), fchdr->oxid,
fchdr->rxid, NO_PORT2);
}
@ -1724,7 +1724,7 @@ dissect_fcswils(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, void* data)
else {
/* Opcode is ACC or RJT */
conversation = find_conversation(pinfo->num, &pinfo->src, &pinfo->dst,
pinfo->ptype, fchdr->oxid,
conversation_pt_to_endpoint_type(pinfo->ptype), fchdr->oxid,
fchdr->rxid, NO_PORT2);
isreq = FC_SWILS_RPLY;
if (!conversation) {

View File

@ -101,7 +101,7 @@ static void dissect_payload(tvbuff_t *next_tvb, packet_info *pinfo, proto_tree *
p_add_proto_data(wmem_file_scope(), pinfo, proto_umts_rlc, 0, fp_mux_info->rlcinfos[payload_index]);
/* Trying a dissector assigned to the conversation (Usually from NBAP) */
conv_dissected = try_conversation_dissector(&pinfo->dst, &pinfo->src, PT_UDP,
conv_dissected = try_conversation_dissector(&pinfo->dst, &pinfo->src, ENDPOINT_UDP,
pinfo->destport, pinfo->srcport, next_tvb, pinfo, tree, NULL);
if (!conv_dissected) {
/* No conversation dissector / TVB was rejected, try other options */

View File

@ -236,7 +236,7 @@ static void create_and_link_data_conversation(packet_info *pinfo,
ftp_data_conversation_t *p_ftp_data_conv;
conversation_t *data_conversation = conversation_new(pinfo->num,
addr_a, addr_b,
PT_TCP,
ENDPOINT_TCP,
port_a, port_b,
NO_PORT2);
conversation_set_dissector(data_conversation, ftpdata_handle);

View File

@ -505,7 +505,7 @@ find_or_create_call_info_conv(packet_info * pinfo)
*/
conv2 = find_conversation( pinfo->num,
&pinfo->dst,&pinfo->src,
pinfo->ptype,
conversation_pt_to_endpoint_type(pinfo->ptype),
pinfo->destport,pinfo->srcport, 0 );
if(conv2 != NULL)
datax = (h223_call_info *)conversation_get_proto_data(conv2, proto_h223);

View File

@ -1713,9 +1713,9 @@ dissect_h225_H245TransportAddress(tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t
return offset;
}
conv=find_conversation(actx->pinfo->num, &src_addr, &src_addr, PT_TCP, ip_port, ip_port, NO_ADDR_B|NO_PORT_B);
conv=find_conversation(actx->pinfo->num, &src_addr, &src_addr, ENDPOINT_TCP, ip_port, ip_port, NO_ADDR_B|NO_PORT_B);
if(!conv){
conv=conversation_new(actx->pinfo->num, &src_addr, &src_addr, PT_TCP, ip_port, ip_port, NO_ADDR2|NO_PORT2);
conv=conversation_new(actx->pinfo->num, &src_addr, &src_addr, ENDPOINT_TCP, ip_port, ip_port, NO_ADDR2|NO_PORT2);
conversation_set_dissector(conv, h245_handle);
}
}

View File

@ -1255,12 +1255,12 @@ hartip_set_conversation(packet_info *pinfo)
* for this protocol.
*/
conversation = find_conversation(pinfo->num,
&pinfo->src, &pinfo->dst, pinfo->ptype,
&pinfo->src, &pinfo->dst, conversation_pt_to_endpoint_type(pinfo->ptype),
pinfo->srcport, 0, NO_PORT_B);
if( (conversation == NULL) ||
(conversation_get_dissector(conversation, pinfo->num) != hartip_udp_handle) ) {
conversation = conversation_new(pinfo->num,
&pinfo->src, &pinfo->dst, pinfo->ptype,
&pinfo->src, &pinfo->dst, conversation_pt_to_endpoint_type(pinfo->ptype),
pinfo->srcport, 0, NO_PORT2);
conversation_set_dissector(conversation, hartip_udp_handle);
}

View File

@ -2193,7 +2193,7 @@ http_payload_subdissector(tvbuff_t *tvb, proto_tree *tree,
destport = pinfo->destport;
}
conv = find_conversation(pinfo->num, &pinfo->src, &pinfo->dst, PT_TCP, srcport, destport, 0);
conv = find_conversation(pinfo->num, &pinfo->src, &pinfo->dst, ENDPOINT_TCP, srcport, destport, 0);
/* We may get stuck in a recursion loop if we let process_tcp_payload() call us.
* So, if the port in the URI is one we're registered for or we have set up a

View File

@ -418,13 +418,13 @@ static conversation_t *_find_or_create_conversation(packet_info * pinfo)
/* Have we seen this conversation before? */
conv =
find_conversation(pinfo->num, &pinfo->src, &pinfo->dst,
pinfo->ptype, 0, 0, 0);
find_conversation(pinfo->num, &pinfo->src, &pinfo->dst, conversation_pt_to_endpoint_type(pinfo->ptype),
0, 0, 0);
if (conv == NULL) {
/* No, this is a new conversation. */
conv =
conversation_new(pinfo->num, &pinfo->src,
&pinfo->dst, pinfo->ptype, 0, 0, 0);
&pinfo->dst, conversation_pt_to_endpoint_type(pinfo->ptype), 0, 0, 0);
}
return conv;
}
@ -1082,7 +1082,7 @@ static icmp_transaction_t *transaction_end(packet_info * pinfo,
conversation =
find_conversation(pinfo->num, &pinfo->src, &pinfo->dst,
pinfo->ptype, 0, 0, 0);
conversation_pt_to_endpoint_type(pinfo->ptype), 0, 0, 0);
if (conversation == NULL) {
return NULL;
}

View File

@ -1377,11 +1377,11 @@ static conversation_t *_find_or_create_conversation(packet_info *pinfo)
/* Have we seen this conversation before? */
conv = find_conversation(pinfo->num, &pinfo->src, &pinfo->dst,
pinfo->ptype, 0, 0, 0);
conversation_pt_to_endpoint_type(pinfo->ptype), 0, 0, 0);
if (conv == NULL) {
/* No, this is a new conversation. */
conv = conversation_new(pinfo->num, &pinfo->src, &pinfo->dst,
pinfo->ptype, 0, 0, 0);
conversation_pt_to_endpoint_type(pinfo->ptype), 0, 0, 0);
}
return conv;
}
@ -1498,7 +1498,7 @@ static icmp_transaction_t *transaction_end(packet_info *pinfo, proto_tree *tree,
double resp_time;
conversation = find_conversation(pinfo->num, &pinfo->src, &pinfo->dst,
pinfo->ptype, 0, 0, 0);
conversation_pt_to_endpoint_type(pinfo->ptype), 0, 0, 0);
if (conversation == NULL)
return NULL;

View File

@ -2493,7 +2493,7 @@ static void update_sport(packet_info *pinfo)
conversation_infiniband_data *conv_data;
conv = find_conversation(pinfo->num, &pinfo->dst, &pinfo->dst,
PT_IBQP, pinfo->destport, pinfo->destport, NO_ADDR_B|NO_PORT_B);
ENDPOINT_IBQP, pinfo->destport, pinfo->destport, NO_ADDR_B|NO_PORT_B);
if (!conv)
return;
@ -3178,13 +3178,13 @@ create_conv_and_add_proto_data(packet_info *pinfo, guint64 service_id,
proto_data->src_qp = src_port;
memcpy(&proto_data->mad_private_data[0], mad_data, MAD_DATA_SIZE);
conv = conversation_new(pinfo->num, addr, addr,
PT_IBQP, port, port, options);
ENDPOINT_IBQP, port, port, options);
conversation_add_proto_data(conv, proto_infiniband, proto_data);
/* next, register the conversation using the LIDs */
set_address(addr, AT_IB, sizeof(guint16), wmem_memdup(pinfo->pool, &lid, sizeof lid));
conv = conversation_new(pinfo->num, addr, addr,
PT_IBQP, port, port, options);
ENDPOINT_IBQP, port, port, options);
conversation_add_proto_data(conv, proto_infiniband, proto_data);
}
@ -3230,7 +3230,7 @@ static void save_conversation_info(packet_info *pinfo, guint8 *local_gid, guint8
proto_data->client_to_server = TRUE;
conv = conversation_new(pinfo->num, &pinfo->src, &pinfo->dst,
PT_IBQP, pinfo->srcport, pinfo->destport, 0);
ENDPOINT_IBQP, pinfo->srcport, pinfo->destport, 0);
conversation_add_proto_data(conv, proto_infiniband, proto_data);
/* create unidirection conversation for packets that will flow from
@ -3437,7 +3437,7 @@ static void create_bidi_conv(packet_info *pinfo, connection_context *connection)
proto_data->client_to_server = FALSE;
memset(&proto_data->mad_private_data[0], 0, MAD_DATA_SIZE);
conv = conversation_new(pinfo->num, &pinfo->src, &pinfo->dst,
PT_IBQP, connection->resp_qp,
ENDPOINT_IBQP, connection->resp_qp,
connection->req_qp, 0);
conversation_add_proto_data(conv, proto_infiniband, proto_data);
}
@ -3488,7 +3488,7 @@ static void update_passive_conv_info(packet_info *pinfo,
conversation_infiniband_data *conv_data;
conv = find_conversation(pinfo->num, &pinfo->dst, &pinfo->dst,
PT_IBQP, connection->req_qp, connection->req_qp,
ENDPOINT_IBQP, connection->req_qp, connection->req_qp,
NO_ADDR_B|NO_PORT_B);
if (!conv)
return; /* nothing to do with no conversation context */

View File

@ -261,14 +261,14 @@ dissect_ib_sdp_heur(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, void *d
will not work since we do not have the source QP. this WILL succeed when we're still
in the process of CM negotiations */
conv = find_conversation(pinfo->num, &pinfo->src, &pinfo->dst,
PT_IBQP, pinfo->srcport, pinfo->destport, 0);
ENDPOINT_IBQP, pinfo->srcport, pinfo->destport, 0);
if (!conv) {
/* if not, try to find an established RC channel. recall Infiniband conversations are
registered with one side of the channel. since the packet is only guaranteed to
contain the qpn of the destination, we'll use this */
conv = find_conversation(pinfo->num, &pinfo->dst, &pinfo->dst,
PT_IBQP, pinfo->destport, pinfo->destport, NO_ADDR_B|NO_PORT_B);
ENDPOINT_IBQP, pinfo->destport, pinfo->destport, NO_ADDR_B|NO_PORT_B);
if (!conv)
return FALSE; /* nothing to do with no conversation context */

View File

@ -681,7 +681,7 @@ dissect_spx(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, void* data _U_)
* SPX session using that source port; can that happen? If so,
* we should probably use the direction, as well as the conversation,
* as part of the hash key; if we do that, we can probably just
* use PT_IPX as the port type, and possibly get rid of PT_NCP.
* use ENDPOINT_IPX as the port type, and possibly get rid of ENDPOINT_NCP.
*
* According to
*
@ -706,7 +706,7 @@ dissect_spx(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, void* data _U_)
*/
if (!pinfo->fd->flags.visited) {
conversation = find_conversation(pinfo->num, &pinfo->src,
&pinfo->dst, PT_NCP, pinfo->srcport,
&pinfo->dst, ENDPOINT_NCP, pinfo->srcport,
pinfo->srcport, 0);
if (conversation == NULL) {
/*
@ -714,7 +714,7 @@ dissect_spx(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, void* data _U_)
* a new one.
*/
conversation = conversation_new(pinfo->num, &pinfo->src,
&pinfo->dst, PT_NCP, pinfo->srcport,
&pinfo->dst, ENDPOINT_NCP, pinfo->srcport,
pinfo->srcport, 0);
}

View File

@ -587,7 +587,7 @@ iscsi_dissect_TargetAddress(packet_info *pinfo, tvbuff_t* tvb, proto_tree *tree,
if (addr && !pinfo->fd->flags.visited) {
conversation_t *conv;
conv = conversation_new(pinfo->num, addr, addr, PT_TCP, port, port, NO_ADDR2|NO_PORT2);
conv = conversation_new(pinfo->num, addr, addr, ENDPOINT_TCP, port, port, NO_ADDR2|NO_PORT2);
if (conv == NULL) {
return;
}

View File

@ -234,14 +234,14 @@ dissect_iser(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree,
will not work since we do not have the source QP. this WILL succeed when we're still
in the process of CM negotiations */
conv = find_conversation(pinfo->num, &pinfo->src, &pinfo->dst,
PT_IBQP, pinfo->srcport, pinfo->destport, 0);
ENDPOINT_IBQP, pinfo->srcport, pinfo->destport, 0);
if (!conv) {
/* if not, try to find an established RC channel. recall Infiniband conversations are
registered with one side of the channel. since the packet is only guaranteed to
contain the qpn of the destination, we'll use this */
conv = find_conversation(pinfo->num, &pinfo->dst, &pinfo->dst,
PT_IBQP, pinfo->destport, pinfo->destport, NO_ADDR_B|NO_PORT_B);
ENDPOINT_IBQP, pinfo->destport, pinfo->destport, NO_ADDR_B|NO_PORT_B);
if (!conv)
return FALSE; /* nothing to do with no conversation context */

View File

@ -767,7 +767,7 @@ dissect_isns_attr_port(tvbuff_t *tvb, guint offset, proto_tree *tree, int hf_ind
guint16 port = tvb_get_ntohs(tvb, offset+2);
gboolean is_udp = ((tvb_get_ntohs(tvb, offset) & 0x01) == 0x01);
conversation_t *conversation;
port_type pt;
endpoint_type et;
dissector_handle_t handle;
proto_tree_add_uint(tree, hf_index, tvb, offset, 4, port);
@ -775,19 +775,19 @@ dissect_isns_attr_port(tvbuff_t *tvb, guint offset, proto_tree *tree, int hf_ind
if ((isns_port_type == ISNS_ESI_PORT) || (isns_port_type == ISNS_SCN_PORT)) {
if (is_udp) {
pt = PT_UDP;
et = ENDPOINT_UDP;
handle = isns_udp_handle;
}
else {
pt = PT_TCP;
et = ENDPOINT_TCP;
handle = isns_tcp_handle;
}
conversation = find_conversation(pinfo->num,
&pinfo->src, &pinfo->dst, pt, port, 0, NO_PORT_B);
&pinfo->src, &pinfo->dst, et, port, 0, NO_PORT_B);
if (conversation == NULL) {
conversation = conversation_new(pinfo->num,
&pinfo->src, &pinfo->dst, pt, port, 0, NO_PORT2_FORCE);
&pinfo->src, &pinfo->dst, et, port, 0, NO_PORT2_FORCE);
conversation_set_dissector(conversation, handle);
}
}

View File

@ -786,11 +786,11 @@ static conversation_t *get_peer_conversation(packet_info * pinfo, jxta_stream_co
if ((AT_NONE != tpt_conv_data->initiator_address.type) && (AT_NONE != tpt_conv_data->receiver_address.type)) {
peer_conversation = find_conversation(pinfo->num, &tpt_conv_data->initiator_address, &tpt_conv_data->receiver_address,
PT_NONE, 0, 0, NO_PORT_B);
ENDPOINT_NONE, 0, 0, NO_PORT_B);
if (create && (NULL == peer_conversation)) {
peer_conversation = conversation_new(pinfo->num, &tpt_conv_data->initiator_address,
&tpt_conv_data->receiver_address, PT_NONE, 0, 0, NO_PORT_B);
&tpt_conv_data->receiver_address, ENDPOINT_NONE, 0, 0, NO_PORT_B);
conversation_set_dissector(peer_conversation, stream_jxta_handle);
}

View File

@ -3145,10 +3145,10 @@ dissect_kerberos_KDC_REQ_BODY(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int
* http://www.ietf.org/internet-drafts/draft-ietf-krb-wg-kerberos-clarifications-07.txt
*/
if (actx->pinfo->destport == UDP_PORT_KERBEROS && actx->pinfo->ptype == PT_UDP) {
conversation = find_conversation(actx->pinfo->num, &actx->pinfo->src, &actx->pinfo->dst, PT_UDP,
conversation = find_conversation(actx->pinfo->num, &actx->pinfo->src, &actx->pinfo->dst, ENDPOINT_UDP,
actx->pinfo->srcport, 0, NO_PORT_B);
if (conversation == NULL) {
conversation = conversation_new(actx->pinfo->num, &actx->pinfo->src, &actx->pinfo->dst, PT_UDP,
conversation = conversation_new(actx->pinfo->num, &actx->pinfo->src, &actx->pinfo->dst, ENDPOINT_UDP,
actx->pinfo->srcport, 0, NO_PORT2);
conversation_set_dissector(conversation, kerberos_handle_udp);
}

View File

@ -2940,16 +2940,16 @@ dissect_l2tp_udp(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, void *data
return 0;
}
conv = find_conversation(pinfo->num, &pinfo->src, &pinfo->dst, PT_UDP,
conv = find_conversation(pinfo->num, &pinfo->src, &pinfo->dst, ENDPOINT_UDP,
pinfo->srcport, pinfo->destport, NO_PORT_B);
if (conv == NULL) {
conv = find_conversation(pinfo->num, &pinfo->src, &pinfo->dst, PT_UDP,
conv = find_conversation(pinfo->num, &pinfo->src, &pinfo->dst, ENDPOINT_UDP,
pinfo->srcport, pinfo->destport, 0);
}
if ((conv == NULL) || (conversation_get_dissector(conv, pinfo->num) != l2tp_udp_handle)) {
conv = conversation_new(pinfo->num, &pinfo->src, &pinfo->dst, PT_UDP,
conv = conversation_new(pinfo->num, &pinfo->src, &pinfo->dst, ENDPOINT_UDP,
pinfo->srcport, 0, NO_PORT2);
conversation_set_dissector(conv, l2tp_udp_handle);
}

View File

@ -89,10 +89,10 @@ static lbmtcp_transport_t * lbmtcp_transport_add(const address * address1, guint
lbmtcp_transport_t * entry;
conversation_t * conv = NULL;
conv = find_conversation(frame, address1, address2, PT_TCP, port1, port2, 0);
conv = find_conversation(frame, address1, address2, ENDPOINT_TCP, port1, port2, 0);
if (conv == NULL)
{
conv = conversation_new(frame, address1, address2, PT_TCP, port1, port2, 0);
conv = conversation_new(frame, address1, address2, ENDPOINT_TCP, port1, port2, 0);
}
entry = (lbmtcp_transport_t *) conversation_get_proto_data(conv, lbmpdm_tcp_protocol_handle);
if (entry != NULL)

View File

@ -59,7 +59,7 @@ static lbtrm_transport_t * lbtrm_transport_unicast_find(const address * source_a
conversation_t * conv = NULL;
wmem_tree_t * session_tree = NULL;
conv = find_conversation(frame, source_address, &lbtrm_null_address, PT_UDP, source_port, 0, 0);
conv = find_conversation(frame, source_address, &lbtrm_null_address, ENDPOINT_UDP, source_port, 0, 0);
if (conv != NULL)
{
if (frame > conv->last_frame)
@ -81,10 +81,10 @@ static void lbtrm_transport_unicast_add(const address * source_address, guint16
wmem_tree_t * session_tree = NULL;
lbtrm_transport_t * transport_entry = NULL;
conv = find_conversation(frame, source_address, &lbtrm_null_address, PT_UDP, source_port, 0, 0);
conv = find_conversation(frame, source_address, &lbtrm_null_address, ENDPOINT_UDP, source_port, 0, 0);
if (conv == NULL)
{
conv = conversation_new(frame, source_address, &lbtrm_null_address, PT_UDP, source_port, 0, 0);
conv = conversation_new(frame, source_address, &lbtrm_null_address, ENDPOINT_UDP, source_port, 0, 0);
}
session_tree = (wmem_tree_t *) conversation_get_proto_data(conv, proto_lbtrm);
if (session_tree == NULL)
@ -105,7 +105,7 @@ static lbtrm_transport_t * lbtrm_transport_find(const address * source_address,
wmem_tree_t * session_tree = NULL;
conversation_t * conv = NULL;
conv = find_conversation(frame, source_address, multicast_group, PT_UDP, source_port, dest_port, 0);
conv = find_conversation(frame, source_address, multicast_group, ENDPOINT_UDP, source_port, dest_port, 0);
if (conv != NULL)
{
if (frame > conv->last_frame)
@ -127,10 +127,10 @@ lbtrm_transport_t * lbtrm_transport_add(const address * source_address, guint16
conversation_t * conv = NULL;
wmem_tree_t * session_tree = NULL;
conv = find_conversation(frame, source_address, multicast_group, PT_UDP, source_port, dest_port, 0);
conv = find_conversation(frame, source_address, multicast_group, ENDPOINT_UDP, source_port, dest_port, 0);
if (conv == NULL)
{
conv = conversation_new(frame, source_address, multicast_group, PT_UDP, source_port, dest_port, 0);
conv = conversation_new(frame, source_address, multicast_group, ENDPOINT_UDP, source_port, dest_port, 0);
}
if (frame > conv->last_frame)
{

View File

@ -57,7 +57,7 @@ static lbtru_transport_t * lbtru_transport_find(const address * source_address,
wmem_tree_t * session_tree = NULL;
conversation_t * conv = NULL;
conv = find_conversation(frame, source_address, &lbtru_null_address, PT_UDP, source_port, 0, 0);
conv = find_conversation(frame, source_address, &lbtru_null_address, ENDPOINT_UDP, source_port, 0, 0);
if (conv != NULL)
{
if (frame != 0)
@ -86,10 +86,10 @@ lbtru_transport_t * lbtru_transport_add(const address * source_address, guint16
wmem_tree_t * session_tree = NULL;
conversation_t * conv = NULL;
conv = find_conversation(frame, source_address, &lbtru_null_address, PT_UDP, source_port, 0, 0);
conv = find_conversation(frame, source_address, &lbtru_null_address, ENDPOINT_UDP, source_port, 0, 0);
if (conv == NULL)
{
conv = conversation_new(frame, source_address, &lbtru_null_address, PT_UDP, source_port, 0, 0);
conv = conversation_new(frame, source_address, &lbtru_null_address, ENDPOINT_UDP, source_port, 0, 0);
}
if (frame != 0)
{
@ -133,7 +133,7 @@ static lbtru_client_transport_t * lbtru_client_transport_find(lbtru_transport_t
{
return (NULL);
}
client_conv = find_conversation(frame, &(transport->source_address), receiver_address, PT_UDP, transport->source_port, receiver_port, 0);
client_conv = find_conversation(frame, &(transport->source_address), receiver_address, ENDPOINT_UDP, transport->source_port, receiver_port, 0);
if (client_conv != NULL)
{
wmem_tree_t * session_tree = NULL;
@ -182,10 +182,10 @@ static lbtru_client_transport_t * lbtru_client_transport_add(lbtru_transport_t *
entry->sm_high_sqn = 0;
/* See if a conversation for this address/port pair exists. */
client_conv = find_conversation(frame, &(transport->source_address), receiver_address, PT_UDP, transport->source_port, receiver_port, 0);
client_conv = find_conversation(frame, &(transport->source_address), receiver_address, ENDPOINT_UDP, transport->source_port, receiver_port, 0);
if (client_conv == NULL)
{
client_conv = conversation_new(frame, &(transport->source_address), receiver_address, PT_UDP, transport->source_port, receiver_port, 0);
client_conv = conversation_new(frame, &(transport->source_address), receiver_address, ENDPOINT_UDP, transport->source_port, receiver_port, 0);
session_tree = wmem_tree_new(wmem_file_scope());
conversation_add_proto_data(client_conv, proto_lbtru, (void *) session_tree);
}

View File

@ -59,7 +59,7 @@ lbttcp_transport_t * lbttcp_transport_find(const address * source_address, guint
conversation_t * conv = NULL;
lbttcp_transport_conv_data_t * conv_data = NULL;
conv = find_conversation(frame, source_address, &lbttcp_null_address, PT_TCP, source_port, 0, 0);
conv = find_conversation(frame, source_address, &lbttcp_null_address, ENDPOINT_TCP, source_port, 0, 0);
if (conv != NULL)
{
conv_data = (lbttcp_transport_conv_data_t *) conversation_get_proto_data(conv, proto_lbttcp);
@ -91,10 +91,10 @@ lbttcp_transport_t * lbttcp_transport_add(const address * source_address, guint1
conversation_t * conv = NULL;
lbttcp_transport_conv_data_t * conv_data = NULL;
conv = find_conversation(frame, source_address, &lbttcp_null_address, PT_TCP, source_port, 0, 0);
conv = find_conversation(frame, source_address, &lbttcp_null_address, ENDPOINT_TCP, source_port, 0, 0);
if (conv == NULL)
{
conv = conversation_new(frame, source_address, &lbttcp_null_address, PT_TCP, source_port, 0, 0);
conv = conversation_new(frame, source_address, &lbttcp_null_address, ENDPOINT_TCP, source_port, 0, 0);
}
conv_data = (lbttcp_transport_conv_data_t *) conversation_get_proto_data(conv, proto_lbttcp);
if (conv_data == NULL)
@ -124,7 +124,7 @@ static lbttcp_client_transport_t * lbttcp_client_transport_find(lbttcp_transport
{
return (NULL);
}
client_conv = find_conversation(frame, &(transport->source_address), receiver_address, PT_TCP, transport->source_port, receiver_port, 0);
client_conv = find_conversation(frame, &(transport->source_address), receiver_address, ENDPOINT_TCP, transport->source_port, receiver_port, 0);
if (client_conv != NULL)
{
wmem_tree_t * session_tree = NULL;
@ -159,10 +159,10 @@ static lbttcp_client_transport_t * lbttcp_client_transport_add(lbttcp_transport_
entry->id = transport->next_client_id++;
/* See if a conversation for this address/port pair exists. */
client_conv = find_conversation(frame, &(transport->source_address), receiver_address, PT_TCP, transport->source_port, receiver_port, 0);
client_conv = find_conversation(frame, &(transport->source_address), receiver_address, ENDPOINT_TCP, transport->source_port, receiver_port, 0);
if (client_conv == NULL)
{
client_conv = conversation_new(frame, &(transport->source_address), receiver_address, PT_TCP, transport->source_port, receiver_port, 0);
client_conv = conversation_new(frame, &(transport->source_address), receiver_address, ENDPOINT_TCP, transport->source_port, receiver_port, 0);
session_tree = wmem_tree_new(wmem_file_scope());
conversation_add_proto_data(client_conv, proto_lbttcp, (void *) session_tree);
}
@ -200,7 +200,7 @@ gboolean lbttcp_transport_sid_find(const address * source_address, guint16 sourc
lbttcp_transport_conv_data_t * conv_data = NULL;
lbttcp_transport_t * transport = NULL;
conv = find_conversation(frame, source_address, &lbttcp_null_address, PT_TCP, source_port, 0, 0);
conv = find_conversation(frame, source_address, &lbttcp_null_address, ENDPOINT_TCP, source_port, 0, 0);
if (conv == NULL)
{
return (FALSE);
@ -229,10 +229,10 @@ void lbttcp_transport_sid_add(const address * source_address, guint16 source_por
lbttcp_transport_conv_data_t * conv_data = NULL;
lbttcp_transport_t * transport = NULL;
conv = find_conversation(frame, source_address, &lbttcp_null_address, PT_TCP, source_port, 0, 0);
conv = find_conversation(frame, source_address, &lbttcp_null_address, ENDPOINT_TCP, source_port, 0, 0);
if (conv == NULL)
{
conv = conversation_new(frame, source_address, &lbttcp_null_address, PT_TCP, source_port, 0, 0);
conv = conversation_new(frame, source_address, &lbttcp_null_address, ENDPOINT_TCP, source_port, 0, 0);
}
conv_data = (lbttcp_transport_conv_data_t *) conversation_get_proto_data(conv, proto_lbttcp);
if (conv_data == NULL)

View File

@ -210,7 +210,7 @@ static void
prepare_ldss_transfer_conv(ldss_broadcast_t *broadcast)
{
if (!find_conversation(broadcast->num, &broadcast->broadcaster->addr, &broadcast->broadcaster->addr,
PT_TCP, broadcast->broadcaster->port, broadcast->broadcaster->port, NO_ADDR2|NO_PORT2)) {
ENDPOINT_TCP, broadcast->broadcaster->port, broadcast->broadcaster->port, NO_ADDR2|NO_PORT2)) {
conversation_t *transfer_conv;
ldss_transfer_info_t *transfer_info;
@ -219,7 +219,7 @@ prepare_ldss_transfer_conv(ldss_broadcast_t *broadcast)
/* Preparation for later push/pull dissection */
transfer_conv = conversation_new (broadcast->num, &broadcast->broadcaster->addr, &broadcast->broadcaster->addr,
PT_TCP, broadcast->broadcaster->port, broadcast->broadcaster->port, NO_ADDR2|NO_PORT2);
ENDPOINT_TCP, broadcast->broadcaster->port, broadcast->broadcaster->port, NO_ADDR2|NO_PORT2);
conversation_add_proto_data(transfer_conv, proto_ldss, transfer_info);
conversation_set_dissector(transfer_conv, ldss_tcp_handle);
}
@ -458,7 +458,7 @@ dissect_ldss_transfer (tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, void
/* Look for the transfer conversation; this was created during
* earlier broadcast dissection (see prepare_ldss_transfer_conv) */
transfer_conv = find_conversation (pinfo->num, &pinfo->src, &pinfo->dst,
PT_TCP, pinfo->srcport, pinfo->destport, 0);
ENDPOINT_TCP, pinfo->srcport, pinfo->destport, 0);
DISSECTOR_ASSERT(transfer_conv);
transfer_info = (ldss_transfer_info_t *)conversation_get_proto_data(transfer_conv, proto_ldss);
DISSECTOR_ASSERT(transfer_info);

View File

@ -1257,7 +1257,7 @@ static void dissect_mgcp_firstline(tvbuff_t *tvb, packet_info *pinfo, proto_tree
* if you do that.
*/
conversation = find_conversation(pinfo->num, &null_address,
&pinfo->dst, pinfo->ptype, pinfo->srcport,
&pinfo->dst, conversation_pt_to_endpoint_type(pinfo->ptype), pinfo->srcport,
pinfo->destport, 0);
}
if (conversation != NULL)
@ -1358,7 +1358,7 @@ static void dissect_mgcp_firstline(tvbuff_t *tvb, packet_info *pinfo, proto_tree
* if you do that.
*/
conversation = find_conversation(pinfo->num, &pinfo->src,
&null_address, pinfo->ptype, pinfo->srcport,
&null_address, conversation_pt_to_endpoint_type(pinfo->ptype), pinfo->srcport,
pinfo->destport, 0);
}
if (conversation == NULL)
@ -1367,13 +1367,13 @@ static void dissect_mgcp_firstline(tvbuff_t *tvb, packet_info *pinfo, proto_tree
if (pinfo->ptype == PT_TCP)
{
conversation = conversation_new(pinfo->num, &pinfo->src,
&pinfo->dst, pinfo->ptype, pinfo->srcport,
&pinfo->dst, ENDPOINT_TCP, pinfo->srcport,
pinfo->destport, 0);
}
else
{
conversation = conversation_new(pinfo->num, &pinfo->src,
&null_address, pinfo->ptype, pinfo->srcport,
&null_address, conversation_pt_to_endpoint_type(pinfo->ptype), pinfo->srcport,
pinfo->destport, 0);
}
}

View File

@ -308,7 +308,7 @@ static void dissect_media_stream_mbr_selector(tvbuff_t *tvb, proto_tree *tree, g
static void dissect_header_request(tvbuff_t *tvb, proto_tree *tree, guint offset);
static void dissect_stop_button_pressed(tvbuff_t *tvb, proto_tree *tree, guint offset);
static void msmms_data_add_address(packet_info *pinfo, address *addr, port_type pt, int port);
static void msmms_data_add_address(packet_info *pinfo, address *addr, endpoint_type et, int port);
@ -762,21 +762,21 @@ static void dissect_client_transport_info(tvbuff_t *tvb, packet_info *pinfo, pro
/* Use this information to set up a conversation for the data stream */
if (fields_matched == 6)
{
port_type pt = PT_NONE;
endpoint_type et = ENDPOINT_NONE;
/* Work out the port type */
if (strncmp(protocol, "UDP", 3) == 0)
{
pt = PT_UDP;
et = ENDPOINT_UDP;
}
else
if (strncmp(protocol, "TCP", 3) == 0)
{
pt = PT_TCP;
et = ENDPOINT_TCP;
}
/* Set the dissector for indicated conversation */
if (pt != PT_NONE)
if (et != ENDPOINT_NONE)
{
guint8 octets[4];
address addr;
@ -787,7 +787,7 @@ static void dissect_client_transport_info(tvbuff_t *tvb, packet_info *pinfo, pro
addr.type = AT_IPv4;
addr.len = 4;
addr.data = octets;
msmms_data_add_address(pinfo, &addr, pt, port);
msmms_data_add_address(pinfo, &addr, et, port);
}
}
}
@ -1108,7 +1108,7 @@ static void dissect_stop_button_pressed(tvbuff_t *tvb, proto_tree *tree, guint o
/********************************************************/
/* Helper function to set up an MS-MMS data conversation */
/********************************************************/
static void msmms_data_add_address(packet_info *pinfo, address *addr, port_type pt, int port)
static void msmms_data_add_address(packet_info *pinfo, address *addr, endpoint_type et, int port)
{
address null_addr;
conversation_t *p_conv;
@ -1125,13 +1125,13 @@ static void msmms_data_add_address(packet_info *pinfo, address *addr, port_type
/* Check if the ip address and port combination is not
* already registered as a conversation. */
p_conv = find_conversation(pinfo->num, addr, &null_addr, pt, port, 0,
p_conv = find_conversation(pinfo->num, addr, &null_addr, et, port, 0,
NO_ADDR_B | NO_PORT_B);
/* If not, create a new conversation. */
if (!p_conv)
{
p_conv = conversation_new(pinfo->num, addr, &null_addr, pt,
p_conv = conversation_new(pinfo->num, addr, &null_addr, et,
(guint32)port, 0, NO_ADDR2 | NO_PORT2);
}

View File

@ -279,12 +279,12 @@ static void add_msproxy_conversation( packet_info *pinfo,
}
conversation = find_conversation( pinfo->num, &pinfo->src,
&pinfo->dst, (port_type)hash_info->proto, hash_info->server_int_port,
&pinfo->dst, (endpoint_type)hash_info->proto, hash_info->server_int_port,
hash_info->clnt_port, 0);
if ( !conversation) {
conversation = conversation_new( pinfo->num, &pinfo->src, &pinfo->dst,
(port_type)hash_info->proto, hash_info->server_int_port,
(endpoint_type)hash_info->proto, hash_info->server_int_port,
hash_info->clnt_port, 0);
}
conversation_set_dissector(conversation, msproxy_sub_handle);

View File

@ -177,14 +177,14 @@ msrp_add_address( packet_info *pinfo,
* Check if the ip address and port combination is not
* already registered as a conversation.
*/
p_conv = find_conversation( pinfo->num, addr, &null_addr, PT_TCP, port, 0,
p_conv = find_conversation( pinfo->num, addr, &null_addr, ENDPOINT_TCP, port, 0,
NO_ADDR_B | NO_PORT_B);
/*
* If not, create a new conversation.
*/
if (!p_conv) {
p_conv = conversation_new( pinfo->num, addr, &null_addr, PT_TCP,
p_conv = conversation_new( pinfo->num, addr, &null_addr, ENDPOINT_TCP,
(guint32)port, 0,
NO_ADDR2 | NO_PORT2);
}
@ -231,7 +231,7 @@ show_setup_info(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree)
{
/* First time, get info from conversation */
p_conv = find_conversation(pinfo->num, &pinfo->net_dst, &pinfo->net_src,
PT_TCP,
ENDPOINT_TCP,
pinfo->destport, pinfo->srcport, 0);
if (p_conv)

View File

@ -10814,7 +10814,7 @@ dissect_nbap_AvailabilityStatus(tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *a
static int
dissect_nbap_HSDSCH_RNTI(tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) {
#line 2347 "./asn1/nbap/nbap.cnf"
#line 2342 "./asn1/nbap/nbap.cnf"
gint hrnti;
umts_fp_conversation_info_t *umts_fp_conversation_info = NULL;
fp_hsdsch_channel_info_t* fp_hsdsch_channel_info = NULL;
@ -10838,8 +10838,7 @@ nbap_hsdsch_channel_info = private_data_get_nbap_hsdsch_channel_info(actx->pinfo
for (i = 0; i < maxNrOfMACdFlows; i++) {
if (nbap_hsdsch_channel_info[i].crnc_port != 0){
conversation = find_conversation(actx->pinfo->num, &(nbap_hsdsch_channel_info[i].crnc_address), &null_addr,
PT_UDP,
nbap_hsdsch_channel_info[i].crnc_port, 0, NO_ADDR_B);
ENDPOINT_UDP, nbap_hsdsch_channel_info[i].crnc_port, 0, NO_ADDR_B);
if(conversation != NULL){
umts_fp_conversation_info = (umts_fp_conversation_info_t *)conversation_get_proto_data(conversation, proto_fp);
DISSECTOR_ASSERT(umts_fp_conversation_info != NULL);
@ -12051,7 +12050,7 @@ dissect_nbap_Common_E_DCH_Resource_Combination_InfoList(tvbuff_t *tvb _U_, int o
static int
dissect_nbap_Common_MACFlow_ID(tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) {
#line 2190 "./asn1/nbap/nbap.cnf"
#line 2186 "./asn1/nbap/nbap.cnf"
guint32 common_macdflow_id;
offset = dissect_per_constrained_integer(tvb, offset, actx, tree, hf_index,
0U, maxNrOfCommonMACFlows_1, &common_macdflow_id, FALSE);
@ -12186,7 +12185,7 @@ dissect_nbap_E_DCH_MACdFlow_Multiplexing_List(tvbuff_t *tvb _U_, int offset _U_,
static int
dissect_nbap_LogicalChannelID(tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) {
#line 1801 "./asn1/nbap/nbap.cnf"
#line 1799 "./asn1/nbap/nbap.cnf"
guint32 logical_channel_id;
guint num_items;
nbap_edch_channel_info_t* nbap_edch_channel_info;
@ -12210,7 +12209,7 @@ dissect_nbap_LogicalChannelID(tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *act
static int
dissect_nbap_MAC_PDU_SizeExtended(tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) {
#line 1919 "./asn1/nbap/nbap.cnf"
#line 1917 "./asn1/nbap/nbap.cnf"
guint32 hsdsch_macdflow_id;
nbap_hsdsch_channel_info_t* nbap_hsdsch_channel_info;
nbap_hsdsch_channel_info = private_data_get_nbap_hsdsch_channel_info(actx->pinfo);
@ -12637,7 +12636,7 @@ static const per_sequence_t CommonMACFlow_Specific_InfoItem_sequence[] = {
static int
dissect_nbap_CommonMACFlow_Specific_InfoItem(tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) {
#line 2198 "./asn1/nbap/nbap.cnf"
#line 2194 "./asn1/nbap/nbap.cnf"
address dst_addr;
guint32 transportLayerAddress_ipv4;
guint16 bindingID;
@ -12689,7 +12688,7 @@ dissect_nbap_CommonMACFlow_Specific_InfoList(tvbuff_t *tvb _U_, int offset _U_,
static int
dissect_nbap_MACdPDU_Size(tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) {
#line 1785 "./asn1/nbap/nbap.cnf"
#line 1783 "./asn1/nbap/nbap.cnf"
guint32 mac_d_pdu_size;
guint num_items;
nbap_edch_channel_info_t* nbap_edch_channel_info;
@ -13957,7 +13956,7 @@ dissect_nbap_CriticalityDiagnostics(tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_
static int
dissect_nbap_CRNC_CommunicationContextID(tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) {
#line 2317 "./asn1/nbap/nbap.cnf"
#line 2312 "./asn1/nbap/nbap.cnf"
guint32 com_context_id;
offset = dissect_per_constrained_integer(tvb, offset, actx, tree, hf_index,
0U, 1048575U, &com_context_id, FALSE);
@ -18681,7 +18680,7 @@ dissect_nbap_E_DCH_HARQ_Combining_Capability(tvbuff_t *tvb _U_, int offset _U_,
static int
dissect_nbap_E_DCH_DDI_Value(tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) {
#line 1769 "./asn1/nbap/nbap.cnf"
#line 1767 "./asn1/nbap/nbap.cnf"
guint32 e_dch_ddi_value;
guint num_items;
nbap_edch_channel_info_t* nbap_edch_channel_info;
@ -18821,7 +18820,7 @@ static const per_sequence_t E_DCH_LogicalChannelInformationItem_sequence[] = {
static int
dissect_nbap_E_DCH_LogicalChannelInformationItem(tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) {
#line 1766 "./asn1/nbap/nbap.cnf"
#line 1764 "./asn1/nbap/nbap.cnf"
private_data_increment_num_items(actx->pinfo);
@ -18838,7 +18837,7 @@ static const per_sequence_t E_DCH_LogicalChannelInformation_sequence_of[1] = {
static int
dissect_nbap_E_DCH_LogicalChannelInformation(tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) {
#line 1757 "./asn1/nbap/nbap.cnf"
#line 1755 "./asn1/nbap/nbap.cnf"
private_data_set_num_items(actx->pinfo, 0);
nbap_edch_channel_info_t* nbap_edch_channel_info;
nbap_edch_channel_info = private_data_get_nbap_edch_channel_info(actx->pinfo);
@ -18895,8 +18894,7 @@ nbap_edch_channel_info = private_data_get_nbap_edch_channel_info(actx->pinfo);
e_dch_macdflow_id = private_data_get_e_dch_macdflow_id(actx->pinfo);
clear_address(&null_addr);
p_conv = find_conversation(actx->pinfo->num, &nbap_edch_channel_info[e_dch_macdflow_id].crnc_address, &null_addr,
PT_UDP,
nbap_edch_channel_info[e_dch_macdflow_id].crnc_port, 0, NO_ADDR_B);
ENDPOINT_UDP, nbap_edch_channel_info[e_dch_macdflow_id].crnc_port, 0, NO_ADDR_B);
if(!p_conv)
return offset;
@ -19059,7 +19057,7 @@ static const per_sequence_t E_DCH_LogicalChannelToModifyItem_sequence[] = {
static int
dissect_nbap_E_DCH_LogicalChannelToModifyItem(tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) {
#line 1752 "./asn1/nbap/nbap.cnf"
#line 1750 "./asn1/nbap/nbap.cnf"
offset = dissect_per_sequence(tvb, offset, actx, tree, hf_index,
ett_nbap_E_DCH_LogicalChannelToModifyItem, E_DCH_LogicalChannelToModifyItem_sequence);
@ -19134,7 +19132,7 @@ static const per_sequence_t E_DCH_MACdFlow_Specific_InfoItem_to_Modify_sequence[
static int
dissect_nbap_E_DCH_MACdFlow_Specific_InfoItem_to_Modify(tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) {
#line 1659 "./asn1/nbap/nbap.cnf"
#line 1658 "./asn1/nbap/nbap.cnf"
guint32 no_ddi_entries, i;
address null_addr;
nbap_edch_port_info_t *old_info;
@ -19191,8 +19189,7 @@ private_data_set_num_items(actx->pinfo, 1);
/* Check if we have conversation info */
clear_address(&null_addr);
p_conv = find_conversation(actx->pinfo->num, &nbap_edch_channel_info[e_dch_macdflow_id].crnc_address, &null_addr,
PT_UDP,
nbap_edch_channel_info[e_dch_macdflow_id].crnc_port, 0, NO_ADDR_B);
ENDPOINT_UDP, nbap_edch_channel_info[e_dch_macdflow_id].crnc_port, 0, NO_ADDR_B);
if(!p_conv)
return offset;
@ -19277,7 +19274,7 @@ static const per_sequence_t E_DCH_FDD_Information_to_Modify_sequence[] = {
static int
dissect_nbap_E_DCH_FDD_Information_to_Modify(tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) {
#line 1558 "./asn1/nbap/nbap.cnf"
#line 1557 "./asn1/nbap/nbap.cnf"
address dst_addr, null_addr;
conversation_t *conversation,*old_conversation = NULL;
@ -19310,8 +19307,8 @@ private_data_set_binding_id_port(actx->pinfo, 0);
set_address(&dst_addr, AT_IPv4, 4, &transportLayerAddress_ipv4);
old_conversation = find_conversation(actx->pinfo->num,&dst_addr,
&null_addr, PT_UDP, bindingID,
old_conversation = find_conversation(actx->pinfo->num, &dst_addr,
&null_addr, ENDPOINT_UDP, bindingID,
0, NO_ADDR_B|NO_PORT_B);
if(old_conversation){
@ -19326,7 +19323,7 @@ private_data_set_binding_id_port(actx->pinfo, 0);
/* It's not part of any conversation - create a new one. */
conversation = conversation_new(actx->pinfo->num, &dst_addr,
&null_addr, PT_UDP, bindingID,
&null_addr, ENDPOINT_UDP, bindingID,
0, NO_ADDR2|NO_PORT2);
/* Set dissector */
@ -23992,7 +23989,7 @@ static const per_sequence_t HSDSCH_Common_System_InformationFDD_sequence[] = {
static int
dissect_nbap_HSDSCH_Common_System_InformationFDD(tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) {
#line 2225 "./asn1/nbap/nbap.cnf"
#line 2221 "./asn1/nbap/nbap.cnf"
/*
* 5.1.6 High Speed Downlink Shared Channels
* The Data Transfer procedure is used to transfer a HS-DSCH DATA FRAME (TYPE 1, TYPE 2 [FDD and 1.28Mcps
@ -24034,12 +24031,11 @@ int i;
if (nbap_common_channel_info[i].crnc_port != 0){
conversation = find_conversation(actx->pinfo->num, &(nbap_common_channel_info[i].crnc_address), &null_addr,
PT_UDP,
nbap_common_channel_info[i].crnc_port, 0, NO_ADDR_B);
ENDPOINT_UDP, nbap_common_channel_info[i].crnc_port, 0, NO_ADDR_B);
if (conversation == NULL) {
conversation = conversation_new(actx->pinfo->num, &(nbap_common_channel_info[i].crnc_address),
&null_addr, PT_UDP, nbap_common_channel_info[i].crnc_port,
&null_addr, ENDPOINT_UDP, nbap_common_channel_info[i].crnc_port,
0, NO_ADDR2|NO_PORT2);
/* Set dissector */
@ -24173,7 +24169,7 @@ static const per_sequence_t HSDSCH_MACdFlow_Specific_InfoItem_sequence[] = {
static int
dissect_nbap_HSDSCH_MACdFlow_Specific_InfoItem(tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) {
#line 1891 "./asn1/nbap/nbap.cnf"
#line 1889 "./asn1/nbap/nbap.cnf"
address dst_addr;
guint32 transportLayerAddress_ipv4;
guint16 bindingID;
@ -24282,7 +24278,7 @@ static const value_string nbap_RLC_Mode_vals[] = {
static int
dissect_nbap_RLC_Mode(tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) {
#line 1814 "./asn1/nbap/nbap.cnf"
#line 1812 "./asn1/nbap/nbap.cnf"
guint32 rlc_mode;
nbap_hsdsch_channel_info_t* nbap_hsdsch_channel_info;
nbap_hsdsch_channel_info = private_data_get_nbap_hsdsch_channel_info(actx->pinfo);
@ -24324,7 +24320,7 @@ static const per_sequence_t PriorityQueue_InfoItem_sequence[] = {
static int
dissect_nbap_PriorityQueue_InfoItem(tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) {
#line 1882 "./asn1/nbap/nbap.cnf"
#line 1880 "./asn1/nbap/nbap.cnf"
private_data_increment_num_items(actx->pinfo);
@ -24358,7 +24354,7 @@ static const per_sequence_t HSDSCH_MACdFlows_Information_sequence[] = {
static int
dissect_nbap_HSDSCH_MACdFlows_Information(tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) {
#line 1841 "./asn1/nbap/nbap.cnf"
#line 1839 "./asn1/nbap/nbap.cnf"
int protocol_ie_id;
guint32 i;
private_data_set_num_items(actx->pinfo,0);
@ -24403,7 +24399,7 @@ dissect_nbap_HSDSCH_MACdFlows_Information(tvbuff_t *tvb _U_, int offset _U_, asn
static int
dissect_nbap_T_hSDSCH_Physical_Layer_Category(tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) {
#line 1832 "./asn1/nbap/nbap.cnf"
#line 1830 "./asn1/nbap/nbap.cnf"
guint32 hsdsch_physical_layer_category;
nbap_hsdsch_channel_info_t* nbap_hsdsch_channel_info;
nbap_hsdsch_channel_info = private_data_get_nbap_hsdsch_channel_info(actx->pinfo);
@ -24473,7 +24469,7 @@ static const per_sequence_t HSDSCH_FDD_Information_sequence[] = {
static int
dissect_nbap_HSDSCH_FDD_Information(tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) {
#line 1953 "./asn1/nbap/nbap.cnf"
#line 1951 "./asn1/nbap/nbap.cnf"
/*
* Collect the information about the HSDSCH MACdFlows set up conversation(s) and set the conversation data.
*/
@ -24513,15 +24509,14 @@ dissect_nbap_HSDSCH_FDD_Information(tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_
address_to_str (wmem_packet_scope(), &(nbap_hsdsch_channel_info[i].crnc_address)),
nbap_hsdsch_channel_info[i].crnc_port);
conversation = find_conversation(actx->pinfo->num, &(nbap_hsdsch_channel_info[i].crnc_address), &null_addr,
PT_UDP,
nbap_hsdsch_channel_info[i].crnc_port, 0, NO_ADDR_B);
ENDPOINT_UDP, nbap_hsdsch_channel_info[i].crnc_port, 0, NO_ADDR_B);
if (conversation == NULL) {
/* It's not part of any conversation - create a new one. */
nbap_debug("Frame %u HSDSCH-MACdFlows-Information: Set up conv on Port %u", actx->pinfo->num, nbap_hsdsch_channel_info[i].crnc_port);
conversation = conversation_new(actx->pinfo->num, &(nbap_hsdsch_channel_info[i].crnc_address),
&null_addr, PT_UDP, nbap_hsdsch_channel_info[i].crnc_port,
&null_addr, ENDPOINT_UDP, nbap_hsdsch_channel_info[i].crnc_port,
0, NO_ADDR2|NO_PORT2);
/* Set dissector */
@ -24619,7 +24614,7 @@ static const per_sequence_t HSDSCH_MACdFlow_Specific_InfoItem_to_Modify_sequence
static int
dissect_nbap_HSDSCH_MACdFlow_Specific_InfoItem_to_Modify(tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) {
#line 2051 "./asn1/nbap/nbap.cnf"
#line 2048 "./asn1/nbap/nbap.cnf"
address dst_addr;
guint32 transportLayerAddress_ipv4;
guint16 bindingID;
@ -24682,7 +24677,7 @@ static const per_sequence_t PriorityQueue_InfoItem_to_Add_sequence[] = {
static int
dissect_nbap_PriorityQueue_InfoItem_to_Add(tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) {
#line 1885 "./asn1/nbap/nbap.cnf"
#line 1883 "./asn1/nbap/nbap.cnf"
private_data_set_num_items(actx->pinfo,1);
@ -24817,7 +24812,7 @@ static const per_sequence_t HSDSCH_Information_to_Modify_sequence[] = {
static int
dissect_nbap_HSDSCH_Information_to_Modify(tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) {
#line 2076 "./asn1/nbap/nbap.cnf"
#line 2073 "./asn1/nbap/nbap.cnf"
/*
* This is pretty much the same like if we setup a previous flow
*/
@ -24864,8 +24859,7 @@ dissect_nbap_HSDSCH_Information_to_Modify(tvbuff_t *tvb _U_, int offset _U_, asn
address_to_str (wmem_packet_scope(), &(nbap_hsdsch_channel_info[i].crnc_address)),
nbap_hsdsch_channel_info[i].crnc_port);
conversation = find_conversation(actx->pinfo->num, &(nbap_hsdsch_channel_info[i].crnc_address), &null_addr,
PT_UDP,
nbap_hsdsch_channel_info[i].crnc_port, 0, NO_ADDR_B);
ENDPOINT_UDP, nbap_hsdsch_channel_info[i].crnc_port, 0, NO_ADDR_B);
if (conversation == NULL) {
@ -24873,7 +24867,7 @@ dissect_nbap_HSDSCH_Information_to_Modify(tvbuff_t *tvb _U_, int offset _U_, asn
nbap_debug(" Set up conv on Port %u", nbap_hsdsch_channel_info[i].crnc_port);
conversation = conversation_new(actx->pinfo->num, &(nbap_hsdsch_channel_info[i].crnc_address),
&null_addr, PT_UDP, nbap_hsdsch_channel_info[i].crnc_port,
&null_addr, ENDPOINT_UDP, nbap_hsdsch_channel_info[i].crnc_port,
0, NO_ADDR2|NO_PORT2);
/* Set dissector */
@ -24948,7 +24942,7 @@ static const value_string nbap_HSDSCH_MACdPDUSizeFormat_vals[] = {
static int
dissect_nbap_HSDSCH_MACdPDUSizeFormat(tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) {
#line 1930 "./asn1/nbap/nbap.cnf"
#line 1928 "./asn1/nbap/nbap.cnf"
/*
* Removed 10 Aug. 2012, I'm not sure if this was right, it wrongfully
* set some packets as type 2 for HSDHCH modified items.
@ -25059,7 +25053,7 @@ static const per_sequence_t HSDSCH_MACdFlow_Specific_InformationResp_Item_sequen
static int
dissect_nbap_HSDSCH_MACdFlow_Specific_InformationResp_Item(tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) {
#line 1888 "./asn1/nbap/nbap.cnf"
#line 1886 "./asn1/nbap/nbap.cnf"
private_data_increment_num_items(actx->pinfo);
@ -25475,7 +25469,7 @@ static const per_sequence_t HSDSCH_Paging_System_InformationFDD_sequence[] = {
static int
dissect_nbap_HSDSCH_Paging_System_InformationFDD(tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) {
#line 2307 "./asn1/nbap/nbap.cnf"
#line 2302 "./asn1/nbap/nbap.cnf"
/*
g_warning("HS-DSCH Type 3 NOT Implemented!");
*/
@ -25669,7 +25663,7 @@ static const per_sequence_t HSDSCH_MACdFlows_to_Delete_Item_sequence[] = {
static int
dissect_nbap_HSDSCH_MACdFlows_to_Delete_Item(tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) {
#line 1879 "./asn1/nbap/nbap.cnf"
#line 1877 "./asn1/nbap/nbap.cnf"
private_data_increment_num_items(actx->pinfo);
@ -25686,7 +25680,7 @@ static const per_sequence_t HSDSCH_MACdFlows_to_Delete_sequence_of[1] = {
static int
dissect_nbap_HSDSCH_MACdFlows_to_Delete(tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) {
#line 1874 "./asn1/nbap/nbap.cnf"
#line 1872 "./asn1/nbap/nbap.cnf"
private_data_set_num_items(actx->pinfo,0);
@ -28792,7 +28786,7 @@ dissect_nbap_NI_Information(tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx
static int
dissect_nbap_NodeB_CommunicationContextID(tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) {
#line 2323 "./asn1/nbap/nbap.cnf"
#line 2318 "./asn1/nbap/nbap.cnf"
guint node_b_com_context_id;
/*Set up and map that maps Node-B ids to CRNC ids, since often you only have one of them present in nbap*/
nbap_com_context_id_t *cur_val;
@ -29416,14 +29410,14 @@ private_data_set_dch_id(actx->pinfo, 0xFFFFFFFF);
set_address(&dst_addr, AT_IPv4, 4, &transportLayerAddress_ipv4);
conversation = find_conversation(actx->pinfo->num,&dst_addr,
&null_addr, PT_UDP,private_data_get_binding_id_port(actx->pinfo),
conversation = find_conversation(actx->pinfo->num, &dst_addr,
&null_addr, ENDPOINT_UDP, private_data_get_binding_id_port(actx->pinfo),
0, NO_ADDR_B|NO_PORT_B);
if (conversation == NULL) {
/* It's not part of any conversation - create a new one. */
conversation = conversation_new(actx->pinfo->num, &dst_addr,
&null_addr, PT_UDP,private_data_get_binding_id_port(actx->pinfo),
&null_addr, ENDPOINT_UDP, private_data_get_binding_id_port(actx->pinfo),
0, NO_ADDR2|NO_PORT2);
/* Set dissector */
@ -29563,8 +29557,8 @@ private_data_set_binding_id_port(actx->pinfo, 0);
set_address(&dst_addr, AT_IPv4, 4, &transportLayerAddress_ipv4);
conversation = find_conversation(actx->pinfo->num,&dst_addr,
&null_addr, PT_UDP, bindingID,
conversation = find_conversation(actx->pinfo->num, &dst_addr,
&null_addr, ENDPOINT_UDP, bindingID,
0, NO_ADDR_B|NO_PORT_B);
if (conversation) {
umts_fp_conversation_info = (umts_fp_conversation_info_t*)conversation_get_proto_data(conversation, proto_fp);
@ -29579,7 +29573,7 @@ private_data_set_binding_id_port(actx->pinfo, 0);
/* It's not part of any conversation - create a new one. */
conversation = conversation_new(actx->pinfo->num, &dst_addr,
&null_addr, PT_UDP, bindingID,
&null_addr, ENDPOINT_UDP, bindingID,
0, NO_ADDR2|NO_PORT2);
/* Set dissector */
@ -33141,7 +33135,7 @@ private_data_set_transport_format_set_type(actx->pinfo, NBAP_CPCH);
set_address(&dst_addr, AT_IPv4, 4, &transportLayerAddress_ipv4);
conversation = conversation_new(actx->pinfo->num, &dst_addr, &null_addr, PT_UDP, bindingID, 0, NO_ADDR2|NO_PORT2);
conversation = conversation_new(actx->pinfo->num, &dst_addr, &null_addr, ENDPOINT_UDP, bindingID, 0, NO_ADDR2|NO_PORT2);
/* Set dissector */
conversation_set_dissector(conversation, fp_handle);
@ -33314,7 +33308,7 @@ private_data_set_num_items(actx->pinfo, 1);
set_address(&dst_addr, AT_IPv4, 4, &transportLayerAddress_ipv4);
conversation = conversation_new(actx->pinfo->num, &dst_addr, &null_addr, PT_UDP, bindingID, 0, NO_ADDR2|NO_PORT2);
conversation = conversation_new(actx->pinfo->num, &dst_addr, &null_addr, ENDPOINT_UDP, bindingID, 0, NO_ADDR2|NO_PORT2);
/* Set dissector */
conversation_set_dissector(conversation, fp_handle);
@ -33458,7 +33452,7 @@ private_data_set_transport_format_set_type(actx->pinfo, NBAP_CPCH);
set_address(&dst_addr, AT_IPv4, 4, &transportLayerAddress_ipv4);
conversation = conversation_new(actx->pinfo->num, &dst_addr, &null_addr, PT_UDP, bindingID, 0, NO_ADDR2|NO_PORT2);
conversation = conversation_new(actx->pinfo->num, &dst_addr, &null_addr, ENDPOINT_UDP, bindingID, 0, NO_ADDR2|NO_PORT2);
conversation_set_dissector(conversation, fp_handle);
@ -41829,7 +41823,7 @@ col_set_str(actx->pinfo->cinfo, COL_INFO,"RadioLinkReconfigurationCommit ");
actx->pinfo->link_dir=P2P_DIR_DL;
#line 2381 "./asn1/nbap/nbap.cnf"
#line 2375 "./asn1/nbap/nbap.cnf"
/*
* Here we need to signal the CFN value, down to FP so
* that lowert layers know when a reconfiguration becomes active
@ -55978,12 +55972,12 @@ static void add_hsdsch_bind(packet_info *pinfo){
clear_address(&null_addr);
for (i = 0; i < maxNrOfMACdFlows; i++) {
if (nbap_hsdsch_channel_info[i].crnc_port != 0){
conversation = find_conversation(pinfo->num, &(nbap_hsdsch_channel_info[i].crnc_address), &null_addr, PT_UDP,
conversation = find_conversation(pinfo->num, &(nbap_hsdsch_channel_info[i].crnc_address), &null_addr, ENDPOINT_UDP,
nbap_hsdsch_channel_info[i].crnc_port, 0, NO_ADDR_B);
if (conversation == NULL) {
/* It's not part of any conversation - create a new one. */
conversation = conversation_new(pinfo->num, &(nbap_hsdsch_channel_info[i].crnc_address), &null_addr, PT_UDP,
conversation = conversation_new(pinfo->num, &(nbap_hsdsch_channel_info[i].crnc_address), &null_addr, ENDPOINT_UDP,
nbap_hsdsch_channel_info[i].crnc_port, 0, NO_ADDR2|NO_PORT2);
/* Set dissector */

View File

@ -849,7 +849,7 @@ dissect_ncp_common(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree,
* connection.
*/
conversation = find_conversation(pinfo->num, &pinfo->src, &pinfo->dst,
PT_NCP, (guint32) pinfo->srcport, (guint32) pinfo->destport,
ENDPOINT_NCP, (guint32) pinfo->srcport, (guint32) pinfo->destport,
0);
if ((ncpiph.length & 0x80000000) || ncpiph.signature == NCPIP_RPLY) {
/* First time through we will record the initial connection and task
@ -873,7 +873,7 @@ dissect_ncp_common(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree,
* - create a new one.
*/
conversation = conversation_new(pinfo->num, &pinfo->src,
&pinfo->dst, PT_NCP, (guint32) pinfo->srcport, (guint32) pinfo->destport, 0);
&pinfo->dst, ENDPOINT_NCP, (guint32) pinfo->srcport, (guint32) pinfo->destport, 0);
mncp_hash_insert(conversation, nw_connection, header.task, pinfo);
}
/* If this is a request packet then we
@ -915,7 +915,7 @@ dissect_ncp_common(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree,
* - create a new one.
*/
conversation = conversation_new(pinfo->num, &pinfo->src,
&pinfo->dst, PT_NCP, (guint32) pinfo->srcport, (guint32) pinfo->destport, 0);
&pinfo->dst, ENDPOINT_NCP, (guint32) pinfo->srcport, (guint32) pinfo->destport, 0);
mncp_hash_insert(conversation, nw_connection, header.task, pinfo);
}
/* find the record telling us the request

View File

@ -6735,7 +6735,7 @@ nds_defrag(tvbuff_t *tvb, packet_info *pinfo, guint32 nw_connection, guint8 sequ
if (!pinfo->fd->flags.visited) {
/* Find the conversation whence the request would have come. */
conversation = find_conversation(pinfo->num, &pinfo->src, &pinfo->dst,
PT_NCP, nw_connection, nw_connection, 0);
ENDPOINT_NCP, nw_connection, nw_connection, 0);
if (conversation != NULL) {
/* find the record telling us the request made that caused
this reply */
@ -7109,12 +7109,12 @@ dissect_ncp_request(tvbuff_t *tvb, packet_info *pinfo,
as being part of a single conversation so that we can
let the user select that conversation to be displayed.) */
conversation = find_conversation(pinfo->num, &pinfo->src, &pinfo->dst,
PT_NCP, nw_connection, nw_connection, 0);
ENDPOINT_NCP, nw_connection, nw_connection, 0);
if (conversation == NULL) {
/* It's not part of any conversation - create a new one. */
conversation = conversation_new(pinfo->num, &pinfo->src, &pinfo->dst,
PT_NCP, nw_connection, nw_connection, 0);
ENDPOINT_NCP, nw_connection, nw_connection, 0);
}
request_value = ncp_hash_insert(conversation, sequence, ncp_rec, pinfo->num);
request_value->req_frame_num = pinfo->num;
@ -7268,7 +7268,7 @@ dissect_ncp_request(tvbuff_t *tvb, packet_info *pinfo,
if (!request_value)
{
conversation = find_conversation(pinfo->num, &pinfo->src, &pinfo->dst,
PT_NCP, nw_connection, nw_connection, 0);
ENDPOINT_NCP, nw_connection, nw_connection, 0);
if (conversation != NULL) {
/* find the record telling us the request made that caused
this reply */
@ -7939,7 +7939,7 @@ dissect_ncp_reply(tvbuff_t *tvb, packet_info *pinfo,
if (!pinfo->fd->flags.visited) {
/* Find the conversation whence the request would have come. */
conversation = find_conversation(pinfo->num, &pinfo->src, &pinfo->dst,
PT_NCP, nw_connection, nw_connection, 0);
ENDPOINT_NCP, nw_connection, nw_connection, 0);
if (conversation != NULL) {
/* find the record telling us the request made that caused
this reply */
@ -7959,7 +7959,7 @@ dissect_ncp_reply(tvbuff_t *tvb, packet_info *pinfo,
proper request packet. */
else {
conversation = find_conversation(pinfo->num,
&pinfo->src, &pinfo->dst, PT_NCP, 65535, 65535, 0);
&pinfo->src, &pinfo->dst, ENDPOINT_NCP, 65535, 65535, 0);
if (conversation != NULL) {
/* find the record telling us the request made
that caused this reply */
@ -7973,7 +7973,7 @@ dissect_ncp_reply(tvbuff_t *tvb, packet_info *pinfo,
}
else {
conversation = find_conversation(pinfo->num,
&pinfo->src, &pinfo->dst, PT_NCP, 0, 0, 0);
&pinfo->src, &pinfo->dst, ENDPOINT_NCP, 0, 0, 0);
if (conversation != NULL) {
/* find the record telling us the request made
that caused this reply */
@ -7993,7 +7993,7 @@ dissect_ncp_reply(tvbuff_t *tvb, packet_info *pinfo,
else {
/*request_value = p_get_proto_data(wmem_file_scope(), pinfo, proto_ncp);*/
conversation = find_conversation(pinfo->num, &pinfo->src, &pinfo->dst,
PT_NCP, nw_connection, nw_connection, 0);
ENDPOINT_NCP, nw_connection, nw_connection, 0);
if (conversation != NULL) {
request_value = ncp_hash_lookup(conversation,
@ -8263,11 +8263,11 @@ dissect_nds_request(tvbuff_t *tvb, packet_info *pinfo,
let the user select that conversation to be displayed.) */
conversation = find_conversation(pinfo->num, &pinfo->src, &pinfo->dst,
PT_NCP, nw_connection, nw_connection, 0);
ENDPOINT_NCP, nw_connection, nw_connection, 0);
if (conversation == NULL) {
/* It's not part of any conversation - create a new one. */
conversation = conversation_new(pinfo->num, &pinfo->src, &pinfo->dst,
PT_NCP, nw_connection, nw_connection, 0);
ENDPOINT_NCP, nw_connection, nw_connection, 0);
}
if (!pinfo->fd->flags.visited) {
@ -9256,13 +9256,13 @@ dissect_ping_req(tvbuff_t *tvb, packet_info *pinfo,
let the user select that conversation to be displayed.) */
conversation = find_conversation(pinfo->num, &pinfo->src, &pinfo->dst,
PT_NCP, nw_connection, nw_connection, 0);
ENDPOINT_NCP, nw_connection, nw_connection, 0);
if (conversation == NULL)
{
/* It's not part of any conversation - create a new one. */
conversation = conversation_new(pinfo->num, &pinfo->src, &pinfo->dst,
PT_NCP, nw_connection, nw_connection, 0);
ENDPOINT_NCP, nw_connection, nw_connection, 0);
}
request_value = ncp_hash_insert(conversation, sequence, ncp_rec, pinfo->num);

View File

@ -4274,13 +4274,13 @@ ndps_defrag(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, spx_info *spx_i
{
/* Lets see if this is a new conversation */
conversation = find_conversation(pinfo->num, &pinfo->src, &pinfo->dst,
PT_NCP, (guint32) pinfo->srcport, (guint32) pinfo->srcport, 0);
ENDPOINT_NCP, (guint32) pinfo->srcport, (guint32) pinfo->srcport, 0);
if (conversation == NULL)
{
/* It's not part of any conversation - create a new one. */
conversation = conversation_new(pinfo->num, &pinfo->src, &pinfo->dst,
PT_NCP, (guint32) pinfo->srcport, (guint32) pinfo->srcport, 0);
ENDPOINT_NCP, (guint32) pinfo->srcport, (guint32) pinfo->srcport, 0);
}
/* So now we need to get the request info for this conversation */
@ -4466,13 +4466,13 @@ dissect_ndps_request(tvbuff_t *tvb, packet_info *pinfo, proto_tree *ndps_tree, g
let the user select that conversation to be displayed.) */
conversation = find_conversation(pinfo->num, &pinfo->src, &pinfo->dst,
PT_NCP, (guint32) pinfo->srcport, (guint32) pinfo->srcport, 0);
ENDPOINT_NCP, (guint32) pinfo->srcport, (guint32) pinfo->srcport, 0);
if (conversation == NULL)
{
/* It's not part of any conversation - create a new one. */
conversation = conversation_new(pinfo->num, &pinfo->src, &pinfo->dst,
PT_NCP, (guint32) pinfo->srcport, (guint32) pinfo->srcport, 0);
ENDPOINT_NCP, (guint32) pinfo->srcport, (guint32) pinfo->srcport, 0);
}
request_value = ndps_hash_insert(conversation, (guint32) pinfo->srcport);
@ -6720,7 +6720,7 @@ dissect_ndps_reply(tvbuff_t *tvb, packet_info *pinfo, proto_tree *ndps_tree, int
if (!pinfo->fd->flags.visited) {
/* Find the conversation whence the request would have come. */
conversation = find_conversation(pinfo->num, &pinfo->src, &pinfo->dst,
PT_NCP, (guint32) pinfo->destport, (guint32) pinfo->destport, 0);
ENDPOINT_NCP, (guint32) pinfo->destport, (guint32) pinfo->destport, 0);
if (conversation != NULL) {
/* find the record telling us the request made that caused
this reply */

View File

@ -253,7 +253,7 @@ find_ib_conversation(packet_info *pinfo, conversation_infiniband_data **uni_conv
conversation_infiniband_data *conv_data;
conv = find_conversation(pinfo->num, &pinfo->dst, &pinfo->dst,
PT_IBQP, pinfo->destport, pinfo->destport,
ENDPOINT_IBQP, pinfo->destport, pinfo->destport,
NO_ADDR_B|NO_PORT_B);
if (!conv)
return NULL; /* nothing to do with no conversation context */
@ -267,7 +267,7 @@ find_ib_conversation(packet_info *pinfo, conversation_infiniband_data **uni_conv
* conversation, so that we can relate to nvme q.
*/
return find_conversation(pinfo->num, &pinfo->src, &pinfo->dst,
PT_IBQP, pinfo->srcport, pinfo->destport, 0);
ENDPOINT_IBQP, pinfo->srcport, pinfo->destport, 0);
}
static guint16 find_nvme_qid(packet_info *pinfo)
@ -277,7 +277,7 @@ static guint16 find_nvme_qid(packet_info *pinfo)
guint16 qid;
conv = find_conversation(pinfo->num, &pinfo->dst, &pinfo->dst,
PT_IBQP, pinfo->destport, pinfo->destport,
ENDPOINT_IBQP, pinfo->destport, pinfo->destport,
NO_ADDR_B|NO_PORT_B);
if (!conv)
return 0; /* nothing to do with no conversation context */
@ -291,7 +291,7 @@ static guint16 find_nvme_qid(packet_info *pinfo)
return qid;
}
conv = find_conversation(pinfo->num, &pinfo->src, &pinfo->src,
PT_IBQP, conv_data->src_qp, conv_data->src_qp,
ENDPOINT_IBQP, conv_data->src_qp, conv_data->src_qp,
NO_ADDR_B|NO_PORT_B);
conv_data = get_conversion_data(conv);
if (!conv_data)
@ -326,7 +326,7 @@ find_ib_cm_conversation(packet_info *pinfo)
conversation_t *conv;
conv = find_conversation(pinfo->num, &pinfo->src, &pinfo->dst,
PT_IBQP, pinfo->srcport, pinfo->destport, 0);
ENDPOINT_IBQP, pinfo->srcport, pinfo->destport, 0);
if (!conv)
return NULL;

View File

@ -140,9 +140,9 @@ dissect_getport_reply(tvbuff_t *tvb, packet_info *pinfo _U_,
port=tvb_get_ntohl(tvb, offset);
if(port){
conversation_t *conv;
conv=find_conversation(pinfo->num, &pinfo->src, &pinfo->dst, (port_type)rpc_call->private_data, port, 0, NO_ADDR_B|NO_PORT_B);
conv=find_conversation(pinfo->num, &pinfo->src, &pinfo->dst, ENDPOINT_UDP, port, 0, NO_ADDR_B|NO_PORT_B);
if(!conv){
conv=conversation_new(pinfo->num, &pinfo->src, &pinfo->dst, (port_type)rpc_call->private_data, port, 0, NO_ADDR2|NO_PORT2);
conv=conversation_new(pinfo->num, &pinfo->src, &pinfo->dst, ENDPOINT_UDP, port, 0, NO_ADDR2|NO_PORT2);
}
conversation_set_dissector(conv, rpc_handle);
}

View File

@ -2047,13 +2047,13 @@ dissect_radius(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, void *data _
* if you do that.
*/
conversation = find_conversation(pinfo->num, &pinfo->src,
&null_address, pinfo->ptype, pinfo->srcport,
&null_address, conversation_pt_to_endpoint_type(pinfo->ptype), pinfo->srcport,
pinfo->destport, 0);
if (conversation == NULL)
{
/* It's not part of any conversation - create a new one. */
conversation = conversation_new(pinfo->num, &pinfo->src,
&null_address, pinfo->ptype, pinfo->srcport,
&null_address, conversation_pt_to_endpoint_type(pinfo->ptype), pinfo->srcport,
pinfo->destport, 0);
}
@ -2167,7 +2167,7 @@ dissect_radius(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, void *data _
* if you do that.
*/
conversation = find_conversation(pinfo->num, &null_address,
&pinfo->dst, pinfo->ptype, pinfo->srcport, pinfo->destport, 0);
&pinfo->dst, conversation_pt_to_endpoint_type(pinfo->ptype), pinfo->srcport, pinfo->destport, 0);
if (conversation == NULL) {
/* Nothing more to do here */
break;

View File

@ -244,13 +244,13 @@ void rdt_add_address(packet_info *pinfo,
/* Check if the ip address and port combination is not already registered
as a conversation. */
p_conv = find_conversation(pinfo->num, addr, &null_addr, PT_UDP, port, other_port,
p_conv = find_conversation(pinfo->num, addr, &null_addr, ENDPOINT_UDP, port, other_port,
NO_ADDR_B | (!other_port ? NO_PORT_B : 0));
/* If not, create a new conversation. */
if ( !p_conv || p_conv->setup_frame != pinfo->num)
{
p_conv = conversation_new(pinfo->num, addr, &null_addr, PT_UDP,
p_conv = conversation_new(pinfo->num, addr, &null_addr, ENDPOINT_UDP,
(guint32)port, (guint32)other_port,
NO_ADDR2 | (!other_port ? NO_PORT2 : 0));
}
@ -1233,7 +1233,7 @@ static void show_setup_info(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree)
{
/* First time, get info from conversation */
p_conv = find_conversation(pinfo->num, &pinfo->net_dst, &pinfo->net_src,
pinfo->ptype,
conversation_pt_to_endpoint_type(pinfo->ptype),
pinfo->destport, pinfo->srcport, NO_ADDR_B);
if (p_conv)
{

View File

@ -223,7 +223,7 @@ dissect_reload_framing_message(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tr
if (!conversation) {
conversation = conversation_new(pinfo->num, &pinfo->src, &pinfo->dst,
pinfo->ptype, pinfo->srcport, pinfo->destport, 0);
conversation_pt_to_endpoint_type(pinfo->ptype), pinfo->srcport, pinfo->destport, 0);
}
/*

View File

@ -332,9 +332,7 @@ ros_match_call_response(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, gui
conversation_t *conversation;
/* first see if we have already matched this */
conversation = find_conversation(pinfo->num, &pinfo->src, &pinfo->dst,
pinfo->ptype, pinfo->srcport,
pinfo->destport, 0);
conversation = find_conversation_pinfo(pinfo, 0);
if (conversation == NULL)
return NULL;
@ -1012,7 +1010,7 @@ dissect_ros_Code(gboolean implicit_tag _U_, tvbuff_t *tvb _U_, int offset _U_, a
/*--- End of included file: packet-ros-fn.c ---*/
#line 377 "./asn1/ros/packet-ros-template.c"
#line 375 "./asn1/ros/packet-ros-template.c"
/*
* Dissect ROS PDUs inside a PPDU.
@ -1208,7 +1206,7 @@ void proto_register_ros(void) {
"OBJECT_IDENTIFIER", HFILL }},
/*--- End of included file: packet-ros-hfarr.c ---*/
#line 460 "./asn1/ros/packet-ros-template.c"
#line 458 "./asn1/ros/packet-ros-template.c"
};
/* List of subtrees */
@ -1238,7 +1236,7 @@ void proto_register_ros(void) {
&ett_ros_Code,
/*--- End of included file: packet-ros-ettarr.c ---*/
#line 476 "./asn1/ros/packet-ros-template.c"
#line 474 "./asn1/ros/packet-ros-template.c"
};
static ei_register_info ei[] = {

View File

@ -1661,18 +1661,18 @@ get_conversation_for_call(packet_info *pinfo)
* if you use NO_ADDR_B.
*/
conversation = find_conversation(pinfo->num,
&pinfo->src, &null_address, pinfo->ptype,
&pinfo->src, &null_address, conversation_pt_to_endpoint_type(pinfo->ptype),
pinfo->destport, 0, NO_ADDR_B|NO_PORT_B);
}
if (conversation == NULL) {
if (pinfo->ptype == PT_TCP || pinfo->ptype == PT_IBQP) {
conversation = conversation_new(pinfo->num,
&pinfo->src, &pinfo->dst, pinfo->ptype,
&pinfo->src, &pinfo->dst, conversation_pt_to_endpoint_type(pinfo->ptype),
pinfo->srcport, pinfo->destport, 0);
} else {
conversation = conversation_new(pinfo->num,
&pinfo->src, &null_address, pinfo->ptype,
&pinfo->src, &null_address, conversation_pt_to_endpoint_type(pinfo->ptype),
pinfo->destport, 0, NO_ADDR2|NO_PORT2);
}
}
@ -1713,7 +1713,7 @@ find_conversation_for_reply(packet_info *pinfo)
* if you use NO_ADDR_B.
*/
conversation = find_conversation(pinfo->num,
&pinfo->dst, &null_address, pinfo->ptype,
&pinfo->dst, &null_address, conversation_pt_to_endpoint_type(pinfo->ptype),
pinfo->srcport, 0, NO_ADDR_B|NO_PORT_B);
}
return conversation;
@ -1724,36 +1724,23 @@ new_conversation_for_reply(packet_info *pinfo)
{
conversation_t *conversation;
if (pinfo->ptype == PT_TCP || pinfo->ptype == PT_IBQP) {
switch (pinfo->ptype)
{
case PT_TCP:
conversation = conversation_new(pinfo->num,
&pinfo->src, &pinfo->dst, pinfo->ptype,
&pinfo->src, &pinfo->dst, ENDPOINT_TCP,
pinfo->srcport, pinfo->destport, 0);
} else {
break;
case PT_IBQP:
conversation = conversation_new(pinfo->num,
&pinfo->dst, &null_address, pinfo->ptype,
&pinfo->src, &pinfo->dst, ENDPOINT_IBQP,
pinfo->srcport, pinfo->destport, 0);
break;
default:
conversation = conversation_new(pinfo->num,
&pinfo->dst, &null_address, conversation_pt_to_endpoint_type(pinfo->ptype),
pinfo->srcport, 0, NO_ADDR2|NO_PORT2);
}
return conversation;
}
static conversation_t *
get_conversation_for_tcp(packet_info *pinfo)
{
conversation_t *conversation;
/*
* We know this is running over TCP, so the conversation should
* not wildcard either address or port, regardless of whether
* this is a call or reply.
*/
conversation = find_conversation_pinfo(pinfo, 0);
if (conversation == NULL) {
/*
* It's not part of any conversation - create a new one.
*/
conversation = conversation_new(pinfo->num,
&pinfo->src, &pinfo->dst, pinfo->ptype,
pinfo->srcport, pinfo->destport, 0);
break;
}
return conversation;
}
@ -3315,7 +3302,7 @@ dissect_rpc_fragment(tvbuff_t *tvb, int offset, packet_info *pinfo,
it doesn't already exist, and make the
dissector for it the non-heuristic RPC
dissector for RPC-over-TCP. */
conversation = get_conversation_for_tcp(pinfo);
conversation = find_or_create_conversation(pinfo);
conversation_set_dissector(conversation,
rpc_tcp_handle);
}
@ -3379,7 +3366,7 @@ dissect_rpc_fragment(tvbuff_t *tvb, int offset, packet_info *pinfo,
* one, create it.
*/
if (conversation == NULL)
conversation = get_conversation_for_tcp(pinfo);
conversation = find_or_create_conversation(pinfo);
old_rfk.conv_id = conversation->conv_index;
old_rfk.seq = seq;
old_rfk.port = pinfo->srcport;

View File

@ -39126,7 +39126,7 @@ dissect_rrc_C_RNTI(tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, prot
/* Finding FP conversation info */
p_conv = (conversation_t *)find_conversation(actx->pinfo->num, &actx->pinfo->net_dst, &actx->pinfo->net_src,
actx->pinfo->ptype,
conversation_pt_to_endpoint_type(actx->pinfo->ptype),
actx->pinfo->destport, actx->pinfo->srcport, NO_ADDR_B);
/* If the current FP channel is FACH, Adding the C-RNTI / U-RNTI match to the FACH's RNTIs map*/

View File

@ -748,14 +748,14 @@ void srtcp_add_address( packet_info *pinfo,
* Check if the ip address and port combination is not
* already registered as a conversation.
*/
p_conv = find_conversation( pinfo->num, addr, &null_addr, PT_UDP, port, other_port,
p_conv = find_conversation( pinfo->num, addr, &null_addr, ENDPOINT_UDP, port, other_port,
NO_ADDR_B | (!other_port ? NO_PORT_B : 0));
/*
* If not, create a new conversation.
*/
if ( ! p_conv ) {
p_conv = conversation_new( pinfo->num, addr, &null_addr, PT_UDP,
p_conv = conversation_new( pinfo->num, addr, &null_addr, ENDPOINT_UDP,
(guint32)port, (guint32)other_port,
NO_ADDR2 | (!other_port ? NO_PORT2 : 0));
}
@ -2990,7 +2990,7 @@ void show_setup_info(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree)
conversation_t *p_conv;
/* First time, get info from conversation */
p_conv = find_conversation(pinfo->num, &pinfo->net_dst, &pinfo->net_src,
pinfo->ptype,
conversation_pt_to_endpoint_type(pinfo->ptype),
pinfo->destport, pinfo->srcport, NO_ADDR_B);
if (p_conv)
@ -3068,13 +3068,13 @@ static void remember_outgoing_sr(packet_info *pinfo, guint32 lsr)
Even though we think of this as an outgoing packet being sent,
we store the time as being received by the destination. */
p_conv = find_conversation(pinfo->num, &pinfo->net_dst, &pinfo->net_src,
pinfo->ptype,
conversation_pt_to_endpoint_type(pinfo->ptype),
pinfo->destport, pinfo->srcport, NO_ADDR_B);
/* If the conversation doesn't exist, create it now. */
if (!p_conv)
{
p_conv = conversation_new(pinfo->num, &pinfo->net_dst, &pinfo->net_src, PT_UDP,
p_conv = conversation_new(pinfo->num, &pinfo->net_dst, &pinfo->net_src, ENDPOINT_UDP,
pinfo->destport, pinfo->srcport,
NO_ADDR2);
if (!p_conv)
@ -3160,7 +3160,7 @@ static void calculate_roundtrip_delay(tvbuff_t *tvb, packet_info *pinfo,
/* Look for captured timestamp of last SR in conversation of sender */
/* of this packet */
p_conv = find_conversation(pinfo->num, &pinfo->net_src, &pinfo->net_dst,
pinfo->ptype,
conversation_pt_to_endpoint_type(pinfo->ptype),
pinfo->srcport, pinfo->destport, NO_ADDR_B);
if (!p_conv)
{
@ -3314,7 +3314,7 @@ dissect_rtcp( tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, void* data _U
/* first see if this conversation is encrypted SRTP, and if so do not try to dissect the payload(s) */
p_conv = find_conversation(pinfo->num, &pinfo->net_src, &pinfo->net_dst,
pinfo->ptype,
conversation_pt_to_endpoint_type(pinfo->ptype),
pinfo->srcport, pinfo->destport, NO_ADDR_B);
if (p_conv)
{

View File

@ -2365,16 +2365,16 @@ dissect_rtmpt_http(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, void* da
cdir = pinfo->srcport == pinfo->match_uint;
if (cdir) {
conv = find_conversation(pinfo->num, &pinfo->dst, &pinfo->src, pinfo->ptype, 0, pinfo->srcport, 0);
conv = find_conversation(pinfo->num, &pinfo->dst, &pinfo->src, conversation_pt_to_endpoint_type(pinfo->ptype), 0, pinfo->srcport, 0);
if (!conv) {
RTMPT_DEBUG("RTMPT new conversation\n");
conv = conversation_new(pinfo->num, &pinfo->dst, &pinfo->src, pinfo->ptype, 0, pinfo->srcport, 0);
conv = conversation_new(pinfo->num, &pinfo->dst, &pinfo->src, conversation_pt_to_endpoint_type(pinfo->ptype), 0, pinfo->srcport, 0);
}
} else {
conv = find_conversation(pinfo->num, &pinfo->src, &pinfo->dst, pinfo->ptype, 0, pinfo->destport, 0);
conv = find_conversation(pinfo->num, &pinfo->src, &pinfo->dst, conversation_pt_to_endpoint_type(pinfo->ptype), 0, pinfo->destport, 0);
if (!conv) {
RTMPT_DEBUG("RTMPT new conversation\n");
conv = conversation_new(pinfo->num, &pinfo->src, &pinfo->dst, pinfo->ptype, 0, pinfo->destport, 0);
conv = conversation_new(pinfo->num, &pinfo->src, &pinfo->dst, conversation_pt_to_endpoint_type(pinfo->ptype), 0, pinfo->destport, 0);
}
}

View File

@ -1169,14 +1169,14 @@ bluetooth_add_address(packet_info *pinfo, address *addr, guint32 stream_number,
* Check if the ip address and port combination is not
* already registered as a conversation.
*/
p_conv = find_conversation(setup_frame_number, addr, &null_addr, PT_BLUETOOTH, stream_number, stream_number,
p_conv = find_conversation(setup_frame_number, addr, &null_addr, ENDPOINT_BLUETOOTH, stream_number, stream_number,
NO_ADDR_B | NO_PORT_B);
/*
* If not, create a new conversation.
*/
if (!p_conv || p_conv->setup_frame != setup_frame_number) {
p_conv = conversation_new(setup_frame_number, addr, &null_addr, PT_BLUETOOTH, stream_number, stream_number,
p_conv = conversation_new(setup_frame_number, addr, &null_addr, ENDPOINT_BLUETOOTH, stream_number, stream_number,
NO_ADDR2 | NO_PORT2);
}
@ -1258,7 +1258,7 @@ srtp_add_address(packet_info *pinfo, const port_type ptype, address *addr, int p
* Check if the ip address and port combination is not
* already registered as a conversation.
*/
p_conv = find_conversation(setup_frame_number, addr, &null_addr, ptype, port, other_port,
p_conv = find_conversation(setup_frame_number, addr, &null_addr, conversation_pt_to_endpoint_type(ptype), port, other_port,
NO_ADDR_B | (!other_port ? NO_PORT_B : 0));
DENDENT();
@ -1268,7 +1268,7 @@ srtp_add_address(packet_info *pinfo, const port_type ptype, address *addr, int p
* If not, create a new conversation.
*/
if (!p_conv || p_conv->setup_frame != setup_frame_number) {
p_conv = conversation_new(setup_frame_number, addr, &null_addr, ptype,
p_conv = conversation_new(setup_frame_number, addr, &null_addr, conversation_pt_to_endpoint_type(ptype),
(guint32)port, (guint32)other_port,
NO_ADDR2 | (!other_port ? NO_PORT2 : 0));
}
@ -1390,11 +1390,11 @@ dissect_rtp_heur_common(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, voi
}
/* Create a conversation in case none exists so as to allow reassembly code to work */
if (!find_conversation(pinfo->num, &pinfo->net_dst, &pinfo->net_src, pinfo->ptype,
if (!find_conversation(pinfo->num, &pinfo->net_dst, &pinfo->net_src, conversation_pt_to_endpoint_type(pinfo->ptype),
pinfo->destport, pinfo->srcport, NO_ADDR2)) {
conversation_t *p_conv;
struct _rtp_conversation_info *p_conv_data;
p_conv = conversation_new(pinfo->num, &pinfo->net_dst, &pinfo->net_src, pinfo->ptype,
p_conv = conversation_new(pinfo->num, &pinfo->net_dst, &pinfo->net_src, conversation_pt_to_endpoint_type(pinfo->ptype),
pinfo->destport, pinfo->srcport, NO_ADDR2);
p_conv_data = (struct _rtp_conversation_info *)conversation_get_proto_data(p_conv, proto_rtp);
if (! p_conv_data) {
@ -2733,7 +2733,7 @@ get_conv_info(packet_info *pinfo, struct _rtp_info *rtp_info)
/* First time, get info from conversation */
p_conv = find_conversation(pinfo->num, &pinfo->net_dst, &pinfo->net_src,
pinfo->ptype,
conversation_pt_to_endpoint_type(pinfo->ptype),
pinfo->destport, pinfo->srcport, NO_ADDR_B);
if (p_conv)
{

View File

@ -3242,10 +3242,10 @@ dissect_snmp(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, void *data _U_
* wildcarded, and give it the SNMP dissector as a dissector.
*/
if (pinfo->destport == UDP_PORT_SNMP) {
conversation = find_conversation(pinfo->num, &pinfo->src, &pinfo->dst, PT_UDP,
conversation = find_conversation(pinfo->num, &pinfo->src, &pinfo->dst, ENDPOINT_UDP,
pinfo->srcport, 0, NO_PORT_B);
if( (conversation == NULL) || (conversation_get_dissector(conversation, pinfo->num)!=snmp_handle) ) {
conversation = conversation_new(pinfo->num, &pinfo->src, &pinfo->dst, PT_UDP,
conversation = conversation_new(pinfo->num, &pinfo->src, &pinfo->dst, ENDPOINT_UDP,
pinfo->srcport, 0, NO_PORT2);
conversation_set_dissector(conversation, snmp_handle);
}

View File

@ -387,7 +387,7 @@ socks_udp_dissector(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, void* d
static void
new_udp_conversation( socks_hash_entry_t *hash_info, packet_info *pinfo){
conversation_t *conversation = conversation_new( pinfo->num, &pinfo->src, &pinfo->dst, PT_UDP,
conversation_t *conversation = conversation_new( pinfo->num, &pinfo->src, &pinfo->dst, ENDPOINT_UDP,
hash_info->udp_port, hash_info->port, 0);
DISSECTOR_ASSERT( conversation);
@ -1011,7 +1011,7 @@ dissect_socks(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, void *data) {
return 0;
conversation = conversation_new(pinfo->num, &pinfo->src, &pinfo->dst,
pinfo->ptype, pinfo->srcport, pinfo->destport, 0);
conversation_pt_to_endpoint_type(pinfo->ptype), pinfo->srcport, pinfo->destport, 0);
}
hash_info = (socks_hash_entry_t *)conversation_get_proto_data(conversation,proto_socks);

View File

@ -213,7 +213,7 @@ dissect_soupbintcp_common(
conv = conversation_new(pinfo->num,
&pinfo->src,
&pinfo->dst,
pinfo->ptype,
conversation_pt_to_endpoint_type(pinfo->ptype),
pinfo->srcport,
pinfo->destport,
0);
@ -391,7 +391,7 @@ dissect_soupbintcp_common(
/* If this packet is part of a conversation, call dissector
* for the conversation if available */
if (try_conversation_dissector(&pinfo->dst, &pinfo->src, pinfo->ptype,
if (try_conversation_dissector(&pinfo->dst, &pinfo->src, conversation_pt_to_endpoint_type(pinfo->ptype),
pinfo->srcport, pinfo->destport,
sub_tvb, pinfo, tree, NULL)) {
return;

View File

@ -782,14 +782,14 @@ void sprt_add_address(packet_info *pinfo,
* Check if the ip address and port combination is not
* already registered as a conversation.
*/
p_conv = find_conversation(setup_frame_number, addr, &null_addr, PT_UDP, port, other_port,
p_conv = find_conversation(setup_frame_number, addr, &null_addr, ENDPOINT_UDP, port, other_port,
NO_ADDR_B | (!other_port ? NO_PORT_B : 0));
/*
* If not, create a new conversation.
*/
if (!p_conv || p_conv->setup_frame != setup_frame_number) {
p_conv = conversation_new(setup_frame_number, addr, &null_addr, PT_UDP,
p_conv = conversation_new(setup_frame_number, addr, &null_addr, ENDPOINT_UDP,
(guint32)port, (guint32)other_port,
NO_ADDR2 | (!other_port ? NO_PORT2 : 0));
}

View File

@ -3366,11 +3366,11 @@ void ssl_set_master_secret(guint32 frame_num, address *addr_srv, address *addr_c
ssl_debug_printf("\nssl_set_master_secret enter frame #%u\n", frame_num);
conversation = find_conversation(frame_num, addr_srv, addr_cli, ptype, port_srv, port_cli, 0);
conversation = find_conversation(frame_num, addr_srv, addr_cli, conversation_pt_to_endpoint_type(ptype), port_srv, port_cli, 0);
if (!conversation) {
/* create a new conversation */
conversation = conversation_new(frame_num, addr_srv, addr_cli, ptype, port_srv, port_cli, 0);
conversation = conversation_new(frame_num, addr_srv, addr_cli, conversation_pt_to_endpoint_type(ptype), port_srv, port_cli, 0);
ssl_debug_printf(" new conversation = %p created\n", (void *)conversation);
}
ssl = ssl_get_session(conversation, ssl_handle);

View File

@ -268,14 +268,14 @@ void t38_add_address(packet_info *pinfo,
* Check if the ip address and port combination is not
* already registered as a conversation.
*/
p_conversation = find_conversation( setup_frame_number, addr, &null_addr, PT_UDP, port, other_port,
p_conversation = find_conversation( setup_frame_number, addr, &null_addr, ENDPOINT_UDP, port, other_port,
NO_ADDR_B | (!other_port ? NO_PORT_B : 0));
/*
* If not, create a new conversation.
*/
if ( !p_conversation || p_conversation->setup_frame != setup_frame_number) {
p_conversation = conversation_new( setup_frame_number, addr, &null_addr, PT_UDP,
p_conversation = conversation_new( setup_frame_number, addr, &null_addr, ENDPOINT_UDP,
(guint32)port, (guint32)other_port,
NO_ADDR2 | (!other_port ? NO_PORT2 : 0));
}
@ -1007,13 +1007,13 @@ init_t38_info_conv(packet_info *pinfo)
/* find the conversation used for Reassemble and Setup Info */
p_conv = find_conversation(pinfo->num, &pinfo->net_dst, &pinfo->net_src,
pinfo->ptype,
conversation_pt_to_endpoint_type(pinfo->ptype),
pinfo->destport, pinfo->srcport, NO_ADDR_B | NO_PORT_B);
/* create a conv if it doen't exist */
if (!p_conv) {
p_conv = conversation_new(pinfo->num, &pinfo->net_src, &pinfo->net_dst,
pinfo->ptype, pinfo->srcport, pinfo->destport, NO_ADDR_B | NO_PORT_B);
conversation_pt_to_endpoint_type(pinfo->ptype), pinfo->srcport, pinfo->destport, NO_ADDR_B | NO_PORT_B);
/* Set dissector */
conversation_set_dissector(p_conv, t38_udp_handle);

View File

@ -1284,7 +1284,7 @@ static void
handle_export_pdu_conversation(packet_info *pinfo, tvbuff_t *tvb, int src_port, int dst_port, struct tcpinfo *tcpinfo)
{
if (have_tap_listener(exported_pdu_tap)) {
conversation_t *conversation = find_conversation(pinfo->num, &pinfo->src, &pinfo->dst, PT_TCP, src_port, dst_port, 0);
conversation_t *conversation = find_conversation(pinfo->num, &pinfo->src, &pinfo->dst, ENDPOINT_TCP, src_port, dst_port, 0);
if (conversation != NULL)
{
dissector_handle_t handle = (dissector_handle_t)wmem_tree_lookup32_le(conversation->dissector_tree, pinfo->num);
@ -1547,7 +1547,7 @@ add_tcp_process_info(guint32 frame_num, address *local_addr, address *remote_add
if (!tcp_display_process_info)
return;
conv = find_conversation(frame_num, local_addr, remote_addr, PT_TCP, local_port, remote_port, 0);
conv = find_conversation(frame_num, local_addr, remote_addr, ENDPOINT_TCP, local_port, remote_port, 0);
if (!conv) {
return;
}
@ -5484,7 +5484,7 @@ decode_tcp_ports(tvbuff_t *tvb, int offset, packet_info *pinfo,
/* determine if this packet is part of a conversation and call dissector */
/* for the conversation if available */
if (try_conversation_dissector(&pinfo->src, &pinfo->dst, PT_TCP,
if (try_conversation_dissector(&pinfo->src, &pinfo->dst, ENDPOINT_TCP,
src_port, dst_port, next_tvb, pinfo, tree, tcpinfo)) {
pinfo->want_pdu_tracking -= !!(pinfo->want_pdu_tracking);
handle_export_pdu_conversation(pinfo, next_tvb, src_port, dst_port, tcpinfo);
@ -5835,7 +5835,7 @@ dissect_tcp(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, void* data _U_)
}
else {
conv = conversation_new(pinfo->num, &pinfo->src,
&pinfo->dst, pinfo->ptype,
&pinfo->dst, ENDPOINT_TCP,
pinfo->srcport, pinfo->destport, 0);
}
tcpd=get_tcp_conversation_data(conv,pinfo);
@ -5856,7 +5856,7 @@ dissect_tcp(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, void* data _U_)
if (save_last_frame > 0)
conv->last_frame = save_last_frame;
conv=conversation_new(pinfo->num, &pinfo->src, &pinfo->dst, pinfo->ptype, pinfo->srcport, pinfo->destport, 0);
conv=conversation_new(pinfo->num, &pinfo->src, &pinfo->dst, ENDPOINT_TCP, pinfo->srcport, pinfo->destport, 0);
tcpd=get_tcp_conversation_data(conv,pinfo);
}
if(!tcpd->ta)
@ -5880,7 +5880,7 @@ dissect_tcp(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, void* data _U_)
conv->last_frame = save_last_frame;
}
other_conv = find_conversation(pinfo->num, &pinfo->dst, &pinfo->src, pinfo->ptype, pinfo->destport, pinfo->srcport, 0);
other_conv = find_conversation(pinfo->num, &pinfo->dst, &pinfo->src, ENDPOINT_TCP, pinfo->destport, pinfo->srcport, 0);
if (other_conv != NULL)
{
conv = other_conv;

View File

@ -659,17 +659,17 @@ dissect_tftp(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, void* data _U_
*/
if (value_is_in_range(global_tftp_port_range, pinfo->destport) ||
(pinfo->match_uint == pinfo->destport)) {
conversation = find_conversation(pinfo->num, &pinfo->src, &pinfo->dst, PT_UDP,
conversation = find_conversation(pinfo->num, &pinfo->src, &pinfo->dst, ENDPOINT_UDP,
pinfo->srcport, 0, NO_PORT_B);
if( (conversation == NULL) || (conversation_get_dissector(conversation, pinfo->num) != tftp_handle) ){
conversation = conversation_new(pinfo->num, &pinfo->src, &pinfo->dst, PT_UDP,
conversation = conversation_new(pinfo->num, &pinfo->src, &pinfo->dst, ENDPOINT_UDP,
pinfo->srcport, 0, NO_PORT2);
conversation_set_dissector(conversation, tftp_handle);
}
} else {
conversation = find_conversation_pinfo(pinfo, 0);
if( (conversation == NULL) || (conversation_get_dissector(conversation, pinfo->num) != tftp_handle) ){
conversation = conversation_new(pinfo->num, &pinfo->src, &pinfo->dst, PT_UDP,
conversation = conversation_new(pinfo->num, &pinfo->src, &pinfo->dst, ENDPOINT_UDP,
pinfo->destport, pinfo->srcport, 0);
conversation_set_dissector(conversation, tftp_handle);
} else if (conversation->options & NO_PORT_B) {

View File

@ -480,7 +480,7 @@ add_udp_process_info(guint32 frame_num, address *local_addr, address *remote_add
return;
}
conv = find_conversation(frame_num, local_addr, remote_addr, PT_UDP, local_port, remote_port, 0);
conv = find_conversation(frame_num, local_addr, remote_addr, ENDPOINT_UDP, local_port, remote_port, 0);
if (!conv) {
return;
}
@ -569,7 +569,7 @@ static void
handle_export_pdu_conversation(packet_info *pinfo, tvbuff_t *tvb, int uh_dport, int uh_sport)
{
if (have_tap_listener(exported_pdu_tap)) {
conversation_t *conversation = find_conversation(pinfo->num, &pinfo->dst, &pinfo->src, PT_UDP, uh_dport, uh_sport, 0);
conversation_t *conversation = find_conversation(pinfo->num, &pinfo->dst, &pinfo->src, ENDPOINT_UDP, uh_dport, uh_sport, 0);
if (conversation != NULL)
{
dissector_handle_t handle = (dissector_handle_t)wmem_tree_lookup32_le(conversation->dissector_tree, pinfo->num);
@ -631,7 +631,7 @@ decode_udp_ports(tvbuff_t *tvb, int offset, packet_info *pinfo,
/* determine if this packet is part of a conversation and call dissector */
/* for the conversation if available */
if (try_conversation_dissector(&pinfo->dst, &pinfo->src, PT_UDP,
if (try_conversation_dissector(&pinfo->dst, &pinfo->src, ENDPOINT_UDP,
uh_dport, uh_sport, next_tvb, pinfo, tree, NULL)) {
handle_export_pdu_conversation(pinfo, next_tvb, uh_dport, uh_sport);
return;

View File

@ -1475,14 +1475,14 @@ dissect_uma_IE(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, int offset)
set_address(&dst_addr, AT_IPv4, 4, &GPRS_user_data_ipv4_address);
conversation = find_conversation(pinfo->num,&dst_addr,
&null_addr, PT_UDP, GPRS_user_data_transport_UDP_port,
conversation = find_conversation(pinfo->num, &dst_addr,
&null_addr, ENDPOINT_UDP, GPRS_user_data_transport_UDP_port,
0, NO_ADDR_B|NO_PORT_B);
if (conversation == NULL) {
/* It's not part of any conversation - create a new one. */
conversation = conversation_new(pinfo->num, &dst_addr,
&null_addr, PT_UDP,GPRS_user_data_transport_UDP_port ,
&null_addr, ENDPOINT_UDP, GPRS_user_data_transport_UDP_port ,
0, NO_ADDR2|NO_PORT2);
/* Set dissector */
@ -1507,14 +1507,14 @@ dissect_uma_IE(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, int offset)
set_address(&dst_addr, AT_IPv4, 4, &unc_ipv4_address);
conversation = find_conversation(pinfo->num,&dst_addr,
&null_addr, PT_TCP, UNC_tcp_port,
conversation = find_conversation(pinfo->num, &dst_addr,
&null_addr, ENDPOINT_TCP, UNC_tcp_port,
0, NO_ADDR_B|NO_PORT_B);
if (conversation == NULL) {
/* It's not part of any conversation - create a new one. */
conversation = conversation_new(pinfo->num, &dst_addr,
&null_addr, PT_TCP,UNC_tcp_port ,
&null_addr, ENDPOINT_TCP, UNC_tcp_port,
0, NO_ADDR2|NO_PORT2);
/* Set dissector */
conversation_set_dissector(conversation, uma_tcp_handle);

View File

@ -4037,26 +4037,26 @@ set_both_sides_umts_fp_conv_data(packet_info *pinfo, umts_fp_conversation_info_t
/* Finding or creating conversation for the way the packet is heading */
packet_direction_conv = (conversation_t *)find_conversation(pinfo->num, &pinfo->net_dst, &pinfo->net_src,
pinfo->ptype,
conversation_pt_to_endpoint_type(pinfo->ptype),
pinfo->destport, pinfo->srcport, NO_ADDR_B);
if (packet_direction_conv == NULL) {
/* Conversation does not exist yet, creating one now. */
packet_direction_conv = conversation_new(pinfo->num, &pinfo->net_dst, &pinfo->net_src,
pinfo->ptype,
conversation_pt_to_endpoint_type(pinfo->ptype),
pinfo->destport, pinfo->srcport, NO_ADDR_B);
}
conversation_add_proto_data(packet_direction_conv, proto_fp, umts_fp_conversation_info);
/* Finding or creating conversation for the other side */
other_direction_conv = (conversation_t *)find_conversation(pinfo->num, &pinfo->net_src, &pinfo->net_dst,
pinfo->ptype,
conversation_pt_to_endpoint_type(pinfo->ptype),
pinfo->srcport, pinfo->destport, NO_ADDR_B);
if (other_direction_conv == NULL) {
/* Conversation does not exist yet, creating one now. */
other_direction_conv = conversation_new(pinfo->num, &pinfo->net_src, &pinfo->net_dst,
pinfo->ptype,
conversation_pt_to_endpoint_type(pinfo->ptype),
pinfo->srcport, pinfo->destport, NO_ADDR_B);
}
conversation_add_proto_data(other_direction_conv, proto_fp, umts_fp_conversation_info);
@ -4075,7 +4075,7 @@ heur_dissect_fp_dcch_over_dch(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tre
/* Trying to find existing conversation */
p_conv = (conversation_t *)find_conversation(pinfo->num, &pinfo->net_dst, &pinfo->net_src,
pinfo->ptype,
conversation_pt_to_endpoint_type(pinfo->ptype),
pinfo->destport, pinfo->srcport, NO_ADDR_B);
if (p_conv != NULL) {
@ -4130,7 +4130,7 @@ heur_dissect_fp_dcch_over_dch(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tre
/* the conversation must be created here if it doesn't exist yet*/
if (p_conv == NULL) {
conversation_new(pinfo->num, &pinfo->net_dst, &pinfo->net_src,
pinfo->ptype,
conversation_pt_to_endpoint_type(pinfo->ptype),
pinfo->destport, pinfo->srcport, NO_ADDR_B);
}
return FALSE;
@ -4201,7 +4201,7 @@ heur_dissect_fp_fach1(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, void
/* Finding or creating conversation */
p_conv = (conversation_t *)find_conversation(pinfo->num, &pinfo->net_dst, &pinfo->net_src,
pinfo->ptype,
conversation_pt_to_endpoint_type(pinfo->ptype),
pinfo->destport, pinfo->srcport, NO_ADDR_B);
if (p_conv != NULL) {
@ -4311,7 +4311,7 @@ heur_dissect_fp_fach2(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, void
/* Finding or creating conversation */
p_conv = (conversation_t *)find_conversation(pinfo->num, &pinfo->net_dst, &pinfo->net_src,
pinfo->ptype,
conversation_pt_to_endpoint_type(pinfo->ptype),
pinfo->destport, pinfo->srcport, NO_ADDR_B);
if (p_conv != NULL) {
@ -4426,7 +4426,7 @@ heur_dissect_fp_rach(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, void *
/* Finding or creating conversation */
p_conv = (conversation_t *)find_conversation(pinfo->num, &pinfo->net_dst, &pinfo->net_src,
pinfo->ptype,
conversation_pt_to_endpoint_type(pinfo->ptype),
pinfo->destport, pinfo->srcport, NO_ADDR_B);
if (p_conv != NULL) {
@ -4550,7 +4550,7 @@ heur_dissect_fp_pch(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, void *d
/* Finding or creating conversation */
p_conv = (conversation_t *)find_conversation(pinfo->num, &pinfo->net_dst, &pinfo->net_src,
pinfo->ptype,
conversation_pt_to_endpoint_type(pinfo->ptype),
pinfo->destport, pinfo->srcport, NO_ADDR_B);
if (p_conv != NULL) {
@ -4736,7 +4736,7 @@ heur_dissect_fp_hsdsch_type_1(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tre
/* Trying to find existing conversation */
p_conv = (conversation_t *)find_conversation(pinfo->num, &pinfo->net_dst, &pinfo->net_src,
pinfo->ptype,
conversation_pt_to_endpoint_type(pinfo->ptype),
pinfo->destport, pinfo->srcport, NO_ADDR_B);
if (p_conv != NULL) {
@ -4867,7 +4867,7 @@ heur_dissect_fp_hsdsch_type_2(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tre
/* Trying to find existing conversation */
p_conv = (conversation_t *)find_conversation(pinfo->num, &pinfo->net_dst, &pinfo->net_src,
pinfo->ptype,
conversation_pt_to_endpoint_type(pinfo->ptype),
pinfo->destport, pinfo->srcport, NO_ADDR_B);
if (p_conv != NULL) {
@ -5026,7 +5026,7 @@ heur_dissect_fp_unknown_format(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tr
/* Trying to find existing conversation */
p_conv = (conversation_t *)find_conversation(pinfo->num, &pinfo->net_dst, &pinfo->net_src,
pinfo->ptype,
conversation_pt_to_endpoint_type(pinfo->ptype),
pinfo->destport, pinfo->srcport, NO_ADDR_B);
/* Check if FP Conversation Info is attached */
@ -5570,7 +5570,7 @@ dissect_fp_common(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, void *dat
/* Check if we have conversation info */
/* Trying to find exact match - with both RNC's address & port and Node B's address & port */
p_conv = (conversation_t *)find_conversation(pinfo->num, &pinfo->net_dst, &pinfo->net_src,
pinfo->ptype,
conversation_pt_to_endpoint_type(pinfo->ptype),
pinfo->destport, pinfo->srcport, 0);
if (p_conv) {
p_conv_data = (umts_fp_conversation_info_t *)conversation_get_proto_data(p_conv, proto_fp);
@ -5579,7 +5579,7 @@ dissect_fp_common(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, void *dat
/* Didn't find exact conversation match */
/* Try to find a partial match with just the source/destination included */
p_conv = (conversation_t *)find_conversation(pinfo->num, &pinfo->net_dst, &pinfo->net_src,
pinfo->ptype,
conversation_pt_to_endpoint_type(pinfo->ptype),
pinfo->destport, pinfo->srcport, NO_ADDR2);
if (p_conv) {
p_conv_data = (umts_fp_conversation_info_t *)conversation_get_proto_data(p_conv, proto_fp);
@ -5886,10 +5886,10 @@ umts_fp_init_protocol(void)
} else {
continue; /* Not implemented yet */
}
conversation = find_conversation(1, &src_addr, &dst_addr, PT_UDP, uat_umts_fp_ep_and_ch_records[i].src_port, 0, NO_ADDR2|NO_PORT2);
conversation = find_conversation(1, &src_addr, &dst_addr, ENDPOINT_UDP, uat_umts_fp_ep_and_ch_records[i].src_port, 0, NO_ADDR2|NO_PORT2);
if (conversation == NULL) {
/* It's not part of any conversation - create a new one. */
conversation = conversation_new(1, &src_addr, &dst_addr, PT_UDP, uat_umts_fp_ep_and_ch_records[i].src_port, 0, NO_ADDR2|NO_PORT2);
conversation = conversation_new(1, &src_addr, &dst_addr, ENDPOINT_UDP, uat_umts_fp_ep_and_ch_records[i].src_port, 0, NO_ADDR2|NO_PORT2);
if (conversation == NULL)
continue;
conversation_set_dissector(conversation, fp_handle);

View File

@ -252,7 +252,7 @@ static guint16 tree_add_common_dcch_dtch_fields(tvbuff_t *tvb, packet_info *pinf
proto_tree_add_bits_item(tree, hf_mac_crnti, tvb, 4, 16, ENC_BIG_ENDIAN);
c_rnti = tvb_get_bits16(tvb, bitoffs, 16,ENC_BIG_ENDIAN);
p_conv = (conversation_t *)find_conversation(pinfo->num, &pinfo->net_dst, &pinfo->net_src,
pinfo->ptype,
conversation_pt_to_endpoint_type(pinfo->ptype),
pinfo->destport, pinfo->srcport, NO_ADDR_B);
if (p_conv != NULL) {
umts_fp_conversation_info = (umts_fp_conversation_info_t *)conversation_get_proto_data(p_conv, proto_fp);

View File

@ -1693,7 +1693,7 @@ get_usb_conversation(packet_info *pinfo,
*/
conversation = find_conversation(pinfo->num,
src_addr, dst_addr,
pinfo->ptype,
conversation_pt_to_endpoint_type(pinfo->ptype),
src_endpoint, dst_endpoint, 0);
if (conversation) {
return conversation;
@ -1702,7 +1702,7 @@ get_usb_conversation(packet_info *pinfo,
/* We don't yet have a conversation, so create one. */
conversation = conversation_new(pinfo->num,
src_addr, dst_addr,
pinfo->ptype,
conversation_pt_to_endpoint_type(pinfo->ptype),
src_endpoint, dst_endpoint, 0);
return conversation;
}

View File

@ -1069,7 +1069,7 @@ static gboolean test_vnc_protocol(tvbuff_t *tvb, packet_info *pinfo,
if (vnc_is_client_or_server_version_message(tvb, NULL, NULL)) {
conversation = conversation_new(pinfo->num, &pinfo->src,
&pinfo->dst, pinfo->ptype,
&pinfo->dst, conversation_pt_to_endpoint_type(pinfo->ptype),
pinfo->srcport,
pinfo->destport, 0);
conversation_set_dissector(conversation, vnc_handle);

View File

@ -4006,10 +4006,10 @@ dissect_redirect(tvbuff_t *tvb, int offset, packet_info *pinfo,
redir_address.data = (const guint8 *)&address_ipv4;
/* Find a conversation based on redir_address and pinfo->dst */
conv = find_conversation(pinfo->num, &redir_address, &pinfo->dst,
PT_UDP, port_num, 0, NO_PORT_B);
ENDPOINT_UDP, port_num, 0, NO_PORT_B);
if (conv == NULL) { /* This conversation does not exist yet */
conv = conversation_new(pinfo->num, &redir_address,
&pinfo->dst, PT_UDP, port_num, 0, NO_PORT2);
&pinfo->dst, ENDPOINT_UDP, port_num, 0, NO_PORT2);
}
/* Apply WSP dissection to the conversation */
conversation_set_dissector(conv, dissector_handle);
@ -4042,10 +4042,10 @@ dissect_redirect(tvbuff_t *tvb, int offset, packet_info *pinfo,
redir_address.data = (const guint8 *)&address_ipv6;
/* Find a conversation based on redir_address and pinfo->dst */
conv = find_conversation(pinfo->num, &redir_address, &pinfo->dst,
PT_UDP, port_num, 0, NO_PORT_B);
ENDPOINT_UDP, port_num, 0, NO_PORT_B);
if (conv == NULL) { /* This conversation does not exist yet */
conv = conversation_new(pinfo->num, &redir_address,
&pinfo->dst, PT_UDP, port_num, 0, NO_PORT2);
&pinfo->dst, ENDPOINT_UDP, port_num, 0, NO_PORT2);
}
/* Apply WSP dissection to the conversation */
conversation_set_dissector(conv, dissector_handle);

View File

@ -111,10 +111,10 @@ dissect_xyplex(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, void *data _
* return_port.
*/
conversation = find_conversation(pinfo->num, &pinfo->src, &pinfo->dst,
PT_TCP, return_port, 0, NO_PORT_B);
ENDPOINT_TCP, return_port, 0, NO_PORT_B);
if (conversation == NULL) {
conversation = conversation_new(pinfo->num, &pinfo->src, &pinfo->dst,
PT_TCP, return_port, 0, NO_PORT2);
ENDPOINT_TCP, return_port, 0, NO_PORT2);
conversation_set_dissector(conversation, xyplex_handle);
}
return offset;

View File

@ -1140,7 +1140,6 @@ port_type_to_str (port_type type)
case PT_NCP: return "NCP";
case PT_EXCHG: return "FC EXCHG";
case PT_DDP: return "DDP";
case PT_SBCCS: return "FICON SBCCS";
case PT_IDP: return "IDP";
case PT_TIPC: return "TIPC";
case PT_USB: return "USB";

View File

@ -537,7 +537,7 @@ static void dissect_iap_request(tvbuff_t* tvb, packet_info* pinfo, proto_tree* r
set_address(&destaddr, irda_address_type, 1, &circuit_id);
conv = find_conversation(pinfo->num, &srcaddr, &destaddr, PT_NONE, pinfo->srcport, pinfo->destport, 0);
conv = find_conversation(pinfo->num, &srcaddr, &destaddr, ENDPOINT_NONE, pinfo->srcport, pinfo->destport, 0);
if (conv)
{
iap_conv = (iap_conversation_t*)conversation_get_proto_data(conv, proto_iap);
@ -559,7 +559,7 @@ static void dissect_iap_request(tvbuff_t* tvb, packet_info* pinfo, proto_tree* r
}
else
{
conv = conversation_new(pinfo->num, &srcaddr, &destaddr, PT_NONE, pinfo->srcport, pinfo->destport, 0);
conv = conversation_new(pinfo->num, &srcaddr, &destaddr, ENDPOINT_NONE, pinfo->srcport, pinfo->destport, 0);
iap_conv = wmem_new(wmem_file_scope(), iap_conversation_t);
conversation_add_proto_data(conv, proto_iap, (void*)iap_conv);
}
@ -687,7 +687,7 @@ static void dissect_iap_result(tvbuff_t* tvb, packet_info* pinfo, proto_tree* ro
set_address(&destaddr, irda_address_type, 1, &circuit_id);
/* Find result value dissector */
conv = find_conversation(pinfo->num, &srcaddr, &destaddr, PT_NONE, pinfo->srcport, pinfo->destport, 0);
conv = find_conversation(pinfo->num, &srcaddr, &destaddr, ENDPOINT_NONE, pinfo->srcport, pinfo->destport, 0);
if (conv)
{
num = pinfo->num;
@ -968,7 +968,7 @@ static void dissect_appl_proto(tvbuff_t* tvb, packet_info* pinfo, proto_tree* ro
set_address(&destaddr, irda_address_type, 1, &circuit_id);
/* Find result value dissector */
conv = find_conversation(pinfo->num, &srcaddr, &destaddr, PT_NONE, pinfo->srcport, pinfo->destport, 0);
conv = find_conversation(pinfo->num, &srcaddr, &destaddr, ENDPOINT_NONE, pinfo->srcport, pinfo->destport, 0);
if (conv)
{
num = pinfo->num;
@ -1196,7 +1196,7 @@ void add_lmp_conversation(packet_info* pinfo, guint8 dlsap, gboolean ttp, dissec
dest = circuit_id ^ CMD_FRAME;
set_address(&destaddr, irda_address_type, 1, &dest);
conv = find_conversation(pinfo->num, &destaddr, &srcaddr, PT_NONE, dlsap, 0, NO_PORT_B);
conv = find_conversation(pinfo->num, &destaddr, &srcaddr, ENDPOINT_NONE, dlsap, 0, NO_PORT_B);
if (conv)
{
lmp_conv = (lmp_conversation_t*)conversation_get_proto_data(conv, proto_irlmp);
@ -1217,7 +1217,7 @@ void add_lmp_conversation(packet_info* pinfo, guint8 dlsap, gboolean ttp, dissec
}
else
{
conv = conversation_new(pinfo->num, &destaddr, &srcaddr, PT_NONE, dlsap, 0, NO_PORT_B);
conv = conversation_new(pinfo->num, &destaddr, &srcaddr, ENDPOINT_NONE, dlsap, 0, NO_PORT_B);
lmp_conv = wmem_new(wmem_file_scope(), lmp_conversation_t);
conversation_add_proto_data(conv, proto_irlmp, (void*)lmp_conv);
}

View File

@ -8272,12 +8272,12 @@ dissect_ARBlockReq_block(tvbuff_t *tvb, int offset,
/* When ARType==IOCARSR, then find or create conversation for this frame */
if (!pinfo->fd->flags.visited) {
/* Get current conversation endpoints using MAC addresses */
conversation = find_conversation(pinfo->num, &pinfo->dl_src, &pinfo->dl_dst, PT_UDP, 0, 0, 0);
conversation = find_conversation(pinfo->num, &pinfo->dl_src, &pinfo->dl_dst, ENDPOINT_UDP, 0, 0, 0);
if (conversation == NULL) {
/* If conversation is null, then create new conversation */
/* Connect Request is sent by controller and not by device. */
/* All conversations are based on Controller MAC as address */
conversation = conversation_new(pinfo->num, &pinfo->dl_src, &pinfo->dl_dst, PT_UDP, 0, 0, 0);
conversation = conversation_new(pinfo->num, &pinfo->dl_src, &pinfo->dl_dst, ENDPOINT_UDP, 0, 0, 0);
}
/* Try to get apdu status switch information from the conversation */
@ -8510,12 +8510,12 @@ dissect_IOCRBlockReq_block(tvbuff_t *tvb, int offset,
/* Notice: Handle Input & Output seperate!!! */
if (!pinfo->fd->flags.visited) {
/* Get current conversation endpoints using MAC addresses */
conversation = find_conversation(pinfo->num, &pinfo->dl_src, &pinfo->dl_dst, PT_NONE, 0, 0, 0);
conversation = find_conversation(pinfo->num, &pinfo->dl_src, &pinfo->dl_dst, ENDPOINT_NONE, 0, 0, 0);
if (conversation == NULL) {
/* Create new conversation, if no "Ident OK" frame as been dissected yet!
* Need to switch dl_src & dl_dst, as Connect Request is sent by controller and not by device.
* All conversations are based on Device MAC as addr1 */
conversation = conversation_new(pinfo->num, &pinfo->dl_dst, &pinfo->dl_src, PT_NONE, 0, 0, 0);
conversation = conversation_new(pinfo->num, &pinfo->dl_dst, &pinfo->dl_src, ENDPOINT_NONE, 0, 0, 0);
}
station_info = (stationInfo*)conversation_get_proto_data(conversation, proto_pn_dcp);
@ -9291,9 +9291,9 @@ dissect_DataDescription(tvbuff_t *tvb, int offset,
/* Save new data for IO Data Objects */
if (!pinfo->fd->flags.visited) {
/* Get current conversation endpoints using MAC addresses */
conversation = find_conversation(pinfo->num, &pinfo->dl_src, &pinfo->dl_dst, PT_NONE, 0, 0, 0);
conversation = find_conversation(pinfo->num, &pinfo->dl_src, &pinfo->dl_dst, ENDPOINT_NONE, 0, 0, 0);
if (conversation == NULL) {
conversation = conversation_new(pinfo->num, &pinfo->dl_src, &pinfo->dl_dst, PT_NONE, 0, 0, 0);
conversation = conversation_new(pinfo->num, &pinfo->dl_src, &pinfo->dl_dst, ENDPOINT_NONE, 0, 0, 0);
}
station_info = (stationInfo*)conversation_get_proto_data(conversation, proto_pn_dcp);
@ -9423,9 +9423,9 @@ dissect_ExpectedSubmoduleBlockReq_block(tvbuff_t *tvb, int offset,
/* Get current conversation endpoints using MAC addresses */
conversation = find_conversation(pinfo->num, &pinfo->dl_src, &pinfo->dl_dst, PT_NONE, 0, 0, 0);
conversation = find_conversation(pinfo->num, &pinfo->dl_src, &pinfo->dl_dst, ENDPOINT_NONE, 0, 0, 0);
if (conversation == NULL) {
conversation = conversation_new(pinfo->num, &pinfo->dl_src, &pinfo->dl_dst, PT_NONE, 0, 0, 0);
conversation = conversation_new(pinfo->num, &pinfo->dl_src, &pinfo->dl_dst, ENDPOINT_NONE, 0, 0, 0);
}
station_info = (stationInfo*)conversation_get_proto_data(conversation, proto_pn_dcp);
@ -9812,9 +9812,9 @@ dissect_ModuleDiffBlock_block(tvbuff_t *tvb, int offset,
if (!pinfo->fd->flags.visited) {
/* Get current conversation endpoints using MAC addresses */
conversation = find_conversation(pinfo->num, &pinfo->dl_src, &pinfo->dl_dst, PT_NONE, 0, 0, 0);
conversation = find_conversation(pinfo->num, &pinfo->dl_src, &pinfo->dl_dst, ENDPOINT_NONE, 0, 0, 0);
if (conversation == NULL) {
conversation = conversation_new(pinfo->num, &pinfo->dl_src, &pinfo->dl_dst, PT_NONE, 0, 0, 0);
conversation = conversation_new(pinfo->num, &pinfo->dl_src, &pinfo->dl_dst, ENDPOINT_NONE, 0, 0, 0);
}
station_info = (stationInfo*)conversation_get_proto_data(conversation, proto_pn_dcp);
@ -11263,9 +11263,9 @@ dissect_ProfiSafeParameterRequest(tvbuff_t *tvb, int offset,
if (!pinfo->fd->flags.visited) {
/* Get current conversation endpoints using MAC addresses */
conversation = find_conversation(pinfo->num, &pinfo->dl_src, &pinfo->dl_dst, PT_NONE, 0, 0, 0);
conversation = find_conversation(pinfo->num, &pinfo->dl_src, &pinfo->dl_dst, ENDPOINT_NONE, 0, 0, 0);
if (conversation == NULL) {
conversation = conversation_new(pinfo->num, &pinfo->dl_src, &pinfo->dl_dst, PT_NONE, 0, 0, 0);
conversation = conversation_new(pinfo->num, &pinfo->dl_src, &pinfo->dl_dst, ENDPOINT_NONE, 0, 0, 0);
}
station_info = (stationInfo*)conversation_get_proto_data(conversation, proto_pn_dcp);
@ -11328,9 +11328,9 @@ dissect_RecordDataWrite(tvbuff_t *tvb, int offset,
/* PROFISafe */
/* Get current conversation endpoints using MAC addresses */
conversation = find_conversation(pinfo->num, &pinfo->dl_src, &pinfo->dl_dst, PT_NONE, 0, 0, 0);
conversation = find_conversation(pinfo->num, &pinfo->dl_src, &pinfo->dl_dst, ENDPOINT_NONE, 0, 0, 0);
if (conversation == NULL) {
conversation = conversation_new(pinfo->num, &pinfo->dl_src, &pinfo->dl_dst, PT_NONE, 0, 0, 0);
conversation = conversation_new(pinfo->num, &pinfo->dl_src, &pinfo->dl_dst, ENDPOINT_NONE, 0, 0, 0);
}
station_info = (stationInfo*)conversation_get_proto_data(conversation, proto_pn_dcp);

View File

@ -554,9 +554,9 @@ dissect_PNDCP_Suboption_Device(tvbuff_t *tvb, int offset, packet_info *pinfo,
if (pinfo->fd->flags.visited == FALSE) {
/* Create a conversation between the MAC addresses */
conversation = find_conversation(pinfo->num, &pinfo->dl_src, &pinfo->dl_dst, PT_NONE, 0, 0, 0);
conversation = find_conversation(pinfo->num, &pinfo->dl_src, &pinfo->dl_dst, ENDPOINT_NONE, 0, 0, 0);
if (conversation == NULL) {
conversation = conversation_new(pinfo->num, &pinfo->dl_src, &pinfo->dl_dst, PT_NONE, 0, 0, 0);
conversation = conversation_new(pinfo->num, &pinfo->dl_src, &pinfo->dl_dst, ENDPOINT_NONE, 0, 0, 0);
}
station_info = (stationInfo*)conversation_get_proto_data(conversation, proto_pn_dcp);
@ -592,9 +592,9 @@ dissect_PNDCP_Suboption_Device(tvbuff_t *tvb, int offset, packet_info *pinfo,
if (pinfo->fd->flags.visited == FALSE) {
/* Create a conversation between the MAC addresses */
conversation = find_conversation(pinfo->num, &pinfo->dl_src, &pinfo->dl_dst, PT_NONE, 0, 0, 0);
conversation = find_conversation(pinfo->num, &pinfo->dl_src, &pinfo->dl_dst, ENDPOINT_NONE, 0, 0, 0);
if (conversation == NULL) {
conversation = conversation_new(pinfo->num, &pinfo->dl_src, &pinfo->dl_dst, PT_NONE, 0, 0, 0);
conversation = conversation_new(pinfo->num, &pinfo->dl_src, &pinfo->dl_dst, ENDPOINT_NONE, 0, 0, 0);
}
station_info = (stationInfo*)conversation_get_proto_data(conversation, proto_pn_dcp);
@ -616,9 +616,9 @@ dissect_PNDCP_Suboption_Device(tvbuff_t *tvb, int offset, packet_info *pinfo,
if (pinfo->fd->flags.visited == FALSE) {
/* Create a conversation between the MAC addresses */
conversation = find_conversation(pinfo->num, &pinfo->dl_src, &pinfo->dl_dst, PT_NONE, 0, 0, 0);
conversation = find_conversation(pinfo->num, &pinfo->dl_src, &pinfo->dl_dst, ENDPOINT_NONE, 0, 0, 0);
if (conversation == NULL) {
conversation = conversation_new(pinfo->num, &pinfo->dl_src, &pinfo->dl_dst, PT_NONE, 0, 0, 0);
conversation = conversation_new(pinfo->num, &pinfo->dl_src, &pinfo->dl_dst, ENDPOINT_NONE, 0, 0, 0);
}
station_info = (stationInfo*)conversation_get_proto_data(conversation, proto_pn_dcp);

View File

@ -181,7 +181,7 @@ dissect_DataStatus(tvbuff_t *tvb, int offset, proto_tree *tree, packet_info *pin
u8DataValid = (u8DataStatus >> 2) & 0x01;
/* if PN Connect Request has been read, IOC mac is dl_src and IOD mac is dl_dst */
conversation = find_conversation(pinfo->num, &pinfo->dl_src, &pinfo->dl_dst, PT_UDP, 0, 0, 0);
conversation = find_conversation(pinfo->num, &pinfo->dl_src, &pinfo->dl_dst, ENDPOINT_UDP, 0, 0, 0);
if (conversation != NULL) {
apdu_status_switch = (apduStatusSwitch*)conversation_get_proto_data(conversation, proto_pn_io_apdu_status);

View File

@ -429,7 +429,7 @@ dissect_PNIO_C_SDU_RTC1(tvbuff_t *tvb, int offset,
return(tvb_captured_length(tvb));
/* Only dissect cyclic RTC1 frames, if PN Connect Request has been read */
conversation = find_conversation(pinfo->num, &pinfo->dl_src, &pinfo->dl_dst, PT_NONE, 0, 0, 0);
conversation = find_conversation(pinfo->num, &pinfo->dl_src, &pinfo->dl_dst, ENDPOINT_NONE, 0, 0, 0);
/* Detect input data package and output data package */
if (conversation != NULL) {