Last active
October 21, 2019 00:44
-
-
Save jason-riddle/d2bf6de8b25a70c05a6570232da9d0c9 to your computer and use it in GitHub Desktop.
Snippet using tcpdump to listen on an http port #snippet #complete
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Ref: https://github.com/SergK/cheatsheat-tcpdump/blob/master/tcpdump_advanced_filters.txt | |
# Ref: http://edoceo.com/cli/tcpdump | |
HTTP_PORT="8444" | |
HTTP_FILTER="(((ip[2:2] - ((ip[0]&0xf)<<2)) - ((tcp[12]&0xf0)>>2)) != 0)" | |
tcpdump -i any -s 0 -A "tcp port $HTTP_PORT and $HTTP_FILTER" |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment