Article - P25-Markettos - Through Computer Architecture, Darkly

You might also like

Download as pdf or txt
Download as pdf or txt
You are on page 1of 3

V

viewpoints

DOI:10.1145/3325284 A.T. Markettos, R.N.M. Watson, S.W. Moore, P. Sewell, and P.G. Neumann

Inside Risks
Through Computer
Architecture, Darkly
Total-system hardware and microarchitectural
issues are becoming increasingly critical.

S
PECTRE, 11 MELTDOWN, 13 FORE-
SHADOW, 18,20 Rowhammer,9
Spoiler, —suddenly it seems
9

as if there is a new and un-


ending stream of vulner-
abilities in processors. Previous niche
concepts such as speculative execution
and cache timing side-channels have
taken center stage. Across the whole
hardware/software system, new vulner-
abilities such as insufficiently protect-
ed memory access from untrustworthy
PCIe or Thunderbolt USB-C periph-
erals,15 malicious Wi-Fi firmware,4 or
alleged hardware implants14 are also
starting to emerge.
We may be facing a crisis in systems
design. What might we do about it?
Here, we consider whether existing ap-
proaches are adequate, and where sub-
stantial new work is needed.

Prove, Don’t Patch


Many existing commercial operating
systems have extensive vulnerabili-
ties. The MITRE repository of com-
mon software security vulnerabilities
COLL AGE BY A NDRIJ BO RYS ASSOCIATES, U SING SH UT T ERSTOCK

