CN112055098A - Method for establishing long IP data connection, 5G gateway equipment and computer equipment - Google Patents

Method for establishing long IP data connection, 5G gateway equipment and computer equipment Download PDF

Info

Publication number
CN112055098A
CN112055098A CN202010845600.3A CN202010845600A CN112055098A CN 112055098 A CN112055098 A CN 112055098A CN 202010845600 A CN202010845600 A CN 202010845600A CN 112055098 A CN112055098 A CN 112055098A
Authority
CN
China
Prior art keywords
address
sub
real
time
equipment
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.)
Granted
Application number
CN202010845600.3A
Other languages
Chinese (zh)
Other versions
CN112055098B (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.)
Shenzhen Water World Co Ltd
Original Assignee
Shenzhen Water World 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 Shenzhen Water World Co Ltd filed Critical Shenzhen Water World Co Ltd
Priority to CN202010845600.3A priority Critical patent/CN112055098B/en
Publication of CN112055098A publication Critical patent/CN112055098A/en
Application granted granted Critical
Publication of CN112055098B publication Critical patent/CN112055098B/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/50Address allocation
    • H04L61/5007Internet protocol [IP] addresses
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L61/00Network arrangements, protocols or services for addressing or naming
    • H04L61/50Address allocation
    • H04L61/5053Lease time; Renewal aspects
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04WWIRELESS COMMUNICATION NETWORKS
    • H04W12/00Security arrangements; Authentication; Protecting privacy or anonymity
    • H04W12/06Authentication
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04WWIRELESS COMMUNICATION NETWORKS
    • H04W4/00Services specially adapted for wireless communication networks; Facilities therefor
    • H04W4/12Messaging; Mailboxes; Announcements
    • H04W4/14Short messaging services, e.g. short message services [SMS] or unstructured supplementary service data [USSD]
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04WWIRELESS COMMUNICATION NETWORKS
    • H04W76/00Connection management
    • H04W76/10Connection setup
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04WWIRELESS COMMUNICATION NETWORKS
    • H04W88/00Devices specially adapted for wireless communication networks, e.g. terminals, base stations or access point devices
    • H04W88/16Gateway arrangements
    • 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/618Details of network addresses
    • H04L2101/622Layer-2 addresses, e.g. medium access control [MAC] addresses
    • YGENERAL TAGGING OF NEW TECHNOLOGICAL DEVELOPMENTS; GENERAL TAGGING OF CROSS-SECTIONAL TECHNOLOGIES SPANNING OVER SEVERAL SECTIONS OF THE IPC; TECHNICAL SUBJECTS COVERED BY FORMER USPC CROSS-REFERENCE ART COLLECTIONS [XRACs] AND DIGESTS
    • Y02TECHNOLOGIES OR APPLICATIONS FOR MITIGATION OR ADAPTATION AGAINST CLIMATE CHANGE
    • Y02DCLIMATE CHANGE MITIGATION TECHNOLOGIES IN INFORMATION AND COMMUNICATION TECHNOLOGIES [ICT], I.E. INFORMATION AND COMMUNICATION TECHNOLOGIES AIMING AT THE REDUCTION OF THEIR OWN ENERGY USE
    • Y02D30/00Reducing energy consumption in communication networks
    • Y02D30/70Reducing energy consumption in communication networks in wireless communication networks

Landscapes

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

Abstract

The invention provides a method for establishing long IP data connection, 5G gateway equipment and computer equipment, wherein the method comprises the following steps: acquiring a first real-time IP address of each first sub-device connected with the 5G gateway device, and updating the first real-time IP address into an addressing index table; if the change of the IP address of any one of the first sub-devices is detected, generating a corresponding first RCS short message based on the addressing index table; the RCS short message is communicated with the 5G gateway equipment belonging to the equipment within the interaction authority range through the SIM card number; and controlling the first sub-equipment with the changed IP address to establish IP data long connection with the equipment corresponding to the second real-time IP address. The invention has the beneficial effects that: the two devices which need to be connected with each other are connected with each other in an IP data long way, and the storage and forwarding of a third-party server are not needed, so that the low time delay of data transmission is realized, the cost of data transmission is reduced, and the privacy protection is facilitated.

Description

