The application is a divisional application of a Chinese patent application with the name of 'network sharing method, device, terminal and computer readable storage medium' filed by the Chinese patent office with the application number of 201910016811.3 on 08.01.2019.
Detailed Description
Embodiments of the present invention will be described in more detail below with reference to the accompanying drawings. While certain embodiments of the present invention are shown in the drawings, it should be understood that the present invention may be embodied in various forms and should not be construed as limited to the embodiments set forth herein, but rather are provided for a more thorough and complete understanding of the present invention. It should be understood that the drawings and the embodiments of the present invention are illustrative only and are not intended to limit the scope of the present invention.
The terms "first," "second," "third," "fourth," and the like in the description and in the claims, and in the above-described drawings, if any, are used for distinguishing between similar elements and not necessarily for describing a particular sequential or chronological order. It is to be understood that the data so used are interchangeable under appropriate circumstances such that the embodiments of the invention described herein are, for example, capable of operation in sequences other than those illustrated or otherwise described herein. Furthermore, the terms "comprises," "comprising," and "having," and any variations thereof, are intended to cover a non-exclusive inclusion, such that a process, method, system, article, or terminal that comprises a list of steps or elements is not necessarily limited to those steps or elements expressly listed, but may include other steps or elements not expressly listed or inherent to such process, method, article, or terminal.
Fig. 1 is an application scenario diagram of a network sharing method according to an embodiment of the present invention, as shown in fig. 1, in the network sharing method according to the embodiment of the present invention, a sharedterminal 1 detects a networking state, and sends shared internet access information to a sharednetwork server 2 in a VPN encryption manner if the networking state is normal, where the shared internet access information includes: networking preparation information, sharing networking modes and networking passwords. The networking preparation information may include, among other things: and sharing the identification and the authentication password of the terminal. And the shared networking server checks whether the shared terminal passes the authentication according to the identification and the authentication password of the shared terminal. If the authentication is passed, the base station 4 nearby is checked according to the current second geographic position in the networking preparation information reported by the base station, the shared internet information reported by the sharedterminal 1 is stored in a preset shared terminal connection table, and meanwhile, the base station 4 nearby is informed to update the connectable shared terminal table through theinternet equipment 3. The sharednetwork server 2 transmits a shared networking service response to the sharedterminal 1, notifying the sharedterminal 1 that the service can be performed. The sharedterminal 1 opensother terminals 5 which need to surf the internet according to the definition of the shared connection mode. Theterminal 5 needing to surf the internet checks the current network condition, judges whether the internet can be connected, if the connection cannot be performed, a shared networking request is sent to the base station 4, the network surfing of the shared terminal is requested, the base station 4 determines available shared terminals near theterminal 5 needing to surf the internet through searching a preset shared terminal connection table, the current first geographic position information of theterminal 5 needing to surf the internet and the current second geographic position information of each shared terminal in the preset shared terminal connection table, and networking preparation information of the available shared terminals is sent to theterminal 5 needing to surf the internet. Theterminal 5 needing to surf the internet matches the networking strategy with the networking preparation information of each available shared terminal, and determines the available shared terminal corresponding to the matched networking preparation information as the target shared terminal. Theterminal 5 needing to access the internet sends the second terminal identification of the target sharing terminal to the base station 4, and the base station 4 obtains the shared internet information of the target sharing terminal according to the second terminal identification of the target sharing terminal and obtains the shared networking mode and the networking password from the shared internet information. And theterminal 5 needing to surf the internet receives the target shared terminal shared networking mode and the networking password sent by the base station 4. And theterminal 5 needing to surf the internet accesses the network according to the sharing networking mode and the networking password of the target sharing terminal. Firstly, physical layer connection is established with a target sharing terminal, and then application layer VPN connection is established with the target sharing terminal. After theterminal 5 to be networked accesses the network, encrypted communication is performed with the sharednetwork server 2 through VPN. Specifically, an internet data request is sent to the sharednetwork server 2, where the internet data request at least includes a first terminal identifier of theterminal 5 to be connected to the internet, an identifier of the connected shared terminal, a charging mode, a current time, an internet request address, and the like. The sharednetwork server 2 acquires the internet surfing data required by the terminal needing internet surfing according to the internet surfing data request, sends the internet surfing data to theterminal 5 needing internet surfing, counts the shared internet surfing use information of the terminal needing internet surfing according to the internet surfing data request and the internet surfing data, and stores the shared internet surfing use information of the terminal needing internet surfing into the shared internet surfing use data table. Theterminal 5 needing to surf the internet obtains the internet surfing data fed back by the sharednetwork server 2 and displays the internet surfing data on a related client or browser. This operation continues until the physical connection with the target shared terminal is broken. In the network sharing method provided in this embodiment, the sharing terminal is used to share the network, and the sharing terminal has mobility, and can enable the terminal requiring internet access to share the network according to the selection of the terminal requiring internet access, and can control the access terminal. The method has the advantages that the network surfing data is obtained from the shared network server in a VPN encryption communication mode, the safety of the request data of the terminal needing to surf the network can be protected, the use data of the terminal needing to surf the network, which surfs the network, adopting the shared network for charging the terminal needing to surf the network can be stored, the terminal needing to surf the network is authenticated before the shared network service is provided by the shared terminal, the safety of the shared terminal is improved, and the network surfing experience of a user is improved.
Example one
Fig. 2 is a flowchart of a network sharing method according to an embodiment of the present invention, and as shown in fig. 2, an execution main body of this embodiment is a network sharing device, and the network sharing device is integrated on a terminal that needs to surf the internet, and the network sharing method according to this embodiment is applied to a terminal that needs to surf the internet, where the terminal that needs to surf the internet may be a terminal such as a smart phone, a tablet computer, a notebook computer, or a computer, and the network sharing method according to this embodiment includes the following steps:
step 201, sending a sharing networking request to a base station; the shared networking request includes: and the base station inquires networking preparation information of the available shared terminal in a preset shared terminal connection table according to the current first geographical position information.
Specifically, in this embodiment, the current network status of the terminal that needs to surf the internet is detected, and if the current network of the terminal that needs to surf the internet cannot surf the internet, a shared networking request is sent to the base station. After the base station receives the sharing networking request, comparing the current first geographic position information in the sharing networking request with the current second geographic position information of all the sharing terminals in a preset sharing terminal connection table, if the difference value between the current first geographic position and the current second geographic position is in a preset range, determining that the sharing terminal is the available sharing terminal of the terminal needing to surf the internet, and acquiring networking preparation information of the available sharing terminal.
The method for detecting the current network condition of the terminal needing to surf the internet can be as follows: the terminal needing to surf the internet detects the current network condition in a mode of sending a ping instruction to a specific internet address or acquiring data from a specific internet through the base station.
Wherein, in the shared networking request, comprising: the terminal comprises a first terminal identification of the terminal needing to surf the internet and current first geographical position information of the terminal needing to surf the internet. The first terminal identification is an identification of the terminal needing to surf the internet, and the first terminal identification can be a mobile phone number, an IMEI number or other information which only represents the terminal needing to surf the internet. The current first geographical location information may be a current GPS location of the terminal that needs to surf the internet.
The preset shared terminal connection table includes shared internet access information of each shared terminal near the base station, and the shared internet access information may include: networking provisioning information, sharing networking means, and networking passwords. Wherein the networking preparation information includes: a second terminal identifier of the shared terminal, current second geographical location information of the shared terminal, a current internet access network, a shared networking mode, connection quality, a charging mode, a charging unit price and the like.
The current internet access network is a network connected with the internet, and can be WiFi, China Mobile/telecom/Unicom and the like. The connection quality may be signal strength and/or connection speed. The charging mode can be charging according to flow or charging according to time, etc.
The sharing networking mode is a mode that a terminal needing to surf the internet is connected with a sharing terminal, such as bluetooth, WLAN and the like.
Instep 202, networking preparation information of available shared terminals sent by the base station is received.
Specifically, in this embodiment, the terminal that needs to surf the internet communicates with the base station through a signaling channel such as a data short message or cell broadcast when the terminal that needs to surf the internet cannot surf the internet, so the networking preparation information of the available shared terminal sent by the base station can be received through the signaling channel such as the data short message or the cell broadcast.
Wherein the networking preparation information of the available shared terminals includes: the second terminal identification of the available shared terminal, the current second geographical position information of the available shared terminal, the current internet access network, the shared networking mode, the connection quality, the charging mode, the charging unit price and the like.
Step 203, determining the target sharing terminal according to the networking preparation information of the available sharing terminals.
Specifically, in this embodiment, the shared internet access manner supported by the terminal that needs to access the internet can be checked, the supported shared internet access manner is compared with the shared internet access manner in the networking preparation information, and the available shared terminal corresponding to the matching networking preparation information is obtained as the target shared terminal.
Or in this embodiment, a user or a user defines a networking policy in advance, matches the networking policy with the networking preparation information of each available shared terminal, and determines the available shared terminal corresponding to the networking preparation information matched with the networking policy as the target shared terminal.
The networking policy is not limited. For example, after the sharing and networking mode is matched, an available sharing terminal with good connection quality is considered in advance as a target sharing terminal. Or after the sharing and networking modes are matched, the available sharing terminal with low charge is considered as the target sharing terminal in advance, or other networking strategies are considered.
And step 204, acquiring the sharing networking mode and the networking password of the target sharing terminal.
Specifically, in this embodiment, the shared internet access information of the target shared terminal is stored in the base station, and the shared networking mode and the networking password in the shared internet access information of the target shared terminal can be obtained in a communication mode with the base station.
And step 205, accessing the network according to the sharing networking mode and the networking password of the target sharing terminal.
Specifically, in this embodiment, the shared networking mode includes a networking name, and the network can be accessed by inputting the networking name and the networking password into a page of the shared networking mode.
In the network sharing method provided by the embodiment, a sharing networking request is sent to a base station; the shared networking request includes: a first terminal identifier of a terminal needing to surf the internet and current first geographical position information of the terminal needing to surf the internet are provided for a base station to inquire networking preparation information of an available shared terminal in a preset shared terminal connection table according to the current first geographical position information; receiving networking preparation information of available shared terminals sent by a base station; determining a target shared terminal according to the networking preparation information of the available shared terminals; acquiring a sharing networking mode and a networking password of a target sharing terminal; and accessing the network according to the sharing networking mode and the networking password of the target sharing terminal. The sharing terminal is adopted to share the network, the sharing terminal has mobility, the terminals needing to surf the internet can share the network according to the selection of the terminals needing to surf the internet, the access terminal can be controlled, and the internet experience of a user is improved.
Example two
Fig. 3 is a method for network sharing according to the second embodiment of the present invention, which is further detailed insteps 203 to 205 based on the method for network sharing according to the first embodiment of the present invention, and further includes a step of requesting data using a shared network. The method for network sharing provided by the present embodiment includes the following steps.
Step 301, sending a shared networking request to a base station; the shared networking request includes: and the base station inquires networking preparation information of the available shared terminal in a preset shared terminal connection table according to the current first geographical position information.
Step 302, receiving the networking preparation information of the available shared terminal sent by the base station.
In this embodiment, the implementation manners ofsteps 301 to 302 are the same as the implementation manners ofsteps 201 to 202 of the network sharing method provided in the first embodiment of the present invention, and are not described in detail herein.
And step 303, acquiring a networking strategy of the terminal needing to be networked.
Further, in this embodiment, a networking policy is preset in the terminal that needs to access the internet. The weight of each networking factor is defined in the networking policy. Networking factors may include: shared networking mode, connection quality, charging mode, etc. Wherein, the weight of the sharing networking mode is 1, that is, the available sharing terminal must support the terminal sharing networking mode needing to access the internet. The weight of the connection quality and the charging mode can be between 0 and 1.
And step 304, determining the available shared terminal corresponding to the networking preparation information matched with the networking strategy as a target shared terminal.
Further, in this embodiment, each networking factor in the networking policy is respectively matched with a corresponding networking factor in the networking preparation information in each available shared terminal, and the matching degree is calculated according to the weight of each networking factor, so that the available shared terminal corresponding to the networking preparation information with the highest matching degree is obtained as the target shared terminal.
And 305, sending the second terminal identifier of the target sharing terminal to the base station, so that the base station can obtain the sharing networking mode and the networking password of the target sharing terminal according to the sharing networking information of the target sharing terminal.
And step 306, receiving the sharing networking mode and the networking password of the target sharing terminal sent by the base station.
Further, in this embodiment, steps 305 to 306 are further refinements ofstep 204 in the first embodiment of the present invention.
Specifically, in this embodiment, the second terminal identifier of the target shared terminal is sent to the base station. And the base station searches the shared internet access information of the target shared terminal in a preset shared terminal connection table according to the second terminal identifier. The shared internet access information comprises a shared networking mode and a networking password. And the base station sends the sharing networking mode and the networking password of the target sharing terminal to the terminal needing to surf the internet.
And the terminal identification of the target sharing terminal is the second terminal identification. The second terminal identifier of the target sharing terminal may be a mobile phone number, an IMEI number, or other information uniquely representing the target sharing terminal.
The shared networking information may further include an authentication password of the shared terminal, so as to authenticate whether the shared terminal is secure.
Table 1 is a preset shared terminal connection table, and only shared internet access information of one shared terminal is shown in table 1.
And 307, accessing the network according to the sharing networking mode and the networking password of the target sharing terminal.
Further, in this embodiment, accessing the network according to the sharing networking mode and the networking password of the target sharing terminal specifically includes:
firstly, a physical layer connection is established with the target sharing terminal according to the sharing networking mode and the networking password of the target sharing terminal.
And secondly, establishing application layer VPN connection with the target sharing terminal according to the sharing networking mode and the networking password of the target sharing terminal.
Table 1: preset connection table for shared terminals
In this embodiment, an application layer VPN connection is established with the target sharing terminal, and a VPN encryption communication mode is adopted when the target sharing terminal communicates with the shared network server, so that the security of the internet access request and the returned data can be effectively protected.
And 308, sending an internet surfing data request to the shared network server by adopting a VPN encryption communication mode so that the shared network server acquires internet surfing data and stores shared internet surfing data of the terminal needing to surf the internet into a shared internet surfing data table.
Further, in this embodiment, the shared network sends the internet data request to the shared network server in a VPN encrypted communication manner. The request for the data on the Internet comprises the following steps: the method comprises the steps of a first terminal identification of a terminal needing to surf the internet, a second terminal identification of a target sharing terminal, a charging mode, request time, a request address and other information. And the shared network server acquires the internet data after receiving the internet data request, and counts the shared internet data use information according to the internet data request and the internet data. And storing the shared internet surfing data use information into a shared internet surfing use data table.
The shared internet data usage information may include: the method comprises the steps of obtaining information such as a first terminal identification of a terminal needing to surf the internet, a second terminal identification of a target sharing terminal, a charging mode, request time, a request address, a data volume of the internet and the like. Table 2 is a shared internet usage data table. Table 2 shows the internet access information of only one internet access request.
Table 2: shared internet access data table
Step 309, receiving the internet access data sent by the shared network server.
And further, receiving the internet surfing data sent by the shared network server, and displaying the internet surfing data on a client or a browser of the terminal needing internet surfing.
In the network sharing method provided by the embodiment, a sharing networking request is sent to a base station; the shared networking request includes: a first terminal identification of a terminal needing to surf the internet and current first geographical position information of the terminal needing to surf the internet, a base station inquires networking preparation information of an available shared terminal in a preset shared terminal connection table according to the current first geographical position information, receives the networking preparation information of the available shared terminal sent by the base station, acquires a networking strategy of the terminal needing to surf the internet, determines the available shared terminal corresponding to the networking preparation information matched with the networking strategy as a target shared terminal, sends a second terminal identification of the target shared terminal to the base station, so that the base station acquires a shared networking mode and a networking password of the target shared terminal according to the shared networking information of the target shared terminal, receives the shared networking mode and the networking password of the target shared terminal sent by the base station, accesses a network according to the shared networking mode and the networking password of the target shared terminal, and sends a request for surfing data to a shared network server by adopting a VPN encryption communication mode, the shared network server obtains the internet surfing data, stores the shared internet surfing data of the terminal needing internet surfing into the shared internet surfing data table, and receives the internet surfing data sent by the shared network server. Because the terminal needing to surf the internet communicates with the shared network server in a VPN encryption mode, the safety of the internet request and the returned data of the terminal needing to surf the internet can be protected, the shared internet use information is stored in the shared network server, the terminal needing to surf the internet can be effectively charged, and the internet experience of a user is further improved.
EXAMPLE III
Fig. 4 is a flowchart of a network sharing method according to a third embodiment of the present invention. As shown in fig. 4, an execution subject of the embodiment is a network sharing device, the network sharing device is integrated on a base station, and the network sharing method provided by the embodiment is applied to the base station, and then the network sharing method provided by the embodiment includes the following steps.
Step 401, receiving a first terminal identifier sent by a terminal needing to surf the internet and current first geographical location information of the terminal needing to surf the internet.
The first terminal identification is an identification of the terminal needing to surf the internet, and the first terminal identification can be a mobile phone number, an IMEI number or other information which only represents the terminal needing to surf the internet. The current first geographical location information may be a current GPS location of the terminal that needs to surf the internet.
Step 402, inquiring the networking preparation information of the available sharing terminal matched with the current first geographical location information in a preset sharing terminal connection table.
The preset shared terminal stores the shared internet access information of all the shared terminals near the base station. Wherein, the sharing of the internet surfing information may include: networking provisioning information, sharing networking means, and networking passwords. The networking preparation information includes: a second terminal identifier of the shared terminal, current second geographical location information of the shared terminal, a current internet access network, a shared networking mode, connection quality, a charging mode, a charging unit price and the like.
Specifically, in this embodiment, the base station compares current first geographic location information in the shared networking request with current second geographic location information of all shared terminals in a preset shared terminal connection table, and if a difference between the current first geographic location and the current second geographic location is within a preset range, determines that the shared terminal is an available shared terminal of the terminal requiring internet access, and obtains networking preparation information of the available shared terminal.
And step 403, sending networking preparation information of the available sharing terminal to the terminal needing to surf the internet, so that the terminal needing to surf the internet determines the target sharing terminal according to the networking preparation information of the available sharing terminal.
Specifically, in this embodiment, the networking preparation information of the available shared terminal is sent to the terminal needing to surf the internet. The terminal needing to surf the internet determines the target shared terminal according to the networking preparation information of the available shared terminal, acquires the shared networking mode and the networking password of the target shared terminal, and accesses the network according to the shared networking mode and the networking password of the target shared terminal.
And step 404, receiving a second terminal identifier of the target shared terminal sent by the terminal needing to surf the internet.
And the terminal identification of the target sharing terminal is the second terminal identification. The second terminal identifier of the target sharing terminal may be a mobile phone number, an IMEI number, or other information uniquely representing the target sharing terminal.
And 405, inquiring a shared networking mode and a networking password in the shared networking information of the target shared terminal corresponding to the second terminal identifier in a preset shared terminal connection table.
The preset connection table of the sharing terminal is shown in table 1. And the base station searches the shared internet access information of the target shared terminal in a preset shared terminal connection table according to the second terminal identifier. The shared internet information comprises a shared networking mode and a networking password.
And step 406, sending the sharing networking mode and the networking password of the target sharing terminal to the terminal needing to surf the internet.
Specifically, in this embodiment, the shared networking mode and the networking password of the target shared terminal are sent to the terminal to be networked, the terminal to be networked may first establish a physical layer connection with the target shared terminal according to the shared networking mode and the networking password of the target shared terminal, and then may establish an application layer VPN connection with the target shared terminal according to the shared networking mode and the networking password of the target shared terminal.
In the network sharing method provided by this embodiment, a first terminal identifier sent by a terminal needing to surf the internet and current first geographical location information of the terminal needing to surf the internet are received; inquiring networking preparation information of the available sharing terminal matched with the current first geographical position information in a preset sharing terminal connection table; sending networking preparation information of the available sharing terminal to the terminal needing to surf the internet, enabling the terminal needing to surf the internet to determine a target sharing terminal according to the networking preparation information of the available sharing terminal, receiving a second terminal identification of the target sharing terminal sent by the terminal needing to surf the internet, inquiring a sharing networking mode and a networking password in the sharing networking information of the target sharing terminal corresponding to the second terminal identification in a preset sharing terminal connection table, and sending the sharing networking mode and the networking password of the target sharing terminal to the terminal needing to surf the internet. The sharing terminal is adopted to share the network, the sharing terminal has mobility, the terminals needing to surf the internet can share the network according to the selection of the terminals needing to surf the internet, the access terminal can be controlled, and the internet experience of a user is improved.
Example four
Fig. 5 is a flowchart of a network sharing method according to a fourth embodiment of the present invention. As shown in fig. 5, the main execution body of the method for network sharing provided by the present embodiment is a network sharing device, and the network sharing device may be integrated in a shared network server. The network sharing method provided by the embodiment is applied to a shared network server. The method for network sharing provided by the present embodiment includes the following steps.
Step 501, receiving shared internet access information sent by a shared terminal, where the shared internet access information includes: networking provisioning information, sharing networking means, and networking passwords.
Specifically, in this embodiment, the shared terminal detects the internet access connection state through the application. And if the internet connection state is normal, sending shared internet information to the shared network server in a VPN encrypted communication mode.
The method for detecting the internet access connection state by the sharing terminal through the application can be as follows: and automatically sending a Ping instruction to a specific Internet address at regular time or detecting the Internet connection state in a mode of acquiring specific data.
The shared internet access information of the shared terminal comprises: the network preparation information of the shared terminal, the sharing networking mode of the shared terminal and the networking password. The networking preparation information of the shared terminal may include: a second terminal identifier of the shared terminal, current second geographical location information of the shared terminal, a current internet access network, a shared networking mode, connection quality, a charging mode, a charging unit price and the like.
Step 502, determining the base station near the shared terminal according to the current second position information of the shared terminal in the networking preparation information.
Wherein the current second location information is current location information of the shared terminal. The current second location information may be a GPS location of the shared terminal.
Specifically, in this embodiment, the current second location information of the shared terminal is compared with the location information of the base station, and if a difference between the current second location and the location of the base station is smaller than a preset threshold, the base station is determined to be a base station near the shared terminal.
Step 503, sending the shared internet access information of the shared terminal to the base station, so that the base station stores the shared internet access information of the shared terminal in a preset shared terminal connection table, and updates the connectable shared terminal table.
Specifically, in this embodiment, the base station receives the shared internet access information of the shared terminal, and stores the shared internet access information of the shared terminal in a preset shared terminal connection table. And storing the identification of the base station and partial information in the shared internet access information of the shared terminal into a connectable shared terminal table. Table 3 is a connectable shared terminal table. Only a part of the shared internet access information of one shared terminal is shown in table 3.
Table 3: connectable sharing terminal table
Step 504, a shared networking service response is sent to the shared terminal.
Specifically, in this embodiment, a shared networking service response is sent to the shared terminal to notify the shared terminal that the shared network service can be performed.
In the network sharing method provided in this embodiment, the shared internet access information sent by the sharing terminal is received, where the shared internet access information includes: determining a base station near the shared terminal according to the current second position information of the shared terminal in the networking preparation information; sending the shared internet access information of the shared terminal to the base station so that the base station stores the shared internet access information of the shared terminal into a preset shared terminal connection table and updates the connectable shared terminal table; and transmitting a shared networking service response to the shared terminal. The sharing terminal is adopted to share the network, the sharing terminal has mobility, the terminals needing to surf the internet can share the network according to the selection of the terminals needing to surf the internet, the access terminal can be controlled, and the internet experience of a user is improved.
EXAMPLE five
Fig. 6 is a flowchart of a network sharing method according to a fifth embodiment of the present invention. As shown in fig. 6, the method for network sharing provided in this embodiment is based on the fourth embodiment of the method for network sharing of the present invention, and further includes a step of authenticating the shared terminal, receiving an internet data request sent by the terminal to be networked in a VPN encrypted communication manner, obtaining internet data according to the internet data request, sending the internet data to the terminal to be networked, and a step of counting shared internet usage information of the terminal to be networked according to the internet data request and the internet data, and storing the shared internet usage information of the terminal to be networked in a shared internet usage data table. The method for network sharing provided by the present embodiment includes the following steps.
Step 601, receiving shared internet access information sent by a shared terminal, where the shared internet access information includes: networking provisioning information, sharing networking means, and networking passwords.
Further, in this embodiment, the shared internet access information further includes an authentication password.
Step 602, authenticating the shared terminal according to the authentication password, and determining whether the authentication is passed, if so, executingstep 603, otherwise, ending.
Further, in this embodiment, whether the shared terminal is normal is checked according to the authentication password, and if the shared terminal is normal, the authentication is passed, and if the shared terminal is not normal, the authentication is not passed.
Step 603, determining the base station near the shared terminal according to the current second position information of the shared terminal in the networking preparation information.
Step 604, sending the shared internet access information of the shared terminal to the base station, so that the base station stores the shared internet access information of the shared terminal in a preset shared terminal connection table, and updates the connectable shared terminal table.
Step 605, the shared networking service response is sent to the shared terminal.
In this embodiment, the implementation manners ofstep 603 to step 605 are the same as the implementation manners ofstep 502 to step 504 in the fourth embodiment of the present invention, and are not described in detail herein.
And 606, receiving the internet surfing data request sent by the terminal needing to surf the internet by adopting a VPN encryption communication mode.
Further, in this embodiment, an internet data request sent by a terminal that needs to surf the internet is received through a shared network in a VPN encrypted communication manner, where the internet data request includes: the method comprises the steps of a first terminal identification of a terminal needing to surf the internet, a second terminal identification of a target sharing terminal, a charging mode, request time, request address and other information.
Step 607, obtaining the internet data according to the internet data request, and sending the internet data to the terminal needing to access the internet.
Step 608, the shared internet access use information of the terminal needing internet access is counted according to the internet access data request and the internet access data.
Step 609, storing the shared internet access use information of the terminal needing to be connected to the internet into the shared internet access use data table.
The description is made in connection with step 608-step 609. Further, in this embodiment, the first terminal identifier of the terminal to be networked, the second terminal identifier of the target shared terminal, the charging mode, the request time, and the request address in the shared internet use information of the terminal to be networked are counted according to the internet data request. And counting the internet surfing data volume according to the internet surfing data. Table 2 is a shared internet usage data table.
In the network sharing method provided in this embodiment, the shared internet access information sent by the sharing terminal is received, where the shared internet access information includes: the network connection preparing information, the sharing network connection mode and the network connection password, the shared terminal is authenticated according to the authentication password, if the authentication is passed, determining a base station near the shared terminal according to the current second location information of the shared terminal in the networking preparation information, transmitting the shared networking information of the shared terminal to the base station, so that the base station stores the shared internet access information of the shared terminal into a preset shared terminal connection table, and updates the connectable sharing terminal table, sends a sharing networking service response to the sharing terminal, receives an internet data request sent by the terminal needing to be connected to the internet by adopting a VPN encryption communication mode, and acquiring internet surfing data according to the internet surfing data request, sending the internet surfing data to the terminal needing internet surfing, counting shared internet surfing use information of the terminal needing internet surfing according to the internet surfing data request and the internet surfing data, and storing the shared internet surfing use information of the terminal needing internet surfing into a shared internet use data table. The terminal to be networked communicates with the shared network server in a VPN encryption mode, so that the safety of the request data of the terminal to be networked can be protected, the shared network server stores shared networking use information, the terminal to be networked can be effectively charged, the shared terminal is authenticated before the shared terminal provides shared network service, and the safety of the shared terminal is guaranteed. Therefore, the internet surfing experience of the user is further improved.
EXAMPLE six
Fig. 7 is a schematic structural diagram of a network sharing apparatus according to a sixth embodiment of the present invention. As shown in fig. 6, the network sharing apparatus provided in this embodiment includes: a sendingmodule 701, a receivingmodule 702, a determiningmodule 703, an obtainingmodule 704 and anetworking module 705.
Wherein, the sendingmodule 701 is configured to send a shared networking request to a base station; the shared networking request includes: and the base station inquires networking preparation information of the available shared terminal in a preset shared terminal connection table according to the current first geographical position information. A receivingmodule 702, configured to receive networking preparation information of an available shared terminal sent by a base station. A determiningmodule 703, configured to determine a target shared terminal according to the networking preparation information of the available shared terminals. An obtainingmodule 704, configured to obtain a sharing networking mode and a networking password of the target sharing terminal. And anetworking module 705 for accessing the network according to the sharing networking mode and the networking password of the target sharing terminal.
The network sharing apparatus provided in this embodiment may execute the technical solution of the method embodiment shown in fig. 2, and the implementation principle and the technical effect are similar, which are not described herein again.
Further, in the network sharing apparatus provided in this embodiment, the determiningmodule 703 is specifically configured to: acquiring a networking strategy of a terminal needing to surf the internet; and determining the available shared terminal corresponding to the networking preparation information matched with the networking strategy as a target shared terminal.
Further, the obtainingmodule 704 is specifically configured to: sending the second terminal identification of the target sharing terminal to the base station so that the base station can obtain the sharing networking mode and the networking password of the target sharing terminal according to the sharing networking information of the target sharing terminal; and receiving the sharing networking mode and the networking password of the target sharing terminal sent by the base station.
Further, the sendingmodule 701 is further configured to: sending an internet surfing data request to a shared network server by adopting a VPN encryption communication mode so that the shared network server acquires internet surfing data and stores shared internet surfing data use information of a terminal needing to surf the internet into a shared internet surfing use data table; and the receiving module is also used for receiving the internet surfing data sent by the shared network server.
Further, the network sharing apparatus provided in this embodiment may execute the technical solution of the method embodiment shown in fig. 3, and the implementation principle and the technical effect are similar, which are not described herein again.
EXAMPLE seven
Fig. 8 is a schematic structural diagram of a network sharing device according to a seventh embodiment of the present invention, and as shown in fig. 8, the network sharing device according to the present embodiment includes: a receivingmodule 801, aquery module 802 and a sendingmodule 803.
The receivingmodule 801 is configured to receive a first terminal identifier sent by a terminal that needs to surf internet and current first geographic location information of the terminal that needs to surf internet. Aquery module 802, configured to query, in a preset shared terminal connection table, networking preparation information of an available shared terminal that matches the current first geographic location information. A sendingmodule 803, configured to send networking preparation information of the available shared terminal to the terminal needing to surf the internet, so that the terminal needing to surf the internet determines the target shared terminal according to the networking preparation information of the available shared terminal. The receivingmodule 801 is further configured to receive a second terminal identifier of the target shared terminal sent by the terminal needing to surf the internet. Thequerying module 802 is further configured to query, in a preset shared terminal connection table, a shared networking mode and a networking password in the shared networking information of the target shared terminal corresponding to the second terminal identifier. The sendingmodule 803 is further configured to send the shared networking mode and the networking password of the target shared terminal to the terminal needing to surf the internet.
The network sharing apparatus provided in this embodiment may execute the technical solution of the method embodiment shown in fig. 4, and the implementation principle and the technical effect are similar, which are not described herein again.
Example eight
Fig. 9 is a schematic structural diagram of a network sharing device according to an eighth embodiment of the present invention, and as shown in fig. 9, the network sharing device according to the present embodiment includes: a receivingmodule 901, a determiningmodule 902 and a sendingmodule 903.
The receivingmodule 901 is configured to receive shared internet access information sent by a shared terminal, where the shared internet access information includes: networking provisioning information, sharing networking means, and networking passwords. A determiningmodule 902, configured to determine a base station near the shared terminal according to the current second location information of the shared terminal in the networking preparation information. A sendingmodule 903, configured to send shared internet access information of the shared terminal to the base station, so that the base station stores the shared internet access information of the shared terminal in a preset shared terminal connection table, and updates the connectable shared terminal table. A sendingmodule 903, configured to send a shared networking service response to the shared terminal.
The network sharing apparatus provided in this embodiment may execute the technical solution of the method embodiment shown in fig. 5, and the implementation principle and the technical effect are similar, which are not described herein again.
Example nine
Fig. 10 is a schematic structural diagram of a network sharing device according to a ninth embodiment of the present invention, and as shown in fig. 10, the network sharing device according to this embodiment further includes, on the basis of the network sharing device according to an eighth embodiment of the present invention: astatistics module 1001 and astorage module 1002.
Further, the receivingmodule 901 is further configured to receive an internet data request sent by a terminal that needs to access the internet by using a VPN encryption communication manner. The sendingmodule 903 is further configured to obtain internet data according to the internet data request, and send the internet data to the terminal needing to access the internet. Thestatistics module 1001 is configured to perform statistics on shared internet access usage information of the terminal that needs to access the internet according to the internet access data request and the internet access data. Thestorage module 1002 is configured to store shared internet access use information of a terminal that needs to access the internet into a shared internet access use data table.
The network sharing apparatus provided in this embodiment may execute the technical solution of the method embodiment shown in fig. 6, and the implementation principle and the technical effect are similar, which are not described herein again.
Example ten
Fig. 11 is a schematic structural diagram of a terminal device provided in a tenth embodiment of the present invention, and as shown in fig. 11, the terminal device provided in this embodiment includes: one ormore processors 1101 andmemory 1102.
Thememory 1102 is used for storing one or more programs. When the one or more programs are executed by the one ormore processors 1101, the one ormore processors 1101 enable the one ormore processors 1101 to implement the method for network sharing provided by the first embodiment of the present invention or the method for network sharing provided by the second embodiment of the present invention.
EXAMPLE eleven
Fig. 12 is a schematic structural diagram of a base station according to an eleventh embodiment of the present invention, and as shown in fig. 12, a terminal device according to this embodiment includes: one ormore processors 1201 andmemory 1202.
Thememory 1202 is used for storing one or more programs. When the one or more programs are executed by the one ormore processors 1201, the one ormore processors 1201 implement the network sharing method provided in the third embodiment of the present invention.
Example twelve
Fig. 13 is a schematic structural diagram of a server according to a twelfth embodiment of the present invention, and as shown in fig. 13, a terminal device according to this embodiment includes: one ormore processors 1301 andmemory 1302.
Thememory 1302 is used for storing one or more programs. When the one or more programs are executed by the one ormore processors 1301, the one ormore processors 1301 enable the network sharing method provided in the fourth embodiment of the present invention or the network sharing method provided in the fifth embodiment of the present invention.
EXAMPLE thirteen
A thirteenth embodiment of the present invention provides a computer-readable storage medium, on which a computer program is stored, where the computer program is executed by a processor to perform the method for network sharing provided in the first embodiment of the present invention or the method for network sharing provided in the second embodiment of the present invention.
Example fourteen
A fourteenth embodiment of the present invention provides a computer-readable storage medium, on which a computer program is stored, where the computer program is executed by a processor to perform the network sharing method provided in the third embodiment of the present invention.
Example fifteen
Fifteenth of the present embodiments provides a computer-readable storage medium, on which a computer program is stored, where the computer program is executed by a processor to perform the network sharing method provided in the fourth of the present embodiments or the network sharing method provided in the fifth of the present embodiments.
In the embodiments provided in the present invention, it should be understood that the disclosed apparatus and method may be implemented in other ways. For example, the above-described apparatus embodiments are merely illustrative, and for example, a division of modules is merely a division of logical functions, and an actual implementation may have another division, for example, a plurality of modules or components may be combined or integrated into another system, or some features may be omitted, or not executed. In addition, the shown or discussed mutual coupling or direct coupling or communication connection may be an indirect coupling or communication connection through some interfaces, devices or modules, and may be in an electrical, mechanical or other form.
Modules described as separate parts may or may not be physically separate, and parts displayed as modules may or may not be physical modules, may be located in one place, or may be distributed on a plurality of network modules. Some or all of the modules may be selected according to actual needs to achieve the purpose of the solution of the present embodiment.
In addition, functional modules in the embodiments of the present invention may be integrated into one processing module, or each of the modules may exist alone physically, or two or more modules are integrated into one module. The integrated module can be realized in a hardware form, and can also be realized in a form of hardware and a software functional module.
Program code for implementing the methods of the present invention may be written in any combination of one or more programming languages. These program codes may be provided to a processor or controller of a general purpose computer, special purpose computer, or other programmable data processing apparatus, such that the program codes, when executed by the processor or controller, cause the functions/operations specified in the flowchart and/or block diagram to be performed. The program code may execute entirely on the machine, partly on the machine, as a stand-alone software package partly on the machine and partly on a remote machine or entirely on the remote machine or server.
In the context of the present invention, a machine-readable medium may be a tangible medium that can contain, or store a program for use by or in connection with an instruction execution system, apparatus, or terminal. The machine-readable medium may be a machine-readable signal medium or a machine-readable storage medium. A machine-readable medium may include, but is not limited to, an electronic, magnetic, optical, electromagnetic, infrared, or semiconductor system, apparatus, or terminal, or any suitable combination of the foregoing. More specific examples of a machine-readable storage medium would include an electrical connection based on one or more wires, a portable computer diskette, a hard disk, a Random Access Memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber, a portable compact disc read-only memory (CD-ROM), an optical storage terminal, a magnetic storage terminal, or any suitable combination of the foregoing.
Further, while operations are depicted in a particular order, this should be understood as requiring that such operations be performed in the particular order shown or in sequential order, or that all illustrated operations be performed, to achieve desirable results. Under certain circumstances, multitasking and parallel processing may be advantageous. Likewise, while several specific implementation details are included in the above discussion, these should not be construed as limitations on the scope of the disclosure. Certain features that are described in the context of separate embodiments can also be implemented in combination in a single implementation. Conversely, various features that are described in the context of a single implementation can also be implemented in multiple implementations separately or in any suitable subcombination.
Although the subject matter has been described in language specific to structural features and/or methodological acts, it is to be understood that the subject matter defined in the appended claims is not necessarily limited to the specific features or acts described above. Rather, the specific features and acts described above are disclosed as example forms of implementing the claims.