WO2014094483A1 - WiFi设备的访问控制方法及WiFi设备 - Google Patents

WiFi设备的访问控制方法及WiFi设备 Download PDF

Info

Publication number
WO2014094483A1
WO2014094483A1 PCT/CN2013/084904 CN2013084904W WO2014094483A1 WO 2014094483 A1 WO2014094483 A1 WO 2014094483A1 CN 2013084904 W CN2013084904 W CN 2013084904W WO 2014094483 A1 WO2014094483 A1 WO 2014094483A1
Authority
WO
WIPO (PCT)
Prior art keywords
wifi device
access request
ssid
access
wifi
Prior art date
Application number
PCT/CN2013/084904
Other languages
English (en)
French (fr)
Inventor
相超
Original Assignee
华为终端有限公司
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by 华为终端有限公司 filed Critical 华为终端有限公司
Priority to JP2014552514A priority Critical patent/JP5849354B2/ja
Priority to EP13807886.0A priority patent/EP2814217B1/en
Priority to US14/145,234 priority patent/US9467932B2/en
Publication of WO2014094483A1 publication Critical patent/WO2014094483A1/zh

Links

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04WWIRELESS COMMUNICATION NETWORKS
    • H04W12/00Security arrangements; Authentication; Protecting privacy or anonymity
    • H04W12/08Access security
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L41/00Arrangements for maintenance, administration or management of data switching networks, e.g. of packet switching networks
    • H04L41/28Restricting access to network management systems or functions, e.g. using authorisation function to access network configuration
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04WWIRELESS COMMUNICATION NETWORKS
    • H04W74/00Wireless channel access
    • H04W74/002Transmission of channel access control information
    • H04W74/004Transmission of channel access control information in the uplink, i.e. towards network
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04WWIRELESS COMMUNICATION NETWORKS
    • H04W12/00Security arrangements; Authentication; Protecting privacy or anonymity
    • H04W12/60Context-dependent security
    • H04W12/69Identity-dependent
    • H04W12/73Access point logical identity
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04WWIRELESS COMMUNICATION NETWORKS
    • H04W84/00Network topologies
    • H04W84/02Hierarchically pre-organised networks, e.g. paging networks, cellular networks, WLAN [Wireless Local Area Network] or WLL [Wireless Local Loop]
    • H04W84/10Small scale networks; Flat hierarchical networks
    • H04W84/12WLAN [Wireless Local Area Networks]

