4 ms·
Very nice! I love projects like this that return to first principles, and rebuild the core without the cruft. It is refreshing. The dependency on netlink add
by gorgoiler 6y ago
Very nice! I love projects like this that return to first principles, and rebuild the core without the cruft. It is refreshing.
The dependency on netlink adds a little to the code weight. Some of this also feels like it could just be a shell script (sh, unlike Go, ships with built in Linux support for netlink, and sticks with dotted-quad-string types for IP addresses instead of mixing with int32!)
I did not realize cgroups were this simple to manipulate. Thank you for the enlightenment.
- nine_k 6y agoTBH, all network utilities I ever saw accept the int32 form of IP addresses. E.g. ping 127.0.0.1 can also be written as ping 0x7f000001 Try it; it works.
- arpa 6y agoYou can also just provide an integer. That works too.
- Erwin 6y agoURLs too, though Chrome makes them canonical: http://0xacd91124/ http://0xacd91124/ -- Google I did a quick search for whether "fun" Hex strings are reachable, but didn't find any (e.g. the canonical http://0xcafebabe http://0xcafebabe). Random combination of hex-words are login pages to web cameras or cable modems. I didn't try to e.g. replace "e" with "3", e.g. http://0xcaf3babe/ http://0xcaf3babe/