CN111371909B - Method and system for realizing 4in6DS Lite data stream forwarding - Google Patents

Method and system for realizing 4in6DS Lite data stream forwarding Download PDF

Info

Publication number
CN111371909B
CN111371909B CN201811593559.4A CN201811593559A CN111371909B CN 111371909 B CN111371909 B CN 111371909B CN 201811593559 A CN201811593559 A CN 201811593559A CN 111371909 B CN111371909 B CN 111371909B
Authority
CN
China
Prior art keywords
hard acceleration
ipv4
message
entry
acceleration entry
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active
Application number
CN201811593559.4A
Other languages
Chinese (zh)
Other versions
CN111371909A (en
Inventor
朱圣东
袁开心
夏刚
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Sanechips Technology Co Ltd
Original Assignee
Sanechips Technology Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Sanechips Technology Co Ltd filed Critical Sanechips Technology Co Ltd
Priority to CN201811593559.4A priority Critical patent/CN111371909B/en
Priority to PCT/CN2019/128195 priority patent/WO2020135479A1/en
Publication of CN111371909A publication Critical patent/CN111371909A/en
Application granted granted Critical
Publication of CN111371909B publication Critical patent/CN111371909B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L61/00Network arrangements, protocols or services for addressing or naming
    • H04L61/09Mapping addresses
    • H04L61/25Mapping addresses of the same type
    • H04L61/2503Translation of Internet protocol [IP] addresses
    • H04L61/2592Translation of Internet protocol [IP] addresses using tunnelling or encapsulation
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L45/00Routing or path finding of packets in data switching networks
    • H04L45/74Address processing for routing
    • H04L45/741Routing in networks with a plurality of addressing schemes, e.g. with both IPv4 and IPv6
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L61/00Network arrangements, protocols or services for addressing or naming
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L2101/00Indexing scheme associated with group H04L61/00
    • H04L2101/60Types of network addresses
    • H04L2101/686Types of network addresses using dual-stack hosts, e.g. in Internet protocol version 4 [IPv4]/Internet protocol version 6 [IPv6] networks

Landscapes

  • Engineering & Computer Science (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Signal Processing (AREA)
  • Data Exchanges In Wide-Area Networks (AREA)

Abstract

The invention discloses a method and a system for realizing 4in6DS Lite data stream forwarding, wherein the method comprises the following steps: receiving an IPv4 message from a Local Area Network (LAN); judging whether a hard acceleration entry exists or not; if a hard acceleration entry exists and the IPv4 message is matched with the hard acceleration entry, the IPv4 message is packaged into an IPv6 message according to the hard acceleration entry and then sent out from a Wide Area Network (WAN); if no hard acceleration entry exists, the hard acceleration entry is generated in the process of encapsulating the IPv4 message from the LAN into an IPv6 message through a protocol stack and sending out from the wide area network WAN. The invention can improve the forwarding efficiency of the 4in6DS Lite data stream.

Description

Method and system for realizing 4in6DS Lite data stream forwarding
Technical Field
The invention relates to an IPv 4in IPv6 tunnel data transmission technology, in particular to a method and a system for realizing 4in6DS Lite data stream forwarding.
Background
Because of the problems of limited application layer software or terminal hardware and the like, a fourth version IPv4 user of the Internet Protocol (IP) cannot be upgraded to the sixth version IPv6 of the Internet Protocol in a large scale in a short time, and most networks such as Internet Content Providers (ICPs) have no intention of upgrading to IPv6, and the main traffic in the network will still be IPv4-in-IPv4 traffic for a long time in the future. Based on rational observation of the development relationship between IPv4 and IPv6, the DS Lite (Dual-Stack Lite) scheme is provided for realizing IPv4 service continuation and promoting IPv6 deployment.
The essence of the DS Lite technology is that an IPv4-in-IPv6 tunnel is deployed in an IPv6 network to complete IPv4 service transmission, and IPv6 service is directly transmitted through an IPv6 network. The current network device processes 4in6DS Lite data (here and hereafter, 4in6DS Lite data refers to data packets transmitted under IPv4-in-IPv6 (generally referred to as 4in6 in the art)) mainly through a kernel complex protocol stack processing flow: the IPv4 message enters the gateway and is sent to the third layer after being processed by the second layer bridge, the DS Lite is found out, and the IPv4 message and the IPv6 header are forwarded out. The method has low forwarding efficiency, occupies a large amount of CPU resources and influences other normal service operation.
Disclosure of Invention
In order to solve the technical problem, the invention provides a method and a system for realizing the 4in6DS Lite data stream forwarding, which can improve the forwarding efficiency of the 4in6DS Lite data stream.
In order to achieve the purpose of the invention, the invention provides a method for realizing IPv4-in-IPv 6DS Lite data stream forwarding, which comprises the following steps:
receiving an IPv4 message from a Local Area Network (LAN);
judging whether a hard acceleration entry exists or not;
if a hard acceleration entry exists and the IPv4 message is matched with the hard acceleration entry, the IPv4 message is packaged into an IPv6 message according to the hard acceleration entry and then sent out from a Wide Area Network (WAN);
if no hard acceleration entry exists, the hard acceleration entry is generated in the process of encapsulating the IPv4 message from the LAN into an IPv6 message through a protocol stack and sending out from the wide area network WAN.
As an implementation, the method further comprises:
after receiving an IPv4 message from a Local Area Network (LAN), counting the number of messages entering an IPv4-in-IPv6 tunnel transmission, and if the number of the messages entering the IPv4-in-IPv6 tunnel transmission is larger than or equal to a preset value, judging whether a hard acceleration item exists;
if no hard acceleration item exists, generating a hard acceleration item in the process of encapsulating the IPv4 message from the LAN into an IPv6 message through a protocol stack and sending the IPv6 message from the WAN;
and if the hard acceleration entry exists and the IPv4 message is matched with the hard acceleration entry, encapsulating the IPv4 message into an IPv6 message according to the hard acceleration entry and then sending the IPv6 message out of a Wide Area Network (WAN).
As an implementation, the method further comprises:
when a hard acceleration entry exists, judging whether the existing hard acceleration entry is used in a preset time period T1, if not, updating the life cycle of the hard acceleration entry to the value obtained by subtracting T1 from the existing life cycle of the hard acceleration entry, and if the life cycle of the updated hard acceleration entry reaches the aging time of the hard acceleration entry, deleting the hard acceleration entry, wherein the initial life cycle of the hard acceleration entry is greater than or equal to the preset time period T1.
As an implementation, the method further comprises:
when a hard acceleration entry exists and the hard acceleration entry is used in the preset time period, updating the life cycle of the hard acceleration entry to the aging time of the hard acceleration entry, and deleting the hard acceleration entry when the hard acceleration strip time is reached.
As an implementation, the method further comprises:
and if the number of the received messages is less than the preset value, the hard acceleration entries exist, and the existing hard acceleration entries are deleted.
The embodiment of the invention also provides a system for realizing IPv4-in-IPv 6DS Lite data stream forwarding, which comprises:
the message receiving module is used for receiving the IPv4 message from the Local Area Network (LAN);
the hard acceleration module is used for judging whether a hard acceleration item exists or not, if the hard acceleration item exists and the IPv4 message is matched with the hard acceleration item, the IPv4 message is packaged into an IPv6 message according to the hard acceleration item and then sent out from a Wide Area Network (WAN); if no hard acceleration entry exists, the hard acceleration entry is generated in the process of encapsulating the IPv4 message from the LAN into an IPv6 message through a protocol stack and sending out from the wide area network WAN.
As an implementation manner, the hard acceleration module is further configured to count the number of packets entering the IPv4-in-IPv6 tunnel transmission after the packet receiving module receives an IPv4 packet from the local area network LAN, and determine whether a hard acceleration entry exists if the number of packets entering the IPv4-in-IPv6 tunnel transmission is greater than or equal to a preset value; if no hard acceleration item exists, generating a hard acceleration item in the process of encapsulating the IPv4 message from the LAN into an IPv6 message through a protocol stack and sending the IPv6 message from the WAN; and if the hard acceleration entry exists and the IPv4 message is matched with the hard acceleration entry, encapsulating the IPv4 message into an IPv6 message according to the hard acceleration entry and then sending the IPv6 message out of a Wide Area Network (WAN).
In one implementation, the hard acceleration module is further configured to determine whether a hard acceleration entry exists and is used within a preset time period T1, if the hard acceleration entry does not exist, update the lifetime of the hard acceleration entry to the value obtained by subtracting T1 from the existing lifetime of the hard acceleration entry, and delete the hard acceleration entry if the lifetime of the updated hard acceleration entry reaches the aging time of the updated hard acceleration entry, where the initial lifetime of the hard acceleration entry is greater than or equal to the preset time period T1.
In one implementation, the hard acceleration module is further configured to update a life cycle of the hard acceleration entry to an aging time thereof when the hard acceleration entry exists and is used within the preset time period, and delete the hard acceleration entry when the hard acceleration leveling time arrives.
As an implementation manner, the hard acceleration module is further configured to delete a hard acceleration entry if the number of received packets is smaller than a preset value.
Embodiments of the present invention further provide a computer-readable storage medium, where the medium stores computer-executable instructions, and the computer-executable instructions, when executed by a processor, implement the steps of the method for implementing IPv4-in-IPv 6DS Lite data stream forwarding described in the foregoing embodiments.
The embodiment of the invention also provides a terminal for realizing IPv4-in-IPv 6DS Lite data stream forwarding, which comprises:
a memory for storing computer executable instructions;
a processor for executing the computer-executable instructions to implement the steps of the method for implementing IPv4-in-IPv 6DS Lite data stream forwarding as described in the previous embodiments
Compared with the prior art, the invention comprises the following steps: receiving an IPv4 message from a Local Area Network (LAN); judging whether a hard acceleration entry exists or not; if a hard acceleration entry exists and the IPv4 message is matched with the hard acceleration entry, the IPv4 message is packaged into an IPv6 message according to the hard acceleration entry and then sent out from a Wide Area Network (WAN); if no hard acceleration entry exists, the hard acceleration entry is generated in the process of encapsulating the IPv4 message from the LAN into an IPv6 message through a protocol stack and sending out from the wide area network WAN. The invention can improve the forwarding efficiency of the 4in6DS Lite data stream.
Additional features and advantages of the invention will be set forth in the description which follows, and in part will be obvious from the description, or may be learned by practice of the invention. The objectives and other advantages of the invention will be realized and attained by the structure particularly pointed out in the written description and claims hereof as well as the appended drawings.
Drawings
The accompanying drawings are included to provide a further understanding of the invention and are incorporated in and constitute a part of this specification, illustrate embodiments of the invention and together with the example serve to explain the principles of the invention and not to limit the invention.
Fig. 1 is a schematic diagram of a conventional 4in6DS Lite data message forwarding flow;
fig. 2 is a flowchart of a method for implementing 4in6DS Lite data stream forwarding according to an embodiment of the present invention;
fig. 3 is a flowchart for implementing 4in6DS Lite data stream forwarding according to another embodiment of the present invention;
fig. 4 is a block diagram of a system for implementing 4in6DS Lite data stream forwarding according to an embodiment of the present invention.
Detailed Description
In order to make the objects, technical solutions and advantages of the present invention more apparent, embodiments of the present invention will be described in detail below with reference to the accompanying drawings. It should be noted that the embodiments and features of the embodiments in the present application may be arbitrarily combined with each other without conflict.
The steps illustrated in the flow charts of the figures may be performed in a computer system such as a set of computer-executable instructions. Also, while a logical order is shown in the flow diagrams, in some cases, the steps shown or described may be performed in an order different than here.
Fig. 1 is a schematic diagram of a conventional 4in6DS Lite data packet forwarding process, and as shown in fig. 1, after a 4in6DS Lite data packet is sent to a CPU, the data packet is forwarded to hardware through a complex protocol stack processing process, where the specific process is as follows:
the message enters a packet processing module from the LAN side, and the packet processing module sends the message to a CPU;
after the packet is received by the CPU packet receiving module, the message is sent to the Br bridge processing module;
the Br bridge processing module receives the message and sends the message to the three-layer V4 processing module;
the V4 processing module processes the IPv4 message, searches an IPv4 route and sends the IPv4 route to the 4in6 tunnel interface;
the V6 tunnel processing module encapsulates an IPv4 message into an IPv6 header, enters an IPv6 protocol stack flow, performs IPv6 routing query, and sends an IPv6 message to the WAN processing module;
the WAN processing module searches for a WAN side outlet, adds a corresponding VLAN, and sends an IPv6 message to the packet processing module;
the packet processing module sends the message out from the WAN side;
the WAN side reply message is processed similarly, the difference is that the process enters IPv6 flow, strips off IPv6 head, enters IPv4 flow and finally returns to the LAN side.
Because the above-mentioned data message forwarding mode is inefficient, occupies a large amount of CPU resources of the central processing unit, and affects other normal service operations, an embodiment of the present invention provides a method for implementing 4in6DS Lite data stream forwarding, as shown in fig. 2, the method includes:
s201, receiving an IPv4 message from a Local Area Network (LAN);
s201, judging whether a hard acceleration item exists or not;
s203, if a hard acceleration entry exists and the IPv4 message is matched with the hard acceleration entry, the IPv4 message is packaged into an IPv6 message according to the hard acceleration entry and then sent out from a Wide Area Network (WAN), and the process is finished;
s204, if no hard acceleration item exists, generating the hard acceleration item in the process of encapsulating the IPv4 message from the LAN into an IPv6 message through a protocol stack and sending out the IPv6 message from the WAN.
Because hardware resources are precious, hard acceleration items cannot be configured without limit, the number of the hard acceleration items is limited, the embodiment of the invention can count the number of messages entering 4in6 tunnel transmission after receiving the IPv4 message from the Local Area Network (LAN), and the hard acceleration items are configured only if the number of the messages entering 4in6 tunnel transmission is larger than or equal to a preset value. The number of messages entering the 4in6 tunnel may be the number of messages per SECOND tunneled at 4in6, PPS (PACKET PER SECOND), and a PPS THRESHOLD is set, for example, the PPS _ THRESHOLD is 20, that is, 20 or more messages per SECOND are tunneled at 4in6, and then a hard acceleration entry is configured. As an implementation manner, the method specifically includes:
after receiving an IPv4 message from a Local Area Network (LAN), counting the number of messages entering 4in6 tunnel transmission, and if the number of the messages entering 4in6 tunnel transmission is larger than or equal to a preset value, judging whether a hard acceleration item exists;
if no hard acceleration item exists, generating a hard acceleration item in the process of encapsulating the IPv4 message from the LAN into an IPv6 message through a protocol stack and sending the IPv6 message from the WAN;
and if the hard acceleration entry exists and the IPv4 message is matched with the hard acceleration entry, encapsulating the IPv4 message into an IPv6 message according to the hard acceleration entry and then sending the IPv6 message out of a Wide Area Network (WAN).
As an implementation, the method further comprises:
and if the number of the received messages is less than the preset value, the hard acceleration entries exist, and the existing hard acceleration entries are deleted.
The method can realize the dynamic allocation of hard acceleration resources, achieve the effect that the flow meeting a certain speed enters acceleration, and improve the utilization rate of hard acceleration items.
In addition, due to limited hard acceleration resources, the acceleration entries need to be periodically refreshed to remove unused entries. As an implementation manner, the method further includes:
when a hard acceleration entry exists, judging whether the existing hard acceleration entry is used within a preset time period T1, if not, updating the life cycle of the hard acceleration entry to the value obtained by subtracting T1 from the existing life cycle, and if the life cycle of the updated hard acceleration entry reaches the aging time of the hard acceleration entry, deleting the hard acceleration entry;
when a hard acceleration entry exists and the hard acceleration entry is used within a preset time period, updating the life cycle of the hard acceleration entry to the aging time of the hard acceleration entry, and deleting the hard acceleration entry when the hard acceleration aging time arrives
The initial life cycle of the hard acceleration entry is greater than or equal to the preset time period T1.
Fig. 3 is a schematic diagram of another implementation of the 4in6DS Lite data stream forwarding according to an embodiment of the present invention.
Firstly, after receiving an IPv4 message from a Local Area Network (LAN), counting PPS;
and when the PPS is larger than or equal to a preset value, if no hard acceleration item exists, generating the hard acceleration item in the process of encapsulating the IPv4 message from the LAN into an IPv6 message through a protocol stack and sending the IPv6 message out of the WAN. Judging whether the generated hard acceleration entry is used in a preset time period T1, if not, updating the life cycle of the hard acceleration entry to the value obtained by subtracting T1 from the existing life cycle, and if the life cycle of the updated hard acceleration entry reaches the aging time of the updated hard acceleration entry, deleting the hard acceleration entry; and if the generated hard acceleration entry is used within a preset time period, updating the life cycle of the hard acceleration entry to the aging time of the hard acceleration entry, and deleting the hard acceleration entry when the hard acceleration strip time is reached, wherein the initial life cycle of the hard acceleration entry is greater than or equal to the preset time T1.
And if the PPS is smaller than the preset value and the hard acceleration entry exists, deleting the existing hard acceleration entry.
The following describes an embodiment of the present invention, taking the LAN-side terminal 192.168.1.3 accessing the remote host 10.30.1.61 as an example.
First, the processing flow of the connection establishment phase (three-way handshake for TCP, first packet for UDP) is as follows:
establishing IPv6 connection and a DS Lite tunnel, acquiring that a local IP and a remote IP are 2000::31, 3000: 21 respectively, and configuring an IPv4 address 192.0.0.2 for the tunnel;
IPv4 message enters into packet processing module from LAN side, the packet processing module sends the message to CPU;
after the packet is received by the CPU packet receiving module, the message is sent to the Br bridge processing module;
the Br bridge processing module receives the message and sends the message to the three-layer V4 processing module;
the V4 processing module processes the IPv4 message, searches an IPv4 route and sends the IPv4 route to the 4in6 tunnel interface;
the V6 tunnel processing module encapsulates an IPv4 message into an IPv6 header, at the moment, the data message 192.168.1.3- >10.30.1.61 is encapsulated into the message of 2000::31- >3000::21, enters an IPv6 protocol stack flow, carries out IPv6 routing query, and records IPv6 address information in the generated hard acceleration entry; sending the IPv6 message to a WAN processing module;
the WAN processing module searches for a WAN side outlet, adds a corresponding VLAN, sends an IPv6 message to the packet processing module, and records VLAN information in the hard acceleration entry;
the packet processing module sends the message out from the WAN side;
the WAN side reply message is processed similarly, the difference is that the process enters IPv6 flow, strips off IPv6 head, enters IPv4 flow and finally returns to the LAN side.
After the hard acceleration item is established, the specific steps are as follows:
the message enters a packet processing module from the LAN side;
the packet processing module extracts message five-tuple information (source IP, destination IP, source PORT, destination PORT, protocol) as MATCH information to perform hard acceleration entry query;
hitting a hard acceleration entry, acquiring TARGET information, and adding an IPv6 head, a VLAN label and the like;
the packet processing module sends the encapsulated IPv6 message out from the WAN side;
the reply message enters a packet processing module from the WAN side, the packet processing module extracts message quintuple information (source IP, destination IP, source PORT, destination PORT and protocol) as MATCH information to carry out accelerated entry query, and the source IP and the destination IP are IPv6 information at the moment;
hitting the acceleration entry, acquiring TARGET information, and stripping an IPv6 head, a VLAN label and the like;
the packet processing module sends the message out from the LAN side.
The embodiment of the present invention further provides a system for implementing IPv4-in-IPv 6DS Lite data stream forwarding, as shown in fig. 4, including:
a message receiving module 401, configured to receive an IPv4 message from a local area network LAN;
a hard acceleration module 402, configured to determine whether a hard acceleration entry exists, and if a hard acceleration entry exists and the IPv4 packet matches the hard acceleration entry, encapsulate the IPv4 packet into an IPv6 packet according to the hard acceleration entry and send the IPv6 packet out of a wide area network WAN; if no hard acceleration entry exists, the hard acceleration entry is generated in the process of encapsulating the IPv4 message from the LAN into an IPv6 message through a protocol stack and sending out from the wide area network WAN.
Since hardware resources are precious, hard acceleration entries cannot be configured without limit, the number of the hard acceleration entries is limited, as an implementation manner, the hard acceleration module 402 is further configured to count the number of packets entering the IPv4-in-IPv6 tunnel transmission after the packet receiving module 401 receives an IPv4 packet from the local area network LAN, and determine whether a hard acceleration entry exists if the number of packets entering the IPv4-in-IPv6 tunnel transmission is greater than or equal to a preset value; if no hard acceleration item exists, generating a hard acceleration item in the process of encapsulating the IPv4 message from the LAN into an IPv6 message through a protocol stack and sending the IPv6 message from the WAN; and if the hard acceleration entry exists and the IPv4 message is matched with the hard acceleration entry, encapsulating the IPv4 message into an IPv6 message according to the hard acceleration entry and then sending the IPv6 message out of a Wide Area Network (WAN). The number of messages entering the 4in6 tunnel may be the number of messages per SECOND tunneled at 4in6, PPS (PACKET PER SECOND), and a PPS THRESHOLD is set, for example, the PPS _ THRESHOLD is 20, that is, 20 or more messages per SECOND are tunneled at 4in6, and then a hard acceleration entry is configured.
As an implementation manner, the hard acceleration module 402 is further configured to delete a hard acceleration entry if the number of received packets is smaller than a preset value.
The method can realize the dynamic allocation of hard acceleration resources, achieve the effect that the flow meeting a certain speed enters acceleration, and improve the utilization rate of hard acceleration items.
In addition, due to limited hard acceleration resources, the acceleration entries need to be periodically refreshed to remove unused entries. In one implementation, the hard acceleration module 402 is further configured to determine whether a hard acceleration entry exists, when the hard acceleration entry exists, the existing hard acceleration entry is used within a preset time period T1, if the existing hard acceleration entry is not used, update the lifetime of the hard acceleration entry to the value obtained by subtracting T1 from the existing lifetime of the hard acceleration entry, and delete the hard acceleration entry if the lifetime of the updated hard acceleration entry reaches the aging time of the updated hard acceleration entry, where the initial lifetime of the hard acceleration entry is greater than or equal to the preset time T1. When a hard acceleration entry exists and the hard acceleration entry is used within a preset time period, updating the life cycle of the hard acceleration entry to the aging time of the hard acceleration entry, and deleting the hard acceleration entry when the hard acceleration strip time arrives.
The embodiment of the invention also provides a computer-readable storage medium, which is characterized in that the medium stores computer-executable instructions, and the computer-executable instructions, when executed by a processor, implement the steps of the method for implementing forwarding of the IPv4-in-IPv 6DS Lite data stream described in the previous embodiment.
The embodiment of the invention also provides a terminal for realizing IPv4-in-IPv 6DS Lite data stream forwarding, which comprises:
a memory for storing computer executable instructions;
a processor for executing the computer executable instructions to implement the steps of the method for implementing IPv4-in-IPv 6DS Lite data stream forwarding as described in the previous embodiments.
It will be understood by those of ordinary skill in the art that all or some of the steps of the methods, systems, functional modules/units in the devices disclosed above may be implemented as software, firmware, hardware, and suitable combinations thereof. In a hardware implementation, the division between functional modules/units mentioned in the above description does not necessarily correspond to the division of physical components; for example, one physical component may have multiple functions, or one function or step may be performed by several physical components in cooperation. Some or all of the components may be implemented as software executed by a processor, such as a digital signal processor or microprocessor, or as hardware, or as an integrated circuit, such as an application specific integrated circuit. Such software may be distributed on computer readable media, which may include computer storage media (or non-transitory media) and communication media (or transitory media). The term computer storage media includes volatile and nonvolatile, removable and non-removable media implemented in any method or technology for storage of information such as computer readable instructions, data structures, program modules or other data, as is well known to those of ordinary skill in the art. Computer storage media includes, but is not limited to, RAM, ROM, EEPROM, flash memory or other memory technology, CD-ROM, Digital Versatile Disks (DVD) or other optical disk storage, magnetic cassettes, magnetic tape, magnetic disk storage or other magnetic storage devices, or any other medium which can be used to store the desired information and which can accessed by a computer. In addition, communication media typically embodies computer readable instructions, data structures, program modules or other data in a modulated data signal such as a carrier wave or other transport mechanism and includes any information delivery media as known to those skilled in the art.

Claims (10)

1. A method for realizing IPv4-in-IPv 6DS Lite data stream forwarding is characterized by comprising the following steps:
receiving an IPv4 message from a Local Area Network (LAN);
judging whether a hard acceleration entry exists or not;
if a hard acceleration entry exists and the IPv4 message is matched with the hard acceleration entry, the IPv4 message is packaged into an IPv6 message according to the hard acceleration entry and then sent out from a Wide Area Network (WAN);
if no hard acceleration item exists, generating a hard acceleration item in the process of encapsulating the IPv4 message from the LAN into an IPv6 message through a protocol stack and sending the IPv6 message from the WAN;
and if the number of the received messages is less than the preset value, deleting the existing hard acceleration entries.
2. The method for implementing IPv4-in-IPv 6DS Lite data flow forwarding according to claim 1, further comprising:
after receiving an IPv4 message from a Local Area Network (LAN), counting the number of messages entering an IPv4-in-IPv6 tunnel transmission, and if the number of the messages entering the IPv4-in-IPv6 tunnel transmission is larger than or equal to a preset value, judging whether a hard acceleration item exists;
if no hard acceleration item exists, generating a hard acceleration item in the process of encapsulating the IPv4 message from the LAN into an IPv6 message through a protocol stack and sending the IPv6 message from the WAN;
and if the hard acceleration entry exists and the IPv4 message is matched with the hard acceleration entry, encapsulating the IPv4 message into an IPv6 message according to the hard acceleration entry and then sending the IPv6 message out of a Wide Area Network (WAN).
3. The method for implementing IPv4-in-IPv 6DS Lite data flow forwarding according to claim 1 or 2, further comprising:
when a hard acceleration entry exists, judging whether the existing hard acceleration entry is used in a preset time period T1, if not, updating the life cycle of the hard acceleration entry to the value obtained by subtracting T1 from the existing life cycle of the hard acceleration entry, and if the life cycle of the updated hard acceleration entry reaches the aging time of the hard acceleration entry, deleting the hard acceleration entry, wherein the initial life cycle of the hard acceleration entry is greater than or equal to the preset time period T1.
4. The method for implementing IPv4-in-IPv 6DS Lite data flow forwarding according to claim 3, further comprising:
when a hard acceleration entry exists and the hard acceleration entry is used in the preset time period, updating the life cycle of the hard acceleration entry to the aging time of the hard acceleration entry, and deleting the hard acceleration entry when the aging time of the hard acceleration entry reaches.
5. A system for realizing IPv4-in-IPv 6DS Lite data stream forwarding is characterized by comprising the following steps:
the message receiving module is used for receiving the IPv4 message from the Local Area Network (LAN);
the hard acceleration module is used for judging whether a hard acceleration item exists or not, if the hard acceleration item exists and the IPv4 message is matched with the hard acceleration item, the IPv4 message is packaged into an IPv6 message according to the hard acceleration item and then sent out from a Wide Area Network (WAN); if no hard acceleration item exists, generating a hard acceleration item in the process of encapsulating the IPv4 message from the LAN into an IPv6 message through a protocol stack and sending the IPv6 message from the WAN;
the hard acceleration module is further configured to delete a hard acceleration entry if the hard acceleration entry exists when the number of received messages is smaller than a preset value.
6. The system for implementing IPv4-in-IPv 6DS Lite data flow forwarding of claim 5,
the hard acceleration module is further configured to count the number of messages entering an IPv4-in-IPv6 tunnel transmission after the message receiving module receives an IPv4 message from the local area network LAN, and determine whether a hard acceleration entry exists if the number of messages entering the IPv4-in-IPv6 tunnel transmission is greater than or equal to a preset value; if no hard acceleration item exists, generating a hard acceleration item in the process of encapsulating the IPv4 message from the LAN into an IPv6 message through a protocol stack and sending the IPv6 message from the WAN; and if the hard acceleration entry exists and the IPv4 message is matched with the hard acceleration entry, encapsulating the IPv4 message into an IPv6 message according to the hard acceleration entry and then sending the IPv6 message out of a Wide Area Network (WAN).
7. The system for implementing IPv4-in-IPv 6DS Lite data flow forwarding according to claim 5 or 6,
the hard acceleration module is further configured to determine whether a hard acceleration entry exists in a preset time period T1, if the hard acceleration entry does not exist in the preset time period T1, update the lifetime of the hard acceleration entry to the value obtained by subtracting T1 from the existing lifetime of the hard acceleration entry, and delete the hard acceleration entry if the lifetime of the updated hard acceleration entry reaches the aging time of the hard acceleration entry, where the initial lifetime of the hard acceleration entry is greater than or equal to the preset time period T1.
8. The system for implementing IPv4-in-IPv 6DS Lite data flow forwarding of claim 7,
the hard acceleration module is further used for updating the life cycle of the hard acceleration entry to the aging time of the hard acceleration entry when the hard acceleration entry exists and is used in the preset time period, and deleting the hard acceleration entry when the aging time of the hard acceleration entry reaches.
9. A computer-readable storage medium, characterized in that the medium stores computer-executable instructions which, when executed by a processor, implement the steps of a method of implementing IPv4-in-IPv 6DS Lite data flow forwarding according to any of claims 1 to 4.
10. A terminal for realizing IPv4-in-IPv 6DS Lite data stream forwarding is characterized by comprising the following components:
a memory for storing computer executable instructions;
a processor for executing the computer-executable instructions to implement the steps of the method of implementing IPv4-in-IPv 6DS Lite data flow forwarding of any of claims 1 to 4.
CN201811593559.4A 2018-12-25 2018-12-25 Method and system for realizing 4in6DS Lite data stream forwarding Active CN111371909B (en)

Priority Applications (2)

Application Number Priority Date Filing Date Title
CN201811593559.4A CN111371909B (en) 2018-12-25 2018-12-25 Method and system for realizing 4in6DS Lite data stream forwarding
PCT/CN2019/128195 WO2020135479A1 (en) 2018-12-25 2019-12-25 Ipv4-in-ipv6 ds lite data stream forwarding method, system, terminal and medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201811593559.4A CN111371909B (en) 2018-12-25 2018-12-25 Method and system for realizing 4in6DS Lite data stream forwarding

Publications (2)

Publication Number Publication Date
CN111371909A CN111371909A (en) 2020-07-03
CN111371909B true CN111371909B (en) 2022-04-26

Family

ID=71129075

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201811593559.4A Active CN111371909B (en) 2018-12-25 2018-12-25 Method and system for realizing 4in6DS Lite data stream forwarding

Country Status (2)

Country Link
CN (1) CN111371909B (en)
WO (1) WO2020135479A1 (en)

Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101695047A (en) * 2009-10-26 2010-04-14 中兴通讯股份有限公司 Method and switch for realizing forwarding of dynamic tunnel message
CN103516692A (en) * 2012-06-28 2014-01-15 中兴通讯股份有限公司 Method and system for achieving accelerating processing of DS-Lite data message
CN107196776A (en) * 2016-03-14 2017-09-22 中兴通讯股份有限公司 A kind of method and apparatus of message forwarding

Family Cites Families (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102546362A (en) * 2010-12-20 2012-07-04 中兴通讯股份有限公司 Message processing method, message processing system and customer premises equipment
CN102938736B (en) * 2012-11-20 2016-06-08 杭州迪普科技有限公司 A kind of method and apparatus realizing IPv4 message passing through IPv 6 network
CN105282102B (en) * 2014-06-30 2019-03-15 中国电信股份有限公司 Data flow processing method and system and IPv6 data processing equipment

Patent Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101695047A (en) * 2009-10-26 2010-04-14 中兴通讯股份有限公司 Method and switch for realizing forwarding of dynamic tunnel message
CN103516692A (en) * 2012-06-28 2014-01-15 中兴通讯股份有限公司 Method and system for achieving accelerating processing of DS-Lite data message
CN107196776A (en) * 2016-03-14 2017-09-22 中兴通讯股份有限公司 A kind of method and apparatus of message forwarding

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
网络终端设备软件加速方法研究;王大伟;《科技风》;20151025(第20期);全文 *

Also Published As

Publication number Publication date
CN111371909A (en) 2020-07-03
WO2020135479A1 (en) 2020-07-02

Similar Documents

Publication Publication Date Title
US10148573B2 (en) Packet processing method, node, and system
CN108011837B (en) Message processing method and device
KR100453055B1 (en) Method for path MTU discovery on IP network and apparatus thereof
CN113055127B (en) Data message duplicate removal and transmission method, electronic equipment and storage medium
US10791051B2 (en) System and method to bypass the forwarding information base (FIB) for interest packet forwarding in an information-centric networking (ICN) environment
WO2020156166A1 (en) Packet processing method and device
CN108600109B (en) Message forwarding method and device
WO2016177145A1 (en) Packet transmission method and device
CN108924062B (en) Message processing method and device
CN110545229B (en) Message sending method and device in VXLAN axis networking mode
CN105337881A (en) Data message processing method, service node and stream guiding point
CN101848171A (en) Data transmission method based on GRE tunnel, device and system
EP4057576A1 (en) Packet encapsulating method and apparatus, and packet decapsulating method and apparatus
EP4044529A1 (en) Detnet data packet processing method and apparatus
CN110062060B (en) System and method for IP address allocation
WO2011015106A1 (en) Management method and device for uplink traffic flow template
CN108075991B (en) Message forwarding method and device
CN113472718A (en) Service processing method, device, equipment and storage medium
CN108259301B (en) Tunnel online method and device
CN107483369B (en) Message processing method and virtual switch
CN111371909B (en) Method and system for realizing 4in6DS Lite data stream forwarding
CN102655476B (en) Internet protocol flow transmitting method and device
CN111277426B (en) IOAM information processing method and device
CN115242892B (en) Stream identifier acquisition method, device, equipment and medium
CN112565044B (en) Message processing method and device

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant