Internet of Things (IoT) applications are becoming increasingly critical and require rigorous formal verification. In this paper we target Contiki, a widely used open-source OS for IoT, and present a verification case study of one of its most critical modules: that of linked lists. Its API and list representation differ from the classical linked list implementations, and are particularly chal- lenging for deductive verification. The proposed verification technique relies on a parallel view of a list through a companion ghost array. This approach makes it possible to perform most proofs automatically using the Frama-C/WP tool, only a small number of auxiliary lemmas being proved interactively in the Coq proof assistant. We present an elegant segment-based reasoning over the companion ar- ray developed for the proof. Finally, we validate the proposed specification by proving a few functions manipulating lists.
Proc. of the 10th NASA Formal Methods Symposium (NFM 2018)
Newport News, VA, USA, April 2018, LNCS, vol. 10811, pages 37-53. Springer. ISBN 978-3-319-77934-8
Final publication available at http://link.springer.com. DOI: 10.1007/978-3-319-77935-5_3.