Definitions

  • the present invention relates to the field of wireless communications, and in particular, to an access control method for a WiFi device and a WiFi device.
  • BACKGROUND OF THE INVENTION With the popularity of WiFi products, the demand for WiFi access is increasing.
  • Multi-SSID Multi-Service Set Identifier
  • the terminal user that can be associated with the SSID1 can log in to the WiFi management interface WEBUI and perform terminal parameter configuration, and the terminal user associated with the SSID2 is not allowed to access the WiFi management interface WEBUI.
  • the application module in the WiFi product When an end user initiates a WEBUI access request, the application module in the WiFi product according to the Dynamic Host Configuration Protocol (DHCP) module reports the Internet Protocol (IP) address and media access control (Media) The corresponding relationship between the access control and the MAC address, obtains the MAC address of the terminal user that currently initiates the WEBUI access request, and invokes the WiFi query interface to obtain the MAC address list of the terminal user associated with the SSID (for example, SSID2) that is not allowed to access the WEBUI, and determines Whether the MAC address list includes the MAC address of the terminal user that currently initiates the WEBUI access request, and if so, rejects the user's access request to the WEBUI, and if not, responds to the user's access request to the WEBUI.
  • SSID for example, SSID2
  • the IP/MAC correspondence table is queried, and the WiFi query interface is invoked to obtain a list of MAC addresses of all terminal users associated with the SSID (for example, SSID2) that is not allowed to access the WEBUI, and the MAC address is determined. Does the list contain the current The MAC address of the end user who initiated the WEBUI access request is inefficient.
  • a first aspect of the present invention provides an access control method for a WiFi device, which may include: receiving, at a user layer of the WiFi device, an access request for accessing a WiFi device based on a service set identifier SSID, where the access request includes accessing the WiFi device Management interface WEBUI request;
  • the method before the user layer of the WiFi device receives the access request of the WiFi device based on the service set identifier SSID, the method further includes: at a kernel layer of the WiFi device Obtaining an index value of an interface of the multi-WiFi service set identifier Multi-SSID that is prohibited from accessing the SSID of the WiFi device;
  • the kernel layer of the WiFi device When receiving, by the kernel layer of the WiFi device, an access request of the access device of the WiFi device based on the server identifier SSID, determining whether the index value of the interface where the service set identifier SSID is based on the access request is forbidden to access the WiFi device One of the index values of the interface where the SSID is located; if the determination is yes, the kernel layer of the WiFi device adds a preset label to the access request based on the server identifier SSID, and the access with the preset label is added.
  • a second possible implementation manner before the user layer of the WiFi device receives the access request for accessing the WiFi device based on the service set identifier SSID, also includes:
  • a second aspect of the present invention provides a WiFi device, which may include:
  • a first receiving module configured to receive, by a user layer of the WiFi device, an access request for accessing a WiFi device based on a service set identifier SSID, where the access request includes a request for accessing a management interface WEBUI of the WiFi device;
  • a first determining module configured to determine, at a user layer of the WiFi device, whether the received access request label is the same as one of a label set in advance for prohibiting access to the SSID of the WiFi device;
  • the first access control module is configured to reject the access request when the determining result of the first determining module is YES, and accept the access request when the determining result of the first determining module is negative.
  • the WiFi device of the present invention may further include:
  • An obtaining module configured to acquire, in a kernel layer of the WiFi device, an index value of an interface of the multi-WiFi service set identifier Multi-SSID that prohibits accessing an SSID of the WiFi device;
  • a second receiving module configured to receive an access request of the accessing WiFi device based on the server identifier SSID at a kernel layer of the WiFi device;
  • a second determining module configured to: when the second receiving module receives an access request for accessing the WiFi device based on the server identifier SSID, determine whether the index value of the interface where the service set identifier SSID is based on the access request is forbidden One of the index values of the interface where the SSID of the WiFi device is located;
  • a second access control module configured to: when the determination result of the second determining module is YES, add a preset label to the access request based on the server identifier SSID at the kernel layer, and add a preset The access request of the tag is sent to the first receiving module, and when the determining result of the second determining module is no, the kernel layer does not add a preset label to the access request based on the server identifier SSID, and An access request to which the preset tag is not added is sent to the first receiving module.
  • the WiFi device of the present invention may further include:
  • a setting module configured to prohibit access to the WiFi device at a user layer of the WiFi device
  • the corresponding ID of the SSID is set.
  • a third aspect of the present invention provides a WiFi device, which may include a memory and a processor, wherein the memory stores a specified program, and the processor calls a program stored in the memory to perform the following steps:
  • an access request for accessing a WiFi device based on a service set identifier SSID the access request including a request to access a management interface WEBUI of the WiFi device
  • the processor determines, at a user layer of the WiFi device, whether a label of the received access request is set with an SSID that is forbidden to access the WiFi device in advance. Before one of the labels is the same, perform the following steps:
  • the index value of the interface where the SSID of the WiFi device is located is prohibited in the multi-WiFi service set identifier Multi-SSID of the WiFi layer of the WiFi device;
  • the kernel layer of the WiFi device When receiving, by the kernel layer of the WiFi device, an access request of the access device of the WiFi device based on the server identifier SSID, determining whether the index value of the interface where the service set identifier SSID is based on the access request is forbidden to access the WiFi device One of the index values of the interface where the SSID is located; if the determination is yes, the kernel layer of the WiFi device adds a preset label to the access request based on the server identifier SSID, and the access with the preset label is added.
  • the processor at the user layer of the WiFi device, receives the access service set identifier SSID accessing the WiFi device Before the access request, the following steps are also performed:
  • a corresponding tag is set at the user layer of the WiFi device for prohibiting access to the SSID of the WiFi device.
  • the use of the WiFi device receives an access request for accessing the WiFi device based on the service set identifier SSID, the access request includes a request to access the management interface WEBUI of the WiFi device; and the user layer of the WiFi device determines the label of the received access request Whether it is the same as one of the tags set in advance for prohibiting access to the SSID of the WiFi device, if the determination is YES, the access request is rejected, and if the determination is no, the access request is accepted.
  • the access request for accessing the WiFi device can be managed only by using the label, which effectively reduces the processing time of querying the IP/MAC correspondence table and the MAC table of the user associated with the SSID that is not allowed to access the WEBUI, and improves the processing time. Processing efficiency.
  • the embodiment of the present invention manages the access based on the SSID, instead of managing the access based on the MAC address of the user. When the user changes, the user permission setting is still not erroneous; in addition, the embodiment of the present invention avoids the user setting the static IP. Network security risks have improved the user experience.
  • FIG. 1 is a schematic flowchart diagram of an embodiment of an access control method for a WiFi device according to the present invention.
  • FIG. 2 is a schematic flowchart diagram of another embodiment of an access control method of a WiFi device according to the present invention.
  • FIG. 3 is a schematic structural diagram of an embodiment of a WiFi device according to the present invention.
  • FIG. 4 is a schematic structural diagram of another embodiment of a WiFi device according to the present invention.
  • FIG. 5 is a schematic structural diagram of another embodiment of a WiFi device according to the present invention.
  • FIG. 1 is a schematic flowchart diagram of an embodiment of an access control method for a WiFi device according to the present invention. As shown in FIG. 1, the method of the embodiment of the present invention includes:
  • Step S110 receiving, at a user layer of the WiFi device, an access request for accessing a WiFi device based on a service set identifier SSID, where the access request includes a request for accessing a management interface WEBUI of the WiFi device; Step Sill, determining, by the user layer of the WiFi device, whether the label of the received access request is the same as one of the labels set in advance for prohibiting access to the SSID of the WiFi device, and if the determination is yes, executing step S112; If the determination is no, step S122 is performed.
  • Step S112 rejecting the access request.
  • Step S122 accepting the access request.
  • the user layer of the embodiment of the present invention may include a platform layer, a protocol layer, and an application layer.
  • the kernel layer of an embodiment of the invention may include an operating system portion.
  • the access request received in step S110 may be an access request for logging in or maintaining a management interface of the WiFi device, where the access request may be Hypertext Transfer Protocol (HTTP), file transfer protocol. (File Transfer Protocol, FTP), etc.
  • HTTP Hypertext Transfer Protocol
  • FTP File Transfer Protocol
  • the corresponding label and the access request filtering rule may be set in the user layer of the WiFi device for prohibiting access to the SSID of the WiFi device by using a firewall setting process in advance. For example, if it is forbidden to access the SSID of the WiFi device as SSID2, the firewall rule can be set by calling the SetSSID2AccessRule (custom function name, which can be set to other names as needed) function at the user layer of the WiFi device.
  • the access request filtering rule may be inserted or deleted according to the enable/disable parameter.
  • the set filtering rule may be: the access request with the tag Oxfffl is rejected.
  • step S111 the user layer of the WiFi device determines the label of the received access request, and if the label is Oxfffl, discards (ie, denies access), otherwise normal forwarding (ie, Accept the interview).
  • a user layer of the WiFi device receives an access request for accessing a WiFi device based on a service set identifier SSID, where the access request includes a request for accessing a management interface WEBUI of the WiFi device; Determining, at the user layer of the WiFi device, whether the tag of the received access request is the same as one of the tags set in advance for prohibiting access to the SSID of the WiFi device, and if the determination is yes, rejecting the access request, if If the determination is no, the access request is accepted.
  • the access request for accessing the WiFi device can be managed only by using the label, which effectively reduces the processing time of querying the IP/MAC correspondence table and the MAC table of the user who is not allowed to access the SSID of the WEBUI, thereby improving the processing efficiency.
  • the embodiment of the present invention manages access based on SSID, instead of based on user MAC address management. When the user changes, the user rights setting is still not errored.
  • the embodiment of the present invention avoids network security risks caused by the user setting a static IP, and improves the user experience.
  • FIG. 2 is a schematic flow chart of an embodiment of an access control method for a WiFi device according to the present invention.
  • the related processing flow of the kernel layer of the WiFi device is added.
  • the method of the embodiment of the present invention includes:
  • Step S210 Obtain an index value of an interface where the SSID of the WiFi device is located in the multi-WiFi service set identifier Multi-SSID is acquired in the kernel layer of the WiFi device.
  • Step S211 Receive an access request of the access WiFi device based on the server identifier SSID at the kernel layer of the WiFi device.
  • Step S212 determining, at the kernel layer of the WiFi device, whether an index value of an interface where the service set identifier SSID is located on the access request is one of index values of an interface where the SSID of the WiFi device is prohibited from being accessed, and if it is determined to be Step S213 is performed; if the determination is no, step S223 is performed.
  • Step S213 Add a preset label to the access request based on the server identifier SSID at the kernel layer of the WiFi device, and send an access request with a preset label to the user layer of the WiFi device.
  • Step S223 Add a preset label to the access request based on the server identifier SSID at the WiFi device kernel layer, and send an access request without adding a preset label to the user layer of the WiFi device.
  • Step S214 receiving, by the user layer of the WiFi device, an access request of the access WiFi device based on the service set identifier SSID, where the access request includes a request for accessing the management interface WEBUI of the WiFi device;
  • Step S215 determining, by the user layer of the WiFi device, whether the label of the received access request is the same as one of the labels set in advance for prohibiting access to the SSID of the WiFi device, if the determination is yes, executing step S216; If the determination is no, step S236 is performed.
  • Step S216 rejecting the access request.
  • the user layer of the WiFi device may set an access right for accessing each SSID of the WiFi device, and in particular, for prohibiting access to the SSID of the WiFi device, Access to WiFi devices is prohibited.
  • the SSID of the WiFi device is forbidden to be SSID2
  • the EnableSsid2AccessUI customized interface name, which can be set to other names as needed
  • the application module of the user layer can transmit the enable/disable parameter to record the permission value of the SSID through the function.
  • the default record parameter is forbidden to access, that is, the access request for accessing the WiFi device based on the SSID2 is prohibited.
  • the enable/disable parameter it is judged whether the index value of the interface where SSID2 is located is written in the user layer to the ssid2 Proc file (the customized file name can be set to other names as needed), such as the index of the interface ethl. Value ifmdex value; If the parameter is SSID2 prohibits access to the WiFi device, you need to write the index value of the interface where SSID2 is located to the ssid2 Proc file. If the parameter is SSID2 to allow access to the WiFi device, you need to write an illegal value to the ssid2 Proc file. That is, the index value of any interface.
  • step S210 the index value of the interface for prohibiting access to the SSID2 of the WiFi device can be obtained at the kernel layer of the WiFi device by reading the interface index value in the ssid2 Proc file.
  • steps S211 and S212 when an access request of the WiFi device based on the server identifier SSID is received at the kernel layer of the WiFi device, before the kernel layer forwards the access request to the user layer, at the WiFi device
  • the kernel layer determines whether the index value of the interface where the service set identifier SSID is based on the access request is one of the index values of the interface where the SSID of the WiFi device is prohibited from being accessed. If the determination is yes, step S213 is performed; , step S223 is performed.
  • step S212 in the kernel forwarding process, the index value of the current forwarding device interface is determined by judging (for example, in the br_pass_frame_up(struct sk_buff *skb) function of the br_input.c file) If the ifindex is equal to the ifmdex obtained in the ssid2 Proc file, if the index values of the forwarding device interface are equal to those obtained in the ssid2 Proc file, then in step S213, a preset is added for the access request based on the server identifier SSID2. The label (for example, the added label is Oxfffl). If the index values of the forwarding device interface are not equal to those obtained in the ssid2 Proc file, the label addition operation is skipped, and the standard process is executed to directly forward the access request.
  • the user layer of the WiFi device determines the label of the received access request, and if the label is Oxfffl, it discards (ie, denies access), otherwise it normally forwards (ie, accepts access). It can be seen that, in some possible implementation manners of the present invention, the user layer of the WiFi device receives an access request of the access WiFi device based on the service set identifier SSID, where the access request includes management of accessing the WiFi device.
  • the embodiment of the present invention can manage the access request for accessing the WiFi device only by using the label, and effectively reduce the processing time of the MAC table of the user associated with the queryed IP/MAC correspondence table and the SSID that is not allowed to access the WEBUI, and improve the processing. effectiveness.
  • FIG. 3 is a schematic structural diagram of an embodiment of a WiFi device according to the present invention.
  • the WiFi device in the embodiment of the present invention may include: a first receiving module 31, a first determining module 32, and a first access control module 33, where:
  • the first receiving module 31 is configured to receive, by the user layer of the WiFi device, an access request for accessing the WiFi device based on the service set identifier SSID, where the access request includes a request for accessing the management interface WEBUI of the WiFi device;
  • the first determining module 32 is configured to determine, at the user layer of the WiFi device, whether the label of the received access request is the same as one of the labels set in advance for prohibiting access to the SSID of the WiFi device;
  • the first access control module 33 is configured to reject the access request when the determination result of the first determining module 32 is YES, and accept the access request when the determining result of the first determining module 32 is negative. .
  • the access request received by the first receiving module 31 may be an access request for logging in or maintaining a management interface of the WiFi device, where the access request may be a Hyper Text Transfer Protocol (HTTP) file or a file. Transfer Protocol (FTP), etc.
  • the WiFi device in the embodiment of the present invention may further include a setting module 34, configured to preset a corresponding label filtering rule in the user layer of the WiFi device for prohibiting access to the SSID of the WiFi device.
  • the setting module may set a corresponding label and access request filtering rule for the SSID of the WiFi device to be prohibited from accessing the WiFi device by the user layer of the WiFi device in advance through the firewall setting process.
  • the setting module may set a SetSSID2AccessRule (a custom function name, which can be set to another name as needed) function at the user layer of the WiFi device.
  • SetSSID2AccessRule a custom function name, which can be set to another name as needed
  • this function can insert or delete the access request filtering rule according to the enable/disable parameter. For example, if the filtering rule is set, the access request with the tag Oxfffl is rejected, and when the wifi works in the Multi-SSID In the mode, the first determining module 32 determines the label of the received access request at the user layer of the WiFi device. If the label is Oxfffl, it discards (ie, denies access), otherwise it normally forwards (ie, accepts access).
  • the user layer of the WiFi device receives an access request of the access WiFi device based on the service set identifier SSID, where the access request includes management of accessing the WiFi device.
  • a request of the interface WEBUI determining, at the user layer of the WiFi device, whether the tag of the received access request is the same as one of the tags set in advance for prohibiting access to the SSID of the WiFi device, and if the determination is yes, rejecting the The access request, if the determination is no, accepts the access request.
  • the access request for accessing the WiFi device can be managed only by using the label, which effectively reduces the processing time of querying the IP/MAC correspondence table and the MAC table of the user associated with the SSID that is not allowed to access the WEBUI, and improves the processing time. Processing efficiency.
  • the embodiment of the present invention manages the access based on the SSID, instead of managing the access based on the MAC address of the user. When the user changes, the user permission setting is still not erroneous; in addition, the embodiment of the present invention avoids the user setting the static IP. Network security risks have improved the user experience.
  • FIG. 4 is a schematic structural diagram of another embodiment of a WiFi device according to the present invention.
  • the WiFi device in the embodiment of the present invention may include: an obtaining module 41, a second receiving module 42, a second determining module 43, a second access control module 44, a setting module 45, and a first receiving module 46.
  • the first determining module 32 and the first access control module 33 wherein:
  • the obtaining module 41 is configured to obtain an index value of an interface where the SSID of the WiFi device is prohibited from being accessed in the multi-WiFi service set identifier Multi-SSID in the kernel layer of the WiFi device.
  • the second receiving module 42 is configured to receive an access request of the accessing WiFi device based on the server identifier SSID at a kernel layer of the WiFi device.
  • the second determining module 43 is configured to: when the second receiving module 42 receives the access request of the accessing the WiFi device based on the server identifier SSID, determine whether the index value of the interface where the service set identifier SSID is based on the access request is It is forbidden to access one of the index values of the interface where the SSID of the WiFi device is located.
  • the second access control module 44 is configured to: when the determination result of the second determining module 43 is YES, add a preset label to the access request based on the server identifier SSID at the kernel layer, and add a pre-added An access request for setting a tag is sent to the first receiving module, and when the determining result of the second determining module 43 is negative, the kernel layer does not add a preset for the access request based on the server identifier SSID.
  • the tag transmits an access request to which the pre-set tag is not added to the first receiving module 46.
  • the setting module 45 is configured to preset a corresponding label in the user layer of the WiFi device for prohibiting access to the SSID of the WiFi device.
  • the first receiving module 46 is configured to receive, at a user layer of the WiFi device, an access request for accessing the WiFi device based on the service set identifier SSID, where the access request includes a request for accessing the management interface WEBUI of the WiFi device.
  • the first determining module 47 is configured to determine, at the user layer of the WiFi device, whether the tag of the received access request is the same as one of the tags set in advance for prohibiting access to the SSID of the WiFi device.
  • the first access control module 48 is configured to reject the access request when the determination result of the first determining module 47 is YES, and accept the access request when the determining result of the first determining module 47 is negative. .
  • the user layer of the WiFi device may set an access right for accessing each SSID of the WiFi device, and in particular, for prohibiting access to the SSID of the WiFi device, it is required to disable access to the WiFi device.
  • the SSID of the WiFi device is forbidden to be SSID2
  • the EnableSsid2AccessUI customized interface name, which can be set to other names as needed
  • the application module of the user layer can pass the enable/disable parameter to record the permission value of the SSID through the function.
  • the default recorded parameter is forbidden, that is, the access request for accessing the WiFi device based on SSID2 is prohibited.
  • the enable/disable parameter it is judged whether the index value of the interface where SSID2 is located is written in the user layer to the ssid2 Proc file (the customized file name can be set to other names as needed), such as the index of the interface ethl. Value ifmdex value; If the parameter is SSID2 prohibits access to the WiFi device, you need to write the index value of the interface where SSID2 is located to the ssid2 Proc file. If the parameter is SSID2 to allow access to the WiFi device, you need to write an illegal value to the ssid2 Proc file. That is, the index value of any interface.
  • the obtaining module 41 may obtain an index value of an interface for prohibiting access to the SSID2 of the WiFi device by reading the ssid2 Proc file of the user layer at the kernel layer of the WiFi device.
  • the index value of the interface where the SSID2 is located in the ssid2 Proc file is only a simple example.
  • the SSID can be transmitted from the user layer in other manners.
  • the index value of the interface on which the SSID of the WiFi device (not limited to SSID2, including all SSIDs that are prohibited from accessing the WiFi device).
  • the second receiving module 42 passes the second determining module 43 before the kernel layer forwards the access request to the user layer.
  • the kernel layer of the WiFi device determines whether the index value of the interface where the service set identifier SSID on which the access request is based is one of index values of the interface where the SSID of the WiFi device is prohibited from accessing.
  • the second judging module 43 can judge (for example, in the br_pass_frame_up(struct sk_buff *skb) function of the br-input.c file) the index value of the interface currently forwarding the SSID ifmdex Whether it is equal to the ifmdex obtained in the ssid2 Proc file, if the index values of the interface for forwarding the SSID are equal to those obtained in the ssid2 Proc file, the second access control module 44 adds a preset for the access request based on the server identifier SSID2.
  • the label is preset (the label is preset by the setting module 45, for example, the label is Oxfffl; the setting module 45 has the same function as the setting module 34 in the previous embodiment, and is not mentioned here), if the SSID is forwarded If the index value of the interface is not equal to the value obtained in the ssid2 Proc file, the label addition operation is skipped, and the standard process is executed to directly forward the access request.
  • the first receiving module 46 can receive the second access control module 44 to send at the user layer.
  • the access request, and the first judging module 47 judges the label of the received access request at the user layer of the WiFi device. If the label is Oxfffl, it discards (ie, denies access), otherwise it normally forwards (ie, accepts access).
  • the user layer of the WiFi device receives an access request of the access WiFi device based on the service set identifier SSID, where the access request includes management of accessing the WiFi device.
  • a request of the interface WEBUI determining, at the user layer of the WiFi device, whether the tag of the received access request is the same as one of the tags set in advance for prohibiting access to the SSID of the WiFi device, and if the determination is yes, rejecting the The access request, if the determination is no, accepts the access request.
  • the embodiment of the present invention can manage the access request for accessing the WiFi device only by using the label, and effectively reduce the processing time of the MAC table of the user associated with the queryed IP/MAC correspondence table and the SSID that is not allowed to access the WEBUI, and improve the processing. effectiveness.
  • the embodiment of the present invention manages the access based on the SSID, instead of managing the access based on the MAC address of the user, and the user permission setting is still not in error when the user changes; in addition, the embodiment of the present invention avoids the user setting the static IP. Network security risks, improve user experience.
  • FIG. 5 is a schematic structural diagram of another embodiment of a WiFi device according to the present invention.
  • the WiFi device of the embodiment of the present invention may include a memory 51 and a processor 52.
  • the memory 51 stores a specified program
  • the processor 52 calls a program stored in the memory 51 to execute. The following steps:
  • the processor 52 determines, before the user layer of the WiFi device, whether the label of the received access request is the same as one of the labels set in advance for prohibiting access to the SSID of the WiFi device. , also perform the following steps:
  • Multi-SSID of the kernel layer of the WiFi device Accessing an index value of an interface where the SSID of the WiFi device is located;
  • the kernel layer of the WiFi device When receiving, by the kernel layer of the WiFi device, an access request of the access device of the WiFi device based on the server identifier SSID, determining whether the index value of the interface where the service set identifier SSID is based on the access request is forbidden to access the WiFi device One of the index values of the interface where the SSID is located; if the determination is yes, the kernel layer of the WiFi device adds a preset label to the access request based on the server identifier SSID, and the access with the preset label is added.
  • the processor 52 performs the following steps before the user layer of the WiFi device receives the access request of the WiFi device based on the service set identifier SSID:
  • a corresponding tag is set in advance at the user layer of the WiFi device for prohibiting access to the SSID of the WiFi device.

