zlacker

Toward a Reasonably Secure Laptop

submitted by doener+(OP) on 2017-07-11 11:32:09 | 344 points 100 comments
[view article] [source] [go to bottom]

NOTE: showing posts with links only show all posts
7. ashley+57[view] [source] 2017-07-11 12:50:08
>>doener+(OP)
Looks like Qubes make you pay to get certified: https://puri.sm/posts/ "The costs involved, requiring a supplementary technical consulting contract with Qubes/ITL (as per their new Commercial Hardware Goals proposal document), are not financially justifiable for us."
◧◩
9. mozart+g7[view] [source] [discussion] 2017-07-11 12:51:31
>>d33+y5
The best option right now is to use Rockchip ARM devices. With a few little compromises you can run a pretty much free architecture: https://libreboot.org/docs/hardware/c201.html
◧◩
10. zer0to+m7[view] [source] [discussion] 2017-07-11 12:52:15
>>d33+y5
I think the whole point of Qubes OS is t not trust hardware because of potential BIOS or ME backdoors.

Joanna Rutkowska, Qubes founder, is the person who brought up intel ME as a problem in her paper Intel x86 considered harmful (https://blog.invisiblethings.org/papers/2015/x86_harmful.pdf).

◧◩
13. x86ins+U8[view] [source] [discussion] 2017-07-11 13:04:09
>>d33+y5
You could contact AMD and show support for open sourcing PSP (their ME equivalent) or having an option to disable it. There is hope: https://www.reddit.com/r/linux/comments/5xvn4i/update_corebo...
◧◩
19. cyphar+dc[view] [source] [discussion] 2017-07-11 13:32:56
>>d33+y5
OpenPOWER[1] would be a great option. There was a recent crowd-funding effort to try to make an OpenPOWER desktop a reality[2] but unfortunately it didn't get nearly enough funding (though apparently they are still developing it[3]).

[1]: https://openpowerfoundation.org/ [2]: https://www.crowdsupply.com/raptor-computing-systems/talos-s... [3]: https://www.raptorengineering.com/TALOS/prerelease.php

20. x86ins+hc[view] [source] 2017-07-11 13:33:12
>>doener+(OP)
There are things we can do to help get us out of this Intel ME rut.

* Let AMD know that open-sourcing/disabling PSP is important to you [1].

* Contribute to RISC-V. You can buy a RISC-V SoC today [2]. Does your favorite compiler have a RISC-V backend?

[1] https://www.reddit.com/r/linux/comments/5xvn4i/update_corebo... [2] https://www.sifive.com/products/hifive1/

◧◩
29. Admira+Yl[view] [source] [discussion] 2017-07-11 14:46:52
>>x86ins+hc
AMD is not going to open-source or disable PSP. That thread was four months ago and they still haven't even commented publicly on it. See this recent update from 8 days ago:

https://www.reddit.com/r/Amd/comments/6krg13/has_there_been_...

If AMD really wanted to, they would have announced something by now. I can commend the AMD rep who continues to push for it, but he can't dictate company policy.

◧◩◪
31. majews+Am[view] [source] [discussion] 2017-07-11 14:50:57
>>hollan+7l
Y'know they're a volunteer effort, right? According to https://www.qubes-os.org/funding/, they didn't receive any major funding this year, so if you want progress in this area, you should donate: https://www.qubes-os.org/donate/
◧◩◪◨
42. qb45+yu[view] [source] [discussion] 2017-07-11 15:46:43
>>brians+Ci
What makes you think that x86 MacBooks or Chromebooks could work without ME?

Also, according to libreboot FAQ, even Google was unable to get source for Intel firmware blobs.

https://libreboot.org/faq.html#intel-is-uncooperative

◧◩◪
58. wuch+xC[view] [source] [discussion] 2017-07-11 16:39:50
>>emilfi+Sy
Problem is not what your machine does with an USB device, but what the USB device does with machine [0].

[0] https://security.stackexchange.com/questions/118854/attacks-...

◧◩◪◨⬒
59. CaptSp+cD[view] [source] [discussion] 2017-07-11 16:45:09
>>pmoria+Gy
> https://puri.sm/posts/camera-microphone-hardware-kill-switch...

The purism laptops do, but afaik, they are the only ones.

63. notaci+5I[view] [source] 2017-07-11 17:17:31
>>doener+(OP)
This article helped me get up and running with Qubes:

https://medium.com/@securitystreak/living-with-qubes-os-r3-2...

◧◩
65. fghtr+UJ[view] [source] [discussion] 2017-07-11 17:30:34
>>d33+y5
>What could one do to make it possible to have ME-less x86 in the future?

One could lock all the devices that can store data: https://blog.invisiblethings.org/papers/2015/state_harmful.p...

"The general idea is to remove the SPI flash chip from the motherboard, and route the wiring to one of the external ports, such as either a standard SD or a USB port, or perhaps even to a custom connector. A Trusted Stick (discussed in the next chapter) would be then plugged into this port before the platform boots, and would be delivering all the required firmware requested by the processor, as well as other firmware and, optionally, all the software for the platform."

◧◩◪◨
76. cyphar+9m1[view] [source] [discussion] 2017-07-11 22:00:13
>>raesen+Yw
CPU firmware is likely the worst type of compromise (see Intel ME). However, the issue is that private information can be gained by listening in on conversations near a laptop or by recording what the camera sees.

Keylogging isn't good either, but if you're using a password manager and/or 2FA then it's not really as big of an issue. It is an issue for your disk encryption passphrase, but I'm hoping that in the future we might be able to remedy that through some 2FA-like system[1]. If we seal disk encryption keys inside TPMs then we have to only come up with a sane security policy (which is obviously the hard part).

Disk controllers are similarly not an issue if you have full-disk encryption (though then your RAM is the weak point because it contains the keys). There was some work in the past about encrypted RAM but I doubt that is going to be a reality soon. The real concern is that a worrying array of devices plugged into your laptop can DMA your memory (USB 3.1, PCI, etc). iommu improves this slightly but from memory there is still some kernel work necessary to make the order in which devices load secure (if you load a device that supports DMA before iommu is loaded then you don't have iommu defences).

[1]: https://www.youtube.com/watch?v=ykG8TGZcfT8 "Beyond Anti-Evil Maid"

◧◩◪◨⬒
78. nickps+so1[view] [source] [discussion] 2017-07-11 22:22:48
>>falcol+xn
It's a solved problem. Paul Karger, who invented the attack and concept in the 1970's, immediately worked with others to solve it with rigorous methods called high-assurance security. Far as this problem, it's mainly a problem of people you trust reviewing it, it getting distributed to you, and you verifying you got what they reviewed. With most distro's, it boils down to that since you have to trust millions of lines of code (maybe privileged) in the first place. SCM security of a trusted repo becomes the solution. Wheeler covers SCM security here:

https://www.dwheeler.com/essays/scm-security.html

Now, let's say you want to know the compiler isn't a threat. That requires you to know that (a) it does its job correctly, (b) optimizations don't screw up programs esp removing safety checks, and (c) it doesn't add any backdoors. You essentially need a compiler whose implementation can be reviewed against stated requirements to ensure it does what it says, nothing more, nothing less. That's called a verified compiler. Here's what it takes assuming multiple, small passes for easier verification:

1. A precise specification of what each pass does. This might involve its inputs, intermediate states, and its outputs. This needs to be good enough to both spot errors in the code and drive testing.

2. An implementation of each pass done in as readable a way possible in the safest, tooling-assisted language one can find.

3. Optionally, an intermediate representation of each pass side-by-side with the high-level one that talks in terms of expressions, basic control flow (i.e. while construct), stacks, heaps, and so on. The high-level decomposed into low-level operations that still aren't quite assembly.

4. The high-level or intermediate forms side by side with assembly language for them. This will be simplified, well-structured assembly designed for readability instead of performance.

5. An assembler, linker, loader, and/or anything else I'm forgetting that the compiler depends on to produce the final executable. Each of these will be done as above with focus on simplicity. May not be feature complete so much as just enough features to build the compiler. Initial ones are done by hand optionally with helper programs that are easy to do by hand.

6. Combine the ASM of compiler manually or by any trusted applications you have so far. The output must run through assembler, linker, etc. to get the initial executable. Test that and use it to compile the high-level compiler. Now, you're set. Rest of development can be done in high-level language w/ compiler extensions or more optimizations.

7. Formal specification and verification of the above for best results. Already been done with CompCert for C and CakeML for SML. Far as trust, CakeML runs on Isabelle/HOL whose proof checker is smaller than most programs. HOL/Light will make it smaller. This route puts trust mostly in the formal specs with one, small, trusted executable instead of a pile of specs and code. Vast increase in trustworthiness.

@rain1 has a site collecting as many worked examples as possible of small, verified, or otherwise bootstrapping-related work on compilers or interpreters. I contributed a bunch on there, too. I warn it looks rough since it's a work in progress that's focused more on content than presentation. Already has many, many weekends worth of reading for people interested in Trusting Trust solutions. Here it is for your enjoyment or any contributions you might have:

https://bootstrapping.miraheze.org/wiki/Main_Page

◧◩◪◨⬒⬓
82. nickps+dA1[view] [source] [discussion] 2017-07-12 00:52:14
>>jancsi+Mw
Once you learn digital design, you learn how tools like this works:

http://opencircuitdesign.com/qflow/

Start with a simple CPU and memories you can hand-check sent to a 0.35-0.5 micron fab that's visually inspectible. Then, after verifying random sample of those, you use the others in boards that make the rest of your hardware and software. You can even try to use them in peripherals like your keyboard or networking. Make a whole cluster of crappy, CPU boards running verified hardware each handling part of the job since it will take a while. You can use untrusted storage if the source and transport CPU's are trusted since you can just use crypto approaches to ensuring data wasn't tampered with in untrusted RAM or storage. Designs exist in CompSci for both.

So, you'll eventually be running synthesis and testing with open-source software, verification with ACL2 a la Jared Davis's work (maybe Milawa modified), visual inspection of final chips, and Beowulf-style clusters to deal with how slow they are. And then use that for each iteration of better tooling. I also considered using image recognition on the pics of the visual trained by all the people reviewing them across the world. More as an aid than replacing people. Would be helpful when transistor count went up, though.

Other links:

https://www.cs.utexas.edu/users/moore/publications/acl2-pape...

https://www.cs.utexas.edu/users/jared/milawa/Web/

http://www.vlsitechnology.org/html/libraries.html

◧◩◪◨⬒
85. qb45+5Y1[view] [source] [discussion] 2017-07-12 07:37:36
>>floatb+PU
I'm under impression that USB 3.1 DMA is a semi-fake news viral meme.

https://news.ycombinator.com/item?id=14669377

> Is that running on the chipset or the CPU?

USB 3.x controllers are more complex than predecessors and typically run some firmware on the controller chip to implement functionality which used to be implemented in the OS drivers.

[go to top]