Service processing method, ONT and user equipment
By establishing the correspondence between the private network IP address and the public network IP address in ONT, the traffic of service messages is realized, which solves the problem of increased communication costs caused by the introduction of vCPE, and improves the reliability and efficiency of the communication system.
Patent Information
- Application Number
- CN202310835709.2
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2023-07-07
- Publication Date
- 2025-01-07
- Estimated Expiration
- 2043-07-07
AI Technical Summary
In the communication field, the introduction of virtual customer user equipment (vCPE) to improve the access experience of cloud services will lead to increased communication costs.
Through optical network terminals (ONTs) establish a correspondence between private network IP addresses and public network IP addresses between user equipment and destination devices, realize the diversion of service messages, avoid dependence on vCPE, reduce communication costs, and increase the Communication reliability.
It realizes efficient shunt of service messages, reduces communication costs, and improves the reliability of the communication system, avoiding the increase in cost caused by the introduction of vCPE.
Smart Images

Figure CN119276833A_ABST
Abstract
Description
Technical Field
[0001] The present application relates to the field of communications, and in particular to a service processing method, an ONT and a user equipment. Background Art
[0002] In the field of communications, optical network terminals (ONTs) connect to the public network through traditional Internet access channels. User devices access the public network through ONTs. In order to improve the user experience of cloud services, a layer 2 logical channel can be added to the ONT. One end of the logical channel is connected to the ONT, and the other end is connected to the virtual customer premises equipment (vCPE). Service messages for user devices to access the cloud service network and the public network are first forwarded to the vCPE through the ONT. The vCPE diverts the service messages to the cloud service network or the public network based on the Internet Protocol (IP) address of the service message.
[0003] In practical applications, the introduction of vCPE will increase the cost of communication. Summary of the invention
[0004] The present application provides a service processing method, an ONT and a user equipment, by which the ONT is used to realize the diversion of service messages, thereby reducing the communication cost.
[0005] The first aspect of the present application provides a service processing method. The service processing method comprises the following steps: an ONT receives a domain name service (DNS) query message from a user device. The DNS query message includes a first domain name of a destination device. The user device and the destination device are in the same local area network. The ONT sends a first DNS response message to the user device. The first DNS response message includes a first private Internet protocol (IP) address of the destination device. The first private IP address is obtained by the ONT according to the first domain name by querying the correspondence between the domain name and the private IP address stored locally. The first private IP address is used by the user device to send a first service message to the destination device.
[0006] In an optional manner of the first aspect, the service processing method further includes the following steps: if the correspondence between the domain name and the private network IP address does not include the IP address corresponding to the first domain name, the ONT sends a second DNS response message to the user device. The second DNS response message includes the first public network IP address of the destination device. The first public network IP address is obtained by the ONT from the DNS server according to the first domain name. The first public network IP address is used by the user device to send a second service message to the destination device. In the present application, when the user device cannot send a service message to the destination device through the first private network IP address, the user device can send a service message to the destination device through the first public network IP address. Therefore, the present application can improve the reliability of communication.
[0007] In an optional manner of the first aspect, before the ONT receives the DNS query message from the user equipment, the service processing method further includes the following steps: the ONT receives a dynamic host configuration protocol (DHCP) request from the destination device. The DHCP request includes the first domain name. The ONT sends a DHCP response to the destination device. The DHCP response includes a first private network IP address allocated by the ONT to the destination device.
[0008] In an optional manner of the first aspect, before the ONT receives the DNS query message from the user equipment, the service processing method further includes the following steps: the ONT receives a first message from the destination device. The first message includes a first domain name and a first private network IP address.
[0009] In an optional manner of the first aspect, before the ONT receives a DNS query message from a destination device, the service processing method further includes the following steps: the ONT sends a probe request to the destination device. If the probe response is not received within the specified time, the ONT deletes the correspondence between the first domain name and the first private network IP address or marks the state of the correspondence between the first domain name and the first private network IP address as invalid. In the present application, it can be determined whether the first private network IP address is reachable through the probe request. When the first private network IP address is unreachable, the user equipment can transmit the service message through the first public network IP address. Therefore, the present application can improve the reliability of communication.
[0010] In an optional manner of the first aspect, the value of the time to life (TTL) field in the first DNS response message is 0. In practical applications, in order to reduce the number of DNS queries, the user device can save the obtained IP address for use when accessing the same domain name next time. However, in the present application, when the first private network IP address is unreachable, if the user device uses the first private network IP address saved last time to transmit the first business message, the destination device will be unable to receive the first business message. Therefore, by setting the effective duration of the first DNS response message, the reliability of communication can be improved.
[0011] The second aspect of the present application provides a service processing method. The service processing method comprises the following steps: a user device sends a DNS query message to an ONT. The DNS query message includes a first domain name of a destination device. The user device and the destination device are in the same local area network. The user device receives a first DNS response message from the ONT. The first DNS response message includes a first private network IP address of the destination device. The first private network IP address is obtained by the ONT according to the first domain name by querying the correspondence between the domain name and the private network IP address stored locally. The first private network IP address is used by the user device to send a first service message to the destination device.
[0012] In an optional manner of the second aspect, the service processing method further includes the following steps: the user equipment receives a second DNS response message from the ONT. The second DNS response message includes a first public IP address of the destination device. The first public IP address is obtained by the ONT from a DNS server according to the first domain name. The first public IP address is used by the user equipment to send a second service message to the destination device.
[0013] In an optional manner of the second aspect, a value of the TTL field in the first DNS response message is 0.
[0014] In an optional manner of the second aspect, the service processing method further includes the following steps: the user device generates a first service message through the first application. When the IP address corresponding to the first domain name obtained by the user device is a private network address, the user device determines that it is in the first functional state. When the IP address corresponding to the first domain name obtained by the user device is a public network address, the user device determines that it is in the second functional state. In the present application, the state of the user device is determined by the IP address, and different services are provided according to the state of the user device, which can improve the user experience.
[0015] In an optional manner of the second aspect, in the first functional state, the user device displays a state where the first application is in a high-speed channel. In the second functional state, the user device displays a state where the first application is not in a high-speed channel. By displaying the state of using the high-speed channel, the user experience can be improved.
[0016] The third aspect of the present application provides an ONT. The ONT includes a transceiver and a network interface. The transceiver is used to receive a DNS query message from a user device. The DNS query message includes a first domain name of a destination device. The user device and the destination device are in the same local area network. The transceiver is also used to send a first DNS response message to the user device. The first DNS response message includes a first private IP address of the destination device. The first private IP address is obtained by querying the correspondence between the domain name and the private IP address stored locally based on the first domain name. The transceiver is also used to receive a first service message from the user device. The destination IP address of the first service message is the first private IP address. The network interface is used to send the first service message to the destination device.
[0017] In an optional manner of the third aspect, if the correspondence between the domain name and the private IP address does not include the IP address corresponding to the first domain name, the transceiver is also used to send a second DNS response message to the user device. The second DNS response message includes the first public IP address of the destination device. The first public IP address is obtained by querying the DNS server based on the first domain name. The transceiver is also used to receive a second service message from the user device. The destination IP address of the second service message is the first public IP address. The network interface is also used to send a second service message to the destination device.
[0018] In an optional manner of the third aspect, the network interface is further used to receive a DHCP request from a destination device. The DHCP request includes the first domain name. The network interface is further used to send a DHCP response to the destination device. The DHCP response includes the first private network IP address allocated by the ONT to the destination device.
[0019] In an optional manner of the third aspect, the network interface is further configured to receive a first message from a destination device. The first message includes a correspondence between the first domain name and the first private network IP address.
[0020] In an optional manner of the third aspect, the ONT further includes a processor. The network interface is further configured to send a probe request to a destination device. If a probe response is not received within a specified time, the processor is configured to delete the correspondence between the first domain name and the first private network IP address or mark the state of the correspondence between the first domain name and the first private network IP address as invalid.
[0021] A fourth aspect of the present application provides a user device. The user device includes a receiver and a transmitter. The transmitter is used to send a DNS query message to the ONT. The DNS query message includes a first domain name of the destination device. The user device and the destination device are in the same local area network. The receiver is used to receive a first DNS response message from the ONT. The first DNS response message includes a first private IP address of the destination device. The first private IP address is obtained by the ONT based on the first domain name by querying the correspondence between the domain name and the private IP address stored locally. The first private IP address is used by the user device to send a first service message to the destination device.
[0022] In an optional manner of the fourth aspect, the receiver is used to receive a second DNS response message from the ONT. The second DNS response message includes a first public IP address of the destination device. The first public IP address is obtained by the ONT from a DNS server according to the first domain name. The first public IP address is used by the user device to send a second service message to the destination device.
[0023] In an optional manner of the fourth aspect, a first application is installed in a user device. The user device also includes a processor. The first application is used to generate a first service message. When the IP address corresponding to the first domain name obtained by the user device is a private network address, the processor is used to determine that it is in a first functional state. When the IP address corresponding to the first domain name obtained by the user device is a public network address, the processor is used to determine that it is in a second functional state.
[0024] In an optional manner of the fourth aspect, the user device further includes a display screen. In the first functional state, the display screen is used to display a state where the first application is in a high-speed channel. In the second functional state, the display screen is used to display a state where the first application is not in a high-speed channel.
[0025] The fifth aspect of the present application provides a computer storage medium, characterized in that instructions are stored in the computer storage medium, and when the instructions are executed on a computer, the computer executes the method as described in the first aspect or any one of the embodiments of the first aspect; or the computer executes the method as described in the second aspect or any one of the embodiments of the second aspect.
[0026] The sixth aspect of the present application provides a computer program product, characterized in that when the computer program product is executed on a computer, it enables the computer to execute the method as described in the first aspect or any one of the embodiments of the first aspect; or enables the computer to execute the method as described in the second aspect or any one of the embodiments of the second aspect. BRIEF DESCRIPTION OF THE DRAWINGS
[0027] Figure 1 A first structural diagram of a communication system provided in an embodiment of the present application;
[0028] Figure 2 A first flowchart of a business processing method provided by an example of the present application;
[0029] Figure 3 A second flow chart of the business processing method provided in an embodiment of the present application;
[0030] Figure 4 A third flow chart of the business processing method provided in the embodiment of the present application;
[0031] Figure 5 A second structural diagram of a communication system provided in an embodiment of the present application;
[0032] Figure 6 A first structural diagram of an ONT provided in an embodiment of the present application;
[0033] Figure 7 A second structural diagram of an ONT provided in an embodiment of the present application;
[0034] Figure 8 A schematic diagram of the structure of a user device provided in an embodiment of the present application. DETAILED DESCRIPTION
[0035] The present application provides a service processing method, an optical network terminal (ONT) and a user device, which can reduce the cost of communication by implementing the diversion of service messages through the ONT. It should be understood that the "first", "second" or "target" used in the present application is only used to distinguish the purpose of description, and cannot be understood as indicating or implying relative importance, nor can it be understood as indicating or implying order. In addition, for the sake of simplicity and clarity, reference numbers and / or letters are repeated in multiple figures of the present application. Repetition does not indicate a strict limiting relationship between various embodiments and / or configurations. In the field of communications, in order to improve the user experience of cloud services, a layer 2 logical channel can be added to the ONT. One end of the logical channel is connected to the ONT, and the other end is connected to the virtual customer premises equipment (vCPE). The vCPE is used to divert the service messages of the user equipment according to the destination Internet Protocol (IP) address of the service message. However, the introduction of vCPE will increase the cost of communication.
[0036] To this end, the present application provides a service processing method. The service processing method is applied to an ONT, a user equipment or a destination equipment in a communication system. Figure 1 This is a first structural diagram of a communication system provided in an embodiment of the present application. Figure 1As shown, the communication system includes a user device 101, an ONT 102, and a destination device 103 in the same local area network. The user device 101 is a laptop, a desktop computer, or a mobile phone. The destination device 103 is another ONT or a server. The ONT 102 and the destination device 103 are connected through a first channel. The first channel is a layer 2 channel or a layer 3 channel, such as a virtual private network (VPN) tunnel. The ONT 102 includes a corresponding public IP address and is connected to the public network through a second channel. The second channel is a layer 3 channel. The destination device 103 also includes a corresponding public IP address and can receive service messages from the public network through the public IP address.
[0037] It should be understood that in the present application, the first channel and the second channel are logically different channels. Therefore, the first channel and the second channel can share the same network interface in the ONT. For example, the first channel and the second channel share the same network interface of the network card in the ONT or the same network interface of the optical module in the ONT. The network interface is also called a network port. The first channel and the second channel can also use different network interfaces in the ONT. For example, the network interface includes a first network interface and a second network interface. The ONT includes a first network card and a second network card. The first channel uses the first network interface of the first network card. The second channel uses the second network interface of the second network card.
[0038] It should be understood that the present application does not limit whether the user device 101 and the destination device 103 in the same local area network are in the same region. When the user device 101 and the destination device 103 are in the same region, for example, the user device 101 and the destination device 103 are physically in the same home, the user device 101 and the destination device 103 can form a local area network through a network cable or wireless WIFI. When the user device 101 and the destination device 103 are not in the same region, the user device 101 and the destination device 103 can form a local area network through a dedicated line or by establishing a tunnel. For the convenience of management, the virtual local area network (VLAN) identifier (ID) of the user device 101 and the destination device 103 connected to the ONT may be different or the same.
[0039] Figure 2 The first flowchart of the business processing method provided by this application example. Figure 2 As shown, the service processing method includes the following steps: In step 201, the user equipment sends a domain name service (DNS) query message including a first domain name to the ONT.
[0040] Before the user device accesses the first domain name, the user device needs to obtain the Internet Protocol (IP) address corresponding to the first domain name. If the user device does not obtain the IP address corresponding to the first domain name, or the IP address corresponding to the first domain name obtained by the user device has expired, the user device sends a DNS query message to the ONT. The DNS query message is also called a DNS request or a DNS request message. The DNS query message includes the first domain name of the destination device. The DNS query message is used to query the IP address corresponding to the first domain name.
[0041] In step 202, the ONT sends a first DNS response message to the user equipment, including a first private network IP address corresponding to the first domain name.
[0042] The ONT locally stores the correspondence between the domain name and the private IP address. The private IP address is also called the local area network IP address. After receiving the DNS query message from the user device, the ONT queries the correspondence to determine whether the correspondence includes the first private IP address corresponding to the first domain name. If the correspondence includes the first private IP address corresponding to the first domain name, and the state of the correspondence between the first domain name and the first private IP address is valid, the ONT sends a first DNS response message to the user device, and the user device does not query the DNS server for the public IP address corresponding to the first domain name. The DNS response message is also called a DNS reply message or a DNS response message. The first DNS response message includes the first private IP address corresponding to the first domain name. If the correspondence does not include the first private IP address corresponding to the first domain name, or the state of the correspondence between the first domain name and the first private IP address is invalid, the ONT forwards the DNS query message to the DNS server. The DNS server replies to a second DNS response message according to the DNS query message. The second DNS response message includes the first public IP address of the destination device. The ONT sends a second DNS response message to the user device.
[0043] In step 203, the user equipment sends a first service message to the ONT.
[0044] After receiving the first DNS response message or the second DNS response message, the user device learns the media access control (MAC) address corresponding to the first private network IP address or the first public network IP address. For example, the user device sends a broadcast address resolution protocol (ARP) message. The ARP message includes the first private network IP address. After receiving the ARP message, the ONT broadcasts the ARP message in the local area network. The destination device in the local area network can also receive the ARP message. The destination device replies with an ARP response according to the ARP message. The ARP response includes the MAC address corresponding to the first private network IP address, that is, the MAC address of the destination device. The user device sends a first service message or a second service message to the ONT. The destination IP address of the first service message is the first private network IP address. The destination MAC address of the first service message is the MAC address of the destination device. When the ONT acts as a gateway for the user device, the user device obtains the MAC address of the ONT device. If the IP address obtained by the user device is the first public network IP address, the user device fills the MAC address of the ONT into the destination MAC address of the message. Therefore, the destination IP address of the second service message is the first public network IP address. The destination MAC address of the first service message is the MAC address of the ONT.
[0045] In step 204, the ONT sends a first service message to a destination device.
[0046] After receiving the service message from the user device, the ONT determines the destination MAC address or destination IP address of the service message. When the destination MAC address of the service message is the MAC address of the destination device and the destination IP address is the first private network IP address, the ONT forwards the service message to the network interface corresponding to the first channel according to the destination MAC address or destination IP address. For example, a first VPN tunnel is established between the ONT and the destination device. The ONT adds a first virtual extensible local area network (VxLAN) header to the outer layer of the first service message. The ONT transmits the first service message carrying the first VxLAN header through the first VPN tunnel. For another example, the first channel and the second channel use different network interfaces in the ONT. The ONT establishes a dedicated line with the destination device through the second network interface. The ONT directly transmits the first service message through the dedicated line. At this time, the ONT does not need to make any modifications to the first service message, such as modifying the source IP address. When the destination MAC address of the service message is the MAC address of the ONT and the destination IP address is the first public network IP address, the ONT forwards the service message to the network interface corresponding to the second channel according to the destination MAC address or destination IP address. For example, the ONT modifies the source IP address of the second service message to the public IP address of the ONT, and transmits the second service message with the modified source IP address to the public network through the second channel. For another example, the ONT establishes a second VPN tunnel with the receiving device of the second service message. The ONT adds a second VxLAN header to the outer layer of the second service message. The ONT transmits the second service message carrying the second VxLAN header through the second VPN tunnel.
[0047] In an embodiment of the present application, for a service message (e.g., a second service message) accessing the public network, that is, a service message whose destination IP address is a public network IP address, the ONT sends the service message to the public network through the second channel. For a service message accessing a destination device through a first private network IP address, the ONT sends the service message to the destination device through the first channel. Therefore, the embodiment of the present application implements the diversion of service messages through the ONT. By diverting service messages through the ONT, there is no need to introduce vCPE, thereby reducing the cost of communication.
[0048] according to Figure 1 As can be seen from the description, the user device, the ONT and the destination device are located in the same local area network. Therefore, the user device, the ONT and the destination device include different private network IP addresses. In order to avoid conflicts in private network IP addresses, a distribution device for private network IP addresses is included in the local area network. The distribution device is the ONT or other devices. When the distribution device is the ONT or other devices, the ONT obtains the correspondence between the first domain name and the first private network IP address in different ways. This is described below.
[0049] In the first mode, the allocating device is an ONT. In this mode, the ONT receives a second message from a destination device. The second message includes a first domain name, and the ONT allocates a first private network IP address to the destination device according to the second message, and locally stores the correspondence between the first domain name and the first private network IP address. The following description is taken as an example that the second message is a dynamic host configuration protocol (DHCP) request. Figure 3 This is a second flow chart of the service processing method provided in the embodiment of the present application. Figure 3 As shown, the business processing method includes the following steps.
[0050] In step 301, the destination device sends a DHCP request including a first domain name to the ONT.
[0051] After the destination device accesses the local area network where the ONT is located, the destination device sends a DHCP request to the ONT. The DHCP request includes a first domain name. For example, the DHCP request includes multiple options fields. Multiple options fields include a host name field. The host name field is also called option 12host name field. The host name field carries the first domain name. In actual applications, the DHCP request may also include device authentication information. For example, multiple options fields also include a vendor class identifier field. The vendor class identifier field is also called option 60vendor class identifier field. The vendor class identifier field carries device authentication information. The device authentication information includes the device type or identity information of the destination device, etc.
[0052] In step 302, the ONT sends a DHCP response to the destination device, including the first private network IP address allocated by the ONT to the destination device.
[0053] The ONT verifies the device authentication information. If the verification is successful, the ONT sends a DHCP response to the destination device. The DHCP response includes the first private IP address assigned by the ONT to the destination device. If the verification fails, the ONT discards the DHCP request or replies with a rejection message. If the ONT has already assigned the first private IP address to the destination device, and has locally recorded the correspondence between other domain names and the first private IP address, the ONT and the destination device can determine the purpose of the DHCP request by agreement. For example, if the DHCP request carries the first identifier, the ONT will not assign a private IP address to the destination device again, but will update the aforementioned correspondence. The updated correspondence includes the correspondence between the first domain name and the first private IP address. If the DHCP request does not carry the first identifier, the ONT assigns a private IP address to the destination device again and updates the aforementioned correspondence. The updated correspondence includes the correspondence between the first domain name and the first private IP address. It should be understood that the two first private IP addresses assigned by the ONT to the destination device may be different.
[0054] The description of steps 303 to 305 is the same as the above Figure 2 There are similarities between the descriptions of steps 201 to 204 in the embodiment of the present invention. Therefore, the descriptions of steps 303 to 305 can refer to the descriptions of steps 201 to 204. For example, the description of step 303 can refer to the description of step 201. For another example, the description of step 305 can refer to the descriptions of steps 203 and 204.
[0055] In the second mode, the allocating device is another device. The other device is a device other than the ONT in the local area network, such as another DHCP server. In this mode, after the other device allocates the first private network IP address to the destination device, the destination device sends a first message to the ONT. The first message includes the first domain name and the first private network IP address. The embodiment of the present application does not limit the format of the first message. After receiving the first message, the ONT locally saves the correspondence between the first domain name and the first private network IP address. When the domain name of the destination device changes, the destination device resends the first message to the ONT. The resent first message includes the updated domain name and the first private network IP address. The ONT updates the correspondence according to the resent first message.
[0056] In other embodiments, the ONT can also generate the correspondence between the domain name and the private IP through configuration from a WEB graphical user interface (GUI), a network management device, or a command line interface (CLI). For example, the network management device configures the correspondence between the private IP address and the domain name to the ONT through a TR-069 protocol message. Similarly, the ONT can also update the correspondence between the domain name and the private IP through a new configuration.
[0057] In an embodiment of the present application, in order to improve user experience, the ONT can transmit the first service message to the destination device through the first channel. However, if the first channel fails, the ONT still transmits the first service message through the first channel, which may cause the first service message to be unreachable, thereby reducing the reliability of communication. To this end, in other embodiments, the ONT can detect whether the first channel is working properly. Figure 4 This is a third flow chart of the business processing method provided in the embodiment of the present application. Figure 4 As shown, the business processing method includes the following steps.
[0058] In step 401, the ONT sends a detection request to a destination device.
[0059] The ONT locally stores the correspondence between the domain name and the private IP address. The correspondence includes one or more sub-correspondences. Each sub-correspondence includes a correspondence between a private IP address and a domain name. The ONT needs to maintain the reachability of the private IP address in each sub-correspondence through a probe request. The embodiment of the present application is described only by taking the first private IP address as an example. The ONT periodically sends a probe request, such as a PING request, to the destination device through the first channel.
[0060] In step 402, the destination device sends a probe response to the ONT.
[0061] In step 403, if no detection response is received, the ONT deletes the correspondence between the first domain name and the first private network IP address.
[0062] After the destination device receives the detection request, it will reply with a detection response. However, if the network interface connected to the second channel in the destination device fails, or the second channel fails, the destination device cannot normally receive the detection request and will not reply with a detection response. If the detection response is not received within the specified time, the ONT deletes the corresponding relationship between the first domain name and the first private network IP address in the corresponding relationship or marks the status of the corresponding relationship between the first domain name and the first private network IP address as invalid. If the detection response is received within the specified time, the status of the corresponding relationship between the first domain name and the first private network IP address continues to be maintained as valid.
[0063] The description of steps 404 to 407 and the aforementioned Figure 2 There are similarities between the descriptions of steps 201 to 204 in the embodiment. Therefore, the descriptions of steps 404 to 407 can refer to the descriptions of steps 201 to 204. For example, the description of step 404 can refer to the description of step 201. For another example, the descriptions of steps 405 and 406 can refer to the description of step 202. For another example, the description of step 407 can refer to the descriptions of steps 203 and 204.
[0064] exist Figure 1 In the communication system, the user equipment 101 can access the destination device 103 through the ONT 102. In practical applications, the user equipment 101 can also access the destination device 103 without going through the ONT 102. For example, the user equipment 101 is a mobile phone, and the user equipment 101 accesses the destination device 103 through a base station. Figure 5 This is a second structural diagram of the communication system provided in the embodiment of the present application. Figure 5 As shown, after the user equipment 101 is disconnected from the ONT 102, the user equipment 101 can access the destination device 103 through the public network.
[0065] In the embodiment of the present application, when the user device 101 accesses the destination device 103 through other means, the user device 101 accesses the destination device 103 through the first public network IP address of the destination device 103. Figure 2 It can be seen from the description that when the user device 101 accesses the destination device 103 through the ONT 102, the user device 101 accesses the destination device 103 through the first private IP address or the first public IP address of the destination device 103. In order to improve the user experience, the user device 101 can provide different services to the user according to the IP address used. For example, the user device 101 generates a first service message through a first application. When the IP address corresponding to the first domain name obtained by the user device 101 is a private network address, that is, the user device 101 accesses the destination device 103 through the first private network IP address of the destination device 103, the user device is determined to be in the first functional state. When the IP address corresponding to the first domain name obtained by the user device is a public network address, that is, the user device 101 accesses the destination device 103 through the first public network IP address of the destination device 103, the user device is determined to be in the second functional state.
[0066] In different functional states, the user device 101 can provide different services to the user. Different services refer to different interfaces and / or functions. For example, in the first functional state, the user device 101 allows the transfer of files larger than the target threshold size to the destination device. In the second functional state, the user device 101 does not allow the transfer of files larger than the target threshold size to the destination device. For another example, in the first functional state, the user device 101 does not limit the flow or rate upper limit of the first application. In the second functional state, the user device 101 limits the flow or rate upper limit of the first application. For another example, in the first functional state, the user device 101 displays the state of the first application in a high-speed channel; in the second functional state, the user device 101 displays the state of the first application not in a high-speed channel. The embodiment of the present application does not limit how the user device 101 displays whether the first application is in a high-speed channel. For example, the first application is a video application, and in the first functional state, the first application provides N optional video resolution options. In the second functional state, the first application provides M optional video resolution options. N and M are both integers greater than 0. N is greater than M. For example, the N optional video resolution options include 720P and 1080P. The M optional video resolution options include 720P. 720P refers to a video with a resolution of 1280*720. 1080P refers to a video with a resolution of 1280*720. Alternatively, in the first functional state, the user device 101 displays the words "in high-speed channel" through the first application. In the second functional state, the user device 101 does not display the words "in high-speed channel" through the first application.
[0067] In practical applications, in order to reduce the number of DNS queries, the user device can save the obtained IP address for use when accessing the same domain name next time. However, in an embodiment of the present application, if the first channel fails, the user device still accesses the destination device through the first private network IP address, which will cause the first service message to be unreachable. If the first channel is not in a failed state, the user device still accesses the destination device through the first public network IP address, which will reduce the user experience. For this reason, in other embodiments, the value of the life cycle (time to life, TTL) field in the first DNS response message is 0. The DNS protocol message includes a resource record (resource record, RR) field. The RR field includes a domain name field, a query type field, a query class field, a TTL field, a resource data length field, and a resource data field. The value in the TTL field represents the life cycle of the resource record. When the value of the TTL field is 0, the user device will only use the first public network IP address or the first private network IP address obtained this time in this session access. When the user device still needs to access the first domain name next time, the user device will re-acquire the IP address corresponding to the first domain name through a DNS query message.
[0068] The service processing method provided in the present application is described above, and the ONT and user equipment provided in the present application are described below. Figure 6 The first structural diagram of the ONT provided in the embodiment of the present application. Figure 6 As shown, ONT 102 includes a transceiver 601 and a network interface 602. Transceiver 601 can be an optical transceiver module. ONT 102 communicates with the user equipment through transceiver 601 and connects to the destination device through network interface 602. The user equipment and the destination device are in the same local area network. In an embodiment of the present application, transceiver 601 is used to receive a DNS query message from the user equipment. The DNS query message includes a first domain name of the destination device. Transceiver 601 is also used to send a first DNS response message to the user equipment. The first DNS response message includes a first private network IP address of the destination device. The first private network IP address is obtained by querying the correspondence between the domain name and the private network IP address stored locally according to the first domain name. Transceiver 601 is also used to receive a first service message from the user equipment. The destination IP address of the first service message is the first private network IP address. Network interface 602 is used to send the first service message to the destination device.
[0069] Figure 7 The second structural diagram of the ONT provided in the embodiment of the present application. Figure 7 As shown, ONT 102 includes a transceiver 601, a processor 701, a memory 702, a service diversion circuit 703 and a network interface 602. Processor 701 can be a central processing unit (CPU), a network processor (NP) or a combination of CPU and NP. Processor 701 can further include a hardware chip or other general-purpose processor. The above-mentioned hardware chip can be an application specific integrated circuit (ASIC), a programmable logic device (PLD) or a combination thereof. Memory 702 can be a volatile memory or a non-volatile memory, or can include both volatile and non-volatile memories. Among them, the non-volatile memory can be a read-only memory (ROM), a programmable read-only memory (PROM), an erasable programmable read-only memory (EPROM), or a flash memory, etc. The volatile memory can be a random access memory (RAM).
[0070] ONT 102 communicates with the user device through transceiver 601, and connects the destination device and the public network through network interface 602. For example, ONT 102 connects to the destination device through network port 1 in network interface 602. ONT 102 connects to the public network through network port 2 in the network interface. For another example, ONT 102 connects to the destination device and the public network through network port 1 in network interface 602. The user device and the destination device are in the same local area network. In an embodiment of the present application, transceiver 601 is used to receive a DNS query message from the user device. The DNS query message includes a first domain name of the destination device. The memory 702 stores a correspondence between a domain name and a private network IP address. The processor 701 is used to receive a DNS query message from the transceiver 601, and determine whether the correspondence includes a first private network IP address corresponding to the first domain name. If the correspondence includes a first private network IP address corresponding to the first domain name, and the state of the correspondence between the first domain name and the first private network IP address is valid, the processor 701 is also used to generate a first DNS response message. The first DNS response message includes the first private IP address corresponding to the first domain name. The processor 701 is also used to transmit the first DNS response message to the transceiver 601. If the correspondence does not include the first private IP address corresponding to the first domain name, or the state of the correspondence between the first domain name and the first private IP address is invalid, the processor 701 is also used to forward the DNS query message to the DNS server through the network interface 602. The network interface 602 is used to receive a second DNS response message from the DNS server. The second DNS response message includes the first public IP address of the destination device. The transceiver 601 is also used to send the first DNS response message or the second DNS response message to the user device.
[0071] The transceiver 601 is also used to receive a first service message or a second service message from a user device. The destination IP address of the first service message is the first private network IP address of the destination device. The destination IP address of the second service message is the first public network IP address of the destination device. The transceiver 601 is also used to transmit the first service message or the second service message to the service diversion circuit 703. The service diversion circuit 703 selects a corresponding transmission channel according to the destination IP address or the destination MAC address of the service message. For example, the first channel uses the network port 1 in the network interface 602. The second channel uses the network port 2 in the network interface 602. The service diversion circuit 703 transmits the first service message to the network port 1 or transmits the second service message to the network port 2. It should be understood that after selecting the transmission channel, the service diversion circuit 703 or other circuits can process the service message, such as adding a VxLAN header. The network ports in the network interface 602 can be interfaces on different network cards or optical modules. For example, network port 1 is the first network interface of the first network card; network port 2 is the second network interface of the second network card. The network interface 602 is used to output service messages.
[0072] It should be understood that Figure 6 or Figure 7 The description of ONT 102 in FIG. 1 is similar to the description of the aforementioned service processing method. Figure 1 to Figure 5 . For example, the network interface 602 is also used to receive a DHCP request from a destination device. The DHCP request includes a first domain name. The network interface 602 is also used to send a DHCP response to the destination device. The DHCP response includes a first private network IP address assigned by the ONT to the destination device. For another example, the network interface 602 is also used to send a probe request to the destination device. If the probe response is not received within the specified time, the processor 701 is used to delete the correspondence between the first domain name and the first private network IP address or mark the state of the correspondence between the first domain name and the first private network IP address as invalid.
[0073] Figure 8 This is a schematic diagram of the structure of the user equipment provided in the embodiment of the present application. Figure 8 As shown, the user equipment 101 includes a receiver 801 and a transmitter 802. The receiver 801 may be an optical receiver or a wireless receiver. The transmitter 802 may be an optical transmitter or a wireless transmitter. The transmitter 802 is used to send a DNS query message to the ONT. The DNS query message includes a first domain name of the destination device. The user equipment and the destination device are in the same local area network. The receiver 801 is used to receive a first DNS response message from the ONT. The first DNS response message includes a first private network IP address of the destination device. The first private network IP address is obtained by the ONT according to the first domain name, by querying the correspondence between the domain name and the private network IP address stored locally. The first private network IP address is used by the user equipment 101 to send a first service message to the destination device.
[0074] It should be understood that Figure 8 The description of the user equipment 101 in FIG. 1 is similar to the description of the service processing method described above. Therefore, the description of the user equipment 101 can refer to the description of the service processing method described above. Figure 1 to Figure 5Description of any figure in . For example, the receiver 801 is used to receive a second DNS response message from the ONT. The second DNS response message includes a first public IP address of the destination device. The first public IP address is obtained by the ONT from the DNS server according to the first domain name. The first public IP address is used by the user device to send a second service message to the destination device. For another example, the user device 101 also includes a processor. The first application is used to generate a first service message. When the IP address corresponding to the first domain name obtained by the user device 101 is a private network address, the processor is used to determine that it is in a first functional state. When the IP address corresponding to the first domain name obtained by the user device 101 is a public network address, the processor is used to determine that it is in a second functional state. In different functional states, the user device 101 can provide different services to the user. For another example, the user device 101 also includes a display screen. In the first functional state, the display screen is used to display the state of the first application in a high-speed channel. In the second functional state, the display screen is used to display the state of the first application not in a high-speed channel.
[0075] The above are only specific implementation methods of the present application, but the protection scope of the present application is not limited thereto. Any technician familiar with the technical field can easily think of changes or substitutions within the technical scope disclosed in the present application, which should be covered by the protection scope of the present application.
Claims
1. A business processing method, characterized in that: include: The optical network terminal ONT receives a domain name service DNS query message from a user device, wherein the DNS query message includes a first domain name of a destination device; The user device and the destination device are in the same local area network; The ONT sends a first DNS response message to the user equipment; wherein the first DNS response message includes a first private Internet Protocol IP address of the destination device; the first private IP address is obtained by querying the correspondence between the domain name and the private IP address stored locally according to the first domain name; the first private IP address is used by the user equipment to send a first service message to the destination device.
2. The service processing method according to claim 1, characterized in that: The method further comprises: If the correspondence between the domain name and the private IP address does not include the IP address corresponding to the first domain name, the ONT sends a second DNS response message to the user equipment; wherein the second DNS response message includes the first public IP address of the destination device; the first public IP address is obtained by querying the DNS server according to the first domain name; the first public IP address is used by the user equipment to send a second service message to the destination device.
3. The service processing method according to claim 1 or 2, characterized in that: Before the ONT receives the DNS query message from the user equipment, the method further includes: The ONT receives a Dynamic Host Configuration Protocol DHCP request from the destination device, where the DHCP request includes the first domain name; The ONT sends a DHCP response to the destination device, where the DHCP response includes the first private network IP address allocated by the ONT to the destination device.
4. The service processing method according to claim 1 or 2, characterized in that: Before the ONT receives the DNS query message from the user equipment, the method further includes: The ONT receives a first message from the destination device, where the first message includes the first domain name and the first private IP address.
5. The service processing method according to any one of claims 1 to 4, characterized in that: Before the ONT receives the DNS query message from the destination device, the method further includes: The ONT sends a detection request to the destination device; If the detection response is not received within the specified time, the ONT deletes the correspondence between the first domain name and the first private IP address or marks the state of the correspondence between the first domain name and the first private IP address as invalid.
6. The service processing method according to any one of claims 1 to 5, characterized in that: The value of the lifecycle TTL field in the first DNS response message is 0.
7. A business processing method, characterized in that: include: The user equipment sends a domain name service DNS query message to the optical network terminal ONT, where the DNS query message includes a first domain name of the destination device; The user device and the destination device are in the same local area network; The user equipment receives a first DNS response message from the ONT, where the first DNS response message includes a first private Internet Protocol IP address of the destination device; The first private IP address is obtained by the ONT according to the first domain name by querying the correspondence between the domain name and the private IP address stored locally; the first private IP address is used by the user equipment to send the first service message to the destination device.
8. The service processing method according to claim 7, characterized in that: The method further comprises: The user equipment receives a second DNS response message from the ONT, where the second DNS response message includes a first public IP address of the destination device; the first public IP address is obtained by the ONT from a DNS server according to the first domain name; the first public IP address is used by the user equipment to send a second service message to the destination device.
9. The service processing method according to claim 7 or 8, characterized in that: The value of the lifecycle TTL field in the first DNS response message is 0.
10. The service processing method according to any one of claims 7 to 9, characterized in that: The method further comprises: The user equipment generates the first service message through the first application; When the IP address corresponding to the first domain name obtained by the user equipment is a private network address, the user equipment is determined to be in a first functional state; When the IP address corresponding to the first domain name obtained by the user equipment is a public network address, the user equipment is determined to be in the second functional state.
11. The service processing method according to claim 10, characterized in that: In the first functional state, the user equipment displays that the first application is in a high-speed channel state, and in the second functional state, the user equipment displays that the first application is not in a high-speed channel state.
12. An optical network terminal ONT, characterized in that: Includes transceiver and network interface: The transceiver is used to receive a domain name service DNS query message from a user device, wherein the DNS query message includes a first domain name of a destination device; the user device and the destination device are in the same local area network; The transceiver is also used to send a first DNS response message to the user equipment; wherein the first DNS response message includes a first private Internet Protocol IP address of the destination device; the first private IP address is obtained by querying the correspondence between the domain name and the private IP address stored locally according to the first domain name; The transceiver is further configured to receive a first service message from the user equipment, wherein the destination IP address of the first service message is the first private network IP address; The network interface is used to send the first service message to the destination device.
13. The ONT according to claim 12, characterized in that: If the correspondence between the domain name and the private IP address does not include the IP address corresponding to the first domain name, the transceiver is further used to send a second DNS response message to the user equipment; wherein the second DNS response message includes the first public IP address of the destination device; the first public IP address is obtained by querying the DNS server according to the first domain name; The transceiver is further configured to receive a second service message from the user equipment, wherein the destination IP address of the second service message is the first public network IP address; The network interface is further used to send the second service message to the destination device.
14. The ONT according to claim 12 or 13, characterized in that: The network interface is further used to receive a Dynamic Host Configuration Protocol DHCP request from the destination device, wherein the DHCP request includes the first domain name; The network interface is further used to send a DHCP response to the destination device, where the DHCP response includes the first private network IP address allocated by the ONT to the destination device.
15. The ONT according to claim 12 or 13, characterized in that: The network interface is further used to receive a first message from the destination device, where the first message includes the first domain name and the first private IP address.
16. The ONT according to any one of claims 12 to 15, characterized in that: The ONT also includes a processor; The network interface is also used to send a detection request to the destination device; If the detection response is not received within the specified time, the processor is used to delete the correspondence between the first domain name and the first private IP address or mark the state of the correspondence between the first domain name and the first private IP address as invalid.
17. A user equipment, characterized in that: It includes a receiver and a transmitter, wherein: The transmitter is used to send a domain name service DNS query message to the optical network terminal ONT, wherein the DNS query message includes a first domain name of a destination device; the user device and the destination device are in the same local area network; The receiver is used to receive a first DNS response message from the ONT, where the first DNS response message includes a first private Internet Protocol IP address of the destination device; the first private IP address is obtained by the ONT through querying a correspondence between a locally stored domain name and a private IP address according to the first domain name; the first private IP address is used by the user equipment to send a first service message to the destination device.
18. The user equipment according to claim 17, characterized in that: The receiver is further configured to receive a second DNS response message from the ONT, where the second DNS response message includes the first public network IP address of the destination device; The first public IP address is obtained by the ONT from a DNS server according to the first domain name; the first public IP address is used by the user equipment to send a second service message to the destination device.
19. The user equipment according to claim 17 or 18, characterized in that: The user equipment has a first application installed therein, and the user equipment further includes a processor; The first application is used to generate the first service message; When the IP address corresponding to the first domain name obtained by the user equipment is a private network address, the processor is used to determine that it is in a first functional state; When the IP address corresponding to the first domain name obtained by the user equipment is a public network address, the processor is used to determine that it is in the second functional state.
20. The user equipment according to claim 19, characterized in that The user equipment also includes a display screen; In the first functional state, the display screen is used to display that the first application is in a high-speed channel state, and in the second functional state, the display screen is used to display that the first application is not in a high-speed channel state.
Citation Information
Patent Citations
Method, device and system for vicariously managing ONU (Optical Network Unit) by OLT (Optical Line Terminal)
CN102149024A
Automatic configuration method and system of ONT
CN106888408A
Network method, network device, network system and memory medium
CN107277101A
Domain name access method and related equipment
CN115225605A
Method and system for efficient use of a telecommunication network and the connection between the telecommunications network and a customer premises equipment
US20130100913A1