Authors
Dominique Devriese, Marco Patrignani, Frank Piessens, Steven Keuchel
Publication date
2017/10/25
Journal
Logical methods in computer science
Volume
13
Publisher
Episciences. org
Description
A compiler is fully-abstract if the compilation from source language programs to target language programs reflects and preserves behavioural equivalence. Such compilers have important security benefits, as they limit the power of an attacker interacting with the program in the target language to that of an attacker interacting with the program in the source language. Proving compiler full-abstraction is, however, rather complicated. A common proof technique is based on the back-translation of target-level program contexts to behaviourally-equivalent source-level contexts. However, constructing such a backtranslation is problematic when the source language is not strong enough to embed an encoding of the target language. For instance, when compiling from a simply-typed λcalculus (λτ) to an untyped λ-calculus (λu), the lack of recursive types in λτ prevents such a back-translation.
We propose a general and elegant solution for this problem. The key insight is that it suffices to construct an approximate back-translation. The approximation is only accurate up to a certain number of steps and conservative beyond that, in the sense that the context generated by the back-translation may diverge when the original would not, but not vice versa. Based on this insight, we describe a general technique for proving compiler full-abstraction and demonstrate it on a compiler from λτ to λu. The proof uses asymmetric cross-language logical relations and makes innovative use of step-indexing to express the relation between a context and its approximate back-translation. The proof extends easily to common compiler patterns such as modular compilation and, to …
Total citations
20162017201820192020202120222023202424826212
Scholar articles
D Devriese, M Patrignani, F Piessens, S Keuchel - Logical methods in computer science, 2017