Communication penetration method and device for network address translation scene, equipment and storage medium
By generating optimal strategies through type recognition models and real-time state decisions, the problem of low communication penetration success rate in network address translation scenarios is solved, achieving a more efficient penetration effect.
Patent Information
- Application Number
- CN202610046868.8
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2026-01-14
- Publication Date
- 2026-03-13
AI Technical Summary
Existing technologies have a low success rate in communication penetration in network address translation scenarios, especially in session initialization protocol communication, where network address translation leads to address hiding, port mapping failure, and complex rule adaptation, resulting in a low success rate for existing solutions.
A type recognition model is used to process network feature data. Combined with real-time network status, server resource status and historical penetration decisions, the optimal penetration strategy is generated and sent to the communication terminal for execution.
It improves the success rate of communication penetration in network address translation scenarios by accurately identifying network address translation rule types and dynamically generating the optimal strategy.
Smart Images

Figure CN121664769A_ABST
Abstract
Description
Technical Field
[0001] This application relates to the field of network communication technology, and in particular to a communication penetration method, apparatus, device, and storage medium for network address translation scenarios. Background Technology
[0002] In network communication, Session Initiation Protocol (SIP) communication often suffers from problems such as address hiding, port mapping failure, and complex rule adaptation due to Network Address Translation (NAT). Existing solutions such as session traversal, relay traversal, and general plug-and-play technologies have low success rates. Therefore, improving the success rate of communication traversal in NAT scenarios remains a problem that needs to be solved. Summary of the Invention
[0003] The main objective of this application is to provide a communication penetration method, apparatus, device, and storage medium for network address translation scenarios, aiming to solve the technical problem of how to improve the success rate of communication penetration in network address translation scenarios.
[0004] To achieve the above objectives, this application proposes a communication traversal method for network address translation scenarios, the method comprising: Receive network characteristic data sent by the communication terminal; The network feature data is processed using a type recognition model to obtain the rule type recognition result of network address translation. The type recognition model includes at least a local feature extraction unit and a temporal feature analysis unit. Obtain server resource status data and historical penetration decisions, and generate a target penetration strategy based on real-time network status data in the network feature data, the rule type identification result, the server resource status data, and the historical penetration decisions; The penetration strategy is sent to the communication terminal so that the communication terminal performs a penetration operation according to the penetration strategy.
[0005] In one embodiment, the step of processing the network feature data using a type recognition model to obtain the rule type recognition result for network address translation includes: Local feature vectors are extracted from the network feature data using the local feature extraction unit of the type recognition model. The temporal feature analysis unit of the type recognition model is used to analyze the local feature vector and the temporal information in the network feature data to obtain the sequence feature vector; Based on the local feature vector and the sequence feature vector, a rule type recognition result is generated.
[0006] In one embodiment, the step of generating a target penetration strategy based on real-time network status data in the network feature data, the rule type identification result, the server resource status data, and the historical penetration decision includes: A state vector is obtained based on the real-time network status data, the rule type identification result, and the server resource status data; The penetration strategy decision model is used to evaluate and optimize the historical penetration decisions based on the state vector and the preset reward function to obtain the target penetration strategy.
[0007] In one embodiment, after the step of obtaining the target penetration strategy, the method further includes: Receive the policy execution result data returned by the communication terminal; The type recognition model and the penetration strategy decision model are trained based on the strategy execution result data to obtain the updated type recognition model and penetration strategy decision model.
[0008] In one embodiment, the server resource status data includes load information data and available bandwidth information data, and the step of obtaining server resource status data and historical penetration decision includes: Send a status query request to the address discovery server and receive the load information data returned by the address discovery server; Send a resource query request to the data relay server and receive available bandwidth information data returned by the data relay server; Historical penetration decisions are retrieved from the policy database based on the rule type identification results.
[0009] In one embodiment, after processing the network feature data using a type recognition model to obtain the rule type recognition result for network address translation, the method further includes: Obtain the confidence level of the rule type identification result output by the type identification model; When the confidence level is less than a preset value, a feature supplementation instruction is sent to the communication terminal, and the latest feature data sent by the communication terminal is received. The latest feature data is processed to obtain updated rule type identification results.
[0010] In one embodiment, after the step of receiving network feature data sent by the communication terminal, the method further includes: Detect whether the network feature data has any missing data; If missing values exist, the network feature data is filled with missing values to obtain complete network feature data.
[0011] Furthermore, to achieve the above objectives, this application also proposes a communication penetration device for network address translation scenarios, the communication penetration device for network address translation scenarios comprising: The receiving module is used to receive network characteristic data sent by the communication terminal; The identification module is used to process the network feature data using a type identification model to obtain the rule type identification result of network address translation. The type identification model includes at least a local feature extraction unit and a temporal feature analysis unit. The generation module is used to acquire server resource status data and historical penetration decisions, and generate a target penetration strategy based on the real-time network status data in the network feature data, the rule type identification result, the server resource status data, and the historical penetration decisions. The distribution module is used to distribute the penetration strategy to the communication terminal so that the communication terminal can perform a penetration operation according to the penetration strategy.
[0012] In addition, to achieve the above objectives, this application also proposes a communication traversal device for network address translation scenarios. The device includes: a memory, a processor, and a computer program stored in the memory and executable on the processor. The computer program is configured to implement the steps of the communication traversal method for network address translation scenarios as described above.
[0013] In addition, to achieve the above objectives, this application also proposes a storage medium, which is a computer-readable storage medium, on which a computer program is stored, and when the computer program is executed by a processor, it implements the steps of the communication penetration method in the network address translation scenario described above.
[0014] In addition, to achieve the above objectives, this application also provides a computer program product, which includes a computer program that, when executed by a processor, implements the steps of the communication penetration method for the network address translation scenario described above.
[0015] This application provides a communication penetration method for Network Address Translation (NAT) scenarios. The method involves receiving network feature data sent by a communication terminal; processing the network feature data using a type recognition model to obtain a NAT rule type identification result, where the type recognition model includes at least a local feature extraction unit and a temporal feature analysis unit; acquiring server resource status data and historical penetration decisions; generating a target penetration strategy based on real-time network status data, the rule type identification result, the server resource status data, and the historical penetration decisions; and distributing the penetration strategy to the communication terminal so that the communication terminal performs a penetration operation according to the strategy. This application improves the communication penetration success rate in NAT scenarios by receiving terminal network feature data, using a type recognition model with local and temporal analysis capabilities to accurately determine the NAT rule type, and dynamically generating and distributing the optimal penetration strategy based on real-time network status, server resource status, and historical decisions. Attached Figure Description
[0016] The accompanying drawings, which are incorporated in and form part of this specification, illustrate embodiments consistent with this application and, together with the description, serve to explain the principles of this application.
[0017] To more clearly illustrate the technical solutions in the embodiments of this application or the prior art, the drawings used in the description of the embodiments or the prior art will be briefly introduced below. Obviously, for those skilled in the art, other drawings can be obtained based on these drawings without creative effort.
[0018] Figure 1 A flowchart illustrating the communication penetration method for the network address translation scenario in this application (Example 1). Figure 2 A flowchart illustrating the second embodiment of the communication penetration method for network address translation scenarios in this application; Figure 3 This is a schematic diagram of the module structure of the communication penetration device in the network address translation scenario of this application embodiment; Figure 4 This is a schematic diagram of the device structure of the hardware operating environment involved in the communication penetration method in the network address translation scenario in this application embodiment.
[0019] The purpose, features, and advantages of this application will be further explained in conjunction with the embodiments and with reference to the accompanying drawings. Detailed Implementation
[0020] It should be understood that the specific embodiments described herein are merely illustrative of the technical solutions of this application and are not intended to limit this application.
[0021] To better understand the technical solution of this application, a detailed description will be provided below in conjunction with the accompanying drawings and specific implementation methods.
[0022] This application receives network feature data sent by a communication terminal; processes the network feature data using a type recognition model to obtain a rule type recognition result for network address translation, wherein the type recognition model includes at least a local feature extraction unit and a temporal feature analysis unit; acquires server resource status data and historical penetration decisions; generates a target penetration strategy based on the real-time network status data in the network feature data, the rule type recognition result, the server resource status data, and the historical penetration decisions; and sends the penetration strategy to the communication terminal so that the communication terminal performs a penetration operation according to the penetration strategy.
[0023] In network communication, Session Initiation Protocol (SIP) communication often suffers from problems such as address hiding, port mapping failure, and complex rule adaptation due to Network Address Translation (NAT). Existing solutions such as session traversal, relay traversal, and general plug-and-play technologies have low success rates. Therefore, improving the success rate of communication traversal in NAT scenarios remains a problem that needs to be solved.
[0024] This application receives terminal network characteristic data, uses a type identification model with local and temporal analysis capabilities to accurately determine the network address translation rule type, and dynamically generates the optimal penetration strategy by integrating real-time network status, server resource status, and historical decisions, thereby improving the communication penetration success rate in network address translation scenarios.
[0025] Based on this, embodiments of this application provide a communication penetration method for network address translation scenarios, referring to... Figure 1 , Figure 1 This is a flowchart illustrating the first embodiment of the communication penetration method for the network address translation scenario of this application.
[0026] In this embodiment, the communication penetration method for the network address translation scenario includes steps S10 to S40: Step S10: Receive network characteristic data sent by the communication terminal; It should be noted that the executing entity in this embodiment can be a computing service device with data processing, network communication, and program execution functions, such as a tablet computer, personal computer, or mobile phone, or an electronic device capable of performing the above functions, a communication penetration device for network address translation scenarios, etc. The following description uses a communication penetration device for network address translation scenarios as an example to illustrate this embodiment and the subsequent embodiments.
[0027] It should be noted that the communication terminal can be a Session Initiation Protocol (SIP) terminal, such as a VoIP phone terminal or a video conferencing software terminal. Network characteristic data includes basic network characteristics: the terminal's private IP address, private port, public IP address, and the MAC address of the Network Address Translation (NAT) device. It also includes dynamic network characteristics: network latency, packet loss rate, port mapping timeout (which can be recorded by sending "probe packets" to track the lifespan of the mapping relationship), and SIP signaling interaction success rate. Finally, it includes device characteristics: the NAT device manufacturer, the SIP terminal type, and the operating system version.
[0028] In one feasible approach, after the step of receiving network feature data sent by the communication terminal, the method further includes: detecting whether there is any missing data in the network feature data; if so, performing missing value filling processing on the network feature data to obtain complete network feature data.
[0029] It should be noted that if missing network feature data is detected, the missing feature values (such as some terminals being unable to obtain NAT vendor information) are filled with the mean, the numerical features (such as latency and packet loss rate) are normalized (mapped to the 0-1 range), and the categorical features (such as terminal type) are one-hot encoded to obtain complete network feature data.
[0030] Step S20: Process the network feature data using a type recognition model to obtain the rule type recognition result of network address translation. The type recognition model includes at least a local feature extraction unit and a temporal feature analysis unit. It should be noted that the local feature extraction unit can be a convolutional neural network (CNN), and the temporal feature analysis unit can be a long short-term memory network (LSTM).
[0031] In one feasible approach, the step of processing the network feature data using a type recognition model to obtain a rule type recognition result for network address translation includes: using the local feature extraction unit of the type recognition model to extract local feature vectors from the network feature data; using the temporal feature analysis unit of the type recognition model to analyze the local feature vectors and the temporal information in the network feature data to obtain a sequence feature vector; and generating a rule type recognition result based on the local feature vectors and the sequence feature vectors.
[0032] It should be noted that when network feature data is input into the type recognition model, the local feature extraction layer of the type recognition model can extract the local correlation between features (such as the correlation between "latency and packet loss rate" and NAT type). Then, it is input into the time series feature analysis unit (capturing time series features, such as the changing trend of port mapping timeout). Finally, the rule type recognition result is output, that is, the NAT type, including full cone, address-restricted cone, port-restricted cone and symmetric type. In addition, the recognition confidence can also be output.
[0033] Step S30: Obtain server resource status data and historical penetration decisions, and generate a target penetration strategy based on the real-time network status data in the network feature data, the rule type identification result, the server resource status data, and the historical penetration decisions; It should be noted that the servers include address discovery servers and data relay servers. For example, an address discovery server can be a NAT session traversal (STUN) server; a data relay server can be a traversal using relays around NAT (TURN) server.
[0034] In one feasible approach, the steps of obtaining server resource status data and historical penetration decisions include: sending a status query request to an address discovery server and receiving load information data returned by the address discovery server; sending a resource query request to a data relay server and receiving available bandwidth information data returned by the data relay server; and retrieving historical penetration decisions from the policy database based on the rule type identification result.
[0035] It's important to note that each instance in the STUN server cluster periodically sends an HTTP GET request to query its current status. The STUN server responds to the request, returning JSON data containing information such as the number of currently active sessions or CPU utilization. This data is either aggregated or recorded separately as load information. Simultaneously, it also sends query requests to the TURN server cluster. The TURN server returns the current total bandwidth and used bandwidth of its network interface, or directly calculates and returns available bandwidth information. Furthermore, a search is performed in the local or remote policy database, using the currently identified rule type (e.g., "port-restricted cone NAT") as the primary query key, combined with the range of real-time network status (e.g., latency <100ms) as auxiliary conditions. The database returns a series of historical traversal decision records that meet the conditions, including the traversal policy content, execution time, final result (success / failure), resource consumption, etc. This set of records constitutes the historical traversal decisions used in this decision.
[0036] In one feasible approach, after the step of processing the network feature data using a type recognition model to obtain the rule type recognition result for network address translation, the method further includes: obtaining the confidence level of the rule type recognition result output by the type recognition model; when the confidence level is less than a preset value, sending a feature supplementation instruction to the communication terminal and receiving the latest feature data sent by the communication terminal; and processing the latest feature data to obtain an updated rule type recognition result.
[0037] It should be noted that when the type recognition model outputs a rule type recognition result (such as "symmetric"), it also outputs a value between 0 and 1 as a confidence level (e.g., 0.65). When the confidence level of the recognition result is lower than the preset value, it is considered that the current network feature data may not be sufficient to make a reliable judgment. At this time, a feature supplementation instruction is generated and sent to the SIP terminal through the signaling channel. This instruction may require the terminal to collect specific features at a higher frequency in a short period of time (e.g., sending probe packets intensively to more accurately measure port timeout). After the terminal executes the instruction, it reports the latest feature data. After receiving the latest feature data, the latest feature data can be merged with the original feature data, or the new data can be directly used for reprocessing and then input into the type recognition model again for inference. Because the input feature information is richer or more accurate, the rule type recognition result output by the model the second time is usually accompanied by a higher confidence level (e.g., 0.91). This result will be used as the updated rule type recognition result for subsequent policy generation. If the confidence level is still lower than the preset value, the feature supplementation step is repeated until the final confidence level meets the requirements.
[0038] Step S40: Send the penetration strategy to the communication terminal so that the communication terminal performs a penetration operation according to the penetration strategy.
[0039] It should be noted that after receiving the penetration policy, a specific execution logic of the SIP terminal is to send a "Binding Request" to the STUN server via the User Datagram Protocol (UDP), and after receiving the "Binding Response", extract the public IP and port, write the information into the "Contact" field of the SIP signaling, and then send it to the peer SIP terminal.
[0040] Send an "AddPortMapping" request to the NAT device via Simple Object Access Protocol (SOAP) to request port binding between "Private IP:5060" and "Public IP:12345". If an "AddPortMapping Response" is received with a status code of "200 OK", the mapping is confirmed to be successful. Send an "Allocate Request" to the designated TURN server, obtain the relay address, and then forward the SIP signaling and media stream to the TURN server, which will then relay them to the peer terminal. Send UDP keep-alive packets (empty packets, 16 bytes in length) to the NAT device at the period set by the policy (e.g., 40 seconds) to maintain the port mapping relationship.
[0041] This embodiment receives network feature data sent by a communication terminal; processes the network feature data using a type recognition model to obtain a rule type recognition result for network address translation (NAT). The type recognition model includes at least a local feature extraction unit and a temporal feature analysis unit; acquires server resource status data and historical penetration decisions; and generates a target penetration strategy based on real-time network status data, the rule type recognition result, the server resource status data, and the historical penetration decisions. The penetration strategy is then sent to the communication terminal so that the communication terminal performs a penetration operation according to the strategy. This embodiment improves the communication penetration success rate in NAT scenarios by receiving terminal network feature data, using a type recognition model with local and temporal analysis capabilities to accurately determine the NAT rule type, and dynamically generating and executing an optimal penetration strategy by integrating real-time network status, server resource status, and historical decisions.
[0042] Based on the first embodiment of this application, in the second embodiment of this application, the content that is the same as or similar to that in the first embodiment described above can be referred to the above description, and will not be repeated hereafter. Based on this, please refer to... Figure 2 Step S30 also includes steps S301 to S302: Step S301: Obtain a state vector based on the real-time network status data, the rule type identification result, and the server resource status data; It should be noted that real-time network status data can include parameters such as 20ms latency, 1% packet loss rate, and 120s port mapping timeout. Server resource status can include STUN server online rate and TURN server remaining bandwidth. Historical decision data includes penetration success rate and resource consumption data for the same NAT type and network status. Then, information from different dimensions is formatted, encoded, and concatenated. For example, real-time network status data is normalized into numerical values, rule type identification results are encoded into numerical results, and server resource status data is converted into utilization percentages. All these encoded data are then concatenated into a unified state vector that comprehensively describes the current system status.
[0043] Step S302: Use the penetration strategy decision model to evaluate and optimize the historical penetration decisions based on the state vector and the preset reward function to obtain the target penetration strategy.
[0044] It should be noted that the penetration strategy decision model can be an agent based on deep reinforcement learning. The model internally sets a pre-defined reward function, which defines the criteria for a good or bad decision, such as successful penetration (+10 points), no use of a TURN relay (+5 points), communication latency less than 50ms (+3 points); penetration failure (-20 points), use of a TURN relay (-3 points), premature invalidation of the mapping relationship (-10 points). For the current state vector, the model simulates and evaluates the cumulative rewards that various strategies (such as "using only STUN", "STUN+UPnP", "direct TURN") might bring in historical penetration decisions. Finally, the model selects or generates the strategy with the highest expected cumulative reward in the current state as the target penetration strategy output. An example of a final output penetration strategy is as follows: Prioritize sending STUN requests (frequency: 1 time / 30s) to obtain a public IP address and port; if the STUN request fails twice consecutively, trigger a Universal Plug and Play (UPnP) port mapping request (retry count: 3 times, interval 5s); if the UPnP request fails, enable TURN relay (select a TURN server with remaining bandwidth > 5Mbps); set the keep-alive packet period to 40s (1 / 3 of the port mapping timeout of 120s to avoid mapping failure).
[0045] In one feasible approach, after obtaining the target penetration strategy, the method further includes: receiving strategy execution result data returned by the communication terminal; and training the type identification model and the penetration strategy decision model based on the strategy execution result data to obtain the parameter-updated type identification model and penetration strategy decision model.
[0046] It should be noted that after the SIP terminal completes the penetration process, it will report the result data, including the penetration result (success / failure); the actual strategy used (e.g., STUN+UPnP); resource consumption (e.g., whether TURN relay was used, bandwidth usage); and communication quality (latency, packet loss rate, number of call interruptions). After receiving this data, model optimization can be performed. Specifically, the feedback data is stored in a database, and incremental training of the type recognition model and penetration strategy decision model is performed periodically (e.g., every early morning).
[0047] For type recognition models, newly labeled network feature data (such as feature samples of symmetric NAT) can be used to adjust the parameters of CNN and LSTM, thereby improving recognition confidence. For penetration policy decision models, the experience pool of reinforcement learning can be updated, the reward function weights can be retrained, and the policy selection logic can be optimized (such as adjusting the number of UPnP request retries for a specific vendor's NAT device).
[0048] This embodiment obtains a state vector based on the real-time network status data, the rule type identification result, and the server resource status data. A penetration strategy decision model is then used to evaluate and optimize historical penetration decisions based on the state vector and a preset reward function to obtain the target penetration strategy. This embodiment comprehensively encodes real-time network status, accurately identified NAT rule types, and server resource status into a unified state vector, and uses a preset reward function to automatically evaluate and optimize historical penetration decisions under this state vector. This dynamically generates penetration strategies that match the current complex network environment and resource conditions, thereby improving the communication penetration success rate in Network Address Translation (NAT) scenarios.
[0049] This application also provides a communication penetration device for network address translation scenarios; please refer to [reference needed]. Figure 3 The communication penetration device for the network address translation scenario includes: The receiving module 10 is used to receive network characteristic data sent by the communication terminal; The identification module 20 is used to process the network feature data using a type identification model to obtain the rule type identification result of network address translation. The type identification model includes at least a local feature extraction unit and a temporal feature analysis unit. The generation module 30 is used to acquire server resource status data and historical penetration decisions, and generate a target penetration strategy based on the real-time network status data in the network feature data, the rule type identification result, the server resource status data and the historical penetration decisions; The sending module 40 is used to send the penetration strategy to the communication terminal so that the communication terminal can perform a penetration operation according to the penetration strategy.
[0050] This embodiment receives network feature data sent by a communication terminal; processes the network feature data using a type recognition model to obtain a rule type recognition result for network address translation (NAT). The type recognition model includes at least a local feature extraction unit and a temporal feature analysis unit; acquires server resource status data and historical penetration decisions; and generates a target penetration strategy based on real-time network status data, the rule type recognition result, the server resource status data, and the historical penetration decisions. The penetration strategy is then sent to the communication terminal so that the communication terminal performs a penetration operation according to the strategy. This embodiment improves the communication penetration success rate in NAT scenarios by receiving terminal network feature data, using a type recognition model with local and temporal analysis capabilities to accurately determine the NAT rule type, and dynamically generating and executing an optimal penetration strategy by integrating real-time network status, server resource status, and historical decisions.
[0051] In one embodiment, the recognition module 20 is further configured to use the local feature extraction unit of the type recognition model to extract local feature vectors from the network feature data; use the temporal feature analysis unit of the type recognition model to analyze the local feature vectors and the temporal information in the network feature data to obtain sequence feature vectors; and generate rule type recognition results based on the local feature vectors and the sequence feature vectors.
[0052] In one embodiment, the generation module 30 is further configured to obtain a state vector based on the real-time network status data, the rule type identification result, and the server resource status data; and to use a penetration strategy decision model to evaluate and optimize the historical penetration decisions based on the state vector and a preset reward function to obtain a target penetration strategy.
[0053] In one embodiment, the generation module 30 is further configured to receive policy execution result data returned by the communication terminal; and to train the type identification model and the penetration policy decision model based on the policy execution result data to obtain the parameter-updated type identification model and penetration policy decision model.
[0054] In one embodiment, the generation module 30 is further configured to send a status query request to the address discovery server and receive load information data returned by the address discovery server; send a resource query request to the data relay server and receive available bandwidth information data returned by the data relay server; and retrieve historical penetration decisions from the policy database based on the rule type identification result.
[0055] In one embodiment, the generation module 30 is further configured to obtain the confidence level of the rule type recognition result output by the type recognition model; when the confidence level is less than a preset value, send a feature supplementation instruction to the communication terminal and receive the latest feature data sent by the communication terminal; process the latest feature data to obtain an updated rule type recognition result.
[0056] In one embodiment, the receiving module 10 is further configured to detect whether there is any missing data in the network feature data; if so, the missing value is filled in the network feature data to obtain complete network feature data.
[0057] The communication penetration device for network address translation scenarios provided in this application, employing the communication penetration method for network address translation scenarios described in the above embodiments, can solve the technical problem of how to improve the success rate of communication penetration in network address translation scenarios. Compared with the prior art, the beneficial effects of the communication penetration device for network address translation scenarios provided in this application are the same as those of the communication penetration method for network address translation scenarios provided in the above embodiments, and other technical features in the communication penetration device for network address translation scenarios are the same as those disclosed in the methods of the above embodiments, and will not be repeated here.
[0058] This application provides a communication penetration device for a network address translation scenario. The communication penetration device for a network address translation scenario 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, and the instructions are executed by the at least one processor to enable the at least one processor to execute the communication penetration method for a network address translation scenario in the above embodiment 1.
[0059] The following is for reference. Figure 4 This document illustrates a schematic diagram of a communication penetration device suitable for implementing network address translation scenarios in the embodiments of this application. The communication penetration device for network address translation scenarios in the embodiments of this application may include, but is not limited to, mobile terminals such as mobile phones, laptops, digital broadcast receivers, PDAs (Personal Digital Assistants), PADs (Portable Application Description), PMPs (Portable Media Players), in-vehicle terminals (e.g., in-vehicle navigation terminals), and fixed terminals such as digital TVs and desktop computers. Figure 4 The communication penetration device shown in the network address translation scenario is merely an example and should not impose any limitations on the functionality and scope of use of the embodiments of this application.
[0060] like Figure 4 As shown, the communication tunneling device in a network address translation scenario may include a processing unit 1001 (e.g., a central processing unit, a graphics processing unit, etc.), which can perform various appropriate actions and processes according to a program stored in ROM (Read Only Memory) 1002 or a program loaded from storage device 1003 into RAM (Random Access Memory) 1004. RAM 1004 also stores various programs and data required for the operation of the communication tunneling device in a network address translation scenario. The processing unit 1001, ROM 1002, and RAM 1004 are interconnected via bus 1005. Input / output (I / O) interface 1006 is also connected to the bus. Typically, the following systems can be connected to I / O interface 1006: input devices 1007 including, for example, touchscreens, touchpads, keyboards, mice, image sensors, microphones, accelerometers, gyroscopes, etc.; output devices 1008 including, for example, liquid crystal displays (LCDs), speakers, vibrators, etc.; storage devices 1003 including, for example, magnetic tapes, hard disks, etc.; and communication devices 1009. Communication device 1009 allows the communication penetration device in a network address translation scenario to exchange data wirelessly or via wired communication with other devices. Although a communication penetration device in a network address translation scenario with various systems is shown in the figure, it should be understood that it is not required to implement or possess all the systems shown. More or fewer systems can be implemented alternatively.
[0061] Specifically, according to the embodiments disclosed in this application, the processes described above with reference to the flowcharts can be implemented as computer software programs. For example, embodiments disclosed in this application include a computer program product comprising a computer program carried on a computer-readable medium, the computer program containing program code for performing the methods shown in the flowcharts. In such embodiments, the computer program can be downloaded and installed from a network via a communication device, or installed from storage device 1003, or installed from ROM 1002. When the computer program is executed by processing device 1001, it performs the functions defined in the methods of the embodiments disclosed in this application.
[0062] The communication penetration device for network address translation scenarios provided in this application, employing the communication penetration method for network address translation scenarios described in the above embodiments, can solve the technical problem of how to improve the success rate of communication penetration in network address translation scenarios. Compared with the prior art, the beneficial effects of the communication penetration device for network address translation scenarios provided in this application are the same as those of the communication penetration method for network address translation scenarios provided in the above embodiments, and other technical features in this communication penetration device for network address translation scenarios are the same as those disclosed in the method of the previous embodiment, and will not be repeated here.
[0063] It should be understood that the various parts disclosed in this application can be implemented using hardware, software, firmware, or a combination thereof. In the description of the above embodiments, specific features, structures, materials, or characteristics can be combined in any suitable manner in one or more embodiments or examples.
[0064] The above description is merely a specific embodiment of this application, but the scope of protection of this application is not limited thereto. Any variations or substitutions that can be easily conceived by those skilled in the art within the scope of the technology disclosed in this application should be included within the scope of protection of this application. Therefore, the scope of protection of this application should be determined by the scope of the claims.
[0065] This application provides a computer-readable storage medium having computer-readable program instructions (i.e., a computer program) stored thereon, which are used to execute the communication penetration method for the network address translation scenario in the above embodiments.
[0066] The computer-readable storage medium provided in this application may be, for example, a USB flash drive, but is not limited to, electrical, magnetic, optical, electromagnetic, infrared, or semiconductor systems, devices, or any combination thereof. More specific examples of computer-readable storage media may include, but are not limited to: electrical connections having one or more wires, portable computer disks, hard disks, random access memory (RAM), read-only memory (ROM), erasable programmable read-only memory (EPROM or flash memory), optical fiber, portable compact disk read-only memory (CD-ROM), optical storage devices, magnetic storage devices, or any suitable combination thereof. In this embodiment, the computer-readable storage medium may be any tangible medium containing or storing a program that can be used by or in conjunction with an instruction execution system, system, or device. The program code contained on the computer-readable storage medium may be transmitted using any suitable medium, including but not limited to: wires, optical cables, RF (Radio Frequency), etc., or any suitable combination thereof.
[0067] The aforementioned computer-readable storage medium may be included in a communication penetration device for a network address translation scenario; or it may exist independently and not be assembled into a communication penetration device for a network address translation scenario.
[0068] The aforementioned computer-readable storage medium carries one or more programs. When these programs are executed by a communication penetration device in a network address translation (NAT) scenario, the communication penetration device in the NAT scenario: receives network feature data sent by a communication terminal; processes the network feature data using a type recognition model to obtain a rule type recognition result for NAT, wherein the type recognition model includes at least a local feature extraction unit and a temporal feature analysis unit; acquires server resource status data and historical penetration decisions; generates a target penetration strategy based on real-time network status data in the network feature data, the rule type recognition result, the server resource status data, and the historical penetration decisions; and distributes the penetration strategy to the communication terminal so that the communication terminal performs a penetration operation according to the penetration strategy.
[0069] Computer program code for performing the operations of this application can be written in one or more programming languages or a combination thereof, including object-oriented programming languages such as Java, Smalltalk, and C++, and conventional procedural programming languages such as the "C" language or similar programming languages. The program code can be executed entirely on the user's computer, partially on the user's computer, as a standalone software package, partially on the user's computer and partially on a remote computer, or entirely on a remote computer or server. In cases involving remote computers, the remote computer can be connected to the user's computer via any type of network—including a Local Area Network (LAN) or a Wide Area Network (WAN)—or can be connected to an external computer (e.g., via the Internet using an Internet service provider).
[0070] The flowcharts and block diagrams in the accompanying drawings illustrate the architecture, functionality, and operation of possible implementations of systems, methods, and computer program products according to various embodiments of this application. In this regard, each block in a flowchart or block diagram may represent a module, segment, or portion of code containing one or more executable instructions for implementing a specified logical function. It should also be noted that in some alternative implementations, the functions indicated in the blocks may occur in a different order than those indicated in the drawings. For example, two consecutively indicated blocks may actually be executed substantially in parallel, and they may sometimes be executed in reverse order, depending on the functions involved. It should also be noted that each block in the block diagrams and / or flowcharts, and combinations of blocks in the block diagrams and / or flowcharts, can be implemented using a dedicated hardware-based system that performs the specified function or operation, or using a combination of dedicated hardware and computer instructions.
[0071] The modules described in the embodiments of this application can be implemented in software or hardware. The names of the modules do not necessarily limit the functionality of the unit itself.
[0072] The readable storage medium provided in this application is a computer-readable storage medium that stores computer-readable program instructions (i.e., a computer program) for executing the communication traversal method in the above-described network address translation scenario, thereby solving the technical problem of how to improve the success rate of communication traversal in network address translation scenarios. Compared with the prior art, the beneficial effects of the computer-readable storage medium provided in this application are the same as the beneficial effects of the communication traversal method in the network address translation scenario provided in the above embodiments, and will not be repeated here.
[0073] This application also provides a computer program product, including a computer program that, when executed by a processor, implements the steps of the communication traversal method for the network address translation scenario described above.
[0074] The computer program product provided in this application can solve the technical problem of how to improve the success rate of communication penetration in network address translation scenarios. Compared with the prior art, the beneficial effects of the computer program product provided in this application are the same as the beneficial effects of the communication penetration method in network address translation scenarios provided in the above embodiments, and will not be repeated here.
[0075] The above description is only a part of the embodiments of this application and does not limit the patent scope of this application. All equivalent structural transformations made under the technical concept of this application and using the contents of the specification and drawings of this application, or direct / indirect applications in other related technical fields, are included in the patent protection scope of this application.
Claims
1. A communication penetration method for a network address translation scenario, characterized in that, The method includes: Receive network characteristic data sent by the communication terminal; The network feature data is processed using a type recognition model to obtain the rule type recognition result of network address translation. The type recognition model includes at least a local feature extraction unit and a temporal feature analysis unit. Obtain server resource status data and historical penetration decisions, and generate a target penetration strategy based on real-time network status data in the network feature data, the rule type identification result, the server resource status data, and the historical penetration decisions; The penetration strategy is sent to the communication terminal so that the communication terminal performs a penetration operation according to the penetration strategy.
2. The method as described in claim 1, characterized in that, The step of processing the network feature data using a type recognition model to obtain the rule type recognition result for network address translation includes: Local feature vectors are extracted from the network feature data using the local feature extraction unit of the type recognition model. The temporal feature analysis unit of the type recognition model is used to analyze the local feature vector and the temporal information in the network feature data to obtain the sequence feature vector; Based on the local feature vector and the sequence feature vector, a rule type recognition result is generated.
3. The method as described in claim 1, characterized in that, The step of generating a target penetration strategy based on the real-time network status data in the network feature data, the rule type identification result, the server resource status data, and the historical penetration decision includes: A state vector is obtained based on the real-time network status data, the rule type identification result, and the server resource status data; The penetration strategy decision model is used to evaluate and optimize the historical penetration decisions based on the state vector and the preset reward function to obtain the target penetration strategy.
4. The method as described in claim 3, characterized in that, After obtaining the target penetration strategy, the method further includes: Receive the policy execution result data returned by the communication terminal; The type recognition model and the penetration strategy decision model are trained based on the strategy execution result data to obtain the updated type recognition model and penetration strategy decision model.
5. The method as described in claim 1, characterized in that, The server resource status data includes load information data and available bandwidth information data. The steps for obtaining server resource status data and historical penetration decisions include: Send a status query request to the address discovery server and receive the load information data returned by the address discovery server; Send a resource query request to the data relay server and receive available bandwidth information data returned by the data relay server; Historical penetration decisions are retrieved from the policy database based on the rule type identification results.
6. The method as described in claim 1, characterized in that, After the step of processing the network feature data using a type recognition model to obtain the rule type recognition result for network address translation, the method further includes: Obtain the confidence level of the rule type identification result output by the type identification model; When the confidence level is less than a preset value, a feature supplementation instruction is sent to the communication terminal, and the latest feature data sent by the communication terminal is received. The latest feature data is processed to obtain updated rule type identification results.
7. The method as described in claim 1, characterized in that, After the step of receiving network feature data sent by the communication terminal, the method further includes: Detect whether the network feature data has any missing data; If missing values exist, the network feature data is filled with missing values to obtain complete network feature data.
8. A communication penetration device for network address translation scenarios, characterized in that, The device includes: The receiving module is used to receive network characteristic data sent by the communication terminal; The identification module is used to process the network feature data using a type identification model to obtain the rule type identification result of network address translation. The type identification model includes at least a local feature extraction unit and a temporal feature analysis unit. The generation module is used to acquire server resource status data and historical penetration decisions, and generate a target penetration strategy based on the real-time network status data in the network feature data, the rule type identification result, the server resource status data, and the historical penetration decisions. The distribution module is used to distribute the penetration strategy to the communication terminal so that the communication terminal can perform a penetration operation according to the penetration strategy.
9. A communication penetration device for network address translation scenarios, characterized in that, The device includes: a memory, a processor, and a computer program stored in the memory and executable on the processor, the computer program being configured to implement the steps of the communication traversal method for a network address translation scenario as described in any one of claims 1 to 7.
10. A storage medium, characterized in that, The storage medium is a computer-readable storage medium, and a computer program is stored on the storage medium. When the computer program is executed by a processor, it implements the communication penetration method for the network address translation scenario as described in any one of claims 1 to 7.