Method for establishing long IP data connection, 5G gateway equipment and computer equipment
Technical Field
The invention relates to the field of communication, in particular to a method for establishing long IP data connection, 5G gateway equipment and computer equipment.
Background
At present, IP addresses of intelligent terminals are distributed by operators and dynamically change randomly, and long connection of IP data links is kept by help of a third-party server, and a heartbeat packet is sent to the third-party server. But the third-party server causes the problems of high cost, long time delay, easy privacy disclosure and the like. Therefore, a method for establishing long IP data connections is needed.
Disclosure of Invention
The invention mainly aims to provide a method for establishing long IP data connection, 5G gateway equipment and computer equipment, and aims to solve the problems of high cost, long time delay and easy privacy disclosure caused by the aid of a third-party server in the existing long IP data link connection process.
The invention provides a method for establishing long IP data connection, which comprises the following steps:
acquiring a first real-time IP address of each first sub-device connected with the 5G gateway device, and updating the first real-time IP address into an addressing index table; the addressing index table records the corresponding relation of communication parameters of each first sub-device and each device in the interaction authority range of the first sub-device, wherein the communication parameters comprise MAC addresses, IP addresses and SIM card numbers of the 5G gateway devices; each device in the interaction authority range is a far-end 5G gateway device or a second sub-device connected with the far-end 5G gateway device;
if the change of the IP address of any one of the first sub-devices is detected, generating a corresponding first RCS short message based on the addressing index table; the first RCS short message at least comprises a first real-time IP address and an MAC address corresponding to the first sub-equipment;
inquiring the corresponding SIM card number of the first sub-equipment with the changed IP address based on the addressing index table, intercommunicating RCS short messages with 5G gateway equipment belonging to the equipment within the interaction authority range through the SIM card number, and analyzing second RCS short messages sent by the 5G gateway equipment belonging to the equipment so as to obtain a second real-time IP address contained in the second RCS short messages;
and controlling the first sub-equipment with the changed IP address to establish IP data long connection with the equipment corresponding to the second real-time IP address.
Further, the step of acquiring the first real-time IP address of each first sub-device connected to the 5G gateway device and updating the first real-time IP address into the addressing index table includes:
acquiring a first real-time IP address corresponding to each first sub-device based on the MAC address of each first sub-device;
judging whether the obtained first real-time IP address is different from an IP address corresponding to the MAC address in the addressing index table or not;
if the difference exists, the first sub-equipment with the difference is extracted, and the IP address of the first sub-equipment in the addressing index table is updated to the corresponding first real-time IP address.
Further, before the step of acquiring the first real-time IP address of each first sub-device connected to the 5G gateway device and updating the first real-time IP address into the addressing index table, the step of selecting a device in the interaction right range as a remote 5G gateway device further includes:
acquiring a first control authority of the remote 5G gateway device, wherein the first control authority is used for indicating each first sub-device which is allowed to be controlled by the remote 5G gateway device, and establishing a first corresponding relation between the remote 5G gateway device and each first sub-device according to the first control authority;
and importing the first corresponding relation into the addressing index table.
Further, before the steps of acquiring the first real-time IP address of each first sub-device connected to the 5G gateway device and updating the first real-time IP address into the addressing index table, the method further includes:
acquiring second control authority of the second sub-devices, wherein the second control authority is used for indicating the first sub-devices which are respectively allowed to be controlled by each second sub-device, and establishing a second corresponding relation between the second sub-devices and the first sub-devices according to the second control authority;
and importing the second corresponding relation into the addressing index table.
Further, before the step of querying the corresponding SIM card number based on the addressing index table, the first sub-device that changes the IP address by the SIM card number intercommunicates an RCS short message with the 5G gateway device to which the device in the interaction authority range belongs through the SIM card number, and analyzes a second RCS short message sent by the 5G gateway device to which the device belongs, so as to obtain a second real-time IP address included in the second RCS short message, the method further includes:
acquiring an RCS short message protocol between each device in an interactive authority range; and the RCS short message protocol is used for analyzing the RCS short message sent by the equipment to acquire the corresponding second real-time IP address.
Further, after the step of establishing the IP data long connection between the first sub-device controlling the change of the IP address and the device corresponding to the second real-time IP address, the method further includes:
analyzing the received IP data packet to obtain the IP address of the first sub-equipment corresponding to the IP data packet;
and forwarding the IP data packet to the first sub-equipment corresponding to the IP address.
Further, the step of acquiring the first real-time IP address of each first sub-device connected to the 5G gateway device and updating the first real-time IP address into the addressing index table includes:
detecting MAC addresses of various first sub-devices connected with 5G gateway devices, and distributing corresponding first real-time IP addresses based on the MAC addresses of the first sub-devices;
and inputting the corresponding relation between the MAC address of each first sub-device and the first real-time IP address of the first sub-device into an addressing index table.
The invention also provides a 5G gateway device, comprising:
the IP address updating module is used for acquiring a first real-time IP address of each first sub-device connected with the 5G gateway device and updating the first real-time IP address into an addressing index table; the addressing index table records the corresponding relation of communication parameters of each first sub-device and each device in the interaction authority range of the first sub-device, wherein the communication parameters comprise MAC addresses, IP addresses and SIM card numbers of the 5G gateway devices; each device in the interaction authority range is a far-end 5G gateway device or a second sub-device connected with the far-end 5G gateway device;
the RCS short message generating module is used for generating a corresponding first RCS short message based on the addressing index table if the change of the IP address of any one of the first sub-devices is detected; the first RCS short message at least comprises a first real-time IP address and an MAC address corresponding to the first sub-equipment;
the communication module is used for inquiring the corresponding SIM card number of the first sub-equipment with the changed IP address based on the addressing index table, communicating RCS short messages with 5G gateway equipment belonging to the equipment within the interaction authority range through the SIM card number, and analyzing a second RCS short message sent by the 5G gateway equipment belonging to the equipment so as to acquire a second real-time IP address contained in the second RCS short message;
and the IP data long connection establishing module is used for controlling the first sub-equipment with the changed IP address to establish the IP data long connection with the equipment corresponding to the second real-time IP address.
The invention also provides a computer device comprising a memory storing a computer program and a processor implementing the steps of any of the above methods when the processor executes the computer program.
The invention also provides a computer-readable storage medium, on which a computer program is stored, which computer program, when being executed by a processor, carries out the steps of the method of any of the above.
The invention has the beneficial effects that: through the mutual RCS short message of 5G gateway equipment and the equipment within the interactive authority scope, in order to obtain the second real-time IP address that corresponds, and send first real-time IP address for far-end equipment, so that two equipment that need carry out the IP connection all know the real-time IP address of the other side, and then realize establishing the IP data long connection with two equipment that need carry out the IP connection, need not forward with the help of the storage of third party's server, data transmission low delay has been realized, data transmission's cost has been reduced, and be favorable to protecting privacy.
Drawings
Fig. 1 is a flowchart illustrating a method for establishing an IP data long connection according to an embodiment of the present invention;
fig. 2 is a block diagram of a 5G gateway device according to an embodiment of the present invention;
FIG. 3 is a block diagram of a storage medium according to an embodiment of the present invention;
FIG. 4 is a block diagram of a computer device according to an embodiment of the present invention.
The implementation, functional features and advantages of the objects of the present invention will be further explained with reference to the accompanying drawings.
Detailed Description
The technical solutions in the embodiments of the present invention will be clearly and completely described below with reference to the drawings in the embodiments of the present invention, and it is obvious that the described embodiments are only a part of the embodiments of the present invention, and not all of the embodiments. All other embodiments, which can be derived by a person skilled in the art from the embodiments given herein without making any creative effort, shall fall within the protection scope of the present invention.
It should be noted that all directional indicators (such as up, down, left, right, front, back, etc.) in the embodiments of the present invention are only used to explain the relative position relationship between the components, the motion situation, etc. in a specific posture (as shown in the drawings), and if the specific posture is changed, the directional indicator is changed accordingly, and the connection may be a direct connection or an indirect connection.
The term "and/or" herein is merely an association describing an associated object, meaning that three relationships may exist, e.g., a and B, may mean: a exists alone, A and B exist simultaneously, and B exists alone.
In addition, the descriptions related to "first", "second", etc. in the present invention are only for descriptive purposes and are not to be construed as indicating or implying relative importance or implicitly indicating the number of technical features indicated. Thus, a feature defined as "first" or "second" may explicitly or implicitly include at least one such feature. In addition, technical solutions between various embodiments may be combined with each other, but must be realized by a person skilled in the art, and when the technical solutions are contradictory or cannot be realized, such a combination should not be considered to exist, and is not within the protection scope of the present invention.
Referring to fig. 1, the present invention provides a method for establishing an IP data long connection, including:
s1: acquiring a first real-time IP address of each first sub-device connected with the 5G gateway device, and updating the first real-time IP address into an addressing index table; the addressing index table records the corresponding relation of communication parameters of each first sub-device and each device in the interaction authority range of the first sub-device, wherein the communication parameters comprise MAC addresses, IP addresses and SIM card numbers of the 5G gateway devices; each device in the interaction authority range is a far-end 5G gateway device or a second sub-device connected with the far-end 5G gateway device;
s2: if the change of the IP address of any one of the first sub-devices is detected, generating a corresponding first RCS short message based on the addressing index table; the first RCS short message at least comprises a first real-time IP address and an MAC address corresponding to the first sub-equipment;
s3: inquiring the corresponding SIM card number of the first sub-equipment with the changed IP address based on the addressing index table, intercommunicating RCS short messages with 5G gateway equipment belonging to the equipment within the interaction authority range through the SIM card number, and analyzing second RCS short messages sent by the 5G gateway equipment belonging to the equipment so as to obtain a second real-time IP address contained in the second RCS short messages;
s4: and controlling the first sub-equipment with the changed IP address to establish IP data long connection with the equipment corresponding to the second real-time IP address.
As described in step S1, since the IP address of each first sub-device in the 5G gateway is constantly changed and the MAC address thereof is fixed and unchanged, an addressing index table may be established according to the changed MAC address of the first sub-device corresponding to the changed IP address of the first sub-device, and the IP address of the first sub-device in the addressing index table is updated in real time. Certainly, the addressing index table at least further includes a SIM card number of the remote device, an IP address provided by the remote device, an IP address and a MAC address of each first sub device in the 5G gateway, and a SIM card number of the 5G gateway device; the remote device refers to each device in the interaction authority range of the first sub-device, and may be a remote 5G gateway device, or a second sub-device connected to the remote 5G gateway device. The devices within the interaction authority range of the first sub-device are the devices having control authority or controlled authority to the first sub-device. When the remote device is a remote 5G gateway device, the addressing index table may be as shown in table 1 below:
TABLE 1
Figure BDA0002642953470000071
In some embodiments, one first sub-device may correspond to devices within a plurality of interaction right ranges, a device within an interaction right range may also correspond to the plurality of first sub-devices, and further, a device within an interaction right range may correspond to the plurality of 5G gateway devices, which is not limited in this application, and if a device within an interaction right range is a far-end 5G gateway device, an associated second sub-device may correspond to the plurality of first sub-devices, and also may correspond to one first sub-device. The addressing index table may further include a right for the corresponding device to establish connection with each first sub-device, that is, a corresponding relationship with each first sub-device. In this embodiment, only one device in the interaction right range is taken as an example for explanation, and it should be understood that when RCS short message communication is performed subsequently, the device in the interaction right range may be sent to the corresponding device in the interaction right range according to the correspondence between the SIM card number of the device in the interaction right range and the 5G gateway device in the addressing index table.
As described in step S2, when it is detected that the IP address of any first sub-device is changed, a corresponding first RCS short message is generated based on the addressing table, where the first RCS short message is to send the changed IP address of the first sub-device to the corresponding device (if the device in the interaction right range is the terminal device, the changed IP address is directly sent to the corresponding terminal device, and if the device in the interaction right range is the far-end 5G gateway device, the changed IP address is sent to the corresponding second sub-device through the far-end 5G gateway device).
As described in step S3, the RCS short message is intercommunicated with the devices within the interaction right range, that is, the first RCS short message is sent to the device within the corresponding interaction right range, the second RCS short message sent by the device within the interaction right range is received, and the second RCS short message is analyzed to obtain the corresponding second real-time IP address, where the device corresponding to the second real-time IP address may be a device within the interaction right range (if the device within the interaction right range is a terminal device), or may be a second sub-device connected to the device within the interaction right range (if the device within the interaction right range is a far-end 5G gateway device). And enabling the devices corresponding to the first sub-device and the second real-time IP address to mutually know the real-time IP address of the other side.
As described in step S4, when the first sub-device and the device corresponding to the second real-time IP address know the real-time IP address of the other device, the corresponding sub-first device and the corresponding device may be connected with each other for long IP data.
In this embodiment, the step S1 includes:
s101: acquiring a first real-time IP address corresponding to each first sub-device based on the MAC address of each first sub-device;
s102: judging whether the obtained first real-time IP address is different from an IP address corresponding to the MAC address in the addressing index table or not;
s103: if the difference exists, the first sub-equipment with the difference is extracted, and the IP address of the first sub-equipment in the addressing index table is updated to the corresponding first real-time IP address.
As described in the foregoing steps S101 to S103, the updating may be performed by first obtaining the first real-time IP address of each first sub-device in the 5G gateway, where the obtaining is performed by the first sub-device directly sending the MAC address and the first real-time IP address to the 5G gateway device, and since the MAC address is fixed and unchanged, the first real-time IP address may be corresponding to the corresponding first sub-device. Then judging whether the acquired first real-time IP address of the first sub-equipment is the same as the IP address of the corresponding first sub-equipment recorded in the addressing index table or not; if the two sub-devices are different, the corresponding IP address recorded in the addressing index table can be updated to the corresponding first real-time IP address so as to complete the updating of the IP address of each first sub-device in the addressing index table, so that the corresponding RCS short message can be generated based on the first real-time IP address subsequently and sent to the devices within the interaction authority range.
In an embodiment, the device in the interaction right range is a remote 5G gateway device, and before the step S1, the method further includes:
s001: acquiring a first control authority of the remote 5G gateway device, wherein the first control authority is used for indicating each first sub-device which is allowed to be controlled by the remote 5G gateway device, and establishing a first corresponding relation between the remote 5G gateway device and each first sub-device according to the first control authority;
s002: and importing the first corresponding relation into the addressing index table.
As described in the foregoing steps S001 to S002, when the device in the interaction right range is the terminal device, the first control right of the device in the interaction right range may be obtained, for example, the first control right is to only allow the terminal device to perform IP connection with the device 1, but not to perform IP connection with the device 2, and then the first corresponding relationship between the terminal device and each first sub-device in the 5G gateway is established according to the first control right, and is imported into the addressing index table, and then the IP data length connection is established with the device in the interaction right range according to the first corresponding relationship in the addressing index table. It should be understood that the IP data long connection may be simultaneously established with the devices in multiple interaction authority ranges, the devices in the multiple interaction authority ranges may have the same or different authorities, and then different first corresponding relationships may be established according to the authorities of the devices in the respective interaction authority ranges, so as to implement control of the devices in the interaction authority ranges on different first sub-devices. Specifically, the devices within the interaction authority range may be mobile phones, each first sub-device may be an intelligent sound box, an intelligent television, or other intelligent products, different mobile phones have different management authorities for different intelligent homes, then a first corresponding relationship may be established based on the first corresponding relationship, and then the second real-time IP address of the mobile phone with the management authority may be sent to the corresponding first sub-device, and if there is no mobile phone with the management authority, the second real-time IP address may not be sent to the first sub-device.
In another embodiment, the device in the interaction right range is a second sub-device connected to the remote 5G gateway device, and before the step S1, the method further includes:
s011: acquiring second control authority of the second sub-devices, wherein the second control authority is used for indicating the first sub-devices which are respectively allowed to be controlled by each second sub-device, and establishing a second corresponding relation between the second sub-devices and the first sub-devices according to the second control authority;
s012: and importing the second corresponding relation into the addressing index table.
As described in the foregoing steps S011 through S012, when the device in the interaction right range is the far-end 5G gateway device, the second control right of each second sub-device in the interaction right range may be acquired in such a manner that the far-end 5G gateway device acquires the second control right of the second sub-device connected based on the near field communication technology, and then sends the second control right to the 5G gateway device in the form of the second RCS short message, where the second control right may be led into an index table in the far-end 5G gateway device and then regenerated into the second RCS short message. After receiving the second RCS short message, the 5G gateway device analyzes the second RCS short message, generates a second corresponding relationship according to the obtained second control authority, introduces the second corresponding relationship into the addressing index table for recording, and establishes long IP data connection between the corresponding first sub-device and a second sub-device in the device within the interaction authority range corresponding to the second real-time IP address.
In this embodiment, before the step S3, the method further includes:
s201: acquiring an RCS short message protocol between each device in an interactive authority range; the RCS short message protocol is used for analyzing the RCS short message sent by the equipment in the interaction authority range to acquire the corresponding second real-time IP address.
As described in step S201, the short message protocol between the 5G gateway device and each device in the interaction authority range may be designed in advance, and when the RCS short message of the device in the interaction authority range is obtained, the RCS short message protocol between the 5G gateway device and each device in the interaction authority range may be obtained, and the RCS short message protocol is analyzed according to the RCS short message protocol to obtain the corresponding second real-time IP address. The RCS short message protocol may be a special algorithm, for example, the corresponding second real-time IP address is compiled into a character string, and then the second real-time IP address is resolved based on the RCS short message protocol. In addition, the corresponding first RCS short message is generated based on the addressing index table, which may be based on the above-mentioned RCS short message protocol or another RCS short message protocol.
In this embodiment, after the step S4, the method further includes:
s501: analyzing the received IP data packet to obtain the IP address of the first sub-equipment corresponding to the IP data packet;
s502: and forwarding the IP data packet to the first sub-equipment corresponding to the IP address.
As described in the foregoing steps S501 to S502, the received IP data packet is analyzed, and since the first real-time IP addresses of all the first sub-devices are sent to the devices within the interaction authority range before, the IP data packet carries corresponding first real-time IP address information, the 5G gateway device identifies the first real-time IP address carried by the IP data packet, and then forwards the IP data packet to the corresponding first sub-device, in other embodiments, the 5G gateway device may directly analyze the IP data packet, and then send the control data content included in the IP data packet to the corresponding first sub-device.
In this embodiment, the step S1 includes:
s111: detecting MAC addresses of various first sub-devices connected with 5G gateway devices, and distributing corresponding first real-time IP addresses based on the MAC addresses of the first sub-devices;
s112: and inputting the corresponding relation between the MAC address of each first sub-device and the first real-time IP address of the first sub-device into an addressing index table.
As described in the foregoing steps S111-S112, when the first sub-device is connected to the 5G gateway device, a corresponding first real-time IP address may be allocated based on the MAC address of the first sub-device, and then the corresponding relationship is established and input into the addressing index table.
Referring to fig. 2, the present invention further provides a 5G gateway device, including:
the IP address updating module 10 is configured to obtain a first real-time IP address of each first sub-device connected to the 5G gateway device, and update the first real-time IP address into the addressing index table; the addressing index table records the corresponding relation of communication parameters of each first sub-device and each device in the interaction authority range of the first sub-device, wherein the communication parameters comprise MAC addresses, IP addresses and SIM card numbers of the 5G gateway devices; each device in the interaction authority range is a far-end 5G gateway device or a second sub-device connected with the far-end 5G gateway device;
the RCS short message generating module 20 is configured to generate a corresponding first RCS short message based on the addressing index table if it is detected that the IP address of any one of the first sub-devices changes; the first RCS short message at least comprises a first real-time IP address and an MAC address corresponding to the first sub-equipment;
the communication module 30 is configured to query the first sub-device with the changed IP address for the corresponding SIM card number based on the addressing index table, to intercommunicate RCS short messages with the 5G gateway device belonging to the device within the interaction authority range via the SIM card number, and to analyze a second RCS short message sent by the 5G gateway device belonging to the device, so as to obtain a second real-time IP address included in the second RCS short message;
and the IP data long connection establishing module 40 is configured to control the first sub-device with the changed IP address to establish an IP data long connection with the device corresponding to the second real-time IP address.
The IP address of each first sub-device in the 5G gateway is constantly changing, and the MAC address is fixed and unchangeable, so that an addressing index table can be established according to the changed IP address of the first sub-device corresponding to the unchangeable MAC address of the first sub-device, and the IP address of the first sub-device in the addressing index table is updated in real time. Certainly, the addressing index table at least further includes a SIM card number of the remote device, an IP address provided by the remote device, an IP address and a MAC address of each first sub device in the 5G gateway, and a SIM card number of the 5G gateway device; the remote device refers to each device in the interaction authority range of the first sub-device, and may be a remote 5G gateway device, or a second sub-device connected to the remote 5G gateway device. The devices within the interaction authority range of the first sub-device are the devices having control authority or controlled authority to the first sub-device. When the remote device is a remote 5G gateway device, the addressing index table may be as shown in table 1 below:
TABLE 1
Figure BDA0002642953470000121
In some embodiments, one first sub-device may correspond to devices within a plurality of interaction right ranges, a device within an interaction right range may also correspond to the plurality of first sub-devices, and further, a device within an interaction right range may correspond to the plurality of 5G gateway devices, which is not limited in this application, and if a device within an interaction right range is a far-end 5G gateway device, an associated second sub-device may correspond to the plurality of first sub-devices, and also may correspond to one first sub-device. The addressing index table may further include a right for the corresponding device to establish connection with each first sub-device, that is, a corresponding relationship with each first sub-device. In this embodiment, a device within the interaction right range is taken as an example for explanation, and it should be understood that when RCS short message communication is performed subsequently, the device within the interaction right range may be sent to a device within the corresponding interaction right range according to a correspondence between the SIM card number of the device within the interaction right range and the 5G gateway device in the addressing index table. And when the change of the IP address of any first sub-equipment is detected, generating a corresponding first RCS short message based on the addressing index table, wherein the first RCS short message is used for sending the IP address of the changed first sub-equipment to the corresponding equipment (if the equipment in the interaction authority range is the terminal equipment, the IP address of the changed first sub-equipment is directly sent to the corresponding terminal equipment, and if the equipment in the interaction authority range is the far-end 5G gateway equipment, the IP address of the changed first sub-equipment is sent to the corresponding second sub-equipment through the far-end 5G gateway equipment).
And communicating the RCS short messages with the equipment within the interaction authority range, namely sending the first RCS short message to the equipment within the corresponding interaction authority range, receiving a second RCS short message sent by the equipment within the interaction authority range, analyzing the second RCS short message to obtain a corresponding second real-time IP address, wherein the equipment corresponding to the second real-time IP address can be the equipment within the interaction authority range (if the equipment within the interaction authority range is terminal equipment) or second sub-equipment connected with the equipment within the interaction authority range (if the equipment within the interaction authority range is far-end 5G gateway equipment). And enabling the devices corresponding to the first sub-device and the second real-time IP address to mutually know the real-time IP address of the other side.
When the sub-devices and the devices corresponding to the second real-time IP address know the real-time IP addresses of the other side, the corresponding sub-devices and the corresponding devices can be connected in an IP data length mode.
In this embodiment, the IP address updating module 10 includes:
the first real-time IP address acquisition submodule is used for acquiring the first real-time IP address of each sub-device in the 5G gateway in the addressing index table;
the first real-time IP address judgment submodule is used for judging whether the obtained first real-time IP address is different from the IP addresses of all the sub-devices in the 5G gateway in the addressing index table;
and the sub-device extracting sub-module is used for extracting the sub-devices with the IP addresses different from the first real-time IP address in the addressing index table and updating the IP addresses of the sub-devices with the corresponding first real-time IP address if the sub-devices are different from the first real-time IP address.
The updating method may be that the first real-time IP address of each sub-device in the 5G gateway is obtained first, and the obtaining method is that the sub-device directly sends the MAC address and the first real-time IP address to the 5G gateway device. Then judging whether the acquired first real-time IP address of the sub-device is the same as the corresponding IP address recorded in the addressing index table; if the acquired first real-time IP address is different from the corresponding IP address recorded in the addressing index table, the corresponding IP address recorded in the addressing index table can be updated to the corresponding first real-time IP address so as to complete the updating of the IP address of each sub-device in the addressing index table, so that the corresponding RCS short message can be generated based on the first real-time IP address subsequently and sent to the devices within the interactive authority range.
In one embodiment, the device in the interaction right range is a remote 5G gateway device, and the 5G gateway device further includes:
an authority acquisition first module, configured to acquire a first control authority of the remote 5G gateway device, where the first control authority is used to indicate each first sub-device that the remote 5G gateway device allows to control, and establish a first corresponding relationship between the remote 5G gateway device and each first sub-device according to the first control authority;
and the first corresponding relation importing module is used for importing the first corresponding relation into the addressing index table.
When the device in the interactive authority range is a terminal device, a first control authority of the device in the interactive authority range may be obtained, for example, the first control authority is to only allow the terminal device to perform IP connection with the device 1, but not to perform IP connection with the device 2, a first corresponding relationship between the terminal device and each first sub-device in the 5G gateway is established according to the first control authority, and is imported into the addressing index table, and then, according to the first corresponding relationship in the addressing index table, an IP data long connection is established with the device in the interactive authority range. It should be understood that the IP data long connection may be simultaneously established with the devices in multiple interaction authority ranges, the devices in the multiple interaction authority ranges may have the same or different authorities, and then different first corresponding relationships may be established according to the authorities of the devices in the respective interaction authority ranges, so as to implement control of the devices in the interaction authority ranges on different first sub-devices. Specifically, the devices within the interaction authority range may be mobile phones, each first sub-device may be an intelligent sound box, an intelligent television, or other intelligent products, different mobile phones have different management authorities for different intelligent homes, then a first corresponding relationship may be established based on the first corresponding relationship, and then the second real-time IP address of the mobile phone with the management authority may be sent to the corresponding first sub-device, and if there is no mobile phone with the management authority, the second real-time IP address may not be sent to the first sub-device.
In another embodiment, the device in the interaction right range is a second sub-device connected to the remote 5G gateway device, and the 5G gateway device includes:
the permission acquisition module is used for acquiring a second control permission of the second sub-devices, wherein the second control permission is used for indicating the first sub-devices which are respectively allowed to be controlled by each second sub-device, and establishing a second corresponding relation between the second sub-devices and the first sub-devices according to the second control permission;
and the second corresponding relation importing module is used for importing the second corresponding relation into the addressing index table.
When the device in the interactive authority range is the far-end 5G gateway device, the control authority of each far-end sub-device in the interactive authority range can be acquired in a manner that the far-end 5G gateway device acquires the hole authority of the far-end sub-device connected based on the near field communication technology, and then the control authority is sent to the 5G gateway device in a form of a second RCS short message, wherein the control authority can be led into an index table in the far-end 5G gateway device, and then the second RCS short message is generated. After receiving the second RCS short message, the 5G gateway device analyzes the second RCS short message, generates a second correspondence according to the obtained control authority, imports the second correspondence into an addressing index table for recording, and establishes long IP data connection between the corresponding sub-device and the sub-device in the device within the interaction authority range corresponding to the second real-time IP address.
In this embodiment, the 5G gateway device further includes:
the RCS short message protocol acquisition module is used for acquiring an RCS short message protocol between each device in the interaction authority range; the RCS short message protocol is used for analyzing RCS short messages sent by equipment within the interaction authority range to acquire the corresponding second real-time IP address.
The short message protocol between the 5G gateway device and each device in the interaction authority range can be designed in advance, when the RCS short message of the device in the interaction authority range is obtained, the RCS short message protocol between the 5G gateway device and each device in the interaction authority range can be obtained, and the RCS short message protocol is analyzed according to the RCS short message protocol to obtain the corresponding second real-time IP address. The RCS short message protocol may be a special algorithm, for example, the corresponding second real-time IP address is compiled into a character string, and then the second real-time IP address is resolved based on the RCS short message protocol. In addition, the corresponding first RCS short message is generated based on the addressing index table, which may be based on the above-mentioned RCS short message protocol or another RCS short message protocol.
In this embodiment, the 5G gateway device further includes:
the analysis module is used for analyzing the received IP data packet to obtain the IP address of the first sub-equipment corresponding to the IP data packet;
and the forwarding module is used for forwarding the IP data packet to the first sub-equipment corresponding to the IP address.
Analyzing the received IP data packet, wherein the IP data packet carries corresponding first real-time IP address information because the first real-time IP addresses of all the sub-devices are sent to the devices within the interaction authority range before, the 5G gateway device identifies the first real-time IP address carried by the IP data packet and then forwards the IP data packet to the corresponding first sub-device, and in other embodiments, the 5G gateway device may directly analyze the IP data packet and then send the control data content contained in the IP data packet to the corresponding first sub-device.
In this embodiment, the 5G gateway device further includes:
the system comprises an MAC address acquisition module, a first real-time IP address acquisition module and a second real-time IP address acquisition module, wherein the MAC address acquisition module is used for detecting the MAC address of each first sub-device connected with the 5G gateway device and allocating a corresponding first real-time IP address based on the MAC address of the first sub-device;
and the input module is used for inputting the corresponding relation between the MAC address of each first sub-device and the first real-time IP address of the first sub-device into an addressing index table.
When the sub-device is connected with the 5G gateway device, a corresponding first real-time IP address may be allocated based on the MAC address of the sub-device, and then the corresponding relationship is established and input into the addressing index table.
The invention has the beneficial effects that: through the mutual RCS short message of 5G gateway equipment and the equipment within the interactive authority scope, in order to obtain the second real-time IP address that corresponds, and send first real-time IP address for far-end equipment, so that two equipment that need carry out the IP connection all know the real-time IP address of the other side, and then realize establishing the IP data long connection with two equipment that need carry out the IP connection, need not forward with the help of the storage of third party's server, data transmission low delay has been realized, data transmission's cost has been reduced, and be favorable to protecting privacy.
Referring to fig. 3, the present application further provides a storage medium 100, in which a computer program 200 is stored in the storage medium 100, and when the computer program runs on a computer, the computer is caused to execute the method for establishing the long IP data connection described in the above embodiment.
Referring to fig. 4, the present application further provides a computer device 300 comprising the storage medium 100, when the computer program 200 stored in the storage medium 100 runs on the computer device 300, the computer device 300 is enabled to execute the method for establishing long IP data connection described in the above embodiment through the processor 400 arranged inside the computer device 300.
In the above embodiments, the implementation may be wholly or partially realized by software, hardware, firmware, or any combination thereof. When implemented in software, may be implemented in whole or in part in the form of a computer program product.
The computer program product includes one or more computer instructions. When loaded and executed on a computer, cause the processes or functions described in accordance with the embodiments of the application to occur, in whole or in part. The computer may be a general purpose computer, a special purpose computer, a network of computers, or other programmable device. The computer instructions may be stored on a storage medium or transmitted from one storage medium to another, for example, from one website, computer, server, or data center to another website, computer, server, or data center via wire (e.g., coaxial cable, fiber optic, Digital Subscriber Line (DSL)) or wireless (e.g., infrared, wireless, microwave, etc.). The storage medium may be any available medium that a computer can store or a data storage device including one or more available media integrated servers, data centers, and the like. The usable medium may be a magnetic medium (e.g., floppy Disk, hard Disk, magnetic tape), an optical medium (e.g., DVD), or a semiconductor medium (e.g., Solid State Disk (SSD)), among others.
The above description is only a preferred embodiment of the present invention and is not intended to limit the present invention, and various modifications and changes may be made by those skilled in the art. Any modification, equivalent replacement, or improvement made within the spirit and principle of the present invention should be included in the scope of the claims of the present invention.

