rakesh bahl wrote:

> How do you make your ethernet card on linux accept all the packets
> which are flowing on the segment?

Put it into promiscuous mode.

> I think I would have to write a driver which would communicate with
> the card and some sort of a skeleton TCP/IP stack so that the packet 
> reaches the Application Layer.
> 
> Am I right or is there an easier way?

You can create a socket of type SOCK_RAW or SOCK_PACKET. Take a look
at the code for libpcap (which is used by tcpdump) as an example.

-- 
Glynn Clements <[EMAIL PROTECTED]>
-
To unsubscribe from this list: send the line "unsubscribe linux-net" in
the body of a message to [EMAIL PROTECTED]

Reply via email to