Public and private network proxy method based on television network dongle

By using a public/private network proxy method with a TV network dongle, the problem of IPTV players being unable to play private network video resources was solved, improving video smoothness and loading speed, enhancing user experience, and ensuring network security and efficiency.

CN119011899APending Publication Date: 2024-11-22ANDROIDMOV TECH CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202411108468.2
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-08-13
Publication Date
2024-11-22

AI Technical Summary

Technical Problem

Existing IPTV players can only access public network video resources and cannot play private network video resources, resulting in a limited user experience.

Method used

A public-private network proxy method based on a TV network dongle is adopted. By establishing a mapping relationship between the original address object and the proxy address object, and using the proxy server for data forwarding and caching, the conversion from public network address to private network address is realized.

Benefits of technology

It improves video smoothness and loading speed, enhances user experience, ensures compliance and security of network access, reduces bandwidth consumption and improves network efficiency, and reduces instability factors in direct communication with the server.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119011899A_ABST
    Figure CN119011899A_ABST
Patent Text Reader

Abstract

The invention discloses a public and private network proxy method based on television network dongle, which comprises the following steps: S1, receiving a play request event, judging whether the play request event has a proxy request identifier, S2, judging whether a proxy forwarding object is created, S3, after a proxy address object is created, entering a request video stream service process, and S4, executing the proxy forwarding object. The player sends a data request to the server side according to the video URL address; and S4, writing the data into a decoding and rendering module so as to finish the content playing of the proxy interface. According to the method provided by the invention, the proxy server can cache part of data and carry out accelerated forwarding, so that the video fluency and the loading speed can be improved, and the user experience is improved; an access control strategy is realized at the proxy server side, data traffic is managed and monitored, and the compliance and security of network access are guaranteed. The proxy server can compress and optimize the data, so that the bandwidth consumption is reduced, the cost is reduced, and the network efficiency is improved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The invention belongs to the technical field of network transmission, and in particular relates to a public-private network proxy method based on a television network dongle. Background Art

[0002] With the requirements of digital TV and radio and television for player quality, existing IPTV players can only access public network video resources, which has relatively large restrictions on viewing program resources. In addition, due to the requirements for playback quality, it is impossible to use technologies such as FCC and FEC to ensure video playback quality. Therefore, the player has specially developed a public-private network proxy method based on the TV network dongle, which solves the problem of accessing the private network in the public network environment, thereby providing users with a better service experience. Existing technology: It is necessary to purchase more advanced hardware equipment to update the existing network.

[0003] In the existing technology, as digital television and radio and television have higher requirements for player quality, the existing technology only plays public network resources and cannot play video resources on private networks. In the process of digital television development, the requirements for players also urgently need to increase the playback capabilities of private network resources. Summary of the invention

[0004] The purpose of the present invention is to provide a public-private network proxy method based on a TV network dongle to solve the problem that the prior art proposed in the background technology only realizes the playback of public network resources but cannot play private network video resources.

[0005] In order to solve the above technical problems, the technical solution adopted by the present invention is:

[0006] A public-private network proxy method based on a TV network dongle comprises the following steps:

[0007] Step S1, the player receives a play request event sent by the system, and determines whether the play request event has a proxy request identifier. If there is a proxy identifier, the process proceeds to step S2; if there is no proxy identifier, the non-proxy forwarding data process is performed;

[0008] Step S2, determining whether the proxy forwarding object is created, if not, it needs to be created first, if the proxy forwarding object is created, directly establishing a mapping relationship between the original address object and the proxy address object, and storing it in the memory;

[0009] Step S3, the player sends a data request to the video server according to the issued video URL address;

[0010] Step S4, after establishing a connection with the proxy server through itvnet_socket_connect API, the player network protocol layer uses itvnet_socket_send to send the playback signaling through the proxy interface of the proxy server, and the player network protocol layer receives the audio and video data forwarded by the proxy server through itvnet_socket_recvfrom, thereby completing the content playback of the proxy interface.

[0011] According to the above technical solution, in step S1, the non-proxy forwarding data process is specifically as follows:

[0012] Step S101, parse the current requested playback address and create an original address object.

