<<

Lecture Notes in Computer Science 11254

Commenced Publication in 1973 Founding and Former Series Editors: Gerhard Goos, Juris Hartmanis, and Jan van Leeuwen

Editorial Board David Hutchison Lancaster University, Lancaster, UK Takeo Kanade Carnegie Mellon University, Pittsburgh, PA, USA Josef Kittler University of Surrey, Guildford, UK Jon M. Kleinberg Cornell University, Ithaca, NY, USA Friedemann Mattern ETH Zurich, Zurich, Switzerland John C. Mitchell Stanford University, Stanford, CA, USA Moni Naor Weizmann Institute of Science, Rehovot, Israel C. Pandu Rangan Indian Institute of Technology Madras, Chennai, India Bernhard Steffen TU Dortmund University, Dortmund, Germany Demetri Terzopoulos University of California, Los Angeles, CA, USA Doug Tygar University of California, Berkeley, CA, USA Gerhard Weikum Max Planck Institute for Informatics, Saarbrücken, Germany More information about this series at http://www.springer.com/series/7408 Tiago Massoni • Mohammad Reza Mousavi (Eds.)

Formal Methods: Foundations and Applications 21st Brazilian Symposium, SBMF 2018 Salvador, , November 26–30, 2018 Proceedings

123 Editors Tiago Massoni Mohammad Reza Mousavi Federal University of Campina Grande University of Leicester Campina Grande, Brazil Leicester, UK

ISSN 0302-9743 ISSN 1611-3349 (electronic) Lecture Notes in Computer Science ISBN 978-3-030-03043-8 ISBN 978-3-030-03044-5 (eBook) https://doi.org/10.1007/978-3-030-03044-5

Library of Congress Control Number: 2018958772

LNCS Sublibrary: SL2 – Programming and Software Engineering

