Location via proxy:   [ UP ]  
[Report a bug]   [Manage cookies]                
skip to main content
research-article

Ponzi scheme detection in smart contracts using the integration of deep learning and formal verification

Published: 27 December 2023 Publication History

Abstract

Blockchain smart contracts are codes that can execute and enforce rules for blockchain digital transactions. However, smart contracts may contain numerous subtle vulnerabilities, among which Ponzi vulnerabilities are notable. Existing Ponzi scheme contract detection approaches often rely on machine learning models trained on manually extracted features to achieve satisfactory classification results. Nonetheless, the code of a smart contract potentially harbours elusive semantics and characteristics, which compromises the precision and accuracy of vulnerability detection. Therefore, this paper proposes a method of converting operation codes into sequences to process data to avoid losing unnecessary important information, and uses a one‐dimensional convolutional neural network combined with formal verification. This method is named PZ‐C1DZ3(Ponzi‐Conv1D‐Z3) and is used for Ponzi scheme detection. Four types of machine learning models, namely Conv1D, Conv1D‐LSTM, Conv1D‐MLP, and Conv1D‐transformer, are employed for improvement and comparative validation experiments. Additionally, formal verification tool Z3 solver is utilized to conduct formal security verification on the final model, ensuring its safety. Experimental results demonstrate that the improved Conv1D model outperforms other existing models in terms of detection efficiency and accuracy while also meeting the requirements of formal security verification.

Graphical Abstract

A novel approach called PZ‐C1DZ3, which combines formal verification with one‐dimensional convolutional neural networks (CNNs) based on opcode for Ponzi scheme detection, is proposed. Four types of machine learning models, namely Conv1D, Conv1D‐LSTM, Conv1D‐MLP, and Conv1D‐ transformer, are employed for improvement and comparative validation experiments. Additionally, formal verification tool Z3 solver is utilized to conduct formal security verification on the final model, ensuring its safety.

References