[0013] Step S102: Use the socket API to complete the communication between the player and the video server and the sending and receiving of data.

[0014] According to the above technical solution, step S101 is specifically as follows: requesting the playback address ur l to be converted to the corresponding server ip through dns resolution, obtaining the corresponding server port by parsing the ur l string, and creating the original address object according to the obtained server ip and port.

[0015] According to the above technical solution, in step S102, the client connects to the video server using the connect interface, the client sends data to the video server using the send interface, the client receives data from the video server using the recv interface, and the client closes the connection to the video server using the close interface.

[0016] According to the above technical solution, in step S2, creating a proxy forwarding object is specifically as follows:

[0017] Step 201, the requested playback address URL is converted to the corresponding server IP through DNS resolution, and the corresponding server port is obtained by parsing the URL string;

[0018] Step 202: Create an original address object according to the acquired server IP and port; further parse the current requested playback address to obtain the original address object;

[0019] Step 203: Establish a mapping relationship between the original address object and the proxy address object, and store it in the memory.

[0020] According to the above technical solution, in step 203, the mapping relationship between the original address object and the proxy address object is established by using a map association container to establish a one-to-one mapping between the original address object and the proxy address object, and one original address object corresponds to a corresponding proxy address object.

[0021] According to the above technical solution, in step S3, the player sends a data request to the video server according to the video URL address:

[0022] Step S301, using the original address object created and saved after the video URL address is resolved as the Key value,

[0023] Step S302, find the corresponding proxy address object in the map container according to the mapping relationship;

[0024] Step S303, the client performs data interaction operations such as connecting, closing, and sending and receiving data to the video server through four API interfaces;

[0025] Step S304: The player uses the interface of the proxy address object to connect, close, and send and receive data to the network, thereby converting the public network address to the private network address.

[0026] According to the above technical solution, in step S303, the client connects to the video server using the itvnet_socket_connect interface, the client sends data to the video server using the itvnet_socket_send interface, the client receives data from the video server using the itvnet_socket_recvfrom interface, and the client closes the video server connection using the itvnet_socket_close interface.

[0027] Compared with the prior art, the present invention has the following beneficial effects:

[0028] The method of the present invention can improve the video fluency and loading speed and enhance the user experience because the proxy server can cache part of the data and accelerate forwarding. The access control strategy is implemented on the proxy server side to manage and monitor the data flow to ensure the compliance and security of network access. The proxy server can compress and optimize the data, save bandwidth consumption, reduce costs and improve network efficiency. By establishing a proxy channel, the instability factors of direct communication with the server can be reduced, and the stability and reliability of data transmission can be improved. BRIEF DESCRIPTION OF THE DRAWINGS

[0029] Figure 1 A schematic diagram of the process flow of the present invention is provided. DETAILED DESCRIPTION

[0030] The following will be combined with the drawings in the embodiments of the present invention to clearly and completely describe the technical solutions in the embodiments of the present invention. Obviously, the described embodiments are only part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of the present invention.

[0031] Embodiment 1

[0032] like Figure 1 As shown, a public-private network proxy method based on a TV network dongle is characterized by comprising the following steps:

[0033] Step S1, the player receives a play request event sent by the system, and determines whether the play request event has a proxy request identifier. If there is a proxy identifier, the process proceeds to step 2; if there is no proxy identifier, the non-proxy forwarding data process is performed;

[0034] Step S2, determining whether the proxy forwarding object is created, if not, it needs to be created first, if the proxy forwarding object is created, directly establishing a mapping relationship between the original address object and the proxy address object, and storing it in the memory;

[0035] Step S3, the player sends a data request to the video server according to the issued video URL address;

[0036] Step S4, after establishing a connection with the proxy server through itvnet_socket_connectAPI, the player network protocol layer uses itvnet_socket_send to send the playback signal through the proxy interface, and the player network protocol layer receives the audio and video data forwarded by the proxy server through itvnet_socket_recvfrom, and the data is systemized, thereby completing the content playback of the proxy interface.

