Compliance and Subtyping in Timed Session Types

  • Massimo Bartoletti
  • Tiziana Cimoli
  • Maurizio Murgia
  • Alessandro Sebastian Podda
  • Livio Pompianu
Part of the Lecture Notes in Computer Science book series (LNCS, volume 9039)

Abstract

We propose an extension of binary session types, to formalise timed communication protocols between two participants at the endpoints of a session. We introduce a decidable compliance relation, which generalises to the timed setting the usual progress-based notion of compliance between untimed session types. We then show a sound and complete technique to decide when a timed session type admits a compliant one, and if so, to construct the least session type compliant with a given one, according to the subtyping preorder induced by compliance. Decidability of subtyping follows from these results. We exploit our theory to design and implement a message-oriented middleware, where distributed modules with compliant protocols can be dynamically composed, and their communications monitored, so to guarantee safe interactions.

References

  1. 1.
    PayPal buyer protection, https://www.paypal.com/us/webapps/mpp/ua/useragreement-full#13 (accessed: January 20, 2015)
  2. 2.
    Alur, R., Dill, D.L.: A theory of timed automata. Theor. Comput. Sci. 126(2), 183–235 (1994)CrossRefMATHMathSciNetGoogle Scholar
  3. 3.
    Barbanera, F., de’Liguoro, U.: Two notions of sub-behaviour for session-based client/server systems. In: PPDP, pp. 155–164 (2010)Google Scholar
  4. 4.
    Barbanera, F., de’Liguoro, U.: Sub-behaviour relations for session-based client/server systems. Math. Struct. in Comp. Science, 1–43 (January 2015)Google Scholar
  5. 5.
    Bartoletti, M., Cimoli, T., Murgia, M., Podda, A.S., Pompianu, L.: Compliance and subtyping in timed session types. Technical report (2015), http://co2.unica.it
  6. 6.
    Bartoletti, M., Tuosto, E., Zunino, R.: Contract-oriented computing in CO2. Sci. Ann. Comp. Sci. 22(1) (2012)Google Scholar
  7. 7.
    Behrmann, G., David, A., Larsen, K.G.: A tutorial on Uppaal. In: Bernardo, M., Corradini, F. (eds.) SFM-RT 2004. LNCS, vol. 3185, pp. 200–236. Springer, Heidelberg (2004)CrossRefGoogle Scholar
  8. 8.
    Bengtsson, J., Yi, W.: Timed automata: Semantics, algorithms and tools. In: Desel, J., Reisig, W., Rozenberg, G. (eds.) ACPN 2003. LNCS, vol. 3098, pp. 87–124. Springer, Heidelberg (2004)CrossRefGoogle Scholar
  9. 9.
    Bocchi, L., Yang, W., Yoshida, N.: Timed multiparty session types. In: Baldan, P., Gorla, D. (eds.) CONCUR 2014. LNCS, vol. 8704, pp. 419–434. Springer, Heidelberg (2014)CrossRefGoogle Scholar
  10. 10.
    Castagna, G., Dezani-Ciancaglini, M., Giachino, E., Padovani, L.: Foundations of session types. In: PPDP, pp. 219–230 (2009)Google Scholar
  11. 11.
    Castagna, G., Gesbert, N., Padovani, L.: A theory of contracts for web services. ACM Transactions on Programming Languages and Systems 31(5) (2009)Google Scholar
  12. 12.
    Corin, R., Deniélou, P.-M., Fournet, C., Bhargavan, K., Leifer, J.J.: A secure compiler for session abstractions. Journal of Computer Security 16(5) (2008)Google Scholar
  13. 13.
    David, A., Larsen, K.G., Legay, A., Nyman, U., Traonouez, L., Wasowski, A.: Real-time specifications. STTT 17(1), 17–45 (2015)CrossRefGoogle Scholar
  14. 14.
    de Alfaro, L., Henzinger, T.A.: Interface automata. In: ACM SIGSOFT, pp. 109–120 (2001)Google Scholar
  15. 15.
    Deniélou, P.-M., Yoshida, N.: Multiparty compatibility in communicating automata: Characterisation and synthesis of global session types. In: Fomin, F.V., Freivalds, R., Kwiatkowska, M., Peleg, D. (eds.) ICALP 2013, Part II. LNCS, vol. 7966, pp. 174–186. Springer, Heidelberg (2013)CrossRefGoogle Scholar
  16. 16.
    Dezani-Ciancaglini, M., de’Liguoro, U.: Sessions and session types: An overview. In: Laneve, C., Su, J. (eds.) WS-FM 2009. LNCS, vol. 6194, pp. 1–28. Springer, Heidelberg (2010)CrossRefGoogle Scholar
  17. 17.
    Henzinger, T.A., Nicollin, X., Sifakis, J., Yovine, S.: Symbolic model checking for real-time systems. Inf. Comput. 111(2), 193–244 (1994)CrossRefMATHMathSciNetGoogle Scholar
  18. 18.
    Honda, K., Vasconcelos, V.T., Kubo, M.: Language primitives and type discipline for structured communication-based programming. In: Hankin, C. (ed.) ESOP 1998. LNCS, vol. 1381, pp. 122–138. Springer, Heidelberg (1998)CrossRefGoogle Scholar
  19. 19.
    Honda, K., Yoshida, N., Carbone, M.: Multiparty asynchronous session types. In: POPL (2008)Google Scholar
  20. 20.
    Krčál, P., Yi, W.: Communicating timed automata: The more synchronous, the more difficult to verify. In: Ball, T., Jones, R.B. (eds.) CAV 2006. LNCS, vol. 4144, pp. 249–262. Springer, Heidelberg (2006)CrossRefGoogle Scholar
  21. 21.
    Laneve, C., Padovani, L.: The must preorder revisited. In: Caires, L., Vasconcelos, V.T. (eds.) CONCUR 2007. LNCS, vol. 4703, pp. 212–225. Springer, Heidelberg (2007)CrossRefGoogle Scholar
  22. 22.
    Neykova, R., Bocchi, L., Yoshida, N.: Timed runtime monitoring for multiparty conversations. In: BEAT, pp. 19–26 (2014)Google Scholar
  23. 23.
    Takeuchi, K., Honda, K., Kubo, M.: An interaction-based language and its typing system. In: Halatsis, C., Maritsas, D., Philokyprou, G., Theodoridis, S. (eds.) PARLE 1994. LNCS, vol. 817, pp. 398–413. Springer, Heidelberg (1994)CrossRefGoogle Scholar
  24. 24.
    Yoshida, N., Hu, R., Neykova, R., Ng, N.: The Scribble protocol language. In: Abadi, M., Lluch Lafuente, A. (eds.) TGC 2013. LNCS, vol. 8358, pp. 22–41. Springer, Heidelberg (2014)CrossRefGoogle Scholar

Copyright information

© IFIP International Federation for Information Processing 2015

Authors and Affiliations

  • Massimo Bartoletti
    • 1
  • Tiziana Cimoli
    • 1
  • Maurizio Murgia
    • 1
  • Alessandro Sebastian Podda
    • 1
  • Livio Pompianu
    • 1
  1. 1.Università degli Studi di CagliariCagliariItaly

Personalised recommendations