joaoptc DD-WRT User
Joined: 28 Oct 2014 Posts: 57
|
Posted: Wed Oct 02, 2019 19:27 Post subject: Monitor LAN Traffic |
|
Hello all,
I just migrated back to standard FW. I was using Kong´s for the last few years, but I still want to keep up with the new stuff released.
I have a script to WOL my machine in case someone try to access a specific service.
on Kong´s I was using tcpdump to monitor that.
on Current FW, tcpdump is not available and dmesg only monitor external traffic.
These are the root commands of my script:
dmesg -c | awk '/DPT=32400/ {print }' (Lattest FW)
tcpdump 'dst host 192.168.1.2 and dst port 32400' (Kong FW)
Can any of you pinpoint a way to monitor all traffic to destination 192.168.1.2 regardless the origin (internal network or external) ?
ps: I have a media server called Plex and this script WOL the server whenever I start a client.
Thanks! |
|
joaoptc DD-WRT User
Joined: 28 Oct 2014 Posts: 57
|
Posted: Wed Oct 02, 2019 22:02 Post subject: |
|
Well .....
It is not the prettiest solution, but I found a way to install tcpdump. For my CPU, these are the ipks:
Code: | cd /tmp
wget http://archive.openwrt.org/snapshots/trunk/bcm53xx/generic/packages/base/libpcap_1.7.4-1_bcm53xx.ipk
wget http://archive.openwrt.org/snapshots/trunk/bcm53xx/generic/packages/base/tcpdump-mini_4.9.2-1_bcm53xx.ipk
ipkg -d /tmp install tcpdump-mini_4.9.2-1_bcm53xx.ipk
ipkg -d /tmp install libpcap_1.7.4-1_bcm53xx.ipk
export LD_LIBRARY_PATH="$LD_LIBRARY_PATH:/tmp/usr/lib"
PATH="$PATH:/tmp/usr/sbin" |
I will add that to my script ....
I am still searching for a more elegant way of doing this.
Please share !!!![/code] |
|
Alozaros DD-WRT Guru
Joined: 16 Nov 2015 Posts: 6436 Location: UK, London, just across the river..
|
Posted: Thu Oct 03, 2019 6:11 Post subject: |
|
i dont know if this is relevant to this case, but
i do have opkg (entware) on my Broadcom unit and there you can get tcpdump or any other useful package, i guess ipkg is a bit outdated... _________________ Atheros
TP-Link WR740Nv1 ---DD-WRT 55630 WAP
TP-Link WR1043NDv2 -DD-WRT 55723 Gateway/DoT,Forced DNS,Ad-Block,Firewall,x4VLAN,VPN
TP-Link WR1043NDv2 -Gargoyle OS 1.15.x AP,DNS,QoS,Quotas
Qualcomm-Atheros
Netgear XR500 --DD-WRT 55779 Gateway/DoH,Forced DNS,AP Isolation,4VLAN,Ad-Block,Firewall,Vanilla
Netgear R7800 --DD-WRT 55819 Gateway/DoT,AD-Block,Forced DNS,AP&Net Isolation,x3VLAN,Firewall,Vanilla
Netgear R9000 --DD-WRT 55779 Gateway/DoT,AD-Block,AP Isolation,Firewall,Forced DNS,x2VLAN,Vanilla
Broadcom
Netgear R7000 --DD-WRT 55460 Gateway/SmartDNS/DoH,AD-Block,Firewall,Forced DNS,x3VLAN,VPN
NOT USING 5Ghz ANYWHERE
------------------------------------------------------
Stubby DNS over TLS I DNSCrypt v2 by mac913 |
|