[0037] The method of the present invention can improve the video fluency and loading speed and enhance the user experience because the proxy server can cache part of the data and accelerate forwarding. The access control strategy is implemented on the proxy server side to manage and monitor the data flow to ensure the compliance and security of network access. The proxy server can compress and optimize the data, save bandwidth consumption, reduce costs and improve network efficiency. By establishing a proxy channel, the instability factors of direct communication with the server can be reduced, and the stability and reliability of data transmission can be improved.

[0038] Embodiment 2

[0039] This embodiment is a further refinement of the first embodiment.

[0040] Step 1: Upon receiving a play request event, check whether there is a proxy request identifier. If there is a proxy identifier, proceed to step 2; if there is no proxy identifier, proceed to step 5 to perform a non-proxy forwarding data process.

[0041] Step 2: Determine whether the proxy forwarding object has been created. If not, it needs to be created first. The creation is as follows: the requested playback address ur l is converted to the corresponding server ip through dns resolution, and the corresponding server port is obtained by further parsing the ur l string. The original address object is further created based on the obtained server ip and port; the current requested playback address is further parsed to obtain the original address object;

[0042] Then, a mapping relationship between the original address object and the proxy address object is established and stored in memory (a map associative container is used to establish a one-to-one mapping between the original address object and the proxy address object, and one original address object corresponds to this proxy address object).

[0043] If a proxy forwarding object is created, a mapping relationship between the original address object and the proxy address object is directly established and stored in the memory.

[0044] The corresponding code uses a map container to save the mapping relationship between the original address object and the proxy address object.

[0045] Further, the sockaddr_i n data structure is used to represent the original address object, and the xsockaddr_i n is used to represent the proxy address object, and a corresponding relationship between the two is established in the map container.

[0046] The xsockaddr_in data structure consists of the following members:

[0047] xsin_len; the effective length of the data

[0048] xsin_family: Address family, AFX_INET, AFX_INET6 values ​​represent IPv4, IPv6 protocols,

[0049] xsin_port: port number, expressed in network byte order,

[0050] xsin_addr: IP address, expressed in network byte order,

[0051] xsin_zero: Fill field, usually set to 0.

[0052] The sockaddr_in data structure consists of the following members:

[0053] sin_family: Address family, with AF_INET and AF_INET6 values ​​representing IPv4 and IPv6 protocols,

[0054] sin_port: port number, expressed in network byte order,

[0055] sin_addr: IP address, expressed in network byte order,

[0056] sin_zero: Fill field, usually set to 0.

[0057] Step 3. After creating the proxy address object, enter the video stream request business process. The player sends a data request to the server based on the video URL address. In the data interaction process, use the original address object created and saved after the video URL address is resolved as the Key value, and find the corresponding proxy address object in the map container according to the mapping relationship. The client uses the itvnet_socket_connect interface to connect to the server, the client uses the itvnet_socket_send interface to send data to the server, the client uses the itvnet_socket_recvfrom interface to receive data from the server, and the client uses the itvnet_socket_close interface to close the server connection. Four APIs are used to perform data interaction operations on the server, such as connection, closing, and data transmission and reception. The player uses the interface of the proxy address object to realize network connection, closing, and data transmission and reception, thereby realizing the conversion of the public network address to the private network address.

[0058] Step 4. After establishing a connection with the proxy server through the itvnet_socket_connect API, the player network protocol layer uses itvnet_socket_send to send the playback signal through the proxy interface. The player network protocol layer receives the audio and video data forwarded by the proxy service through itvnet_socket_recvfrom, and writes the data into the decoding and rendering module, thereby completing the content playback of the proxy interface.

[0059] Step 5, non-proxy forwarding data flow, parse the current requested playback address, get the original address object (the requested playback address URL is converted to the corresponding server IP through DNS resolution, and the corresponding server port is obtained by further parsing the URL string, and the original address object is created based on the obtained server IP and port), and further use the socketAPI provided by the operating system to complete the communication with the server and the sending and receiving of data. The client connects to the server using the connect interface, the client sends data to the server using the send interface, the client receives data from the server using the recv interface, and the client closes the server connection using the close interface.

[0060] Glossary: ​​dongle, a method of encrypting computer software.

