Ethereal

[Ethereal-users] Dissector based on UDP Src or Dst port to find the direction of packets
Google
 
Web Ethereal.com

Home | Introduction | Documentation | Lists | FAQ | Development | Wiki | Bugs

Ethereal-users: July 2006


Hi,

 

I’m new to Ethereal dissectors. I’m trying to write a dissector for a VOIP proprietary protocol. It is based on UDP. Phone uses a specific port number say X to communicate with the PBX. And the PBX uses port Y to communicate with the phone. X and Y are fixed. My problem is, I need to find the direction of the packet like who is talking to whom (Phone to PBX Or PBX to Phone?). That can be done only by analyzing the UDP Source or Destination port numbers. I tried using the following function call ->

 

dissector_add("udp.srcport", PORT_NO, my_handle);

 

but that gave me a runtime fatal error. It’s my understanding that I can’t use “udp.srcport”  for dissector_add(). If I use “udp.port”, things work fine.  But with “udp.port” I can’t find the direction of the packet.

 

Is there any other solution for this problem ?  All I need is to find the direction of the packets.

 

Thanks in advance,

Vasanthi


Powered by MHonArc 2.6.10