Disclosure of Invention
The invention aims to provide a WDS connection method, a wireless access point and terminal equipment, which effectively solve the technical problem that connection requests of different modes cannot be automatically processed in the Portal process in the prior art.
The technical scheme provided by the invention is as follows:
a WDS connection method is applied to a wireless access point, the wireless access point is configured to authenticate terminal equipment by adopting a Portal authentication mode, and identification information of the terminal equipment authenticated by Portal is stored in the wireless access point, and the WDS connection method comprises the following steps:
receiving an association request sent by terminal equipment, and associating the terminal equipment according to the association request;
receiving a text request sent by the associated terminal equipment;
judging whether the terminal equipment is connected in a WDS mode or not according to the text request; if so,
judging whether the terminal equipment passes Portal authentication or not according to the identification information of the terminal equipment; if so,
and releasing the terminal equipment, and completing WDS connection of the terminal equipment.
In the technical scheme, after receiving a text request sent by the terminal equipment, the wireless access point immediately judges whether the terminal equipment is connected in a WDS connection mode, if so, further judges whether the terminal equipment completes Portal authentication, and if so, directly releases the terminal equipment to realize WDS connection of the terminal equipment.
Further preferably, in the step of determining whether the terminal device is connected in a WDS manner according to the text request, if it is determined that the terminal device is not connected in a WDS manner,
and feeding back the address of the resource locator obtained by redirection to the terminal equipment to finish Portal authentication of the terminal equipment.
In the technical scheme, if the terminal equipment is judged not to complete Portal authentication and the sent association request is not in a WDS mode, the Portal authentication step of the terminal equipment is directly entered, so that a basis is provided for subsequent WDS connection, authentication conflicts in different connection modes are solved, and convenience is provided for users.
Further preferably, after the redirecting the address of the resource locator is fed back to the terminal device and the Portal authentication of the terminal device is completed, the method includes:
the Portal server feeds back the identification information of the terminal equipment to the wireless access point for storage;
the terminal equipment disconnects with the wireless access point and sends an association request to the wireless access point in a WDS connection mode.
In the technical scheme, if the Portal server finishes Portal authentication of the terminal equipment, the terminal equipment immediately disconnects the connection with the wireless access point, and the wireless access point is reconnected in a WDS connection mode. Therefore, when the terminal equipment accesses the wireless access point in a WDS connection mode, the wireless access point can directly pass through the wireless access point according to the identification information.
Further preferably, the step of feeding back the redirected resource locator address to the terminal device to complete the Portal authentication of the terminal device includes:
the terminal equipment receives a resource locator address sent by a wireless access point and sends a Web page request to a Portal server according to the resource locator address;
the terminal equipment receives a Web page issued by the Portal server, automatically inputs prestored authentication information in the Web page and sends the authentication information to the Portal server so as to authenticate the identity of the terminal equipment.
In the technical scheme, after the terminal equipment acquires the Web page according to the resource locator address sent by the wireless access point, the authentication information is automatically filled in the Web page according to the pre-stored information and sent to the Portal server for authentication, so that the authentication of the terminal equipment is realized, the wireless relay of the terminal equipment is further realized, and convenience is provided for users.
Further preferably, after the step that the terminal device receives a Web page delivered by a Portal server, automatically inputs pre-stored authentication information in the Web page, and sends the authentication information to the Portal server, the method further includes:
the Portal server receives authentication information sent by the terminal equipment;
the Portal server performs identity authentication on the terminal equipment according to the received authentication information;
if the identity authentication is successful, the Portal server completes the identity authentication of the terminal equipment.
The invention also provides a wireless access point, which is configured to authenticate the terminal equipment by adopting a Portal authentication mode, and the wireless access point comprises:
a first processor for processing instructions; and
the first memory is used for storing identification information of the terminal equipment authenticated by Portal and storing a plurality of instructions, and the instructions are suitable for the first processor to load and execute; the plurality of instructions includes:
receiving an association request sent by terminal equipment, and associating the terminal equipment according to the association request;
receiving a text request sent by the associated terminal equipment;
judging whether the terminal equipment is connected in a WDS mode or not according to the text request; if so,
judging whether the terminal equipment passes Portal authentication or not according to the identification information of the terminal equipment; if so,
and releasing the terminal equipment, and completing WDS connection of the terminal equipment.
In the technical scheme, after receiving a text request sent by the terminal equipment, the wireless access point immediately judges whether the terminal equipment is connected in a WDS connection mode, if so, further judges whether the terminal equipment completes Portal authentication, and if so, directly releases the terminal equipment to realize WDS connection of the terminal equipment.
Further preferably, in the step of instructing to determine whether the terminal device is connected in the WDS mode according to the text request, if it is determined that the terminal device is not connected in the WDS mode,
and feeding back the address of the resource locator obtained by redirection to the terminal equipment to finish Portal authentication of the terminal equipment.
In the technical scheme, if the terminal equipment is judged not to finish Portal authentication and the sent association request is not in a WDS mode, the Portal authentication step of the terminal equipment is directly entered, so that a basis is provided for subsequent WDS connection, authentication conflicts in different connection modes are solved, and convenience is provided for users.
Further preferably, after the instructing to feed back the redirected resource locator address to the terminal device and completing the Portal authentication of the terminal device, the method further includes:
and receiving and storing the identification information of the terminal equipment sent by the Portal server.
In the technical scheme, if the Portal server completes Portal authentication of the terminal equipment, the identification information of the terminal equipment is immediately transmitted to the wireless access equipment for storage. Therefore, when the terminal equipment accesses the wireless access point in a WDS connection mode, the wireless access point can directly pass through the wireless access point according to the identification information.
The invention also provides a terminal device, which supports WDS, and comprises:
a second processor for processing instructions; and
a second memory for storing a plurality of instructions, the instructions adapted to be loaded and executed by a second processor; the plurality of instructions includes:
sending an association request to a wireless access point to realize association with the wireless access point;
judging whether Portal authentication is finished in the wireless access point or not; if so,
and sending a text request to the wireless access point in a WDS mode to complete WDS connection.
Further preferably, in instructing whether to complete Portal authentication in the wireless access point, if it is determined that Portal authentication has not been completed in the wireless access point, then,
and sending the text request to the wireless access point in a non-WDS mode.
In the technical scheme, in the terminal equipment, whether Portal authentication is completed in the wireless access point is judged according to the record stored in the terminal equipment, whether WDS mode connection is adopted is further judged, if not, the Portal authentication is not completed by the terminal equipment, then the Portal authentication step is started, the subsequent WDS connection is facilitated, simplicity and convenience are realized, the wireless access point does not need to be manually switched to a corresponding working mode according to different connection modes, manpower and material resources are saved, and convenience is provided for users.
Detailed Description
In order to more clearly illustrate the embodiments of the present invention or the technical solutions in the prior art, the following description will be made with reference to the accompanying drawings. It is obvious that the drawings in the following description are only some examples of the invention, and that for a person skilled in the art, other drawings and embodiments can be derived from them without inventive effort.
For the sake of simplicity, the drawings only schematically show the parts relevant to the present invention, and they do not represent the actual structure as a product.
As shown in fig. 1, a WDS connection method provided by the present invention is applied to a wireless access point, the wireless access point is configured to authenticate a terminal device by using a Portal authentication method, and identification information of the terminal device authenticated by the Portal authentication is stored in the wireless access point, and as can be seen from the figure, the WDS connection method includes:
s10, receiving the association request sent by the terminal device, and associating the terminal device according to the association request;
s20, receiving a text request sent by the associated terminal equipment;
s30 judging whether the terminal device is connected in WDS mode according to the text request; if yes, go to step S40;
s40 judging whether the terminal device passes Portal authentication according to the identification information of the terminal device; if yes, go to step S50;
s50 releases the end device and completes the WDS connection of the end device.
In this embodiment, the terminal device obtains the SSID of the open mode in the wireless access point by scanning, and then sends an association request to the wireless access point. In the process of sending the association request, firstly, the identification information (such as MAC address) of the wireless access point is obtained, then whether Portal authentication is finished in the wireless access point is judged according to the identification information, if the Portal authentication is finished, the association request in a WDS mode is directly sent, and if not, the association request directly enters the Portal authentication process.
After receiving a text request sent by a terminal device, a wireless access point immediately judges whether the terminal device is connected in a WDS connection mode, if so, further judges whether Portal authentication is completed according to identification information (such as MAC (media access control) address) of the terminal device, if the identification information of the terminal device is stored in a memory of the wireless access point, the terminal device is authenticated, further authentication is not needed, the terminal device is directly released to access the Internet, and WDS connection of the terminal device is realized. And if the identifier of the terminal equipment is not stored in the memory of the wireless access point, sending an alarm to prompt the user.
Specifically, in this embodiment, when the terminal device connects to the wireless access point in the WDS mode, the wireless access point is a master device in the WDS connection, and the terminal device is a slave device in the WDS connection (initiates the WDS connection, and serves as a relay terminal). In the working process, after the relay terminal associates a certain wireless access point, if the relay terminal judges that Portal authentication is finished in the wireless access point, a WDS mode connection request is sent to the wireless access point.
As shown in fig. 2, this WDS connection method according to this embodiment includes:
s10, receiving the association request sent by the terminal device, and associating the terminal device according to the association request;
s20, receiving a text request sent by the associated terminal equipment;
s30 judging whether the terminal device is connected in WDS mode according to the text request; if yes, go to step S40; otherwise, jumping to step S60;
s40 judging whether the terminal device passes Portal authentication according to the identification information of the terminal device; if yes, go to step S50;
s50 releases the end device and completes the WDS connection of the end device.
S60, the address of the resource locator obtained by redirection is fed back to the terminal equipment, and Portal authentication of the terminal equipment is completed.
In this embodiment, the terminal device obtains the SSID of the open mode in the wireless access point by scanning, and then sends an association request to the wireless access point. In the process of sending the association request, firstly, the identification information (such as MAC address) of the wireless access point is obtained, then whether Portal authentication is finished in the wireless access point is judged according to the identification information, if the Portal authentication is finished, the association request in a WDS mode is directly sent, and if not, the association request directly enters the Portal authentication process.
After receiving a text request sent by a terminal device, a wireless access point immediately judges whether the terminal device adopts a WDS connection mode for connection, if not, a Resource Locator address (URL) obtained by redirection is sent to the terminal device according to the text request, and a Portal authentication step is entered.
After receiving the resource locator address sent by the wireless access point, the terminal equipment sends a Web page request to a Portal server according to the resource locator address; and after receiving the Web page request, the Portal server transmits the corresponding Web page to the terminal equipment. After the terminal device obtains the Web page, the terminal device automatically inputs pre-stored authentication information (including user name, password and the like) in the Web page and sends the authentication information to the Portal server.
After receiving the authentication information sent by the terminal equipment, the Portal server authenticates the identity of the terminal equipment according to the received authentication information (compares and verifies the received identity information according to prestored information), and if the authentication is successful, the Portal server sends an authentication success message to the wireless access point and sends the identification information of the terminal equipment to the wireless access point for storage; otherwise, the Portal server sends an authentication failure message to the wireless access point and refuses the access of the terminal equipment.
And then, the wireless access point feeds back a Portal authentication success message to the terminal equipment. And the terminal equipment receives the feedback message, then actively disconnects the connection with the wireless access point, acquires the SSID in the open mode in the wireless access point again in a scanning mode, and retransmits the text request in a WDS mode. After receiving the text request, the wireless access point judges that the identification information of the terminal equipment is stored in a list authenticated by Portal, and directly releases the terminal equipment to access the Internet.
Specifically, in this embodiment, when the terminal device connects to the wireless access point in the WDS mode, the wireless access point is a master device in the WDS connection, and the terminal device is a slave device in the WDS connection (initiates the WDS connection, as a relay terminal). In the working process, after the relay terminal associates a certain wireless access point, if the relay terminal judges that Portal authentication is not completed in the wireless access point, the relay terminal imitates the association mode of STA (such as a mobile phone terminal) to send a text request to the wireless access point, and enters the Portal authentication process of the relay terminal. After completing Portal authentication, the relay terminal actively breaks the association with the wireless access point immediately, and resends the text request for WDS connection to the wireless access point, so as to realize network connection of the relay equipment.
As shown in fig. 3, a schematic diagram of a wireless access point provided by the present invention, specifically, the wireless access point is configured to authenticate a terminal device by using a Portal authentication method, and as can be seen from the diagram, the wireless access point 100 includes: a first processor 110 for processing instructions; and the first memory 120 is used for storing the identification information of the terminal equipment authenticated by Portal and storing a plurality of instructions, and the instructions are suitable for the first processor to load and execute.
In one embodiment, the plurality of instructions includes:
receiving an association request sent by terminal equipment, and associating the terminal equipment according to the association request;
receiving a text request sent by associated terminal equipment;
judging whether the terminal equipment is connected in a WDS mode or not according to the text request; if so,
judging whether the terminal equipment passes Portal authentication or not according to the identification information of the terminal equipment; if so,
and releasing the terminal equipment, and completing WDS connection of the terminal equipment.
In another embodiment, the plurality of instructions includes:
receiving an association request sent by terminal equipment, and associating the terminal equipment according to the association request;
receiving a text request sent by associated terminal equipment;
judging whether the terminal equipment is connected in a WDS mode or not according to the text request; if not, the address of the resource locator obtained by redirection is fed back to the terminal equipment, and Portal authentication of the terminal equipment is completed; if so,
judging whether the terminal equipment passes Portal authentication or not according to the identification information of the terminal equipment; if so,
and releasing the terminal equipment, and completing WDS connection of the terminal equipment.
Based on this, in the working process, after the terminal device obtains the SSID of the open mode in the wireless access point through the scanning mode, the terminal device immediately sends an association request to the wireless access point. In the process of sending the association request, firstly, acquiring the identification information (such as MAC address) of the wireless access point, then judging whether Portal authentication is finished in the wireless access point or not according to the identification information, if the Portal authentication is finished, directly sending the association request in a WDS mode, otherwise, sending the association request in a Portal authentication mode, and entering the Portal authentication mode.
After receiving a text request sent by a terminal device, a wireless access point immediately judges whether the terminal device is connected in a WDS connection mode, if so, further judges whether Portal authentication is finished according to identification information (such as MAC (media access control) address) of the terminal device, if the identification information of the terminal device is stored in a memory of the wireless access point, the terminal device is authenticated, further authentication is not needed, the terminal device is directly released to access the Internet, and WDS connection of the terminal device is realized.
And if the wireless access point judges that the terminal equipment is not in the WDS connection mode, the resource locator address obtained by redirection is sent to the terminal equipment according to the text request, and the Portal authentication step is carried out. After receiving the resource locator address sent by the wireless access point, the terminal equipment sends a Web page request to a Portal server according to the resource locator address; and after receiving the Web page request, the Portal server transmits the corresponding Web page to the terminal equipment. After the terminal device obtains the Web page, the terminal device automatically inputs pre-stored authentication information (including user name, password and the like) in the Web page and sends the authentication information to the Portal server.
After receiving the authentication information sent by the terminal equipment, the Portal server authenticates the identity of the terminal equipment according to the received authentication information (compares and verifies the received identity information according to prestored information), and if the authentication is successful, the Portal server sends an authentication success message to the wireless access point and sends the identification information of the terminal equipment to the wireless access point for storage; otherwise, the Portal server sends an authentication failure message to the wireless access point and refuses the access of the terminal equipment.
And then, the wireless access point feeds back a Portal authentication success message to the terminal equipment. And the terminal equipment receives the feedback message, then actively disconnects the connection with the wireless access point, acquires the SSID in the open mode in the wireless access point again in a scanning mode, and retransmits the text request in a WDS mode. After receiving the text request, the wireless access point judges that the identification information of the terminal equipment is stored in a list authenticated by Portal, and directly releases the terminal equipment to access the Internet.
As shown in fig. 4, a schematic diagram of a terminal device provided by the present invention, specifically, the terminal device supports WDS, and as can be seen from the diagram, the terminal device 200 includes: a second processor 210 for processing instructions; and a second memory 220 for storing a plurality of instructions, the instructions being adapted to be loaded and executed by the second processor; the plurality of instructions includes:
sending an association request to a wireless access point to realize association with the wireless access point;
judging whether Portal authentication is finished in the wireless access point or not; if so, sending a text request to the wireless access point in a WDS mode to complete WDS connection; otherwise, sending the text request to the wireless access point in a non-WDS mode.
In this embodiment, the terminal device obtains the SSID of the open mode in the wireless access point by scanning, and then sends an association request to the wireless access point. In the process of sending the association request, firstly, acquiring the identification information (such as MAC address) of the wireless access point, then judging whether Portal authentication is finished in the wireless access point or not according to the identification information, if the Portal authentication is finished, directly sending the association request in a WDS mode, otherwise, sending the association request in a Portal authentication mode, and entering the Portal authentication mode. After completing Portal authentication, the terminal equipment actively breaks the connection with the wireless access point, acquires the SSID of the open mode in the wireless access point again in a scanning mode, and resends a text request in a WDS mode to realize the access of the terminal equipment to the Internet. Specifically, here, the wireless access point is a master device in the WDS connection, and the terminal device is a slave device in the WDS connection (initiates the WDS connection, as a relay terminal).
It should be noted that the above embodiments can be freely combined as necessary. The foregoing is only a preferred embodiment of the present invention, and it should be noted that, for those skilled in the art, various modifications and decorations can be made without departing from the principle of the present invention, and these modifications and decorations should also be regarded as the protection scope of the present invention.