IEEE Access (Jan 2020)

Using Fault Injection to Assess Blockchain Systems in Presence of Faulty Smart Contracts

  • Akos Hajdu,
  • Naghmeh Ivaki,
  • Imre Kocsis,
  • Attila Klenik,
  • Laszlo Gonczy,
  • Nuno Laranjeiro,
  • Henrique Madeira,
  • Andras Pataricza

DOI
https://doi.org/10.1109/ACCESS.2020.3032239
Journal volume & issue
Vol. 8
pp. 190760 – 190783

Abstract

Read online

Blockchain has become particularly popular due to its promise to support business-critical services in very different domains (e.g., retail, healthcare). Blockchain systems rely on complex middleware, like Ethereum or Hyperledger Fabric, that allow running smart contracts, which specify business logic in cooperative applications. The presence of software defects in these contracts has notably caused failures, including severe security problems. In this article, we use software-implemented fault injection (SWIFI) to assess the behavior of permissioned blockchain systems in the presence of faulty smart contracts. We emulate the occurrence of general software faults and also blockchain-specific software faults (e.g., missing require on transaction sender) in smart contracts code and observe the impact on the overall system dependability in terms of reliability and integrity. We also analyze the effectiveness of formal verification and runtime protection mechanisms in detecting the injected faults. Results indicate that formal verification and runtime protections have to complement built-in platform checks to guarantee proper dependability of blockchain systems. The work presented in this article allows smart contract developers to become aware of possible faults in smart contracts and to understand the impact of their presence. It also provides valuable information for middleware developers to improve the overall fault tolerance of their systems.

Keywords