Work

CodeBERT-Based Embeddings for Detecting Vulnerable Smart Contracts

Year: 2025
Type: conference-paper
Abstract: Smart contracts are a key part of blockchain applications, and attackers can exploit them to manipulate contract behaviour or steal assets. Smart contracts often contain security vulnerabilities, either accidentally introduced by developers or due to flawed business logic. In this paper, we focus on finding an optimal Machine Learning based framework for detecting vulnerable smart contracts by analysing the smart contracts as embedding vectors. CodeBERT, a pre-trained transformer model, is used for feature extraction in the proposed framework. The framework has shown approximately 97% accuracy in detecting smart contracts that contain various vulnerabilities. Additionally, the research explores the performance of CodeBERT variants for this task. The results of the experiments have proven the favourability of this framework in detecting vulnerable smart contracts.
Language: English
Open Access status: green
OpenAlex ID: W4414198440
FWCI: 4.665
Cites: 28
Cited by: 4
Related to: