davical/testing/watch-port-80.sh
2006-10-11 14:17:56 +13:00

6 lines
143 B
Bash
Executable File

#!/bin/sh
PORT=${1:-"80"}
sudo tcpdump -i lo -s0 -n -q -A "tcp port ${PORT} and (((ip[2:2] - ((ip[0]&0xf)<<2)) - ((tcp[12]&0xf0)>>2)) != 0)"