Skip to content

Instantly share code, notes, and snippets.

@BoredHackerBlog
Last active July 2, 2026 18:01
Show Gist options
  • Select an option

  • Save BoredHackerBlog/1e2690262ff914c482053a88231c2ebe to your computer and use it in GitHub Desktop.

Select an option

Save BoredHackerBlog/1e2690262ff914c482053a88231c2ebe to your computer and use it in GitHub Desktop.
tcpdump, ufw, networking stuff
https://davecturner.github.io/2020/12/12/rolling-tcpdump.html
https://www.tcpdump.org/manpages/tcpdump.1.html
tcpdump -i eth0 -G 600 -w mycapture_%s.pcap -zgzip -Z root
allow ssh in but no traffic out or in besides that:
ufw enable
ufw default deny outgoing
ufw default deny incoming
ufw allow in ssh
socat port forwarding:
https://www.cyberciti.biz/faq/linux-unix-tcp-port-forwarding/
https://www.redhat.com/en/blog/getting-started-socat
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment