99 points · by transpute · 2y ago · 77 comments
This does nothing to explain what any of these features are, what are "Boot hardening" and "sysctl hardening"?
At least OpenBSD's innovations page makes an attempt to explain new concepts and features that have been developed over the years, and people can make any comparisons for themselves.
I'm guessing that "sysctl hardening" is https://git.hardenedbsd.org/hardenedbsd/HardenedBSD/-/wikis/...
There's no clue on the wiki what "boot hardening" is, though.
Could FreeBSD implement some of the security features identified by HardenedBSD?
https://hardenedbsd.org/content/about
It also sounds like the person wants to promote his own "ElectroBSD", but just in the form of a patch-sets because of "unresolved license issues" he reallyreally wants his GPL-Code in BSD:
I assume but don't know for sure that this refers to Veriexec in NetBSD, and I'm not sure what in HardenedBSD. Anyone know?
https://man.netbsd.org/veriexec.8
My understanding is that Veriexec isn't enabled by default - the manpage says only that "[s]ome kernels already enable Veriexec by default." If you have this enabled, how do you upgrade binaries? The manpage says that in strict mode 1, write access to monitored binaries is allowed but then access is denied. So I assume that after file modification, root then runs veriexecgen and veriexecctl load as mentioned in the manual to update the signatures list. So it seems that strict level 1 isn't functionally different from a read-only /usr or even just root-owned binaries. In either case, you just need root to update targeted binaries. Surely I'm missing something and would appreciate some insight.
At a glance as an outsider, stricter modes appear somewhat functionally similar to "chflags schg" on BSD systems, where more work is needed to get around restrictions. In the case of schg, you have to reboot into single user mode, remove the schg flag, then modify the binary, and continue booting into multi-user mode. You could do this as a remote attacker (as in not having console access) depending on what boot files are or aren't protected with schg, but modifying all the necessary files can be a source of new problems.
I suspect the actual most likely case is that it's meant for appliances where the running system doesn't update itself, and updates are accomplished via actions like "go physically replace the SD card with the new one".
My understanding is that the difference is you would need to boot with a kernel with veriexec disabled to replace binaries and regenerate hashes. Root alone isn't sufficient, and you can't disable veriexec as root in strict mode.
most of the topics.. are still in development and are not yet used by default
.. Kicksecure has adopted a best-effort, but admittedly quite weak approach
CFI, SafeStack, automatic stack variable init..unlikely..due to.. resourcing
kernel security issues.. are rooted deep within its design
upstream developers are not very focused on serious security enhancementsThis is basically what muslc does, but with the kernel itself offering a memset / malloc with randomized padding, right?
Also, what does ASLR brute force detection (SEGVGUARD) do? To me this sounds like malloc has a hook that maps process ids and tries to find heuristics of the allocated offsets?
Anybody know where those features are documented do someone can try to bypass/exploit it?
I don't see a comparison in the wiki.
https://git.hardenedbsd.org/hardenedbsd/HardenedBSD/-/wikis/...
What any BSD needs to have a merit to a claim to security, in 2024, is some form of MAC. As long as there is no way to take away from having an all powerful root user (and pledge and unveil ain't it), then they have a long ways to go.
They're talking about pledge. https://man.openbsd.org/pledge.2
While e.g. ignoring many security features openbsd has and HardenedBSD has not.
BTW: For Linux, OpenPaX is on the horizon:
> Introduction
> Founded in 2014 by Oliver Pinter and Shawn Webb, HardenedBSD is a security-enhanced fork of FreeBSD. The HardenedBSD Project is implementing many exploit mitigation and security technologies on top of FreeBSD. The project started with Address Space Layout Randomization (ASLR) as an initial focal point and is now implementing further exploit mitigation techniques.
> Why Fork FreeBSD?
> HardenedBSD forked the FreeBSD codebase for ease of development. Prior to ...