Edge node abnormal behavior detection and positioning method suitable for task unloading scene
By introducing dynamic grouping policies and reputation management mechanisms in the multi-edge node task offload scenario, the problem of inaccurate verification of honesty at edge nodes is solved, and the rapid identification and positioning of dishonest nodes is achieved, the security and reliability of the system are improved, and the efficiency of resource usage is optimized.
Patent Information
- Application Number
- CN202411925513.3
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-12-25
- Publication Date
- 2025-03-25
- Estimated Expiration
- 2044-12-25
AI Technical Summary
In multi-edge node task offload scenarios, the prior art cannot accurately verify the honesty of edge nodes, resulting in malicious nodes that may provide incorrect calculation results, affecting the security and reliability of the system.
By introducing dynamic grouping policies and reputation management mechanisms of edge nodes, each edge node is required to register a true identity with the cloud and pay an honest margin, implement verification of intermediate results and verification of replication mechanisms, comprehensive verification results determine the payment of service compensation or withholding margin, and update the reputation value of edge nodes based on the verification results.
It significantly improves the supervision efficiency and communication collaboration capabilities of nodes in the same area, quickly identify and locate dishonest edge nodes, prevent malicious behavior, improves the security and reliability of the system, reduces the overhead of system resources, and improves overall operational efficiency.
Smart Images

