Invention content
In consideration of it, an embodiment of the present invention provides a kind of roam control method of website and device, to solve the prior art
In some websites it is not high for the support of wireless network protocol, lead to that network or handover network can not be used after roaming
Less efficient problem.
In a first aspect, an embodiment of the present invention provides a kind of roam control methods of website, including:
When receiving the association request message of website transmission, Jie of the website is obtained from the association request message
The information of matter access control MAC addresses and the access point of site requests access;
If corresponding first Hash table of the MAC Address for inquiring the website, obtains the corresponding first stop of the website
Point information table;
If the access point stored in the information of the access point of the site requests access and the first website information table
Information is inconsistent, then according to the first website information table described in the information update of the access point of site requests access, obtains the
Two site information tables, and associate response message is replied to the website;
It is that the website distributes a new Internet protocol IP address according to dynamic host configuration protocol DHCP, described in foundation
Corresponding second Hash table of new IP address of website establishes the MAC Address third corresponding with new IP address of the website
Hash table;
The second website information table is updated according to the new IP address of the website, obtains third site information table.
Second aspect, an embodiment of the present invention provides a kind of roaming control devices of website, including:
First acquisition unit, for when receive website transmission association request message when, from the association request message
The information of the middle medium access control MAC Address for obtaining the website and the access point of site requests access;
Second acquisition unit, if for inquiring corresponding first Hash table of the MAC Address of the website, obtain described in
The corresponding first website information table of website;
Site information table updating unit, if being used for the information of the access point of site requests access and first website
The information of the access point stored in information table is inconsistent, then according to described in the information update of the access point of site requests access
First website information table obtains the second website information table, and replys associate response message to the website;
Unit is established, for being that the website distributes a new Internet protocol IP according to dynamic host configuration protocol DHCP
Corresponding second Hash table of new IP address of the website is established in address, establishes the MAC Address of the website with new IP
The corresponding third Hash table in location;
The site information table updating unit is additionally operable to update second website according to the new IP address of the website
Information table obtains third site information table.
Existing advantageous effect is the embodiment of the present invention compared with prior art:The embodiment of the present invention will not be by that will meet nothing
The message adaptation of line network protocol standard is at the message for meeting wireless network protocol specification, to improve being successfully accessed for website
Rate avoids website that from can not using network after roaming, improves the online experience of user;When the association for receiving website transmission is asked
Message is sought, and the information of the access point of site requests access and the information of the access point stored in the first website information table are inconsistent
When, judgement website is roamed, that is, has switched access point, and executes the flow of switching access point, thus avoids website can not
It accesses network or network can not be used after accessing network, improve the online experience of user.
Specific implementation mode
In order to make the purpose , technical scheme and advantage of the present invention be clearer, with reference to the accompanying drawings and embodiments, right
The present invention is further elaborated.It should be appreciated that the specific embodiments described herein are merely illustrative of the present invention, and
It is not used in the restriction present invention.
Fig. 1 shows the implementation flow chart of the roam control method of website provided in an embodiment of the present invention, and details are as follows:
In step S101, when receiving the association request message of website transmission, the acquisition station from association request message
The information of the access point of medium access control MAC Address and the site requests access of point.
It should be noted that the executive agent of the embodiment of the present invention can be AC (Access Controller, access control
Device processed).Website in the embodiment of the present invention refers to wireless site, such as smart mobile phone, tablet computer and Intelligent bracelet.
In embodiments of the present invention, after receiving the association request message of website transmission, association request message is parsed, with
(Media Access Control, the medium access control) addresses MAC and station of the website are obtained from association request message
Point request access access point (AP, Access Point) information, further according to the website MAC Address inquiry with the presence or absence of should
Corresponding first Hash table of MAC Address of website.
In step s 102, if corresponding first Hash table of the MAC Address for inquiring website, website corresponding is obtained
One site information table.
In step s 103, if the access stored in the information of the access point of site requests access and the first website information table
The information of point is inconsistent, then according to information update the first website information table of the access point of site requests access, obtains second station
Point information table, and associate response message is replied to website.
If corresponding first Hash table of the MAC Address for inquiring the website, show the website accessed network feelings
Association request message is sent under condition again.It is not inconsistent since website sends association request message again in the case of accessed network
The specification flow of wireless network protocol is closed, therefore, in embodiments of the present invention, if the MAC Address for inquiring website corresponding the
One Hash table then obtains the corresponding first website information table of website, the access point of storage is obtained from the first website information table
Information, then by the information for the access point that the site requests access compared with the information of the access point stored in the first website information table
Compared with if inconsistent, showing that the website is roamed, i.e., the website is not to access network by original access point.If standing
The information and the information of the access point stored in the first website information table of the access point of point request access are inconsistent, then according to website
Information update the first website information table for asking the access point of access, obtains the second website information table, according still further to 802.11 agreements,
Associate response message is replied to website.
As an embodiment of the present invention, the information of the access point of site requests access is deposited with the first website information table
The information of the access point of storage is inconsistent to be specially:The access stored in the access point and the first website information table of site requests access
MAC Address, IP (Internet Protocol, Internet protocol) address, SSID (Service Set Identifier, the clothes of point
Be engaged in set identifier) and/or WLAN ID (WLAN Identifier, WLAN mark) it is inconsistent.
In step S104, for one new Internet protocol IP of website distribution according to dynamic host configuration protocol DHCP
Corresponding second Hash table of new IP address of website is established in location, establishes the MAC Address corresponding with new IP address of website
Three Hash tables.Wherein, third Hash table is used to record the correspondence of the MAC Address and IP address of website.
Herein, according to DHCP (Dynamic Host Configuration Protocol, dynamic host configuration protocol)
A new IP address, and corresponding second Hash table of new IP address for establishing the website are distributed for the website, and is established
The MAC Address of website third Hash table corresponding with new IP address.
In step S105, the second website information table is updated according to the new IP address of website, obtains third site information
Table.
Fig. 2 shows the implementation flow charts of the roam control method of the website of another embodiment of the present invention offer, with reference to figure
2:
In step s 201, when receiving the association request message of website transmission, the acquisition station from association request message
The information of the access point of medium access control MAC Address and the site requests access of point;
In step S202, if corresponding first Hash table of the MAC Address for inquiring website, website corresponding is obtained
One site information table;
In step S203, if the access stored in the information of the access point of site requests access and the first website information table
The information of point is inconsistent, then according to information update the first website information table of the access point of site requests access, obtains second station
Point information table, and associate response message is replied to website;
In step S204, corresponding second Hash table of initial ip address of website is deleted, and deletes the MAC Address of website
Third Hash table corresponding with initial ip address;
In step S205, for one new Internet protocol IP of website distribution according to dynamic host configuration protocol DHCP
Corresponding second Hash table of new IP address of website is established in location, establishes the MAC Address corresponding with new IP address of website
Three Hash tables;
In step S206, the second website information table is updated according to the new IP address of website, obtains third site information
Table;
In step S207, the corresponding website of transmitting station adds the access point that information is accessed to site requests;
In step S208, the corresponding website of transmitting station deletes the access stored in information to the first website information table
Point.
In embodiments of the present invention, if storing in information and the first website information table of the access point of site requests access
The information of access point is inconsistent, then deletes corresponding second Hash table of initial ip address of website, and deletes the MAC Address of website
Third Hash table corresponding with initial ip address, to avoid redundant data is stored in AC.
After obtaining third site information table, according to CAPWAP (Control And Provisioning of
Wireless Access Points protocol specification, the control of wireless access point and configuration protocol), group
Information is added at website, and website addition information is sent to the access point of site requests access, to notify the site requests
The access point of access adds the information of the website, and forwards the Internet data of the website.Letter is deleted according to CAPWAP composition websites
Breath, and website deletion information is sent to the access point stored in the first website information table, so that in the first website information table
The information of the access point deletion of the storage website, and stop handling the Internet data of the website.
As an embodiment of the present invention, this method further includes:The message interface defined by AC internal systems uses
Socket (socket) communication technology updates site-local data forwarding relation table, with the Internet data for the treatment of station.
Fig. 3 is shown described in the roam control method step S103 of website provided in an embodiment of the present invention according to the station
First website information table described in the information update of the access point of point request access, obtains the specific implementation stream of the second website information table
Cheng Tu, with reference to Fig. 3:
In step S301, all information of the access point stored in the first website information table are deleted;
In step s 302, MAC Address, the IP of the access point of site requests access are obtained from association request message
Location, service set SSID and/or WLAN identify WLAN ID, and by the MAC of the access point of site requests access
Location, IP address, SSID and/or WLAN ID are added in the first website information table, obtain the second website information table.
In embodiments of the present invention, if storing in information and the first website information table of the access point of site requests access
The information of access point is inconsistent, then needs to be updated the first website information table, specifically, deletes in the first website information table
All information of the access point of storage, MAC Address, the IP of the access point of site requests access are obtained from association request message
Location, SSID and/or WLAN ID, and MAC Address, IP address, SSID the and/or WLAN ID for the access point that site requests are accessed
It is added in the first website information table, obtains the second website information table.
It should be understood that in embodiments of the present invention, size of the sequence numbers of the above procedures is not meant to the elder generation of execution sequence
Afterwards, the execution sequence of each process should be determined by its function and internal logic, the implementation process structure without coping with the embodiment of the present invention
At any restriction.
The embodiment of the present invention is not by will meet the message adaptation of wireless network protocol specification at meeting wireless network protocol
The message of specification is successfully accessed rate to improve website, avoids website that from can not using network after roaming, improve user
Online experience;When receive website transmission association request message, and site requests access access point information and first
When the information of the access point stored in site information table is inconsistent, judgement website is roamed, that is, has switched access point, and hold
Thus the flow of row switching access point avoids website that from can not accessing network or can not use network after accessing network, improves
The online experience of user.
Fig. 4 shows the structure diagram of the roaming control device of website provided in an embodiment of the present invention, which can use
In service chart 1 to the roam control method of website shown in Fig. 3.For convenience of description, it illustrates only and phase of the embodiment of the present invention
The part of pass.
With reference to Fig. 4, which includes:
First acquisition unit 41, for when receiving the association request message of website transmission, disappearing from the association request
The information of the medium access control MAC Address of the website and the access point of site requests access is obtained in breath;
If second acquisition unit 42 obtains institute for inquiring corresponding first Hash table of the MAC Address of the website
State the corresponding first website information table of website;
Site information table updating unit 43, if being used for the information of the access point of site requests access and the first stop
The information of the access point stored in point information table is inconsistent, then according to the information update institute of the access point of site requests access
The first website information table is stated, the second website information table is obtained, and replys associate response message to the website;
Unit 44 is established, for being that the website distributes a new Internet protocol according to dynamic host configuration protocol DHCP
IP address establishes corresponding second Hash table of new IP address of the website, establishes the MAC Address of the website and new IP
The corresponding third Hash table in address;
The site information table updating unit 43 is additionally operable to update the second station according to the new IP address of the website
Point information table, obtains third site information table.
Further, described device further includes:
Deleting unit 45, corresponding second Hash table of initial ip address for deleting the website, and delete the station
The corresponding third Hash table of MAC Address and initial ip address of point.
Further, described device further includes:
First transmission unit 46 adds what information was accessed to the site requests for sending the corresponding website of the website
Access point.
Further, described device further includes:
Second transmission unit 47 deletes information to the first website information table for sending the corresponding website of the website
The access point of middle storage.
Preferably, the site information table updating unit 43 includes:
Delete subelement 431, all information for deleting the access point stored in the first website information table;
Subelement 432 is updated, the access point for obtaining site requests accesses from the association request message
MAC Address, IP address, service set SSID and/or WLAN identify WLAN ID, and the site requests are accessed
MAC Address, IP address, SSID the and/or WLAN ID of access point be added in the first website information table, obtain described
Second website information table.
The embodiment of the present invention is not by will meet the message adaptation of wireless network protocol specification at meeting wireless network protocol
The message of specification is successfully accessed rate to improve website, avoids website that from can not using network after roaming, improve user
Online experience;When receive website transmission association request message, and site requests access access point information and first
When the information of the access point stored in site information table is inconsistent, judgement website is roamed, that is, has switched access point, and hold
Thus the flow of row switching access point avoids website that from can not accessing network or can not use network after accessing network, improves
The online experience of user.
Those of ordinary skill in the art may realize that lists described in conjunction with the examples disclosed in the embodiments of the present disclosure
Member and algorithm steps can be realized with the combination of electronic hardware or computer software and electronic hardware.These functions are actually
It is implemented in hardware or software, depends on the specific application and design constraint of technical solution.Professional technician
Each specific application can be used different methods to achieve the described function, but this realization is it is not considered that exceed
The scope of the present invention.
It is apparent to those skilled in the art that for convenience and simplicity of description, the device of foregoing description
It with the specific work process of unit, can refer to corresponding processes in the foregoing method embodiment, details are not described herein.
In several embodiments provided herein, it should be understood that disclosed device and method can pass through it
Its mode is realized.For example, the apparatus embodiments described above are merely exemplary, for example, the division of the unit, only
Only a kind of division of logic function, formula that in actual implementation, there may be another division manner, such as multiple units can combine or
It is desirably integrated into another system, or some features can be ignored or not executed.Another point, it is shown or discussed it is mutual it
Between coupling, direct-coupling or communication connection can be by some interfaces, the INDIRECT COUPLING of unit or communication connection, can be with
It is electrical, machinery or other forms.
The unit illustrated as separating component may or may not be physically separated, aobvious as unit
The component shown may or may not be physical unit, you can be located at a place, or may be distributed over multiple
In network element.Some or all of unit therein can be selected according to the actual needs to realize the mesh of this embodiment scheme
's.
In addition, each functional unit in each embodiment of the present invention can be integrated in a processing unit, it can also
It is that each unit physically exists alone, it can also be during two or more units be integrated in one unit.
It, can be with if the function is realized in the form of SFU software functional unit and when sold or used as an independent product
It is stored in a computer read/write memory medium.Based on this understanding, technical scheme of the present invention is substantially in other words
The part of the part that contributes to existing technology or the technical solution can be expressed in the form of software products, the meter
Calculation machine software product is stored in a storage medium, including some instructions are used so that a computer equipment (can be
People's computer, server or network equipment etc.) it performs all or part of the steps of the method described in the various embodiments of the present invention.
And storage medium above-mentioned includes:USB flash disk, mobile hard disk, read-only memory (ROM, Read-Only Memory), arbitrary access are deposited
The various media that can store program code such as reservoir (RAM, Random Access Memory), magnetic disc or CD.
The above description is merely a specific embodiment, but scope of protection of the present invention is not limited thereto, any
Those familiar with the art in the technical scope disclosed by the present invention, can easily think of the change or the replacement, and should all contain
Lid is within protection scope of the present invention.Therefore, the protection scope of the present invention shall be subject to the protection scope of the claims.