tshark: why is -p (no promiscuous mode) not working for me?
sudo tshark -i enp2s0 -p
on Ubuntu.
New user. The host has another wire interface, enp1s0, also. Both interfaces are on the same local subnet. When I first used this command a few days ago it didn't capture any traffic for which the specified interface was not the src or dst. But today it's showing me everything on the local subnet, including, e.g., SSH traffic on enp1s0.
I did a little research on promiscuous mode, and wondered if enp2s0 had been put in it by some accident. I did sudo ifconfig enp2s0 -promisc
but that didn't help.
What's the output of
sudo ifconfig enp2s0
?@Chuckc
enp2s0: flags=4163<UP,BROADCAST,RUNNING,MULTICAST> mtu 1500
I.e., it's showing you traffic that's not multicast or broadcast (SSH runs over TCP, so it's unlikely to be multicast or broadcast traffic) and that's neither to nor from the MAC address of enp2s0?
@Guy_Harris That's right. Here are the first three lines of output from
sudo tshark -i enp2s0 -p
recently:enp2s0
's ip address is192.168.50.212
. tshark, at least with only the -p option, doesn't show MAC addresses.192.168.50.10
isenp1s0
-- with which192.168.50.200
, another host, is the SSH client. TP-Link is a switch.Off topic: there's probably a way to tag you with "@" but "GuyHarris" didn't work so I tried the underscore.