Skip to main content

Automatically Verifying Typing Constraints for a Data Processing Language

  • Conference paper
Certified Programs and Proofs (CPP 2011)

Part of the book series: Lecture Notes in Computer Science ((LNTCS,volume 7086))

Included in the following conference series:

Abstract

In this paper we present a new technique for automatically verifying typing constraints in the setting of Dminor, a first-order data processing language with refinement types and dynamic type-tests. We achieve this by translating Dminor programs into a standard while language and then using a general-purpose verification tool. Our translation generates assertions in the while program that faithfully represent the sophisticated typing constraints in the original program. We use a generic verification condition generator together with an SMT solver to prove statically that these assertions succeed in all executions. We formalise our translation algorithm using an interactive theorem prover and provide a machine-checkable proof of its soundness. We provide a prototype implementation using Boogie and Z3 that can already be used to efficiently verify a large number of test programs.

This is a preview of subscription content, log in via an institution to check access.

Access this chapter

Chapter
USD 29.95
Price excludes VAT (USA)
  • Available as PDF
  • Read on any device
  • Instant download
  • Own it forever
eBook
USD 39.99
Price excludes VAT (USA)
  • Available as PDF
  • Read on any device
  • Instant download
  • Own it forever
Softcover Book
USD 54.99
Price excludes VAT (USA)
  • Compact, lightweight edition
  • Dispatched in 3 to 5 business days
  • Free shipping worldwide - see info

Tax calculation will be finalised at checkout

Purchases are for personal use only

Institutional subscriptions

Preview

Unable to display preview. Download preview PDF.

Unable to display preview. Download preview PDF.

