1 Apr 2025 |
jade_ | yes | 23:21:27 |
artemist | Seems like the easiest way to figure that out will be to try it, i'll do that | 23:25:36 |
rhelmot | my guess is that software which isn't explicitly checking for "am I communicating with a jailed user" will think you are the real actual root | 23:27:25 |
artemist | the main page for LOCAL_PEERCRED doesn't have jid, just "effective user id" | 23:27:51 |
artemist | https://man.freebsd.org/cgi/man.cgi?query=unix&apropos=0&sektion=0&manpath=FreeBSD+13.1-RELEASE+and+Ports&arch=default&format=html | 23:27:51 |
jade_ | of course the other interaction with this that might be hilarious is if freebsd has abstract domain unix sockets, which I think it does because they had to copy linux's bad features for the linux abi thing | 23:28:44 |
artemist | FreeBSD has a linux compatibility layer so I wouldn't be surprised | 23:30:11 |
artemist | like, it's sufficiently compatible to run commercial games and software | 23:30:52 |
jade_ | https://lists.freebsd.org/archives/freebsd-hackers/2021-December/000636.html hm | 23:31:10 |
jade_ | maybe they did not! | 23:31:13 |
jade_ | at least it is good that they are proposing "having a security model" for this feature which is a walking CVE | 23:31:33 |
artemist | ... who the hell thought this was a good idea | 23:32:58 |
jade_ | I DONT KNOW BUT I DO KNOW HOW MANY CVES THIS FUCKIN THING HAS CAUSED | 23:33:11 |
jade_ | did you know they are isolated by network namespace on linux??? infinite CVEs in container runtimes... | 23:33:30 |
artemist | if you're forced to have them then network namespace feels like the least bad place to isolate them, but oh god | 23:34:05 |
jade_ | no it's not | 23:34:13 |
artemist | oh, mount namespace? | 23:34:35 |
jade_ | host netns allowing containers to send each other fds is how you get CVE-2024-27297 | 23:34:45 |
jade_ | among also docker ones | 23:34:51 |
artemist | network namespace is where i would expect them to go | 23:35:03 |
jade_ | CVE-2020-15257 lol | 23:35:14 |
jade_ | but unix sockets exist as a fd passing primitive and secondarily as a network feature, in my view :) | 23:35:42 |
jade_ | the fact that you have to shove containers into a netns with NAT if you don't want them sending each other fds is a hilarious linux moment | 23:36:14 |
artemist | Yeah, that's not the worst interpretation. It makes me think of how systemd is a database for file descriptors | 23:36:49 |
artemist | sending file descriptors between mount namespaces at all feels sus | 23:37:15 |
jade_ | it combines somewhat poorly with the userspace nat implementations being all kind of annoying. pasta, slirp4netns, etc | 23:37:17 |
jade_ | it's ... well. i can see the use case for it in container setup, but it is pretty sketchy | 23:37:42 |
jade_ | (and i think that it really should only be allowed on inherited fds) | 23:38:06 |
artemist | I wonder how much would break if I patched linux to disallow abstract sockets | 23:39:28 |
jade_ | they can be disabled via apparmor and other LSMs | 23:40:22 |