(CVEs: http://cve.mitre.org) currently


has over 110,000 open enumerated lars, which clearly tilts the balance of large classes of attacks. It relies on
vulnerabilities that have been report- firmly in favor of the attacker. trustworthy models of the architec-
ed (excluding ones that have been re- Recent advances such as the seL4 tural abstraction—the hardware/soft-
solved, and totally ignoring countless microkernel,10 the CertiKOS virtual- ware interface—and those too have
other vulnerabilities that have never machine hierarchy,8 and the Comp- advanced recently, in work by the au-
been reported); the list is growing at Cert verified compiler12 have signifi- thors and others.1,6
a rate of approximately 50 new vulner- cantly contributed to the state of the
abilities each day. Patches cannot pos- art in formally proven correctness of Looking Behind
sibly keep up with the weaknesses. In operating-system kernels. This tech- the Hardware Curtain
addition, patching silicon takes years nology is not yet widespread, but it of- It has recently become clear that this
and potentially costs billions of dol- fers the potential to prove the absence is not enough, in several ways. First,

JU N E 2 0 1 9 | VO L. 6 2 | N O. 6 | C OM M U N IC AT ION S OF T HE ACM 25
viewpoints

processor hardware (typically subject there by the designer but were created
to extensive verification) has long been by the physical implementation, often
assumed to provide a solid foundation Designers need unhelpfully sucking away signals or
for software, but increasingly suffers to understand more power. Today we have parasitic com-
from its own vulnerabilities. Second, puters. Many components have unin-
increasing complexity and the way sys- of what takes place tended computational power, which
tems are composed of many hardware/ in layers above can be perverted—from the x86 page-
software pieces, from many vendors, fault handler2 to DMA controllers.16
means one cannot think just in terms or below their field This presents a challenge to under-
of a single-processor architecture. We of expertise. standing where all the computation is
need to take a holistic view that ac- happening, such as what is software
knowledges the complexities of this rather than hardware.
landscape. Third, and most seriously,
these new attacks involved phenomena Toward Robustly Engineered
that cut across the traditional architec- Trustworthy Systems
tural abstractions, which have inten- exploitable malfunction. Unlike the bi- Total-system approaches to security
tionally only described the envelopes nary code of malware, there is no way to defenses are important (see, for ex-
of allowed functional behavior of hard- observe many of these physical proper- ample, Bellovin3). A further lesson
ware implementations, to allow imple- ties. As a result, systems are more vul- from physical-layer attacks is why
mentation variation in performance. nerable to both design mistakes and such attacks are not more of a threat
That flexibility has been essential to supply-chain attacks. today—due to further layers of pro-
hardware performance increases—but As the recent attacks demonstrate, tection. It is not enough to extract
the attacks involve subtle information side-channels are becoming more the cryptographic key from a banking
flows via performance properties. They powerful than expected. Traditional card using laser fault injection; the at-
expose the hidden consequences of physical-layer side-channels are a sig- tacker must also use it to steal money.
some of the microarchitectural inno- nals-from-noise problem. If you record At this point the bank’s system-level
vations that have given us ever-faster enough traces of the power usage, with defenses apply, such as transaction
sequential computation in the last de- powerful enough signal processing, limits and fraud detection. If the key
cades, as caching and prediction leads you can extract secrets. Architectural relates only to one account, the payoff
to side-channels. side-channels have more bandwidth involves only money held by that cus-
and better signal-to-noise ratios, leak- tomer, not all other customers. Ap-
Hardware Vulnerabilities ing much more data more reliably. plication-level compartmentalization
Ideally, security must be built from the If we take a systems-oriented view, limits the reward, and thus makes the
ground up. How can we solve the prob- what can we say about the problem? attack economically nonviable.
lem by building the foundations of se- First of all, the whole is often worse Another approach is to ensure that
cure hardware? than the sum of its parts. Systems are richer contextual information is avail-
For years, hardware security to many composed of disparate components, able that allows the hardware to under-
people has meant focusing on the often sourced from different vendors, stand and enforce security properties.
physical layers. Power/electromagnetic and often granting much greater access The authors are on a team designing,
side-channels and fault injection are to resources than needed to fulfill their developing, and formally analyzing
common techniques for extracting purpose; this can be a boon for attack- the CHERI hardware instruction-set
cryptographic secrets by manipulating ers. For example, in Google Project Ze- architecture,20 as well as CHERI oper-
the physical implementation of a chip. ro’s attack on the Broadcom Wi-Fi chip ating system and application security.
These are not without effectiveness, inside iPhones,4 the attackers jumped The CHERI ISA can enable hardware to
but it is notable that the new spate of from bad Wi-Fi packets to installing enforce pointer provenance, arbitrarily
attacks represents entirely different, malicious code on the Wi-Fi chip, and fine-grained access controls to virtual
and more potent, attack vectors. then to compromising iOS on the ap- memory and to abstract system ob-
One lesson from the physical-layer plication processor. Their ability to use jects, as well as both coarse- and fine-
security community is that implemen- the Wi-Fi chip as a springboard mul- grained compartmentalization. To-
tation is critical. Hardware definition tiplied their efficacy. It is surprisingly gether, these can provide enforceable
languages (HDLs) are compiled down difficult to reason about the behavior of separation and controlled sharing, al-
to connections between library logic such compositions of components.5 At- lowing trustworthy and untrustworthy
cells. The logic cells are then placed tackers may create new side-channels software (including unmodified legacy
and routed and the chip layer designs through unexpected connections—for code) to coexist securely. Since the
produced. One tiny slip—at any level example, a memory DIMM that can hardware has awareness of software
from architecture to HDL source and send network packets via a shared I2C constructs such as pointers and com-
compiler, to cell transistor definitions, bus with an Ethernet controller.17 partments, it can protect them, and we
routing, power, thermals, electromag- Hardware engineers often talk can reason about the protection guar-
netics, dopant concentrations and about ‘parasitic’ resistance or capaci- antees—for example, formally proving
crystal lattices—can cause a potentially tance—components that were not put the architectural abstraction enforces

26 COM MUNICATIO NS O F TH E AC M | J U NE 201 9 | VO L . 62 | NO. 6


viewpoints

specific security properties. We believe


this CHERI system architecture has
References
1. Armstrong, A. et al. ISA Semantics for ARMv8-A,
RISC-V, and CHERI-MIPS. In Proceedings of the
Calendar
significant potential to provide unprec-
edented total-system trustworthiness,
including addressing some of the side-
Principles of Programming Languages Conference
(POPL) 2019.
2. Bangert, J. et al. The page-fault weird machine:
Lessons in instruction-less computation. In
of Events
channel attacks that were unknown at Proceedings of the USENIX Workshop on Offensive June 2–6
Technologies (WOOT), 2013.
the time of its conception.19 3. Bellovin, S.M. and Neumann, P.G. The big picture: A
JCDL ‘19: The 18th ACM/IEEE
systems-oriented view of trustworthiness. Commun. Joint Conference on Digital
Such architectural guarantees enable
ACM 61, 11 (Nov. 2018), 24–26. Libraries Champaign, IL,
more secure implementation of currently 4. Beniamini, G. Over The Air: Exploiting Broadcom’s Wi-Fi Sponsored: ACM/SIG,
insecure languages (such as C/C++) and Stack; https://bit.ly/2oA6GJL Contact: J. Stephen Downie,
5. Gerber, S. et al. Not your parents’ physical address
can put demonstrably secure operat- space. In Proceedings of the Hot Topics in Operating
Email: jdownie@illinois.edu
Systems Conference (HotOS-XV) 2015.
ing-system kernels on a more secure 6. Goel, S., Hunt, W.A. Jr., and Kaufmann, M. Engineering June 3–5
foundation. Similar approaches may a formal, executable x86 ISA simulator for software SIGSIM-PADS ‘19:
verification. Provably Correct Systems (ProCoS), 2017.
apply in other domains, for example 7. Google Project Zero, 2018; https://bit.
SIGSIM Principles of Advanced
between vulnerable components ly/2CAQzTMGu, R. et al. CertiKOS: An Extensible Discrete Simulation,
Architecture for Building Certified Concurrent OS Chicago, IL,
across a system-on-chip. Kernels. OSDI 2016, 653–669; See also https://bit. Sponsored: ACM/SIG,
Engineering such systems re- ly/2Uzj9sI for ongoing work. Contact: Dong Jin,
8. Islam, S. et al. SPOILER: Speculative Load Hazards
quires a more holistic view, with a Boost Rowhammer and Cache Attacks, arXiv e-prints
Email: dong.jin@iit.edu
tighter interplay between hardware, (Mar. 1, 2019); https://bit.ly/2TxWdhk
9. Klein, G. et al. Comprehensive formal verification of June 3–5
operating systems and applications. an OS microkernel. ACM Trans. Computer Systems SYSTOR ‘19: International
In particular, designers need to un- 2014; See also https://bit.ly/2UPKgEY for ongoing Systems and Storage Conference,
work.
derstand more of what takes place 10. Kocher, P. et al. Spectre attacks: Exploiting Haifa, Israel,
in layers above or below their field of speculative execution. ArXiv e-prints (Jan. 2018); Sponsored: ACM/SIG,
https://bit.ly/2lUpJLk Contact: Moshik Hershcovitch,
expertise. Better architectural models 11. Leroy, X. A formally verified compiler back-end. Journal Email: moshikh@il.ibm.com
enable more robust verification of se- of Automated Reasoning 43, 4 (2009), 363–446.
12. Lipp, M. et al. Meltdown, 2018; https://bit.ly/2E6myYl
curity properties, and amortizing veri- 13. Markettos, A.T. Making sense of the Supermicro June 3–6
fication costs across projects helps motherboard attack; https://bit.ly/2PqOnld SACMAT ‘19: The 24th ACM
14. Markettos, A.T. et al. Thunderclap: Exploring Symposium on Access Control
defenders but not attackers. Such vulnerabilities in operating system IOMMU protection Models and Technologies,
via DMA from untrustworthy peripherals. In
verification must be inclusive, testing Proceedings of the Network and Distributed Systems
Toronto, ON,
all the aspects of a system including Security Symposium (NDSS), (Feb. 2019). Sponsored: ACM/SIG,
15. Rushanan, M. and Checkoway, S. Run-DMA. In Contact: Atefeh (Atty) Mashatan,
the boundaries of implementation- Proceedings of the WOOT 2015 Conference. (2015). Email: amashatan@ryerson.ca
defined behavior. 16. Sutherland, G. Secrets of the motherboard ([sh*t]
my chipset says). In Proceedings of the 44CON 2017,
Better verification can defend us (Sept. 2017). June 5–7
against new vulnerabilities present in 17. Van Bulck, J. et al. Foreshadow: Extracting the keys TVX ‘19: ACM International
to the Intel SGX kingdom with transient out-of-order Conference on Interactive
the abstractions it is based upon, but execution. USENIX Security (Aug. 15–17, 2018); Experiences for TV and
not against those that involve phenom- https://bit.ly/2DusEDT
Online Video,
18. Watson, R.N.M. et al. Capability Hardware Enhanced
ena that are not modeled. An open RISC Instructions (CHERI): Notes on the Meltdown Salford (Manchester), U.K.,
question is whether there is an abstrac- and Spectre Attacks. Technical Report UCAM- Sponsored: ACM/SIG,
CL-TR-916, University of Cambridge, Computer Contact: Jonathan Hook,
tion between an architectural specifi- Laboratory (Feb. 2018); https://bit.ly/2DuVDrr Email: jonathan.hook@york.
cation and a full hardware implemen- 19. Watson, R.N.M. et al. Capability Hardware Enhanced
RISC Instructions (CHERI): CHERI Instruction-set
ac.uk
tation that allows us to fully reason Architecture, Version 7, Technical Report UCAM-
about potential leakage, without being CL-TR-927, University of Cambridge, Computer June 9–12
Laboratory (Apr. 2019); https://bit.ly/2XzPgKU UMAP ‘19: 27th Conference on
so complex as to being intractable. 20. Weisse, O. et al. Foreshadow-NG: Breaking the virtual User Modeling, Adaptation
memory abstraction with transient out-of-order
execution (Aug. 2018); https://bit.ly/2VZLD0h and Personalization,
Conclusion Larnaca, Cyprus,
Co-Sponsored: ACM/SIG,
Traditional models—in which design- A. Theodore Markettos (theo.markettos@cl.cam.ac.uk)
Contact: George Angelos
ers have free reign within tightly con- is a Senior Research Associate in the Department of
Computer Science and Technology at the University of Papadopoulos,
strained layers—are no longer fit for Cambridge, U.K. Email: george@cs.ucy.ac.cy
purpose. Hardware/software system Robert N.M. Watson (robert.watson@cl.cam.ac.uk) is a
Senior Lecturer in the Department of Computer Science June 10–13
security architects need better aware- and Technology at the University of Cambridge, U.K. ICMR ‘19: International
ness of what comes above and below Simon W. Moore (simon.moore@cl.cam.ac.uk) is Conference on Multimedia
them, to be able to reason about what Professor of Computer Engineering in the Department of Retrieval,
Computer Science and Technology at the University of Ottawa, ON,
happens at other levels of abstraction, Cambridge, U.K. Sponsored: ACM/SIG,
and to understand the effects of com- Peter Sewell (Peter.Sewell@cl.cam.ac.uk) is Contact: Zhongfei (Mark) Zhang,
position. Managing overall complex- Professor of Computer Science in the Department of Email: zhongfei@
Computer Science and Technology at the University of cs.binghamton.edu
ity must fully capture information that Cambridge, U.K.
might be relevant for security analysis, Peter G. Neumann (neumann@csl.sri.com) is Chief
especially for entirely new classes of Scientist of the SRI International Computer Science Lab,
and moderator of the ACM Risks Forum.
vulnerabilities. The defensive battle
has only just begun. Copyright held by authors.

JU N E 2 0 1 9 | VO L. 6 2 | N O. 6 | C OM M U N IC AT ION S OF T HE ACM 27

You might also like