From: Brian Candler Date: 2009-12-22T19:09:20+09:00 Subject: Re: promiscuous mode Marco Biscetti wrote: > Hi guys. i have a question. i am new in a ruby world. > How can i set my wlan device in a promiscuous mode? One answer is: use the Socket API. You have direct access there to all the facilities there that you would have in a C program, e.g. setsockopt. So the problem boils down to: how do I create a raw socket, how do I set promiscuous mode on it, how do I read packets from it? These are socket questions, not Ruby ones. If you can find a C program which does what you want, you can port it to ruby. As has already been pointed out, Ruby is probably a poor choice of language for packet inspection if you have any significant volume of traffic. But if you really want to do it in Ruby, I suggest you use someone else's code: google for "ruby pcap". -- Posted via http://www.ruby-forum.com/.