[Winpcap-users] Retriving the data from UDP packet
Umesh Chandra Sahoo
USahoo at ixiacom.com
Sat Sep 22 07:15:41 GMT 2007
Till now I worked on IPV4 and TCP. What I found it works fine. I think
for ur case there might be two reasons.
1. you might fetching the wrong thing for the data. Do one thing
check thoroughly that u r bypassing the UDP header propelr or not. Just
be aware that u r not doing anything wrong in the data bytes calculation
of UDP header.
2. It might be possible that from which pcap file you are reading
that packets may not contain any data. So do one thing open that file in
ethereal and there u can check whether those packets have any data or
If these two cant solve ur problem then let me know. I will try recheck
myself for UDP in my set up.
From: winpcap-users-bounces at winpcap.org
[mailto:winpcap-users-bounces at winpcap.org] On Behalf Of Prashant Kasal
Sent: Saturday, September 22, 2007 12:02 AM
To: winpcap-users at winpcap.org
Subject: [Winpcap-users] Retriving the data from UDP packet
I was wondering could anybody help me out to solve my issue as
I'm new to networking programming using WinPcap. My task is to retrieve
the IPv4 header information and UDP header information and also data of
the UDP packet. I'm using WinPCap library for doing the above task,
fortunately I found a sample code in WinPcap site regarding this
the code outputs only the header information of both UDP and IPv4
address, along with these info I need data also. When I debugged the
code I came across pcap_next_ex() API where I am supposed to get packet
data also, but it returns empty string.
Any help would be greatly appreciated.
Thanks & Regds
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the Winpcap-users