Claims (10)

1. A method for establishing long IP data connections, comprising:
acquiring a first real-time IP address of each first sub-device connected with the 5G gateway device, and updating the first real-time IP address into an addressing index table; the addressing index table records the corresponding relation of communication parameters of each first sub-device and each device in the interaction authority range of the first sub-device, wherein the communication parameters comprise MAC addresses, IP addresses and SIM card numbers of the 5G gateway devices; each device in the interaction authority range is a far-end 5G gateway device or a second sub-device connected with the far-end 5G gateway device;
if the change of the IP address of any one of the first sub-devices is detected, generating a corresponding first RCS short message based on the addressing index table; the first RCS short message at least comprises a first real-time IP address and an MAC address corresponding to the first sub-equipment;
inquiring the corresponding SIM card number of the first sub-equipment with the changed IP address based on the addressing index table, intercommunicating RCS short messages with 5G gateway equipment belonging to the equipment within the interaction authority range through the SIM card number, and analyzing second RCS short messages sent by the 5G gateway equipment belonging to the equipment so as to obtain a second real-time IP address contained in the second RCS short messages;
and controlling the first sub-equipment with the changed IP address to establish IP data long connection with the equipment corresponding to the second real-time IP address.
2. The method for establishing long IP data connection according to claim 1, wherein the step of obtaining the first real-time IP address of each first sub-device connected to the 5G gateway device and updating the first real-time IP address into the addressing index table comprises:
acquiring a first real-time IP address corresponding to each first sub-device based on the MAC address of each first sub-device;
judging whether the obtained first real-time IP address is different from an IP address corresponding to the MAC address in the addressing index table or not;
if the difference exists, the first sub-equipment with the difference is extracted, and the IP address of the first sub-equipment in the addressing index table is updated to the corresponding first real-time IP address.
3. The method according to claim 1, wherein the device in the interaction right range is a remote 5G gateway device, and before the step of acquiring the first real-time IP address of each first sub-device connected to the 5G gateway device and updating the first real-time IP address into the addressing index table, the method further comprises:
acquiring a first control authority of the remote 5G gateway device, wherein the first control authority is used for indicating each first sub-device which is allowed to be controlled by the remote 5G gateway device, and establishing a first corresponding relation between the remote 5G gateway device and each first sub-device according to the first control authority;
and importing the first corresponding relation into the addressing index table.
4. The method according to claim 3, wherein the device in the interaction right range is a second sub-device connected to the remote 5G gateway device, and before the step of obtaining the first real-time IP address of each first sub-device connected to the 5G gateway device and updating the first real-time IP address into the addressing index table, the method further comprises:
acquiring second control authority of the second sub-devices, wherein the second control authority is used for indicating the first sub-devices which are respectively allowed to be controlled by each second sub-device, and establishing a second corresponding relation between the second sub-devices and the first sub-devices according to the second control authority;
and importing the second corresponding relation into the addressing index table.
5. The method according to claim 1, wherein before the step of querying the corresponding SIM card number based on the addressing index table, the first sub-device that changes the IP address to intercommunicate the RCS short message with the 5G gateway device belonging to the device in the interaction right range via the SIM card number, and parsing the second RCS short message sent by the 5G gateway device belonging to the device to obtain the second real-time IP address included in the second RCS short message, the method further comprises:
acquiring an RCS short message protocol between each device in an interactive authority range; and the RCS short message protocol is used for analyzing the RCS short message sent by the equipment to acquire the corresponding second real-time IP address.
6. The method for establishing long IP data connection according to claim 1, wherein after the step of controlling the first sub-device with the changed IP address to establish long IP data connection with the device corresponding to the second real-time IP address, the method further comprises:
analyzing the received IP data packet to obtain the IP address of the first sub-equipment corresponding to the IP data packet;
and forwarding the IP data packet to the first sub-equipment corresponding to the IP address.
7. The method for establishing long IP data connection according to claim 1, wherein the step of obtaining the first real-time IP address of each first sub-device connected to the 5G gateway device and updating the first real-time IP address into the addressing index table comprises:
detecting MAC addresses of various first sub-devices connected with 5G gateway devices, and distributing corresponding first real-time IP addresses based on the MAC addresses of the first sub-devices;
and inputting the corresponding relation between the MAC address of each first sub-device and the first real-time IP address of the first sub-device into an addressing index table.
8. A5G gateway device, comprising:
the IP address updating module is used for acquiring a first real-time IP address of each first sub-device connected with the 5G gateway device and updating the first real-time IP address into an addressing index table; the addressing index table records the corresponding relation of communication parameters of each first sub-device and each device in the interaction authority range of the first sub-device, wherein the communication parameters comprise MAC addresses, IP addresses and SIM card numbers of the 5G gateway devices; each device in the interaction authority range is a far-end 5G gateway device or a second sub-device connected with the far-end 5G gateway device;
the RCS short message generating module is used for generating a corresponding first RCS short message based on the addressing index table if the change of the IP address of any one of the first sub-devices is detected; the first RCS short message at least comprises a first real-time IP address and an MAC address corresponding to the first sub-equipment;
the communication module is used for inquiring the corresponding SIM card number of the first sub-equipment with the changed IP address based on the addressing index table, communicating RCS short messages with 5G gateway equipment belonging to the equipment within the interaction authority range through the SIM card number, and analyzing a second RCS short message sent by the 5G gateway equipment belonging to the equipment so as to acquire a second real-time IP address contained in the second RCS short message;
and the IP data long connection establishing module is used for controlling the first sub-equipment with the changed IP address to establish the IP data long connection with the equipment corresponding to the second real-time IP address.
9. A computer device comprising a memory and a processor, the memory storing a computer program, wherein the processor implements the steps of the method of any one of claims 1 to 7 when executing the computer program.
10. A computer-readable storage medium, on which a computer program is stored, which, when being executed by a processor, carries out the steps of the method of any one of claims 1 to 7.
CN202010845600.3A 2020-08-20 2020-08-20 Method for establishing long IP data connection, 5G gateway equipment and computer equipment Active CN112055098B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202010845600.3A CN112055098B (en) 2020-08-20 2020-08-20 Method for establishing long IP data connection, 5G gateway equipment and computer equipment

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202010845600.3A CN112055098B (en) 2020-08-20 2020-08-20 Method for establishing long IP data connection, 5G gateway equipment and computer equipment