[0061] It should be noted that, in this article, relational terms such as first and second, etc. are only used to distinguish one entity or operation from another entity or operation, and do not necessarily require or imply any such actual relationship or order between these entities or operations. Moreover, the terms "include", "comprise" or any other variants thereof are intended to cover non-exclusive inclusion, so that a process, method, article or device including a series of elements includes not only those elements, but also other elements not explicitly listed, or also includes elements inherent to such process, method, article or device.

[0062] Finally, it should be noted that the above description is only a preferred embodiment of the present invention and is not intended to limit the present invention. Although the present invention has been described in detail with reference to the aforementioned embodiments, those skilled in the art can still modify the technical solutions described in the aforementioned embodiments or replace some of the technical features therein by equivalents. Any modification, equivalent replacement, improvement, etc. made within the spirit and principle of the present invention shall be included in the protection scope of the present invention.

Claims

1. A public and private network proxy method based on TV network dongle, Features: The following steps are involved: Step S1, the player receives a play request event sent by the system, and determines whether the play request event has a proxy request identifier. If there is a proxy identifier, the process proceeds to step S2; if there is no proxy identifier, the non-proxy forwarding data process is performed; Step S2, determining whether the proxy forwarding object is created, if not, it needs to be created first, if the proxy forwarding object is created, directly establishing a mapping relationship between the original address object and the proxy address object, and storing it in the memory; Step S3, the player sends a data request to the video server according to the issued video URL address; Step S4, after establishing a connection with the proxy server through itvnet_socket_connect API, the player network protocol layer uses itvnet_socket_send to send the playback signaling through the proxy interface of the proxy server, and the player network protocol layer receives the audio and video data forwarded by the proxy server through itvnet_socket_recvfrom, thereby completing the content playback of the proxy interface.

2. A public-private network proxy method based on a TV network dongle according to claim 1, Features: In step S1, the non-proxy forwarding data process is specifically as follows: Step S101, parse the current requested playback address and create an original address object. Step S102, using the socket API to complete the communication between the player and the video server and the sending and receiving of data.

3. A public-private network proxy method based on a TV network dongle according to claim 2, Features: Step S101 specifically includes: requesting the playback address URL to be converted to the corresponding server IP through DNS resolution, obtaining the corresponding server port by parsing the URL string, and creating an original address object according to the obtained server IP and port.

4. A public-private network proxy method based on a TV network dongle according to claim 2, Features: In step S102, the client connects to the video server using the connect interface, sends data to the video server using the send interface, receives data from the video server using the recv interface, and closes the connection to the video server using the close interface.

5. A public-private network proxy method based on a TV network dongle according to claim 1, Features: In step S2, creating a proxy forwarding object is specifically as follows: Step 201, the requested playback address URL is converted to the corresponding server IP through DNS resolution, and the corresponding server port is obtained by parsing the URL string; Step 202: Create an original address object according to the acquired server IP and port; further parse the current requested playback address to obtain the original address object; Step 203: Establish a mapping relationship between the original address object and the proxy address object, and store it in the memory.

6. A public-private network proxy method based on a TV network dongle according to claim 5, Features: In step 203, the mapping relationship between the original address object and the proxy address object is established by using a map association container to establish a one-to-one mapping between the original address object and the proxy address object, and one original address object corresponds to a corresponding proxy address object.

7. A public-private network proxy method based on a TV network dongle according to claim 1, Features: In step S3, the player sends a data request to the video server according to the video URL address: Step S301, using the original address object created and saved after the video URL address is resolved as the Key value, Step S302, find the corresponding proxy address object in the map container according to the mapping relationship; Step S303, the client performs data interaction operations such as connecting, closing, and sending and receiving data to the video server through four API interfaces; Step S304: The player uses the interface of the proxy address object to connect to and close the network and send and receive data, thereby converting the public network address to the private network address.

8. A public-private network proxy method based on a TV network dongle according to claim 1, Features: In step S303, the client connects to the video server using the itvnet_socket_connect interface, sends data to the video server using the itvnet_socket_send interface, receives data from the video server using the itvnet_socket_recvfrom interface, and closes the video server connection using the itvnet_socket_close interface.