自组合C代码关系性质的静态和动态验证
Static and Dynamic Verification of Relational Properties on Self-Composed C Code
摘要:
函数契约是正式指定函数预期行为的一种行之有效的方法。然而,它们通常只描述在单个呼叫期间应该发生的事情。另一方面,关系属性链接多个函数调用。它们包括不干涉性、连续性和单调性等性质。例如,其他示例涉及函数调用的序列,以表明使用适当的密钥解密加密的消息会返回原始消息。这些性质不能直接在传统的模块化演绎验证中表达,但可以通过自组合进行验证。本文提出了一种基于自组合的C程序关系属性验证技术及其在FRAMA-C插件RPP中的实现。它支持具有副作用的函数和递归函数。所提出的方法可以证明一个关系属性,在运行时检查它,使用测试生成一个反例,并将其作为一个假设,在随后的验证。我们在现有基准上的初步实验证实,所提出的技术是有助于静态和动态分析的相关属性。
英文摘要:
Function contracts are a well-established way of formally specifying the intended behavior of a function. However, they usually only describe what should happen during a single call. Relational properties, on the other hand, link several function calls. They include such properties as non-interference, continuity and monotonicity. Other examples relate sequences of function calls, for instance, to show that decrypting an encrypted message with the appropriate key gives back the original message. Such properties cannot be expressed directly in the traditional setting of modular deductive verification, but are amenable to verification through self-composition. This paper presents a verification technique dedicated to relational properties in C programs and its implementation in the form of a FRAMA-C plugin called RPP and based on self-composition. It supports functions with side effects and recursive functions. The proposed approach makes it possible to prove a relational property, to check it at runtime, to generate a counterexample using testing and to use it as a hypothesis in the subsequent verification. Our initial experiments on existing benchmarks confirm that the proposed technique is helpful for static and dynamic analysis of relational properties.
机构、总结、中文摘要均由AI分析而来,可能存在错误,请以论文正文为准。