curl-users
Re: pcap output
Date: Thu, 16 Jun 2011 16:30:34 -0400 (EDT)
On Thu, 16 Jun 2011, Daniel Nagy wrote:
> I had in mind to write a more generic command wrapper like:
>
> $ pcapout --outfile=my.pcap curl http://kernel.org/
>
> If pcapout would be such a wrapper programm, it could wrap the system
> calls of curl and generate a .pcap file without the need of root-right
> to listen on the network interface, as the system calls of curl and
> other programs provide enough information to build a correct .pcap file
> ( i think ).
Without root privs, you can't actually capture the network traffic. Otherwise, you cannot get the details of the actual packets on the wire. What's the point of reconstructing what you *think* said traffic *ought* to look like (if that's what you're suggesting; I'm not clear)? The only really meaningful data in that would be the contents of the curl TCP stream, which you can already get with --trace and --trace-ascii.
Now, if you want to add this feature with the understanding that it can only be used by root, you could -- but that doesn't seem useful enough to bother, given that someone with root can just run tcpdump/wireshark/whatever himself and get the trace that way.
- Richard
-------------------------------------------------------------------
List admin: http://cool.haxx.se/list/listinfo/curl-users
FAQ: http://curl.haxx.se/docs/faq.html
Etiquette: http://curl.haxx.se/mail/etiquette.html
Received on 2011-06-16