References:
Source codes data:
“Complete formal verification is the only known way to guarantee that a system is free of programming errors.”
“absence of bugs”
Third generation microkernel, based on L4 [46], influenced by EROS [58];
Features abstractions for virtual address spaces, threads, inter-process communication (IPC);
Exceptions and non-native system calls are also propagated via IPC
IPC:
Capabilities:
CNode
s;Drivers: run as user-mode applications
Explicit memory management:
Unlike most L4 kernels, seL4 features capabilities for authorization;
Privilege Modes:
seL4 could run as an OS kernel (supervisor mode in RISC-V) or as a hypervisor (HS-mode in RISC-V, EL2 on ARM, Root Ring-0 on x86). – Whitepaper 20210610.
Functional correctness:
Worst-Case Execution Time (WCET):
Correctness of:
OS developers tend to take a bottom-up approach to kernel design. High performance is obtained by managing the hardware efficiently, which leads to designs motivated by low-level details. In contrast, formal methods practitioners tend toward top-down design, as proof tractability is determined by system complexity. This leads to designs based on simple models with a high degree of abstraction from hardware.
seL4 methodology: an intermediate target.
Square box: the formal artefacts;
Double arrows: represent impl. or proof effort;
Single arrows: represent design/impl. influence of artefacts on other artefacts;
Haskell prototype of the kernel: the Central Artefact:
C prototype of the kernel: the final production kernel:
Use Isabelle/HOL
Interactive theorem proving vs Automated verification methods:
Interactive theorem proving has the advantage that it is not constrained to specific properties or finite, feasible state spaces, unlike more automated methods of verification such as static analysis or model checking.
Refinement Proof: functional correctness in the strongest sense.
A refinement proof establishes a correspondence between a high-level (abstract) and a low-level (concrete, or refined) representation of a system.
Security properties: abstract model <==> refined model:
If a security property is proved in Hoare logic about the abstract model (not all security properties can be), refinement guarantees that the same property holds for the kernel source code.
SOSP 09 paper: functional correctness property + security of seL4’s access-control system in Isabelle/HOL;
To verify the function correctness:
its behavior is specified precisely, formally, at an abstract level;
its formal design is used to prove desirable properties, including termination and execution safety;
its implementation is formally proven to satisfy the specification;
Methodology of rapid kernel design and implementation:
runs as supervisor-mode kernel on RISC-V platforms.
verifying the RISC-V port of seL4, with proof of functional correctness (to the binary) expected to complete in Q1’20.
Time protection with FPGA hardware prototype.
References: camkes-tool/docs/ CAmkES More
References: The Last Mile: An empirical study of timing channels on seL4, Leakage in Trustworthy Systems, by David Cock, August 2014. Overview Side channel data collection. seL4 on Exynos4412 platform: Scope serverl timing channels on seL4 based system with their defenses with low overhead. Do not consider noise-adding solutions (due to their overhead); Only consider black box techniques (require no insight into the internals of software running on seL4, as retrofitting security into complex software is generally impossible);
References: The last mile Time Protection: The Missing OS Abstraction, Qian Ge, Yuval Yarom, Tom Chothia, and Gernot Heiser. 2019. In Proceedings of the Fourteenth EuroSys Conference 2019 (Dresden, Germany) (EuroSys ’19). ACM, New York, NY, USA, Article 1, 17 pages. https://doi.org/10.1145/3302424.3303976; paper site “No security without time protection: We need a new hardware-software contract.”, Ge, Qian, Yuval Yarom, and Gernot Heiser. In Proceedings of the 9th Asia-Pacific Workshop on Systems, pp.
If you could revise
the fundmental principles of
computer system design
to improve security...
... what would you change?