diff options
author | Michael Mann <mmann78@netscape.net> | 2017-10-30 15:57:34 -0400 |
---|---|---|
committer | Michael Mann <mmann78@netscape.net> | 2017-11-01 02:41:45 +0000 |
commit | 66b441f3d63e21949530d672bf1406dea94ed254 (patch) | |
tree | 82fef0bb973e0907d9333e980a95f4c2531baba0 /epan/conversation.h | |
parent | d518f28b395a7d1c8588c8f321ad5ade194fb423 (diff) |
Add ability to create endpoints through conversations
Add endpoint information to the packet_info structure for dissectors
to potentially use as their data to create conversations.
This patch includes a simple "example" of using conversation_create_endpoint
with TDMoP. The assignment of the PT_TDMOP "port type" has been replaced by
setting ENDPOINT_TDMOP within the endpoint structure. Then when subdissectors
of TDMoP call find_or_create_conversation(), it implicitly picks up the
conversation information set by TDMoP
Change-Id: I11dc29989cccd3b0f0349ee901babb455ca02d19
Reviewed-on: https://code.wireshark.org/review/24190
Petri-Dish: Michael Mann <mmann78@netscape.net>
Tested-by: Petri Dish Buildbot
Reviewed-by: Andrew Chernyh <andrew.chernyh@gmail.com>
Reviewed-by: Michael Mann <mmann78@netscape.net>
Diffstat (limited to 'epan/conversation.h')
-rw-r--r-- | epan/conversation.h | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/epan/conversation.h b/epan/conversation.h index 3ff9469da2..6fce0bf8d6 100644 --- a/epan/conversation.h +++ b/epan/conversation.h @@ -101,6 +101,9 @@ typedef struct conversation { } conversation_t; +struct endpoint; +typedef struct endpoint* endpoint_t; + WS_DLL_PUBLIC address* conversation_key_addr1(const conversation_key_t key); WS_DLL_PUBLIC address* conversation_key_addr2(const conversation_key_t key); WS_DLL_PUBLIC guint32 conversation_key_port1(const conversation_key_t key); @@ -193,6 +196,9 @@ WS_DLL_PUBLIC void conversation_set_dissector_from_frame_number(conversation_t * WS_DLL_PUBLIC dissector_handle_t conversation_get_dissector(conversation_t *conversation, const guint32 frame_num); +WS_DLL_PUBLIC void conversation_create_endpoint(struct _packet_info *pinfo, address* addr1, address* addr2, + endpoint_type etype, guint32 port1, guint32 port2, const guint options); + /** * Given two address/port pairs for a packet, search for a matching * conversation and, if found and it has a conversation dissector, |