by lokedhs · 5y ago · 0 comments
Widows might be doing something interesting with it, but does it help in the case of dual boot?
I'm using Qubes OS myself so I don't think Secure Boot would ever be useful in my case?
For a typical laptop, Secure Boot plus Full-Disk Encryption (e.g. Windows BitLocker) makes it harder but not impossible for an "evil maid" - an attacker with temporary, undetected access to the hardware - to compromise the system. (Note that Qubes' VM isolation, per se, does not help in an "evil maid" scenario! - the evil maid typically never even turns the system on.)
There's a lot to say about Secure Boot, and Intel's "measured boot" is rather different from the usual authenticate-then-start approach. If you want to know more, Rutkowska's (of Qubes OS fame) "x86 considered harmful" has quite a lot of good information.
[EDITed to properly spell Rutkowska’s name; thanks, e Erik!]
What exactly are you imagining the maid doing, taking apart the laptop, removing the hard disk, mounting the EFI partition on another device... at that point, why not just install a physical keylogger?
To me, this sort of threat model never made sense, once physical access is possible your main worry ought to be https://xkcd.com/538/
Some people might say they have a detached bootloader (secondary USB which contains the LUKS headers+bootloader), but that depends on them actually keeping the two separate. Even then there is no way to authenticate what you are booting.
Let me introduce you to TPM, signed binaries and measured boot!
However, the most secure ways usually involve a flashed kernel (coreboot) on a write protected NAND chip, of course with encrypted root, that start the boot process by dumping and sha'ing the NAND and comparing that to the whitelist.
On my laptop the SSD can be removed and replaced in 1-2 minutes - you just remove a single panel with 2 screws to get at it. On the other hand, the keyboard would take 10+ minutes to get at and rebuild the computer.
> To me, this sort of threat model never made sense, once physical access is possible your main worry ought to be https://xkcd.com/538/
Sometimes, compromise without the target's knowledge is useful.
https://man7.org/linux/man-pages/man7/kernel_lockdown.7.html
Asking for a friend.
The threat model here is a physical attack that either boots an unauthorized operating system or modified the binaries, how useful it is in the real world for most people I don’t know but it can provide some mitigation or at least a detection if someone is trying to mess with your boot sequence hastily like at the airport or overnight at the office.
Basically you can say that if you lose control over the machine it’s not secure anymore which is somewhat true but in reality you can lock down the UEFI effectively enough that without any known vulnerabilities or bypasses even TLA will probably need quite some time to break into it especially without raising any alarms.
The other threat model is that as long as the MoK signing key is not on the machine, any malware that compromises it won’t be able to add persistence in the bootloader layer.
The TPM can be used to verify that the next boot stage has not been compromised, but it cannot do the first step, so if bad code inserts itself right up front it can lie to the TPM and unlock the security keys under malware control.
The threat was that users would continue to be able to install other operating systems like Linux or Windows 7 or XP, or multiboot these on brand new PC's no differently than IBM had always intended.
As a universal bootloader, GRUB had always been able to boot Windows just as well as a Windows bootloader, and still could at the time but only if Microsoft SecureBoot was disabled if relying on UEFI.
Windows bootloaders could always also boot Linux under BIOS, but not GPT.
Just in time because Linux was getting more functional than ever, which could lead to actual popularity if left unchecked.
Without further effort on Microsoft's part this has naturally morphed as intended into the significant open-source team effort needed to finally overcome the obstacle just to get back to boot parity on brand-new PC's having default firmware settings.
Along the way looks like multiple revocations will be needed for things other than Windows, but eventually once everything is back on parity again these open-source leaders can dust off their hands and take pride in a job very well done.
Looks like not less than about seven years getting there, this is by design.
Still could be a moving target for a while, but Revocations-R-Us now.
Remember how they said that GPT partitioning had no unaccounted-for sectors like MBR setups always traditionally had between sector 0 and the first sector of the first partition? (these were also one of the optional locations for GRUB to be installed)
Well, they were lying and up until recently using GPT when Microsoft quietly moved their mysterious _Microsoft Reserved_ MSR partition to now be the very first possible one starting at sector 34, there had always been gobs of space, as much but usually much more than under BIOS.
_Traditionaly_, the almost-nonexistent MSR had appeared (geometrically aligned) whether you wanted it or not in between the first usually hidden (boot or EFI) partition, and the first system volume (default C:) on the HDD. Now MSR exists too close to the beginning of the SSD or HDD to geometrically align with erase blocks or 4K sectors. When the concept of all-sectors-allocated is actually achieved, people have still always needed some out-of-partition sectors anyway, whether for GRUB or things like the old _drive overlays_ of BIOS use. So the MSR is there for that reason, but for Microsoft only not for you.
But as always with GPT, sectors 2 through 33 by default still define all your partitions, 4 partitons to a sector. Unless you have more than 8 partitions, sectors 4 through 33 are still blank for everybody no differently than under BIOS.
So much SecureBoot.
I don't know how to say that politely, but you have no idea what you are talking about
With GPT, you can align your partitions on erase block size- align just to 8192 and you'll get an empty 32M that you can use as a partition later. Align more and you will get more space. But you are the one in control, and nothing will "claim" this space if you don't.
Also, it can be done ex post: the MSR can be moved anywhere before the Windows partition (take a binary snapshot then restore it at the new position), and the Windows partition can be resized through Windows itself in a few clicks.
Even better: you can "repair" the installation with some simple commands after booting from a Windows install thumbdrive and letting the Windows Boot Manager installed on the EFI partition know about the new geometry of your system - without even updating the EFI boot entry if you kept the same partition UUID!!
This is something that could be done by free software tools if someone cared enough to reverse the WBM format - so no, nobody is doing anything nefarious there.
You have more freedom and security than even before.
Exactly what I was talking about.
>Also, it can be done ex post: the MSR can be moved anywhere before the Windows partition, and the Windows partition resized through Windows itself.
Can we get a show of hands for how many Windows users have been doing this to their MSR?
No, you were saying that this empty space would be claimed by the MSR, and that it wouldn't work otherwise due to some hostile intent by Microsoft.
So I edited to add that nothing would "claim" this space, as out-of-sequence partitions are not done by OS: the gaps will be left empty.
> Can we get a show of hands for how many Windows users have been doing this to their MSR?
I do, and a lot of people do - because it's technically possible. If you don't know how to, it's your problem, not Microsoft problems.
The modern GPT scheme + UEFI boot as used currently by Windows is extremely permissive yet secure: TPM and MOKs allow signed EFI payloads, and you even got a dedicated EFI partition with lots of free space to put them there! Add a LUKS partition and you're just as secure as Windows Secureboot on Bitlocker.
But you have to learn on how to use these new things, as it's not your grandpa MBR.