Publications (2)

Publication Number Publication Date
CN112055098A true CN112055098A (en) 2020-12-08
CN112055098B CN112055098B (en) 2023-04-07

Family

ID=73601003

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202010845600.3A Active CN112055098B (en) 2020-08-20 2020-08-20 Method for establishing long IP data connection, 5G gateway equipment and computer equipment

Country Status (1)

Country Link
CN (1) CN112055098B (en)

Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102932364A (en) * 2012-11-12 2013-02-13 华为软件技术有限公司 Register method, register device and register system
US20170006164A1 (en) * 2015-06-30 2017-01-05 At&T Intellectual Property I, L.P. Ip carrier peering
CN106487864A (en) * 2015-09-02 2017-03-08 华为终端(东莞)有限公司 The method for building up of data cube computation, service end and mobile terminal
CN108234294A (en) * 2017-12-29 2018-06-29 中兴通讯股份有限公司 Method for message transmission, device, storage medium and electronic device
CN110300404A (en) * 2019-06-27 2019-10-01 维沃移动通信有限公司 A kind of network control method and mobile terminal
US20190387030A1 (en) * 2018-06-19 2019-12-19 T-Mobile Usa, Inc. Session control logic with internet protocol (ip)-based routing

Patent Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102932364A (en) * 2012-11-12 2013-02-13 华为软件技术有限公司 Register method, register device and register system
US20170006164A1 (en) * 2015-06-30 2017-01-05 At&T Intellectual Property I, L.P. Ip carrier peering
CN106487864A (en) * 2015-09-02 2017-03-08 华为终端(东莞)有限公司 The method for building up of data cube computation, service end and mobile terminal
CN108234294A (en) * 2017-12-29 2018-06-29 中兴通讯股份有限公司 Method for message transmission, device, storage medium and electronic device
US20190387030A1 (en) * 2018-06-19 2019-12-19 T-Mobile Usa, Inc. Session control logic with internet protocol (ip)-based routing
CN110300404A (en) * 2019-06-27 2019-10-01 维沃移动通信有限公司 A kind of network control method and mobile terminal

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
张碧君,李威立: "RCS业务与功能分析", 《广东通信技术》 *