Landscapes

  • Engineering & Computer Science (AREA)
  • Computer Security & Cryptography (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Signal Processing (AREA)
  • Mobile Radio Communication Systems (AREA)

Abstract

本发明实施例公开了WiFi设备的访问控制方法及WiFi设备,其中所述方法可包括:在所述WiFi设备的用户层接收基于服务集标识SSID的访问WiFi设备的访问请求,所述访问请求包括访问所述WiFi设备的管理界面WEBUI的请求;在所述WiFi设备的用户层判断所述接收的访问请求的标签是否与预先为禁止访问所述WiFi设备的SSID设定的标签之一相同,如果判断为是,则拒绝所述访问请求,如果判断为否,则接受所述访问请求。由此,可通过简单的方式实现WiFi设备的访问控制。

Description

WiFi设备的访问控制方法及 WiFi设备
本申请要求于 2012年 12月 18日提交中国专利局、 申请号为 201210551879.X中国专利申请的优先权, 其全部内容通过引用结合在本申 请中。
技术领域 本发明涉及无线通信领域,尤其涉及 WiFi设备的访问控制方法及 WiFi 设备。 背景技术 随着 WiFi产品的普及, 用户对 WiFi访问的需求不断增加, 当 WiFi支 持多 WiFi服务集标识( Multi Service Set Identifier, Multi-SSID )时, 需要 对每个 SSID的权限进行管理, 比如,可允许 SSID1关联的终端用户可以登 录 WiFi的管理界面 WEBUI, 并进行终端参数配置, 而不允许 SSID2关联 的终端用户访问 WiFi的管理界面 WEBUI。
目前, 对 Multi-SSID进行管理的方案如下:
当有终端用户发起 WEBUI访问请求时, WiFi产品中的应用模块根据 动态主机配置协议 ( Dynamic Host Configuration Protocol, DHCP )模块上 报的网络互连协议地址 ( Internet Protocol , IP )地址与介质访问控制( Media Access Control , MAC )地址的对应关系, 获取当前发起 WEBUI访问请求 的终端用户的 MAC地址, 并调用 WiFi查询接口获取不允许访问 WEBUI 的 SSID (比如, SSID2 )关联的终端用户的 MAC地址列表,判断所述 MAC 地址列表中是否包含有当前发起 WEBUI访问请求的终端用户的 MAC地 址, 如果包含, 则拒绝用户对 WEBUI的访问请求, 如果不包含, 则响应用 户对 WEBUI的访问请求。
但是, 该方案尚存在如下不足之处:
每次用户试图访问 WEBUI时, 都要查询 IP/MAC对应关系表, 并调用 WiFi查询接口获取不允许访问 WEBUI的 SSID (比如, SSID2 ) 关联的所 有终端用户的 MAC地址列表, 判断所述 MAC地址列表中是否包含有当前 发起 WEBUI访问请求的终端用户的 MAC地址 , 效率低下。 发明内容 本发明实施例提供 WiFi设备的访问控制方法及 WiFi设备, 可通过简 单的方式实现 WiFi设备的访问控制。
本发明第一方面提供一种 WiFi设备的访问控制方法, 可包括: 在所述 WiFi设备的用户层接收基于服务集标识 SSID的访问 WiFi设备 的访问请求 , 所述访问请求包括访问所述 WiFi设备的管理界面 WEBUI的 请求;
在所述 WiFi设备的用户层判断所述接收的访问请求的标签是否与预先 为禁止访问所述 WiFi设备的 SSID设定的标签之一相同, 如果判断为是, 则拒绝所述访问请求, 如果判断为否, 则接受所述访问请求。
结合第一方面, 在第一种可能的实现方式中, 在所述 WiFi设备的用户 层接收基于服务集标识 SSID的访问 WiFi设备的访问请求之前,还可包括: 在所述 WiFi设备的内核层获取多 WiFi服务集标识 Multi-SSID中禁止 访问所述 WiFi设备的 SSID所在接口的索引值;
当在所述 WiFi设备的内核层接收到基于服务器标识 SSID的访问 WiFi 设备的访问请求时,判断所述访问请求所基于的服务集标识 SSID所在接口 的索引值是否为禁止访问所述 WiFi设备的 SSID所在接口的索引值之一; 如果判断为是,在所述 WiFi设备的内核层为基于所述服务器标识 SSID 的所述访问请求添加预先设定标签, 并将添加了预先设定标签的访问请求 发送给所述 WiFi设备的用户层, 如果判断为否, 在所述 WiFi设备内核层 不为基于所述服务器标识 SSID的所述访问请求添加预先设定标签,并将未 添加预先设定标签的访问请求发送给所述 WiFi设备的用户层。
结合第一方面或第一方面的第一种可能的实现方式, 在第二种可能的 实现方式中, 在所述 WiFi设备的用户层接收基于服务集标识 SSID的访问 WiFi设备的访问请求之前, 还包括:
在所述 WiFi设备的用户层为禁止访问所述 WiFi设备的 SSID设定对应 的标签。 本发明第二方面提供一种 WiFi设备, 可包括:
第一接收模块, 用于在所述 WiFi设备的用户层接收基于服务集标识 SSID的访问 WiFi设备的访问请求, 所述访问请求包括访问所述 WiFi设备 的管理界面 WEBUI的请求;
第一判断模块, 用于在所述 WiFi设备的用户层判断所述接收的访问请 求的标签是否与预先为禁止访问所述 WiFi设备的 SSID设定的标签之一相 同;
第一访问控制模块, 用于当所述第一判断模块的判断结果为是时, 拒 绝所述访问请求, 当所述第一判断模块的判断结果为否时, 接受所述访问 请求。
结合第二方面, 在第一种可能的实现方式中, 本发明的 WiFi设备还可 包括:
获取模块, 用于在所述 WiFi设备的内核层获取多 WiFi服务集标识 Multi-SSID中禁止访问所述 WiFi设备的 SSID所在接口的索引值;
第二接收模块, 用于在所述 WiFi设备的内核层接收基于服务器标识 SSID的访问 WiFi设备的访问请求;
第二判断模块, 用于当所述第二接收模块接收到基于服务器标识 SSID 的访问 WiFi设备的访问请求时, 判断所述访问请求所基于的服务集标识 SSID所在接口的索引值是否为禁止访问所述 WiFi设备的 SSID所在接口的 索引值之一;
第二访问控制模块, 用于当所述第二判断模块的判断结果为是时, 在 内核层为基于所述服务器标识 SSID的所述访问请求添加预先设定标签,并 将添加了预先设定标签的访问请求发送给所述第一接收模块, 当所述第二 判断模块的判断结果为否时,在内核层不为基于所述服务器标识 SSID的所 述访问请求添加预先设定标签, 并将未添加预先设定标签的访问请求发送 给所述第一接收模块。
结合第二方面或第二方面的第一种可能的实现方式, 在第二种可能的 实现方式中, 本发明的 WiFi设备还可包括:
设定模块, 用于在所述 WiFi设备的用户层为禁止访问所述 WiFi设备 的 SSID设定对应的标签。
本发明第三方面提供一种 WiFi设备, 可包括存储器和处理器, 所述存 储器中存储有指定程序, 所述处理器调用所述存储器中所存储的程序, 以 执行如下步骤:
在所述 WiFi设备的用户层接收基于服务集标识 SSID的访问 WiFi设备 的访问请求 , 所述访问请求包括访问所述 WiFi设备的管理界面 WEBUI的 请求;
在所述 WiFi设备的用户层判断所述接收的访问请求的标签是否与预先 为禁止访问所述 WiFi设备的 SSID设定的标签之一相同, 如果判断为是, 则拒绝所述访问请求, 如果判断为否, 则接受所述访问请求。
结合第三方面, 在第一种可能的实现方式中, 所述处理器在所述 WiFi 设备的用户层判断所述接收的访问请求的标签是否与预先为禁止访问所述 WiFi设备的 SSID设定的标签之一相同之前, 还执行如下步骤:
在所述 WiFi设备的内核层获取多 WiFi服务集标识 Multi-SSID中禁止 访问所述 WiFi设备的 SSID所在接口的索引值;
当在所述 WiFi设备的内核层接收到基于服务器标识 SSID的访问 WiFi 设备的访问请求时,判断所述访问请求所基于的服务集标识 SSID所在接口 的索引值是否为禁止访问所述 WiFi设备的 SSID所在接口的索引值之一; 如果判断为是,在所述 WiFi设备的内核层为基于所述服务器标识 SSID 的所述访问请求添加预先设定标签, 并将添加了预先设定标签的访问请求 发送给所述 WiFi设备的用户层, 如果判断为否, 在所述 WiFi设备内核层 不为基于所述服务器标识 SSID的所述访问请求添加预先设定标签,并将未 添加预先设定标签的访问请求发送给所述 WiFi设备的用户层。
结合第三方面或第三方面的第一种可能的实现方式, 在第二种可能的 实现方式中, 所述处理器在所述 WiFi设备的用户层接收基于的服务集标识 SSID的访问 WiFi设备的访问请求之前, 还执行如下步骤:
在所述 WiFi设备的用户层为禁止访问所述 WiFi设备的 SSID设定对应 的标签。
由上可见, 在本发明的一些可行的实施方式中, 在所述 WiFi设备的用 户层接收基于服务集标识 SSID的访问 WiFi设备的访问请求, 所述访问请 求包括访问所述 WiFi设备的管理界面 WEBUI的请求;在所述 WiFi设备的 用户层判断所述接收的访问请求的标签是否与预先为禁止访问所述 WiFi设 备的 SSID设定的标签之一相同, 如果判断为是, 则拒绝所述访问请求, 如 果判断为否, 则接受所述访问请求。 由此可知, 本发明实施例仅通过标签 即可对访问 WiFi设备的访问请求进行管理, 有效降低了查询 IP/MAC对应 表和不允许访问 WEBUI的 SSID关联的用户的 MAC表的处理时间, 提升 了处理效率。 另外, 本发明实施例基于 SSID管理访问, 而不是基于用户的 MAC地址管理访问, 则用户发生变化时, 用户权限设置仍不会出错; 另外 本发明实施例避免了用户设置静态 IP时, 造成的网络安全隐患, 提升了用 户体验。 附图说明 图 1为本发明的 WiFi设备的访问控制方法的一实施例的流程示意图。 图 2 为本发明的 WiFi设备的访问控制方法的另一实施例的流程示意 图。
图 3为本发明的 WiFi设备的一实施例的结构组成示意图。
图 4为本发明的 WiFi设备的另一实施例的结构组成示意图。
图 5为本发明的 WiFi设备的另一实施例的结构组成示意图。
具体实施方式 为使本发明的目的、 技术方案和优点更加清楚, 下面将结合附图对本 发明作进一步地详细描述。
图 1为本发明的 WiFi设备的访问控制方法的一实施例的流程示意图。 如 图 1所示, 本发明实施例的方法包括:
步骤 S110, 在所述 WiFi设备的用户层接收基于服务集标识 SSID的访 问 WiFi设备的访问请求, 所述访问请求包括访问所述 WiFi设备的管理界 面 WEBUI的请求; 步骤 Sill , 在所述 WiFi设备的用户层判断所述接收的访问请求的标签 是否与预先为禁止访问所述 WiFi设备的 SSID设定的标签之一相同, 如果判 断为是, 则执行步骤 S112; 如果判断为否, 则执行步骤 S122。
步骤 S112, 拒绝所述访问请求。
步骤 S122, 接受所述访问请求。
具体实现中, 本发明实施例的用户层可以包括平台层、 协议层及应用 层。 本发明实施例的内核层可以包括操作系统部分。
具体实现中, 步骤 S110所接收的访问请求可为登录或维护 WiFi设备的 管理界面的访问请求, 所述访问请求可为超文本传输协议( Hyper Text Transfer Protocol, HTTP )才艮文, 文件传输协议 ( File Transfer Protocol, FTP ) 等。
具体实现中, 可预先通过防火墙设置流程在所述 WiFi设备的用户层为 禁止访问所述 WiFi设备的 SSID设定对应的标签和访问请求过滤规则。比如, 假设禁止访问所述 WiFi设备的 SSID为 SSID2 ,则可在所述 WiFi设备的用户层 调用 SetSSID2AccessRule (自定义的函数名, 可根据需要设定为其他名称) 函数来设置防火墙规则, 该函数可根据使能 /去使能参数, 插入或者删除访 问请求过滤规则,比如设定的过滤规则可为,拒绝标签为 Oxfffl的访问请求。 则当 wifi工作在 Multi-SSID模式时, 在步骤 S111 , 在所述 WiFi设备的用户层 判断接收的访问请求的标签, 如果标签是 Oxfffl , 则丟弃(即拒绝访问), 否则正常转发(即接受访问)。
在本发明的一些可行的实施方式中, 在所述 WiFi设备的用户层接收基 于服务集标识 SSID的访问 WiFi设备的访问请求, 所述访问请求包括访问 所述 WiFi设备的管理界面 WEBUI的请求;在所述 WiFi设备的用户层判断 所述接收的访问请求的标签是否与预先为禁止访问所述 WiFi设备的 SSID 设定的标签之一相同, 如果判断为是, 则拒绝所述访问请求, 如果判断为 否, 则接受所述访问请求。 本发明实施例仅通过标签即可对访问 WiFi设备 的访问请求进行管理, 有效降低了查询 IP/MAC 对应表和不允许访问 WEBUI的 SSID关联的用户的 MAC表的处理时间, 提升了处理效率。 另 外, 本发明实施例基于 SSID管理访问, 而不是基于用户的 MAC地址管理 访问, 则用户发生变化时, 用户权限设置仍不会出错; 另外本发明实施例 避免了用户设置静态 IP时, 造成的网络安全隐患, 提升了用户体验。
图 2为本发明的 WiFi设备的访问控制方法的一实施例的流程示意图。 其 在图 1实施例的基石出上, 增加了 WiFi设备内核层的相关处理流程, 如图 2所 示, 本发明实施例的方法包括:
步骤 S210 , 在所述 WiFi 设备的内核层获取多 WiFi 服务集标识 Multi-SSID中禁止访问所述 WiFi设备的 SSID所在接口的索引值。
步骤 S211 , 在所述 WiFi设备的内核层接收基于服务器标识 SSID的访 问 WiFi设备的访问请求。
步骤 S212,在所述 WiFi设备的内核层判断所述访问请求所基于的服务 集标识 SSID所在接口的索引值是否为禁止访问所述 WiFi设备的 SSID所在 接口的索引值之一, 如果判断为是, 执行步骤 S213; 如果判断为否, 执行 步骤 S223。
步骤 S213 , 在所述 WiFi设备的内核层为基于所述服务器标识 SSID的所 述访问请求添加预先设定标签, 并将添加了预先设定标签的访问请求发送 给所述 WiFi设备的用户层。
步骤 S223 , 在所述 WiFi设备内核层不为基于所述服务器标识 SSID的所 述访问请求添加预先设定标签, 并将未添加预先设定标签的访问请求发送 给所述 WiFi设备的用户层。
步骤 S214, 在所述 WiFi设备的用户层接收基于的服务集标识 SSID的 访问 WiFi设备的访问请求, 所述访问请求包括访问所述 WiFi设备的管理 界面 WEBUI的请求;
步骤 S215 , 在所述 WiFi设备的用户层判断所述接收的访问请求的标签 是否与预先为禁止访问所述 WiFi设备的 SSID设定的标签之一相同, 如果判 断为是, 则执行步骤 S216; 如果判断为否, 则执行步骤 S236。
步骤 S216, 拒绝所述访问请求。
步骤 S236, 接受所述访问请求。
具体实现中, 在所述 WiFi设备的用户层可为访问所述 WiFi设备的各 SSID设置访问权限, 尤其对于禁止访问所述 WiFi设备的 SSID需要设置其 禁止访问 WiFi设备。比如,假设禁止访问所述 WiFi设备的 SSID为 SSID2, 则可在用户层 wlan— api.c文件中新增 EnableSsid2AccessUI (自定义的接口 名称, 可根据需要设定为其他名称)接口供用户层的应用模块调用, 则用 户层的应用模块可通过该函数传递使能 /去使能参数记录该 SSID的权限值, 默认记录的参数为禁止访问,即禁止基于 SSID2发送访问 WiFi设备的访问 请求。 并根据使能 /去使能参数来判断是否在用户层向 ssid2 Proc文件 (自 定义的文件名称, 可根据需要设定为其他名称) 中写入 SSID2所在接口的 索引值, 如接口 ethl的索引值 ifmdex值; 若参数是 SSID2禁止访问 WiFi 设备, 则需向 ssid2 Proc文件中写入 SSID2所在接口的索引值, 若参数是 SSID2允许访问 WiFi设备, 则需向 ssid2 Proc文件中写入非法值, 即非任 何接口的索引值。
因此,在步骤 S210,则可在所述 WiFi设备的内核层通过读取 ssid2 Proc 文件中的接口索引值来获取禁止访问所述 WiFi设备的 SSID2的接口的索引 值。
在步骤 S211和 S212, 当在所述 WiFi设备的内核层接收到基于服务器 标识 SSID的访问 WiFi设备的访问请求时, 在内核层将所述访问请求向用 户层转发之前, 在所述 WiFi设备的内核层判断所述访问请求所基于的服务 集标识 SSID所在接口的索引值是否为禁止访问所述 WiFi设备的 SSID所在 接口的索引值之一, 如果判断为是, 执行步骤 S213; 如果判断为否, 执行 步骤 S223。 仍结合前述例子, 则在步骤 S212, 在内核转发流程中, 通过判 断(比如在 br_input.c文件的 br_pass— frame— up(struct sk— buff *skb)函数中判 断) 当前转发设备接口的索引值 ifindex是否与 ssid2 Proc文件中获取到的 ifmdex相等, 如果转发设备接口的索引值 ifmdex和 ssid2 Proc文件中获取 的值相等, 则在步骤 S213 , 为基于所述服务器标识 SSID2的访问请求添加 预先设定标签(比如, 添加的标签为 Oxfffl ), 如果转发设备接口的索引值 ifmdex和 ssid2 Proc文件中获取的值不相等, 则跳过添加标签的操作, 执行 标准的流程而直接转发访问请求。
则在步骤 S225, 在所述 WiFi设备的用户层判断接收的访问请求的标签, 如果标签是 Oxfffl , 则丟弃(即拒绝访问), 否则正常转发(即接受访问)。 由上可见, 在本发明的一些可行的实施方式中, 在所述 WiFi设备的用 户层接收基于的服务集标识 SSID的访问 WiFi设备的访问请求, 所述访问 请求包括访问所述 WiFi设备的管理界面 WEBUI的请求;在所述 WiFi设备 的用户层判断所述接收的访问请求的标签是否与预先为禁止访问所述 WiFi 设备的 SSID设定的标签之一相同, 如果判断为是, 则拒绝所述访问请求, 如果判断为否, 则接受所述访问请求。 由此可知, 本发明实施例仅通过标 签即可对访问 WiFi设备的访问请求进行管理, 有效降低了查询 IP/MAC对 应表和不允许访问 WEBUI的 SSID关联的用户的 MAC表处理时间, 提升 处理效率。 另外, 本发明实施例基于 SSID 管理访问, 而不是基于用户的 MAC地址管理访问, 则用户发生变化时, 用户权限设置仍不会出错; 另外 本发明实施例避免了用户设置静态 IP时, 造成的网络安全隐患, 提升用户 体验。 备的装置实施例。图 3为本发明的 WiFi设备的一实施例的结构组成示意图。 如图 3所示, 本发明实施例的 WiFi设备可包括: 第一接收模块 31、 第一判 断模块 32以及第一访问控制模块 33 , 其中:
第一接收模块 31 ,用于在所述 WiFi设备的用户层接收基于服务集标识 SSID的访问 WiFi设备的访问请求, 所述访问请求包括访问所述 WiFi设备 的管理界面 WEBUI的请求;
第一判断模块 32,用于在所述 WiFi设备的用户层判断所述接收的访问 请求的标签是否与预先为禁止访问所述 WiFi设备的 SSID设定的标签之一 相同;
第一访问控制模块 33,用于当所述第一判断模块 32的判断结果为是时, 拒绝所述访问请求, 当所述第一判断模块 32的判断结果为否时, 接受所述 访问请求。
具体实现中, 第一接收模块 31接收的访问请求可为登录或维护 WiFi设 备的管理界面的访问请求, 所述访问请求可为超文本传输协议(Hyper Text Transfer Protocol, HTTP )才艮文, 文件传输协议 ( File Transfer Protocol, FTP ) 等。 具体实现中, 本发明实施例的 WiFi设备还可包括设定模块 34, 用于预 先在所述 WiFi设备的用户层为禁止访问所述 WiFi设备的 SSID设定对应的标 签过滤规则。 比如, 设定模块可预先通过防火墙设置流程在所述 WiFi设备 的用户层为禁止访问所述 WiFi设备的 SSID设定对应的标签和访问请求过滤 规则。 比如, 假设禁止访问所述 WiFi设备的 SSID为 SSID2, 则所述设定模块 可在所述 WiFi设备的用户层调用 SetSSID2AccessRule (自定义的函数名, 可 根据需要设定为其他名称) 函数来设置防火墙规则, 该函数可根据使能 /去 使能参数, 插入或者删除访问请求过滤规则, 比如假设, 设定的过滤规则 可为, 拒绝标签为 Oxfffl的访问请求, 则当 wifi工作在 Multi-SSID模式时, 第 一判断模块 32在所述 WiFi设备的用户层判断接收的访问请求的标签, 如果 标签是 Oxfffl , 则丟弃 (即拒绝访问), 否则正常转发 (即接受访问)。
由上可见, 在本发明的一些可行的实施方式中, 在所述 WiFi设备的用 户层接收基于的服务集标识 SSID的访问 WiFi设备的访问请求, 所述访问 请求包括访问所述 WiFi设备的管理界面 WEBUI的请求;在所述 WiFi设备 的用户层判断所述接收的访问请求的标签是否与预先为禁止访问所述 WiFi 设备的 SSID设定的标签之一相同, 如果判断为是, 则拒绝所述访问请求, 如果判断为否, 则接受所述访问请求。 由此可知, 本发明实施例仅通过标 签即可对访问 WiFi设备的访问请求进行管理, 有效降低了查询 IP/MAC对 应表和不允许访问 WEBUI的 SSID关联的用户的 MAC表的处理时间, 提 升了处理效率。 另外, 本发明实施例基于 SSID管理访问, 而不是基于用户 的 MAC地址管理访问, 则用户发生变化时, 用户权限设置仍不会出错; 另 外本发明实施例避免了用户设置静态 IP时, 造成的网络安全隐患, 提升了 用户体验。
图 4为本发明的 WiFi设备的另一实施例的结构组成示意图。 如图 4所 示, 本发明实施例的 WiFi设备可包括: 获取模块 41、 第二接收模块 42、 第二判断模块 43、 第二访问控制模块 44、 设定模块 45、 第一接收模块 46、 第一判断模块 32、 第一访问控制模块 33 , 其中:
获取模块 41 , 用于在所述 WiFi设备的内核层获取多 WiFi服务集标识 Multi-SSID中禁止访问所述 WiFi设备的 SSID所在接口的索引值。 第二接收模块 42,用于在所述 WiFi设备的内核层接收基于服务器标识 SSID的访问 WiFi设备的访问请求。
第二判断模块 43 ,用于当所述第二接收模块 42接收到基于服务器标识 SSID的访问 WiFi设备的访问请求时, 判断所述访问请求所基于的服务集 标识 SSID所在接口的索引值是否为禁止访问所述 WiFi设备的 SSID所在接 口的索引值之一。
第二访问控制模块 44 ,用于当所述第二判断模块 43的判断结果为是时, 在内核层为基于所述服务器标识 SSID的所述访问请求添加预先设定标签, 并将添加了预先设定标签的访问请求发送给所述第一接收模块, 当所述第 二判断模块 43的判断结果为否时,在内核层不为基于所述服务器标识 SSID 的所述访问请求添加预先设定标签, 并将未添加预先设定标签的访问请求 发送给所述第一接收模块 46。
设定模块 45 ,用于预先在所述 WiFi设备的用户层为禁止访问所述 WiFi 设备的 SSID设定对应的标签。
第一接收模块 46,用于在所述 WiFi设备的用户层接收基于服务集标识 SSID的访问 WiFi设备的访问请求, 所述访问请求包括访问所述 WiFi设备 的管理界面 WEBUI的请求。
第一判断模块 47,用于在所述 WiFi设备的用户层判断所述接收的访问 请求的标签是否与预先为禁止访问所述 WiFi设备的 SSID设定的标签之一 相同。
第一访问控制模块 48 ,用于当所述第一判断模块 47的判断结果为是时, 拒绝所述访问请求, 当所述第一判断模块 47的判断结果为否时, 接受所述 访问请求。
具体实现中, 在所述 WiFi设备的用户层可为访问所述 WiFi设备的各 SSID设置访问权限, 尤其对于禁止访问所述 WiFi设备的 SSID需要设置其 禁止访问 WiFi设备。比如,假设禁止访问所述 WiFi设备的 SSID为 SSID2, 则可在用户层 wlan— api.c文件中新增 EnableSsid2AccessUI (自定义的接口 名称, 可根据需要设定为其他名称)接口供用户层的应用模块调用, 则用 户层的应用模块可通过该函数传递使能 /去使能参数记录该 SSID的权限值, 默认记录的参数为禁止访问,即禁止基于 SSID2发送访问 WiFi设备的访问 请求。 并根据使能 /去使能参数来判断是否在用户层向 ssid2 Proc文件 (自 定义的文件名称, 可根据需要设定为其他名称) 中写入 SSID2所在接口的 索引值, 如接口 ethl的索引值 ifmdex值; 若参数是 SSID2禁止访问 WiFi 设备, 则需向 ssid2 Proc文件中写入 SSID2所在接口的索引值, 若参数是 SSID2允许访问 WiFi设备, 则需向 ssid2 Proc文件中写入非法值, 即非任 何接口的索引值。
因此, 本发明实施例中获取模块 41可在所述 WiFi设备的内核层通过 读取用户层的 ssid2 Proc文件获取禁止访问所述 WiFi设备的 SSID2的接口 的索引值。上述在 ssid2 Proc文件中写入 SSID2所在接口的索引值只是一个 简单举例, 在其他一些实施例中, 可通过其他方式从用户层传递 SSID所在
WiFi设备的 SSID(不限于 SSID2,包括所有禁止访问所述 WiFi设备的 SSID ) 所在接口的索引值。
第二接收模块 42 在所述 WiFi设备的内核层接收到基于服务器标识 SSID的访问 WiFi设备的访问请求时, 在内核层将所述访问请求向用户层 转发之前, 通过第二判断模块 43在所述 WiFi设备的内核层判断所述访问 请求所基于的服务集标识 SSID 所在接口的索引值是否为禁止访问所述 WiFi设备的 SSID所在接口的索引值之一。 仍以 SSID2为例进行说明, 第 二判断模块 43可通过判断(比如在 br— input.c文件的 br_pass— frame— up(struct sk_buff *skb)函数中判断) 当前转发 SSID的接口的索引值 ifmdex是否与 ssid2 Proc文件中获取到的 ifmdex相等, 如果转发 SSID的接口的索引值 ifmdex和 ssid2 Proc文件中获取的值相等, 第二访问控制模块 44为基于所 述服务器标识 SSID2的访问请求添加预先设定标签(由设定模块 45预先设 定标签, 比如, 标签为 Oxfffl ; 设定模块 45与上一实施例中的设定模块 34 的功能相同, 在此不进行赞述), 如果转发 SSID的接口的索引值 ifindex和 ssid2 Proc文件中获取的值不相等, 则跳过添加标签操作, 执行标准的流程 而直接转发访问请求。
则第一接收模块 46在用户层则能接收到来自第二访问控制模块 44发送 的访问请求, 以及第一判断模块 47在所述 WiFi设备的用户层判断接收的访 问请求的标签, 如果标签是 Oxfffl时, 则丟弃(即拒绝访问), 否则正常转 发(即接受访问)。
由上可见, 在本发明的一些可行的实施方式中, 在所述 WiFi设备的用 户层接收基于的服务集标识 SSID的访问 WiFi设备的访问请求, 所述访问 请求包括访问所述 WiFi设备的管理界面 WEBUI的请求;在所述 WiFi设备 的用户层判断所述接收的访问请求的标签是否与预先为禁止访问所述 WiFi 设备的 SSID设定的标签之一相同, 如果判断为是, 则拒绝所述访问请求, 如果判断为否, 则接受所述访问请求。 由此可知, 本发明实施例仅通过标 签即可对访问 WiFi设备的访问请求进行管理, 有效降低了查询 IP/MAC对 应表和不允许访问 WEBUI的 SSID关联的用户的 MAC表处理时间, 提升 处理效率。 另外, 本发明实施例基于 SSID 管理访问, 而不是基于用户的 MAC地址管理访问, 则用户发生变化时, 用户权限设置仍不会出错; 另外 本发明实施例避免了用户设置静态 IP时, 造成的网络安全隐患, 提升用户 体验。
图 5为本发明的 WiFi设备的另一实施例的结构组成示意图。 如图 5所 示, 本发明实施例的 WiFi设备可包括存储器 51和处理器 52, 所述存储器 51中存储有指定程序,所述处理器 52调用所述存储器 51中所存储的程序, 以执行如下步骤:
在所述 WiFi设备的用户层接收基于的服务集标识 SSID 的访问 WiFi 设备的访问请求 ,所述访问请求包括访问所述 WiFi设备的管理界面 WEBUI 的请求;
在所述 WiFi设备的用户层判断所述接收的访问请求的标签是否与预先 为禁止访问所述 WiFi设备的 SSID设定的标签之一相同, 如果判断为是, 则拒绝所述访问请求, 如果判断为否, 则接受所述访问请求。
在一些可行的实施方式中, 所述处理器 52在所述 WiFi设备的用户层 判断所述接收的访问请求的标签是否与预先为禁止访问所述 WiFi设备的 SSID设定的标签之一相同之前, 还执行如下步骤:
在所述 WiFi设备的内核层获取多 WiFi服务集标识 Multi-SSID中禁止 访问所述 WiFi设备的 SSID所在接口的索引值;
当在所述 WiFi设备的内核层接收到基于服务器标识 SSID的访问 WiFi 设备的访问请求时,判断所述访问请求所基于的服务集标识 SSID所在接口 的索引值是否为禁止访问所述 WiFi设备的 SSID所在接口的索引值之一; 如果判断为是,在所述 WiFi设备的内核层为基于所述服务器标识 SSID 的所述访问请求添加预先设定标签, 并将添加了预先设定标签的访问请求 发送给所述 WiFi设备的用户层, 如果判断为否, 在所述 WiFi设备内核层 不为基于所述服务器标识 SSID的所述访问请求添加预先设定标签,并将未 添加预先设定标签的访问请求发送给所述 WiFi设备的用户层。
在一些可行的实施方式中, 所述处理器 52在所述 WiFi设备的用户层 接收基于的服务集标识 SSID的访问 WiFi设备的访问请求之前, 还执行如 下步骤:
预先在所述 WiFi设备的用户层为禁止访问所述 WiFi设备的 SSID设定 对应的标签。
以上所列举的仅为本发明较佳实施例而已, 当然不能以此来限定本发 明之权利范围, 因此依本发明权利要求所作的等同变化, 仍属本发明所涵 盖的范围。

Claims

权利要求
1、 一种 WiFi设备的访问控制方法, 其特征在于, 包括:
在所述 WiFi设备的用户层接收基于服务集标识 SSID的访问 WiFi设备 的访问请求 , 所述访问请求包括访问所述 WiFi设备的管理界面 WEBUI的 请求;
在所述 WiFi设备的用户层判断所述接收的访问请求的标签是否与预先 为禁止访问所述 WiFi设备的 SSID设定的标签之一相同, 如果判断为是, 则拒绝所述访问请求, 如果判断为否, 则接受所述访问请求。
2、 如权利要求 1所述的 WiFi设备的访问控制方法, 其特征在于, 在 所述 WiFi设备的用户层接收基于服务集标识 SSID的访问 WiFi设备的访问 请求之前, 还包括:
在所述 WiFi设备的内核层获取多 WiFi服务集标识 Multi-SSID中禁止 访问所述 WiFi设备的 SSID所在接口的索引值;
当在所述 WiFi设备的内核层接收到基于服务器标识 SSID的访问 WiFi 设备的访问请求时,判断所述访问请求所基于的服务集标识 SSID所在接口 的索引值是否为禁止访问所述 WiFi设备的 SSID所在接口的索引值之一; 如果判断为是,在所述 WiFi设备的内核层为基于所述服务器标识 SSID 的所述访问请求添加预先设定标签, 并将添加了预先设定标签的访问请求 发送给所述 WiFi设备的用户层, 如果判断为否, 在所述 WiFi设备内核层 不为基于所述服务器标识 SSID的所述访问请求添加预先设定标签,并将未 添加预先设定标签的访问请求发送给所述 WiFi设备的用户层。
3、 如权利要求 1或 2所述的 WiFi设备的访问控制方法, 其特征在于, 在所述 WiFi设备的用户层接收基于服务集标识 SSID的访问 WiFi设备的访 问请求之前, 还包括:
在所述 WiFi设备的用户层为禁止访问所述 WiFi设备的 SSID设定对应 的标签。
4、 一种 WiFi设备, 其特征在于, 包括:
第一接收模块, 用于在所述 WiFi设备的用户层接收基于服务集标识 SSID的访问 WiFi设备的访问请求, 所述访问请求包括访问所述 WiFi设备 的管理界面 WEBUI的请求;
第一判断模块, 用于在所述 WiFi设备的用户层判断所述接收的访问请 求的标签是否与预先为禁止访问所述 WiFi设备的 SSID设定的标签之一相 同;
第一访问控制模块, 用于当所述第一判断模块的判断结果为是时, 拒 绝所述访问请求, 当所述第一判断模块的判断结果为否时, 接受所述访问 请求。
5、 如权利要求 4所述的 WiFi设备, 其特征在于, 还包括:
获取模块, 用于在所述 WiFi设备的内核层获取多 WiFi服务集标识 Multi-SSID中禁止访问所述 WiFi设备的 SSID所在接口的索引值;
第二接收模块, 用于在所述 WiFi设备的内核层接收基于服务器标识 SSID的访问 WiFi设备的访问请求;
第二判断模块, 用于当所述第二接收模块接收到基于服务器标识 SSID 的访问 WiFi设备的访问请求时, 判断所述访问请求所基于的服务集标识 SSID所在接口的索引值是否为禁止访问所述 WiFi设备的 SSID所在接口的 索引值之一;
第二访问控制模块, 用于当所述第二判断模块的判断结果为是时, 在 内核层为基于所述服务器标识 SSID的所述访问请求添加预先设定标签,并 将添加了预先设定标签的访问请求发送给所述第一接收模块, 当所述第二 判断模块的判断结果为否时,在内核层不为基于所述服务器标识 SSID的所 述访问请求添加预先设定标签, 并将未添加预先设定标签的访问请求发送 给所述第一接收模块。
6、 如权利要求 4或 5所述的 WiFi设备, 其特征在于, 还包括: 设定模块, 用于在所述 WiFi设备的用户层为禁止访问所述 WiFi设备 的 SSID设定对应的标签。
7、 一种 WiFi设备, 其特征在于, 包括存储器和处理器, 所述存储器 中存储有指定程序, 所述处理器调用所述存储器中所存储的程序, 以执行 如下步骤:
在所述 WiFi设备的用户层接收基于服务集标识 SSID的访问 WiFi设备 的访问请求 , 所述访问请求包括访问所述 WiFi设备的管理界面 WEBUI的 请求;
在所述 WiFi设备的用户层判断所述接收的访问请求的标签是否与预先 为禁止访问所述 WiFi设备的 SSID设定的标签之一相同, 如果判断为是, 则拒绝所述访问请求, 如果判断为否, 则接受所述访问请求。
8、 如权利要求 7所述的 WiFi设备, 其特征在于, 所述处理器在所述 WiFi设备的用户层判断所述接收的访问请求的标签是否与预先为禁止访问 所述 WiFi设备的 SSID设定的标签之一相同之前, 还执行如下步骤:
在所述 WiFi设备的内核层获取多 WiFi服务集标识 Multi-SSID中禁止 访问所述 WiFi设备的 SSID所在接口的索引值;
当在所述 WiFi设备的内核层接收到基于服务器标识 SSID的访问 WiFi 设备的访问请求时,判断所述访问请求所基于的服务集标识 SSID所在接口 的索引值是否为禁止访问所述 WiFi设备的 SSID所在接口的索引值之一; 如果判断为是,在所述 WiFi设备的内核层为基于所述服务器标识 SSID 的所述访问请求添加预先设定标签, 并将添加了预先设定标签的访问请求 发送给所述 WiFi设备的用户层, 如果判断为否, 在所述 WiFi设备内核层 不为基于所述服务器标识 SSID的所述访问请求添加预先设定标签,并将未 添加预先设定标签的访问请求发送给所述 WiFi设备的用户层。
9、 如权利要求 7或 8所述的 WiFi设备, 其特征在于, 所述处理器在 所述 WiFi设备的用户层接收基于的服务集标识 SSID的访问 WiFi设备的访 问请求之前, 还执行如下步骤:
在所述 WiFi设备的用户层为禁止访问所述 WiFi设备的 SSID设定对应 的标签。
PCT/CN2013/084904 2012-12-18 2013-10-09 WiFi设备的访问控制方法及WiFi设备 WO2014094483A1 (zh)

Priority Applications (3)

Application Number Priority Date Filing Date Title
JP2014552514A JP5849354B2 (ja) 2012-12-18 2013-10-09 WiFi装置に対するアクセス制御方法およびWiFi装置
EP13807886.0A EP2814217B1 (en) 2012-12-18 2013-10-09 Access control method for wifi device and wifi device thereof
US14/145,234 US9467932B2 (en) 2012-12-18 2013-12-31 Access control method for WiFi device and WiFi device

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
CN201210551879.XA CN103873456B (zh) 2012-12-18 2012-12-18 WiFi设备的访问控制方法及WiFi设备
CN201210551879.X 2012-12-18

Related Child Applications (1)

Application Number Title Priority Date Filing Date
US14/145,234 Continuation US9467932B2 (en) 2012-12-18 2013-12-31 Access control method for WiFi device and WiFi device

Publications (1)

Publication Number Publication Date
WO2014094483A1 true WO2014094483A1 (zh) 2014-06-26

Family

ID=50911584

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2013/084904 WO2014094483A1 (zh) 2012-12-18 2013-10-09 WiFi设备的访问控制方法及WiFi设备

Country Status (4)

Country Link
EP (1) EP2814217B1 (zh)
JP (1) JP5849354B2 (zh)
CN (1) CN103873456B (zh)
WO (1) WO2014094483A1 (zh)

Families Citing this family (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN105120505B (zh) * 2015-07-28 2019-04-16 小米科技有限责任公司 智能设备接入路由器的方法、装置以及系统
CN105142183B (zh) * 2015-10-09 2018-11-06 烽火通信科技股份有限公司 自动识别wifi数据帧并划分优先级的方法及系统
CN107528712A (zh) * 2016-06-22 2017-12-29 中兴通讯股份有限公司 访问权限的确定、页面的访问方法及装置
CN106254388A (zh) * 2016-09-22 2016-12-21 安徽云图信息技术有限公司 云计算环境下的访问控制技术
CN106851780B (zh) * 2016-12-07 2019-12-31 Oppo广东移动通信有限公司 一种网络连接的方法及终端
CN110611913B (zh) * 2019-09-24 2023-03-21 中广核工程有限公司 核电厂无线网络接入方法、系统管理平台和接入系统

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101459728A (zh) * 2007-12-14 2009-06-17 船井电机株式会社 无线通信终端、保护其中数据的方法、程序及记录媒体
CN101895875A (zh) * 2010-07-29 2010-11-24 杭州华三通信技术有限公司 无线网络中网关设备提供差异化服务的方法及系统
US20120127942A1 (en) * 2009-01-22 2012-05-24 Qwest Communications International Inc. Simultaneous Multi-Mode WiFi Differentiated By SSID
CN102612116A (zh) * 2011-01-21 2012-07-25 捷讯研究有限公司 在控制移动终端的接入点操作模式中使用的方法和装置

Family Cites Families (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
GB0102518D0 (en) * 2001-01-31 2001-03-21 Hewlett Packard Co Trusted operating system
US6950628B1 (en) * 2002-08-02 2005-09-27 Cisco Technology, Inc. Method for grouping 802.11 stations into authorized service sets to differentiate network access and services
US20060117174A1 (en) * 2004-11-29 2006-06-01 Arcadyan Technology Corporation Method of auto-configuration and auto-prioritizing for wireless security domain
US20070159997A1 (en) * 2006-01-10 2007-07-12 Hsiu-Ping Tsai Wireless Security Setup between Station and AP Supporting MSSID
EP2039066A1 (en) * 2006-07-07 2009-03-25 NEC Corporation Station, setting information managing device, wireless communication system, setting information obtaining method, computer-readable medium
CN101286948B (zh) * 2008-05-30 2010-10-06 杭州华三通信技术有限公司 一种访问权限控制的方法和无线接入设备
CN102547684A (zh) * 2011-12-28 2012-07-04 中兴通讯股份有限公司 一种数字移动网络联盟控制内容方法及装置

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101459728A (zh) * 2007-12-14 2009-06-17 船井电机株式会社 无线通信终端、保护其中数据的方法、程序及记录媒体
US20120127942A1 (en) * 2009-01-22 2012-05-24 Qwest Communications International Inc. Simultaneous Multi-Mode WiFi Differentiated By SSID
CN101895875A (zh) * 2010-07-29 2010-11-24 杭州华三通信技术有限公司 无线网络中网关设备提供差异化服务的方法及系统
CN102612116A (zh) * 2011-01-21 2012-07-25 捷讯研究有限公司 在控制移动终端的接入点操作模式中使用的方法和装置

Also Published As

Publication number Publication date
EP2814217B1 (en) 2018-05-30
JP2015507896A (ja) 2015-03-12
CN103873456B (zh) 2017-06-06
EP2814217A1 (en) 2014-12-17
CN103873456A (zh) 2014-06-18
JP5849354B2 (ja) 2016-01-27
EP2814217A4 (en) 2015-05-06

Similar Documents

Publication Publication Date Title
CN108616490B (zh) 一种网络访问控制方法、装置及系统
JP6416409B2 (ja) アクセスポイントステアリング
JP6599341B2 (ja) 動的ネットワークアクセス管理のための方法、デバイスおよびシステム
JP5509334B2 (ja) コンピュータネットワーク内の保護リソースへのアクセスを管理するための方法と、そのための物理エンティティおよびコンピュータプログラム
US8769044B2 (en) Controlling, filtering, and monitoring of mobile device access to the internet, data, voice, and applications
WO2014094483A1 (zh) WiFi设备的访问控制方法及WiFi设备
US8479266B1 (en) Network assignment appeal architecture and process
JP5826399B2 (ja) デジタルリビングネットワークアライアンス内容の制御方法及び装置
WO2008009224A1 (en) A content filtering system, device and method
CN112995163B (zh) 资源访问的鉴权方法及装置、存储介质、电子设备
US12022296B2 (en) Network cyber-security platform
WO2011032501A1 (zh) 一种可扩展标记语言文档管理中转发文档内容的方法、设备和系统
WO2009105976A1 (zh) 一种权限控制方法、系统及设备
US9467932B2 (en) Access control method for WiFi device and WiFi device
WO2012155604A1 (zh) 一种控制数字移动网络联盟内容的方法及装置
US10659497B2 (en) Originator-based network restraint system for identity-oriented networks
JP7383145B2 (ja) ネットワークサービス処理方法、システム及びゲートウェイデバイス
KR20120012229A (ko) 불필요한 패킷 송수신 차단 장치 및 그 방법
WO2015127622A1 (zh) 一种根据策略提供服务的方法和系统
JP4817900B2 (ja) 通信システム、アクセス管理方法、アクセス管理プログラムを記録した記録媒体、アクセス管理サーバ、送信端末および中継サーバ
Kahn et al. SACM D. Waltermire, Ed. Internet-Draft NIST Intended status: Standards Track K. Watson Expires: March 13, 2017 DHS
JP2009239331A (ja) アクセス管理システム、アクセス管理方法、及びアクセス制御用プログラム

Legal Events

Date Code Title Description
WWE Wipo information: entry into national phase

Ref document number: 2013807886

Country of ref document: EP

ENP Entry into the national phase

Ref document number: 2014552514

Country of ref document: JP

Kind code of ref document: A

121 Ep: the epo has been informed by wipo that ep was designated in this application

Ref document number: 13807886

Country of ref document: EP

Kind code of ref document: A1

NENP Non-entry into the national phase

Ref country code: DE