Wireshark mailing list archives
Re: where can I find the ip src address in packet-http.c
From: Guy Harris <guy () alum mit edu>
Date: Mon, 6 Dec 2010 18:47:42 -0800
On Dec 6, 2010, at 6:39 PM, 刘昆 wrote:
Thank you. Now I have noticed "data" is a pointer I add "printf("%s\n",(pinfo->src).data)"
For almost all address types, including IPv4 and IPv6 addresses, the data field does *NOT* point to a text string. Wireshark deals with binary packet data; it does not turn everything into nice easy-to-print strings. If you want to get the string corresponding to the address, use Wireshark's ip_to_str() routine.
___________________________________________________________________________ Sent via: Wireshark-dev mailing list <wireshark-dev () wireshark org> Archives: http://www.wireshark.org/lists/wireshark-dev Unsubscribe: https://wireshark.org/mailman/options/wireshark-dev mailto:wireshark-dev-request () wireshark org?subject=unsubscribe
Current thread:
- where can I find the ip src address in packet-http.c 刘昆 (Dec 06)
- Re: where can I find the ip src address in packet-http.c Guy Harris (Dec 06)
- Re: where can I find the ip src address in packet-http.c Bill Meier (Dec 06)
- Re: where can I find the ip src address in packet-http.c 刘昆 (Dec 06)
- Re: where can I find the ip src address in packet-http.c Guy Harris (Dec 06)
- Re: where can I find the ip src address in packet-http.c 刘昆 (Dec 06)
- Re: where can I find the ip src address in packet-http.c Guy Harris (Dec 06)
- Re: where can I find the ip src address in packet-http.c 刘昆 (Dec 06)
- Re: where can I find the ip src address in packet-http.c Richard Sharpe (Dec 06)
- Re: where can I find the ip src address in packet-http.c James Deucker (Dec 07)
- Re: where can I find the ip src address in packet-http.c Guy Harris (Dec 06)