[1]
Zheng, Z., Xie, S., Dai, H.N., Chen, X., Wang, H.: Blockchain challenges and opportunities: a survey. Int. J. Web Grid Serv. 14(4), 352–375 (2018)
[2]
Xu, L.D., Xu, E.L., Li, L.: Industry 4.0: state of the art and future trends. Int. J. Prod. Res. 56(8), 2941–2962 (2018)
[3]
Li, X., Jiang, P., Chen, T., Luo, X., Wen, Q.: A survey on the security of blockchain systems. Future Gener. Comput. Syst. 107, 841–853 (2020)
[4]
Tschorsch, F., Scheuermann, B.: Bitcoin and beyond: a technical survey on decentralized digital currencies. IEEE Commun. Surv. Tut. 18(3), 2084–2123 (2016)
[5]
Artzrouni, M.: The mathematics of Ponzi schemes. Math. Soc. Sci. 58(2), 190–201 (2009)
[6]
Bartoletti, M., Carta, S., Cimoli, T., Saia, R.: Dissecting Ponzi schemes on Ethereum: identification, analysis, and impact. Future Gener. Comput. Syst. 102, 259–277 (2020)
[7]
Chen, W., Zheng, Z., Cui, J., Ngai, E., Zheng, P., Zhou, Y.: Detecting Ponzi schemes on Ethereum: towards healthier blockchain technology. In: Proceedings of the 2018 World Wide Web Conference, pp. 1409–1418. ACM, New York (2018)
[8]
Chen, W., Zheng, Z., Ngai, E.C.H., Zheng, P., Zhou, Y.: Exploiting blockchain data to detect smart Ponzi schemes on Ethereum. IEEE Access 7, 37575–37586 (2019)
[9]
Shen, X., Jiang, S., Zhang, L.: Mining bytecode features of smart contracts to detect Ponzi scheme on blockchain. Comput. Model. Eng. Sci. 127(3), 1069–1085 (2021)
[10]
Chen, Y., Dai, H., Yu, X., Hu, W., Xie, Z., Tan, C.: Improving Ponzi scheme contract detection using multi‐channel TextCNN and transformer. Sensors 21(19), 6417 (2021)
[11]
Wang, L., Cheng, H., Zheng, Z., Yang, A., Zhu, X.: Ponzi scheme detection via oversampling‐based long short‐term memory for smart contracts. Knowl.‐Based Syst. 228, 107312 (2021)
[12]
Zhang, Y., Yu, W., Li, Z., Raza, S., Cao, H.: Detecting Ethereum Ponzi schemes based on improved LightGBM algorithm. IEEE Trans. Comput. Soc. Syst. 9(2), 624–637 (2021)
[13]
Jin, C., Jin, J., Zhou, J., Wu, J., Xuan, Q.: Heterogeneous feature augmentation for Ponzi detection in Ethereum. IEEE Trans. Circuits Syst. II: Express Briefs 69(9), 3919–3923 (2022)
[14]
Yu, S., Jin, J., Xie, Y., Shen, J., Xuan, Q.: Ponzi scheme detection in Ethereum transaction network. In: Blockchain and Trustworthy Systems: Third International Conference, BlockSys 2021, pp. 175–186. Springer, Cham (2021)
[15]
Bian, L., Zhang, L., Zhao, K., Wang, H., Gong, S.: Image‐based scam detection method using an attention capsule network. IEEE Access 9, 33654–33665 (2021)
[16]
Fan, S., Fu, S., Xu, H., Cheng, X.: AL‐SPSD: anti‐leakage smart Ponzi schemes detection in blockchain. Inf. Process. Manage. 58(4), 102587 (2021)
[17]
De Moura, L., Bjørner, N.: Z3: An Efficient SMT Solver. pp. 337–340. Springer, Berlin, Heidelberg (2008)
[18]
Liu, Z., Wang, H., Liu, J., Qin, Y., Peng, D.: Multitask learning based on lightweight 1DCNN for fault diagnosis of wheelset bearings. IEEE Trans. Instrum. Meas. 70, 1–11 (2020)
[19]
Van.Houdt, G., Mosquera, C., Nápoles, G.: A review on the long short‐term memory model. Artif. Intell. Rev. 53, 5929–5955 (2020)
[20]
Sherstinsky, A.: Fundamentals of recurrent neural network (RNN) and long short‐term memory (LSTM) network. Phys. D 404, 132306 (2020)
[21]
Chen, T., Xu, R., He, Y., Wang, X.: Improving sentiment analysis via sentence type classification using BiLSTM‐CRF and CNN. Expert Syst. Appl. 72, 221–230 (2017)
[22]
Heidari, A.A., Faris, H., Aljarah, I., Mirjalili, S.: An efficient hybrid multilayer perceptron neural network with grasshopper optimization. Soft Comput. 23, 7941–7958 (2019)
[23]
Zhou, H., Zhang, Y., Yang, L., Liu, Q., Yan, K., Du, Y.: Short‐term photovoltaic power forecasting based on long short term memory neural network and attention mechanism. IEEE Access 7, 78063–78074 (2019)
[24]
Han, K., Wang, Y., Chen, H., Chen, X., Guo, J., Liu, Z., et al.: A survey on vision transformer. IEEE Trans. Pattern Anal. Mach. Intell. 45(1), 87–110 (2022)
[25]
Afouras, T., Chung, J.S., Senior, A., Vinyals, O., Zisserman, A.: Deep audio‐visual speech recognition. IEEE Trans. Pattern Anal. Mach. Intell. 44(12), 8717–8727 (2018)
[26]
Singh, A., Parizi, R.M., Zhang, Q., Choo, K.K.R., Dehghantanha, A.: Blockchain smart contracts formalization: approaches and challenges to address vulnerabilities. Comput. Secur. 88, 101654 (2020)
[27]
Liu, J., Liu, Z.: A survey on security verification of blockchain smart contracts. IEEE Access 7, 77894–77904 (2019)
[28]
Bagui, S., Li, K.: Resampling imbalanced data for network intrusion detection datasets. J. Big Data 8(1), 1–41 (2021)

Recommendations

Comments

Information & Contributors

Information

Published In

cover image IET Blockchain
IET Blockchain  Volume 4, Issue 2
June 2024
121 pages
EISSN:2634-1573
DOI:10.1049/blc2.v4.2
Issue’s Table of Contents
This is an open access article under the terms of the Creative Commons Attribution License, which permits use, distribution and reproduction in any medium, provided the original work is properly cited.

Publisher

John Wiley & Sons, Inc.

United States

Publication History

Published: 27 December 2023

Author Tags

  1. artificial intelligence
  2. blockchains
  3. contracts

Qualifiers

  • Research-article

Contributors

Other Metrics

Bibliometrics & Citations

Bibliometrics

Article Metrics

  • 0
    Total Citations
  • 0
    Total Downloads
  • Downloads (Last 12 months)0
  • Downloads (Last 6 weeks)0
Reflects downloads up to 23 Sep 2024

Other Metrics

Citations

View Options

View options

Get Access

Login options

Media

Figures

Other

Tables

Share

Share

Share this Publication link

Share on social media