public recording of an example from https://web.archive.org/web/20180215030743/http://www.binarytides.com/packet-sniffer-code-c-linux. The site is iffy (only loads half the page sometimes?) so I am linking an archived version of the site.
This repo is archived. You can view files and clone it, but cannot push or open issues/pull-requests.
 
 
Go to file
Penguin 909d835488
Update README.md
bin first
inc first
src first
README.md Update README.md

README.md

udp_sniffer_example

This is a public recording of a UDP Sniffer example in C.

Source: https://web.archive.org/web/20180215030743/http://www.binarytides.com/packet-sniffer-code-c-linux

The code is aged, but it works with tweaks (if compiled correctly no tweaks should be needed). Compile with gnu11 or newer. This repo will stay up for as long as my git is up most likely, but a new repo with updated code will replace this as my go to example for udp sniffing eventually.