Abstract
This paper presents our results in the formal verification of kLIBC, a minimalistic C library, using the Frama-C/WP tool. We report how we were able to completely verify a significant number of functions from <string.h> and <stdio.h>. We discuss difficulties encountered and describe in detail a problem in the implementation of common <string.h> functions, for which we suggest alternative implementations. Our work shows that it is presently already viable to verify low-level C code, with heavy usage of pointers. Although the properties proved tend to be shallower as the code becomes of a lower-level nature, it is our view that this is an important direction towards real-world software verification, which cannot be attained by focusing on deep properties of cleaner code, written specifically to be verified.
Access this chapter
Tax calculation will be finalised at checkout
Purchases are for personal use only
Preview
Unable to display preview. Download preview PDF.
Similar content being viewed by others
References
Meyer, B.: Applying “Design by Contract”. IEEE Computer 25(10) (1992)
Burghardt, J., Carben, A., Gerlach, J., Hartig, K., Pohl, H., Völlinger, K.: ACSL By Example – Towards a Verified C Standard Library. DEVICE-SOFT project publication. Fraunhofer FIRST Institute (2011)
Baudin, P., Cuoq, P., Filliâtre, J.-C., Marché, C., Monate, B., Moy, Y., Prevosto, V.: ACSL: ANSI/ISO C Specification Language (June 2013)
Hatcliff, J., Leavens, G.T., Leino, K.R.M., Müller, P., Parkinson, M.: Behavioral interface specification languages. ACM Comput. Surv. 44(3), 16:1–16:58 (2012)
Leavens, G., Cheon, Y.: Design by Contract with JML (2003)
Correnson, L., Cuoq, P., Kirchner, F., Prevosto, V., Puccetti, A., Signoles, J., Yakobowski, B.: Frama-C User Manual (June 2013)
Marché, C.: Jessie: An Intermediate Language for Java and C Verification. In: Stump, A., Xi, H. (eds.) Proceedings of PLPV 2007. ACM (2007)
Baudin, P., Correnson, L., Dargaye, Z.: WP Plug-in Manual (June 2013)
Baudin, P., Correnson, L., Hermann, P.: WP Tutorial (September 2012)
Hermann, P., Signoles, J.: Frama-C’s annotation generator plug-in (June 2013)
Author information
Authors and Affiliations
Editor information
Editors and Affiliations
Rights and permissions
Copyright information
© 2014 Springer International Publishing Switzerland
About this paper
Cite this paper
Carvalho, N., da Silva Sousa, C., Pinto, J.S., Tomb, A. (2014). Formal Verification of kLIBC with the WP Frama-C Plug-in. In: Badger, J.M., Rozier, K.Y. (eds) NASA Formal Methods. NFM 2014. Lecture Notes in Computer Science, vol 8430. Springer, Cham. https://doi.org/10.1007/978-3-319-06200-6_29
Download citation
DOI: https://doi.org/10.1007/978-3-319-06200-6_29
Publisher Name: Springer, Cham
Print ISBN: 978-3-319-06199-3
Online ISBN: 978-3-319-06200-6
eBook Packages: Computer ScienceComputer Science (R0)