Precise Static Identification of Ethereum Storage Variables (Extended Version)

Fuente: arXiv
Saved in:
Bibliographic Details
Main Authors: Lagouvardos, Sifis, Bollanos, Yannis, Debono, Michael, Grech, Neville, Smaragdakis, Yannis
Format: Preprint
Published: 2025
Subjects:
Online Access:
Tags: Add Tag
No Tags, Be the first to tag this record!
_version_ 1866908677992087552
author Lagouvardos, Sifis
Bollanos, Yannis
Debono, Michael
Grech, Neville
Smaragdakis, Yannis
author_facet Lagouvardos, Sifis
Bollanos, Yannis
Debono, Michael
Grech, Neville
Smaragdakis, Yannis
contents Smart contracts are small programs that run autonomously on the blockchain, using it as their persistent memory. The predominant platform for smart contracts is the Ethereum VM (EVM). In EVM smart contracts, a problem with significant applications is to identify data structures (in blockchain state, a.k.a. "storage"), given only the deployed smart contract code. The problem has been highly challenging and has often been considered nearly impossible to address satisfactorily. (For reference, the latest state-of-the-art research tool fails to recover nearly all complex data structures and scales to under 50% of contracts.) Much of the complication is that the main on-chain data structures (mappings and arrays) have their locations derived dynamically through code execution. We propose sophisticated static analysis techniques to solve the identification of on-chain data structures with extremely high fidelity and completeness. Our analysis scales nearly universally and recovers deep data structures. Our techniques are able to identify the exact types of data structures with 98.6% precision and at least 92.6% recall, compared to a state-of-the-art tool managing 80.8% and 68.2% respectively. Strikingly, the analysis is often more complete than the storage description that the compiler itself produces, with full access to the source code.
format Preprint
id arxiv_https___arxiv_org_abs_2503_20690
institution arXiv
publishDate 2025
record_format arxiv
spellingShingle Precise Static Identification of Ethereum Storage Variables (Extended Version)
Lagouvardos, Sifis
Bollanos, Yannis
Debono, Michael
Grech, Neville
Smaragdakis, Yannis
Programming Languages
Smart contracts are small programs that run autonomously on the blockchain, using it as their persistent memory. The predominant platform for smart contracts is the Ethereum VM (EVM). In EVM smart contracts, a problem with significant applications is to identify data structures (in blockchain state, a.k.a. "storage"), given only the deployed smart contract code. The problem has been highly challenging and has often been considered nearly impossible to address satisfactorily. (For reference, the latest state-of-the-art research tool fails to recover nearly all complex data structures and scales to under 50% of contracts.) Much of the complication is that the main on-chain data structures (mappings and arrays) have their locations derived dynamically through code execution. We propose sophisticated static analysis techniques to solve the identification of on-chain data structures with extremely high fidelity and completeness. Our analysis scales nearly universally and recovers deep data structures. Our techniques are able to identify the exact types of data structures with 98.6% precision and at least 92.6% recall, compared to a state-of-the-art tool managing 80.8% and 68.2% respectively. Strikingly, the analysis is often more complete than the storage description that the compiler itself produces, with full access to the source code.
title Precise Static Identification of Ethereum Storage Variables (Extended Version)
topic Programming Languages
url https://arxiv.org/abs/2503.20690