一句话:系统评估黑盒检查,证明其仅需极少查询即可快速发现协议与控制器中的深层缺陷。
黑盒检查(BBC)将主动自动机学习、基于模型的测试与模型检查结合,但以往多数应用只在最终假设模型上使用模型检查,较少系统评估其对中间假设模型进行模型检查以快速发现缺陷的能力。本文基于 77 个来自真实协议实现和控制器的基准模型及其安全性规约,首次系统评估 BBC 的快速缺陷检测能力。结果表明:当完整模型可学习时,BBC 检测规约违反仅需“仅检查完整模型”方法约 3% 的查询;即使完整模型不可学习,BBC 仍能发现大量规约违反,在 RERS 2019 工业 LTL 基准中检测到 96% 的安全性属性违反;相比现有基于模型的测试算法,BBC 在发现实现中的深层缺陷方面更有效。
Combinations of active automata learning, model-based testing and model checking have been successfully used in numerous applications, e.g., for spotting bugs in implementations of major network protocols and to support refactoring of embedded controllers. However, in the large majority of these applications, model checking is only used at the very end, when no counterexample can be found anymore for the latest hypothesis model. This contrasts with the original proposal of black-box checking (BBC) by Peled, Vardi & Yannakakis, which applies model checking for all hypotheses, also the intermediate ones. In this article, we present the first systematic evaluation of the ability of BBC to find bugs quickly, based on 77 benchmark models from real protocol implementations and controllers for which specifications of safety properties are available. Our main finding are: (a) In cases where the full model can be learned, BBC detects violations of the specifications with just 3% of the queries needed by an approach in which model checking is only used for the full model. (b) Even when the full model cannot be learned, BBC is still able to detect many violations of the specification. In particular, BBC manages to detect 96% of the safety property violations in the challenging RERS 2019 industrial LTL benchmarks. (c) Our results also confirm that BBC is way more effective than existing model-based testing algorithms in finding deep bugs in implementations.