Figure CN119696915A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the field of computing technology, and in particular to a network service scenario in edge computing task offloading, and specifically to an edge node abnormal behavior detection and positioning method suitable for task offloading scenarios. Background Art
[0002] In the new era of the Internet of Everything, the number of mobile smart terminals and IoT devices has increased dramatically, bringing huge challenges to network bandwidth and service quality. As the core strategy of edge computing, task offloading technology has shown extensive and far-reaching application potential. In the edge layer composed of multiple edge nodes, the collaborative work of edge nodes (i.e., edge-to-edge collaboration) has become the key to the effectiveness of this technology. For example, in the application of the Internet of Vehicles, this technology enables vehicles to transfer computing-intensive tasks such as high-definition map rendering and road condition analysis to edge nodes for collaborative processing, which reduces the computing burden on the vehicle, reduces processing delays, and improves driving safety and efficiency. In addition, in the computing power network, the task offloading strategy intelligently allocates computing tasks to the most suitable computing power nodes, improves resource utilization, reduces costs, and achieves rapid response and efficient processing. In addition, task offloading is also widely used in telemedicine, intelligent manufacturing, smart cities, virtual reality (VR) and augmented reality (AR) and other fields. It can be seen that task offloading technology not only responds to data challenges, but also supports the development of the Internet of Vehicles, computing power networks and multiple emerging fields through the collaborative work of edge nodes.
[0003] For end users, the computing tasks they face are becoming more and more complex, and are often limited by their own computing and storage capabilities. To solve this problem, task offloading is a feasible solution in edge computing, that is, the terminals send their computing tasks and raw data to the edge layer for processing, and then use the results returned from the edge layer to continue subsequent work.
[0004] Edge systems are usually built by one party (such as the cloud) as a management center to allocate tasks and charge fees. On the one hand, the edge layer consists of edge infrastructure provided by different types of third parties, devices equipped with third-party software and hardware, and personal devices. On the other hand, nodes are usually heterogeneous and widely deployed in different geographical locations to provide close-range services to end users. This enables managers to monitor, configure, and maintain nodes in the same area more efficiently. Since edge nodes need to collaborate to meet complex computing tasks, geographical location grouping makes it easier to achieve communication and collaboration between nodes, thereby improving the overall efficiency of the service. In addition, the resources of edge nodes are limited, which means that their processing power is also limited. Therefore, the services provided by edge nodes may be incorrect, that is, tampering with the output results of computing tasks will generate erroneous data and cause system failures.
[0005] The intervention of third-party edge nodes brings security challenges to multi-edge node task offloading, that is, malicious edge nodes provide incorrect calculation results in the service due to their own interests or vulnerability to attacks, resulting in the inability to execute subsequent tasks on the terminal. The reputation of edge nodes is currently evaluated based on the historical service quality of edge nodes, but edge nodes are not necessarily honest. At the same time, a method of using reputation to verify results has been proposed, that is, if one party actively responds to the outsourcing request of the other party and provides correct results, then the party will gain a higher reputation, so that its request will be processed first. However, this method faces a serious flaw: it does not take into account that the tasks processed by different edge nodes will have dependencies, that is, the edge nodes are collaborative, and edge nodes with high reputations may also have bad intentions or be attacked, and may not necessarily strictly output correct results in the future. Summary of the invention
[0006] The present invention aims to solve the technical problem that the credibility verification of edge nodes is not accurate enough in multi-edge node task offloading, and provides an edge node abnormal behavior detection and positioning method applicable to the task offloading scenario.
[0007] The present invention is implemented by adopting the following technical solution: a method for detecting and locating abnormal behavior of edge nodes applicable to task offloading scenarios, comprising the following steps: 1) Each edge node that enters a system with task offloading requirements is required to register its real identity with the cloud and pay an honesty deposit; the system includes smart terminals and the cloud; 2) The edge nodes entering the system are grouped according to their geographical locations. A leader is selected in each group. After the leader receives the task offloaded from the terminal to the edge layer composed of multiple edge nodes and issues the task to the edge nodes in its group, the edge nodes in the group work together to complete the task. When completing the task, each edge node is required to be responsible for the correctness of the intermediate results when sharing them with other edge nodes. That is, before its subsequent edge node uses the intermediate results, it must first verify the accuracy of the intermediate results and send the verification results to the cloud. 3) When each edge node completes a task in collaboration with other edge nodes, it also needs to verify the accuracy of the tasks completed by other edge nodes. That is, after the original data and computing tasks are unloaded to a certain edge node using the replication mechanism, the same original data and computing tasks will be unloaded to another edge node using the replication mechanism. The replication mechanism will merge the test data into the original data of each task. By comparing the results of a certain edge node completing a task with those of another edge node, the accuracy of the task completed by a certain edge node can be verified, and the verification results will be sent to the cloud. 4) The cloud integrates the verification results in steps 2) and 3) to decide whether to pay service fees to the edge nodes that participated in the collaborative task or to punish them by withholding their honesty deposits; if an error is found in the task result of an edge node, its honesty deposit will be awarded to the edge node that discovered the error; 5) The latest verification result in step 4) is used to update the reputation value of the corresponding edge node; the reputation value refers to the accuracy of a certain edge node after completing previous tasks, which is determined by the verification result. The higher the reputation value, the more accurate times the edge node has completed tasks; 6) After an unloading task is completed, all edge nodes entering the system are divided into good groups and bad groups according to their reputation values, and a new leader is selected for the good group, and the next unloading task is completed according to steps 2) to 5). If the number of tasks is too large and the bad group is also unloaded, then the bad group must also select a leader after completing the task according to steps 2) to 5).
[0008] Furthermore, in step 2), each group selects a leader randomly in the first round of election; the subsequent leader election adopts the RRaft mechanism; The first round of group elections leaders: There are three states for edge nodes: leader, follower, and candidate. In the first round of leader election, all edge nodes are initially in the follower state. Each edge node has an election timeout timer, and each edge node has a different timer (randomly generated by the algorithm or set according to your own needs and environmental conditions); this timer will be started at the beginning of the Raft algorithm or when the follower cannot receive the heartbeat from the leader (the leader is down); Follower conversion to candidate: When a follower's election timeout expires, if it has not received a heartbeat from the leader, it will consider itself the only edge node that can become the leader and convert its status to candidate; the candidate increases its term number by 1 and broadcasts a voting request; Candidate request vote: The candidate sends a request vote to all other edge nodes entering the system, requesting them to vote for themselves. The edge node that receives the request vote decides whether to vote for the candidate that issued the request according to the following rules: (1) If the term number of the candidate making the request is greater than or equal to the term number of the edge node receiving the request; (2) Each edge node can only vote for one candidate during the same term; The RRaft mechanism election is as follows: Including the initial election, each group has only one leader, and the rest are followers. When the leader fails (leader crashes) or the group cluster starts, the leaderless followers become candidates and initiate an election. Candidates send voting requests to other edge nodes in the group. Each edge node can only cast one vote per term for the candidate with the largest term number and the greatest reputation. The candidate who receives more than half of the votes becomes the new leader. If no candidate receives more than half of the votes, the election times out, and the candidate becomes a follower, increases the term number, and reopens the election. The term is used to identify the ruling period of the leader, and the term number will be increased each time a new leader is elected. Timeout means that after a candidate initiates a voting request, if it does not receive a voting response from the majority of nodes within a certain period of time, a timeout will occur. After the timeout, the candidate will give up the current election and return to the follower state. After the leader is successfully elected, it will send a broadcast message to the followers and issue tasks to maintain its leadership position. When the follower receives the leader's message, it will reset the timer, indicating the beginning of a term, and remain in the follower state and listen to instructions; if the follower does not receive a message from the leader within the set time, the leader is considered invalid, the follower increases the term number and becomes a candidate; while waiting for the voting results, the candidate may receive broadcasts from other edge nodes. If the term number in the broadcast is higher than or equal to its own and the reputation is not less than its own, the legitimacy of the edge node leader is recognized, the candidate gives up the candidate state and becomes a follower; if the received term number is lower than its own or no broadcast is received, it continues to maintain the candidate state and broadcasts the election request.
[0009] Furthermore, the RRaft mechanism election also includes: followers vote on a "first come, first served" basis to ensure that at most one candidate is elected leader per term: when a follower receives voting request messages from multiple candidates, it decides who to vote for based on the order in which the messages arrive, and the follower will vote for the first request that arrives and has a higher reputation than itself, while subsequent requests will be rejected (the candidate's voting request message is broadcast to all other nodes in the cluster); that is, the one with the highest reputation during the same term becomes the new leader; the new leader announces its leadership through broadcasting, blocks the new election process, and then begins to perform its duties and receive tasks, and sends the tasks to followers for collaborative processing.
[0010] Furthermore, in step 2), when the edge nodes are initially grouped, they are divided by geographical location (according to the distance from the task); when the good group and the bad group are subsequently divided (i.e. after the first task), they are divided by the reputation value of each edge node, that is, the top 50% of the reputation value is divided into the good group, and the bottom 50% is divided into the bad group.
[0011] Furthermore, in step 5), the reputation value of a certain edge node is associated with its replication frequency, that is, the higher the reputation value, the lower the frequency of the edge node being verified by other edge nodes.
[0012] Technical effect of the present invention: The method for detecting and locating abnormal behaviors of multiple edge nodes based on the Raft protocol and reputation (RRaft) proposed in the present invention significantly improves the supervision efficiency and communication cooperation capabilities of nodes in the same area by introducing a dynamic grouping strategy for edge nodes. The invention not only implements a dual grouping mechanism based on geographic location and reputation value, and optimizes the task offloading process, but also quickly identifies and locates dishonest edge nodes through strict reputation management and economic incentive mechanisms, effectively preventing malicious behaviors such as collusion attacks, improving the security and reliability of the system, and providing a strong guarantee for the safe operation of the edge computing environment. In addition, the invention uses the strategy of reducing verification overhead by the credibility of edge nodes, further reducing the overhead of system resources and improving the overall operating efficiency. BRIEF DESCRIPTION OF THE DRAWINGS
[0013] Figure 1 Flowchart for locating abnormal nodes during task offloading with the collaboration of multiple edge nodes in a group.
[0014] Figure 2 Schematic diagram of the replication mechanism in the task offloading scenario. DETAILED DESCRIPTION
[0015] The present invention proposes an innovative solution that combines the Raft protocol with the reputation mechanism (Reputation-Raft, RRaft). This solution aims to improve the maintenance efficiency of nodes in the region, promote communication and collaboration between nodes, and accurately identify potential malicious behaviors through an efficient node management strategy. First, the present invention adopts a dynamic grouping strategy for edge nodes to optimize node management. In the initial grouping stage, edge nodes are divided according to geographical locations, and each group uses the Raft algorithm to elect a leader, who is responsible for receiving and assigning tasks from terminals to followers in the group. This strategy ensures the efficiency of task allocation and the proximity of geographical locations, which is conducive to reducing communication delays. Subsequently, after the node reputation value is updated, the present invention introduces a dynamic grouping mechanism based on reputation. Specifically, according to the reputation value, the edge nodes are divided into a "good" group (the first 50%) and a "bad" group (the last 50%), and a new round of leader elections is continued according to the RRaft mechanism. This mechanism not only strengthens the competition and cooperation between nodes, but also encourages nodes to maintain honest behavior through the incentive and punishment effects of reputation.
[0016] In the process of task unloading, the present invention follows the principle of proximity in the first round, and gives priority to groups with high reputation values in the second round to improve the reliability and efficiency of task execution. At the same time, considering the dependency of tasks, the present invention requires edge nodes to be responsible for the correctness of intermediate results when sharing them, and ensures the accuracy of the results through a verification mechanism. Once dishonest behavior is found, the node involved will be punished immediately and its reputation value will be reduced. In addition, in order to prevent dishonest nodes from destroying the system through collusion and other attack methods, the present invention also introduces an economic incentive mechanism. Edge nodes newly added to the system need to register their real identities to the management center and pay an honesty deposit (referred to as a deposit) when they first access. This measure not only enhances the sense of responsibility of the nodes, but also reduces the economic burden of the edge nodes by dynamically managing the deposit. Finally, in order to reduce the verification overhead, the present invention proposes a strategy to reduce the number of verifications by using the reputation of edge nodes. By combining test data and replication mechanisms for joint verification, the verification efficiency is improved while ensuring the accuracy of the results.
[0017] The process of the present invention is divided into two parts. The specific implementation mode of the present invention is further described in detail below in conjunction with the accompanying drawings.
[0018] 1. First, the RRaft mechanism is explained.
[0019] In the RRaft mechanism, nodes usually belong to one of three states: leader, follower, and candidate. Under normal circumstances, there is only one leader and the rest are followers. When the leader fails (that is, the leader crashes or a task fails) or the cluster starts, the leaderless followers become candidates and initiate an election. Candidates send voting requests to other nodes in the cluster. Each node can only cast one vote per term for the candidate with the largest term number and the greatest reputation. The candidate who receives more than half of the votes becomes the new leader. If no candidate receives more than half of the votes, the election times out, the candidate becomes a follower, the term number is increased, and the election is reopened.
[0020] After the leader is successfully elected, it will send a broadcast message to the followers and issue tasks to maintain the leadership position. When the follower receives the leader's message, the timer will be reset, and it will remain in the following state and listen to instructions. If the follower does not receive a message from the leader within the set time, the leader is considered invalid, the term number is increased, and it becomes a candidate. While waiting for the voting results, the candidate may receive broadcasts from other nodes. If the term number in the broadcast is higher than or equal to its own and the reputation is not less than its own, it recognizes the legitimacy of the leader, abandons the candidate state, and becomes a follower. If the received term number is lower than its own or no broadcast is received, it will continue to remain in the candidate state and broadcast the election request.
[0021] Followers vote on a first-come, first-served basis to ensure that at most one candidate is elected leader per term. To avoid infinite election cycles, the candidate with the highest reputation in the same term becomes the new leader. The new leader announces its leadership through broadcasting, preventing the new election process, and then begins to perform its duties and receive tasks, sending them to followers for collaborative processing.
[0022] The leader election process of the RRaft mechanism is shown in Algorithm 1.
[0023] Algorithm 1 Leader election process of RRaft mechanism Input: Information of edge nodes Output: Leader 1. Elect the initial leader based on the timer and reputation; 2.FOR followers receive leader broadcasts and subtasks; 3.IF the follower does not receive the broadcast message from the leader within the timer (i.e., the leader is down or the task fails); 4. The follower enters the candidate state and requests to elect a new leader; 5. If multiple candidates submit a request in the same term 6. The candidate with the highest reputation is elected as the new leader; 7. END IF 8. END IF 9. The follower's timer is reset; 10.END FOR.
[0024] 2. As attached Figure 1 As shown, in the task unloading under the cooperation of multiple edge nodes in each group, the process of locating abnormal nodes in the present invention is as follows: 1) Each edge node (EN) entering the system is required to register its real identity with the cloud and pay an honesty deposit.
[0025] 2) After the leader receives the task offloaded from the terminal to the edge layer and issues the task to its followers in the group, the edge nodes in the group work together to complete the task. An edge node is required to be responsible for the correctness of the results provided when sharing intermediate results with other edge nodes, that is, before its successor edge node uses the intermediate results, its accuracy must be verified first.
[0026] 3) EN1 offloads its original data and computing tasks to other edge nodes such as EN2 (at least to two ENs) using a replication mechanism.
[0027] 4) The replication mechanism merges the test data into the original data of each task and determines the replication frequency based on the personalized verification strategy related to the reputation value, that is, as shown in Figure 2, EN1 offloads the computing task to EN2 and EN3.
[0028] 5) EN1 confirms the received results and submits the performance evaluation of EN2 in the service instance to the cloud.
[0029] 6) Then, it is the cloud's turn to perform its operations. Based on the received evaluation, the cloud decides whether to pay EN2 for its services or to punish it by withholding its security deposit. If EN2 is found to be abnormal, its security deposit is awarded to EN3 who discovered it.
[0030] 7) At the same time, the latest evaluation is used to update the reputation of EN2. EN2's updated reputation will help other ENs calculate the replication frequency when they offload tasks to EN2.
[0031] In the present invention, the computing tasks generated by the terminal will be offloaded to the edge nodes near it. After the tasks are completed by the edge layer composed of multiple edge nodes, the present invention can efficiently detect whether the edge nodes are reliable, that is, whether the computing tasks of the terminal are correctly processed according to the computing task requirements. When it is found that the calculation results are wrong, the present invention can promptly locate the edge nodes that provide the wrong results to ensure that the edge system maintains credibility and stability in the presence of untrusted edge nodes.
Claims
1. A method for detecting and locating abnormal behavior of edge nodes suitable for task offloading scenarios, characterized in that: The steps include: 1) Each edge node that enters a system with task offloading requirements is required to register its real identity with the cloud and pay an honesty deposit; the system includes smart terminals and the cloud; 2) The edge nodes entering the system are grouped according to their geographical locations. A leader is selected in each group. After the leader receives the task offloaded from the terminal to the edge layer composed of multiple edge nodes and issues the task to the edge nodes in its group, the edge nodes in the group work together to complete the task. When completing the task, each edge node is required to be responsible for the correctness of the intermediate results when sharing them with other edge nodes. That is, before its subsequent edge node uses the intermediate results, it must first verify the accuracy of the intermediate results and send the verification results to the cloud. 3) When each edge node completes a task in collaboration with other edge nodes, it also needs to verify the accuracy of the tasks completed by other edge nodes. That is, after the original data and computing tasks are unloaded to a certain edge node using the replication mechanism, the same original data and computing tasks will be unloaded to another edge node using the replication mechanism. The replication mechanism will merge the test data into the original data of each task. By comparing the results of a certain edge node completing a task with those of another edge node, the accuracy of the task completed by a certain edge node can be verified, and the verification results will be sent to the cloud. 4) The cloud integrates the verification results in steps 2) and 3) to decide whether to pay service rewards to the edge nodes that participated in the collaborative task or to punish them by withholding their honesty deposits; If an error is found in the task result of an edge node, the honesty deposit will be awarded to the edge node that discovered the error; 5) The latest verification result in step 4) is used to update the reputation value of the corresponding edge node; the reputation value refers to the accuracy of a certain edge node after completing previous tasks, which is determined by the verification result. The higher the reputation value, the more accurate times the edge node has completed tasks; 6) After an unloading task is completed, all edge nodes entering the system are regrouped according to their reputation values, divided into good groups and bad groups, a new leader is selected for the good group, and the next unloading task is completed according to steps 2) to 5); if the number of tasks is too large and the bad group is also unloaded, then the bad group must also select a leader after completing the task according to steps 2) to 5).
2. The method for detecting and locating abnormal behavior of edge nodes applicable to task offloading scenarios according to claim 1, characterized in that: In step 2), each group selects a leader randomly in the first round of elections; the subsequent leader elections are carried out using the RRaft mechanism; The first round of group elections leaders: There are three states for edge nodes: leader, follower, and candidate. In the first round of leader election, all edge nodes are initially in the follower state. Each edge node has an election timeout timer, and each edge node has a different timer; this timer is started at the beginning of the Raft algorithm or when the follower cannot receive a heartbeat from the leader; Follower conversion to candidate: When a follower's election timeout expires, if it has not received a heartbeat from the leader, it will consider itself the only edge node that can become the leader and convert its status to candidate; the candidate increases its term number by 1 and broadcasts a voting request; Candidate request vote: The candidate sends a request vote to all other edge nodes entering the system, requesting them to vote for themselves. The edge node that receives the request vote decides whether to vote for the candidate that issued the request according to the following rules: (1) If the term number of the candidate making the request is greater than or equal to the term number of the edge node receiving the request; (2) Each edge node can only vote for one candidate during the same term; The RRaft mechanism election is as follows: Including the initial election, each group has only one leader, and the rest are followers; when the leader fails or the group cluster is started, the leaderless followers become candidates and initiate elections; The candidate sends a voting request to other edge nodes in the group. Each edge node can only cast one vote per term for the candidate with the largest term number and the greatest reputation; The candidate that receives more than half of the votes becomes the new leader. If no candidate receives more than half of the votes, the election times out and the candidate becomes a follower, increases the term number and restarts the election. The term is used to identify the ruling period of the leader, and the term number is increased each time a new leader is elected. Timeout means that after a candidate initiates a voting request, if it does not receive a voting response from the majority of nodes within a certain period of time, a timeout will occur. After the timeout, the candidate will give up the current election and return to the follower state. After the leader is successfully elected, it will send a broadcast message to the followers and issue tasks to maintain its leadership position. When the follower receives the leader's message, it will reset the timer, indicating the beginning of a term, and remain in the follower state and listen to instructions; if the follower does not receive a message from the leader within the set time, the leader is considered invalid, the follower increases the term number and becomes a candidate; while waiting for the voting results, the candidate may receive broadcasts from other edge nodes. If the term number in the broadcast is higher than or equal to its own and the reputation is not less than its own, the legitimacy of the edge node leader is recognized, the candidate gives up the candidate state and becomes a follower; if the received term number is lower than its own or no broadcast is received, it continues to maintain the candidate state and broadcasts the election request.
3. The method for detecting and locating abnormal behavior of edge nodes applicable to task offloading scenarios according to claim 2, characterized in that: The RRaft mechanism election also includes: followers vote on a "first come, first served" basis to ensure that at most one candidate is elected leader per term: when a follower receives voting request messages from multiple candidates, it decides who to vote for based on the order in which the messages arrive. When the first request arrives and has a higher reputation than itself, the follower will vote, while subsequent requests will be rejected; that is, the one with the highest reputation during the same term becomes the new leader; the new leader announces its leadership through broadcasting, blocks the new election process, and then begins to perform its duties and receive tasks, and sends the tasks to followers for collaborative processing.
4. The method for detecting and locating abnormal behavior of edge nodes applicable to task offloading scenarios according to claim 2, characterized in that: When the good group and the bad group are subsequently divided, the reputation value of each edge node is used for division, that is, the top 50% of the reputation value is divided into the good group, and the bottom 50% is divided into the bad group.
5. A method for detecting and locating abnormal behavior of edge nodes applicable to task offloading scenarios according to any one of claims 1 to 4, characterized in that: In step 5), the reputation value of a certain edge node is associated with its replication frequency, that is, the higher the reputation value, the lower the frequency of the edge node being verified by other edge nodes.
Citation Information
Patent Citations
Fog network unloading decision and resource allocation method based on block chain technology
CN111770073A
Multi-maneuvering edge node resource collaborative scheduling management system and method in high dynamic environment
CN116939038A
Reputation mechanism-based fragmentation consensus method for block chain in smart power grid
CN117255095A
Block chain consensus method and device, equipment and storage medium
CN118018554A
Cooperative task unloading and block mining method for mobile edge computing
CN119110348A
Cited By
Multi-CPU distributed negotiation control method and device for aerospace flight control and rocket
CN120469301A
Distribution resource interaction method, terminal, equipment and medium for transformer area autonomy
CN121906780A