David Schwartz wrote:
> Zheng Da wrote:
>
>> I want to capture packets from the specified ip address.
>> Given the ip address, how do I get the device I need to listen on. Is it
>> possible to get the device by programming?
>
> Your question gives us no idea what you're actually asking.
>
> As just a single example of how ambiguous it is, what is the "I"? Do
> you mean an actual human being? Or a program on a computer?
>
> One more: you ask about "the device", but what does that mean? Are we
> talking about a single computer that has more than one network
> interface?
>
> DS
>
Sorry, I mean I want to use libpcap to capture packets from the
specified ip address. But using pcap_open_live(), I should specify the
device name. But I have the ip address, how can I get the device name in
my program? I hope my program can find the device itself.
Zheng Da
--
Posted via a free Usenet account from
http://www.teranews.com