ERC20: Correctness via Linearizability and Interference Freedom of the Underlying Smart Contract

Rudrapatna K. Shyamasundar

2023

Abstract

ERC20 is a standard for the creation of a specific type of tokens called ERC20 tokens, one of the most widely adopted tokens on Ethereum. ERC20 tokens are transferred through dedicated transactions among Ethereum addresses, and managed by smart contracts. Nondeterministic behaviour has been observed on the smart contracts that manage ERC20 tokens resulting in owners losing significant amounts while using it. In this paper, we first discuss issues of nondeterministic behaviour in the ERC20 smart contract, and the standard general remedies that have been proposed in the literature to avoid nondeterministic behaviour in ERC20. Then, through the notion of linearizability, it is shown that as ERC20 permits unbounded concurrency, the linearizability of the ERC20 smart contract is undecidable - thus, demonstrating the subtle complexity of ERC20 and the strong synchronization requirements of ERC20. Finally, treating ERC20 smart contract as a set of asynchronous interacting processes executing on a blockchain, we describe an approach that is common in classical programming language specification, and show how a set of constraints on the traces of ERC20 executions based on interference freedom property for concurrent execution on the blockchain overcomes the nondeterministic behaviour; we shall further sketch how such an execution can be implemented in Solidity. Furthermore, we discuss how the two approaches of linerarization and interference freedom mutually benefit each other and assist in arriving at constraints that leads to wait-free implementation of smart contracts.

Download


Paper Citation


in Harvard Style

K. Shyamasundar R. (2023). ERC20: Correctness via Linearizability and Interference Freedom of the Underlying Smart Contract. In Proceedings of the 20th International Conference on Security and Cryptography - Volume 1: SECRYPT; ISBN 978-989-758-666-8, SciTePress, pages 557-566. DOI: 10.5220/0012145800003555


in Bibtex Style

@conference{secrypt23,
author={Rudrapatna K. Shyamasundar},
title={ERC20: Correctness via Linearizability and Interference Freedom of the Underlying Smart Contract},
booktitle={Proceedings of the 20th International Conference on Security and Cryptography - Volume 1: SECRYPT},
year={2023},
pages={557-566},
publisher={SciTePress},
organization={INSTICC},
doi={10.5220/0012145800003555},
isbn={978-989-758-666-8},
}


in EndNote Style

TY - CONF

JO - Proceedings of the 20th International Conference on Security and Cryptography - Volume 1: SECRYPT
TI - ERC20: Correctness via Linearizability and Interference Freedom of the Underlying Smart Contract
SN - 978-989-758-666-8
AU - K. Shyamasundar R.
PY - 2023
SP - 557
EP - 566
DO - 10.5220/0012145800003555
PB - SciTePress