OpenBSD system-call-origin verification
OpenBSD system-call-origin verification
Posted Dec 13, 2019 16:21 UTC (Fri) by rweikusat2 (subscriber, #117920)In reply to: OpenBSD system-call-origin verification by Cyberax
Parent article: OpenBSD system-call-origin verification
The underlying message is nevertheless: From now on, it's strengstens verboten to call into the OpenBSD kernel from machine code. This is a necessary security measure because only criminals would do that, anyway.
NB: This is *not* a statement in favour of the great usefulness of machine code programming. But that's a hobby of some people who enjoy building stuff, as opposed to "make money by coming up with ever more abstruse ways of tearing it down".
Posted Dec 13, 2019 18:26 UTC (Fri)
by atai (subscriber, #10977)
[Link] (1 responses)
That can be a sport with regular races. Seriously.
Posted Dec 13, 2019 18:28 UTC (Fri)
by atai (subscriber, #10977)
[Link]
Posted Dec 13, 2019 18:32 UTC (Fri)
by Cyberax (✭ supporter ✭, #52523)
[Link] (13 responses)
The overhead of libc functions is pretty much negligible, since you're doing syscalls.
Posted Dec 13, 2019 19:42 UTC (Fri)
by rweikusat2 (subscriber, #117920)
[Link] (12 responses)
I wasn't referring to the additional runtime cost of invoking the system call through a C wrapper, although that's not necessary negligible and someone writing machine code would very likely care about it nevertheless, but about the "infrastructure overhead" of having to link with this library (including the size of the thing) and the absurdity of writing code following the C calling conventions of a particularly system so that one can interface with (compiled) C code supposed to enable other C code to use an interface defined in machine code.
For a loosely related example, people implement alternative C libraries for Linux solely because they're horrified by "glibc bloat". That's not much of a real practical concern, either, because today's "embedded systems" vastly more powerful than "high-end UNIX workstations of the mid-1990s", but some people do care about it very much nevertheless.
Posted Dec 19, 2019 6:31 UTC (Thu)
by marcH (subscriber, #57642)
[Link] (11 responses)
Yes of course: some hobbyists have fun implementing libraries with insanely small footprints, only to be used in systems several orders of magnitude bigger. It's like a sport.
You should actually look at some of these libraries and corresponding operating systems, they tend to give examples of the sort of real hardware they target.
Posted Dec 19, 2019 10:29 UTC (Thu)
by Cyberax (✭ supporter ✭, #52523)
[Link] (10 responses)
Posted Dec 19, 2019 15:46 UTC (Thu)
by mathstuf (subscriber, #69389)
[Link] (9 responses)
Posted Dec 19, 2019 20:15 UTC (Thu)
by Cyberax (✭ supporter ✭, #52523)
[Link] (8 responses)
Posted Dec 20, 2019 17:06 UTC (Fri)
by cortana (subscriber, #24596)
[Link] (7 responses)
Posted Dec 20, 2019 20:31 UTC (Fri)
by Cyberax (✭ supporter ✭, #52523)
[Link] (5 responses)
Posted Dec 21, 2019 13:26 UTC (Sat)
by cortana (subscriber, #24596)
[Link] (3 responses)
Posted Dec 21, 2019 16:44 UTC (Sat)
by dezgeg (subscriber, #92243)
[Link] (2 responses)
Posted Dec 24, 2019 1:01 UTC (Tue)
by mathstuf (subscriber, #69389)
[Link]
Posted Dec 24, 2019 12:31 UTC (Tue)
by cortana (subscriber, #24596)
[Link]
And that NSS will tell you a host's addresses but not which interface they are reachable via, or whether the query was secured by DNSSEC, dns-over-tls, etc, which resolved does provide via its D-BUS API.
(As well as being able to do nifty things like LLMNR, or split-DNS. OTOH resolved does have its own bugs and limitations that drive me up the wall a bit...)
Posted Jan 8, 2020 11:20 UTC (Wed)
by nix (subscriber, #2304)
[Link]
This isn't to avoid libraries getting loaded behind your back into a running process so much as it is to allow removal of the incredibly convoluted and invasive statically-linked dlopen() feature, which is only really there so that statically linked programs can do name lookups. (But moving all the NSS stuff out of every process's address space into one more controllable domain is definitely a side benefit!)
(I am only an egg, but this is my understanding, anyway. My apologies if I'm mischaracterizing anything or accidentally mixing it up with my own ideas of obviously right implementations etc: human memory is a fallible thing...)
Posted Jan 9, 2020 1:34 UTC (Thu)
by anselm (subscriber, #2796)
[Link]
Probably not, given that the uses of NSS and those of systemd-resolved only overlap slightly.
Posted Dec 14, 2019 8:50 UTC (Sat)
by dvdeug (guest, #10998)
[Link] (3 responses)
A hobby of many people is low-level computer hacking, wherein any Unix-type system is going to get in the way with all this "filesystem" and "virtual memory" crap. Guess what they do? They use a system that supports their needs.
Posted Dec 16, 2019 20:12 UTC (Mon)
by rweikusat2 (subscriber, #117920)
[Link] (1 responses)
Posted Dec 17, 2019 5:44 UTC (Tue)
by dvdeug (guest, #10998)
[Link]
Most code ever written won't compile or run on modern Unix systems, short of emulation, and the dialects they're written in fundamentally won't work well on Unix. You can't really use certain Forth dialects, as they implement hard drives as an array of sectors that the program has arbitrary access to. MS-DOS C dialects assume segmented pointers. VMS C has its own system calls that makes porting any non-trivial program challenging. Same thing with Windows C. Many BASICs assume you can PEEK and POKE certain memory locations for certain effects. You can't run most assembly languages or machine language; 68000 assembly written for OpenBSD won't run on any modern version, and never ran on any non-68K OpenBSD. You can run any language or program on any sufficiently large system with enough layers of indirection, but virtually all non-trivial code not written for Unix systems is going to make enough assumptions about how things work that Unix disagrees with to require serious emulation or virtualization to work without code changes.
The boundary of "your programming language of choice must not be one we disapprove of" was first willfully crossed when memory protection and filesystems were added.
And you say you're not "complaining", but you've chosen to characterize the "eternal OpenBSD quest" in a biased way that sounds a lot like a complaint; the goal is to "increase resilience against bugs", by many tactics, not just those which some rare programmers might find complicating things.
Posted Jan 8, 2020 17:36 UTC (Wed)
by marcH (subscriber, #57642)
[Link]
Other systems often get these mitigations "for free" once OpenBSD paid the initial development price for them.
I really can't see anything to be unhappy about.
OpenBSD system-call-origin verification
OpenBSD system-call-origin verification
OpenBSD system-call-origin verification
Dude, you have some really strange concepts of pretty much everything CS-related.
OpenBSD system-call-origin verification
OpenBSD system-call-origin verification
> That's not much of a real practical concern, either, because today's "embedded systems" vastly more powerful than "high-end UNIX workstations of the mid-1990s", but some people do care about it very much nevertheless.
OpenBSD system-call-origin verification
OpenBSD system-call-origin verification
OpenBSD system-call-origin verification
OpenBSD system-call-origin verification
OpenBSD system-call-origin verification
OpenBSD system-call-origin verification
OpenBSD system-call-origin verification
OpenBSD system-call-origin verification
OpenBSD system-call-origin verification
OpenBSD system-call-origin verification
OpenBSD system-call-origin verification
OpenBSD system-call-origin verification
OpenBSD system-call-origin verification
OpenBSD system-call-origin verification
OpenBSD system-call-origin verification