Ethereum has become one of the primary global platforms for cryptocurrency, playing an important role in promoting the diversification of the financial ecosystem. However, the relative lag in regulation has led to a proliferation of malicious activities in Ethereum, posing a serious threat to fund security. Existing regulatory methods usually detect malicious accounts through feature engineering or large-scale transaction graph mining. However, due to the immense scale of transaction data and malicious attacks, these methods suffer from inefficiency and low robustness during data processing and anomaly detection. In this regard, we propose an Ethereum Transaction Graph Compression method named TGC4Eth, which assists malicious account detection by lightweighting both features and topology of the transaction graph. At the feature level, we select transaction features based on their low importance to improve the robustness of the subsequent detection models against feature evasion attacks; at the topology level, we employ focusing and coarsening processes to compress the structure of the transaction graph, thereby improving both data processing and inference efficiency of detection models. Extensive experiments demonstrate that TGC4Eth significantly improves the computational efficiency of existing detection models while preserving the connectivity of the transaction graph. Furthermore, TGC4Eth enables existing detection models to maintain stable performance and exhibit high robustness against feature evasion attacks.
In decentralized systems, the quest for heightened security and integrity within blockchain networks becomes an issue. This survey investigates anomaly detection techniques in blockchain ecosystems through the lens of unsupervised learning, delving into the intricacies and going through the complex tapestry of abnormal behaviors by examining avant-garde algorithms to discern deviations from normal patterns. By seamlessly blending technological acumen with a discerning gaze, this survey offers a perspective on the symbiotic relationship between unsupervised learning and anomaly detection by reviewing this problem with a categorization of algorithms that are applied to a variety of problems in this field. We propose that the use of unsupervised algorithms in blockchain anomaly detection should be viewed not only as an implementation procedure but also as an integration procedure, where the merits of these algorithms can effectively be combined in ways determined by the problem at hand. In that sense, the main contribution of this paper is a thorough study of the interplay between various unsupervised learning algorithms and how this can be used in facing malicious activities and behaviors within public and private blockchain networks. The result is the definition of three categories, the characteristics of which are recognized in terms of the way the respective integration takes place. When implementing unsupervised learning, the structure of the data plays a pivotal role. Therefore, this paper also provides an in-depth presentation of the data structures commonly used in unsupervised learning-based blockchain anomaly detection. The above analysis is encircled by a presentation of the typical anomalies that have occurred so far along with a description of the general machine learning frameworks developed to deal with them. Finally, the paper spotlights challenges and directions that can serve as a comprehensive compendium for future research efforts.
Due to spectacular gains during periods of rapid price increase and unpredictably large drops, Bitcoin has become a popular emergent asset class over the past few years. In this paper, we are interested in predicting the crashes of Bitcoin market. To tackle this task, we propose a framework for deep learning time series classification based on contrastive learning. The proposed framework is evaluated against six machine learning (ML) and deep learning (DL) baseline models, and outperforms them by 15.8% in balanced accuracy. Thus, we conclude that the contrastive learning strategy significantly enhance the model’s ability of extracting informative representations, and our proposed framework performs well in predicting Bitcoin crashes.
Blockchain technology has rapidly emerged to mainstream attention, while its publicly accessible, heterogeneous, massive-volume, and temporal data are reminiscent of the complex dynamics encountered during the last decade of big data. Unlike any prior data source, blockchain datasets encompass multiple layers of interactions across real-world entities, e.g., human users, autonomous programs, and smart contracts. Furthermore, blockchain's integration with cryptocurrencies has introduced financial aspects of unprecedented scale and complexity such as decentralized finance, stablecoins, non-fungible tokens, and central bank digital currencies. These unique characteristics present both opportunities and challenges for machine learning on blockchain data. On one hand, we examine the state-of-the-art solutions, applications, and future directions associated with leveraging machine learning for blockchain data analysis critical for the improvement of blockchain technology such as e-crime detection and trends prediction. On the other hand, we shed light on the pivotal role of blockchain by providing vast datasets and tools that can catalyze the growth of the evolving machine learning ecosystem. This paper serves as a comprehensive resource for researchers, practitioners, and policymakers, offering a roadmap for navigating this dynamic and transformative field.
Yepeng Ding, Arthur Gervais, Roger Wattenhofer, Hiroyuki Satō
Decentralized finance (DeFi) is revolutionizing the traditional centralized finance paradigm with its attractive features such as high availability, transparency, and tamper-proofing. However, attacks targeting DeFi services have severely damaged the DeFi market, as evidenced by our investigation of 80 real-world DeFi incidents from 2017 to 2022. Existing methods, based on symbolic execution, model checking, semantic analysis, and fuzzing, fall short in identifying the most DeFi vulnerability types. To address the deficiency, we propose Context-Sensitive Concolic Verification (CSCV), a method of automating the DeFi vulnerability finding based on user-defined properties formulated in temporal logic. CSCV builds and optimizes contexts to guide verification processes that dynamically construct context-carrying transition systems in tandem with concolic executions. Furthermore, we demonstrate the effectiveness of CSCV through experiments on real-world DeFi services and qualitative comparison. The experiment results show that our CSCV prototype successfully detects 76.25% of the vulnerabilities from the investigated incidents with an average time of 253.06 seconds.
The rapid development of physical device-based data collection in emerging technology needs smart, secure, and intelligent transmission. Cyber physical systems compete with the requirement of intelligent transmission of data. In cyber physical systems, security is a very challenging task due to the heterogeneous connections of devices in real time. This paper proposes a novel methodology for cyber-attack finding in cyber physical systems. The proposed system employed a DNN-deep neural network for the categorization of normal and attack data. The employed deep neural network design for 4 hidden layers for the detection of anomalies. For the secured transmission, we employed the blockchain process in Ethereum. The process of Ethereum generates blocks of blockchain with headers and transmits data over the cyberworld to the physical world with the alteration of data. For the authentication of the projected algorithm tested on two real-time datasets, such as NSL-KDD15 and CIDDS_001. The working of proposed algorithm is very promising in compression of existing algorithms of deep learning like RNN-recurrent neural networks, DBN, and DNN.
Mohammad H. Hasan, Mohammad Shahriar Rahman, Helge Janicke, Iqbal H. Sarker
As the use of Blockchain for digital payments continues to rise in popularity, it also becomes susceptible to various malicious attacks. Successfully detecting anomalies within Blockchain transactions is essential for bolstering trust in digital payments. However, the task of anomaly detection in Blockchain transaction data is challenging due to the infrequent occurrence of illicit transactions. Although several studies have been conducted in the field, a limitation persists: the lack of explanations for the model's predictions. This study seeks to overcome this limitation by integrating eXplainable Artificial Intelligence (XAI) techniques and anomaly rules into tree-based ensemble classifiers for detecting anomalous Bitcoin transactions. The Shapley Additive exPlanation (SHAP) method is employed to measure the contribution of each feature, and it is compatible with ensemble models. Moreover, we present rules for interpreting whether a Bitcoin transaction is anomalous or not. Additionally, we have introduced an under-sampling algorithm named XGBCLUS, designed to balance anomalous and non-anomalous transaction data. This algorithm is compared against other commonly used under-sampling and over-sampling techniques. Finally, the outcomes of various tree-based single classifiers are compared with those of stacking and voting ensemble classifiers. Our experimental results demonstrate that: (i) XGBCLUS enhances TPR and ROC-AUC scores compared to state-of-the-art under-sampling and over-sampling techniques, and (ii) our proposed ensemble classifiers outperform traditional single tree-based machine learning classifiers in terms of accuracy, TPR, and FPR scores.
Financial anomalies must be detected in order for financial institutions and regulatory bodies to manage risks and avoid fraudulent behavior. Financial anomaly detection is the practice of identifying unexpected or irregular financial transactions or patterns that may indicate fraudulent behavior or errors. It is crucial in today's digital era to prevent fraud, limit financial losses, and maintain secure financial systems. Various types of financial anomalies, such as credit card fraud, money laundering, financial statement fraud, and cryptocurrency fraud, pose significant risks to individuals and organizations. This review critically evaluates a selected research article on the use of blockchain technology in conjunction with data mining techniques to detect financial anomalies. The paper employs the case study method to demonstrate how well the suggested integrated system works in spotting financial anomalies. This review evaluates the article's methodology and conclusions and discusses its implications for practice. The report claims that merging data mining methods with blockchain technology can increase the precision and effectiveness of financial anomaly identification. This research advances knowledge about how block-chain technology and data mining techniques can be used to find financial abnormalities while also offering suggestions for further study and use.
In MLaaS, DNN models are kept in a server operated by the service provider and inputs to the DNN models are provided by the clients. Such inputs are used to execute the DNN models and classification results are sent back to the client. In MLaaS, the DNN model owner does not reveal the DNN model parameters to the client. MLaaS there are a few trust problems: (a) The server may not be secure and an attacker may send manipulated classification results to the client. In the case of safety-critical systems using such classification in the decision-making process, an attacker may specifically manipulate the classification result to disrupt the operations of the safety-critical system, (b) The server may intentionally send wrong or random classification results without executing the DNN model to respond to a massive number of classification requests from the clients. In this paper, we investigate the problem of verifying DNN model execution by the service provider in an MLaaS paradigm. A proof of DNN model execution will prove that given an input, the DNN model is executed to generate the classification result by providing sequences of outputs of all functions used in the DNN model. As the service provider in MLaaS does not share the DNN model with the client, we need to verify DNN function outcomes without the knowledge of DNN function parameters. Hence zero-knowledge proof can be used for verifying DNN model execution. In this paper, we use Zero-Knowledge Succinct Non-interactive Arguments of Knowledge (zk-SNARKs) which reduces the size of proof and complexity of proof verification considerably. In particular, we use a quadratic arithmetic program-based zkSNARK for DNN model verification. Our main results in this paper are as follows: (a) We have developed a DNN model execution verification method using a QAP-based zkSNARK. (b) We prove that the verification protocol is correct and privacy-preserving. (c) We analyzed the cost of using such a verification protocol.
Verification of a deep neural network is required as large DNN models are used in machine learning as a service procedure where the server providing a classification service may be insecure and provide invalid classifications. A verification of deep neural networks in a machine learning as a service paradigm requires verification of function evaluation for all functions of a DNN model given a specific input where the service provider and the server do not want to reveal the DNN model to the client. In this paper, we investigate the privacy-preserving verification problem of the DNN model with zero-knowledge proofs. We have developed a KGZ polynomial commitment scheme based on zero-knowledge proof for such DNN verification. We present an efficient DNN verification using KGZ zero-knowledge proof. We have developed a batch-processing algorithm that can significantly reduce the number of function evaluation verifications. We also prove that a malicious server may not manipulate the proposed verification protocol.
KwangCheol Rim, Youngmin Yoon, S. Kim, Jeongin Kim
The identification and mitigation of anomaly data, characterized by deviations from normal patterns or singularities, stand as critical endeavors in modern technological landscapes, spanning domains such as Non-Fungible Token... | Find, read and cite all the research you need on Tech Science Press
Dongze Li, Kejia Zhang, Shiwei Li, Gang Du · 5 authors
As decentralized finance (DeFi) grows and decentralized exchanges (DEXs) expand, the security of Ethereum smart contracts and blockchain transactions is receiving increasing scholarly attention. The ERC20 token standard has facilitated the emergence of numerous honeypot contracts, which deceive traders by allowing token purchases but blocking withdrawals. This study proposes a lightweight honeypot contract detection system integrated into the go-Ethereum client (Geth). Unlike previous work, our detector does not rely on contract interaction records or source code provided by contract creators. Instead, our approach performs static data flow analysis on contract bytecode to identify honeypot mechanisms. By focusing exclusively on the control flow of the ERC20 Transfer method, our system achieves faster detection than full-contract analysis methods, with an average processing time of 9.74 milliseconds per contract. Experiments on both known honeypot contracts and real-world token contracts demonstrate the effectiveness of our approach in detecting malicious ERC20 contracts.
In the rapidly advancing domain of smart manufacturing, securing data integrity and preventing unauthorized access are critical challenges. This study introduces a novel approach that synergizes anomaly detection techniques with Zero-Knowledge Proofs (ZKPs) to fortify the security framework of smart manufacturing systems. Our methodology employs a combination of data preprocessing, including statistical imputation and data smoothing, alongside advanced anomaly detection using classification methods and neural networks, particularly focusing on deep learning architectures. The detected anomalies undergo verification through zk-SNARKs, a specialized ZKP scheme, ensuring a robust validation process without compromising data confidentiality. Our findings reveal a notable enhancement in the accuracy of anomaly detection, achieving detection rates of approximately 95% for temperature fluctuations and 90% for pressure irregularities, with a significant reduction in false positives. This performance is markedly superior to traditional methods and aligns closely with the highest efficacy rates reported in contemporary studies. Moreover, the utilization of ZKPs for anomaly verification demonstrated a 98% success rate, ensuring the secure and private verification of anomalies. The integration of anomaly detection with ZKPs presents a significant leap forward in addressing the security vulnerabilities inherent in smart manufacturing. This study not only showcases the effectiveness of our approach in enhancing data security and integrity but also sets a benchmark for future research in creating more resilient and trustworthy industrial operations.
Blockchain has emerged as a groundbreaking security technology, playing a vital role in various industries such as banking, the Internet of Things (IoT), healthcare, education, and voting. However, the widespread adoption of this technology has introduced certain vulnerabilities, particularly in the form of exploitation by malicious entities. While existing research primarily focuses on identifying anomalous actor behavior, there has been limited exploration of precisely identifying hostile actors within the Ethereum network. This study aims to uncover malevolent actors operating on the Ethereum network and categorize attacks based on their actions. To achieve this research goal, a new dataset was constructed by consolidating data on malicious actors involved in illicit Ethereum activities. Key features were extracted from this dataset using advanced feature selection techniques, including Principal Component Analysis (PCA), Information Gain, and Ridge Regression. Machine learning classifiers such as LGBM, XGBoost, Random Forest, Extra Tree, Bagging, and K-Nearest Neighbors were applied to identify and classify malicious actors effectively. The results, achieving an impressive accuracy rate of 98%, underscore the effectiveness of Information Gain when coupled with LGBM and XGBoost. Notably, XGBoost demonstrates efficiency by completing the analysis in a mere 13.72 seconds. In addition to identifying fraudulent activities, this research classifies them into distinct categories, enhancing blockchain security and addressing trust concerns. This study’s outcomes fortify the Ethereum network’s resilience and contribute to the broader discourse on bolstering reliability in blockchain systems.
The Internet of Healthcare Things (IoHT) is an emerging critical technology for managing patients’ health. They are prone to cybersecurity vulnerabilities because they are connected to the internet, primarily by wireless connections. This is a major concern, considering data privacy and security. Artificial intelligence (AI) models are excellent methods to detect and mitigate cybersecurity vulnerabilities. Since medical Information Technology (IT) is evolving and data privacy is a major concern with sensors generally, in healthcare IoT. The TON_IOT, Edge_IIoT, and UNSW-NB15 datasets were used in this study for assessment and implementation to solve the challenge using the chosen benchmark AI models with the integration of IPFS blockchain technology in order to decentralize and secure the data. Justifiable parameters were used to determine how efficient each technique is in predicting the best outcome. The results show the efficiency of the utilized models, particularly the Support Vector Machines (SVM). The TON_IoT dataset obtained 100% accuracy, the Edge_IIoT dataset obtained 98% accuracy, and the UNSW-NB15 dataset obtained 89% accuracy. The integrated blockchain technology in this model is applied for security purposes. Utilizing these techniques will proffer a secure and safe transmission of medical data. This study will generally provide important insight to other researchers in the healthcare field.
Shereen Ismail, Muhammad Nouman, Diana W. Dawoud, Hassan Reza
Cyber-attacks pose a significant challenge to the security of Internet of Things (IoT) sensor networks, necessitating the development of robust countermeasures tailored to their unique characteristics and limitations. Various prevention and detection techniques have been proposed to mitigate these attacks. In this paper, we propose an integrated security framework using Blockchain (BC) and Machine Learning (ML) to protect IoT sensor networks. The framework consists of two modules: a BC prevention module and a ML detection module. The BC prevention module has two lightweight mechanisms: identity management and trust management. Identity management employs a lightweight Smart Contract (SC) to manage the node registration and authentication, ensuring that unauthorized entities are prohibited from engaging in any tasks, while trust management uses a lightweight SC that is responsible for maintaining trust and credibility between sensor nodes throughout the network's lifetime and tracking historical node behaviors. Consensus and transaction validation are achieved through a Verifiable Byzantine Fault Tolerance (VBFT) mechanism to ensure network reliability and integrity. The ML detection module utilizes LightGBM algorithm to classify malicious nodes and notify the BC network if it must make decisions to mitigate their impacts. We investigate the performance of several off-the-shelf ML algorithms, including Logistic Regression, Complement Naive Bayes, Nearest Centroid, and Stacking, using the WSN-DS dataset. LightGBM is selected following a detailed comparative analysis conducted using accuracy, precision, recall, F1-score, processing time, training time, prediction time, computational complexity, and Matthews Correlation Coefficient (MCC) evaluation metrics.
Leandro Cunha, Miguel A. Brito, Domingos F. Oliveira, Ana Paula Martins
The cryptocurrency market has grown significantly, and this quick growth has given rise to scams. It is necessary to put fraud detection mechanisms in place. The challenge of inadequate labeling is addressed in this work, which is a barrier to the training of high-performance supervised classifiers. It aims to lessen the necessity for laborious and time-consuming manual labeling. Some unlabeled data points have labels that are more pertinent and informative for the supervised model to learn from. The viability of utilizing unsupervised anomaly detection algorithms and active learning strategies to build an iterative process of acquiring labeled transactions in a cold start scenario, where there are no initial-labeled transactions, is being investigated. Investigating anomaly detection capabilities for a subset of data that maximizes supervised models’ learning potential is the goal. The anomaly detection algorithms under performed, according to the results. The findings underscore the need that anomaly detection algorithms be reserved for situations involving cold starts. As a result, using active learning techniques would produce better outcomes and supervised machine learning model performance.
The Internet of Things (IoT) is the most abundant technology in the fields of manufacturing, automation, transportation, robotics, and agriculture, utilizing the IoT's sensors-sensing capability. It plays a vital role in digital transformation and smart revolutions in critical infrastructure environments. However, handling heterogeneous data from different IoT devices is challenging from the perspective of security and privacy issues. The attacker targets the sensor communication between two IoT devices to jeopardize the regular operations of IoT-based critical infrastructure. In this paper, we propose an artificial intelligence (AI) and blockchain-driven secure data dissemination architecture to deal with critical infrastructure security and privacy issues. First, we reduced dimensionality using principal component analysis (PCA) and explainable AI (XAI) approaches. Furthermore, we applied different AI classifiers such as random forest (RF), decision tree (DT), support vector machine (SVM), perceptron, and Gaussian Naive Bayes (GaussianNB) that classify the data, i.e., malicious or non-malicious. Furthermore, we employ an interplanetary file system (IPFS)-driven blockchain network that offers security to the non-malicious data. In addition, to strengthen the security of AI classifiers, we analyze data poisoning attacks on the dataset that manipulate sensitive data and mislead the classifier, resulting in inaccurate results from the classifiers. To overcome this issue, we provide an anomaly detection approach that identifies malicious instances and removes the poisoned data from the dataset. The proposed architecture is evaluated using performance evaluation metrics such as accuracy, precision, recall, F1 score, and receiver operating characteristic curve (ROC curve). The findings show that the RF classifier transcends other AI classifiers in terms of accuracy, i.e., 98.46%.
Federated Learning (FL) systems are susceptible to adversarial attacks, such as model poisoning attacks and backdoor attacks. Existing defense mechanisms face critical limitations in deployments, such as relying on impractical assumptions (e.g., adversaries acknowledging the presence of attacks before attacking) or undermining accuracy in model training, even in benign scenarios. To address these challenges, we propose CustodianFL, a two-staged anomaly detection method specifically designed for FL deployments. In the first stage, it flags suspicious client activities. In the second stage that is activated only when needed, it further examines these candidates using Three-Sigma Rule to identify and exclude truly malicious local models from FL training. To ensure integrity and transparency within the FL system, CustodianFL integrates zero-knowledge proofs, enabling clients to cryptographically verify the server's detection process without relying on the server's goodwill. CustodianFL operates without unrealistic assumptions and avoids interfering with FL training in attack-free scenarios. It bridges the gap between theoretical advances in FL security and the practical demands of real FL systems. Experimental results demonstrate that CustodianFL consistently delivers performance comparable to benign cases, highlighting its effectiveness in identifying and eliminating malicious models with high accuracy.
The recent surge in the attention garnered by blockchain technology, an immutable ledger enabling decentralized transactions, is noteworthy.However, the security of blockchain remains susceptible to various attacks, including distributed denial-of-service (DDoS) attacks, which have increasingly targeted Bitcoin services.In response, deep learning algorithms have emerged as a potent solution to complex problems within the realm of information science.This study proposes a novel approach, utilizing these algorithms within hybrid frameworks, to address intricate cybersecurity issues.The methodologies were implemented and fine-tuned within a Python environment.Initially, a technique known as data augmentation was applied to an experimental domain aimed at verifying efficiency and boosting precision in complex datasets.Data augmentation, a method of generating new data points from existing ones, artificially enhances the volume of data.A Conditional Table Generative Adversarial Network (CTGAN) approach was adopted for the creation of tabular synthetic data.The utilization of synthetic data was found to enhance the model's performance and robustness compared to the exclusive use of original data.Subsequently, a binary classification hybrid deep learning model, incorporating Recurrent Neural Network (RNN) and Long Short-Term Memory (LSTM) algorithms, was proposed for the detection of DDoS attacks within cryptocurrency networks.The proposed model was then validated using actual instances of DDoS attacks within the Bitcoin service dataset.The validation process incorporated a test set comprising 20% of the augmented data.Evidently, the proposed model outperformed standard deep learning implementations, achieving an impressive accuracy of approximately 95.84%.This study, therefore, presents a promising approach to mitigating DDoS attacks within the Bitcoin ecosystem.
Beibei Han, Yingmei Wei, Qingyong Wang, Francesco Maria De Collibus · 5 authors
Abstract In recent years, a surge of criminal activities with cross-cryptocurrency trades have emerged in Ethereum, the second-largest public blockchain platform. Most of the existing anomaly detection methods utilize the traditional machine learning with feature engineering or graph representation learning technique to capture the information in transaction network. However, these methods either ignore the timestamp information and the transaction flow direction information in transaction network or only consider single transaction network, the cross-cryptocurrency trading patterns in Ethereum are usually ignored. In this paper, we introduce a Multi-layer Temporal Transaction Anomaly Detection (MT $$^2$$ <mml:math xmlns:mml="http://www.w3.org/1998/Math/MathML"> <mml:msup> <mml:mrow/> <mml:mn>2</mml:mn> </mml:msup> </mml:math> AD) model in Ethereum network with graph neural network. Specifically, for a given Ethereum token transaction network, we first extract its initial features including the structure subgraph and edge’s feature. Then, we model the temporal information in subgraph as a series of network snapshots according to the timestamp on each edge and time window. To capture the cross-cryptocurrency trading patterns, we combine the snapshots from multiple token transactions at a given timestamp, and we consider it as a new combined graph. We further use the graph convolution encoder with attention mechanism and pooling operation on this new graph to obtain the graph-level embedding, and we transform the anomaly detection on dynamic multi-layer Ethereum transaction networks as a graph classification task with these graph-level embeddings. MT $$^2$$ <mml:math xmlns:mml="http://www.w3.org/1998/Math/MathML"> <mml:msup> <mml:mrow/> <mml:mn>2</mml:mn> </mml:msup> </mml:math> AD can integrate the transaction structure feature, edge’s feature and cross-cryptocurrency trading patterns into a framework to perform the anomaly detection with graph neural networks. Experiments on three real-world multi-layer transaction networks show that the proposed MT $$^2$$ <mml:math xmlns:mml="http://www.w3.org/1998/Math/MathML"> <mml:msup> <mml:mrow/> <mml:mn>2</mml:mn> </mml:msup> </mml:math> AD (0.8789 Precision, 0.9375 Recall, 0.4987 FbMacro and 0.9351 FbWeighted) can achieve the best performance on most evaluation metrics in comparison with some competing approaches, and the effectiveness in consideration of multiple tokens is also demonstrated.
Blockchain is a growing technology nowadays. This technology is often associated with the terms "distributed" and "decentralized" technology that does not require a central authority (CA) to control certain processes Therefore, the acceptance of this technology is increasing with the introduction of some of the latest applications in the world of decentralized financial (DeFi), non-fungible tokens (NFT), and metaverse. Previously, blockchain technology was widely adopted in several popular domains, such as digital government [2], health [3], business management [4], and smart cities The understanding of blockchain is linked to several main functions: public key, private key, hash value, and peer-to-peer (P2P) network.
Abstract With the high-speed development of decentralized applications, account-based blockchain platforms have become a hotbed of various financial scams and hacks due to their anonymity and high financial value. Financial security has become a top priority with the sustainable development of blockchain-based platforms because of an increasing number of cyber attacks, which have resulted in a huge loss of crypto assets in recent years. Therefore, it is imperative to study the real-time detection of cyber attacks to facilitate effective supervision and regulation. To this end, this paper proposes the weighted and extended isolation forest algorithms and designs a novel framework for the real-time detection of cyber-attack transactions by thoroughly studying and summarizing real-world examples. Furthermore, this study develops a new detection approach for locating the compromised address of a cyber attack to resolve the data scarcity of hack addresses and reduce time consumption. Moreover, three experiments are carried out not only to apply on different types of cyber attacks but also to compare the proposed approach with the widely used existing methods. The results demonstrate the high efficiency and generality of the proposed approach. Finally, the lower time consumption and robustness of our method were validated through additional experiments. In conclusion, the proposed blockchain-oriented approach in this study can handle real-time detection of cyber attacks and has significant scope for applications.