A route leakage method, device and storage medium
By configuring the three-layer master device mechanism and kernel interface, the complexity and resource consumption of route leakage between VRF domains are resolved, and a route leakage method with simplified configuration and clear rules is implemented.
Patent Information
- Application Number
- CN202411852196.7
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2024-12-16
- Publication Date
- 2025-10-28
- Estimated Expiration
- 2044-12-16
AI Technical Summary
In existing technologies, route leakage methods are complex to configure between VRF domains, prone to errors, consume a lot of resources, and have unclear rules.
A three-layer master device mechanism is adopted to create a kernel interface and a kernel routing table. New entries are added at the application layer and the kernel routing table is updated through socket messages, which simplifies the configuration steps and clearly reflects the routing leakage rules.
It simplifies the configuration process for route leaks, reduces the probability of errors, improves the flexibility and clarity of configuration, and reduces resource consumption.
Smart Images

Figure CN119652819B_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of communication technology, and in particular to a routing leakage method, device, and storage medium. Background Technology
[0002] Virtual Router Forwarding (VRF) is a network technology used to create multiple logically isolated VRF domains on a single physical device, thereby achieving network traffic isolation and management. Currently, there are two main ways to implement VRF: one is by configuring policy-based routing, and the other is by using net namespaces. In some cases, it is necessary to share routing information from one VRF domain to another; this process is called route leakage.
[0003] Currently, there are two main methods for route leakage, corresponding to the two VRF implementations mentioned above. Both methods have certain problems, as detailed below:
[0004] (1) When using policy-based routing to implement VRF, a physical device has only one routing table, and each VRF domain configures its own policy routes according to the above routing table. When route leakage is required between these VRF domains, the corresponding policy routing rules must be modified. The problem is that as the number of VRF domains increases, the policy routing rules also become more and more complex, making it tedious and error-prone to modify these rules.
[0005] (2) When using namespaces to implement VRF, a physical device is divided into multiple virtual namespaces, each corresponding to a VRF domain. To achieve route leakage between these VRF domains, the entries in the routing table of one VRF domain need to be copied to the routing table of another VRF domain. In this case, the entries used to achieve route leakage are not significantly different from ordinary entries, making it difficult to clearly demonstrate the rules of route leakage from the routing table. Furthermore, to ensure the consistency of routing information, when entries in the original routing table are changed or deleted, the VRF domain receiving these routing entries also needs to dynamically modify or synchronously delete them, resulting in this implementation method consuming significant hardware resources. Summary of the Invention
[0006] This invention provides a routing leakage method, device, and storage medium to solve at least one of the above-mentioned technical problems.
[0007] The present invention adopts the following technical solution:
[0008] In a first aspect, the present invention provides a route leakage method, the method comprising: creating a kernel interface and a kernel routing table based on a three-layer master device mechanism; creating application layer interfaces corresponding to each kernel interface and application layer routing tables corresponding to each kernel routing table at the application layer; receiving a route leakage command and determining the target network segment and the leakage party's application layer interface according to the route leakage command; configuring a new entry in the receiving party's application layer routing table; and updating the receiving party's kernel routing table according to the new entry.
[0009] In one feasible implementation, updating the receiver kernel routing table based on the newly added entry includes: after the newly added entry is configured, retrieving the data of the newly added entry; creating a socket message based on the data of the newly added entry, and sending the socket message to the kernel to update the receiver kernel routing table.
[0010] In one feasible implementation, a socket message is created based on the data of the newly added table entry, including: extracting the destination network segment corresponding to the routing information to be leaked and the name of the application layer interface of the leaking party from the data of the newly added table entry; determining the name of the kernel interface of the leaking party based on the name of the application layer interface of the leaking party; creating a routing socket message, and setting the destination network segment corresponding to the routing socket message to the destination network segment corresponding to the routing information to be leaked, and setting the name of the next-hop interface corresponding to the routing socket message to the name of the kernel interface of the leaking party.
[0011] In one feasible implementation, a new entry is configured in the receiving application layer routing table, including: detecting whether the network protocol corresponding to the receiving application layer routing table includes a dynamic routing protocol; if so, obtaining the default priority of the route leakage entry, and configuring the priority of the new entry according to the default priority.
[0012] In one feasible implementation, if the network protocol corresponding to the receiving application layer routing table includes a dynamic routing protocol, the receiving kernel routing table is updated according to the newly added entry. Specifically, this includes: after the newly added entry is configured, retrieving the data of the newly added entry; extracting all entries from the receiving application layer routing table that have the same destination network segment as the newly added entry, and updating the receiving kernel routing table according to the entry with the highest priority among all entries.
[0013] In one feasible implementation, creating a kernel interface and a kernel routing table includes: determining the name of the kernel interface and the identifier of the kernel routing table; using kernel commands to create the kernel interface and the kernel routing table based on the name of the kernel interface and the identifier of the kernel routing table, and binding the kernel interface and the kernel routing table; and setting the kernel routing table to the highest priority.
[0014] In one feasible implementation, setting the kernel routing table to the highest priority includes: obtaining multiple routing tables corresponding to the kernel interface, and the priorities of the multiple routing tables; extracting high-priority routing tables from the multiple routing tables whose priorities are higher than those of the kernel routing table; and setting the priority of the high-priority routing tables to be lower than that of the kernel routing table.
[0015] In one feasible implementation, determining the destination network segment and the application layer interface of the leaker based on the route leakage command includes: determining whether the application layer interface of the leaker exists in the route leakage command; if so, extracting the destination network segment and the application layer interface of the leaker from the route leakage command; otherwise, traversing the application layer routing table, finding the application layer routing table of the leaker that contains the destination network segment, and determining the application layer interface of the leaker based on the application layer routing table of the leaker.
[0016] Secondly, the present invention also provides a route leakage device, the device specifically comprising: at least one processor; and a memory communicatively connected to the at least one processor; wherein the memory stores instructions executable by the at least one processor to enable the at least one processor to execute a route leakage method as described in any of the above embodiments.
[0017] Thirdly, the present invention also provides a non-volatile computer storage medium storing computer-executable instructions configured to execute a routing disclosure method as described in any of the above embodiments.
[0018] The routing leakage method, device, and storage medium provided by this invention have the following beneficial effects:
[0019] 1. Based on the three-layer master device mechanism, a kernel interface and kernel routing table are created. The kernel interface can be used as the next-hop interface in the routing table configuration, providing an interface foundation for subsequent route leakage steps. First, the application-layer routing table is modified, and then the kernel routing table is updated based on the content of the application-layer routing table. This facilitates user operations at the application layer and allows for more flexible and diverse configurations within the application-layer routing table. Configuring new entries in the receiving party's application-layer routing table and setting the next-hop interface to the leaking party's application-layer interface greatly simplifies the route leakage configuration steps compared to modifying policy routing, reducing the possibility of errors during route leakage configuration. Compared to using namespaces, the content in new entries used for route leakage is significantly different from ordinary entries; the content in the routing table clearly reflects the rules of the routing configuration. Attached Figure Description
[0020] To more clearly illustrate the technical solutions in this invention or the prior art, the drawings used in the description of the embodiments or the prior art will be briefly introduced below. Obviously, the drawings described below are only some embodiments recorded in this invention. For those skilled in the art, other drawings can be obtained based on these drawings without creative effort. In the drawings:
[0021] Figure 1 A flowchart of a route leakage method provided by the present invention;
[0022] Figure 2 This is a schematic diagram of the structure of a routing leakage device provided by the present invention. Detailed Implementation
[0023] To enable those skilled in the art to better understand the technical solutions of this invention, the technical solutions of this invention will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of this invention, and not all embodiments. Based on the embodiments of this specification, all other embodiments obtained by those skilled in the art without creative effort should fall within the scope of protection of this invention.
[0024] This invention provides a route leakage method that solves the technical problems of cumbersome and error-prone configuration steps for route leakage, high resource consumption, and unclear leakage rules by configuring a new entry in the routing table of the receiving party's application layer and using the application layer interface of the leaking party as the next-hop interface.
[0025] The method of the present invention will now be described in detail with reference to the accompanying drawings.
[0026] Figure 1 A flowchart of a route leakage method provided by the present invention is shown below. Figure 1 As shown, the route leakage method of the present invention includes at least the following execution steps:
[0027] Step 101: Based on the three-layer master device mechanism, create the kernel interface and kernel routing table.
[0028] A Layer 3 master device, or L3Mdev for short, is a feature introduced by the Linux kernel to support Virtual Router Forwarding (VRF). The L3Mdev mechanism allows for Layer 3 network isolation in Linux systems, meaning network layer isolation between different VRF domains. The Layer 3 master device mechanism can be viewed as creating a virtual network interface card (NIC) that only operates at Layer 3 (the network layer) and has its own independent routing table. The kernel interface mentioned above refers to the virtual network interface created by the kernel, also known as a virtual NIC. The kernel routing table refers to the routing table created by the kernel and bound to the aforementioned kernel interface.
[0029] Specifically, the first step is to determine the name of the kernel interface and the identifier of the kernel routing table. These are the parameters required to call the kernel to create the kernel interface and kernel routing table. After the kernel function creates the aforementioned kernel interface and kernel routing table, the kernel will automatically bind these kernel interfaces and kernel routing tables.
[0030] Next, the priority of the kernel routing table needs to be modified to the highest level. This ensures that the kernel interface queries the kernel routing table first. The specific steps for modifying the priority are as follows: First, obtain the multiple routing tables corresponding to the kernel interface and their priority information. Then, extract the high-priority routing tables from the multiple routing tables, which have a higher priority than the kernel routing table. Finally, set the priority of these high-priority routing tables to be lower than that of the kernel routing table. These steps ensure that the kernel routing table containing route leak entries is queried first, thus guaranteeing that when conflicts arise between the kernel routing table and other routing tables, the content in the kernel routing table takes precedence.
[0031] In one example, the kernel interface is first named `vrf_red`, and the kernel routing table identifier is `table_10`. Then, the kernel function `ip link add vrf_red type vrf table_10` is called. This creates the kernel interface named `vrf_red` and the kernel routing table with the identifier `table_10`. After the kernel routing table is created, the kernel automatically assigns it a priority. After creation, the routing table corresponding to the above kernel interface is as follows:
[0032] 0:from all lookup local
[0033] 1000:from all lookup[l3mdev-table]
[0034] 32766:from all lookup main
[0035] 32767:from all lookup default
[0036] The leftmost number represents the priority of the routing table; the smaller the number, the higher the priority.
[0037] [l3mdev-table] refers to the kernel routing table mentioned above. It can be seen that a routing table named "local" has a higher priority than the kernel routing table. Therefore, the priority of the "local" routing table needs to be reduced. Here, its priority can be set to 3000. After modification, the routing table corresponding to the kernel interface is as follows:
[0038] 1000:from all lookup[l3mdev-table]
[0039] 3000:from all lookup local
[0040] 32766:from all lookup main
[0041] 32767:from all lookup default
[0042] Step 102: Create application layer interfaces corresponding to each kernel interface and application layer routing tables corresponding to each kernel routing table at the application layer.
[0043] Kernel interfaces and kernel routing tables require root privileges to modify and can only be modified via command line or sockets, making them inconvenient for users. Therefore, corresponding application-layer interfaces and application-layer routing tables need to be created at the application layer to facilitate route leakage for users. These application-layer interfaces and routing tables can be created in several ways. For example, a data structure can be created at the application layer to synchronize kernel interface information. Alternatively, a linked list can be created at the application layer to synchronize kernel routing table information, selectively synchronizing information from the application-layer routing table to the kernel routing table.
[0044] Step 103: Receive the route leakage command and determine the target network segment and the application layer interface of the leaker based on the route leakage command.
[0045] The route disclosure command here is a user-issued command that includes the destination network segment to be disclosed, referred to as the leaked destination network segment. The command may also include the application layer interface of the disclosing party. The disclosing party's application layer interface refers to the application layer interface corresponding to the application layer routing table containing the leaked route information. Specifically, the essence of route disclosure is sharing table entry data from one routing table with another. Therefore, at the application layer, the routing table providing the table entry data is called the disclosing party's application layer routing table, and the application layer interface bound to the disclosing party's application layer routing table is called the disclosing party's application layer interface. Correspondingly, the routing table receiving the aforementioned table entry data is called the receiving party's application layer routing table, and the interface bound to the receiving party's application layer routing table is called the receiving party's application layer interface.
[0046] Specifically, the first step is to determine whether the route leakage command contains the name of the leaking party's application layer interface. The route leakage command may contain the name of the target network segment and the name of the leaking party's application layer interface. In this case, the relevant information can be directly extracted from the route leakage command for subsequent route leakage configuration. Alternatively, the route leakage command may not contain the name of the leaking party's application layer interface, but rather the name of a physical network interface. In this case, it is necessary to traverse the application layer routing table based on the target network segment and physical network interface information to find the application layer routing table storing the aforementioned information and the name of the leaking party's application layer interface corresponding to that application layer routing table.
[0047] In one example, a user performs route leakage using the command line: `add 20.1.0.0 / 24devvrf_2table 1001`. Here, `20.1.0.0 / 24` is the destination network segment for route leakage, `vrf_2` is the name of the application layer interface used for leakage, and `table 1001` is the identifier of the receiving application layer routing table. The command includes the name of the application layer interface used for leakage, allowing relevant data to be directly extracted for subsequent route leakage configuration operations.
[0048] Step 104: Configure a new entry in the receiving application layer routing table.
[0049] Specifically, based on the L3Mdev mechanism, each virtual routing forwarding domain contains a virtual network interface, namely the kernel interface mentioned above. In this case, to leak a routing table entry from the leaking party's application layer routing table to the receiving party's application layer routing table, one can simply add a new entry to the receiving entry's routing table, where the network segment is set to the leaked destination network segment, and the next-hop interface is set to the leaking party's application layer interface corresponding to the leaking party's application layer routing table.
[0050] After completing the above configuration, when a data packet destined for the leaked network segment arrives at the receiving kernel interface, the receiving kernel routing table is queried to find the next-hop interface. Because the receiving application layer routing table has added an entry corresponding to the route leak and synchronized it with the receiving kernel routing table, the next-hop interface name is found to be the name of the leaking application layer interface. Since the application layer interface name is the same as the kernel interface name, it can be determined that the next-hop interface is the leaking kernel interface, and the aforementioned data packet enters the leaking kernel interface. Then, the leaking kernel routing table is queried to determine the physical network interface of the next hop, completing the data forwarding. Through the above steps, although an entry containing all leaked routing information is not directly added to the receiving application layer routing table, data packets destined for the leaked network segment are successfully forwarded to the leaking kernel interface and forwarded according to the leaked routing information, effectively completing the route leak. The route leakage method described above clearly shows the rules of route leakage in the receiver's routing table. Furthermore, the configuration of route leakage only requires providing the destination network segment and the name of the corresponding application layer interface of the leaker, which is very easy to operate, greatly simplifies the route configuration steps, and reduces the probability of errors during route configuration.
[0051] In one possible implementation, the receiving application-layer routing table may correspond to a dynamic routing protocol, meaning the routing table may automatically learn the next-hop interface of the leaked destination network segment. In this case, different priorities need to be set for the same network segment to determine the data source for updating the kernel routing table. Specifically: first, it is checked whether the network protocol corresponding to the receiving application-layer routing table includes a dynamic routing protocol. If so, the default priority of the leaked routing entry is obtained, and the priority of the newly added entry is configured according to the default priority.
[0052] In one example, the network protocol corresponding to the application layer routing table includes a dynamic routing protocol. The default priority of the route leak entry is 100. The route leak entry for 20.1.0.0 / 24 is set to 20.1.0.0 / 24->vrf_2pro=100, where vrf_2 is the name of the application layer interface of the leaker, and pro=100 indicates that the priority is set to 100. The route entry automatically learned in the routing table for 20.1.0.0 / 24 is 20.1.0.0 / 24->eth_0_1pro=200, where eth_0_1 is the name of the physical network interface, and pro=200 indicates that the priority is set to 200. Here, the larger the priority number, the higher the priority.
[0053] Step 105: Update the receiver kernel routing table based on the newly added entries.
[0054] Specifically, after the configuration of the new entry is completed, the data of the new entry is retrieved. A socket message is created based on the data of the new entry and sent to the kernel to update the receiving kernel routing table.
[0055] Further, the specific steps for creating a socket message based on the data from the newly added table entry are as follows: First, extract the destination network segment corresponding to the routing information to be leaked, and the name of the application layer interface of the leaking party, from the data of the newly added table entry. Then, determine the name of the kernel interface of the leaking party based on the name of the application layer interface. Generally, the name of the application layer interface of the leaking party is the same as the name of the kernel interface of the leaking party. If they are different, the name of the kernel interface of the leaking party can be determined according to the name mapping table. Create a routing socket message, and set the destination network segment corresponding to the socket message to the destination network segment corresponding to the routing information to be leaked, and the name of the next-hop interface corresponding to the routing socket message to the name of the kernel interface of the leaking party.
[0056] In one possible implementation, if the network protocol corresponding to the receiver's application layer routing table includes a dynamic routing protocol, then after the new entry is configured, the data of the new entry is retrieved. Then, all entries with the same destination network segment as the new entry are extracted from the receiver's application layer routing table, and the receiver's kernel routing table is updated based on the highest-priority entry among all entries.
[0057] In one example, the route leak entry for 20.1.0.0 / 24 is set to 20.1.0.0 / 24->vrf_2pro=100. The route entry automatically learned in the routing table for 20.1.0.0 / 24 is 20.1.0.0 / 24->eth_0_1pro=200. Therefore, the kernel routing table is updated according to 20.1.0.0 / 24->eth_0_1pro=200. After the update, the corresponding entry in the kernel routing table is: 20.1.0.0 / 24->eth_0_1.
[0058] Based on the same inventive concept, the present invention also provides a route leakage device, the structure of which is as follows: Figure 2 As shown.
[0059] Figure 2 This is a schematic diagram of a routing leakage device provided by the present invention. Figure 2 As shown, the route leakage device 200 of the present invention specifically includes: at least one processor 201; and a memory 203 communicatively connected to the at least one processor (connected via a bus 202); wherein the memory 203 stores instructions executable by the at least one processor 201 to enable the at least one processor 201 to execute a route leakage method as described in the above embodiments.
[0060] In one or more possible implementations of the present invention, the aforementioned processor is used to perform the following actions: based on a three-layer master device mechanism, create kernel interfaces and kernel routing tables; create application layer interfaces corresponding to each kernel interface and application layer routing tables corresponding to each kernel routing table at the application layer; receive a route leakage command and determine the leakage destination network segment and the leakage party's application layer interface according to the route leakage command; configure a new entry in the receiving party's application layer routing table; and update the receiving party's kernel routing table according to the new entry.
[0061] In addition, the present invention provides a non-volatile computer storage medium storing computer-executable instructions configured to execute a routing disclosure method as described in any of the above embodiments.
[0062] In one or more possible implementations of the present invention, the aforementioned computer-executable instructions are configured to execute, based on a three-layer master device mechanism, to create kernel interfaces and kernel routing tables; to create application layer interfaces corresponding to each kernel interface and application layer routing tables corresponding to each kernel routing table at the application layer; to receive a route leakage command, and to determine the leakage destination network segment and the leakage party's application layer interface according to the route leakage command; to configure a new entry in the receiving party's application layer routing table; and to update the receiving party's kernel routing table according to the new entry.
[0063] The various embodiments in this invention are described in a progressive manner. Similar or identical parts between embodiments can be referred to interchangeably. Each embodiment focuses on its differences from other embodiments. In particular, the embodiments for IoT devices and media are relatively simple in description because they are fundamentally similar to the method embodiments; relevant parts can be referred to the descriptions in the method embodiments.
[0064] The system, medium, and method provided by this invention are in one-to-one correspondence. Therefore, the system and medium also have similar beneficial technical effects as their corresponding methods. Since the beneficial technical effects of the method have been described in detail above, the beneficial technical effects of the system and medium will not be repeated here.
[0065] It will be understood by those skilled in the art that embodiments of the present invention may be provided as methods, systems, or computer program products. Thus, the present invention may take the form of an entirely hardware embodiment, an entirely software embodiment, or an embodiment combining software and hardware. Furthermore, the present invention may take the form of a computer program product implemented on one or more computer-usable storage media (including but not limited to magnetic disk storage, CD-ROM, optical storage, etc.) containing computer-usable program code.
[0066] This invention is described with reference to flowchart illustrations and / or block diagrams of methods, apparatus (systems), and computer program products according to the invention. It will be understood that each block of the flowchart illustrations and / or block diagrams, and combinations of blocks in the flowchart illustrations and / or block diagrams, can be implemented by computer program instructions. These computer program instructions can be provided to a processor of a general-purpose computer, special-purpose computer, embedded processor, or other programmable data processing device to produce a machine, such that the instructions, which execute via the processor of the computer or other programmable data processing device, generate instructions for implementing the flowchart illustrations and / or block diagrams. Figure 1 a process or multiple processes and / or boxes Figure 1 A device that provides the functions specified in one or more boxes.
[0067] These computer program instructions may also be stored in a computer readable memory that can direct a computer or other programmable data processing device to work in a specific manner, so that the instructions stored in the computer readable memory produce an article of manufacture comprising an instruction device, which implements the process Figure 1 a process or multiple processes and / or boxes Figure 1 The function specified in one or more boxes.
[0068] It should also be noted that the terms "comprising," "including," or any other variations thereof are intended to cover non-exclusive inclusion, such that a process, method, article, or apparatus that comprises a list of elements includes not only those elements but also other elements not expressly listed, or elements inherent to such process, method, article, or apparatus. Unless otherwise specified, an element defined by the phrase "comprising one..." does not exclude the presence of other identical elements in the process, method, article, or apparatus that includes that element.
[0069] The above are merely embodiments of the present invention and are not intended to limit the invention. Various modifications and variations can be made to the present invention by those skilled in the art. Any modifications, equivalent substitutions, improvements, etc., made within the spirit and principle of the present invention should be included within the scope of protection of the present invention.
Claims
1. A route leakage method, characterized in that, The method includes: Based on the three-layer master device mechanism, a kernel interface and a kernel routing table are created, with each kernel interface corresponding to a kernel routing table in a one-to-one manner. Create application layer interfaces corresponding to each kernel interface and application layer routing tables corresponding to each kernel routing table at the application layer. Receive a route disclosure command and determine the target network segment and the application layer interface of the party disclosing the route based on the route disclosure command; Configure a new entry in the receiving application layer routing table. The destination network segment corresponding to the new entry is the leaked destination network segment, and the next-hop interface corresponding to the new entry is the leaking application layer interface. Update the receiver's kernel routing table based on the newly added entry.
2. The route leakage method according to claim 1, characterized in that, Update the receiver kernel routing table according to the newly added entries, including: After the new table entry is configured, the data of the new table entry is retrieved; A socket message is created based on the data of the newly added table entry, and the socket message is sent to the kernel to update the receiving kernel routing table.
3. The route leakage method according to claim 2, characterized in that, Create a socket message based on the data of the newly added table entry, including: Extract the destination network segment corresponding to the routing information to be leaked, as well as the name of the application layer interface of the leaking party, from the data of the newly added table entry; The name of the leaker's kernel interface is determined based on the name of the leaker's application layer interface. Create a routing socket message and set the destination network segment corresponding to the routing socket message to the destination network segment corresponding to the routing information to be leaked. The name of the next-hop interface corresponding to the routing socket message is the name of the kernel interface of the leaker.
4. The route leakage method according to claim 1, characterized in that, Configure a new entry in the receiving application layer routing table, including: Detect whether the network protocol corresponding to the application layer routing table of the receiver includes a dynamic routing protocol; If so, obtain the default priority of the route leak entry, and configure the priority of the newly added entry according to the default priority.
5. The route leakage method according to claim 4, characterized in that, If the network protocol corresponding to the receiving application layer routing table includes a dynamic routing protocol, the receiving kernel routing table is updated according to the newly added entry, specifically including: After the new table entry is configured, the data of the new table entry is retrieved; Extract all entries from the receiving application layer routing table that are the same as the destination network segment of the newly added entry, and update the receiving kernel routing table according to the entry with the highest priority among all entries.
6. The route leakage method according to claim 1, characterized in that, Create the kernel interface and kernel routing table, including: Determine the name of the kernel interface and the identifier of the kernel routing table; Based on the name of the kernel interface and the identifier of the kernel routing table, use kernel commands to create the kernel interface and the kernel routing table, and bind the kernel interface and the kernel routing table. Set the kernel routing table to the highest priority.
7. The route leakage method according to claim 6, characterized in that, Setting the kernel routing table to the highest priority includes: Obtain multiple routing tables corresponding to the kernel interface, and the priorities corresponding to the multiple routing tables; Extract the high-priority routing table from the multiple routing tables, which has a higher priority than the kernel routing table; Set the priority of the high-priority routing table to be lower than the priority of the kernel routing table.
8. The route leakage method according to claim 1, characterized in that, The route leakage command determines the target network segment and the application layer interface of the leaker, including: Determine whether the route leakage command contains the application layer interface of the leaking party; If so, then extract the target network segment to be leaked and the application layer interface of the leaking party from the route leak command; Otherwise, traverse the application layer routing table to find the application layer routing table of the leaking party that contains the leaked destination network segment, and determine the application layer interface of the leaking party based on the application layer routing table of the leaking party.
9. A routing leakage device, characterized in that, The device specifically includes: At least one processor; and, A memory communicatively connected to the at least one processor; wherein, The memory stores instructions executable by the at least one processor to enable the at least one processor to perform a routing disclosure method according to any one of claims 1-8.
10. A non-volatile computer storage medium storing computer-executable instructions thereon, characterized in that, The computer-executable instructions are configured to execute a route disclosure method according to any one of claims 1-8.
Citation Information
Patent Citations
Route leakage optimization method, equipment and medium
CN116506344A
Flow transmission method and device and related equipment
CN118740714A