An abstract semantics of speculative execution for reasoning about security vulnerabilities

03/10/2020
by   Robert J. Colvin, et al.
0

Reasoning about correctness and security of software is increasingly difficult due to the complexity of modern microarchitectural features such as out-of-order execution. A class of security vulnerabilities termed Spectre that exploits side effects of speculative, out-of-order execution was announced in 2018 and has since drawn much attention. In this paper we formalise speculative execution and its side effects with the intention of allowing speculation to be reasoned about abstractly at the program level, limiting the exposure to processor-specific or low-level semantics. To this end we encode and expose speculative execution explicitly in the programming language, rather than solely in the operational semantics; as a result the effects of speculative execution are captured by redefining the meaning of a conditional statement, and introducing novel language constructs that model transient execution of an alternative branch. We add an abstract cache to the global state of the system, and derive some general refinement rules that expose cache side effects due to speculative loads. Underlying this extension is a semantic model that is based on instruction-level parallelism. The rules are encoded in a simulation tool, which we use to analyse an abstract specification of a Spectre attack and vulnerable code fragments.

READ FULL TEXT
research
02/13/2018

A wide-spectrum language for verification of programs on weak memory models

Modern processors deploy a variety of weak memory models, which for effi...
research
11/26/2022

Hacky Racers: Exploiting Instruction-Level Parallelism to Generate Stealthy Fine-Grained Timers

Side-channel attacks pose serious threats to many security models, espec...
research
09/06/2023

This is How You Lose the Transient Execution War

A new class of vulnerabilities related to speculative and out-of-order e...
research
12/23/2020

Representing Partial Programs with Blended Abstract Semantics

Synthesizing programs from examples requires searching over a vast, comb...
research
08/04/2021

An Exhaustive Approach to Detecting Transient Execution Side Channels in RTL Designs of Processors

Hardware (HW) security issues have been emerging at an alarming rate in ...
research
09/02/2022

Automatic Detection of Speculative Execution Combinations

Modern processors employ different prediction mechanisms to speculate ov...
research
09/20/2017

Context-Updates Analysis and Refinement in Chisel

This paper presents the context-updates synthesis component of Chisel--a...

Please sign up or login with your details

Forgot password? Click here to reset