References

  1. Bytecode level specification language and program logic. Mobius Project, Deliverable D3.1 (2006)

    Google Scholar 

  2. The Microsoft code name ”M” modeling language specification (October 2009), http://msdn.microsoft.com/en-us/library/dd548667.aspx

  3. Barnett, M., Chang, B.-Y.E., DeLine, R., Jacobs, B., Leino, K.R.M.: Boogie: A Modular Reusable Verifier for Object-Oriented Programs. In: de Boer, F.S., Bonsangue, M.M., Graf, S., de Roever, W.-P. (eds.) FMCO 2005. LNCS, vol. 4111, pp. 364–387. Springer, Heidelberg (2006)

    Chapter  Google Scholar 

  4. Barnett, M., Leino, K.R.M., Schulte, W.: The Spec# Programming System: An Overview. In: Barthe, G., Burdy, L., Huisman, M., Lanet, J.-L., Muntean, T. (eds.) CASSIS 2004. LNCS, vol. 3362, pp. 49–69. Springer, Heidelberg (2005)

    Chapter  Google Scholar 

  5. Barras, B., Boutin, S., Cornes, C., Courant, J., Coscoy, Y., Delahaye, D., de Rauglaudre, D., Filliâtre, J., Giménez, E., Herbelin, H., et al.: The Coq proof assistant reference manual, version 8.2. INRIA (2009)

    Google Scholar 

  6. Bengtson, J., Bhargavan, K., Fournet, C., Gordon, A.D., Maffeis, S.: Refinement types for secure implementations. ACM Transactions on Programming Languages and Systems 33(2), 8 (2011)

    Article  Google Scholar 

  7. Bierman, G.M., Gordon, A.D., Hriţcu, C., Langworthy, D.: Semantic subtyping with an SMT solver. In: 15th ACM SIGPLAN International Conference on Functional programming (ICFP 2010), pp. 105–116. ACM Press (2010)

    Google Scholar 

  8. Böhme, S., Leino, K.R.M., Wolff, B.: HOL-Boogie — An Interactive Prover for the Boogie Program-Verifier. In: Mohamed, O.A., Muñoz, C., Tahar, S. (eds.) TPHOLs 2008. LNCS, vol. 5170, pp. 150–166. Springer, Heidelberg (2008)

    Chapter  Google Scholar 

  9. Cohen, E., Moskal, M., Tobies, S., Schulte, W.: A precise yet efficient memory model for C. Electronic Notes in Theoretical Computer Science 254, 85–103 (2009)

    Article  Google Scholar 

  10. Dahlweid, M., Moskal, M., Santen, T., Tobies, S., Schulte, W.: VCC: Contract-based modular verification of concurrent C. In: 31st International Conference on Software Engineering (ICSE), pp. 429–430. IEEE (2009)

    Google Scholar 

  11. DeLine, R., Leino, K.: BoogiePL: A typed procedural language for checking object-oriented programs. Technical Report MSR-TR-2005-70, Microsoft Research (2005)

    Google Scholar 

  12. Detlefs, D., Nelson, G., Saxe, J.: Simplify: A theorem prover for program checking. Journal of the ACM (JACM) 52(3), 473 (2005)

    Article  MathSciNet  MATH  Google Scholar 

  13. Filliâtre, J.-C., Marché, C.: The Why/Krakatoa/Caduceus Platform for Deductive Program Verification. In: Damm, W., Hermanns, H. (eds.) CAV 2007. LNCS, vol. 4590, pp. 173–177. Springer, Heidelberg (2007)

    Chapter  Google Scholar 

  14. Hosoya, H., Pierce, B.: XDuce: A statically typed XML processing language. ACM Transactions on Internet Technology 3(2), 117–148 (2003)

    Article  Google Scholar 

  15. Jhala, R., Majumdar, R., Rybalchenko, A.: HMC: Verifying Functional Programs Using Abstract Interpreters. In: Gopalakrishnan, G., Qadeer, S. (eds.) CAV 2011. LNCS, vol. 6806, pp. 470–485. Springer, Heidelberg (2011)

    Chapter  Google Scholar 

  16. Kleymann, T.: Hoare logic and auxiliary variables. Formal Aspects of Computing 11(5), 541–566 (1999)

    Article  MATH  Google Scholar 

  17. Knowles, K., Tomb, A., Gronski, J., Freund, S., Flanagan, C.: Sage: Unified hybrid checking for first-class types, general refinement types and Dynamic. Technical report, UCSC (2007)

    Google Scholar 

  18. Kobayashi, N., Ong, C.-H.L.: A type system equivalent to the modal mu-calculus model checking of higher-order recursion schemes. In: 24th Annual IEEE Symposium on Logic in Computer Science (LICS), pp. 179–188. IEEE Computer Society (2009)

    Google Scholar 

  19. Lehner, H., Müller, P.: Formal translation of bytecode into BoogiePL. Electronic Notes in Theoretical Computer Science 190(1), 35–50 (2007)

    Article  Google Scholar 

  20. Leino, K.R.M.: This is Boogie 2. TechReport (2008)

    Google Scholar 

  21. Leino, K.R.M., Millstein, T., Saxe, J.: Generating error traces from verification-condition counterexamples. Science of Computer Programming 55(1-3), 209–226 (2005)

    Article  MathSciNet  MATH  Google Scholar 

  22. Marinos, C.: An introduction to functional programming for.NET developers. MSDN Magazine (April 2010)

    Google Scholar 

  23. Meijer, E., Beckman, B., Bierman, G.M.: LINQ: reconciling object, relations and XML in the .NET framework. In: ACM SIGMOD International Conference on Management of Data (SIGMOD), page 706. ACM (2006)

    Google Scholar 

  24. Morris, J.: Comments on ”procedures and parameters”. Undated and unpublished

    Google Scholar 

  25. Naik, M., Palsberg, J.: A type system equivalent to a model checker. ACM Transactions on Programming Languages and Systems (TOPLAS) 30(5), 29 (2008)

    Article  MATH  Google Scholar 

  26. Nipkow, T.: Hoare logics in Isabelle/HOL. In: Proof and System-Reliability, pp. 341–367. Kluwer (2002)

    Google Scholar 

  27. Pierce, B., Casinghino, C., Greenberg, M., Sjöberg, V., Yorgey, B.: Software Foundations (2010), http://www.cis.upenn.edu/~bcpierce/sf/

  28. Ranise, S., Tinelli, C.: The satisfiability modulo theories library, SMT-LIB (2006), http://www.SMT-LIB.org

  29. Rondon, P.M., Kawaguchi, M., Jhala, R.: Liquid types. In: ACM SIGPLAN 2008 Conference on Programming Language Design and Implementation (PLDI), pp. 159–169 (2008)

    Google Scholar 

  30. Swamy, N., Chen, J., Chugh, R.: Enforcing Stateful Authorization and Information Flow Policies in Fine. In: Gordon, A.D. (ed.) ESOP 2010. LNCS, vol. 6012, pp. 529–549. Springer, Heidelberg (2010)

    Chapter  Google Scholar 

  31. Tarrach, T.: Automatically verifying “M” modeling language constraints. Master’s thesis, Saarland University (2010)

    Google Scholar 

Download references

Author information

Authors and Affiliations

Authors

Editor information

Editors and Affiliations

Rights and permissions

Reprints and permissions

Copyright information

© 2011 Springer-Verlag Berlin Heidelberg

About this paper

Cite this paper

Backes, M., Hriţcu, C., Tarrach, T. (2011). Automatically Verifying Typing Constraints for a Data Processing Language. In: Jouannaud, JP., Shao, Z. (eds) Certified Programs and Proofs. CPP 2011. Lecture Notes in Computer Science, vol 7086. Springer, Berlin, Heidelberg. https://doi.org/10.1007/978-3-642-25379-9_22

Download citation

  • DOI: https://doi.org/10.1007/978-3-642-25379-9_22

  • Publisher Name: Springer, Berlin, Heidelberg

  • Print ISBN: 978-3-642-25378-2

  • Online ISBN: 978-3-642-25379-9

  • eBook Packages: Computer ScienceComputer Science (R0)

Publish with us

Policies and ethics