© Springer Nature Switzerland AG 2018 Chapter “TeSSLa: Temporal Stream-Based Specification Language” is licensed under the terms of the Creative Commons Attribution 4.0 International License (http://creativecommons.org/licenses/by/4.0/). For further details see license information in the chapter. This work is subject to copyright. All rights are reserved by the Publisher, whether the whole or part of the material is concerned, specifically the rights of translation, reprinting, reuse of illustrations, recitation, broadcasting, reproduction on microfilms or in any other physical way, and transmission or information storage and retrieval, electronic adaptation, computer software, or by similar or dissimilar methodology now known or hereafter developed. The use of general descriptive names, registered names, trademarks, service marks, etc. in this publication does not imply, even in the absence of a specific statement, that such names are exempt from the relevant protective laws and regulations and therefore free for general use. The publisher, the authors, and the editors are safe to assume that the advice and information in this book are believed to be true and accurate at the date of publication. Neither the publisher nor the authors or the editors give a warranty, express or implied, with respect to the material contained herein or for any errors or omissions that may have been made. The publisher remains neutral with regard to jurisdictional claims in published maps and institutional affiliations.

This Springer imprint is published by the registered company Springer Nature Switzerland AG The registered company address is: Gewerbestrasse 11, 6330 Cham, Switzerland Preface

Welcome to the proceedings of the 21st Brazilian Symposium on Formal Methods (SBMF 2018), held during November 26–30, 2018, in Salvador, Brazil. This volume contains the papers accepted for presentation at SBMF 2018. For this edition of SBMF, we received 30 full submissions from 15 different countries. An international Program Committee comprising 56 leading scientists from 13 countries reviewed the papers thoroughly, providing a minimum of three and a maximum of five review reports for each paper. We ended up accepting 14 submissions, which translates into 47% of all submissions. The program included three invited talks by the following world-renowned computer scientists: – Prof. José Meseguer, University of Illinois at Urbana-Champaign, USA – Prof. Alexandre Mota, Federal University of , Brazil – Prof. Jim Davies, University of Oxford, UK We thank the Brazilian Computer Society (SBC), the Federal University of Bahia, and the Organizing Committee, for having provided various facilities and for their generous support. We are also grateful to our Program Committee (and additional reviewers) for their professional and hard work in providing expert review reports and thorough discussions leading to a very interesting and strong program. Many thanks for the sponsorship of the Federal University of Bahia (UFBA) and CAPES, and Springer for agreeing to publish the proceedings as a volume of Lecture Notes of Computer Science. We also acknowledge the facilities provided by the EasyChair system, which were crucial in managing the process of submission, selection, revision, and publica- tion of the manuscripts included in this volume.

September 2018 Tiago Massoni Mohammad Reza Mousavi Organization

Program Committee

Aline Andrade Universidade Federal da Bahia, Brazil Luis Barbosa University of Minho, Portugal Harsh Beohar Universität Duisburg-Essen, Germany Christiano Braga Universidade Federal Fluminense, Brazil Michael Butler University of Southampton, UK Sergio Campos UFMG, Brazil Ana Cavalcanti University of York, UK Simone André Da Costa Universidade Federal de Pelotas, Brazil Cavalheiro Matteo Cimini University of Massachusetts Lowell, USA Márcio Cornélio UFPE, Brazil Andrea Corradini Università di Pisa, Italy Pedro R. D’Argenio Universidad Nacional de Córdoba, Argentina Jim Davies University of Oxford, UK Ana De Melo University of São Paulo, Brazil David Deharbe ClearSy, France Ewen Denney RIACS/NASA, USA Clare Dixon University of Liverpool, UK Rachid Echahed CNRS and University of Grenoble, France José Luiz Fiadeiro Royal Holloway, University of London, UK Alysson Filgueira UEPB, Brazil Luciana Foss Universidade Federal de Pelotas, Brazil Rohit Gheyi Universidade Federal de Campina Grande, Brazil Jan Friso Groote Eindhoven University of Technology, The Netherlands Stefan Hallerstede Aarhus University, Denmark Reiko Heckel University of Leicester, UK Rob Hierons The University of Sheffield, UK Hossein Hojjat Rochester Institute of Technology, USA Juliano Iyoda Universidade Federal de Pernambuco, Brazil Thierry Lecomte ClearSy, France Michael Leuschel University of Düsseldorf, Germany Patricia Machado Federal University of Campina Grande, Brazil Rodrigo Machado Universidade Federal do Rio Grande do Sul, Brazil Marcelo Maia Universidade Federal de Uberlândia, Brazil Narciso Marti-Oliet Universidad Complutense de Madrid, Spain Anamaria Martins Moreira Universidade Federal do Rio de Janeiro, Brazil Tiago Massoni Universidade Federal de Campina Grande, Brazil Alvaro Moreira Federal University of Rio Grande do Sul, Brazil VIII Organization

Alexandre Mota Universidade Federal de Pernambuco, Brazil Arnaldo Moura Universidade Estadual de Campinas, Brazil Mohammad Mousavi University of Leicester, UK David Naumann Stevens Institute of Technology, USA Minh Ngo Inria, France Daltro Jose Nunes Institute of Informatics, Federal University of Rio Grande do Sul, Brazil Jose Oliveira University of Minho, Portugal Marcel Vinicius Medeiros Universidade Federal do Rio Grande do Norte, Brazil Oliveira Fernando Orejas Universitat Politècnica de Catalunya, Spain Arend Rensink University of Twente, The Netherlands Leila Ribeiro Universidade Federal do Rio Grande do Sul, Brazil Jan Oliver Ringert University of Leicester, UK Augusto Sampaio Federal University of Pernambuco, Brazil Leila Silva Universidade Federal de Sergipe, Brazil Adenilso Simao Universidade de São Paulo, Brazil Neeraj Singh INPT-ENSEEIHT/IRIT, University of Toulouse, France Ana Sokolova University of Salzburg, Austria Sofiene Tahar Concordia University, Canada Jim Woodcock University of York, UK

Additional Reviewers

Beohar, Harsh Nikouei, Mohammad Dezani, Mariangiola Rashid, Adnan Gazda, Maciej Ribeiro, Pedro Klein Galli, Jaqueline Siddique, Umair Laveaux, Maurice Stolz, Volker Milanez, Alysson Tuosto, Emilio Neele, Thomas Varshosaz, Mahsa Contents

The Pragmatic Dimension of Formal Methods: Towards Building a Sound Synthesiser ...... 1 Alexandre Mota

Formal Design of Cloud Computing Systems in Maude ...... 5 José Meseguer

Source Code Analysis with a Temporal Extension of First-Order Logic . . . . . 20 David Come, Julien Brunel, and David Doose

A Type-Directed Algorithm to Generate Well-Typed Featherweight Java Programs ...... 39 Samuel S. Feitosa, Rodrigo Geraldo Ribeiro, and Andre Rauber Du Bois

Programming Language Foundations in Agda...... 56 Philip Wadler

Formal Verification of n-bit ALU Using Theorem Proving...... 74 Sumayya Shiraz and Osman Hasan

The Scallina Grammar: Towards a Scala Extraction for Coq...... 90 Youssef El Bakouny and Dani Mezher

VDM at Large: Modelling the EMV® 2nd Generation Kernel ...... 109 Leo Freitas

Constraint Reusing and k-Induction for Three-Valued Bounded Model Checking ...... 126 Nils Timm, Stefan Gruner, and Matthias Harvey

TeSSLa: Temporal Stream-Based Specification Language...... 144 Lukas Convent, Sebastian Hungerecker, Martin Leucker, Torben Scheffel, Malte Schmitz, and Daniel Thoma

Automatic Test Case Generation for Concurrent Features from Natural Language Descriptions...... 163 Rafaela Almeida, Sidney Nogueira, and Augusto Sampaio

A Methodology for Protocol Verification Applied to EMV® 1...... 180 Leo Freitas, Paolo Modesti, and Martin Emms X Contents

Analysing RoboChart with Probabilities...... 198 M. S. Conserva Filho, R. Marinho, A. Mota, and J. Woodcock

Timed Scenarios: Consistency, Equivalence and Optimization...... 215 Neda Saeedloei and Feliks Kluźniak

Safe and Constructive Design with UML Components...... 234 Flávia Falcão, Lucas Lima, and Augusto Sampaio

Formal Modelling of Environment Restrictions from Natural-Language Requirements ...... 252 Tainã Santos, Gustavo Carvalho, and Augusto Sampaio

Author Index ...... 271