Graph Neural Networks-Based Detection of Access Control and External Call Vulnerabilities in Smart Contracts
Keywords:
Blockchain, solidity, security risks, graph attention network, unified graph object, edge-awareAbstract
The growing adoption of smart contracts, the self-executing digital agreements stored on blockchain networks, has resulted from the increasing adoption of blockchain technology. While these contracts offer automation and transparency, they also introduce significant security risks, with vulnerabilities often resulting in substantial financial losses. Existing tools, such as Slither, are widely used for vulnerability detection. However, their reliance on expert-defined rules and static analysis patterns limits their effectiveness, resulting in yielding false positives and failing to identify complex or evolving attack patterns. This research proposes an automated vulnerability detection model tailored for Solidity smart contracts, leveraging Graph Neural Networks (GNNs) with a specific focus on the Graph Attention Network (GAT). The model constructs a unified graph structure by integrating Abstract Syntax Tree and Control Flow Graph, preserving semantic edge types and incorporating a custom edge-aware attention mechanism to capture rich structural and relational information. The model is trained on a labelled dataset of Solidity contracts to detect two critical vulnerabilities: access control and unchecked external calls. Experimental evaluation demonstrates that the proposed GATv2EdgeAwareNet achieves an accuracy of 78.98%, along with strong performance in precision (79.14%), F1 score (78.99%) and recall (78.98%). Compared to Slither, it delivers higher accuracy, precision and F1 score, with only a marginal trade-off in recall. Slither, despite achieving the highest recall (92.4%), exhibits inconsistent precision and elevated false positive rates. These findings show the potential of graph-based deep learning approaches as scalable, adaptive and accurate solutions for detecting vulnerabilities in smart contracts amidst evolving blockchain security threats.
Downloads
Published
Issue
Section
License
Copyright (c) 2026 Platform: A Journal of Science and Technology

This work is licensed under a Creative Commons Attribution 4.0 International License.






