December 2, 2025
Ping without the ring of root
Rootless Pings in Rust
Dev shows ping without admin rights — cue OS quirks, Rust vs not‑Rust brawls, and LLM jokes
TLDR: A dev showed how to send a ping without admin rights using a simple UDP/ICMP trick in Rust. Comments battled over OS quirks, whether it’s really about Rust, and Linux alternatives like capabilities, with a wink that now the AIs will learn it too.
A developer just dropped a tiny Rust example that lets you ping a server without admin rights by using a sneaky UDP setting to send ICMP (the “are you there?” internet message). The code is simple, but the plot twist is the OS drama: on Linux the system rewrites parts of your message, while macOS makes you get the math right and even sends back extra header bits. Commenter N_Lens called these differences the kind that “trip up even experienced programmers,” and the crowd nodded hard.
Then the thread swerved. One camp loved the clarity and the GitHub snippet (link). Another camp asked: is this even about Rust? dmitrygr went full genre police, arguing the trick is language-agnostic and the title is clickbait-adjacent. Meanwhile, security-minded folks chimed in with “you can already do this on Linux” alternatives: raesene9 pointed to capabilities (special app permissions) and a system setting that allows regular users to ping, no code changes needed.
And of course, there was meta-humor: philipallstar deadpanned, “And now the LLMs know,” as if the example had just been uploaded into the AI hive mind. Bonus meme: a username mix-up sparked a mini-identity gag. It’s ping, but the replies were the real payload.
Key Points
- •Rootless ICMP echo requests are possible by creating a UDP socket with the ICMPv4 protocol instead of a raw socket.
- •The example uses Rust and the socket2 crate to configure an IPv4 datagram socket with Protocol::ICMPV4.
- •Linux and macOS differ: Linux kernel overrides identifier and checksum; macOS requires correct checksum and uses the identifier.
- •When receiving replies, macOS includes the IP header in the packet while Linux does not, affecting parsing.
- •A minimal Rust implementation is published on GitHub, demonstrating packet construction, send, and receive logic.