Also Published As

Publication number Publication date
CN112055098B (en) 2023-04-07

Similar Documents

Publication Publication Date Title
CN105786451A (en) Method, device and system for processing complicated event
US7433349B2 (en) Automatic compiling of address filter information
CN106878199B (en) Configuration method and device of access information
US11936755B2 (en) Systems and methods for determining a destination location for transmission of packetized data in a network system based on an application server attribute
CN110290044B (en) Method, device and storage medium for shunting VPN (virtual private network) and backbone network
CN105959188B (en) Method and device for controlling user terminal to be on-line
CN115913937A (en) Container multi-network-card network configuration method, device, equipment and storage medium
CN104639555A (en) Request processing method, system and device
CN106453349A (en) An account number login method and apparatus
CN114390044B (en) File uploading method, system, equipment and storage medium
US9942766B1 (en) Caller validation for end service providers
CN106992893A (en) The management method and device of router
CN105281923A (en) Video conference call implementing method and device based on user identifier
CN112055098B (en) Method for establishing long IP data connection, 5G gateway equipment and computer equipment
CN102088401B (en) Addressing processing method and system thereof and network interface device
CN110830477B (en) Service identification method, device, gateway, system and storage medium
CN111127706B (en) Intelligent lock control method, intelligent lock, cloud server and computing equipment
CN110809033B (en) Message forwarding method and device and switching server
CN113746909A (en) Network connection method, device, electronic equipment and computer readable storage medium
CN109962962B (en) Socket connection method and device
CN108173910B (en) Method and system for managing application
WO2022036650A1 (en) Method for establishing ip data persistent connection, and 5g gateway device and computer device
CN114553834B (en) Interaction method and device of 5G core network and IMS network
CN113904980B (en) Channel switching method, device, switch and storage medium
CN108989343A (en) The change of VOIP network and compatible processing method, system, equipment and medium

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