Forum: Ruby Problems with Pcacp Library

Announcement (2017-05-07): www.ruby-forum.com is now read-only since I unfortunately do not have the time to support and maintain the forum any more. Please see rubyonrails.org/community and ruby-lang.org/en/community for other Rails- und Ruby-related community platforms.
Protos J. (Guest)
on 2008-10-26 19:45
Hi!

I want to work with the pcap library, and I installed libpcap and pcap
library in Ubuntu, but when I try a code, there is an error:

/usr/lib/ruby/1.8/pcaplet.rb:51:in `lookupdev': no suitable device found
(Pcap::PcapError)
        from /usr/lib/ruby/1.8/pcaplet.rb:51:in `initialize'
        from httpsniff.rb:4:in `new'
        from httpsniff.rb:4

I searched but i didnt find what to do (I've already required the
library...)

Thanks, and sorry for my english ^^
David Rio (Guest)
on 2008-10-27 20:41
(Received via mailing list)
On Sun, Oct 26, 2008 at 12:44 PM, Protos J. 
<removed_email_address@domain.invalid>
wrote:

>
> I searched but i didnt find what to do (I've already required the
> library...)
>

Do you have any interface available that the library can use to sniff
from?
If so,
be sure you run your script as root.

If still doesn't work post the code your are trying to run.

-drd
This topic is locked and can not be replied to.