WO2014005330A1 - 一种服务注册与发现的方法,设备和系统 - Google Patents

一种服务注册与发现的方法,设备和系统 Download PDF

Info

Publication number
WO2014005330A1
WO2014005330A1 PCT/CN2012/078314 CN2012078314W WO2014005330A1 WO 2014005330 A1 WO2014005330 A1 WO 2014005330A1 CN 2012078314 W CN2012078314 W CN 2012078314W WO 2014005330 A1 WO2014005330 A1 WO 2014005330A1
Authority
WO
WIPO (PCT)
Prior art keywords
service
sta
direct connection
information
frame
Prior art date
Legal status (The legal status 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 status listed.)
Ceased
Application number
PCT/CN2012/078314
Other languages
English (en)
French (fr)
Inventor
庄艳
王云贵
顾颖杰
孙福清
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Huawei Technologies Co Ltd
Original Assignee
Huawei Technologies Co Ltd
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
Priority to EP16202340.2A priority Critical patent/EP3223564B1/en
Priority to KR1020157001243A priority patent/KR101702606B1/ko
Priority to PCT/CN2012/078314 priority patent/WO2014005330A1/zh
Priority to CN201280000930.6A priority patent/CN103891355B/zh
Priority to ES16202340T priority patent/ES2727442T3/es
Priority to EP12880569.4A priority patent/EP2858421B1/en
Priority to KR1020177002559A priority patent/KR101727090B1/ko
Priority to JP2015518775A priority patent/JP6068630B2/ja
Application filed by Huawei Technologies Co Ltd filed Critical Huawei Technologies Co Ltd
Priority to ES12880569.4T priority patent/ES2624429T3/es
Publication of WO2014005330A1 publication Critical patent/WO2014005330A1/zh
Priority to US14/587,213 priority patent/US9794865B2/en
Anticipated expiration legal-status Critical
Priority to US15/703,636 priority patent/US10433241B2/en
Ceased legal-status Critical Current

Links

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04WWIRELESS COMMUNICATION NETWORKS
    • H04W48/00Access restriction; Network selection; Access point selection
    • H04W48/16Discovering, processing access restriction or access information
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L67/00Network arrangements or protocols for supporting network services or applications
    • H04L67/50Network services
    • H04L67/51Discovery or management thereof, e.g. service location protocol [SLP] or web services
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L67/00Network arrangements or protocols for supporting network services or applications
    • H04L67/50Network services
    • H04L67/56Provisioning of proxy services

Definitions

  • a wireless local area network (WLAN) based on the IEEE (Institute of Electrical and Electronics Engineers) 802.11 is a local area network that utilizes radio frequency technology and uses a wireless channel as a transmission medium.
  • a WLAN usually includes a station (station called a STA), an access point (a station called an AP), and the like; a STA refers to a device having a wireless LAN interface, and the AP can be configured by a wireless medium in addition to the function of the STA.
  • the associated STA provides an interface, which is connected to the distribution system, and is responsible for implementing communication between STAs or STAs and the wired network; multiple STAs can be associated with the same AP.
  • the STA Before the STA accesses the WLAN, it first needs to search the network in the area, find the available AP and associate it with the available APs found. There are usually two ways to discover available APs: active scanning and passive scanning. among them,
  • the STA broadcasts a probe request frame on each channel, actively scans the available APs on the channel, and receives the probe response frame returned by the available APs to obtain the information of the available APs.
  • Passive scanning mode The AP periodically sends a beacon frame.
  • the STA listens to the beacon frame one by one to capture the beacon frame sent by the AP and obtain the information of the available AP.
  • the BSS can be identified by a basic service set identifier (BSSID).
  • BSSID basic service set identifier
  • the BSSID is The AP's media access control (MAC) address.
  • Wireless fidelity (WiFi) technology is a short-range wireless Communication technology, based on its advantages of convenient use and high transmission rate, has been widely used in wireless LAN construction and wide area network access.
  • WiFi Wireless fidelity
  • WLAN has become an important technology for informationization, home informationization and personal informationization in the industry, and is widely used in enterprises.
  • WiFi direct connection technology can establish device discovery and point-to-point (P2P) direct connection, and devices can share, display, print and synchronize content.
  • P2P point-to-point
  • WiFi Direct technology is the use of P2P to discover the devices needed, build or join groups, establish connections, and then communicate within the group.
  • WiFi direct connection technology provides a close-range device discovery, which only provides device-based discovery and discovery, and the device needs to periodically listen to channels in response to device discovery and information sharing; therefore, WiFi direct connection technology is subject to Limited to the distance between devices, service-based discovery and lookup cannot be provided, and the device needs to consume a lot of resources for listening to the channel. Summary of the invention
  • an embodiment of the present invention provides a method, a device, and a system for receiving and maintaining a service.
  • the access point AP receives and maintains the service information declared by the STA, and the proxy STA discovers the service information in the network, and further includes discovering the It also services and manages direct communication between STAs to meet the needs of users to select networks based on required services.
  • a method for service discovery including:
  • the first access point AP receives a service discovery request frame from the first station STA,
  • the service discovery request frame includes M service query items, where the M is an integer greater than or equal to 0;
  • the obtaining the query result that meets the M service query items includes: acquiring the service information table of the first AP, and satisfying the M services at the same time The query result of the query item.
  • the obtaining, by the obtaining, the query result that meets the M service query items specifically includes:
  • the service discovery response frame returned by the second AP includes the service information table of the second AP.
  • All the service information of the M service query items; the query result specifically includes: all service information that satisfies the M service query items in the service information table of the first AP, and returned by the second AP Service discovery The service information included in the response frame.
  • the obtaining, by the obtaining, the query result that meets the M service query items specifically includes:
  • the service discovery request frame is forwarded to the second AP, and the service discovery response frame returned by the second AP is received, and the service discovery response frame returned by the second AP includes the second All the service information of the M service query items are met in the service information table of the AP, and the service information included in the service discovery response frame returned by the second AP is obtained.
  • the method further includes:
  • the probe response frame includes a service information element, and the service information element includes a service directory entry.
  • the method before the first AP receives the service discovery request frame from the first STA, the method further includes: the first AP broadcasts a beacon frame, the beacon frame includes a service information element, and the service information element includes a service directory entry.
  • a method for service discovery including:
  • the first station STA sends a service discovery request frame to the first access point AP, where the service discovery request frame includes M service query items, where the M is an integer greater than or equal to 0; and receives a service discovery response returned by the AP.
  • the service discovery response frame includes a query result that satisfies the M service query items.
  • the method before the sending, by the STA, the service discovery request frame to the first AP, the method further includes:
  • the first STA broadcasts a probe request frame that is sent, and the probe request frame includes Service information element
  • the method before the sending, by the first STA, the service discovery request frame to the first AP, the method further includes:
  • beacon frame sent by the first AP broadcast, where the beacon frame includes a service information element, and the service information element includes a service directory entry.
  • a first access point AP for service discovery including: a receiving unit, configured to receive a service discovery request frame from a first station STA, where the service discovery request frame includes M services Query term; the M is an integer greater than or equal to 0.
  • a querying unit configured to query a service information table of the first AP according to the service discovery request frame, and obtain a query result that satisfies the M service query items;
  • a sending unit configured to return a service discovery response frame to the first STA, where the service discovery response frame includes the query result.
  • the query unit specifically includes: a local subunit, configured to query a service information table of the first AP according to the service discovery request frame, and obtain the first All service information of the M service query items are met in the service information table of the AP;
  • a remote sub-unit configured to forward the service discovery request frame to the second AP, and receive a service discovery response frame returned by the second AP, where the service discovery response frame returned by the second AP includes the second AP
  • the service information table satisfies all the service information of the M service query items, and obtains the service information included in the service discovery response frame returned by the second AP;
  • a result obtaining subunit configured to obtain a query node that satisfies the M service query items
  • the query result specifically includes service information acquired by the local subunit, and service information acquired by the remote subunit.
  • the query unit specifically includes: a searching subunit, configured to query a service information table of the first AP according to the service discovery request frame;
  • a remote subunit configured to: when the search result of the lookup subunit is: if any one of the service information tables of the first AP does not satisfy the M service query items, forwarding the a service discovery request frame, and receiving a service discovery response frame returned by the second AP, where the service discovery response frame returned by the second AP includes the M service query items in the service information table of the second AP All service information; obtaining service information included in a service discovery response frame returned by the second AP;
  • a local sub-unit configured to: when the search result of the lookup sub-unit is: at least one piece of service information in the service information table of the first AP meets the M service query items, and obtain service information of the first AP In the table, all service information of the M service query items are satisfied.
  • the AP further includes a scanning unit
  • the scanning unit is configured to broadcast a beacon frame, where the beacon frame includes a service information element, where the service information element includes a service directory entry, or is configured to receive a probe request frame that is sent by the first STA. And returning a probe response frame to the first STA, where the probe request frame includes a service information element, the probe response frame includes a service information element, and the service information element includes a service directory entry.
  • the fourth aspect provides a first station STA for service discovery, including: a sending unit, configured to send a service discovery request frame to the first access point AP, where the service discovery request frame includes M months Service item; And a receiving unit, configured to receive a service discovery response frame returned by the first AP, where the service discovery response frame includes a query result that satisfies the M service query items.
  • the first STA further includes a scanning unit
  • the scanning unit is configured to receive a beacon frame that is sent by the first AP, where the beacon frame includes a service information element, where the service information element includes a service directory entry, or is used to broadcast a probe request frame. And receiving the probe response frame returned by the first AP, where the probe request frame includes a service information element, the probe response frame includes a service information element, and the service information element includes a service directory entry.
  • a method for service registration including:
  • the first access point AP receives a service advertisement request frame from the first station STA, where the service advertisement request frame includes a device address of the first STA and at least one service declaration item, where the service declaration item includes a service name;
  • service information table of the first AP Recording, in the service information table of the first AP, service information corresponding to each service claim item in the at least one service declaration item, where the service information includes a basic service set identifier BSSID, a device identifier, a service identifier, and a service declaration item. ;
  • a service advertisement response frame where the service advertisement response frame includes a device identifier of the STA and a service claim response item corresponding to each service claim item in the at least one service claim item; the service The claim response item includes the service identifier and the service name.
  • the acquiring the device identifier of the first STA specifically includes: Querying, according to the device address of the first STA, an address correspondence table of the AP, where the address correspondence table includes a correspondence between a device address and a device identifier,
  • the device identifier of the existing address is obtained, that is, the first STA is Device identification
  • the device identifier of the first STA is allocated from the device identifier pool, and
  • the address correspondence table records the correspondence between the device address of the first STA and the address of the device identifier.
  • the service advertisement request frame further includes a device identifier of the first STA
  • the acquiring the device identifier of the first STA specifically includes:
  • the acquiring the at least one service claim item according to the at least one service claim item includes:
  • the first service identifier is allocated according to the service name of the first service claim ;
  • the service information table of the first AP records a corresponding one of each service claim item in the at least one service claim item.
  • Service information includes:
  • the first AP acquires first service information, where the first service information includes a BSSID of the first AP, a device identifier of the first STA, the first service identifier, and the first service declaration item;
  • the method further includes:
  • the first AP sends a first service maintenance frame to the second AP, where the first service maintenance frame includes service information corresponding to each service statement in the first maintenance state and the at least one service statement, so that The second AP updates the service information table of the second AP.
  • the method further includes:
  • the second service maintenance frame includes a second maintenance state and at least one service maintenance item;
  • the service maintenance item includes a BSSID, a device identifier, and a good Service identification
  • the first AP updates the service information table of the first AP according to the second service maintenance frame.
  • the method further includes:
  • the first AP senses that the first STA is detached
  • All the service information declared by the first STA in the service information table of the first AP is deleted.
  • the method further includes:
  • the first AP receives a third service maintenance frame, where the third service maintenance frame includes a first maintenance state and at least one service information, or a second maintenance state and at least one service maintenance item;
  • the first AP updates the service information table of the first AP according to the third service maintenance frame.
  • a method for service registration including:
  • the first station STA sends a service advertisement request frame to the first access point AP, where the service advertisement request frame includes a device address of the STA and at least one service declaration item, where the service declaration item includes a service name;
  • the service advertisement response frame includes a device identifier of the STA and a service claim response item corresponding to each service claim item in the at least one service claim item;
  • the service claim response item includes the service ID and the service name.
  • the method further includes: the first STA sending a service maintenance frame to the first AP, so that the first AP updates according to the service maintenance frame. a service information table of the first AP;
  • the service maintenance frame includes a second maintenance state and at least one service maintenance item; the service maintenance item includes a basic service set identifier BSSID, a device identifier, and a service identifier.
  • a first access point AP for service registration including: a receiving unit, configured to receive a service advertisement request frame from a first station STA, where the service advertisement request frame includes the a device address of the STA and at least one service declaration item, where the service declaration item includes a service name;
  • a first acquiring unit configured to acquire a device identifier of the first STA
  • a second obtaining unit configured to obtain, according to the at least one service claim item, a service identifier corresponding to each service claim item in the at least one service claim item
  • a recording unit configured to record, in a service information table of the first AP, service information corresponding to each service claim item in the at least one service claim item, where the service information includes a basic service set identifier BSSID, a device identifier, and a service Identification and service declarations;
  • a sending unit configured to return a service advertisement response frame to the first STA, where the service advertisement response frame includes a device identifier of the first STA and a service corresponding to each service claim item in the at least one service claim item Declaring a response item; the service claim response item includes a service identifier and a service name.
  • the first acquiring unit is configured to: query an address correspondence table of the first AP according to a device address of the first STA, and the address correspondence relationship The table includes the correspondence between the device address and the device identifier.
  • the existing device is obtained.
  • the device identifier of the address corresponding to the address of the first STA is not the same as the device address of the first STA in the address correspondence table of the first AP.
  • the device identifier of the first STA is allocated from the device identifier pool, and the address correspondence between the device address of the first STA and the device identifier is recorded in the address correspondence table.
  • the service advertisement request frame further includes a device identifier of the first STA, where the first acquiring unit is specifically configured to obtain, by using the service advertisement request frame The device identifier of the first STA.
  • the second acquiring unit is specifically configured to: according to the first service in the at least one service claim The service name of the claim item, and the service of the first AP is queried.
  • the service name of any one of the service information tables of the first AP is different from the service name of the first service declaration item, the service name is assigned according to the first service declaration item.
  • a service identifier when the service name of the existing service information in the service information table of the first AP is the same as the service name of the first service declaration item, obtaining the service identifier of the existing service information, that is, And a first service identifier corresponding to the service name of the first service declaration item.
  • the recording unit is specifically configured to acquire first service information, where the first service information includes a BSSID of the first AP, where Decoding the device identifier of the first STA, the first service identifier and the first service declaration item; and recording the first service information in a service information table of the AP.
  • the first AP further includes a maintenance unit
  • the maintenance unit is configured to receive a second service maintenance frame from the first STA, where the second service maintenance frame includes a second maintenance state and at least one service maintenance item; and according to the second service maintenance frame, Updating a service information table of the first AP; and forwarding the second service maintenance frame to the second AP, so that the second AP updates the service information table of the second AP;
  • the service maintenance item includes a BSSID , device ID and service ID.
  • the maintenance unit is further configured to send a first service maintenance frame to the second AP, where the first service maintenance frame includes the first Maintaining service information corresponding to each service claim in the at least one service claim, so that the second AP updates the service information table of the second AP; the service information includes a BSSID, a device identifier, and a service Identification and service declarations.
  • the maintenance unit is further configured to receive a third service maintenance frame, where the third service maintenance frame includes a first maintenance state and at least one service information, or a second maintenance state and at least one service maintenance item; Updating the first according to the third service maintenance frame
  • the eighth aspect provides a first station STA for service registration, including: a sending unit, configured to send a service advertisement request frame to the first access point AP, where the service advertisement request frame includes the first a device address of the STA and at least one service declaration item, where the service declaration item includes a service name;
  • a receiving unit configured to receive a service advertisement response frame from the first AP, where the service advertisement response frame includes a device identifier of the first STA and a corresponding one of the at least one service claim item
  • the service affirmation response item; the service affirmation response item includes a service identifier and a service name.
  • the sending unit is further configured to send a second service maintenance frame to the first AP, where the second service maintenance frame includes a second maintenance state and at least one service maintenance
  • the service maintenance item includes a basic service set identifier BSSID, a device identifier, and a service identifier.
  • a direct connection service request frame sent by the first station STA where the direct connection service request frame includes a service request status and a service name; when the service request status is the first request status, acquiring the first Detecting a distance between the first STA and the second STA by detecting a distance between the first STA and the second STA according to the device address of the second STA;
  • the direct connection service management table of the first AP When the distance between the first STA and the second STA is not greater than the direct connection distance, query the direct connection service management table of the first AP; When there is no existing direct connection service management information in the direct connection service management table of the first AP, the service name of the existing direct connection service management information is the same as the service name in the direct connection service request frame. And when the group address of the existing direct connection service management information is the same as the device address of the second STA, the first direct connection service management information is recorded in the direct connection service management table of the first AP, where the The service management information includes the service name in the direct connection service request frame and the device address of the second STA; and sends a direct connection service response frame to the first STA; the direct connection service response frame The device address of the second STA is included.
  • the method further includes: when the direct connection service management table of the first AP has a service name of the existing direct connection service management information, and the direct connection service When the service name in the request frame is the same, and the group address of the existing direct connection service management information is the same as the device address of the second STA, the first AP sends a direct connection service response frame to the first STA. And the direct connection service response frame includes a group address in the existing direct connection service management information.
  • the acquiring the device address of the second STA specifically includes: the first AP according to the direct connection service request frame Querying the service information table of the first AP; the service name of the existing service information in the service information table of the first AP is the same as the service name in the direct connection service request frame, and
  • the first AP acquires the device identifier in the existing service information, that is, the device identifier of the second STA;
  • the AP acquires the device address of the second STA according to the device identifier of the second STA.
  • the direct connection service request frame further includes a device name; correspondingly, the first AP acquires the second STA
  • the device address specifically includes: the first AP acquiring the The device identifier in the direct connection service request frame is the device identifier of the second STA.
  • the first AP acquires the device address of the second STA according to the device identifier of the second STA.
  • the method when the service request status is a request for the second status, the method further includes: The direct connection service request frame queries the direct connection service management table of the first AP; when the direct connection service management table of the first AP has a service name of the existing direct connection service management information and the straight When the service name in the service request frame is the same, and the group address of the existing direct connection service management information is the same as the device address of the first STA, the existing direct connection service management information is from the first The AP's direct connection service management table is deleted.
  • a method for obtaining a direct connection service is provided, including:
  • the first station STA sends a direct connection service request frame to the first access point AP, where the direct connection service request frame includes a service request status and a service name;
  • a first access point AP for managing a direct connection service including:
  • a receiving unit configured to receive a direct connection service request frame of the first station STA, where the direct service request frame includes a service request status and a service name;
  • a first obtaining unit configured to: when the service request status is the first request status, obtain Taking the device address of the second STA;
  • a detecting unit configured to detect a distance between the first STA and the second STA according to the device address of the second STA acquired by the first acquiring unit;
  • a query unit configured to query a direct connection service management table of the first AP
  • a second obtaining unit configured to obtain direct connection service management information for the direct connection service request of the first STA, where the direct connection service management information includes a group address and a service name
  • a sending unit configured to be used according to the acquiring unit Obtaining the direct connection service management information, and sending a direct connection service response frame to the first STA, so that the first STA establishes a direct connection service with the second STA, where the direct connection service response frame includes The group address.
  • the first acquiring unit is configured to: query, according to the service name in the direct connection service request frame, a service information table of the first AP;
  • the service name of the existing service information in the service information table of the first AP is the same as the service name in the direct connection service request frame, and the device capability in the existing service information is to support Wi-Fi direct connection.
  • Acquiring the device identifier in the existing service information that is, the device identifier of the second STA; acquiring the device address of the second STA according to the device identifier of the second STA; or
  • the device identifier Obtaining, in the direct connection service request frame, the device identifier, the device identifier in the direct connection service request frame, that is, the device identifier of the second STA; obtaining the location according to the device identifier of the second STA The device address of the second STA.
  • the query unit is specifically configured to: when the service request state is the first request state, when the detecting When the distance between the first STA and the second STA detected by the unit is not greater than the direct connection distance, the query is performed according to the service name in the direct connection service request frame and the device address of the second STA. Direct connection service management table of the first AP.
  • the second obtaining unit is specifically configured to: when a service name of the existing direct connection service management information exists in the direct connection service management table of the AP, and the direct connection service request frame When the service name is the same, and the group address of the existing direct connection service management information is the same as the device address of the second STA, the existing direct connection service management information is obtained;
  • the service management information is always connected, and the first direct connection service management information is recorded in the direct connection service management table of the AP; the first direct connection service management information includes the service in the direct connection service request frame Name and device address of the second STA.
  • the first AP further includes a direct connection management unit
  • the query unit is further configured to: when the service request status is the second state, query the direct connection of the first AP according to the service name in the direct connection service request frame and the device address of the first STA Service management table;
  • the direct connection management unit is configured to: when the service request status in the direct connection service request frame is the second request status, when there is an existing direct connection service management in the direct connection service management table of the first AP
  • the service name of the information is the same as the service name in the direct connection service request frame
  • the group address of the existing direct connection service management information is the same as the device address of the first STA
  • the existing direct connection is The service management information is deleted from the direct connection service management table of the first AP.
  • the twelfth aspect provides a STA for obtaining a direct connection service, including: a sending unit, configured to send a direct connection service request frame to the first access point AP, where the direct connection service request frame includes a service Request status and service name; a receiving unit, configured to receive a direct connection service response frame returned by the first AP, where the direct connection monthly service response frame includes a group address;
  • a service establishing unit configured to establish a direct connection service with the second STA corresponding to the group address in the direct connection service response frame, when determining that the direct connection request is successful according to the direct connection service response frame.
  • a system for service discovery comprising a first access point AP for service discovery as described above and a first site STA for service discovery as described above.
  • a system for service registration comprising a first access point AP for service registration as described above and a first site STA for service registration as described above.
  • a direct connection service management system comprising a first access point AP for managing a direct connection service as described above and a first site STA for obtaining a direct connection service as described above.
  • the first AP may proxy the first STA to search for service information in the network, and the first AP may provide a wider range and richer service information for the user through local searching and remote searching, and satisfy the user according to the service.
  • the demand selects the requirements of the network; and the AP can proxy to discover the STAs that provide the direct connection service, and manage the direct communication between the STAs, so that the STAs providing the services in the network do not need to periodically monitor the lookup requests of other devices on the channel, thereby reducing the number of requests.
  • the resource cost and power consumption of the STA that provides the service in addition, the first STA can obtain the service information through the first AP, whether the first STA is associated with the AP, and the first STA is not associated with an AP.
  • the problem of frequent disconnection and detachment between different APs is ensured, and the user can access the network that can provide the service more quickly and accurately, thereby improving the user experience.
  • the first STA associated with the first AP may declare or cancel the service information on the first AP, and the first STA does not need to periodically Listening to the lookup request of other devices on the channel, the first AP may also diffuse the device information and service information declared on the first AP to neighboring APs accessible in the network, or may receive the neighboring APs that are accessible.
  • the service information can be used to provide more abundant service information to the user.
  • the service information maintained on the AP is authenticated and associated with the STA on the AP, ensuring security and ensuring service reliability.
  • FIG. 1 is a flowchart of a method for service discovery according to an embodiment of the present invention
  • FIG. 2 is a flowchart of another method for service discovery according to an embodiment of the present invention
  • FIG. 3 is another service provided by an embodiment of the present invention
  • FIG. 4 is a flowchart of still another method for service discovery according to an embodiment of the present invention
  • FIG. 5 and FIG. 5a are flowcharts of still another method for service discovery according to an embodiment of the present invention
  • FIG. 6 and FIG. 6a are schematic diagrams showing the structure of an access point AP for service discovery according to an embodiment of the present invention
  • FIG. 6b and FIG. 6c are schematic diagrams showing the structure of a query unit in an access point AP for service discovery according to an embodiment of the present invention
  • FIG. 7 and 7a are schematic structural diagrams of a STA for service discovery according to an embodiment of the present invention.
  • FIG. 8 is a flowchart of a method for service registration according to an embodiment of the present invention
  • FIG. 9 and FIG. 9a are flowcharts of another method for registering a month service according to an embodiment of the present invention
  • FIG. 10 and FIG. 10a are flowcharts of still another method for service registration according to an embodiment of the present invention.
  • FIG. 11 and FIG. 11a are schematic diagrams showing the structure of an access point AP for service registration according to an embodiment of the present invention
  • FIG. 12 and FIG. 12a are schematic diagrams showing the structure of a STA for service registration according to an embodiment of the present invention
  • FIG. 13 and FIG. 13a are schematic diagrams showing the structure of a service registration system according to an embodiment of the present invention.
  • FIG. 14 is a schematic diagram of information exchange for service registration according to an embodiment of the present invention
  • FIG. 15 is a flowchart of a method for managing a direct connection service according to an embodiment of the present invention
  • FIG. 17 is a structural diagram of a STA for obtaining a direct connection service according to an embodiment of the present invention
  • FIG. 18 and FIG. 18a are structural diagrams of an access point AP for managing a direct connection service according to an embodiment of the present invention
  • FIG. 19 is a schematic structural diagram of a direct connection service management system according to an embodiment of the present invention
  • FIG. 20 is a schematic diagram of a common behavior frame provided by an embodiment of the present invention
  • 21 is a schematic diagram of a query type table according to an embodiment of the present invention.
  • FIG. 22 is a schematic diagram of a service discovery request frame according to an embodiment of the present invention
  • FIG. 23 is a schematic diagram of a service information table according to an embodiment of the present invention
  • FIG. 24 is a schematic diagram of a service discovery response frame according to an embodiment of the present invention
  • FIG. 25 is a schematic diagram of a service information response element according to an embodiment of the present invention
  • Figure 27 is a schematic diagram of a service advertisement request frame according to an embodiment of the present invention
  • Figure 28 is a schematic diagram of a service advertisement response frame according to an embodiment of the present invention
  • Figure 29 is a schematic diagram of a service maintenance frame according to an embodiment of the present invention
  • FIG. 30 is a schematic diagram of a direct connection service request frame according to an embodiment of the present invention
  • FIG. 31 is a schematic diagram of a direct connection service management table according to an embodiment of the present invention
  • Response frame schematic is a schematic diagram of a direct connection service request frame according to an embodiment of the present invention.
  • the service advertisement request frame, the service advertisement response frame, the service maintenance frame, the service discovery request frame, the service discovery response frame, the direct connection request frame, and the direct connection response frame may be extended by using the existing In the WLAN network
  • the action frame is implemented by a public action frame of 1 J (category); an existing management frame, such as the Public Action used in IEEE 802.Hu, can also be used.
  • the existing Public Action frame is extended.
  • the service discovery request frame is identified by a Public Action field value of 16, and the monthly response field is determined by a Public Action field value of 17
  • the service advertisement request frame is identified by the Public Action field value of 18
  • the service advertisement response frame is identified by the Public Action field value of 19
  • the service maintenance frame is identified by the Public Action field value of 20
  • the direct connection request frame is determined by the Public Action field value.
  • the 21 identifier and the direct response response frame are identified by a Public Action field value of 22;
  • Public Action field value used by the extended Public Action frame in the embodiment of the present invention is an example, and different values may be used as the standard develops, which is not limited by the present invention.
  • the service identifier, the device identifier, and the group identifier involved in the embodiment of the present invention may be allocated according to the local rule, that is, locally unique; or may be allocated according to a global unified rule, that is, globally unique,
  • the embodiment of the invention is not limited thereto.
  • only local service information may be reserved, that is, the service information of the BSS where the user is located; or the local service information may be reserved, and the remote service information may be retained, that is, the accessible phase.
  • the service information of the BSS where the neighbor is located is not limited by the embodiment of the present invention.
  • the service information table in the embodiment of the present invention may be a table, or may be divided into two sub-tables, such as a local service information table and a remote service information table, for which the present invention does not Make a limit.
  • the local service information table stores the service information registered on the UI
  • the remote service information table stores the service information registered on the adjacent access point.
  • querying the local service information table can be understood as querying all service information with the same BSSID as the MAC address of the UI; querying the remote service information table can be understood as querying the BSSID and the MAC of the AP.
  • FIG. 1 is a flowchart of a method for service discovery according to an embodiment of the present invention.
  • the method for discovering the monthly service is implemented by a first access point AP, as shown in FIG. Methods include:
  • the first access point AP receives the service discovery request frame from the first site STA, where the service discovery request frame includes M service query items, where the service query item includes a query type and a query content;
  • the M is an integer greater than or equal to zero.
  • the STA needs to query the required service during the service discovery process
  • the query type may be a query type name, such as a BSSID, a device name, a device capability, a service name, a service identifier, etc.
  • It can be a query type identifier, for example, a query type identifier is defined for each query type name, and the query type identifier is generally globally unified, as long as the technical solution of the present invention can be implemented, the present invention does not limit this.
  • the query type information table shown in FIG. 21 defines a query type identifier for each query type name. Specifically, the present invention does not limit this.
  • the service discovery request frame may be as shown in FIG. 22; wherein a length (length) following the Public Action field value field is variable, and is used to indicate the length of the behavior details in the service discovery request frame;
  • the length (length) in the query item is variable and is used to indicate the length of the query content.
  • the first AP queries the service information table of the first AP according to the service discovery request frame, and obtains a query result that meets the M service query items.
  • the obtaining the query result that satisfies the M service query items specifically includes: obtaining the query result of the M service query items in the service information table of the first AP.
  • the service discovery request frame includes 2 service query items, for example, the first service query item includes: The query type is "service” The service name ", the query content is “print”, the second service query item includes: the query type is "device capability", and the query content is "support Wi-Fi direct connection”, then the query result needs to satisfy the "service name” at the same time.
  • “Print”, and “Device Capability” is "Support Wi-Fi Direct”.
  • the query result is all service information in the service information table of the first AP;
  • the service information includes a basic service set identifier BSSID, a device identifier, a service identifier, and a service name.
  • the service information may further include a network access policy, a device name, a device capability, a service description, and the like.
  • the monthly service information table may be as shown in FIG.
  • the BSSID is the MAC address of the AP associated with the STA that declares the service information. For example, in this implementation, it is the MAC address of the first AP.
  • the query result may be all service information that satisfies the M service query items at the same time; and the service information of the M service query items may also be satisfied at the same time.
  • the service discovery request frame includes two service query items
  • the first service query item includes: the query type is "service name”, the query content is “print”
  • the second The service query items include: The query type is "device capability”, the query content is “support Wi-Fi direct connection”, can return to meet “service name” as “print”, and “device capability” is “support Wi-Fi direct connection” All of the service information of the “services” can also be returned to the "service name” as “printing", and the "device capability” is “all-in-one”.
  • the service information relative to the service information removes the query type "service name” and “device capability” in the service query item. Returning the service information can reduce the amount of information transmitted and improve the transmission efficiency.
  • the first AP returns a service discovery response frame to the first STA, where the service discovery response frame includes the query result.
  • the service discovery response frame may be as shown in FIG. 25; wherein the length (variable) is variable, and is used to indicate the length of the behavior details in the service advertisement response frame.
  • the query result in the service discovery response frame may also be empty, indicating that the first AP does not find the service information that satisfies the M service query items. Then, in the corresponding service frame shown in FIG. 25, the Length field is 0. Further, for the service discovery request of the first STA, the first AP may be searched in the service information table of the first AP, and may also be searched on other accessible neighboring APs, and may be configured as needed.
  • the first AP may forward the service discovery request frame to other accessible neighboring APs in a wireless manner, and receive the service discovery response frame returned by other accessible neighboring APs.
  • the first AP may also forward the service discovery request frame of the first STA to other accessible neighboring APs, and receive the service discovery response frame returned by other accessible neighboring APs; for example,
  • AC access controller
  • the first AP can be bound by data messages in the Control and Provisioning of Wireless Access Point (CAPWAP) protocol.
  • AC access controller
  • CAPWAP Control and Provisioning of Wireless Access Point
  • FIG. 2 is a flowchart of another method for service discovery according to an embodiment of the present invention. This embodiment further describes the technical solution of the present invention based on the method for service discovery shown in FIG. 1 of the present invention; , the method includes:
  • the first AP receives a service discovery request frame from a first station STA, where the service discovery request frame includes M service query items, where the service query item includes a query type identifier and a query content.
  • the M is an integer greater than or equal to zero.
  • the first AP queries the service information table of the first AP according to the service discovery request frame, and obtains a query result that meets the M service query items.
  • the first AP is configured with the forwarding function, that is, the first AP may proxy the STA to discover the service information on the neighboring AP that is accessible by the first AP
  • the 202 specifically includes: 202A - 202C, or 202a - 202c.
  • the first AP queries the service information table of the first AP according to the service discovery request frame, and obtains all service information that meets the M service query items in the service information table of the first AP.
  • the first AP forwards the service discovery request frame to the second AP, and receives a service discovery response frame returned by the second AP, where the service discovery response frame returned by the second AP includes the second All the service information of the M service query items are met in the service information table of the AP, and the service information included in the service discovery response frame returned by the second AP is obtained;
  • the processing procedure after the second AP receives the service discovery request frame may refer to the method 102 in the method shown in FIG. 1 of the present invention.
  • 202C The first AP acquires a query result that meets the M service query items, where the query result specifically includes all service information that meets the M service query items in the service information table of the first AP, and The service information returned by the second AP returns the service information included in the response frame.
  • 202B may be executed before or after 202A; 202B may also be executed in synchronization with 202A.
  • the first AP will forward the service discovery request of the first STA to other accessible phases, whether the service information that satisfies the M service query items can be found on the first AP by 202A to 202C. Adjacent APs for a wider range of service lookups.
  • the first AP queries the service information table of the first AP according to the service discovery request frame; 202b: when any one of the service information tables of the first AP does not satisfy the M
  • the first AP forwards the service discovery request frame to the second AP, and receives a service discovery response frame returned by the second AP, where the service discovery response frame returned by the second AP includes All the service information of the M service query items are met in the service information table of the second AP; the first AP acquires the service information included in the service discovery response frame returned by the second AP;
  • the process of the second AP after receiving the service discovery request frame may refer to 102 in the method shown in FIG. 1 of the present invention.
  • the first AP may record, in the service information table of the first AP, that the M service query items are satisfied on the second AP included in the service discovery response frame returned by the second AP. All service information.
  • the first AP forwards the service discovery request of the first STA to other accessible neighboring APs to perform a wider range of service search.
  • the device may also carry the device address or the device identifier of the first STA, so that the second AP determines whether the second AP has processed The service discovery request of the first STA.
  • the first AP can forward the service discovery request of the first STA to the second AP as an example to describe the technical solution of the present invention.
  • the neighboring AP that the first AP can access may be There are multiple, the process is the same, and will not be described here.
  • the first AP returns a service discovery response frame to the first STA, where the service discovery response frame includes the query result.
  • the first AP may find the accessible range.
  • Service information thus providing a wider range of service discovery and discovery functions, providing users with richer service information to meet the needs of users to select networks according to service needs.
  • the STA does not have any available AP information before the association, and needs to obtain the available AP information through scanning, and associates with the available AP.
  • the STA scan obtains the available AP, which can be implemented by active scanning or passive scanning.
  • the service discovery request frame and the service discovery response frame are obtained, and the service information on the available AP is obtained.
  • the existing scan mode may also be extended to obtain the available AP information.
  • the service directory information on the available APs can be obtained, and new frames can be defined for the active scan and the passive scan respectively, or the probe request ( probe request) can be extended, the probe response (probe response), the beacon (beacon) ⁇ ,
  • Example: 3 ⁇ 4 port defines a new information element (information element), used to describe the monthly information, this issue Ming does not limit this.
  • a new service information element (service request element) is defined, and a probe request, a probe response frame, and a beacon are extended, and the available AP information is acquired.
  • the technical solution of the present invention is described by taking the service directory information on the available AP as an example.
  • the service information element is distinguished by the element ID.
  • the element ID is reserved for 17-31, 128-129, and 133-136. It has not been used yet, and one of them can be selected as one.
  • the element ID of the service information element extended by the technical solution of the present invention.
  • FIG. 3 is a flowchart of still another method for service discovery according to an embodiment of the present invention. The technical solution of the present invention is further described on the basis of the method for service discovery shown in FIG. 1 or FIG. 2 . As shown in FIG. 3, the method includes:
  • the first access point AP broadcasts and sends a beacon frame, where the beacon frame includes a service information element.
  • the first AP When the passive scanning mode is adopted, the first AP periodically broadcasts a beacon frame, and the first station STA needs to monitor the channel by channel to capture the beacon frame sent by the first AP, and obtain the information and location of the first AP.
  • the service directory information on the first AP When the passive scanning mode is adopted, the first AP periodically broadcasts a beacon frame, and the first station STA needs to monitor the channel by channel to capture the beacon frame sent by the first AP, and obtain the information and location of the first AP.
  • the service directory information on the first AP When the passive scanning mode is adopted, the first AP periodically broadcasts a beacon frame, and the first station STA needs to monitor the channel by channel to capture the beacon frame sent by the first AP, and obtain the information and location of the first AP.
  • the service directory information on the first AP When the passive scanning mode is adopted, the first AP periodically broadcasts a beacon frame, and the first station STA needs to monitor the channel by channel to capture the beacon frame sent by the first AP, and
  • the service information element includes a service directory entry, and the service directory entry includes a BSSID, a service identifier, and a service name.
  • the service information element may further include a network type
  • the service directory entry may further include a service description.
  • the network type may be defined in accordance with the IEEE 802.11 standard, such as a private network.
  • the example "1" is generated, and the service information element can be as shown in Fig. 26.
  • the length (length) takes a value of 0 to 256 bytes and is used to indicate the length of the service information element.
  • the first AP receives a service discovery request frame from a first station STA, where the service discovery request frame includes M service query items, where the service query item includes a query type identifier and a query content.
  • the M is an integer greater than or equal to zero.
  • the first AP queries the service information table of the first AP according to the service discovery request frame, and obtains a query result that meets the M service query items.
  • the first AP returns a service discovery response frame to the first STA, where the service discovery response frame includes the satisfying the query result.
  • FIG. 4 is a flowchart of still another method for service discovery according to an embodiment of the present invention. This embodiment further describes the technical solution of the present invention based on the method for service discovery shown in FIG. 1 or FIG. 2; , the method includes:
  • the first access point AP receives a probe request frame that is sent by the first station STA, where the probe request frame includes a service information element.
  • the length (length) field in the service information element is 0.
  • the first STA When the active scanning mode is adopted, the first STA sends a probe request frame carrying a service element on each channel, actively scans available APs on the channel, and requests service directory information on the available AP.
  • the first AP returns a probe response frame to the first STA, where the probe response frame includes a service information element.
  • the service information element includes a service directory entry, and the service directory entry includes a BSSID, a service identifier, and a service name;
  • the first AP After the first AP receives the probe request frame of the first STA, the first AP is sent to the first The STA returns a probe response frame, and provides information about the first AP to the first STA. Meanwhile, the first AP returns to the first STA because the probe request frame includes a monthly service information element. The service response element is also included in the probe response frame, and the first STA is provided with service directory information on the first AP.
  • the service information element may further include a network type
  • the service directory entry may further include a service description.
  • the network type may be defined in accordance with the IEEE 802.11 standard, such as a private network.
  • the example "1" is generated, and the service information element can be as shown in Fig. 26.
  • the length (length) takes a value of 0 to 256 bytes and is used to indicate the length of the service information element.
  • the first AP receives a service discovery request frame from the first STA, where the service discovery request frame includes M service query items, where the service query item includes a query type identifier and a query content.
  • the M is an integer greater than or equal to zero.
  • the first AP queries the service information table of the first AP according to the service discovery request frame, and obtains a query result that meets the M service query items.
  • the first AP returns a service discovery response frame to the first STA, where the service discovery response frame includes the satisfying the query result.
  • FIG. 5 is a flowchart of still another method for service discovery according to an embodiment of the present invention.
  • the method for service discovery is implemented by a STA at a first station. As shown in FIG. 5, the method includes:
  • the first station STA sends a service discovery request frame to the first access point AP, where the service discovery request frame includes M service query items, where the service query item includes a query type and a query content.
  • the M is an integer greater than or equal to zero.
  • the STA needs to query the required service during the service discovery process
  • the query type may be a query type name, such as a BSSID, a device name, a device capability, a service name, a service identifier, etc.
  • It can be a query type identifier, for example, a query type identifier is defined for each query type name, and the query type identifier is generally globally unified, as long as the technical solution of the present invention can be implemented, the present invention does not limit this.
  • the query type information table shown in FIG. 21 defines a query type identifier for each query type name. Specifically, the present invention does not limit this.
  • the service discovery request frame may be as shown in FIG. 22; wherein a length (length) following the Public Action field value field is variable, and is used to indicate the length of the behavior details in the service discovery request frame;
  • the length (length) in the query item is variable and is used to indicate the length of the query content.
  • the first STA receives a service discovery response frame returned by the first AP, where the service discovery response frame includes a query result that satisfies the M service query items.
  • the query result may be service information that satisfies the M service query items at the same time; or may be a piece of service information that simultaneously satisfies the M service query items.
  • the service information includes a basic service set identifier BSSID, a device identifier, a service identifier, and a service name.
  • the service information may further include a network access policy, a device name, a device capability, a service description, and the like.
  • the service information table may be as shown in FIG.
  • the BSSID is the MAC address of the AP associated with the STA that declares the service information. For example, in this implementation, it is the MAC address of the first AP.
  • the service discovery request frame includes two service query items
  • the first service query item includes: the query type is "service name”, the query content is “print”
  • the second The service query items include: The query type is "device capability”, and the query content is "Wi-Fi Direct”; then the query result is that "service name” is “printed” at the same time, and "device capability” is "Wi-Fi straight”
  • All of the service information of "even” can also be all the information about the service that the "service name” is “printed” and the "device capability” is "Wi-Fi direct connection", which is not limited by the present invention.
  • the service information is compared with the service information, and the query types "service name” and “device capability” in the service query item are removed. Returning the service information can reduce the amount of information transmitted and improve the transmission efficiency.
  • the service discovery response frame may be as shown in FIG. 25; wherein the length (variable) is variable, and is used to indicate the length of the behavior details in the service advertisement response frame.
  • the query result in the service discovery response frame may also be empty, indicating that the first AP does not find the service information that satisfies the M service query items. Then, in the corresponding service frame shown in FIG. 25, the Length field is 0.
  • a timer may also be set, if the first time is not received within a time set by the timer.
  • the service discovery response frame returned by the AP the first STA considers that the current service discovery fails; the first STA may send the service discovery request frame to the first AP again, or may send a service discovery request frame to other APs. .
  • the first STA needs to scan for available AP information and request service directory information on the available AP.
  • the method further includes:
  • the first STA broadcasts a probe request frame, where the probe request frame includes a service information element.
  • the length (length) field in the service information element is 0.
  • the probe request frame is used to request to obtain service directory information on the AP. Therefore, the service directory entry of the service information element in the probe request frame is empty, and the length (length) field in the service information element is 0.
  • the first STA receives a probe response frame returned by the first AP, where the probe response frame includes the service information element, the service information element includes a service directory entry, and the service directory entry includes a BSSID. , service ID and service name.
  • the method further includes:
  • the first STA receives a beacon frame that is sent by the first AP, where the beacon frame includes a service information element, where the service information element includes a service directory entry, and the service directory entry includes a BSSID. Service identification and service name;
  • the first AP When the passive scanning mode is adopted, the first AP periodically broadcasts a beacon frame, and the first STA needs to monitor the channel by channel to capture the beacon frame sent by the first AP, and obtain the information and location of the AP.
  • the service catalog information on the AP When the passive scanning mode is adopted, the first AP periodically broadcasts a beacon frame, and the first STA needs to monitor the channel by channel to capture the beacon frame sent by the first AP, and obtain the information and location of the AP.
  • the service catalog information on the AP The service catalog information on the AP.
  • the first STA can search for the device information and the service information that can be provided in the network by using the first AP proxy to obtain richer service information. Users choose the network according to service needs The requirement of the network can also prevent the first STA from being associated with an AP and discover that there is no required service to detach again, resulting in frequent association and disconnection between different APs, ensuring that users can access the available services more quickly and accurately.
  • the network improves the user experience.
  • the embodiment of the present invention provides a service discovery system, where the system includes a first access point AP as shown in FIG. 6 and a first station STA as shown in FIG. 7; the first STA and the first The AP interacts to implement the method for service discovery provided by the embodiment of the present invention.
  • the system may further include a second AP, where the second AP is a neighboring AP that is accessible by the first AP. It may be understood that multiple second APs may exist in the system.
  • the first STA and the first AP in the service discovery system provided by the embodiment of the present invention are described in detail below.
  • FIG. 6 is a schematic structural diagram of a first access point AP for service discovery according to an embodiment of the present invention. As shown in FIG. 6, the first AP includes a receiving unit 601, a query unit 602, and a sending unit 603. among them,
  • the receiving unit 601 is configured to receive a service discovery request frame from the first station STA, where the service discovery request frame includes M service query items;
  • the service query item includes a query type and a query content; the M is an integer greater than or equal to 0.
  • the STA needs to query the required service during the service discovery process
  • the query type may be a query type name, such as a BSSID, a device name, a device capability, a service name, a service identifier, etc.
  • It can be a query type identifier, for example, a query type identifier is defined for each query type name, and the query type identifier is generally globally unified, as long as the technical solution of the present invention can be implemented, the present invention does not limit this.
  • the query type information table shown in FIG. 21 defines a query type identifier for each query type name. Specifically, the present invention does not limit this.
  • the service discovery request frame may be as shown in FIG. 22; wherein Public The length (length) following the Action field value field is variable, and is used to indicate the length of the behavior details in the service discovery request frame; the length (length) in each service query item is variable, and is used to indicate the length of the query content.
  • the querying unit 602 is configured to query the service information table of the first AP according to the service discovery request frame, and obtain a query result that satisfies the M service query items.
  • the query unit 602 is specifically configured to acquire the In the service information table of the first AP, the query result of the M service query items is simultaneously satisfied.
  • the service discovery request frame includes one service query item, for example, the query type is "service name” and the query content is “print”, the query result needs to satisfy "service name” as "" Print
  • the service discovery request frame includes 2 service query items, for example, the first service query item includes: the query type is "service name”, the query content is "print”, the second The service query items include: The query type is "device capability”, and the query content is "support Wi-Fi direct connection", then the query result must satisfy the "service name” as "print”, and the "device capability” is "support Wi-" Fi direct connection.”
  • the query result is all service information in the service information table of the first AP;
  • the service information includes a basic service set identifier BSSID, a device identifier, a service identifier, and a service name.
  • the service information may further include a network access policy, a device name, a device capability, a service description, and the like.
  • the service information table may be as shown in FIG.
  • the BSSID is the MAC address of the AP associated with the STA that declares the service information. For example, in this implementation, it is the MAC address of the first AP.
  • the query result may be all service information that satisfies the M service query items at the same time; and the service information of the M service query items may also be satisfied at the same time.
  • M the service discovery request frame includes two service query items
  • the first service query item includes: the query type is "service name”, the query content is "print”, the second The service query items include: The query type is "device capability”, the query content is “support Wi-Fi direct connection”, can return to meet “service name” as “print”, and “device capability” is “support Wi-Fi direct connection” All of the service information of the "services” can also be returned to the "service name” as “printing", and the "device capability” is “all-in-one”.
  • the service information is compared with the service information, and the query type "service name” and “device capability” in the service query item are removed. Returning the service information can reduce the amount of information transmitted and improve the transmission efficiency.
  • the sending unit 603 is configured to return a service discovery response frame to the first STA, where the service discovery response frame includes the query result.
  • the service discovery response frame may be as shown in FIG. 25.
  • the length (variable) is variable, and is used to indicate the length of the behavior details in the service notification response frame.
  • the query result in the service discovery response frame may also be empty, indicating that the first AP does not find the service information that satisfies the M service query items. Then, in the corresponding service frame shown in FIG. 25, the Length field is 0.
  • the first AP further includes a scanning unit 604;
  • the scanning unit 604 is configured to broadcast a beacon frame, or to receive a probe request frame that is sent by the first STA, and return a probe response frame to the first STA.
  • the scanning unit 604 is specifically configured to periodically broadcast a beacon frame, where the beacon frame includes a service information element, the service information element includes a service directory item, and the service directory item includes a BSSID. , service ID and service name.
  • the first The STA needs to monitor the channel by channel to capture the beacon frame sent by the first AP, and obtain information about the first AP and service directory information on the first AP.
  • the first STA When the active scanning mode is adopted, the first STA sends a probe request frame carrying a service information element on each channel, actively scans available APs on the channel, and requests service directory information on the available AP.
  • the scanning unit 604 is specifically configured to receive a probe request frame that is sent by the first STA, where the probe request frame includes a service information element, and a length (length) field in the service information element is 0;
  • the first STA returns a probe response frame, where the probe response frame includes a service information element, the service information element includes a service directory entry, and the service directory entry includes a BSSID, a service identifier, and a service name, where
  • the first STA provides information of the first AP and service directory information on the first AP.
  • the example "1" is generated, and the service information element can be as shown in Fig. 26.
  • the length (length) takes a value of 0 to 256 bytes and is used to indicate the length of the service information element.
  • the service information element may further include a network type
  • the service directory entry may further include a service description.
  • the network type may be defined in accordance with the IEEE 802.11 standard, such as a private network.
  • the query unit 602 includes:
  • the local sub-unit 602A is configured to query, according to the service discovery request frame, the service information table of the first AP, and obtain all service information that meets the M service query items in the service information table of the first AP;
  • the remote sub-unit 602B is configured to forward the service discovery request frame to the second AP, and receive the service discovery response frame returned by the second AP, where the service discovery response frame returned by the second AP includes the second All the service information of the M service query items are met in the service information table of the AP, and the service discovery response frame returned by the second AP is obtained.
  • Information contained in the service
  • the result obtaining sub-unit 602C is configured to obtain an information that satisfies the M service query items and service information acquired by the remote sub-unit 602B.
  • the query unit 602 includes:
  • the locating unit 602a is configured to query, according to the service discovery request frame, a service information table of the first AP;
  • the remote sub-unit 602b is configured to: when the search result of the lookup sub-unit 602a is: if any one of the service information tables of the first AP does not satisfy the M service query items, forward to the second AP And the service discovery request frame, and receiving the service discovery response frame returned by the second AP, where the service discovery response frame returned by the second AP includes the M services in the service information table of the second AP Querying all the service information of the item; obtaining the service information included in the service discovery response frame returned by the second AP; the local subunit 602c, when the search result of the lookup subunit 602a is: the first AP
  • the service information table has at least one piece of service information that satisfies the M service query items, and obtains all the service information of the M service query items in the service information table of the first AP.
  • FIG. 7 is a schematic diagram of a first STA structure for service discovery according to an embodiment of the present invention; as shown in FIG. 7, the first STA includes a sending unit 701 and a receiving unit 702. among them,
  • the sending unit 701 is configured to send a service discovery request frame to the first access point AP, where
  • the service discovery request frame includes M service query items;
  • the service query item includes a query type and a query content; the M is an integer greater than or equal to 0.
  • the STA needs to query the required service during the service discovery process
  • the query type may be a query type name, such as a BSSID, a device name, a device capability, a service name, a service identifier, etc.
  • It can be a query type identifier, for example, a query type identifier is defined for each query type name, and the query type identifier is generally globally unified, as long as the technical solution of the present invention can be implemented, the present invention does not limit this.
  • the query type information table shown in FIG. 21 defines a query type identifier for each query type name. Specifically, the present invention does not limit this.
  • the service discovery request frame may be as shown in FIG. 22; wherein a length (length) following the Public Action field value field is variable, and is used to indicate the length of the behavior details in the service discovery request frame;
  • the length (length) in the query item is variable and is used to indicate the length of the query content.
  • the receiving unit 702 is configured to receive a service discovery response frame returned by the first AP, where the service discovery response frame includes a query result that satisfies the M service query items.
  • the query result may be all service information that satisfies the M service query items at the same time; and the packaged service information of the M service query items may also be satisfied at the same time.
  • the service information includes a basic service set identifier BSSID, a device identifier, a service identifier, and a service name.
  • the service information may further include a network access policy, a device name, a device capability, a service description, and the like.
  • the service information table may be as shown in FIG. 23.
  • the BSSID is the MAC address of the AP associated with the STA that declares the service information. For example, in this implementation, it is the MAC address of the first AP.
  • the service discovery request frame includes two service query items, for example, the first service query item includes: the query type is "service name”, the query content is "print”, the second The service query items include: The query type is "device capability", and the query content is "support Wi-Fi direct connection", then the query result must satisfy the "service name” as "print”, and the "device capability” is "support Wi-” All the service information of "Fi” is also available; it can also be that all the service information of "Service Name” is "Printed” and “Device Capability” is "Support Wi-Fi Direct Connection", which is not limited by the present invention. .
  • the service information is compared with the service information, and the query type "service name” and "device capability”
  • the service discovery response frame may be as shown in FIG. 25; wherein the length (variable) is variable, and is used to indicate the length of the behavior details in the service advertisement response frame.
  • the query result in the service discovery response frame may also be empty, indicating that the first AP does not find the service information that satisfies the M service query items. Then, in the corresponding service frame shown in FIG. 25, the Length field is 0.
  • the first STA further includes a scanning unit 703;
  • the scanning unit 703 is configured to receive a beacon frame that is sent by the first AP, or to send a probe request frame, and receive a probe response frame returned by the first AP.
  • the first STA may acquire available AP information and request service directory information on the available AP.
  • the scanning unit 703 is specifically configured to broadcast a probe request frame, where the probe request frame includes a service information element, and the service information element
  • the length (length) field is 0; and receives the probe response frame returned by the first AP, where the probe response frame includes the service information element, and the service information element includes a service directory entry, the service Directory entries include BSSID, service ID, and service name.
  • the scanning unit 703 is specifically configured to receive a beacon frame that is sent by the first AP, where the beacon frame includes a service information element, and the service information element includes a service directory entry.
  • the service directory entry includes a BSSID, a service identifier, and a service name.
  • the first STA further includes a timing unit, configured to: after sending the service discovery request frame, set a timer, if the first AP returns is not received within a time set by the timer If the service discovery response frame is considered to be the current service discovery failure, the first STA may send the service discovery request frame to the first AP again, or may send a service discovery request frame to other APs.
  • a timing unit configured to: after sending the service discovery request frame, set a timer, if the first AP returns is not received within a time set by the timer If the service discovery response frame is considered to be the current service discovery failure, the first STA may send the service discovery request frame to the first AP again, or may send a service discovery request frame to other APs.
  • the first AP may proxy the first STA to search for service information in the network, and the first AP may provide a larger range and more for the user through local searching and remote searching.
  • the rich service information can meet the requirements of the user to select the network according to the service requirement.
  • the STAs that provide the service in the network do not need to periodically monitor the lookup requests of other devices on the channel, thereby reducing the resource overhead and energy consumption of the STA providing the service;
  • the first STA can obtain the service information through the first AP, whether the first STA is associated with the AP, and the first STA can be prevented from being disconnected after the first STA is associated with the AP.
  • FIG. 8 is a flowchart of a method for service registration according to an embodiment of the present invention.
  • the method for registering the monthly service is implemented by the first access point AP, as shown in FIG. :
  • the first access point AP receives a service advertisement request frame from the first station STA.
  • the service advertisement request frame includes a device address of the first STA and at least one service declaration item, where the service declaration item includes a service. Name
  • the first STA After the first STA is associated with the first AP, it may send a service advertisement request frame to the first AP, and register a service with the first AP.
  • the device address of the first STA is usually the MAC address of the first STA.
  • the device address of the first STA is usually carried in the header of the service announcement request frame.
  • the service advertisement request frame may further include a device name, a device identifier, a device capability, a device description, and the like of the first STA.
  • the device name of the first STA may be, for example, a printer, a television, or the like, or may be, for example, a cafe No. 1, a ticket center No. 2, etc.; the device capability of the first STA may be, for example, supporting Wi-Fi direct connection. Supporting Bluetooth, etc., can further carry capability parameters in the device capability, for example, when supporting Wi-Fi direct connection, carrying a direct connection distance.
  • the device name of the first STA may be, for example, a printer, a television, or the like, or may be, for example, a cafe No. 1, a ticket center No. 2, etc.
  • the device capability of the first STA may be, for example, supporting Wi-Fi direct connection.
  • Supporting Bluetooth, etc. can further carry capability parameters in the device capability, for example, when supporting Wi-Fi direct connection, carrying a direct connection distance
  • the printer supports Wi-Fi direct connection, and the direct connection distance is L;
  • Ticketing Center No. 2 can provide on-site service; the service declaration item can include a service description in addition to the service name.
  • the service declaration item can include a service description in addition to the service name.
  • the above ticketing center No. 2 can provide the following services:
  • the first STA may register multiple services to the first AP at a time, and the service advertisement request frame includes multiple service declaration items;
  • the STA may also register the service to the first AP in multiple times, that is, each time a service is registered with the first AP, and the registration is performed multiple times, each time the service advertisement request frame includes only one month of service declaration. item.
  • the service advertisement request frame may be as shown in FIG. 27; wherein the length (variable) is variable, and is used to indicate the length of the behavior details in the service advertisement request frame.
  • the first AP acquires a device identifier of the first STA.
  • the first AP queries the address correspondence table of the first AP according to the device address of the first STA, where the address correspondence table includes a correspondence between the device address and the device identifier.
  • the device identifier of the existing address is obtained.
  • the device identifier of the first STA is allocated from the device identifier pool, and Recording, in the address correspondence table, a correspondence between a device address of the first STA and an address of the device identifier.
  • the first AP may also obtain the device identifier of the first STA from the service advertisement request frame.
  • the device identifier DI-1 of the ticketing center of the MAC address is MAC1
  • the device identifier of the printer 1 of the device address of the MAC2 is DI-2;
  • the first AP acquires, according to the at least one service claim, a service identifier corresponding to each service claim in the at least one service claim item; That is, the first ⁇ obtains the corresponding service identifier according to the service name of each service claim item, which specifically includes:
  • the service name of any one of the service information tables in the first service information is different from the service name of the first service declaration item
  • the service name according to the first service declaration item is from the service identification pool. Assigning a first service identifier
  • the service name of the first service information table has the same service name as the service name of the first service declaration item, and the BSSID of the existing service information and the MAC address of the first service
  • the service identifier of the existing service information is obtained, that is, the first service identifier corresponding to the service name of the first service declaration item.
  • the second service identifier corresponding to the service name of the second service declaration item is obtained, and so on.
  • the ticketing center No. 2 sends a service announcement request frame, and the service announcement request frame includes two service declaration items, and the service name of the first service declaration item is "air ticket pre-sale", and the second service declaration The service name of the item is "train ticket pre-sale", then the first AP obtains the service identifier SI-1 according to "air ticket pre-sale”, and then obtains the service identifier SI-2 according to "train ticket pre-sale".
  • the first AP records, in a service information table of the first AP, service information corresponding to each service claim in the at least one service claim item; the service information includes a basic service set identifier BSSID, and a device identifier. , service identification and service declaration items;
  • the first AP acquires the first service information, where the first service information includes a BSSID of the first AP, a device identifier of the first STA, the first service identifier, and the first service.
  • Declaration item And recording the first service information in the service information table of the first AP; if there is a second service declaration item, acquiring the second service information, and recording the location in the service information table of the first AP Said second service information; and so on.
  • the service information may further include a device name of the first STA, a device capability of the first STA, and a network access policy.
  • the network access policy can indicate the access policy in the BSS where the AP is located, or the access policy for a specific month.
  • the API is on the public network
  • AP2 is on the private network
  • the API can access the AP2 according to the AP2 access policy. Private network.
  • the service information may be as shown in FIG. 23; where, the BSSID is the MAC address of the AP associated with the STA that declares the service information; for example, in this implementation, it is the MAC address of the first AP.
  • the first AP returns a service advertisement response frame to the first STA, where the service advertisement response frame includes a device identifier of the first STA and a service affirmation response item corresponding to the at least one service claim item.
  • the service claim response item includes a service identifier and a service name.
  • the service advertisement response frame includes:
  • the service claim corresponding to each service claim in the at least one service claim includes:
  • the first affirmation response item includes a service name of the first service declaration item and the first service identifier
  • the second claim response item includes a service name of the second service claim item and the second service identifier; And so on.
  • the service advertisement response frame may further include the device of the first STA. Name.
  • the service advertisement response frame may be as shown in FIG. 28; wherein the length (variable) is variable, and is used to indicate the length of the behavior details in the service advertisement response frame.
  • the first STA associated with the first AP may declare the service information on the first AP; the first AP manages and maintains the service information in the BSS, and provides a service search function. In this way, the first STA does not need to periodically listen for the lookup request of other devices on the channel, which reduces the resource overhead and power consumption of the first STA.
  • the first AP may forward a service maintenance frame to other accessible neighboring APs by using a wireless manner, and receive service maintenance frames sent by other accessible neighboring APs.
  • the first AP may also forward the service maintenance frame to other accessible neighboring APs by using other methods. For example, when an access controller (Access Controller, called AC) exists in the WLAN, the first AP may pass.
  • AC Access Controller
  • the data message binding encapsulation service maintenance frame in the protocol communicates with other accessible neighboring APs through the AC; for example, when there is no AC in the WLAN, the AP directly connects.
  • the first AP may pass the transmission control protocol and the internet protocol.
  • TCP/IP Transmission Control Protocol/Internet Protocol
  • TCP/IP Transmission Control Protocol/Internet Protocol
  • the present invention does not limit the communication manner between the first AP and other accessible neighboring APs.
  • the following unified forwarding describes the communication between the first AP and other accessible neighboring APs. .
  • FIG. 9 is a flowchart of another method for service registration according to an embodiment of the present invention. This embodiment further describes the technical solution of the present invention based on the method for service registration shown in FIG. 8. As shown in FIG. Methods include:
  • the first access point AP receives a service advertisement request frame from the first station STA.
  • the service advertisement request frame includes a device address of the first STA and at least one service declaration item, where the service declaration item includes a service name;
  • the first AP acquires a device identifier of the first STA according to the device address of the first STA.
  • the first AP acquires, according to the at least one service claim, a service identifier corresponding to each service claim in the at least one service claim item;
  • the first AP records service information corresponding to the at least one service claim in the service information table of the first AP.
  • the service information includes a basic service set identifier BSSID, a device identifier, a service identifier, and a service declaration. Item
  • the first AP returns a service advertisement response frame to the first STA, where the service advertisement response frame includes a device identifier of the first STA and a service affirmation response item corresponding to the at least one service claim item.
  • the service claim response item includes a service identifier and a service name;
  • the STA may cancel the information table by using the service maintenance frame.
  • the service maintenance frame includes maintenance status and maintenance details.
  • the maintenance status includes a first maintenance status and a second maintenance status, where the first maintenance status is used to update the registration service to other accessible neighboring APs when the STA affirmed service is added to the AP;
  • the STA needs to cancel the already announced service, cancel the service to the AP, and optionally
  • the AP updates the cancellation service to other accessible neighboring APs.
  • the maintenance status may be represented by a string, for example, Register indicates a first maintenance status, Cancel indicates a first maintenance status, and may also be represented by a number, for example, 1 indicates a first maintenance status, and 0 indicates a first maintenance status, and the present invention Not limited.
  • the first AP sends a first service maintenance frame to the second AP, where the first service maintenance frame includes maintenance status and maintenance details, so that the second AP updates the service information table of the second AP. ;
  • the maintenance status in the first service maintenance frame is a first maintenance status
  • the maintenance details include service information corresponding to each service declaration item in the at least one service declaration item.
  • the first AP sends a first service maintenance frame to the second AP, where the first service maintenance frame includes:
  • the service information corresponding to each service claim item in the at least one service claim item includes:
  • the second AP is a neighboring AP that is accessible by the first AP.
  • the second AP may be accessed by the first AP by using a wireless method, or may be that the first AP passes.
  • the wired mode can be accessed as long as the communication between the first AP and the second AP is possible, which is not limited by the present invention.
  • the second AP the service information table of the second AP after receiving the first service maintenance frame, specifically: the second AP according to the first maintenance state in the first service maintenance frame And storing service information in the first service maintenance frame in a service information table of the second AP.
  • the first AP may apply to the first STA by The service information of the explicit spreads to a wider range in the network, and the first STA is represented by the first STA to provide a service search function for a wider range of users.
  • all or part of the services that the first STA has declared on the first AP may be cancelled, and the method further includes:
  • the first AP detects that the first STA is detached.
  • the first AP receives a second service maintenance frame from the first STA, where the second service maintenance frame includes maintenance status and maintenance details.
  • the maintenance status in the second service maintenance frame is a second maintenance status, and the maintenance details include at least one service maintenance item;
  • the service maintenance item includes a BSSID, a device identifier, and a service identifier, and can identify a service that the STA has declared.
  • the first AP may cancel all services that the first STA has declared on the first AP; specifically, the first AP In the service information table, all service information declared by the first STA is deleted. Further, the first AP may send a service maintenance frame to the second AP, so that the second AP updates the service information table of the second AP.
  • the first AP is aware of the first STA detachment and can refer to the existing implementation manner, which is not limited by the present invention.
  • the first STA may also send a service maintenance frame whose maintenance status is the second maintenance state to the first AP to cancel all or part of the services that have been declared on the first AP.
  • the BSSID and the device identifier in the monthly maintenance item in the second service maintenance frame received by the first AP may be empty, and the first AP may acquire the BSSID first, that is, The MAC address and the device identifier of the first AP, that is, the device identifier of the first STA; the first AP may query the address correspondence table of the first AP according to the device address of the first STA, and obtain The device identifier of the first STA; and according to the obtained BSSID and device identifier, and the at least one service maintenance The service identifier of each service maintenance item in the item obtains all the services that the first STA needs to cancel, and then performs subsequent processing.
  • the service maintenance item in the second service maintenance frame received by the first AP from the first STA may be empty, indicating that the first STA wants to cancel all the services that have been claimed.
  • the first AP when the first AP receives the second service maintenance frame, if the service maintenance item includes a BSSID and a device identifier, the first AP first verifies whether the BSSID is The MAC address of the first AP, whether the device identifier corresponds to the device address of the first STA, and if they are consistent, perform subsequent processing; otherwise, it may be considered as a malicious attack and is not processed.
  • the first AP updates a service information table of the first AP.
  • the first AP When the first AP perceives the first STA, the first AP deletes all the service information declared by the first STA in the service information table of the first AP, and specifically includes:
  • the first AP acquires a BSSID, that is, a MAC address and a device identifier of the first AP, that is, a device identifier of the first STA; and the first AP may query the device according to the device address of the first STA. Updating an address of the first AP by using an address mapping table of the AP, and updating the service information table of the first AP according to the MAC address of the first AP and the device identifier of the first STA, where The first AP queries the service information table of the first AP according to the MAC address of the first AP and the device identifier of the first STA, and uses the BSSID in the service information table of the first AP. All service information that is the same as the MAC address of the first AP and whose device identifier is the same as the device identifier of the first STA is deleted.
  • the first AP may reclaim the device identifier allocated to the first STA into the device identification pool.
  • the first AP receives the second service maintenance frame from the first STA, the first AP updates the service information table of the first AP according to the second service maintenance frame, and specifically includes:
  • the first AP queries the service information table of the first AP according to the first service maintenance item in the second service maintenance frame;
  • the BSSID of the first service information in the service information table of the first AP is the same as the BSSID of the first service maintenance item in the second service maintenance frame
  • the service identifier of the first service information is the same as the service identifier of the first service maintenance item in the second service maintenance frame
  • the device identifier of the first service information and the first one in the second service maintenance frame When the device identifiers of the service maintenance items are the same, deleting the first service information in the service information table of the first AP;
  • the second service maintenance item If the second service maintenance item is still in the second service maintenance frame, querying the service information table of the first AP according to the second service maintenance item in the second service maintenance frame, when there is a matching second When the service information is used, the second service information is deleted in the service information table of the first AP, and so on.
  • the BSSID and the device identifier in the service maintenance item in the second service maintenance frame may be empty, and the first AP may acquire the BSSID, that is, the MAC address and the device of the first AP.
  • the identifier that is, the device identifier of the first STA; the first AP may query the address correspondence table of the first AP according to the device address of the first STA, and obtain the device identifier of the first STA; Ground,
  • the service information of the first AP is The first service information is deleted from the table;
  • the second service maintenance item If there is a second service maintenance item in the second service maintenance frame, according to the MAC address of the first AP and the device identifier of the first STA, and the second service in the second service maintenance frame.
  • the service identifier of the maintenance item queries the service information table of the first AP. When there is a matching second service information, the second service information is deleted in the service information table of the first AP, and so on.
  • the first AP may reclaim the device identifier allocated to the first STA into the device identifier pool; if the service identifier corresponding to the first STA is cancelled, No other STAs may provide, and the first AP may collect the service identifier into the service identity pool.
  • the first AP may send a second service maintenance frame to the second AP, where the BSSID, that is, the MAC address of the first AP, and the first a device identifier of the STA, so that the second AP updates the service information table of the second AP;
  • the first AP uses the acquired BSSID, that is, the Updating the second service maintenance frame by the MAC address of the AP and the device identifier of the first STA, and forwarding the updated second service maintenance frame to the second AP.
  • the action performed by the first AP may be referred to in the action of the first AP in 908, and details are not described herein again.
  • the The first AP performs the foregoing 906 and 909 to update the service information table of the neighboring APs that are accessible; if the first AP does not have an accessible neighboring AP, it is not necessary to perform the above-described 906 and 909.
  • the service maintenance frame may be as shown in FIG. 29; wherein the length is variable, and is used to indicate the length of the behavior details in the service maintenance frame.
  • the first AP may further maintain service information that is extended by other accessible neighboring APs. As shown in FIG. 9a, the method may further include:
  • the first AP receives a third service maintenance frame from a second AP, where the third service maintenance frame includes maintenance status and maintenance details.
  • the maintenance status in the third service maintenance frame may be a first maintenance status, and correspondingly, the maintenance details include at least one piece of service information;
  • the maintenance status in the third service maintenance frame may also be a second maintenance status.
  • the maintenance details include at least one service maintenance item.
  • the service maintenance item includes a BSSID, a device identifier, and a service identifier.
  • the first AP updates the service information table of the first AP according to the third service maintenance frame.
  • the first AP When the maintenance status in the third service maintenance frame is the first maintenance status, the first AP records the at least the third service maintenance frame included in the service information table of the first AP. a service message;
  • the first AP queries the service information table of the first AP according to the first service maintenance item in the third service maintenance frame.
  • the BSSID of the first service information in the service information table of the first AP is the same as the BSSID of the first service maintenance item in the third service maintenance frame
  • the service identifier of the first service information is the same as the service identifier of the first service maintenance item in the third service maintenance frame
  • the device identifier of the first service information and the third service maintenance frame Service maintenance item If the device identifiers are the same, the first service information is deleted in the service information table of the first AP; if there is a second service declaration item in the third service maintenance frame, the third service is maintained according to the third service
  • the second service maintenance item in the frame queries the service information table of the first AP, and when there is a matching second service information, deletes the second service information in the service information table of the first AP, This type of
  • 910 and 911 can be executed before or after any of steps 901 to 909.
  • the first STA associated with the first AP may affirm or cancel the service information on the first AP, and the first STA does not need to periodically listen for the lookup request of other devices on the channel, which is reduced.
  • Resource consumption and energy consumption of the first STA; the first AP may also diffuse device information and service information declared on the first AP to neighboring APs that are accessible in the network, and may also receive neighboring APs that are accessible.
  • the service information provided can provide a wider range of service discovery functions, provide users with richer service information, and meet the needs of users to select networks according to service requirements.
  • FIG. 10 is a flowchart of still another method for service registration according to an embodiment of the present invention.
  • the method for registering a service is implemented by a first station STA. As shown in FIG. 10, the method includes:
  • the first station STA sends a service advertisement request frame to the first access point AP, where the service advertisement request frame includes a device address of the first STA and at least one service declaration item, where the service declaration item includes a service name. ;
  • the first STA After the first STA is associated with the first AP, it may send a service advertisement request frame to the first AP, and register a service with the first AP.
  • the device address of the first STA is usually the MAC address of the first STA, and the device address of the first STA is usually carried in the header of the service advertisement request frame.
  • the service advertisement request frame may further include a device name of the first STA, and Backup identification, equipment capabilities, equipment description, etc.
  • the device name of the first STA may be, for example, a printer, a television, or the like, or may be, for example, a cafe No. 1, a ticket center No. 2, etc.; the device capability of the first STA may be, for example, supporting Wi-Fi direct connection. Supporting Bluetooth, etc., can further carry capability parameters in the device capability, for example, when supporting Wi-Fi direct connection, carrying a direct connection distance.
  • the device name of the first STA may be, for example, a printer, a television, or the like, or may be, for example, a cafe No. 1, a ticket center No. 2, etc.
  • the device capability of the first STA may be, for example, supporting Wi-Fi direct connection.
  • Supporting Bluetooth, etc. can further carry capability parameters in the device capability, for example, when supporting Wi-Fi direct connection, carrying a direct connection distance.
  • the printer supports Wi-Fi direct connection, and the direct connection distance is L;
  • Ticketing Center No. 2 can provide on-site service; the service declaration item can include a service description in addition to the service name.
  • the above ticketing center No. 2 can provide the following services:
  • the first STA may register multiple services to the first AP at a time, and the service advertisement request frame includes multiple service declaration items;
  • the STA may also register the service to the first AP in multiple times, that is, each time a service is registered with the first AP, and the registration is performed multiple times, each time the service advertisement request frame includes only one month of service declaration. item.
  • the first STA may be in the subsequent registration service with the first AP.
  • the device advertisement request frame carries the device identifier of the first STA.
  • the service advertisement request frame may be as shown in FIG. 27; wherein the length (variable) is variable, and is used to indicate the length of the behavior details in the service advertisement request frame.
  • the response frame includes a device identifier of the first STA and a service claim response entry corresponding to each service claim in the at least one service statement item; the service claim response item includes a service identifier and a service name.
  • the service claim response item corresponding to each service claim item in the at least one service claim item includes:
  • the first affirmation response item includes a service name of the first service declaration item and a first service identifier
  • the second claim response item includes a service name of the second service claim item and a second service identifier; analogy.
  • the service advertisement response frame may further include a device name of the first STA.
  • the service advertisement response frame may be as shown in FIG. 28; wherein the length (variable) is variable, and is used to indicate the length of the behavior details in the service advertisement response frame.
  • the first STA after receiving the service advertisement response frame, the first STA records the device identifier of the first STA and each service request response item according to the service advertisement response frame.
  • the first STA may maintain a service claim information table, where the service declaration information table includes a BSSID, a device identifier, a service name, and a service identifier.
  • the first STA when the first STA wants to cancel the claimed service, the first STA may send a service maintenance frame to the first AP, and cancel all or part of the claimed service.
  • the method further includes:
  • the first STA sends a second service maintenance frame to the first AP, where the second service maintenance frame includes maintenance status and maintenance details.
  • the first STA sends a second service maintenance frame to the first AP, and the maintenance status in the second service maintenance frame is a second maintenance state, where the maintenance details include Having one service maintenance item, so that the first AP updates the service information table of the first AP according to the second service maintenance frame, and optionally forwards the second service maintenance frame to the second AP;
  • the maintenance item includes a BSSID, a device identifier, and a service identifier.
  • the first STA deletes the service declaration information corresponding to each service maintenance item in the at least one service maintenance item in the service declaration information table.
  • the BSSID and the device identifier in the maintenance item may be empty.
  • the service maintenance item in the second service maintenance frame may be empty, indicating that the first STA wants to cancel all the services that have been claimed.
  • FIG. 11 is a schematic structural diagram of a first access point AP for service registration according to an embodiment of the present invention, for implementing the method for service registration shown in FIG. 8 and FIG.
  • the first AP includes a receiving unit 1101, a first acquiring unit 1102, a second obtaining unit 1103, a recording unit 1104, and a sending unit 1105. among them,
  • the receiving unit 1101 is configured to receive a service advertisement request frame from the first station STA, where the service advertisement request frame includes a device address of the first STA and at least one monthly service declaration item, where the service declaration item is Includes the service name.
  • the device address of the first STA is usually a media access control MAC address of the first STA, and the device address of the first STA is usually carried in a header of the service advertisement request frame.
  • the service advertisement request frame may further include a device name, a device capability, a device description, and the like of the first STA.
  • the device name of the first STA may be, for example, a printer, a television, or the like, or may be, for example, a cafe No. 1, a ticket center No. 2, etc.; the device capability of the first STA may be, for example, supporting Wi-Fi direct connection. Supporting Bluetooth, etc., can further carry capability parameters in the device capability, for example, when supporting Wi-Fi direct connection, carrying a direct connection distance.
  • Wi-Fi direct connection carrying a direct connection distance.
  • the printer supports Wi-Fi direct connection, and the direct connection distance is L;
  • Ticketing Center No. 2 can be on-site service
  • the service declaration item may include a service description in addition to the service name.
  • the above ticketing center No. 2 can provide the following services:
  • the service advertisement request frame may be as shown in FIG. 27; wherein the length (variable) is variable, and is used to indicate the length of the behavior details in the service advertisement request frame.
  • the first obtaining unit 1102 is configured to acquire a device identifier of the first STA.
  • the first obtaining unit 1102 is specifically configured to:
  • the address correspondence table includes a correspondence between a device address and a device identifier, and the address correspondence relationship table of the first AP If the device address of the existing address is the same as the device address of the first STA, the device identifier of the existing address is obtained, which is the device identifier of the first STA;
  • the device identifier of the first STA is allocated from the device identifier pool, and the device address of the first STA is recorded in the address correspondence table. The address corresponding to the device ID.
  • the device ID of the ticketing center No. 2 of the MAC address of the MAC1 is DI-1
  • the device ID of the printer 1 of the device address of M AC2 is DI-2.
  • the service advertisement request frame further includes a device identifier of the first STA, where the first acquiring unit is further configured to: obtain a device identifier of the first STA from the service advertisement request frame. .
  • the second obtaining unit 1103 is configured to obtain, according to the at least one service claim item, a service identifier corresponding to each service claim item in the at least one service claim item.
  • the second obtaining unit 1103 is specifically configured to:
  • the service name of the first service declaration item is from the service identification pool. Assigning a first service identifier
  • the service name of the first AP exists in the service information table of the first AP
  • the service name of the existing service information is the same as the service name of the first service announcement
  • the BSSID of the existing service information is the same as the MAC address of the first AP.
  • the service identifier of the existing service information is obtained, that is, the first service identifier corresponding to the service name of the first service declaration item.
  • the second service identifier corresponding to the service name of the second service declaration item is obtained, and so on.
  • the service announcement request frame includes two service declaration items, and the service name of the first service declaration item is "air ticket pre-sale", and the service of the second service declaration item The name is "train ticket pre-sale", then the first AP obtains the service identifier SI-1 according to "air ticket pre-sale”, and then obtains the service identifier SI-2 according to "train ticket pre-sale".
  • the recording unit 1104 is configured to record, in the service information table of the first AP, service information corresponding to the at least one service claim item; the service information includes a basic service set identifier BSSID, a device identifier, and a monthly service identifier. And the month of good service declaration.
  • the recording unit 1104 is specifically configured to:
  • the first service information includes a MAC address of the AP, a device identifier of the first STA, the first service identifier, and the first service claim;
  • the service information may further include a device name of the first STA, a device capability of the first STA, and a network access policy.
  • the network access policy can indicate the access policy in the BSS where the AP is located, or the access policy for a specific month.
  • the API is on the public network
  • AP2 is on the private network
  • the API can access the AP2 according to the AP2 access policy. Private network.
  • the service information may be as shown in FIG. 23; where, the BSSID is the MAC address of the AP associated with the STA that declares the service information; for example, in this implementation, it is the MAC address of the first AP.
  • the sending unit 1105 is configured to return a service advertisement response frame to the first STA, where the service advertisement response frame includes a device identifier of the first STA and a service declaration response corresponding to the at least one service claim Item; the service claim response item includes a service identifier and a service name.
  • the service declaration corresponding to each service claim in the at least one service declaration item shall be Answers, including:
  • the first affirmation response item includes a service name of the first service declaration item and the first service identifier
  • the second claim response item includes a service name of the second service claim item and the second service identifier; And so on.
  • the service advertisement response frame may further include a device name of the first STA.
  • the service advertisement response frame may be as shown in FIG. 28; wherein the length (variable) is variable, and is used to indicate the length of the behavior details in the service advertisement response frame.
  • the first AP further includes a maintenance unit 1106.
  • the maintenance unit 1106 is configured to generate a first service maintenance frame, where the first service maintenance frame includes service information corresponding to each service statement in the first maintenance state and the at least one service declaration item;
  • the sending unit 1105 is further configured to send the first service maintenance frame to the second AP, so that the second AP updates the service information table of the second AP;
  • the service information includes a BSSID, a device identifier, a service identifier, and a service claim.
  • the second AP is a neighboring AP that is accessible by the first AP.
  • the service information corresponding to each service claim item in the at least one service claim item includes:
  • the receiving unit 1101 is further configured to receive a second service maintenance frame from the first STA, where the second service maintenance frame includes a second maintenance state and at least one service maintenance
  • the maintenance item includes a BSSID, a device identifier, and a service identifier.
  • the maintenance unit 1106 is further configured to update the service information table of the first AP according to the second service maintenance frame.
  • the maintenance unit 1106 is further configured to forward the second service maintenance frame to the second AP, so that the second AP updates the second AP service information table.
  • the maintenance unit 1106 is specifically configured to: query, according to the first service maintenance item in the at least one service maintenance item, a service information table of the first AP; when there is a matching first service information, that is, the first The BSSID of the first service information in the service information table of the AP is the same as the BSSID of the first service maintenance item, and the service identifier of the first service information is the same as the service identifier of the first service maintenance item, and When the device identifier of the first service information is the same as the device identifier of the first service maintenance item, the first service information is deleted in the service information table of the first AP.
  • the BSSID and the device identifier in the service maintenance item in the second service maintenance frame may be empty, and the maintenance unit 1106 is further configured to acquire a BSSID, that is, a MAC address and a device of the first AP.
  • An identifier that is, a device identifier of the first STA; and a service identifier of the first service maintenance item in the second service maintenance frame according to the MAC address of the first AP and the device identifier of the first STA Querying the service information table of the first AP; when there is a matching first service information, that is, the BSSID of the first service information is the same as the MAC address of the first AP, and the first service information is The service identifier is the same as the service identifier of the first service maintenance item in the second service maintenance frame, and the device identifier of the first service information is the same as the device identifier of the first STA Deleting the first service information in the service information table of the first AP; if there is a second service maintenance item in the second service maintenance frame, according to the MAC address and location of the first AP The device identifier of the first STA and the service identifier of the second service maintenance item in the second service maintenance frame query the service information table of the first AP,
  • the maintenance unit 1106 is further configured to cancel all services that the first STA has declared on the first AP when the first STA is detached. Specifically, the maintenance unit 1106 is configured to acquire a BSSID, that is, a MAC address and a device identifier of the first AP, that is, a device identifier of the first STA, and according to the MAC address of the first AP, and the first Querying the device information of the first AP, querying the service information table of the first AP, and in the service information table of the first AP, the BSSID is the same as the MAC address of the first AP, and the device identifier is related to the first STA. All device information with the same device ID is deleted.
  • the maintenance unit 1106 can obtain the device identifier of the first STA by using the first acquiring unit 402.
  • the receiving unit 1101 is further configured to receive a third service maintenance frame from the second AP, where the third service maintenance frame includes maintenance status and maintenance details.
  • the maintenance unit 1106 is further configured to update the service information table of the first AP according to the third service maintenance frame.
  • the maintenance status in the third service maintenance frame may be a first maintenance status, and correspondingly, the maintenance details include at least one piece of service information;
  • the maintenance status in the third service maintenance frame may also be a second maintenance status.
  • the maintenance details include at least one service maintenance item.
  • the maintenance unit 1106 is specifically configured to be used
  • the AP records the at least one piece of service information included in the third service maintenance frame in a service information table of the first AP;
  • the first AP queries the service information table of the first AP according to the first service maintenance item in the third service maintenance frame.
  • the BSSID of the first service information in the service information table of the first AP is the same as the BSSID of the first service maintenance item in the third service maintenance frame
  • the service identifier of the first service information is the same as the service identifier of the first service maintenance item in the third service maintenance frame
  • the device identifier of the first service information and the third service maintenance frame If the device identifier of a service maintenance item is the same, deleting the first service information in the service information table of the first AP; if there is a second service declaration item in the third service maintenance frame, according to the The second service maintenance item in the third service maintenance frame queries the service information table of the first AP, and when there is a matching second service information, deletes the second information in the service information table of the first AP.
  • Traffic information and so on
  • the service maintenance frame may be as shown in FIG. 29; wherein the length is variable, and is used to indicate the length of the behavior details in the service maintenance frame.
  • the first AP further includes an identifier recovery unit, configured to collect the device identifier and the monthly service identifier.
  • the identifier recovery unit is specifically configured to: when the first STA cancels all the services that have been declared, reclaim the device identifier allocated to the first STA into the device identifier pool; The service, when no other STA provides, reclaims the monthly good service ID into the service identification pool.
  • FIG. 12 is a first site STA for service registration according to an embodiment of the present invention. Schematic diagram of a structure for implementing the service registration method shown in FIG. 10 of the present invention. As shown in FIG. 12, the first STA includes a transmitting unit 1201, a receiving unit 1202, and a recording unit 1203. among them,
  • the sending unit 1201 is configured to send a service advertisement request frame to the first AP, where the service advertisement request frame includes a device address of the first STA and at least one service declaration item, where the service declaration item includes a service name;
  • the first STA After the first STA is associated with the first AP, it may send a service advertisement request frame to the first AP, and register a service with the first AP.
  • the device address of the first STA is usually a media access control MAC address of the first STA, and the device address of the first STA is usually carried in a header of the service advertisement request frame.
  • the service advertisement request frame may further include a device name, a device capability, a device description, and the like of the first STA.
  • the device name of the first STA may be, for example, a printer, a television, or the like, or may be, for example, a cafe No. 1, a ticket center No. 2, etc.; the device capability of the first STA may be, for example, supporting Wi-Fi direct connection. Supporting Bluetooth, etc., can further carry capability parameters in the device capability, for example, when supporting Wi-Fi direct connection, carrying a direct connection distance.
  • the device name of the first STA may be, for example, a printer, a television, or the like, or may be, for example, a cafe No. 1, a ticket center No. 2, etc.
  • the device capability of the first STA may be, for example, supporting Wi-Fi direct connection.
  • Supporting Bluetooth, etc. can further carry capability parameters in the device capability, for example, when supporting Wi-Fi direct connection, carrying a direct connection distance.
  • the printer supports Wi-Fi direct connection, and the direct connection distance is L;
  • Ticketing Center No. 2 can be on-site service
  • the service declaration item may include a service description in addition to the service name.
  • the above ticketing center No. 2 can provide the following services:
  • the first STA may register multiple services to the first AP at a time, and the service advertisement request frame includes multiple service declaration items;
  • the STA may also register the service to the first AP in multiple times, that is, each time a service is registered with the first AP, and the registration is performed multiple times, each time the service advertisement request frame includes only one month of service declaration. item.
  • the service advertisement request frame may be as shown in FIG. 27; wherein the length (variable) is variable, and is used to indicate the length of the behavior details in the service advertisement request frame.
  • the receiving unit 1202 is configured to receive a service advertisement response frame from the first AP, where the service advertisement response frame includes a device identifier of the first STA and each service claim in the at least one service claim item.
  • the service corresponding to the item is a response item; the service claim response item includes a service identifier and a service name;
  • the service claim responses corresponding to each service claim in the at least one service claim include:
  • the first affirmation response item includes a service name of the first service declaration item and a first service identifier
  • the second claim response item includes a service name of the second service claim item and a second service identifier; analogy.
  • the service advertisement response frame may further include a device name of the first STA.
  • the service advertisement response frame may be as shown in FIG. 28; wherein the length (variable) is variable, and is used to indicate the length of the behavior details in the service advertisement response frame.
  • the recording unit 1203 is configured to record, according to the service advertisement response frame, a device identifier of the first STA, and each service claim response item.
  • the first STA may maintain a service claim information table, where the service declaration information table includes a BSSID, a device identifier, a service name, and a service identifier.
  • the recording unit 1203 is specifically configured to record, in the service claim information table, a BSSID, that is, a MAC address of the first AP, a device identifier of the first STA, a service name of the first affirmative response item, and a first service identifier; if there is a second service claim, the BSSID is recorded, that is, the MAC address of the first AP, the device identifier of the first STA, the service name of the second affirmative response item, and the second Service identifier; and so on.
  • a BSSID that is, a MAC address of the first AP, a device identifier of the first STA, a service name of the first affirmative response item, and a first service identifier
  • the first STA further includes an information maintenance unit 1204;
  • the sending unit 1201 is further configured to send a second service maintenance frame to the first AP, where the second service maintenance frame includes maintenance status and maintenance details.
  • the sending unit 1201 is configured to send a second service maintenance frame to the first AP, where the maintenance state in the second service maintenance frame is a second maintenance state, where the maintenance details include at least one service maintenance.
  • the first AP is configured to update the service information table of the first AP according to the second service maintenance frame, and optionally forward the second service maintenance frame to the second AP; Items include BSSID, device ID, and service ID.
  • the BSSID and device identifier in the monthly maintenance item may be empty.
  • the information maintenance unit 1204 is configured to delete the service declaration information to be canceled in the service declaration information table; specifically, to delete each service maintenance item in the at least one service maintenance item in the second service maintenance frame The service declaration information corresponding to the item.
  • the information maintenance unit 1204 is further configured to: when the first STA is disconnected from the first AP, delete all service claim information in the service declaration information table.
  • the first STA further includes an antenna, configured to send and receive no a line signal; the antenna is connected to the receiving unit 1201 and the transmitting unit 1202.
  • FIG. 13 is a schematic structural diagram of a service registration system according to an embodiment of the present invention, where the system includes a first access point AP as shown in FIG. 11 of the present invention and a first station STA as shown in FIG. 12 of the present invention;
  • the system may further include a second AP.
  • the first AP is as shown in FIG. 11a of the present invention
  • the first STA is as shown in FIG. 12a.
  • the second AP may be reachable by the first AP in a wireless manner, or may be that the first AP is reachable by using a wire, as long as the first AP and the second AP can communicate with each other.
  • the present invention does not limit this.
  • the first AP may have multiple accessible neighboring APs, that is, as shown in FIG. 13a, there are multiple second APs, and two second APs are schematically illustrated in FIG. 13a.
  • FIG. 14 is a schematic diagram of information exchange of service registration according to an embodiment of the present invention.
  • the method for service registration provided by the embodiment of the present invention is further introduced based on the system shown in FIG. 13a.
  • the method for registering the monthly service includes:
  • the first station STA sends a service advertisement request frame to the first access point AP, where the service advertisement request frame includes the device address of the first STA and at least one service description item;
  • the first AP After receiving the service advertisement request frame, the first AP acquires the device identifier and the service identifier, and records the corresponding service information in the service information table of the first AP. Specifically, the first AP Acquiring, according to the device address of the first STA, the device identifier of the first STA; acquiring, according to the at least one service claim, a service identifier corresponding to each service claim in the at least one service claim; Recording service information corresponding to the at least one service claim item in the service information table of the first AP, where the service information includes a basic service set identifier BSSID, a device identifier, a service identifier, and a service request Bright item.
  • BSSID basic service set identifier
  • the first AP returns a service advertisement response frame to the first STA, where the service advertisement response frame includes a device identifier of the first STA and a service affirmation response item corresponding to the at least one service claim item.
  • the service claim response item includes a service identifier and a service name
  • the first AP sends a first service maintenance frame to the second AP, where the first service maintenance frame includes a maintenance status and maintenance details, and the maintenance status in the first service maintenance frame is a first maintenance status.
  • the maintenance details include service information corresponding to each service declaration item in the at least one service declaration item, so that the second AP updates the service information table of the second AP.
  • the second AP After receiving the first service maintenance frame, the second AP updates the service information table of the second AP according to the first service maintenance frame.
  • the second AP records the service information included in the first service maintenance frame in the service information table of the second AP according to the maintenance status of the first service maintenance frame.
  • the first STA When the first STA is to cancel the claimed service, the first STA sends a second service maintenance frame to the first AP.
  • the second service maintenance frame includes a second maintenance state and at least one service maintenance item.
  • the service maintenance item includes a BSSID, a device identifier, and a service identifier, and can identify a service that the first STA has declared.
  • the first AP After receiving the second service maintenance frame, the first AP updates a service information table of the first AP.
  • the first AP updates the service information table of the first AP according to the service maintenance item in the second service maintenance frame.
  • the first AP forwards the second service maintenance frame to the second AP.
  • the second service maintenance frame For details, refer to 909 in the embodiment of the disclosure, and details are not described herein.
  • the second AP After receiving the second service maintenance frame, the second AP updates a service information table of the second AP.
  • the process of the second AP updating the service information table of the second AP is the same as the process of the first AP updating the service information table of the first AP.
  • the process of the first AP updating the service information table of the first AP is the same as the process of the first AP updating the service information table of the first AP.
  • the process of the first AP updating the service information table of the first AP is the same as the process of the first AP updating the service information table of the first AP.
  • the first STA associated with the first AP may abbreviate or cancel the service information on the first AP, and the first STA does not need to periodically listen for the lookup request of other devices on the channel
  • the resource consumption and power consumption of the first STA may be: the first AP may also diffuse the device information and the service information declared on the first AP to neighboring APs that are accessible in the network, and may also receive the accessible neighbors.
  • the service information provided by the AP can provide a wider range of service discovery functions, provide users with richer service information, and meet the needs of users to select networks according to service requirements.
  • the service information maintained on the AP is authenticated and associated with the STA on the AP, ensuring security and ensuring service reliability.
  • the present invention can also discover the STA that provides the direct connection service through the AP proxy, and manage the direct connection communication between the STAs.
  • the device capability is “supporting WiFi direct connection” as an example, but the direct connection service through other technologies, such as Bluetooth, is also applicable. The invention is not limited thereto.
  • the STA may request the AP to obtain the direct connection service or close the direct connection service through the direct connection service request frame including the service request status.
  • the service request status includes a first request status and a second request status.
  • the first request status may be referred to as enable
  • the second request status may be referred to as disable.
  • the service request status in the direct connection service request frame is the first request status, it indicates that the STA request acquires the direct connection service; when the service request status is the second request status, it indicates that the STA requests to close the direct connection service.
  • the service request status may be identified by a string, for example, enable indicates the first request status, disable indicates the second request status, and may also be identified by a number, such as 1 for the first request status and 0 for the second request status; This is not limited.
  • FIG. 15 is a flowchart of a method for managing a direct connection service according to an embodiment of the present invention.
  • the method for managing a direct connection service is implemented by a first access point AP. As shown in FIG. 15, the method includes:
  • the first access point AP receives the direct connection service request frame sent by the first station STA, where the direct connection service request frame includes a service request status and a service name.
  • the first AP When the service request status is the first request status, the first AP performs 1502 - 1507; when the service request status is the second request status, the first AP performs 1508 ⁇ 1509.
  • the device name may also be included in the direct connection service request frame.
  • the direct connection service request frame may be as shown in FIG. 30; wherein the length (variable) is variable, and is used to indicate the length of the behavior details in the direct connection service request frame.
  • the first STA may request the direct connection service to the first AP according to the service directory information.
  • the service name in the direct connection service request frame may also be a service identifier, for example, when When the service identifier is uniformly allocated globally, the direct connection service can be obtained according to the service identifier request.
  • the service name is taken as an example, but the invention is not limited thereto.
  • the first AP acquires a device address of the second STA.
  • the first AP queries the service information table of the AP according to the service name in the direct connection service request frame;
  • the direct connection request fails, and ends;
  • the service name of the existing service information in the service information table of the first AP is the same as the service name in the direct connection service request frame, and the device capability in the existing service information is supported by Wi-Fi.
  • the device identifier in the existing service information is obtained, that is, the device identifier of the second STA; otherwise, the direct connection request fails, and ends;
  • the device identifier in the direct connection service request frame may be obtained, that is, the device identifier of the second STA, according to the second STA.
  • the device identifier is obtained, and the device address of the second STA is obtained.
  • the direct connection service Since the direct connection service has a requirement for the distance between the devices, it is only provided by the STA associated with the first AP.
  • the STA When the first AP queries the service information table of the AP, the BSSID needs to be the same as the MAC address of the first AP.
  • the method includes: the first AP querying, according to the device identifier of the second STA, an address corresponding to the address of the first AP
  • the relationship table obtains the device address of the second STA.
  • the address correspondence table includes a correspondence between the device address and the device identifier.
  • the first AP detects the distance between the first STA and the second STA according to the device address of the second STA.
  • the direct connection request fails, and ends;
  • the first AP queries the direct connection service management table of the first AP, when the distance between the first STA and the second STA is not greater than the direct connection distance.
  • the direct connection distance may be a preset distance on the first AP, or may be carried in the device capability stated by the second STA, which is not limited by the disclosure.
  • the direct connection service management table includes a service name and a group address, and may further include channel information, a group identifier, a service identifier, and a device name.
  • the direct connection service management table may be as shown in FIG.
  • the group address is usually the device address of the STA that provides the direct connection service.
  • the service name of the existing direct connection service management information in the direct connection service management table of the first AP is the same as the service name in the direct connection service request frame, and the existing direct connection service management is performed.
  • the group address of the information is the same as the device address of the second STA, the first AP sends a direct connection service response frame to the first STA; the address may further include a group identifier and channel information.
  • the first AP records the first direct connection service management information in the direct connection service management table of the first AP, where the first direct connection service management information includes the direct connection service request frame. a service name and a device address of the second STA; and sending a direct connection service response frame to the first STA;
  • the direct connection service response frame includes a device address of the second STA.
  • the first AP sends the direct connection service response frame to the first STA, where it is recommended that the first STA establish a direct connection service with the second STA; Establishing a direct connection service with the second STA may be determined by the first STA, or the first STA negotiates with the second STA to determine.
  • the first AP may further allocate a radio channel for direct communication to the first STA, where the first direct connection service management information may further include first channel information, where the first channel information includes the first An AP is configured to allocate, by the first STA, information about a radio channel for direct communication, where the first direct service response frame further includes the first channel, and the first AP may also be the straight And the service request is configured to allocate the first group of identifiers, where the first group of identifiers corresponds to the device address of the second STA; correspondingly, the first direct monthly service management information may further include the first group of identifiers, The direct connection response frame further includes the first group identifier.
  • a group identifier may correspond to a device address of multiple STAs that provide the same service.
  • the direct connection response frame may be as shown in FIG. 32; wherein the length (variable) is variable, which is used to indicate the length of the behavior details in the direct connection service response frame.
  • the channel information of the directly connected service is allocated by the first AP, so that the direct communication between the STAs and the signals of the channel where the first AP is located can be prevented from interfering with each other, and the communication quality is ensured;
  • the first AP may also not allocate a channel, and the direct communication between STAs may be performed on a specific channel, for example, 2.4G channel 1, 6 or 11 currently used by WiFi direct connection technology; or may be negotiated to select channel establishment between STAs.
  • the direct connection service is not limited by the present invention.
  • the first STA may obtain a group address and channel information from the direct connection service response frame, and establish a direct connection with the second STA on the corresponding channel. , and then data interaction.
  • the direct connection service may be distinguished in multiple ways.
  • the response frame indicates whether the request succeeded or failed.
  • the status identifier may be further included in the direct connection service response frame, for example, the status identifier is 0 for failure, and the status identifier is 1 for success; or may be represented by a group identifier in the direct connection service response frame, for example, a group identifier. If it is -1, it indicates a failure; in the direct connection service response frame, the length of 0 indicates that the failure, that is, the group identifier, the group address, and the channel information are all empty;
  • the first AP performs the following 1508 ⁇ 1509:
  • the first AP queries the direct connection service management table of the first AP according to the direct connection service request frame.
  • the direct connection service management table includes a service name and a group address, and may further include channel information, a group identifier, and a device identifier.
  • the group address is usually the device address of the STA that provides the direct connection service.
  • the service name of the existing direct connection service management information in the direct connection service management table of the first AP is the same as the service name in the second direct connection service request frame, and the existing direct connection is When the group address of the service management information is the same as the device address of the first STA, the existing direct connection service management information is deleted from the direct connection service management table of the first AP;
  • the first AP may collect the group identifier in the existing direct connection service management information into the group identifier pool, and recover the channel resource corresponding to the channel information in the existing direct connection management information.
  • the first AP may return a response message to the first STA, for example, ACK (affirmative)
  • Acknowledgement acknowledgement
  • NACK negative acknowledgment, negative answer
  • FIG. 16 is a flowchart of a method for obtaining a direct connection service according to an embodiment of the present invention.
  • the method for obtaining a direct connection service is implemented by a first station STA. As shown in FIG. 16, the method includes:
  • the first station STA sends a direct connection service request frame to the first AP of the access point, where the direct connection service request frame includes a service request status and a service name.
  • the service name in the direct connection service request frame may also be a service identifier.
  • the service identifier is globally unique, the direct connection service may be obtained according to the service identifier request.
  • the service name is taken as an example, but the invention is not limited thereto.
  • the first STA When the service request status in the direct connection service request frame is the first request status, the first STA requests the first AP to acquire the direct connection service.
  • the first STA may request a direct connection service to the first AP according to the service identifier after scanning to obtain the available AP and its service directory information.
  • the first STA when the first STA acquires the service information by using the service discovery method as shown in FIG. 5 in the present invention, it is desirable to establish a direct connection service with a device that supports Wi-Fi direct connection.
  • the first STA may further carry the device name or device identifier of the device in the direct connection service request frame, and request the first AP to establish a direct connection service with the device.
  • the device name is taken as an example, but is not intended to limit the present invention.
  • the first STA When the service request status in the direct connection service request frame is the second request status, the first STA requests the first AP to close a direct connection service provided by the first STA, The first AP deletes the related direct-connection service management information, and reclaims the group identity and the channel resource.
  • the first AP deletes the related direct-connection service management information, and reclaims the group identity and the channel resource.
  • the STA that supports the WiFi direct connection function is not in the working state, by turning off the WiFi direct connection service, the resource consumption of the device can be reduced, and the channelable resources can be released.
  • the service request status is the second request status, the first STA receives a response message returned by the first AP, for example, ACK (affirmative acknowledgement, surely A) Message or NACK (negative acknowledgment) message.
  • the direct connection service request frame may be as shown in FIG. 30; wherein the length (variable) is variable, and is used to indicate the length of the behavior details in the direct connection service request frame.
  • the first STA receives the direct connection service response frame returned by the first AP, and the direct connection service response frame includes a group address, and may further include a group identifier and a channel identifier.
  • the device address of the STA that is connected to the service includes a group address, and may further include a group identifier and a channel identifier.
  • the direct connection response frame may be as shown in FIG. 32; wherein the length (variable) is variable, which is used to indicate the length of the behavior details in the direct connection service response frame.
  • the first STA When determining that the direct connection request is successful according to the direct connection service response frame, the first STA establishes a direct connection with the second STA corresponding to the group address in the direct connection service response frame.
  • the first STA establishes a direct connection with the second STA corresponding to the group address in the direct connection service response frame, where the A STA establishes a direct connection service with the second STA on the radio channel corresponding to the channel information.
  • the channel information of the directly connected service is allocated by the first AP, so that the direct communication between the STAs and the signals of the channel where the first AP is located can be prevented from interfering with each other, and the communication quality is ensured;
  • the first AP may also not allocate a channel, and the direct communication between STAs may be performed on a specific channel, for example, 2.4G channel 1, 6 or 11 currently used by WiFi direct connection technology; or may be negotiated to select channel establishment between STAs.
  • the direct connection service is not limited by the present invention.
  • the status identifier may be further included in the direct connection service response frame, for example, the status identifier is 0 for failure, and the status identifier is 1 for success; or may be represented by a group identifier in the direct connection service response frame, for example, a group identifier.
  • FIG. 17 is a schematic structural diagram of a first station STA for acquiring a direct connection service according to an embodiment of the present invention.
  • the first STA includes a sending unit 1701, a receiving unit 1702, and a service establishing unit 1703. among them,
  • the sending unit 1701 is configured to send a direct connection service request frame to the first access point AP, where the direct connection service request frame includes a service request status and a service name.
  • the service name in the direct connection service request frame may also be a service identifier.
  • the service identifier is globally unique, the direct connection service may be obtained according to the service identifier request.
  • the service name is taken as an example, but the invention is not limited thereto.
  • the direct connection service request frame may be as shown in FIG. 30; wherein the length (variable) is variable, and is used to indicate the length of the behavior details in the direct connection service request frame.
  • the first STA may request the direct connection service from the first AP according to the service identifier after the scan obtains the available AP and its service directory information.
  • the direct connection service request frame may further include a device name or a device identifier.
  • the first STA may be configured to establish a direct connection service with a device that supports Wi-Fi direct connection.
  • the device name or the device identifier of the device is further carried in the direct connection service request frame, and the first AP is requested to establish a direct connection service with the device.
  • the receiving unit 1702 is configured to receive a direct connection service response frame returned by the first AP, where the direct connection service response frame includes a group address, and may further include a group identifier and a channel identifier.
  • the group address is usually the device address of the STA that provides the direct connection service.
  • the channel information of the directly connected service is allocated by the first AP, so that the direct communication between the STAs and the signals of the channel where the first AP is located can be prevented from interfering with each other, and the communication quality is ensured;
  • the first AP may also not allocate a channel, and the direct communication between STAs may be performed on a specific channel, for example, 2.4G channel 1, 6 or 11 currently used by WiFi direct connection technology; or may be negotiated to select channel establishment between STAs.
  • the direct connection service is not limited by the present invention.
  • the direct connection response frame may be as shown in FIG. 32; wherein the length (variable) is variable, which is used to indicate the length of the behavior details in the direct connection service response frame.
  • the service establishing unit 1703 is configured to establish a direct connection service with the second STA corresponding to the group address in the direct connection service response frame, when determining that the direct connection request is successful according to the direct connection service response frame;
  • the service establishing unit 1703 is specifically configured to establish a direct connection service with the second STA on the wireless channel corresponding to the channel information.
  • the first STA further includes a determining unit, configured to determine, according to the direct connection service response frame, whether the direct connection service request is successful.
  • the status identifier may be further included in the direct connection response frame, for example, the status identifier is 0 for failure, and the status identifier is 1 for success; or may be represented by a group identifier in the direct connection response frame, for example If the group ID is -1, it indicates a failure; in the direct connection service response frame as shown in the figure, the length of 0 indicates that the failure, that is, the group identifier, the group address, and the channel information are all empty; limited.
  • the first AP requests to close a certain direct connection service provided by the first STA, so that the first AP deletes the related direct connection service management information, and reclaims the group identity and the channel resource.
  • the method of managing the direct connection service will not be described here.
  • the receiving unit 1702 is further configured to receive a response message returned by the AP, such as an ACK or a NACK.
  • FIG. 18 is a schematic structural diagram of a first access point AP for managing a direct connection service according to an embodiment of the present invention.
  • the first AP includes a receiving unit 1801, a first acquiring unit 1802, and a detecting unit 1803.
  • the receiving unit 1801 is configured to receive a direct connection service request frame of the first station STA, where the direct connection service request frame includes a service request status and a service name, and may further include a device name.
  • the service name and the device name in the direct connection service request frame may also be a service identifier and a device identifier.
  • the direct connection service may be obtained according to the service identifier and the device identifier request.
  • the service name and the device name are taken as an example, but the invention is not limited thereto.
  • the direct connection service request frame may be as shown in FIG. 30; wherein the length (variable) is variable, and is used to indicate the length of the behavior details in the direct connection service request frame.
  • the first obtaining unit 1802 is configured to acquire a device address of the second STA when the service request status is the first request status;
  • the first obtaining unit 1802 is specifically configured to: according to the direct connection service request frame Querying the service information table of the first AP; the service name of the existing service information in the service information table of the first AP is the same as the service name in the direct connection service request frame, and When the device capability in the existing service information is to support the Wi-Fi direct connection, the device identifier in the existing service information is obtained, that is, the device identifier of the second STA; according to the device identifier of the second STA, Obtaining a device address of the second STA;
  • the device identifier in the direct connection service request frame is obtained, that is, the device identifier of the second STA; according to the device identifier of the second STA, Obtaining a device address of the second STA. Since the direct connection service has a requirement for the distance between the devices, it is only provided by the STA associated with the first AP. When querying the service information table of the first AP, the first AP must simultaneously satisfy the same BSSID as the MAC address of the first AP.
  • the detecting unit 1803 is configured to detect a distance between the first STA and the second STA according to the device address of the second STA acquired by the first acquiring unit 1802; the query unit 1804,
  • the direct connection service management table is used to query the first AP.
  • the direct connection service management table may be as shown in FIG. 31.
  • the query unit 1804 is specifically configured to: when the service request status is the first request status, when the distance between the first STA and the second STA detected by the detecting unit 1803 is not greater than a direct connection distance Querying, according to the service name in the direct connection service request frame and the device address of the second STA, the direct connection service management table of the first AP;
  • the direct connection service management table includes a service name and a group address, and may also include a channel. Information, group identification, service identification and device name;
  • the group address is usually the device address of the STA that provides the direct connection service.
  • the direct connection distance may be a preset distance on the first AP, or may be carried in the device capability stated by the second STA, which is not limited by the disclosure.
  • the second obtaining unit 1805 is configured to obtain direct connection service management information for the direct connection service request of the first STA;
  • the service name of the existing direct connection service management information in the direct connection service management table of the first AP is the same as the service name in the direct connection service request frame, and the existing direct connection service management information is Obtaining the existing direct connection service management information when the group address is the same as the device address of the second STA;
  • the first direct connection service management information includes the direct connection service request a service name in the frame and a device address of the second STA;
  • the direct connection service management information may further include a first group identifier and first channel information.
  • the first channel information includes information that the first AP allocates to the first STA for a wireless channel for direct communication; the first group identifier corresponds to a device address of the second STA, and is The first AP allocates a group identifier to the directly connected service request of the first STA. It should be noted that one group identifier may correspond to a device address of multiple STAs that provide the same service.
  • the sending unit 1806 is configured to send a direct connection service response frame to the first STA according to the direct connection service management information acquired by the acquiring unit 1805;
  • the direct connection service response frame includes a group address, and may further include a group identifier and a channel letter. Since the wireless signals are easily interfered with each other and the wireless channel resources are limited, the channel information of the directly connected service is allocated by the first port, so that the direct communication between the STAs and the signals of the first channel are mutually interfered, and the communication quality is ensured; The first channel may also not allocate a channel, and the direct communication between STAs may be performed on a specific channel, such as 2.4G channel 1, 6 or 11 currently used by WiFi direct connection technology; or may be negotiated to select channel establishment between STAs.
  • the direct connection service is not limited by the present invention.
  • the direct connection response frame may be as shown in FIG. 32; wherein the length (variable) is variable, which is used to indicate the length of the behavior details in the direct connection service response frame.
  • the first AP further includes a direct connection management unit 1807.
  • the query unit 1804 is further configured to: when the service request status is the second request status, according to the Querying the service name in the direct connection service request frame and the device address of the first STA, and querying the direct connection service management table of the AP;
  • the direct connection management unit 1807 is configured to: when the service request status in the direct connection service request frame is the second request status, when there is an existing direct connection service in the direct connection service management table of the first AP.
  • the service name of the management information is the same as the service name in the direct connection service request frame, and the group address of the existing direct connection service management information is the same as the device address of the first STA, The service management information is deleted from the direct connection management table of the first AP.
  • the direct connection management unit 1807 is further configured to collect the group identifier in the existing direct connection service management information into a group identifier pool, and use a channel corresponding to the channel information in the existing direct connection service management information. Recycle.
  • the sending unit 1806 is further configured to: after the direct connection management unit 1807 updates the direct connection service management table, return a response message, such as an ACK or a NACK, to the first STA.
  • the first AP further includes an antenna for transmitting and receiving a wireless signal, and the antenna is connected to the receiving unit 1801 and the sending unit 1806.
  • FIG. 19 an embodiment of the present invention provides a direct connection service management system, where the system includes a first station STA as shown in FIG. 17 of the present invention and a first access point as shown in FIG. 18 of the present invention.
  • the first STA and the first AP are configured to perform a second STA that can provide a direct connection service, and manage the direct connection service by using the first AP, where the system further includes the second STA, The first STA and the second STA may perform direct communication.
  • the AP may proxy to discover the STA that provides the direct connection service, and manage the direct communication between the STAs, and the STA does not need to periodically monitor the requests of other devices on the channel. Reduce the resource overhead and energy consumption of the STA.
  • the first AP may proxy the first STA to search for service information in the network, and the first AP may provide a wider range and richer service for the user through local searching and remote searching.
  • the information meets the requirements of the user to select the network according to the service requirement; and the AP can proxy to discover the STA that provides the direct connection service, and manage the direct communication between the STAs, so that the STA providing the service in the network does not need to periodically monitor other devices on the channel.
  • the search request reduces the resource cost and energy consumption of the STA that provides the service.
  • the first STA can obtain the service information through the first AP, whether the first STA is associated with an AP.
  • the first STA associated with the first AP may abbreviate or cancel the service information on the first AP, and the first STA does not need to periodically listen for the lookup request of other devices on the channel, and the first AP may also be in the first AP.
  • the device information and service information declared above are spread to neighboring APs accessible in the network, and may also receive service information provided by neighboring APs that are accessible, from In addition, the service information maintained by the AP is verified by the STAs that are authenticated and associated with the AP, ensuring security and ensuring service reliability.

Landscapes

  • Engineering & Computer Science (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Signal Processing (AREA)
  • Computer Security & Cryptography (AREA)
  • Mobile Radio Communication Systems (AREA)
  • Data Exchanges In Wide-Area Networks (AREA)

Abstract

本发明实施例公开了一种服务注册与发现的方法,设备和系统。AP可以接收并维护关联STA注册的服务信息,代理STA发现网络中的服务信息,包括发现直连服务并管理STA之间的直连通信,满足用户根据所需服务选择网络的需求。

Description

一种服务注册与发现的方法, 设备和系统 技术领域
本发明实施例涉及网络通信领域,尤其涉及一种服务注册与发现 的方法, 设备和系统。 背景技术 基于 IEEE ( Institute of Electrical and Electronics Engineers , 美国 电气和电子工程师协会) 802.11 的无线局域网 (wireless local area network, 筒称 WLAN )是利用射频技术, 以无线信道作为传输媒介 的局域网。 WLAN中通常包括站点( station,筒称 STA )、接入点( access point, 筒称 AP )等; STA指具有无线局域网接口的设备, AP除了具 备 STA的功能之外, 还能够通过无线介质为关联 STA提供接口, 连 接到分发系统, 负责实现 STA之间或 STA与有线网络的通信; 多个 STA可以关联到同一个 AP上。
STA接入 WLAN之前, 首先需要在所处区域搜索网络, 发现 可用 AP并关联到所发现的可用 AP。 通常有主动扫描和被动扫描 两种方式来发现可用 AP。 其中,
主动扫描方式: STA 在各个信道上广播探测请求 ( probe request ) 帧, 主动扫描信道上的可用 AP, 并接收可用 AP返回的探 测响应 ( probe response ) 帧, 获得可用 AP的信息。
被动扫描方式: AP周期性发送信标(beacon ) 帧, STA逐个信 道监听, 以捕获 AP发送的 beacon帧, 获得可用 AP的信息。
关联到同一 AP的所有 STA和该 AP共同构成一个基本服务集 ( basic service set,筒称 BSS ), BSS可用基本月良务集标识( basic service set identifier, 筒称 BSSID )来标识, 通常 BSSID是 AP的媒体访问 控制 ( media access control, 筒称 MAC )地址。
无线保真( wireless fidelity , 筒称 WiFi )技术是一种短距离无线 通信技术, 基于其使用方便、 传输速率高等优点, 在无线局域网构建 和广域网接入方面都得到了广泛的应用。 近年来, 随着支持 WiFi技 术的各类终端设备,例如笔记本电脑、手机等的不断普及和迅速增长, WLAN 已成为行业信息化、 家庭信息化和个人信息化的重要技术, 广泛应用于企业、 家庭、 校园、 医院等各种场所, 带来了 WLAN相 关的各类服务需求和用户体验需求。 例如, 在服务分类繁多, 部署集 中的高密度服务场景下, 用户如何发现网络中可以提供的服务, 根据 自己所需的服务, 例如打印, 快速有效的接入相应的网络; 以及更进 一步的, 用户在发现所需服务的同时, 希望通过 WiFi与提供服务的 设备直接交互, 那么设备能力, 例如支持 WiFi直连、 蓝牙等的发现, 都日益成为 WLAN技术的研究热点。
目前, WiFi直连技术可以进行设备发现和点对点( point-to-point, 筒称 P2P )直连连接的建立, 设备之间可以进行共享、 展示、 打印和 同步内容等。 WiFi直连技术的核心是, 设备之间使用 P2P方式发现 所需要的设备, 构建或加入小组, 互相建立连接, 而后在小组内进行 通信。 WiFi 直连技术提供的是一种近距离设备发现, 只能提供基于 设备的发现和查找, 且设备需要周期性监听信道(channel ), 以回应 设备发现和信息共享; 因此, WiFi直连技术受限于设备之间的距离, 不能提供基于服务的发现和查找,且设备需要消耗大量资源用于监听 信道。 发明内容
有鉴于此, 本发明实施例提供了一种服务注册与发现的方法, 设 备和系统, 由接入点 AP接收并维护 STA申明的服务信息, 代理 STA 发现网络中的服务信息,还包括发现直连服务并管理 STA之间的直连 通信, 满足用户根据所需服务选择网络的需求。
第一方面, 提供了一种服务发现的方法, 包括:
第一接入点 AP接收来自第一站点 STA的服务发现请求帧,所述 服务发现请求帧中包括 M个服务查询项, 所述 M为大于等于 0的整 数;
根据所述服务发现请求帧, 查询所述第一 AP的服务信息表, 获 取满足所述 M个服务查询项的查询结果;
向所述第一 STA返回服务发现响应帧, 所述服务发现响应帧中包 括所述查询结果。
在第一方面的第一种可能实现方式中, 所述获取满足所述 M个 服务查询项的查询结果, 具体包括: 获取所述第一 AP的服务信息表 中, 同时满足所述 M个服务查询项的查询结果。
在第一方面的第二种可能实现方式中, 所述获取满足所述 M个 服务查询项的查询结果, 具体包括:
获取所述第一 AP的服务信息表中,同时满足所述 M个服务查询 项的所有服务信息;
向第二 AP转发所述服务发现请求帧, 并接收所述第二 AP返回 的服务发现响应帧, 所述第二 AP返回的服务发现响应帧中包括所述 第二 AP的服务信息表中满足所述 M个服务查询项的所有服务信息; 所述查询结果具体包括: 所述第一 AP的服务信息表中满足所述 M个服务查询项的所有服务信息,和所述第二 AP返回的服务发现响 应帧中包括的服务信息。
在第一方面的第三种可能实现方式中, 所述获取满足所述 M个 服务查询项的查询结果, 具体包括:
当所述第一 AP的服务信息表中存在至少一条服务信息满足所述 M个服务查询项时, 获取所述第一 AP的服务信息表中, 满足所述 M 个服务查询项的所有服务信息;
当所述第一 AP的服务信息表中任意一条服务信息都不满足所述 M个服务查询项时, 向第二 AP转发所述服务发现请求帧, 并接收所 述第二 AP返回的服务发现响应帧, 所述第二 AP返回的服务发现响 应帧中包括所述第二 AP的服务信息表中满足所述 M个服务查询项的 所有服务信息, 获取所述第二 AP返回的服务发现响应帧中包括的服 务信息。
根据第一方面或第一方面的第一种至第三种任意一种可能实现 方式, 在第四种可能实现方式中, 在所述第一 AP接收来自第一 STA 的服务发现请求帧之前, 所述方法还包括:
所述第一 AP接收所述第一 STA广播发送的探测请求帧,所述探 测请求帧中包括服务信息元素;
向所述第一 STA返回探测响应帧, 所述探测响应帧中包括服务信 息元素, 所述服务信息元素包括服务目录项。
根据第一方面或第一方面的第一种至第三种任一种可能实现方 式,在第五种可能实现方式中, 在所述第一 AP接收来自第一 STA的 服务发现请求帧之前, 所述方法还包括: 所述第一 AP广播发送信标 帧, 所述信标帧中包括服务信息元素, 所述服务信息元素包括服务目 录项。
第二方面, 提供了一种服务发现的方法, 包括:
第一站点 STA向第一接入点 AP发送服务发现请求帧,所述服务 发现请求帧中包括 M个服务查询项, 所述 M为大于等于 0的整数; 接收所述 AP返回的服务发现响应帧, 所述服务发现响应帧中包 括满足所述 M个服务查询项的查询结果。
在第二方面的第一种可能实现方式中,在所述 STA向第一 AP发 送服务发现请求帧之前, 所述方法还包括:
所述第一 STA广播发送的探测请求帧, 所述探测请求帧中包括 服务信息元素;
接收所述第一 AP返回的探测响应帧, 所述探测响应帧中包括服 务信息元素, 所述服务信息元素包括服务目录项。
在第二方面的第二种可能实现方式中, 在所述第一 STA向第一 AP发送服务发现请求帧之前, 所述方法还包括:
接收所述第一 AP广播发送的信标帧, 所述信标帧中包括服务信 息元素, 所述服务信息元素包括服务目录项。
第三方面, 提供了一种用于服务发现的第一接入点 AP, 包括: 接收单元, 用于接收来自第一站点 STA的服务发现请求帧, 所 述服务发现请求帧中包括 M个服务查询项; 所述 M为大于等于 0的 整数。
查询单元, 用于根据所述服务发现请求帧, 查询所述第一 AP的 服务信息表, 获取满足所述 M个服务查询项的查询结果;
发送单元, 用于向所述第一 STA返回服务发现响应帧, 所述服 务发现响应帧中包括所述查询结果。
在第三方面的第一种可能实现方式中, 所述查询单元具体包括: 本地子单元, 用于根据所述服务发现请求帧, 查询所述第一 AP 的服务信息表,获取所述第一 AP的服务信息表中满足所述 M个服务 查询项的所有服务信息;
远程子单元, 用于向第二 AP转发所述服务发现请求帧, 并接收 所述第二 AP返回的服务发现响应帧, 所述第二 AP返回的服务发现 响应帧中包括所述第二 AP的服务信息表中满足所述 M个服务查询项 的所有服务信息, 获取所述第二 AP返回的服务发现响应帧中包含的 服务信息;
结果获取子单元, 用于获取满足所述 M个服务查询项的查询结 果, 所述查询结果具体包括所述本地子单元获取的服务信息, 和所述 远程子单元获取的服务信息。
在第三方面的第二种可能实现方式中, 所述查询单元具体包括: 查找子单元, 用于根据所述服务发现请求帧, 查询所述第一 AP 的服务信息表;
远程子单元, 用于当所述查找子单元的查找结果为: 所述第一 AP的服务信息表中任意一条服务信息都不满足所述 M个服务查询项 时, 向第二 AP转发所述服务发现请求帧, 并接收所述第二 AP返回 的服务发现响应帧, 所述第二 AP返回的服务发现响应帧中包括所述 第二 AP的服务信息表中满足所述 M个服务查询项的所有服务信息; 获取所述第二 AP返回的服务发现响应帧中包括的服务信息;
本地子单元, 用于当所述查找子单元的查找结果为: 所述第一 AP 的服务信息表中存在至少一条服务信息满足所述 M 个服务查询 项,获取所述第一 AP的服务信息表中,满足所述 M个服务查询项的 所有服务信息。
根据第三方面或第三方面的任一种可能实现方式,在第三种可能 实现方式中, 所述 AP还包括扫描单元;
所述扫描单元, 用于广播发送信标帧, 所述信标帧中包括服务信 息元素, 所述服务信息元素包括服务目录项; 或者, 用于接收所述第 一 STA广播发送的探测请求帧,并向所述第一 STA返回探测响应帧, 所述探测请求帧中包括服务信息元素,所述探测响应帧中包括服务信 息元素, 所述服务信息元素包括服务目录项。
第四方面, 提供了一种用于服务发现的第一站点 STA, 包括: 发送单元, 用于向第一接入点 AP发送服务发现请求帧, 所述服 务发现请求帧中包括 M个月良务查询项; 接收单元, 用于接收所述第一 AP返回的服务发现响应帧, 所述 服务发现响应帧中包括满足所述 M个服务查询项的查询结果。
在第四方面的第一种可能实现方式中, 所述第一 STA还包括扫 描单元;
所述扫描单元, 用于接收所述第一 AP广播发送的信标帧, 所述 信标帧中包括服务信息元素, 所述服务信息元素包括服务目录项; 或 者, 用于广播发送探测请求帧, 并接收所述第一 AP返回的探测响应 帧, 所述探测请求帧中包括服务信息元素, 所述探测响应帧中包括服 务信息元素, 所述服务信息元素包括服务目录项。 第五方面, 提供了一种服务注册的方法, 包括:
第一接入点 AP接收来自第一站点 STA的服务通告请求帧,所述服 务通告请求帧中包括所述第一 STA的设备地址和至少一个服务申明 项, 所述服务申明项包括服务名称;
获取所述第一 STA的设备标识;
根据所述至少一个服务申明项,获取所述至少一个服务申明项中 每个良务申明项对应的 良务标识;
在所述第一 AP的服务信息表中记录所述至少一个服务申明项中 每个服务申明项对应的服务信息,所述服务信息包括基本服务集标识 BSSID, 设备标识, 服务标识和服务申明项;
向所述第一 STA返回服务通告响应帧, 所述服务通告响应帧中包 括所述 STA的设备标识和所述至少一个服务申明项中每个服务申明 项对应的服务申明应答项;所述服务申明应答项包括服务标识和服务 名称。
在第五方面的第一种可能实现方式中, 所述获取所述第一 STA的 设备标识具体包括: 根据所述第一 STA的设备地址, 查询所述 AP的地址对应关系表, 所述地址对应关系表中包括设备地址与设备标识的对应关系,
当所述 AP的地址对应关系表中一条已有地址对应关系的设备地 址与所述第一 STA的设备地址相同时, 获取所述已有地址对应关系的 设备标识, 即为所述第一 STA的设备标识;
当所述 AP的地址对应关系表中任意一条地址对应关系的设备地 址与所述第一 STA的设备地址都不相同时, 从设备标识池中分配所 述第一 STA的设备标识, 并在所述地址对应关系表中记录所述第一 STA的设备地址与设备标识的地址对应关系。
在第五方面的第二种可能实现方式中,所述服务通告请求帧中还 包括所述第一 STA的设备标识;
相应地, 所述获取所述第一 STA的设备标识具体包括:
从所述服务通告请求帧中获取所述第一 STA的设备标识。
根据第五方面或第五方面的第一种或第二种可能实现方式,在第 三种可能实现方式中, 所述根据所述至少一个服务申明项, 获取所述 至少一个良务申明项中每个良务申明项对应的服务标识包括:
所述第一 AP根据所述至少一个服务申明项中第一服务申明项的 服务名称, 查询所述第一 AP的服务信息表;
当所述第一 AP的服务信息表中任意一条服务信息的服务名称与 所述第一服务申明项的服务名称均不相同时,根据所述第一服务申明 项的服务名称分配第一服务标识;
当所述第一 AP的服务信息表中存在一条已有服务信息的服务名 称与所述第一服务申明项的服务名称相同时,获取所述已有服务信息 的服务标识,即为所述第一服务申明项的服务名称对应的第一服务标 识。 根据第五方面的第三种可能实现方式, 在第四种可能实现方式 中, 所述在所述第一 AP的服务信息表中记录所述至少一个服务申明 项中每个服务申明项对应的服务信息包括:
所述第一 AP获取第一服务信息, 所述第一服务信息包括所述第 一 AP的 BSSID, 所述第一 STA的设备标识, 所述第一服务标识和所述 第一服务申明项;
并在所述第一 AP的服务信息表中记录所述第一服务信息。
根据第五方面或第五方面的第一种至第四种的任一种可能实现 方式, 在第五种可能实现方式中, 所述方法还包括:
所述第一 AP向第二 AP发送第一服务维护帧, 所述第一服务维护 帧中包括第一维护状态和所述至少一个服务申明项中每个服务申明 项对应的服务信息,以使所述第二 AP更新所述第二 AP的服务信息表。
根据第五方面或第五方面的第一种至第五种的任一种可能实现 方式, 在第六种可能实现方式中, 所述方法还包括:
所述第一 AP接收来自所述第一 STA的第二服务维护帧,所述第二 服务维护帧中包括第二维护状态和至少一个服务维护项;所述服务维 护项包括 BSSID , 设备标识和良务标识;
所述第一 AP根据所述第二服务维护帧, 更新所述第一 AP的服务 信息表。
根据第五方面或第五方面的第一种至第五种的任一种可能实现 方式, 在第七种可能实现方式中, 所述方法还包括:
所述第一 AP感知所述第一 STA脱离;
将所述第一 AP的服务信息表中,所述第一 STA申明的所有服务信 息删除。
根据第五方面或第五方面的任一种可能实现方式,在第八种可能 实现, 所述方法还包括:
所述第一 AP接收第三服务维护帧, 所述第三服务维护帧中包括 第一维护状态和至少一条服务信息,或者第二维护状态和至少一个服 务维护项;
所述第一 AP根据所述第三服务维护帧, 更新所述第一 AP的服务 信息表。 第六方面, 提供了一种服务注册的方法, 包括:
第一站点 STA向第一接入点 AP发送服务通告请求帧,所述服务通 告请求帧中包括所述 STA的设备地址和至少一个服务申明项,所述服 务申明项包括服务名称;
接收来自所述第一 AP的服务通告响应帧, 所述服务通告响应帧 中包括所述 STA的设备标识和所述至少一个服务申明项中每个服务 申明项对应的服务申明应答项;所述服务申明应答项包括服务标识和 服务名称。
在第六方面的第一种可能实现方式中, 所述方法还包括: 所述第一 STA向所述第一 AP发送服务维护帧, 以使所述第一 AP 根据所述服务维护帧, 更新所述第一 AP的服务信息表;
所述服务维护帧中包括第二维护状态和至少一个服务维护项;所 述服务维护项包括基本服务集标识 BSSID , 设备标识和服务标识。 第七方面, 提供了一种用于服务注册的第一接入点 AP, 包括: 接收单元, 用于接收来自第一站点 STA的服务通告请求帧, 所述 服务通告请求帧中包括所述第一 STA的设备地址和至少一个服务申 明项, 所述服务申明项包括服务名称;
第一获取单元, 用于获取所述第一 STA的设备标识; 第二获取单元, 用于根据所述至少一个服务申明项, 获取所述至 少一个服务申明项中每个服务申明项对应的服务标识;
记录单元, 用于在所述第一 AP的服务信息表中记录所述至少一 个服务申明项中每个服务申明项对应的服务信息,所述服务信息包括 基本服务集标识 BSSID, 设备标识, 服务标识和服务申明项;
发送单元, 用于向所述第一 STA返回服务通告响应帧, 所述服务 通告响应帧中包括所述第一 STA的设备标识和所述至少一个服务申 明项中每个服务申明项对应的服务申明应答项;所述服务申明应答项 包括服务标识和服务名称。
在第七方面的第一种可能实现方式中,所述第一获取单元具体用 于,根据所述第一 STA的设备地址,查询所述第一 AP的地址对应关系 表, 所述地址对应关系表中包括设备地址与设备标识的对应关系; 当 所述第一 AP的地址对应关系表中一条已有地址对应关系的设备地址 与所述第一 STA的设备地址相同时, 获取所述已有地址对应关系的设 备标识, 即为所述第一 STA的设备标识; 当所述第一 AP的地址对应关 系表中任意一条地址对应关系的设备地址与所述第一 STA的设备地 址都不相同时, 从设备标识池中分配所述第一 STA的设备标识, 并在 所述地址对应关系表中记录所述第一 STA的设备地址与设备标识的 地址对应关系。
在第七方面的第二种可能实现方式中,所述服务通告请求帧中还 包括所述第一 STA的设备标识, 所述第一获取单元具体用于, 从所述 服务通告请求帧中获取所述第一 STA的设备标识。
根据第七方面或第七方面的第一种或第二种可能实现方式,在第 三种可能实现方式中,所述第二获取单元具体用于根据所述至少一个 服务申明项中第一服务申明项的服务名称, 查询所述第一 AP的服务 信息表; 当所述第一 AP的服务信息表中任意一条服务信息的服务名 称与所述第一服务申明项的服务名称均不相同时,根据所述第一服务 申明项的服务名称分配第一服务标识; 当所述第一 AP的服务信息表 中存在一条已有服务信息的服务名称与所述第一服务申明项的服务 名称相同时, 获取所述已有服务信息的服务标识, 即为所述第一服务 申明项的服务名称对应的第一服务标识。
根据第七方面的第三种可能实现方式, 在第四种可能实现方式 中, 所述记录单元具体用于获取第一服务信息, 所述第一服务信息包 括所述第一 AP的 BSSID, 所述第一 STA的设备标识, 所述第一服务标 识和所述第一服务申明项; 并在所述 AP的服务信息表中记录所述第 一服务信息。
根据第七方面或第七方面的任一种可能实现方式,在第五种可能 实现方式中, 所述第一 AP还包括维护单元;
所述维护单元, 用于接收来自所述第一 STA的第二服务维护帧, 所述第二服务维护帧中包括第二维护状态和至少一个服务维护项;根 据所述第二服务维护帧, 更新所述第一 AP的服务信息表; 并向第二 AP转发所述第二服务维护帧, 以使所述第二 AP更新所述第二 AP的服 务信息表; 所述服务维护项包括 BSSID, 设备标识和服务标识。
根据第七方面的第五种可能实现方式, 在第六种可能实现方式 中, 所述维护单元还用于向第二 AP发送第一服务维护帧, 所述第一 服务维护帧中包括第一维护状态和所述至少一个服务申明项中每个 服务申明项对应的服务信息, 以使所述第二 AP更新所述第二 AP的服 务信息表; 所述服务信息包括 BSSID, 设备标识, 服务标识和服务申 明项。
根据第七方面的第五种或第六种可能实现方式,在第七种可能实 现方式中, 所述维护单元还用于接收第三服务维护帧, 所述第三服务 维护帧中包括第一维护状态和至少一条服务信息,或者第二维护状态 和至少一个服务维护项; 并根据所述第三服务维护帧, 更新所述第一
AP的服务信息表。 第八方面, 提供了一种用于服务注册的第一站点 STA, 包括: 发送单元, 用于向第一接入点 AP发送服务通告请求帧, 所述服 务通告请求帧中包括所述第一 STA的设备地址和至少一个服务申明 项, 所述服务申明项包括服务名称;
接收单元, 用于接收来自所述第一 AP的服务通告响应帧, 所述 服务通告响应帧中包括所述第一 STA的设备标识和所述至少一个服 务申明项中每个服务申明项对应的服务申明应答项;所述服务申明应 答项包括服务标识和服务名称。
在第八方面的第一种可能实现中,所述发送单元还用于向所述第 一 AP发送第二服务维护帧,所述第二服务维护帧中包括第二维护状态 和至少一个服务维护项;所述服务维护项包括基本服务集标识 BSSID, 设备标识和 务标识。 第九方面, 提供了一种管理直连服务的方法, 包括:
第一接入点 AP接收第一站点 STA发送的直连服务请求帧,所述 直连服务请求帧中包括服务请求状态和服务名称; 当所述服务请求状 态为第一请求状态时,获取第二 STA的设备地址;根据所述第二 STA 的设备地址, 探测所述第一 STA与第二 STA之间的距离探测所述第 一 STA与第二 STA之间的距离;
当所述第一 STA与所述第二 STA之间的距离不大于直连距离时, 查询所述第一 AP的直连服务管理表; 当所述第一 AP的直连服务管理表中不存在一条已有直连服务管 理信息,所述已有直连服务管理信息的服务名称与所述直连服务请求 帧中的服务名称相同,且所述已有直连服务管理信息的组地址与所述 第二 STA的设备地址相同时,在所述第一 AP的直连服务管理表中记 录第一直连服务管理信息,所述第一直连服务管理信息包括所述直连 服务请求帧中的服务名称和所述第二 STA的设备地址; 并向所述第 一 STA发送直连服务响应帧; 所述直连服务响应帧中包括所述第二 STA的设备地址。
在第九方面的第一种可能实现方式中, 所述方法还包括: 当所述 第一 AP的直连服务管理表中存在一条已有直连服务管理信息的服务 名称与所述直连服务请求帧中的服务名称相同,且所述已有直连服务 管理信息的组地址与所述第二 STA的设备地址相同时, 所述第一 AP 向所述第一 STA发送直连服务响应帧; 所述直连服务响应帧中包括 所述已有直连服务管理信息中的组地址。
根据第九方面或第九方面的第一种可能实现方式,在第二种可能 实现方式中, 所述获取第二 STA的设备地址具体包括: 所述第一 AP 根据所述直连服务请求帧中的服务名称查询所述第一 AP的服务信息 表; 当所述第一 AP的服务信息表中存在一条已有服务信息的服务名 称与所述直连服务请求帧中的服务名称相同,且所述已有服务信息中 设备能力为支持 Wi-Fi直连时, 所述第一 AP获取所述已有服务信息 中的设备标识, 即为所述第二 STA的设备标识; 所述第一 AP根据所 述第二 STA的设备标识, 获取所述第二 STA的设备地址。
根据第九方面或第九方面的第一种可能实现方式,在第三种可能 实现方式中, 所述直连服务请求帧中还包括设备名称; 相应地, 所述 第一 AP获取第二 STA的设备地址具体包括: 所述第一 AP获取所述 直连服务请求帧中的设备标识, 即为所述第二 STA的设备标识; 所 述第一 AP根据所述第二 STA的设备标识, 获取所述第二 STA的设 备地址。
根据第九方面或第九方面的任一种可能实现方式,在第四种可能 实现方式中, 当所述服务请求状态为请求第二状态时, 所述方法还包 括: 所述第一 AP根据所述直连服务请求帧, 查询所述第一 AP的直 连服务管理表; 当所述第一 AP的直连服务管理表中存在一条已有直 连服务管理信息的服务名称与所述直连服务请求帧中的服务名称相 同, 且所述已有直连服务管理信息的组地址与所述第一 STA的设备 地址相同时, 将所述已有直连服务管理信息从所述第一 AP的直连服 务管理表中删除。 第十方面, 提供了一种获取直连服务的方法, 包括:
第一站点 STA向第一接入点 AP发送直连服务请求帧,所述直连 服务请求帧中包括服务请求状态和服务名称;
当所述服务请求状态为第一请求状态时,
所述第一 STA接收所述第一 AP返回的直连服务响应帧,所述直 连服务响应帧中包括组地址;
当根据所述直连服务响应帧确定直连请求成功时,所述第一 STA 与所述直连良务响应帧中组地址对应的第二 STA建立直连 务。 第十一方面, 提供了一种用于管理直连服务的第一接入点 AP, 包括:
接收单元, 用于接收第一站点 STA的直连服务请求帧, 所述直 连服务请求帧中包括服务请求状态和服务名称;
第一获取单元, 用于当所述服务请求状态为第一请求状态时, 获 取第二 STA的设备地址;
探测单元, 用于根据所述第一获取单元获取的所述第二 STA的 设备地址, 探测所述第一 STA与所述第二 STA之间的距离;
查询单元, 用于查询所述第一 AP的直连服务管理表;
第二获取单元, 用于为所述第一 STA的直连服务请求, 获取直 连服务管理信息, 所述直连服务管理信息包括组地址和服务名称; 发送单元, 用于根据所述获取单元获取的直连服务管理信息, 向 所述第一 STA发送直连服务响应帧, 以使所述第一 STA与所述第二 STA建立直连良务, 所述直连良务响应帧中包括所述组地址。
在第十一方面的第一种可能实现方式中,所述第一获取单元具体 用于, 根据所述直连服务请求帧中的服务名称查询所述第一 AP的服 务信息表; 当所述第一 AP的服务信息表中存在一条已有服务信息的 服务名称与所述直连服务请求帧中的服务名称相同,且所述已有服务 信息中设备能力为支持 Wi-Fi直连时, 获取所述已有服务信息中的设 备标识, 即为所述第二 STA的设备标识; 根据所述第二 STA的设备 标识, 获取所述第二 STA的设备地址; 或者,
当所述直连服务请求帧中包括设备名称时,获取所述直连服务请 求帧中的设备标识, 即为所述第二 STA的设备标识; 根据所述第二 STA的设备标识, 获取所述第二 STA的设备地址。
根据第十一方面或第十一方面的第一种可能实现方式,在第二种 可能实现方式中, 所述查询单元, 具体用于当服务请求状态为第一请 求状态时, 当所述探测单元探测到的所述第一 STA与所述第二 STA 之间的距离不大于直连距离时,根据所述直连服务请求帧中的服务名 称和所述第二 STA的设备地址查询所述第一 AP的直连服务管理表。
根据第十一方面或第十一方面的第一种或第二种可能实现方式, 在第三种可能实现方式中, 第二获取单元具体用于, 当所述 AP的直 连服务管理表中存在一条已有直连服务管理信息的服务名称与所述 直连服务请求帧中的服务名称相同,且所述已有直连服务管理信息的 组地址与所述第二 STA的设备地址相同时, 获取所述已有直连服务管 理信息;
当所述 AP的直连服务管理表中任意一条直连服务管理信息的服 务名称和组地址与所述直连服务请求帧中的服务名称和所述第二 STA的设备地址不同时, 获取第一直连服务管理信息, 并在所述 AP 的直连服务管理表中记录所述第一直连服务管理信息;所述第一直连 服务管理信息包括所述直连服务请求帧中的服务名称和所述第二 STA的设备地址。
根据第十一方面或第十一方面的任一种可能实现方式,在第四种 可能实现方式中, 所述第一 AP还包括直连管理单元;
所述查询单元, 具体还用于当服务请求状态为第二状态时, 根据 所述直连服务请求帧中的服务名称和所述第一 STA的设备地址, 查询 所述第一 AP的直连服务管理表;
所述直连管理单元,用于当所述直连服务请求帧中的服务请求状 态为第二请求状态时, 当所述第一 AP的直连服务管理表中存在一条 已有直连服务管理信息的服务名称与所述直连服务请求帧中的服务 名称相同,且所述已有直连服务管理信息的组地址与所述第一 STA的 设备地址相同时, 将所述已有直连服务管理信息从所述第一 AP的直 连服务管理表中删除。 第十二方面, 提供了一种用于获取直连服务的站点 STA, 包括: 发送单元, 用于向第一接入点 AP发送直连服务请求帧, 所述直 连服务请求帧中包括服务请求状态和服务名称; 接收单元, 用于接收所述第一 AP返回的直连服务响应帧, 所述 直连月良务响应帧中包括组地址;
服务建立单元,用于当根据所述直连服务响应帧确定直连请求成 功时, 与所述直连服务响应帧中组地址对应的第二 STA建立直连服 务。
第十三方面, 提供了一种服务发现的系统, 包括如上所述的用于 服务发现的第一接入点 AP和如上所述的用于服务发现的第一站点 STA。
第十四方面, 提供了一种服务注册的系统, 包括如上所述的用于 服务注册的第一接入点 AP和如上所述的用于服务注册的第一站点 STA。
第十五方面, 提供了一种直连服务管理系统, 包括如上所述的用 于管理直连服务的第一接入点 AP和如上所述的用于获取直连服务的 第一站点 STA。
通过上述方案, 第一 AP可以代理第一 STA查找网络中的服务信 息, 并且所述第一 AP可以通过本地查找和远程查找, 为用户提供更 大范围、更丰富的服务信息,满足用户根据服务需求选择网络的需求; 并且 AP可以代理发现提供直连服务的 STA,并管理 STA之间的直连通 信, 这样网络中提供服务的 STA也无需周期性监听信道上其他设备的 查找请求,降低了提供服务的 STA的资源开销和能耗;此外,第一 STA 无论在关联前还是关联后, 都可以通过第一 AP获取服务信息, 可以 避免第一 STA关联到一个 AP后,发现没有所需服务再脱离,导致在不 同 AP间进行频繁的关联和脱离的问题, 保证用户可以更快速准确地 接入可提供服务的网络, 提高了用户体验。 同时, 关联到第一 AP的 第一 STA可以在第一 AP上申明或取消服务信息,第一 STA无需周期性 监听信道上其他设备的查找请求, 第一 AP还可以将在所述第一 AP上 申明的设备信息和服务信息扩散到网络中可访问的相邻 AP, 也可以 接收可访问的相邻 AP提供的服务信息, 从而可以向用户提供更丰富 的服务信息; 最后, 由于 AP上维护的服务信息, 是经过验证关联到 AP上的 STA发布的, 保证了安全性, 从而保证了服务的可靠性。 附图说明
图 1是本发明实施例提供的一种服务发现的方法流程图; 图 2是本发明实施例提供的另一种服务发现的方法流程图; 图 3是本发明实施例提供的又一种服务发现的方法流程图; 图 4是本发明实施例提供的再一种服务发现的方法流程图; 图 5和图 5a是本发明实施例提供的再一种服务发现的方法流程 图;
图 6和图 6a是本发明实施例提供的一种用于服务发现的接入点 AP 结构示意图;
图 6b和图 6c是本发明实施例提供的一种用于服务发现的接入点 AP中查询单元的结构示意图;
图 7和图 7a是本发明实施例提供的一种用于服务发现的站点 STA 结构示意图;
图 8是本发明实施例提供的一种服务注册的方法流程图; 图 9和图 9a是本发明实施例提供的另一种月良务注册的方法流程 图;
图 10和图 10a是本发明实施例提供的又一种服务注册的方法流程 图;
图 11和图 11a是本发明实施例提供的一种用于服务注册的接入点 AP结构示意图; 图 12和图 12a是本发明实施例提供的一种用于服务注册的站点 STA结构示意图;
图 13和图 13a是本发明实施例提供的一种服务注册系统结构示意 图;
图 14是本发明实施例提供的一种服务注册的信息交互示意图; 图 15是本发明实施例提供的一种管理直连服务的方法流程图; 图 16是本发明实施例提供的一种获取直连服务的方法流程图; 图 17是本发明实施例提供的一种用于获取直连服务的站点 STA 结构图;
图 18和图 18a是本发明实施例提供的一种用于管理直连服务的接 入点 AP结构图;
图 19是本发明实施例提供的一种直连服务管理系统结构示意图; 图 20是本发明实施例提供的公共行为帧示意图;
图 21是本发明实施例提供的一种查询类型表示意图;
图 22是本发明实施例提供的一种服务发现请求帧示意图; 图 23是本发明实施例提供的一种服务信息表示意图;
图 24是本发明实施例提供的一种筒化服务信息示意图; 图 25是本发明实施例提供的一种服务发现响应帧示意图; 图 26是本发明实施例提供的一种服务信息元素示意图; 图 27是本发明实施例提供的一种服务通告请求帧示意图; 图 28是本发明实施例提供的一种服务通告响应帧示意图; 图 29是本发明实施例提供的一种服务维护帧示意图;
图 30是本发明实施例提供的一种直连服务请求帧示意图; 图 31是本发明实施例提供的一种直连服务管理表示意图; 图 32是本发明实施例提供的一种直连服务响应帧示意图。 具体实施方式
下面将结合本发明实施例中的附图,对本发明实施例中的技术 方案进行清楚、 完整地描述, 显然, 所描述的实施例仅仅是本发 明的一部分实施例, 而不是全部的实施例。 基于本发明中的实施 例, 本领域普通技术人员在没有做出创造性劳动前提下所获得的 所有其他实施例, 都属于本发明保护的范围。
需要说明的是, 本发明实施例中, 服务通告请求帧, 服务通告响 应帧, 服务维护帧, 服务发现请求帧, 服务发现响应帧, 直连请求帧 和直连响应帧, 可以通过扩展现有 WLAN网络中行为 (Action ) 帧中 类另1 J ( category )为 4的公共行为帧( Public Action frame )来实现; 也 可以用现有的管理帧, 例如 IEEE 802.Hu中所使用的 Public Action frame, 通用广告月 ^务 ( Generic Advertisement Service, 筒称 GAS )初 始化请求( GAS initial request ) 帧、 GAS初始化响应 ( GAS initial response )帧、 GAS恢复请求( GAS comeback request )帧和 GAS恢复 响应 ( GAS comeback response ) 帧等; 也可以扩展 IEEE 802.1 lu中的 接入网络查询协议 ( Access Network Query Protocol, ANQP ) , 通过 扩展的元素携带新的服务相关信息来实现; 当然, 也可以定义新的帧 来实现, 只要能实现本发明的目的即可, 本发明对此不作限定。 方案。 如图 20所示, 为 Public Action frame的结构示意图, 其中类别 ( category )的值为 4, 公共行为域值 ( Public Action field value )字段 用于标识具体的 Public Action frame的类型, 目前已经有 16种 Public Action frame , 分别是 Public Action field value从 0 ~ 15。 本发明实施例 中扩展现 Public Action frame , 例如, 服务发现请求帧用 Public Action field value为 16标识, 月良务发现响应帧用 Public Action field value为 17 标识, 服务通告请求帧用 Public Action field value为 18标识, 服务通告 应答帧用 Public Action field value为 19标识, 服务维护帧用 Public Action field value为 20标识, 直连请求帧用 Public Action field value为 21标识和直连响应帧用 Public Action field value为 22标识;
需要说明的是,本发明实施例中扩展的 Public Action frame所使用 的 Public Action field value是一种示例,随着标准的发展可能使用不同 的值, 本发明对此不作限定。
需要说明的是, 本发明实施例中涉及到的服务标识, 设备标识和 组标识可以是按照 ΑΡ本地规则分配, 即 ΑΡ本地唯一的; 也可以按照 全局统一的规则分配, 即全局唯一的, 本发明实施例对此不作限定。
需要说明的是, 具体实现中, 可以配置 ΑΡ上仅保留本地服务信 息, 即 ΑΡ所在 BSS的服务信息; 也可以配置 ΑΡ上既保留本地服务信 息, 也保留远程服务信息, 即 ΑΡ可访问的相邻 ΑΡ所在 BSS的服务信 息; 本发明实施例对此不作限定。
需要说明的是, 具体实现中, 本发明实施例中的 ΑΡ的服务信息 表可以为一张表, 也可以分为两个子表, 如本地服务信息表和远程服 务信息表, 对此本发明不做限定。 其中本地服务信息表中保存在所述 ΑΡ上注册的服务信息, 远程服务信息表中保存的是在所述 ΑΡ可访问 的相邻 ΑΡ上注册的服务信息。 本领域技术人员可以理解的是, 查询 本地服务信息表, 可以理解为查询 BSSID与所述 ΑΡ的 MAC地址相同 的所有服务信息; 查询远程服务信息表, 可以理解为查询 BSSID与所 述 AP的 MAC地址不同的所有服务信息; 如果既要查询本地服务信息 表, 也要查询远程服务信息表, 则不限制 BSSID即可。 图 1是本发明实施例提供的一种服务发现的方法流程图, 本实施 例中, 所述月良务发现的方法由第一接入点 AP实施, 如图 1所示, 所述 方法包括:
101、第一接入点 AP接收来自第一站点 STA的服务发现请求帧, 所述服务发现请求帧中包括 M个服务查询项, 所述服务查询项包括 查询类型和查询内容;
所述 M为大于等于 0的整数。
需要说明的是, 本发明实施例中, STA在服务发现过程中, 需要 查询所需的服务, 查询类型可以是查询类型名称, 例如 BSSID, 设备 名称, 设备能力, 服务名称, 服务标识等; 也可以是查询类型标识, 例如为每个查询类型名称定义一个查询类型标识,查询类型标识通常 是全局统一的, 只要能够实现本发明的技术方案即可, 本发明对此不 作限定。 示例性, 如图 21所示的查询类型信息表, 为每种查询类型名 称定义一个查询类型标识, 具体的, 本发明对此不作限定。
示例性的, 所述服务发现请求帧可以如图 22所示; 其中 Public Action field value字段后面的长度(length )可变, 用于表示所述服务 发现请求帧中行为细节的长度; 每个服务查询项中的长度(length ) 可变, 用于表示查询内容的长度。
102、 所述第一 AP根据所述服务发现请求帧, 查询所述第一 AP 的服务信息表, 获取满足所述 M个服务查询项的查询结果;
所述获取满足所述 M个服务查询项的查询结果具体包括: 获取 所述第一 AP的服务信息表中,同时满足所述 M个服务查询项的查询 结果。
举例来说, 当 M为 1 , 即服务发现请求帧中包括 1个服务查询项 时, 例如查询类型为 "服务名称", 查询内容为 "打印", 则查询结果 需满足 "服务名称" 为 "打印,,。 当 M为 2, 即服务发现请求帧中包 括 2个服务查询项时, 例如第 1个服务查询项包括: 查询类型为 "服 务名称", 查询内容为 "打印", 第 2个服务查询项包括: 查询类型为 "设备能力", 查询内容为 "支持 Wi-Fi直连", 则查询结果需同时满 足 "服务名称" 为 "打印", 且 "设备能力" 为 "支持 Wi-Fi直连"。
当 M为 0时,所述查询结果为所述第一 AP的服务信息表中的所 有服务信息;
所述服务信息包括基本服务集标识 BSSID,设备标识,服务标识 和服务名称; 所述服务信息还可以包括网络访问策略, 设备名称, 设 备能力, 服务描述等。
示例性的, 所述月良务信息表可以如图 23所示。 其中, BSSID为申 明该服务信息的 STA所关联 AP的 MAC地址; 例如本实施中, 为所述 第一 AP的 MAC地址。
当 M大于等于 1时, 所述查询结果可以是同时满足所述 M个服 务查询项的所有服务信息; 也可以同时满足所述 M个服务查询项的 筒化服务信息。
举例来说, 当 M为 2, 即服务发现请求帧中包括 2个服务查询项 时, 例如第 1个服务查询项包括: 查询类型为 "服务名称", 查询内 容为 "打印", 第 2个服务查询项包括: 查询类型为 "设备能力", 查 询内容为 "支持 Wi-Fi直连", 可以返回满足 "服务名称"为 "打印", 且 "设备能力" 为 "支持 Wi-Fi直连" 的所有服务信息; 也可以返回 满足 "服务名称" 为 "打印", 且 "设备能力" 为 "支持 Wi-Fi直连" 的所有筒化服务信息, 本发明对此不作限定。 如图 24所示, 筒化服 务信息相对服务信息, 去除了服务查询项中的查询类型 "服务名称" 和 "设备能力", 返回筒化服务信息可以减少传输的信息量, 提高传 输效率。
需要说明是, 本发明实施例中, 均以返回服务信息为例描述本发 明技术方案, 但并不构成对本发明的限定。
103、 所述第一 AP向所述第一 STA返回服务发现响应帧, 所述 服务发现响应帧中包括所述查询结果。
示例性的, 所述服务发现响应帧可以如图 25所示; 其中, 长度 ( length )可变, 用于表示所述服务通告响应帧中行为细节的长度。
当然, 所述服务发现响应帧中的查询结果也可以为空, 表示所述 第一 AP没有发现满足所述 M个服务查询项的服务信息。 则如图 25 所示的良务发现相应帧中, 所述 Length字段为 0。 进一步地,对于第一 STA的服务发现请求, 第一 AP可以在所述第 一 AP的服务信息表中查找, 还可以到其他可访问的相邻 AP上查找, 具体可根据需要进行配置。
需要说明的是, 所述第一 AP可以通过无线方式向其他可访问的 相邻 AP转发服务发现请求帧, 并接收其他可访问的相邻 AP返回的服 务发现响应帧。 所述第一 AP也可以通过其他方式, 将所述第一 STA 的服务发现请求帧转发到其他可访问的相邻 AP, 并接收其他可访问 的相邻 AP返回的服务发现响应帧; 例如, 当 WLAN中存在接入控制 器( Access Controller, 筒称 AC )时, 第一 AP可以通过无线接入点控 制和配置 ( Control And Provisioning of Wireless Access Point, 筒称 CAPWAP )协议中的数据消息绑定封装服务发现请求帧和服务发现响 应帧, 通过 AC与其他可访问的相邻 AP进行通信; 再例如, 当 WLAN 中没有 AC, AP直接连接到以太网络时, 所述第一 AP可以通过传输控 制十办议和网际十办议十办议 ( Transmission Control Protocol/ Internet Protocol, 筒称 TCP/IP )与其他可访问的相邻 AP通信, 通过 TCP/IP协 议封装服务发现请求帧和服务发现响应帧。 本发明对所述第一 AP与 其他可访问的相邻 AP之间的通信方式不作限定; 为方便叙述, 以下 统一用转发描述所述第一 AP与其他可访问的相邻 AP之间的通信。 图 2是本发明实施例提供的另一种服务发现的方法流程图, 本实 施例在如本发明图 1所示服务发现的方法基础上, 对本发明技术方案 作进一步描述; 如图 2所示, 所述方法包括:
201、 所述第一 AP接收来自第一站点 STA的服务发现请求帧, 所述服务发现请求帧中包括 M个服务查询项, 所述服务查询项包括 查询类型标识和查询内容;
所述 M为大于等于 0的整数。
具体参见 101 , 在此不再赘述。
202、 所述第一 AP根据所述服务发现请求帧, 查询所述第一 AP 的服务信息表, 获取满足所述 M个服务查询项的查询结果;
如果所述第一 AP配置了转发功能, 即第一 AP可以代理 STA发现 所述第一 AP可访问的相邻 AP上的服务信息,则 202具体包括: 202A - 202C, 或者 202a~202c。
202A: 所述第一 AP根据所述服务发现请求帧, 查询所述第一 AP 的服务信息表,获取所述第一 AP的服务信息表中满足所述 M个服务查 询项的所有服务信息;
具体参见 102, 在此不再赘述。
202B: 所述第一 AP向第二 AP转发所述服务发现请求帧, 并接收 所述第二 AP返回的服务发现响应帧, 所述第二 AP返回的服务发现响 应帧中包括所述第二 AP的服务信息表中满足所述 M个服务查询项的 所有服务信息, 获取所述第二 AP返回的服务发现响应帧中包括的服 务信息;
所述第二 AP收到所述服务发现请求帧后的处理过程, 可以参考 本发明图 1所示方法中 102。 202C: 所述第一 AP获取满足所述 M个服务查询项的查询结果, 所述查询结果具体包括所述第一 AP的服务信息表中满足所述 M个服 务查询项的所有服务信息, 和所述第二 AP返回的服务发现响应帧中 包括的服务信息。
本领域技术人员可以理解的是, 202B可以在 202A之前或之后执 行; 202B也可以与 202A同步执行。
通过 202A ~ 202C, 无论所述第一 AP上是否可以找到满足所述 M 个服务查询项的服务信息,所述第一 AP都会将所述第一 STA的服务发 现请求转发到其他可访问的相邻 AP, 以进行更大范围的服务查找。
202a: 所述第一 AP根据所述服务发现请求帧, 查询所述第一 AP 的服务信息表; 202b: 当所述第一 AP的服务信息表中任意一条服务 信息都不满足所述 M个服务查询项时, 所述第一 AP向第二 AP转发所 述服务发现请求帧, 并接收所述第二 AP返回的服务发现响应帧, 所 述第二 AP返回的服务发现响应帧中包括所述第二 AP的服务信息表中 满足所述 M个服务查询项的所有服务信息;所述第一 AP获取所述第二 AP返回的服务发现响应帧中包括的服务信息;
所述第二 AP收到所述服务发现请求帧后的处理过程, 可以参考 本发明图 1所示方法中 102。
可选的, 所述第一 AP可以在所述第一 AP的服务信息表中记录所 述第二 AP返回的服务发现响应帧中包括的所述第二 AP上满足所述 M 个服务查询项的所有服务信息。
202c: 否则, 当所述第一 AP的服务信息表中存在至少一条服务 信息满足所述 M个服务查询项时, 获取所述第一 AP的服务信息表中, 满足所述 M个服务查询项的所有服务信息。
通过 202a ~ 202c,只有当所述第一 AP上找不到满足所述 M个服务 查询项的服务信息时,所述第一 AP才会将所述第一 STA的服务发现请 求转发到其他可访问的相邻 AP, 以进行更大范围的服务查找。
可选地, 所述第一 AP向第二 AP转发所述第一 STA的服务发现请 求时, 还可以携带所述第一 STA的设备地址或设备标识, 以便所述第 二 AP判断是否已处理了所述第一 STA的服务发现请求。
需要说明的是, 这里以所述第一 AP向第二 AP转发所述第一 STA 的服务发现请求为例说明本发明技术方案, 具体实现中, 所述第一 AP可访问的相邻 AP可能有多个, 过程相同, 在此不再赘述。
203、 所述第一 AP向所述第一 STA返回服务发现响应帧, 所述 服务发现响应帧中包括所述查询结果。
具体参见 103, 在此不再赘述。
通过本发明实施例提供的技术方案, 无论所述第一 AP是仅保留 了本地服务信息, 还是既保存了本地服务信息又保存了远程服务信 息, 所述第一 AP都可以发现可访问范围内的服务信息; 从而可以提 供更大范围的服务发现和查找功能, 向用户提供更丰富的服务信息, 满足用户根据服务需求选择网络的需求。 通常, STA在关联前, 没有任何可用 AP信息时, 需要通过扫描获 取可用 AP信息, 在关联到可用 AP; STA扫描获取可用 AP具体可通过 主动扫描或被动扫描方式实现。 本发明技术方案中, 可以在扫描获取 可用 AP信息后, 通过服务发现请求帧和服务发现响应帧, 获取可用 AP上的服务信息; 也可以对现有扫描方式进行扩展, 在获取可用 AP 信息的同时, 获取可用 AP上的服务目录信息, 可以为主动扫描和被 动扫描分别定义新的帧, 也可以通过扩展探测请求 ( probe Request ) †贞, 探测响应 ( probe Response ) †贞, 信标 ( beacon ) †贞, 例: ¾口定义 一个新的信息元素 (information element ), 用于描述月良务信息, 本发 明对此不作限定。
本发明实施例中, 以定义新的服务信息元素( service information element ),扩展探测请求 ( probe request )†贞 ,探测响应 ( probe response ) 帧和信标(beacon ), 在获取可用 AP信息的同时, 获取可用 AP上的服 务目录信息为例说明本发明技术方案。 服务信息元素 ( service information element )通过元素标识 ( element ID ) 区分, 目前在 IEEE 802.11标准中, element ID还有 17-31、 128-129和 133-136预留, 尚未 使用, 可以从中选取一个作为本发明技术方案扩展的服务信息元素 ( service information element ) 的 element ID。
图 3是本发明实施例提供的又一种服务发现的方法流程图, 本实 施例在图 1或图 2所示服务发现的方法基础上,对本发明技术方案作进 一步描述。 如图 3所示, 所述方法包括:
301、 第一接入点 AP广播发送信标帧, 所述信标帧中包括服务 信息元素;
当采用被动扫描方式时, 所述第一 AP周期性广播信标帧, 第一 站点 STA需要逐个信道监听以捕获所述第一 AP发送的信标帧,获取 所述第一 AP的信息和所述第一 AP上的服务目录信息。
所述服务信息元素中包括服务目录项, 所述服务目录项包括 BSSID, 服务标识和服务名称。
可选的, 所述服务信息元素中还可以包括网络类型; 所述服务目 录项中还可以包括服务描述。 所述网络类型可以是遵从 IEEE 802.11 标准中的定义, 例如私有网络等。
示例' 1"生的, 所述月 ^务信息元素 ( service information element )可 以如图 26所示。 其中, 长度(length )取值 0 ~ 256字节, 用于表示 该服务信息元素的长度。 302、 所述第一 AP接收来自第一站点 STA的服务发现请求帧, 所述服务发现请求帧中包括 M个服务查询项, 所述服务查询项包括 查询类型标识和查询内容;
所述 M为大于等于 0的整数。
具体参见 101 , 在此不再赘述。
303、 所述第一 AP根据所述服务发现请求帧, 查询所述第一 AP 的服务信息表, 获取满足所述 M个服务查询项的查询结果;
具体参见 102或 202, 在此不再赞述。
304、 所述第一 AP向所述第一 STA返回服务发现响应帧, 所述 服务发现响应帧中包括所述满足所述查询结果。
具体参见 103, 在此不再赘述。 图 4是本发明实施例提供的再一种服务发现的方法流程图, 本实 施例在图 1或图 2所示服务发现的方法基础上,对本发明技术方案作进 一步描述; 如图 4所示, 所述方法包括:
401、第一接入点 AP接收第一站点 STA广播发送的探测请求帧, 所述探测请求帧中包括服务信息元素;
其中所述服务信息元素中的长度(length ) 字段为 0。
当采用主动扫描方式时, 所述第一 STA在各个信道上发送携带 服务元素的探测请求帧, 主动扫描信道上的可用 AP, 并请求可用 AP上的服务目录信息。
402、 所述第一 AP向所述第一 STA返回探测响应帧, 所述探测 响应帧中包括服务信息元素;
所述服务信息元素中包括服务目录项, 所述服务目录项包括 BSSID, 服务标识和服务名称;
所述第一 AP收到所述第一 STA的探测请求帧后, 向所述第一 STA返回探测响应帧, 为所述第一 STA提供所述第一 AP的信息; 同时, 由于所述探测请求帧中包括月良务信息元素, 因此所述第一 AP 向所述第一 STA返回的探测响应帧中也包括该服务信息元素, 向所 述第一 STA提供所述第一 AP上的服务目录信息。
可选的, 所述服务信息元素中还可以包括网络类型; 所述服务目 录项中还可以包括服务描述。 所述网络类型可以是遵从 IEEE 802.11 标准中的定义, 例如私有网络等。
示例' 1"生的, 所述月 ^务信息元素 ( service information element )可 以如图 26所示。 其中, 长度(length )取值 0 ~ 256字节, 用于表示 该服务信息元素的长度。
403、 所述第一 AP接收来自所述第一 STA的服务发现请求帧, 所述服务发现请求帧中包括 M个服务查询项, 所述服务查询项包括 查询类型标识和查询内容;
所述 M为大于等于 0的整数。
具体参见 101 , 在此不再赘述。
404、 所述第一 AP根据所述服务发现请求帧, 查询所述第一 AP 的服务信息表, 获取满足所述 M个服务查询项的查询结果;
具体参见 102或 202, 在此不再赞述。
405、 所述第一 AP向所述第一 STA返回服务发现响应帧, 所述 服务发现响应帧中包括所述满足所述查询结果。
具体参见 103, 在此不再赘述。
采用本发明实施例提供的技术方案, 当第一 STA需要获取服务 信息时, 无论所述第一 STA在关联前还是关联后, 都可以通过所述 第一 AP进行服务发现, 也可以避免第一 STA关联到一个 AP后, 发 现没有所需服务再脱离, 导致在不同 AP间进行频繁的关联和脱离的 问题, 保证用户可以更快速准确地接入可提供服务的网络, 提高了用 户体验; 同时, 网络中提供服务的 STA也无需周期性监听信道上其 他设备的查找请求, 降低了提供服务的 STA的资源开销和能耗。 图 5是本发明实施例提供的再一种服务发现的方法流程图, 本实 施例中, 所述服务发现的方法由第一站点 STA实施, 如图 5所示, 所 述方法包括:
501、 第一站点 STA向第一接入点 AP发送服务发现请求帧, 所 述服务发现请求帧中包括 M个服务查询项, 所述服务查询项包括查 询类型和查询内容;
所述 M为大于等于 0的整数。
需要说明的是, 本发明实施例中, STA在服务发现过程中, 需要 查询所需的服务, 查询类型可以是查询类型名称, 例如 BSSID, 设备 名称, 设备能力, 服务名称, 服务标识等; 也可以是查询类型标识, 例如为每个查询类型名称定义一个查询类型标识,查询类型标识通常 是全局统一的, 只要能够实现本发明的技术方案即可, 本发明对此不 作限定。 示例性, 如图 21所示的查询类型信息表, 为每种查询类型 名称定义一个查询类型标识, 具体的, 本发明对此不作限定。
示例性的, 所述服务发现请求帧可以如图 22所示; 其中 Public Action field value字段后面的长度(length )可变, 用于表示所述服务 发现请求帧中行为细节的长度; 每个服务查询项中的长度(length ) 可变, 用于表示查询内容的长度。
502、 所述第一 STA接收所述第一 AP返回的服务发现响应帧, 所述服务发现响应帧中包括满足所述 M个服务查询项的查询结果。
所述查询结果可以是同时满足所述 M个服务查询项的服务信息; 也可以是同时满足所述 M个服务查询项的筒化服务信息。 所述服务信息包括基本服务集标识 BSSID,设备标识,服务标识 和服务名称; 所述服务信息还可以包括网络访问策略, 设备名称, 设 备能力, 服务描述等。
示例性的, 所述服务信息表可以如图 23所示。 其中, BSSID为 申明该服务信息的 STA所关联 AP的 MAC地址; 例如本实施中, 为 所述第一 AP的 MAC地址。
举例来说, 当 M为 2, 即服务发现请求帧中包括 2个服务查询项 时, 例如第 1个服务查询项包括: 查询类型为 "服务名称", 查询内 容为 "打印", 第 2个服务查询项包括: 查询类型为 "设备能力", 查 询内容为 "Wi-Fi直连"; 则查询结果是同时满足 "服务名称" 为 "打 印", 且 "设备能力" 为 "Wi-Fi直连" 的所有服务信息, 也可以是同 时满足 "服务名称" 为 "打印", 且 "设备能力" 为 "Wi-Fi直连" 的 所有筒化服务信息, 本发明对此不作限定。 如图 24所示, 筒化服务 信息相对服务信息, 去除了服务查询项中的查询类型 "服务名称"和 "设备能力", 返回筒化服务信息可以减少传输的信息量, 提高传输 效率。
需要说明是, 本发明实施例中, 均以查询结果为服务信息为例描 述本发明技术方案, 但并不构成对本发明的限定。
示例性的, 所述服务发现响应帧可以如图 25所示; 其中, 长度 ( length )可变, 用于表示所述服务通告响应帧中行为细节的长度。
当然, 所述服务发现响应帧中的查询结果也可以为空, 表示所述 第一 AP没有发现满足所述 M个服务查询项的服务信息。 则如图 25 所示的良务发现相应帧中, 所述 Length字段为 0。
可选地, 所述第一 STA在发送所述服务发现请求帧之后, 也可 以设置一个定时器, 如果在定时器设定的时间内没有收到所述第一 AP返回的服务发现响应帧,则所述第一 STA认为本次服务发现失败; 所述第一 STA可以向所述第一 AP再次发送服务发现请求帧,或者可 以向其他 AP发送服务发现请求帧。
可选地, 如图 5a所示, 在 501之前, 所述第一 STA需要扫描获取 可用 AP信息, 并请求可用 AP上的服务目录信息。
当采用主动扫描方式时, 所述方法还包括:
503、 所述第一 STA广播发送探测请求帧, 所述探测请求帧中包 括服务信息元素;
其中所述服务信息元素中的长度(length ) 字段为 0。 所述探测 请求帧用于请求获取 AP上的服务目录信息, 因此, 所述探测请求帧 中服务信息元素的服务目录项为空, 所述服务信息元素中的长度 ( length )字段为 0。
504、 所述第一 STA接收所述第一 AP返回的探测响应帧, 所述 探测响应帧中包括所述服务信息元素,所述服务信息元素中包括服务 目录项, 所述服务目录项包括 BSSID, 服务标识和服务名称。
当采用被动扫描方式时, 所述方法还包括:
505、 所述第一 STA接收所述第一 AP广播发送的信标帧, 所述 信标帧中包括服务信息元素, 所述服务信息元素中包括服务目录项, 所述服务目录项包括 BSSID, 服务标识和服务名称;
当采用被动扫描方式时, 所述第一 AP会周期性广播信标帧, 所 述第一 STA需要逐个信道监听以捕获所述第一 AP发送的信标帧,获取 所述 AP的信息和所述 AP上的服务目录信息。
采用本发明实施例提供的技术方案, 所述第一 STA无论在关联前 还是关联后, 都可以通过第一 AP代理查找网络中可提供的设备信息 和服务信息, 获取更丰富的服务信息, 满足用户根据服务需求选择网 络的需求;也可以避免第一 STA关联到一个 AP后,发现没有所需服务 再脱离, 导致在不同 AP间进行频繁的关联和脱离的问题, 保证用户 可以更快速准确地接入可提供服务的网络, 提高了用户体验。 本发明实施例提供了一种服务发现系统, 所述系统包括如图 6所 示的第一接入点 AP和如图 7所示的第一站点 STA; 所述第一 STA和所 述第一 AP交互实现本发明实施例提供的服务发现的方法。
所述系统还可以包括第二 AP, 所述第二 AP为所述第一 AP可访问 的相邻 AP; 可以理解的是, 所述系统中可能存在多个第二 AP。
接下来详细描述本发明实施例提供的服务发现系统中所述第一 STA和所述第一 AP。
图 6是本发明实施例提供的一种用于服务发现的第一接入点 AP 结构示意图; 如图 6所示, 所述第一 AP包括接收单元 601 , 查询单元 602和发送单元 603。 其中,
所述接收单元 601 ,用于接收来自第一站点 STA的服务发现请求 帧, 所述服务发现请求帧中包括 M个服务查询项;
所述服务查询项包括查询类型和查询内容;所述 M为大于等于 0 的整数。
需要说明的是, 本发明实施例中, STA在服务发现过程中, 需要 查询所需的服务, 查询类型可以是查询类型名称, 例如 BSSID, 设备 名称, 设备能力, 服务名称, 服务标识等; 也可以是查询类型标识, 例如为每个查询类型名称定义一个查询类型标识,查询类型标识通常 是全局统一的, 只要能够实现本发明的技术方案即可, 本发明对此不 作限定。 示例性, 如图 21所示的查询类型信息表, 为每种查询类型名 称定义一个查询类型标识, 具体的, 本发明对此不作限定。
示例性的, 所述服务发现请求帧可以如图 22所示; 其中 Public Action field value字段后面的长度(length )可变, 用于表示所述服务 发现请求帧中行为细节的长度; 每个服务查询项中的长度(length ) 可变, 用于表示查询内容的长度。
所述查询单元 602, 用于根据所述服务发现请求帧, 查询所述第 一 AP的服务信息表, 获取满足所述 M个服务查询项的查询结果; 所述查询单元 602具体用于获取所述第一 AP的服务信息表中, 同时满足所述 M个服务查询项的查询结果。
举例来说, 当 M为 1 , 即服务发现请求帧中包括 1个服务查询项 时, 例如查询类型为 "服务名称", 查询内容为 "打印", 则查询结果 需满足 "服务名称" 为 "打印,,。 当 M为 2, 即服务发现请求帧中包 括 2个服务查询项时, 例如第 1个服务查询项包括: 查询类型为 "服 务名称", 查询内容为 "打印", 第 2个服务查询项包括: 查询类型为 "设备能力", 查询内容为 "支持 Wi-Fi直连", 则查询结果需同时满 足 "服务名称" 为 "打印", 且 "设备能力" 为 "支持 Wi-Fi直连"。
当 M为 0时,所述查询结果为所述第一 AP的服务信息表中的所 有服务信息;
所述服务信息包括基本服务集标识 BSSID,设备标识,服务标识 和服务名称; 所述服务信息还可以包括网络访问策略, 设备名称, 设 备能力, 服务描述等。
示例性的, 所述服务信息表可以如图 23所示。 其中, BSSID为 申明该服务信息的 STA所关联 AP的 MAC地址; 例如本实施中, 为 所述第一 AP的 MAC地址。
当 M大于等于 1时, 所述查询结果可以是同时满足所述 M个服 务查询项的所有服务信息; 也可以同时满足所述 M个服务查询项的 筒化服务信息。 举例来说, 当 M为 2, 即服务发现请求帧中包括 2个服务查询项 时, 例如第 1个服务查询项包括: 查询类型为 "服务名称", 查询内 容为 "打印", 第 2个服务查询项包括: 查询类型为 "设备能力", 查 询内容为 "支持 Wi-Fi直连", 可以返回满足 "服务名称"为 "打印", 且 "设备能力" 为 "支持 Wi-Fi直连" 的所有服务信息; 也可以返回 满足 "服务名称" 为 "打印", 且 "设备能力" 为 "支持 Wi-Fi直连" 的所有筒化服务信息, 本发明对此不作限定。 如图 24所示, 筒化服 务信息相对服务信息, 去除了服务查询项中的查询类型 "服务名称" 和 "设备能力", 返回筒化服务信息可以减少传输的信息量, 提高传 输效率。
需要说明是, 本发明实施例中, 均以返回服务信息为例描述本发 明技术方案, 但并不构成对本发明的限定。
所述发送单元 603, 用于向所述第一 STA返回服务发现响应帧, 所述服务发现响应帧中包括所述查询结果。
示例性的, 所述服务发现响应帧可以如图 25所示。 其中, 长度 ( length )可变, 用于表示所述服务通告响应帧中行为细节的长度。
当然, 所述服务发现响应帧中的查询结果也可以为空, 表示所述 第一 AP没有发现满足所述 M个服务查询项的服务信息。 则如图 25 所示的良务发现相应帧中, 所述 Length字段为 0。
可选的, 如图 6a所示, 所述第一 AP还包括扫描单元 604;
所述扫描单元 604, 用于广播发送信标帧; 或者用于接收所述第 一 STA广播发送的探测请求帧,并向所述第一 STA返回探测响应帧。 当采用被动扫描方式时,所述扫描单元 604具体用于周期性广播信标 帧, 所述信标帧中包括服务信息元素, 所述服务信息元素包括服务目 录项, 所述服务目录项包括 BSSID, 服务标识和服务名称。 所述第一 STA需要逐个信道监听以捕获所述第一 AP发送的信标帧 , 获取所述 第一 AP的信息和所述第一 AP上的服务目录信息。
当采用主动扫描方式时, 所述第一 STA会在各个信道上发送携 带服务信息元素的探测请求帧, 主动扫描信道上的可用 AP, 并请求 可用 AP上的服务目录信息。 所述扫描单元 604具体用于接收所述第 一 STA广播发送的探测请求帧, 所述探测请求帧中包括服务信息元 素, 所述服务信息元素中的长度(length ) 字段为 0; 并向所述第一 STA返回探测响应帧,所述探测响应帧中包括服务信息元素,所述服 务信息元素中包括服务目录项, 所述服务目录项包括 BSSID,服务标 识和服务名称,用于向所述第一 STA提供所述第一 AP的信息和所述 第一 AP上的服务目录信息。
示例' 1"生的, 所述月 ^务信息元素 ( service information element )可 以如图 26所示。 其中, 长度(length )取值 0 ~ 256字节, 用于表示 该服务信息元素的长度。
可选的, 所述服务信息元素中还可以包括网络类型; 所述服务目 录项中还可以包括服务描述。 所述网络类型可以是遵从 IEEE 802.11 标准中的定义, 例如私有网络等。
可选的, 如图 6b所示, 所述查询单元 602包括:
本地子单元 602A, 用于根据所述服务发现请求帧, 查询所述第 一 AP的服务信息表, 获取所述第一 AP的服务信息表中满足所述 M 个服务查询项的所有服务信息;
远程子单元 602B, 用于向第二 AP转发所述服务发现请求帧, 并接收所述第二 AP返回的服务发现响应帧, 所述第二 AP返回的服 务发现响应帧中包括所述第二 AP的服务信息表中满足所述 M个服务 查询项的所有服务信息, 获取所述第二 AP返回的服务发现响应帧中 包含的服务信息;
结果获取子单元 602C, 用于获取满足所述 M个服务查询项的查 息, 和所述远程子单元 602B获取的服务信息。
可选的, 如图 6c所示, 所述查询单元 602包括:
查找子单元 602a, 用于根据所述服务发现请求帧, 查询所述第 一 AP的服务信息表;
远程子单元 602b, 用于当所述查找子单元 602a的查找结果为: 所述第一 AP的服务信息表中任意一条服务信息都不满足所述 M个服 务查询项时, 向第二 AP转发所述服务发现请求帧, 并接收所述第二 AP返回的服务发现响应帧, 所述第二 AP返回的服务发现响应帧中 包括所述第二 AP的服务信息表中满足所述 M个服务查询项的所有服 务信息;获取所述第二 AP返回的服务发现响应帧中包括的服务信息; 本地子单元 602c, 用于当所述查找子单元 602a的查找结果为: 所述第一 AP的服务信息表中存在至少一条服务信息满足所述 M个服 务查询项,获取所述第一 AP的服务信息表中,满足所述 M个服务查 询项的所有服务信息。
可选地,所述远程子单元 602B或远程子单元 602b在转发所述第 一 STA的服务发现请求时, 还可以携带所述第一 STA的设备地址或 设备标识,以便所述第二 AP判断是否已处理了所述第一 STA的服务 发现请求。 图 7是本发明实施例提供的一种用于服务发现的第一站点 STA结 构示意图; 如图 7所示, 所述第一 STA包括发送单元 701和接收单元 702。 其中,
所述发送单元 701 ,用于向第一接入点 AP发送服务发现请求帧, 所述服务发现请求帧中包括 M个服务查询项;
所述服务查询项包括查询类型和查询内容;所述 M为大于等于 0 的整数。
需要说明的是, 本发明实施例中, STA在服务发现过程中, 需要 查询所需的服务, 查询类型可以是查询类型名称, 例如 BSSID, 设备 名称, 设备能力, 服务名称, 服务标识等; 也可以是查询类型标识, 例如为每个查询类型名称定义一个查询类型标识,查询类型标识通常 是全局统一的, 只要能够实现本发明的技术方案即可, 本发明对此不 作限定。 示例性, 如图 21所示的查询类型信息表, 为每种查询类型 名称定义一个查询类型标识, 具体的, 本发明对此不作限定。
示例性的, 所述服务发现请求帧可以如图 22所示; 其中 Public Action field value字段后面的长度(length )可变, 用于表示所述服务 发现请求帧中行为细节的长度; 每个服务查询项中的长度(length ) 可变, 用于表示查询内容的长度。
所述接收单元 702, 用于接收所述第一 AP返回的服务发现响应 帧, 所述服务发现响应帧中包括满足所述 M个服务查询项的查询结 果。
所述查询结果可以是同时满足所述 M个服务查询项的所有服务 信息; 也可以同时满足所述 M个服务查询项的筒化服务信息。
所述服务信息包括基本服务集标识 BSSID,设备标识,服务标识 和服务名称; 所述服务信息还可以包括网络访问策略, 设备名称, 设 备能力, 服务描述等。
示例性的, 所述服务信息表可以如图 23所示。 其中, BSSID为 申明该服务信息的 STA所关联 AP的 MAC地址; 例如本实施中, 为 所述第一 AP的 MAC地址。 举例来说, 当 M为 2, 即服务发现请求帧中包括 2个服务查询项 时, 例如第 1个服务查询项包括: 查询类型为 "服务名称", 查询内 容为 "打印", 第 2个服务查询项包括: 查询类型为 "设备能力", 查 询内容为 "支持 Wi-Fi直连", 则查询结果需同时满足 "服务名称" 为 "打印" , 且 "设备能力" 为 "支持 Wi-Fi直连" 的所有服务信息; 也可以是同时满足 "服务名称" 为 "打印", 且 "设备能力" 为 "支 持 Wi-Fi直连" 的所有筒化服务信息, 本发明对此不作限定。 如图 24 所示, 筒化服务信息相对服务信息, 去除了服务查询项中的查询类型 "服务名称" 和 "设备能力", 返回筒化服务信息可以减少传输的信 息量, 提高传输效率。
需要说明是, 本发明实施例中, 均以查询结果为服务信息为例描 述本发明技术方案, 但并不构成对本发明的限定。
示例性的, 所述服务发现响应帧可以如图 25所示; 其中, 长度 ( length )可变, 用于表示所述服务通告响应帧中行为细节的长度。
当然, 所述服务发现响应帧中的查询结果也可以为空, 表示所述 第一 AP没有发现满足所述 M个服务查询项的服务信息。 则如图 25 所示的良务发现相应帧中, 所述 Length字段为 0。
可选的, 如图 7a所示, 所述第一 STA还包括扫描单元 703;
所述扫描单元 703, 用于接收所述第一 AP广播发送的信标帧; 或 者, 用于广播发送探测请求帧, 并接收所述第一 AP返回的探测响应 帧。
通过所述扫描单元 703, 所述第一 STA可以获取可用 AP信息, 并 请求可用 AP上的服务目录信息。
当采用主动扫描方式时, 所述扫描单元 703具体用于广播发送探 测请求帧, 所述探测请求帧中包括服务信息元素, 所述服务信息元素 中的长度 ( length )字段为 0; 并接收所述第一 AP返回的探测响应帧, 所述探测响应帧中包括所述服务信息元素,所述服务信息元素中包括 服务目录项, 所述服务目录项包括 BSSID, 服务标识和服务名称。
当采用被动扫描方式时,所述扫描单元 703具体用于接收所述第 一 AP广播发送的信标帧, 所述信标帧中包括服务信息元素, 所述服 务信息元素中包括服务目录项, 所述服务目录项包括 BSSID,服务标 识和服务名称。
可选地, 所述第一 STA还包括定时单元, 用于在发送所述服务 发现请求帧之后, 设置一个定时器, 如果在定时器设定的时间内没有 收到所述第一 AP返回的服务发现响应帧,则认为本次服务发现失败; 则所述第一 STA可以向所述第一 AP再次发送服务发现请求帧,或者 可以向其他 AP发送服务发现请求帧。
采用本发明实施例提供的服务发现的技术方案, 第一 AP可以代 理第一 STA查找网络中的服务信息 ,并且所述第一 AP可以通过本地查 找和远程查找, 为用户提供更大范围、 更丰富的服务信息, 满足用户 根据服务需求选择网络的需求; 这样网络中提供服务的 STA也无需周 期性监听信道上其他设备的查找请求, 降低了提供服务的 STA的资源 开销和能耗; 此外, 第一 STA无论在关联前还是关联后, 都可以通过 第一 AP获取服务信息, 可以避免第一 STA关联到一个 AP后, 发现没 有所需服务再脱离, 导致在不同 AP间进行频繁的关联和脱离的问题, 保证用户可以更快速准确地接入可提供服务的网络, 提高了用户体 验。 进一步的, 第一 STA关联到第一 AP后, 可以向第一 AP申明可提 供的服务。 第一 AP也可以向网络中其他可访问的相邻 AP扩散第一 STA申明的服务信息。 图 8是本发明实施例提供的一种服务注册的方法流程图, 本实施 例中, 所述月良务注册的方法由第一接入点 AP实施, 如图 8所示, 所述 方法包括:
801、 第一接入点 AP接收来自第一站点 STA的服务通告请求帧; 所述服务通告请求帧中包括所述第一 STA的设备地址和至少一个服 务申明项, 所述服务申明项包括服务名称;
所述第一 STA关联到所述第一 AP后, 可以向所述第一 AP发送服 务通告请求帧, 向所述第一 AP注册服务。
所述第一 STA的设备地址通常为所述第一 STA的 MAC地址。所述 第一 STA的设备地址通常携带在所述服务通告请求帧的头部。
所述服务通告请求帧中还可以包括所述第一 STA的设备名称,设 备标识, 设备能力, 设备描述等。 所述第一 STA的设备名称可以是例 如, 打印机、 电视机等, 也可以是例如 1号咖啡馆, 2号票务中心等; 所述第一 STA的设备能力可以是例如支持 Wi-Fi直连, 支持蓝牙等, 还可进一步在设备能力中携带能力参数, 例如支持 Wi-Fi直连时, 携 带直连距离。 例如,
设备名称 设备能力
打印机 支持 Wi-Fi直连, 直连距离为 L;
2号票务中心 可上门服务; 所述服务申明项除了包括服务名称,还可以包括服务描述。例如: 上述 2号票务中心, 可提供如下服务:
服务名称 月良务描述
飞机票预售 仅售南方航空公司
火车票预售 仅售动车票
票务查询 三曰内 当所述第一 STA可以提供多项服务时, 所述第一 STA可以一次向 所述第一 AP注册多项服务, 则所述服务通告请求帧中包括多个服务 申明项; 所述第一 STA也可以分多次向所述第一 AP注册服务, 即每次 向所述第一 AP注册一项服务, 注册多次, 则每次所述服务通告请求 帧中仅包括一个月良务申明项。
示例性的, 所述服务通告请求帧可以如图 27所示; 其中, 长度 ( length )可变, 用于表示所述服务通告请求帧中行为细节的长度。
802、 所述第一 AP获取所述第一 STA的设备标识;
具体的,所述第一 AP根据所述第一 STA的设备地址,查询所述第 一 AP的地址对应关系表, 所述地址对应关系表中包括设备地址与设 备标识的对应关系,
当所述第一 AP的地址对应关系表中一条已有地址对应关系的设 备地址与所述第一 STA的设备地址相同时, 获取所述已有地址对应关 系的设备标识, 即为所述第一 STA的设备标识;
当所述第一 AP的地址对应关系表中任意一条地址对应关系的设 备地址与所述第一 STA的设备地址都不相同时,从设备标识池中分配 所述第一 STA的设备标识, 并在所述地址对应关系表中记录所述第一 STA的设备地址与设备标识的地址对应关系。
可选的,如果所述服务通告请求帧中包括所述第一 STA的设备标 识, 所述第一 AP也可以从所述服务通告请求帧中获取所述第一 STA 的设备标识。
例如,设备地址为 MAC1的 2号票务中心的设备标识 DI-1 ,设备地 址为 MAC2的打印机 1的设备标识为 DI-2;
803、 所述第一 AP根据所述至少一个服务申明项, 获取所述至少 一个服务申明项中每个服务申明项对应的服务标识; 即, 所述第一 ΑΡ分别根据每个服务申明项的服务名称获取对应 的服务标识, 具体包括:
所述第一 ΑΡ根据所述至少一个服务申明项中第一服务申明项的 服务名称, 查询所述第一 ΑΡ的服务信息表;
当所述第一 ΑΡ的服务信息表中任意一条服务信息的服务名称与 所述第一服务申明项的服务名称均不相同时,根据所述第一服务申明 项的服务名称从服务标识池中分配第一服务标识;
当所述第一 ΑΡ的服务信息表中存在一条已有服务信息的服务名 称与所述第一服务申明项的服务名称相同, 且所述已有服务信息的 BSSID与所述第一 ΑΡ的 MAC地址相同时, 获取所述已有服务信息的 服务标识, 即为所述第一服务申明项的服务名称对应的第一服务标 识。
如果还有第二服务申明项,则获取第二服务申明项的服务名称对 应的第二服务标识, 以此类推。
举例来说, 2号票务中心发送服务通告请求帧, 所述服务通告请 求帧中包括两个服务申明项, 第一个服务申明项的服务名称为 "飞机 票预售" , 第二个服务申明项的服务名称为 "火车票预售" , 则所述 第一 AP根据 "飞机票预售"获取服务标识 SI-1 ,再根据 "火车票预售" 获取服务标识 SI-2。
804、所述第一 AP在所述第一 AP的服务信息表中记录所述至少一 个服务申明项中每个服务申明项对应的服务信息;所述服务信息包括 基本服务集标识 BSSID, 设备标识, 服务标识和服务申明项;
具体的, 所述第一 AP获取第一服务信息, 所述第一服务信息包 括所述第一 AP的 BSSID, 所述第一 STA的设备标识, 所述第一服务标 识和所述第一服务申明项; 并在所述第一 AP的服务信息表中记录所述第一服务信息; 如果还有第二服务申明项, 则获取第二服务信息, 并在所述第一 AP的服务信息表中记录所述第二服务信息; 以此类推。
可选的, 服务信息还可以包括所述第一 STA的设备名称, 所述第 一 STA的设备能力, 网络访问策略。 网络访问策略可以表示 AP所在 BSS内的访问策略, 也可以是针对某项具体月良务的访问策略, 例如, API在公共网络, AP2在私有网络, API根据 AP2的访问策略可以访问 AP2所在的私有网络。
示例性的, 所述服务信息可以如图 23所示; 其中, BSSID为申明 该服务信息的 STA所关联 AP的 MAC地址; 例如本实施中, 为所述第 一 AP的 MAC地址。
805、 所述第一 AP向所述第一 STA返回服务通告响应帧, 所述服 务通告响应帧中包括所述第一 STA的设备标识和所述至少一个服务 申明项对应的服务申明应答项;所述服务申明应答项包括服务标识和 服务名称。
具体的, 所述服务通告响应帧中包括:
在 802中获取的所述第一 STA的设备标识; 和
所述至少一个服务申明项中每个服务申明项对应的服务申明应 答项, 包括:
对应所述第一服务申明项的第一申明应答项,所述第一申明应答 项包括所述第一服务申明项的服务名称和所述第一服务标识;
以及, 如果还有第二服务申明项, 对应所述第二服务申明项的第 二申明应答项,所述第二申明应答项包括第二服务申明项的服务名称 和所述第二服务标识; 以此类推。
可选地, 所述良务通告响应帧中还可以包括所述第一 STA的设备 名称。
示例性的, 所述服务通告响应帧可以如图 28所示; 其中, 长度 ( length )可变, 用于表示所述服务通告响应帧中行为细节的长度。
采用本发明实施例提供的服务注册的方法, 关联到第一 AP的第 一 STA可以在第一 AP上申明服务信息; 第一 AP管理并维护所在 BSS 内的服务信息, 并提供服务查找功能, 这样第一 STA无需周期性监听 信道上其他设备的查找请求, 降低了第一 STA的资源开销和能耗。 需要说明的是, 所述第一 AP可以通过无线方式向其他可访问的 相邻 AP转发服务维护帧, 和接收其他可访问的相邻 AP发送的服务维 护帧。 所述第一 AP也可以通过其他方式, 将服务维护帧转发到其他 可访问的相邻 AP; 例如, 当 WLAN中存在接入控制器(Access Controller, 筒称 AC ) 时, 第一 AP可以通过无线接入点控制和配置
( Control And Provisioning of Wireless Access Point, 筒称 CAPWAP ) 协议中的数据消息绑定封装服务维护帧, 通过 AC与其他可访问的相 邻 AP进行通信; 再例如, 当 WLAN中没有 AC, AP直接连接到以太网 络时, 所述第一 AP可以通过传输控制协议和网际协议协议
( Transmission Control Protocol/ Internet Protocol , 筒称 TCP/IP ) 与其 他可访问的相邻 AP通信, 通过 TCP/IP协议封装服务维护帧。 本发明 对所述第一 AP与其他可访问的相邻 AP之间的通信方式不作限定; 为 方便叙述, 以下统一用转发描述所述第一 AP与其他可访问的相邻 AP 之间的通信。
图 9是本发明实施例提供的另一种服务注册的方法流程图, 本实 施例在图 8所示服务注册的方法基础上, 对本发明技术方案作进一步 描述; 如图 9所示, 所述方法包括:
901、 第一接入点 AP接收来自第一站点 STA的服务通告请求帧; 所述服务通告请求帧中包括所述第一 STA的设备地址和至少一个服 务申明项, 所述服务申明项包括服务名称;
具体参见 801 , 在此不再赘述。
902、 所述第一 AP根据所述第一 STA的设备地址, 获取所述第一 STA的设备标识;
具体参见 802, 在此不再赘述。
903、 所述第一 AP根据所述至少一个服务申明项, 获取所述至少 一个服务申明项中每个服务申明项对应的服务标识;
具体参见 803, 在此不再赘述。
904、所述第一 AP在所述第一 AP的服务信息表中记录所述至少一 个服务申明项对应的服务信息; 所述服务信息包括基本服务集标识 BSSID, 设备标识, 服务标识和服务申明项;
具体参见 804, 在此不再赘述。
905、 所述第一 AP向所述第一 STA返回服务通告响应帧, 所述服 务通告响应帧中包括所述第一 STA的设备标识和所述至少一个服务 申明项对应的服务申明应答项;所述服务申明应答项包括服务标识和 服务名称;
具体参见 805, 在此不再赘述。
进一步的, 在本发明实施例中, STA可以通过服务维护帧取消 息表。
所述服务维护帧中包括维护状态和维护细节。所述维护状态包括 第一维护状态和第二维护状态, 其中第一维护状态用于 AP上新增了 STA申明的服务时,向其他可访问的相邻 AP更新注册服务; 第二维护 状态用于 STA需要取消已经申明的服务, 向 AP取消服务, 以及可选的 AP向其他可访问的相邻 AP更新取消服务。 所述维护状态可以用字符 串表示, 例如 Register表示第一维护状态, Cancel表示第一维护状态; 也可以用数字表示, 例如 1表示第一维护状态, 0表示第一维护状态, 本发明对此不作限定。
906、所述第一 AP向第二 AP发送第一服务维护帧, 所述第一服务 维护帧中包括维护状态和维护细节, 以使所述第二 AP更新所述第二 AP的服务信息表;
所述第一服务维护帧中维护状态为第一维护状态,维护细节包括 所述至少一个服务申明项中每个服务申明项对应的服务信息。
具体的, 所述第一 AP向第二 AP发送第一服务维护帧, 所述第一 服务维护帧中包括:
第一维护状态; 和
所述至少一个服务申明项中每个服务申明项对应的服务信息, 包 括:
对应所述第一服务申明项的第一服务信息;
以及, 如果还有第二服务申明项, 对应所述第二服务申明项的第 二服务信息; 以此类推。
所述第二 AP为所述第一 AP可访问的相邻 AP, 本实施例中, 所述 第二 AP可以是所述第一 AP通过无线方式可以访问, 还可以是所述第 一 AP通过有线方式可以访问, 只要所述第一 AP与所述第二 AP之间可 以进行通信即可, 本发明对此不作限定。
所述第二 AP在收到所述第一服务维护帧之后, 更新所述第二 AP 的服务信息表, 具体包括: 所述第二 AP根据所述第一服务维护帧中 的第一维护状态, 在所述第二 AP的服务信息表中记录所述第一服务 维护帧中的服务信息。 通过 906, 所述第一 AP可以将所述第一 STA申 明的服务信息扩散到网络中更大范围, 并代理所述第一 STA为更大范 围的用户提供服务查找功能。
进一步的,可以取消所述第一 STA在所述第一 AP上已申明的全部 或部分良务, 所述方法还包括:
907、 所述第一 AP感知所述第一 STA脱离; 或者, 所述第一 AP接 收来自所述第一 STA的第二服务维护帧, 所述第二服务维护帧包括维 护状态和维护细节;
所述第二服务维护帧中的维护状态为第二维护状态,维护细节包 括至少一个服务维护项;
所述服务维护项中包括 BSSID, 设备标识和服务标识, 可以标识 所述 STA已申明的一个服务。
当所述第一 AP感知所述第一 STA脱萬时, 所述第一 AP可以取消 所述第一 STA在所述第一 AP上已申明的全部服务;具体的,将所述第 一 AP的服务信息表中,所述第一 STA申明的所有服务信息删除。进一 步可选的, 所述第一 AP可以向第二 AP发送服务维护帧, 以使所述第 二 AP更新所述第二 AP的服务信息表。 第一 AP感知第一 STA脱离可以 参考现有实现方式, 本发明对此不作限定。
所述第一 STA也可以向所述第一 AP发送维护状态为第二维护状 态的服务维护帧取消在所述第一 AP上已申明的全部或部分的服务。
所述第一 AP接收到的来自所述第一 STA的第二服务维护帧中的 月良务维护项中的 BSSID和设备标识可以为空, 则所述第一 AP可以, 先获取 BSSID, 即所述第一 AP的 MAC地址和设备标识, 即所述 第一 STA的设备标识;所述第一 AP可以根据所述第一 STA的设备地址 查询所述第一 AP的地址对应关系表, 获得所述第一 STA的设备标识; 再根据获取到的 BSSID和设备标识, 以及所述至少一个服务维护 项中每个服务维护项的服务标识,得到所述第一 STA需要取消的所有 服务, 然后进行后续处理。
可选的,所述第一 AP接收到的来自所述第一 STA的第二服务维护 帧中的服务维护项可以为空,表示所述第一 STA要取消已申明的全部 服务。
可选的, 为了防止恶意 STA攻击,所述第一 AP收到所述第二服务 维护帧时,如果服务维护项中包含了 BSSID和设备标识,所述第一 AP 首先验证所述 BSSID是否为所述第一 AP的 MAC地址, 所述设备标识 是否与所述第一 STA的设备地址对应, 如果都一致再进行后续处理; 否则可以认为是恶意攻击, 不做处理。
908、 所述第一 AP更新所述第一 AP的服务信息表;
当所述第一 AP感知所述第一 STA脱萬时, 所述第一 AP将所述第 一 AP的服务信息表中, 所述第一 STA申明的所有服务信息删除; 具体 包括:
所述第一 AP获取 BSSID,即所述第一 AP的 MAC地址和设备标识, 即所述第一 STA的设备标识; 所述第一 AP可以根据所述第一 STA的设 备地址查询所述第一 AP的地址对应关系表,获得所述第一 STA的设备 标识; 再根据所述第一 AP的 MAC地址和所述第一 STA的设备标识, 更新所述第一 AP的服务信息表, 具体的, 所述第一 AP根据所述第一 AP的 MAC地址和所述第一 STA的设备标识, 查询所述第一 AP的服务 信息表,将所述第一 AP的服务信息表中, BSSID与所述第一 AP的 MAC 地址相同,且设备标识与所述第一 STA的设备标识相同的所有服务信 息删除。
然后 ,所述第一 AP可以将分配给所述第一 STA的设备标识回收进 设备标识池。 当所述第一 AP收到来自所述第一 STA的第二服务维护帧时,所述 第一 AP根据所述第二服务维护帧, 更新所述第一 AP的服务信息表; 具体包括:
所述第一 AP根据所述第二服务维护帧中的第一服务维护项, 查 询所述第一 AP的服务信息表;
当存在匹配的第一服务信息时, 即, 所述第一 AP的服务信息表 中的第一服务信息的 BSSID与所述第二服务维护帧中的第一服务维 护项的 BSSID相同, 且所述第一服务信息的服务标识与所述第二服务 维护帧中的第一服务维护项的服务标识相同,且所述第一服务信息的 设备标识与所述第二服务维护帧中的第一服务维护项的设备标识相 同时, 在所述第一 AP的服务信息表中删除所述第一服务信息;
如果所述第二服务维护帧中还有第二服务维护项,则根据所述第 二服务维护帧中的第二服务维护项查询所述第一 AP的服务信息表, 当存在匹配的第二服务信息时, 则在所述第一 AP的服务信息表中删 除所述第二服务信息, 以此类推。
进一步可选的, 所述第二服务维护帧中的服务维护项中的 BSSID 和设备标识可以为空, 则所述第一 AP可以, 先获取 BSSID, 即所述第 一 AP的 MAC地址和设备标识, 即所述第一 STA的设备标识; 所述第 一 AP可以根据所述第一 STA的设备地址查询所述第一 AP的地址对应 关系表, 获得所述第一 STA的设备标识; 相应地,
所述第一 AP根据所述第一 AP的 MAC地址和所述第一 STA的设备 标识, 以及所述第二服务维护帧中的第一服务维护项的服务标识, 查 询所述第一 AP的服务信息表;
当存在匹配的第一服务信息时, 即, 所述第一服务信息的 BSSID 与所述第一 AP的 MAC地址相同, 且所述第一服务信息的服务标识与 所述第二服务维护帧中的第一服务维护项的服务标识相同,且所述第 一服务信息的设备标识与所述第一 STA的设备标识相同时, 在所述第 一 AP的服务信息表中删除所述第一服务信息;
如果所述第二服务维护帧中还有第二服务维护项,则根据所述第 一 AP的 MAC地址和所述第一 STA的设备标识, 以及所述第二服务维 护帧中的第二服务维护项的服务标识查询所述第一 AP的服务信息 表, 当存在匹配的第二服务信息时, 则在所述第一 AP的服务信息表 中删除所述第二服务信息, 以此类推。
如果所述第一 STA取消了已申明的所有服务,所述第一 AP可以将 分配给所述第一 STA的设备标识回收进设备标识池; 如果所述第一 STA取消的服务标识对应的服务, 没有其他 STA可提供了, 所述第一 AP可以将该良务标识回收进良务标识池。
909、 向所述第二 AP转发所述第二服务维护帧, 以使所述第二 AP 更新所述第二 AP的服务信息表。
当所述第一 AP感知所述第一 STA脱萬时, 所述第一 AP可以向第 二 AP发送第二服务维护帧, 其中包括 BSSID, 即所述第一 AP的 MAC 地址和所述第一 STA的设备标识, 以使所述第二 AP更新所述第二 AP 的服务信息表;
如果所述第一 AP接收到的来自所述第一 STA的第二服务维护帧 中的服务维护项中的 BSSID和设备标识为空,则所述第一 AP用获取的 BSSID, 即所述第一 AP的 MAC地址和所述第一 STA的设备标识更新 第二服务维护帧, 再向所述第二 AP转发更新后的第二服务维护帧。
所述第二 AP收到所述第二服务维护帧之后 , 执行的动作可以参 见所述第一 AP在 908中的动作, 在此不再赘述。
需要说明的是, 如果所述第一 AP存在可访问的相邻 AP, 则所述 第一 AP执行上述 906和 909更新可访问的相邻 AP的服务信息表; 如果 所述第一 AP不存在可访问的相邻 AP, 则无需执行上述 906和 909。
示例性的, 所述服务维护帧可以如图 29所示; 其中长度(length ) 可变, 用于表示所述服务维护帧中行为细节的长度。
进一步可选的, 所述第一 AP还可以维护其他可访问的相邻 AP扩 散的服务信息, 如图 9a所示, 所述方法还可以包括:
910: 所述第一 AP接收来自第二 AP的第三服务维护帧, 所述第三 服务维护帧包括维护状态和维护细节;
所述第三服务维护帧中的维护状态可以为第一维护状态, 相应 地, 维护细节中包括至少一条服务信息;
所述第三服务维护帧中的维护状态也可以为第二维护状态,相应 地, 维护细节中包括至少一个服务维护项; 所述服务维护项中包括 BSSID, 设备标识和 务标识。
911: 所述第一 AP根据所述第三服务维护帧, 更新所述第一 AP 的服务信息表。
当所述第三服务维护帧中的维护状态为第一维护状态时,则所述 第一 AP在所述第一 AP的服务信息表中记录所述第三服务维护帧中包 括的所述至少一条服务信息;
当所述第三服务维护帧中的维护状态为第二维护状态时,所述第 一 AP根据所述第三服务维护帧中的第一服务维护项, 查询所述第一 AP的服务信息表; 当存在匹配的第一服务信息时, 即, 所述第一 AP 的服务信息表中的第一服务信息的 BSSID与所述第三服务维护帧中 的第一服务维护项的 BSSID相同, 且所述第一服务信息的服务标识与 所述第三服务维护帧中的第一服务维护项的服务标识相同,且所述第 一服务信息的设备标识与所述第三服务维护帧中的第一服务维护项 的设备标识相同时, 在所述第一 AP的服务信息表中删除所述第一服 务信息; 如果所述第三服务维护帧中还有第二服务申明项, 则根据所 述第三服务维护帧中的第二服务维护项查询所述第一 AP的服务信息 表, 当存在匹配的第二服务信息时, 则在所述第一 AP的服务信息表 中删除所述第二服务信息, 以此类推。
本领域普通技术人员可以理解的是, 910和 911可以在 901 ~ 909 任一步之前或之后执行。
采用本发明实施例提供的服务注册的方法, 关联到第一 AP的第 一 STA可以在第一 AP上申明或取消服务信息, 第一 STA无需周期性监 听信道上其他设备的查找请求, 降低了第一 STA的资源开销和能耗; 第一 AP还可以将在所述第一 AP上申明的设备信息和服务信息扩散到 网络中可访问的相邻 AP, 也可以接收可访问的相邻 AP提供的服务信 息, 从而可以提供更大范围的服务发现功能, 向用户提供更丰富的服 务信息, 满足用户根据服务需求选择网络的需求。 图 10是本发明实施例提供的又一种服务注册的方法流程图,本实 施例中, 所述服务注册的方法由第一站点 STA实施, 如图 10所示, 所 述方法包括:
1001、第一站点 STA向第一接入点 AP发送服务通告请求帧,所述 服务通告请求帧中包括所述第一 STA的设备地址和至少一个服务申 明项, 所述服务申明项包括服务名称;
所述第一 STA关联到所述第一 AP后, 可以向所述第一 AP发送服 务通告请求帧, 向所述第一 AP注册服务。
所述第一 STA的设备地址通常为所述第一 STA的 MAC地址 ,所述 第一 STA的设备地址通常携带在所述服务通告请求帧的头部。
所述服务通告请求帧中还可以包括所述第一 STA的设备名称,设 备标识, 设备能力, 设备描述等。 所述第一 STA的设备名称可以是例 如, 打印机、 电视机等, 也可以是例如 1号咖啡馆, 2号票务中心等; 所述第一 STA的设备能力可以是例如支持 Wi-Fi直连, 支持蓝牙等, 还可进一步在设备能力中携带能力参数, 例如支持 Wi-Fi直连时, 携 带直连距离。 例如,
设备名称 设备能力
打印机 支持 Wi-Fi直连, 直连距离为 L;
2号票务中心 可上门服务; 所述服务申明项除了包括服务名称,还可以包括服务描述。例如, 上述 2号票务中心, 可提供如下服务:
服务名称 月良务描述
飞机票预售 仅售南方航空公司
火车票预售 仅售动车票
票务查询 三曰内
当所述第一 STA可以提供多项服务时, 所述第一 STA可以一次向 所述第一 AP注册多项服务, 则所述服务通告请求帧中包括多个服务 申明项; 所述第一 STA也可以分多次向所述第一 AP注册服务, 即每次 向所述第一 AP注册一项服务, 注册多次, 则每次所述服务通告请求 帧中仅包括一个月良务申明项。
可选的,如果所述第一 STA在向所述第一 AP注册服务,获得所述 第一 STA的设备标识后,所述第一 STA可以在后续向所述第一 AP注册 服务时, 在所述服务通告请求帧中携带所述第一 STA的设备标识。
示例性的, 所述服务通告请求帧可以如图 27所示; 其中, 长度 ( length )可变, 用于表示所述服务通告请求帧中行为细节的长度。
1002、 接收来自所述第一 AP的服务通告响应帧, 所述服务通告 响应帧中包括所述第一 STA的设备标识和所述至少一个良务申明项 中每个服务申明项对应的服务申明应答项;所述服务申明应答项中包 括服务标识和服务名称。
具体的,所述至少一个服务申明项中每个服务申明项对应的服务 申明应答项包括:
对应所述第一服务申明项的第一申明应答项,所述第一申明应答 项包括所述第一服务申明项的服务名称和第一服务标识;
以及, 如果还有第二服务申明项, 对应所述第二服务申明项的第 二申明应答项,所述第二申明应答项包括第二服务申明项的服务名称 和第二服务标识; 以此类推。
可选地, 所述良务通告响应帧中还可以包括所述第一 STA的设备 名称。
示例性的, 所述服务通告响应帧可以如图 28所示; 其中, 长度 ( length )可变, 用于表示所述服务通告响应帧中行为细节的长度。
可选的, 所述第一 STA收到所述服务通告响应帧后, 根据所述服 务通告响应帧, 记录所述所述第一 STA的设备标识, 以及每个服务申 明应答项。 所述第一 STA可以维护一张服务申明信息表, 所述服务申 明信息表中包括 BSSID, 设备标识, 服务名称和服务标识等。
可选地, 当所述第一 STA要取消已申明的服务时, 所述第一 STA 可以向所述第一 AP发送服务维护帧, 取消全部或部分已申明的服务。 如图 10a所示, 所述方法还包括:
1003、所述第一 STA向所述第一 AP发送第二服务维护帧,所述第 二服务维护帧中包括维护状态和维护细节;
具体的,所述第一 STA向所述第一 AP发送第二服务维护帧,所述 第二服务维护帧中的维护状态为第二维护状态,所述维护细节包括至 少一个服务维护项, 以使所述第一 AP根据所述第二服务维护帧, 更 新所述第一 AP的服务信息表, 并可选地向第二 AP转发所述第二服务 维护帧; 所述 务维护项包括 BSSID, 设备标识和良务标识。
可选地, 所述第一 STA删除所述服务申明信息表中所述至少一个 服务维护项中每个服务维护项对应的服务申明信息。
可选的, 所述良务维护项中的 BSSID和设备标识可以为空。
可选的, 第二服务维护帧中的服务维护项可以为空, 表示所述第 一 STA要取消已申明的全部服务。
可选地, 当所述第一 STA脱离所述第一 AP时, 所述第一 STA删除 所述服务申明信息表中的所有服务申明信息。采用本发明实施例提供 的服务注册的方法, 关联到第一 AP的第一 STA可以在第一 AP上申明 或取消自己的设备信息和服务信息, 通过第一 AP为用户提供服务信 息, 满足用户根据服务需求选择网络的需求; 第一 STA也无需周期性 监听信道上其他设备的查找请求, 降低了第一 STA的资源开销和能 耗。 图 11是本发明实施例提供的一种用于服务注册的第一接入点 AP 结构示意图, 用于实现本发明图 8和图 9所示的服务注册的方法。 如图 11所示, 所述第一 AP包括接收单元 1101 , 第一获取单元 1102, 第二获 取单元 1103, 记录单元 1104和发送单元 1105。 其中,
所述接收单元 1101 , 用于接收来自第一站点 STA的服务通告请求 帧; 所述服务通告请求帧中包括所述第一 STA的设备地址和至少一个 月良务申明项, 所述服务申明项包括服务名称。
所述第一 STA的设备地址通常为所述第一 STA的媒体访问控制 MAC地址,所述第一 STA的设备地址通常携带在所述服务通告请求帧 的头部。 所述服务通告请求帧中还可以包括所述第一 STA的设备名称,设 备能力,设备描述等。所述第一 STA的设备名称可以是例如,打印机、 电视机等, 也可以是例如 1号咖啡馆, 2号票务中心等; 所述第一 STA 的设备能力可以是例如支持 Wi-Fi直连, 支持蓝牙等, 还可进一步在 设备能力中携带能力参数, 例如支持 Wi-Fi直连时, 携带直连距离。 例如,
设备名称 设备能力
打印机 支持 Wi-Fi直连, 直连距离为 L;
2号票务中心 可上门服务;
所述服务申明项除了包括服务名称,还可以包括服务描述。例如, 上述 2号票务中心, 可提供如下服务:
服务名称 月良务描述
飞机票预售 仅售南方航空公司
火车票预售 仅售动车票
票务查询 三曰内
示例性的, 所述服务通告请求帧可以如图 27所示; 其中, 长度 ( length )可变, 用于表示所述服务通告请求帧中行为细节的长度。
所述第一获取单元 1102, 用于获取所述第一 STA的设备标识。 所述第一获取单元 1102具体用于,
根据所述第一 STA的设备地址,查询所述第一 AP的地址对应关系 表, 所述地址对应关系表中包括设备地址与设备标识的对应关系, 当所述第一 AP的地址对应关系表中一条已有地址对应关系的设 备地址与所述第一 STA的设备地址相同时, 获取所述已有地址对应关 系的设备标识, 即为所述第一 STA的设备标识;
当所述第一 AP的地址对应关系表中任意一条地址对应关系的设 备地址与所述第一 STA的设备地址都不相同时,从设备标识池中分配 所述第一 STA的设备标识, 并在所述地址对应关系表中记录所述第一 STA的设备地址与设备标识的地址对应关系。
例如,设备地址为 MAC1的 2号票务中心的设备标识 DI-1 ,设备地 址为 M AC2的打印机 1的设备标识为 DI-2。
可选的, 所述服务通告请求帧中还包括所述第一 STA的设备标 识, 所述第一获取单元具体还用于: 从所述服务通告请求帧中获取所 述第一 STA的设备标识。
所述第二获取单元 1103, 用于根据所述至少一个服务申明项, 获 取所述至少一个服务申明项中每个服务申明项对应的服务标识。
所述第二获取单元 1103具体用于,
所述第一 AP根据所述至少一个服务申明项中第一服务申明项的 服务名称, 查询所述第一 AP的服务信息表;
当所述第一 AP的服务信息表中任意一条服务信息的服务名称与 所述第一服务申明项的服务名称均不相同时,根据所述第一服务申明 项的服务名称从服务标识池中分配第一服务标识;
当所述第一 AP的服务信息表中存在一条已有服务信息的服务名 称与所述第一服务申明项的服务名称相同, 且所述已有服务信息的 BSSID与所述第一 AP的 MAC地址相同时, 获取所述已有服务信息的 服务标识, 即为所述第一服务申明项的服务名称对应的第一服务标 识。
如果还有第二服务申明项,则获取第二服务申明项的服务名称对 应的第二服务标识, 以此类推。
举例来说, 所述服务通告请求帧中包括两个服务申明项, 第一个 服务申明项的服务名称为 "飞机票预售" , 第二个服务申明项的服务 名称为 "火车票预售" , 则所述第一 AP根据 "飞机票预售" 获取服 务标识 SI-1 , 再根据 "火车票预售" 获取服务标识 SI-2。
所述记录单元 1104, 用于在所述第一 AP的服务信息表中记录所 述至少一个服务申明项对应的服务信息;所述服务信息包括基本服务 集标识 BSSID , 设备标识, 月良务标识和月良务申明项。
所述记录单元 1104具体用于,
获取第一服务信息,所述第一服务信息包括所述 AP的 MAC地址, 所述第一 STA的设备标识, 所述第一服务标识和所述第一服务申明 项;
在所述第一 AP的服务信息表中记录所述第一服务信息; 如果还有第二服务申明项, 则获取第二服务信息, 并在所述第一 AP的服务信息表中记录所述第二服务信息; 以此类推。
可选的, 服务信息还可以包括所述第一 STA的设备名称, 所述第 一 STA的设备能力, 网络访问策略。 网络访问策略可以表示 AP所在 BSS内的访问策略, 也可以是针对某项具体月良务的访问策略, 例如, API在公共网络, AP2在私有网络, API根据 AP2的访问策略可以访问 AP2所在的私有网络。
示例性的, 所述服务信息可以如图 23所示; 其中, BSSID为申明 该服务信息的 STA所关联 AP的 MAC地址; 例如本实施中, 为所述第 一 AP的 MAC地址。
所述发送单元 1105 , 用于向所述第一 STA返回服务通告响应帧, 所述良务通告响应帧中包括所述第一 STA的设备标识和所述至少一 个服务申明项对应的服务申明应答项;所述服务申明应答项包括服务 标识和服务名称。
所述至少一个服务申明项中每个服务申明项对应的服务申明应 答项, 包括:
对应所述第一服务申明项的第一申明应答项,所述第一申明应答 项包括所述第一服务申明项的服务名称和所述第一服务标识;
以及, 如果还有第二服务申明项, 对应所述第二服务申明项的第 二申明应答项,所述第二申明应答项包括第二服务申明项的服务名称 和所述第二服务标识; 以此类推。
可选地, 所述良务通告响应帧中还可以包括所述第一 STA的设备 名称。
示例性的, 所述服务通告响应帧可以如图 28所示; 其中, 长度 ( length )可变, 用于表示所述服务通告响应帧中行为细节的长度。
进一步可选的,如图 11a所示,所述第一 AP还包括维护单元 1106。 所述维护单元 1106, 用于生成第一服务维护帧, 所述第一服务维 护帧中包括第一维护状态和所述至少一个服务申明项中每个服务申 明项对应的服务信息;
所述发送单元 1105 , 还用于向第二 AP发送所述第一服务维护帧, 以使所述第二 AP更新所述第二 AP的服务信息表;
所述服务信息包括 BSSID, 设备标识, 服务标识和服务申明项。 所述第二 AP为所述第一 AP可访问的相邻 AP。
所述至少一个服务申明项中每个服务申明项对应的服务信息, 包 括:
对应所述第一服务申明项的第一服务信息;
以及, 如果还有第二服务申明项, 对应所述第二服务申明项的第 二服务信息; 以此类推。
所述接收单元 1101 ,还用于接收来自所述第一 STA的第二服务维 护帧,所述第二服务维护帧中包括第二维护状态和至少一个服务维护 项; 所述 务维护项包括 BSSID, 设备标识和良务标识。
相应地, 所述维护单元 1106, 还用于根据所述第二服务维护帧, 更新所述第一 AP的服务信息表。
如果所述第一 AP存在可访问的相邻 AP, 所述维护单元 1106, 还 用于向所述第二 AP转发所述第二服务维护帧, 以使所述第二 AP更新 所述第二 AP的服务信息表。
所述维护单元 1106具体用于,根据所述至少一个服务维护项中第 一服务维护项, 查询所述第一 AP的服务信息表; 当存在匹配的第一 服务信息时, 即, 所述第一 AP的服务信息表中的第一服务信息的 BSSID与所述第一服务维护项的 BSSID相同, 且所述第一服务信息的 服务标识与所述第一服务维护项的服务标识相同,且所述第一服务信 息的设备标识与所述第一服务维护项的设备标识相同时,在所述第一 AP的服务信息表中删除所述第一服务信息。
如果还有第二服务申明项,则根据第二服务维护项查询所述第一 AP的服务信息表, 当存在匹配的第二服务信息时, 则在所述第一 AP 的服务信息表中删除所述第二服务信息, 以此类推。
进一步可选的, 所述第二服务维护帧中的服务维护项中的 BSSID 和设备标识可以为空, 则所述维护单元 1106还用于获取 BSSID, 即所 述第一 AP的 MAC地址和设备标识, 即所述第一 STA的设备标识; 并 根据所述第一 AP的 MAC地址和所述第一 STA的设备标识, 以及所述 第二服务维护帧中的第一服务维护项的服务标识, 查询所述第一 AP 的服务信息表; 当存在匹配的第一服务信息时, 即, 所述第一服务信 息的 BSSID与所述第一 AP的 MAC地址相同, 且所述第一服务信息的 服务标识与所述第二服务维护帧中的第一服务维护项的服务标识相 同, 且所述第一服务信息的设备标识与所述第一 STA的设备标识相同 时, 在所述第一 AP的服务信息表中删除所述第一服务信息; 如果所 述第二服务维护帧中还有第二服务维护项, 则根据所述第一 AP的 MAC地址和所述第一 STA的设备标识 ,以及所述第二服务维护帧中的 第二服务维护项的服务标识查询所述第一 AP的服务信息表, 当存在 匹配的第二服务信息时, 则在所述第一 AP的服务信息表中删除所述 第二服务信息, 以此类推。
所述维护单元 1106, 还用于当感知所述第一 STA脱离时, 取消所 述第一 STA在所述第一 AP上已申明的全部服务。具体地,所述维护单 元 1106用于获取 BSSID, 即所述第一 AP的 MAC地址和设备标识, 即 所述第一 STA的设备标识, 并根据所述第一 AP的 MAC地址和所述第 一 STA的设备标识, 查询所述第一 AP的服务信息表; 将所述第一 AP 的服务信息表中, BSSID与所述第一 AP的 MAC地址相同, 且设备标 识与所述第一 STA的设备标识相同的所有服务信息删除。
所述维护单元 1106可以通过所述第一获取单元 402获得所述第一 STA的设备标识。
所述接收单元 1101 , 还用于接收来自第二 AP的第三服务维护帧, 所述第三服务维护帧包括维护状态和维护细节
相应地, 所述维护单元 1106, 还用于根据所述第三服务维护帧, 更新所述第一 AP的服务信息表。
所述第三服务维护帧中的维护状态可以为第一维护状态, 相应 地, 维护细节中包括至少一条服务信息;
所述第三服务维护帧中的维护状态也可以为第二维护状态,相应 地, 所述维护细节中包括至少一个服务维护项。
所述维护单元 1106, 具体用于
当所述第三服务维护帧中的维护状态为第一维护状态时,则所述 AP在所述第一 AP的服务信息表中记录所述第三服务维护帧中包括的 所述至少一条服务信息;
当所述第三服务维护帧中的维护状态为第二维护状态时,所述第 一 AP根据所述第三服务维护帧中的第一服务维护项, 查询所述第一 AP的服务信息表; 当存在匹配的第一服务信息时, 即, 所述第一 AP 的服务信息表中的第一服务信息的 BSSID与所述第三服务维护帧中 的第一服务维护项的 BSSID相同, 且所述第一服务信息的服务标识与 所述第三服务维护帧中的第一服务维护项的服务标识相同,且所述第 一服务信息的设备标识与所述第三服务维护帧中的第一服务维护项 的设备标识相同时, 在所述第一 AP的服务信息表中删除所述第一服 务信息; 如果所述第三服务维护帧中还有第二服务申明项, 则根据所 述第三服务维护帧中的第二服务维护项查询所述第一 AP的服务信息 表, 当存在匹配的第二服务信息时, 则在所述第一 AP的服务信息表 中删除所述第二服务信息, 以此类推。
示例性的, 所述服务维护帧可以如图 29所示; 其中长度(length ) 可变, 用于表示所述服务维护帧中行为细节的长度。
可选地, 所述第一 AP还包括标识回收单元, 用于回收设备标识 和月良务标识。
所述标识回收单元具体用于当所述第一 STA取消了已申明的所 有服务, 将分配给所述第一 STA的设备标识回收进设备标识池; 当所 述第一 STA取消的服务标识对应的服务, 没有其他 STA提供时, 将所 述月良务标识回收进良务标识池。
需要说明的是, 所述第一 AP上还包括天线, 用于发送和接收无 线信号; 所述天线与所述接收单元 1101和所述发送单元 1105相连。 图 12是本发明实施例提供的一种用于服务注册的第一站点 STA 结构示意图, 用于实现本发明图 10所示的服务注册的方法。 如图 12 所示, 所述第一 STA包括发送单元 1201 , 接收单元 1202和记录单元 1203。 其中,
所述发送单元 1201 , 用于向第一 AP发送服务通告请求帧, 所述 服务通告请求帧中包括所述第一 STA的设备地址和至少一个服务申 明项, 所述服务申明项包括服务名称;
所述第一 STA关联到所述第一 AP后, 可以向所述第一 AP发送服 务通告请求帧, 向所述第一 AP注册服务。
所述第一 STA的设备地址通常为所述第一 STA的媒体访问控制 MAC地址,所述第一 STA的设备地址通常携带在所述服务通告请求帧 的头部。
所述服务通告请求帧中还可以包括所述第一 STA的设备名称,设 备能力,设备描述等。所述第一 STA的设备名称可以是例如,打印机、 电视机等, 也可以是例如 1号咖啡馆, 2号票务中心等; 所述第一 STA 的设备能力可以是例如支持 Wi-Fi直连, 支持蓝牙等, 还可进一步在 设备能力中携带能力参数, 例如支持 Wi-Fi直连时, 携带直连距离。 例如,
设备名称 设备能力
打印机 支持 Wi-Fi直连, 直连距离为 L;
2号票务中心 可上门服务;
所述服务申明项除了包括服务名称,还可以包括服务描述。例如, 上述 2号票务中心, 可提供如下服务:
服务名称 月良务描述
飞机票预售 仅售南方航空公司
火车票预售 仅售动车票 票务查询 三曰内
当所述第一 STA可以提供多项服务时, 所述第一 STA可以一次向 所述第一 AP注册多项服务, 则所述服务通告请求帧中包括多个服务 申明项; 所述第一 STA也可以分多次向所述第一 AP注册服务, 即每次 向所述第一 AP注册一项服务, 注册多次, 则每次所述服务通告请求 帧中仅包括一个月良务申明项。
示例性的, 所述服务通告请求帧可以如图 27所示; 其中, 长度 ( length )可变, 用于表示所述服务通告请求帧中行为细节的长度。
所述接收单元 1202, 用于接收来自所述第一 AP的服务通告响应 帧, 所述服务通告响应帧中包括所述第一 STA的设备标识和所述至少 一个服务申明项中每个服务申明项对应的服务申明应答项;所述服务 申明应答项中包括服务标识和服务名称;
所述至少一个服务申明项中每个服务申明项对应的服务申明应 答项包括:
对应所述第一服务申明项的第一申明应答项,所述第一申明应答 项包括所述第一服务申明项的服务名称和第一服务标识;
以及, 如果还有第二服务申明项, 对应所述第二服务申明项的第 二申明应答项,所述第二申明应答项包括第二服务申明项的服务名称 和第二服务标识; 以此类推。
可选地, 所述良务通告响应帧中还可以包括所述第一 STA的设备 名称。
示例性的, 所述服务通告响应帧可以如图 28所示; 其中, 长度 ( length )可变, 用于表示所述服务通告响应帧中行为细节的长度。
所述记录单元 1203, 用于根据所述服务通告响应帧, 记录所述第 一 STA的设备标识, 以及每个服务申明应答项。 所述第一 STA可以维护一张服务申明信息表,所述服务申明信息 表中包括 BSSID, 设备标识, 服务名称和服务标识等。
所述记录单元 1203, 具体用于在所述服务申明信息表中记录 BSSID, 即所述第一 AP的 MAC地址, 所述第一 STA的设备标识, 所 述第一申明应答项的服务名称和第一服务标识;如果还有第二服务申 明项, 则记录 BSSID, 即所述第一 AP的 MAC地址, 所述第一 STA的 设备标识, 所述第二申明应答项的服务名称和第二服务标识; 以此类 推。
进一步可选的, 如图 12a所示, 所述第一 STA还包括信息维护单 元 1204;
所述发送单元 1201, 还用于向所述第一 AP发送第二服务维护帧, 所述第二服务维护帧中包括维护状态和维护细节;
具体的, 所述发送单元 1201 , 用于向所述第一 AP发送第二服务 维护帧, 所述第二服务维护帧中的维护状态为第二维护状态, 所述维 护细节包括至少一个服务维护项, 以使所述第一 AP根据所述第二服 务维护帧, 更新所述第一 AP的服务信息表, 并可选地向第二 AP转发 所述第二服务维护帧; 所述服务维护项包括 BSSID, 设备标识和服务 标识。
所述月良务维护项中的 BSSID和设备标识可以为空。
所述信息维护单元 1204,用于删除所述服务申明信息表中要取消 的服务申明信息; 具体的, 用于删除所述第二服务维护帧中所述至少 一个服务维护项中每个服务维护项对应的服务申明信息。
可选地, 所述信息维护单元 1204, 还用于当所述第一 STA脱离所 述第一 AP时, 删除所述服务申明信息表中的所有服务申明信息。
需要说明的是, 所述第一 STA上还包括天线, 用于发送和接收无 线信号; 所述天线与所述接收单元 1201和所述发送单元 1202相连。 图 13是本发明实施例提供的一种服务注册系统结构示意图,所述 系统包括如本发明中图 11所示的第一接入点 AP和如本发明图 12所示 的第一站点 STA;
可选的, 如图 13a所示, 所述系统还可以包括第二 AP; 相应地, 所述第一 AP如本发明图 11a所示, 所述第一 STA如图 12a所示。
所述第二 AP可以是所述第一 AP通过无线方式可达, 还可以是所 述第一 AP通过有线方式可达, 只要所述第一 AP与所述第二 AP之间可 以进行通信即可, 本发明对此不作限定。
需要说明的是, 所述第一 AP可能存在多个可访问的相邻 AP, 即 如图 13a所示, 存在多个第二 AP, 图 13a中示意性地示出两个第二 AP。
图 14为本发明实施例提供的一种服务注册的信息交互示意图,基 于图 13a所示的系统,进一步介绍本发明实施例提供的服务注册的方 法。 如图 14所示, 所述月良务注册的方法包括:
1401、第一站点 STA向第一接入点 AP发送服务通告请求帧;所述 服务通告请求帧中包括所述第一 STA的设备地址和至少一个服务申 明项;
具体可以参见本发明实施例中的 1001 , 在此不再赘述。
1402、 所述第一 AP收到所述服务通告请求帧后, 获取设备标识 和服务标识, 并在所述第一 AP的服务信息表中记录对应的服务信息; 具体的,所述第一 AP根据所述第一 STA的设备地址,获取所述第 一 STA的设备标识; 根据所述至少一个服务申明项, 获取所述至少一 个服务申明项中每个服务申明项对应的服务标识; 并在所述第一 AP 的服务信息表中记录所述至少一个服务申明项对应的服务信息,所述 服务信息包括基本服务集标识 BSSID, 设备标识, 服务标识和服务申 明项。
具体可以参见本发明实施例中的 802和 803, 在此不再赘述。
1403、所述第一 AP向所述第一 STA返回服务通告响应帧,所述服 务通告响应帧中包括所述第一 STA的设备标识和所述至少一个服务 申明项对应的服务申明应答项;
所述服务申明应答项包括服务标识和服务名称;
具体可以参见本发明实施例中的 805, 在此不再赘述。
1404、 所述第一 AP向第二 AP发送第一服务维护帧, 所述第一服 务维护帧中包括维护状态和维护细节;所述第一服务维护帧中的维护 状态为第一维护状态,维护细节包括所述至少一个服务申明项中每个 服务申明项对应的服务信息, 以使所述第二 AP更新所述第二 AP的服 务信息表。
具体可以参见本发明实施例中的 906, 在此不再赘述。
1405、 所述第二 AP收到所述第一服务维护帧之后, 根据所述第 一服务维护帧更新所述第二 AP的服务信息表;
所述第二 AP根据所述第一服务维护帧的维护状态为第一维护状 态, 在所述第二 AP的服务信息表记录所述第一服务维护帧中包括的 服务信息。
具体可以参见本发明实施例中的 906, 在此不再赘述。
1406、 当所述第一 STA要取消已申明的服务时, 所述第一 STA向 所述第一 AP发送第二服务维护帧;
所述第二服务维护帧中包括第二维护状态和至少一个服务维护 项; 所述服务维护项包括 BSSID, 设备标识和服务标识, 可以标识所 述第一 STA已申明的一个服务。
具体可以参见本发明实施例中的 1003, 在此不再赘述。 1407、 所述第一 AP收到所述第二服务维护帧之后, 更新所述第 一 AP的服务信息表;
具体的, 所述第一 AP根据所述第二服务维护帧中的服务维护项 更新所述第一 AP的服务信息表.
具体可以参见本发明实施例中的 908, 在此不再赘述。
1408、 所述第一 AP向第二 AP转发所述第二服务维护帧; 具体可以参见本发明实施例中的 909, 在此不再赘述。
1409、 所述第二 AP收到所述第二服务维护帧之后, 更新所述第 二 AP的服务信息表。
所述第二 AP更新所述第二 AP的服务信息表的过程与所述第一 AP更新所述第一 AP的服务信息表的过程相同, 具体可以参见本发明 实施例中的 908 , 所述第一 AP更新所述第一 AP的服务信息表的过程。
采用本发明实施例提供的服务注册的技术方案, 关联到第一 AP 的第一 STA可以在第一 AP上申明或取消服务信息, 第一 STA无需周期 性监听信道上其他设备的查找请求, 降低了第一 STA的资源开销和能 耗; 第一 AP还可以将在所述第一 AP上申明的设备信息和服务信息扩 散到网络中可访问的相邻 AP, 也可以接收可访问的相邻 AP提供的服 务信息, 从而可以提供更大范围的服务发现功能, 向用户提供更丰富 的服务信息, 满足用户根据服务需求选择网络的需求。 同时, AP上 维护的服务信息,是经过验证关联到 AP上的 STA发布的,保证了安全 性, 从而保证了服务的可靠性。 基于本发明实施例提供的服务注册和发现的技术方案,本发明还 可以通过 AP代理发现提供直连服务的 STA,并管理 STA之间的直连通 信。 需要说明的是, 本发明实施例中以设备能力为 "支持 WiFi直连" 为例, 但是对于通过其他技术, 例如蓝牙的直连服务也同样适用, 本 发明对此不作限定。
需要说明的是, 本发明实施例中, STA可以通过包含服务请求状 态的直连服务请求帧, 向 AP请求获取直连服务, 或者关闭直连服务。 其中, 服务请求状态包括第一请求状态和第二请求状态, 例如第一请 求状态可称为使能( enable ) ,第二请求状态可称为去使能( disable )。 当直连服务请求帧中的服务请求状态为第一请求状态时,表示 STA请 求获取直连服务; 当服务请求状态为第二请求状态时, 表示 STA请求 关闭直连服务。 服务请求状态可以用字符串标识, 例如 enable表示第 一请求状态, disable表示第二请求状态; 也可以用数字标识, 例如用 1表示第一请求状态, 用 0表示第二请求状态; 本发明对此不作限定。
图 15是本发明实施例提供的一种管理直连服务的方法流程图,本 实施例中, 所述管理直连月良务的方法由第一接入点 AP实施。 如图 15 所示, 所述方法包括:
1501、 第一接入点 AP接收第一站点 STA发送的直连服务请求帧, 所述直连服务请求帧中包括服务请求状态和服务名称;
当所述服务请求状态为第一请求状态时, 所述第一 AP执行 1502 - 1507; 当所述服务请求状态为第二请求状态时, 所述第一 AP 执行 1508 ~ 1509。
所述直连服务请求帧中还可以包括设备名称。
示例性的, 所述直连服务请求帧可以如图 30所示; 其中, 长度 ( length )可变, 用于表示直连服务请求帧中行为细节的长度。
本实施例中,所述第一 STA在扫描获得可用 AP及其服务目录信息 后,所述第一 STA可以根据服务目录信息, 向所述第一 AP请求直连服 务。
所述直连服务请求帧中的服务名称, 也可以是服务标识, 例如当 服务标识全局统一分配时, 就可以根据服务标识请求获取直连服务。 本发明实施例中, 以服务名称为例进行说明, 但并不作为对本发明的 限定。
1502、 所述第一 AP获取第二 STA的设备地址;
具体的,
所述第一 AP根据所述直连服务请求帧中的服务名称查询所述 AP的服务信息表;
当所述第一 AP的服务信息表中任意一条服务信息的服务名称与 所述第一直连服务请求帧中的服务名称均不相同时, 直连请求失败, 结束;
当所述第一 AP的服务信息表中存在一条已有服务信息的服务名 称与所述直连服务请求帧中的服务名称相同,且所述已有服务信息中 设备能力为支持 Wi-Fi直连时,获取所述已有服务信息中的设备标识, 即为所述第二 STA的设备标识; 否则, 直连请求失败, 结束;
根据所述第二 STA的设备标识,获取所述第二 STA的设备地址。 可选的, 当所述直连服务请求帧中包括设备名称时, 也可以获取 所述直连服务请求帧中的设备标识, 即为所述第二 STA的设备标识; 根据所述第二 STA的设备标识, 获取所述第二 STA的设备地址。
由于直连服务对设备之间的距离有要求, 因此只由关联到所述第 一 AP的 STA提供。 所述第一 AP查询所述 AP的服务信息表时, 还需同 时满足 BSSID与所述第一 AP的 MAC地址相同。
所述第一 AP根据所述第二 STA的设备标识获取所述第二 STA的 设备地址具体包括: ,所述第一 AP根据所述第二 STA的设备标识查询 所述第一 AP的地址对应关系表,获取所述第二 STA的设备地址;所述 地址对应关系表中包括设备地址与设备标识的对应关系。 1503、所述第一 AP根据所述第二 STA的设备地址,探测所述第 一 STA与第二 STA之间的距离;
1504、 当所述第一 STA与所述第二 STA之间的距萬大于直连距离 时, 直连请求失败, 结束;
1505、 当所述第一 STA与所述第二 STA之间的距离不大于直连距 离时, 所述第一 AP查询所述第一 AP的直连服务管理表;
所述直连距离可以为所述第一 AP上预先设定的距离, 也可以是 所述第二 STA申明的设备能力中携带的, 本发明对此不作限定。
所述直连服务管理表中包括服务名称和组地址,还可以包括信道 信息, 组标识, 务标识和设备名称;
示例性的, 所述直连服务管理表可以如图 31所示。
所述组地址通常是提供直连服务的 STA的设备地址。
1506、 当所述第一 AP的直连服务管理表中存在一条已有直连服 务管理信息的服务名称与所述直连服务请求帧中的服务名称相同,且 所述已有直连服务管理信息的组地址与所述第二 STA的设备地址相 同时, 所述第一 AP向所述第一 STA发送直连服务响应帧; 地址, 还可以包括组标识和信道信息。
1507、 否则, 所述第一 AP在所述第一 AP的直连服务管理表中记 录第一直连服务管理信息,所述第一直连服务管理信息包括所述直连 服务请求帧中的服务名称和所述第二 STA的设备地址; 并向所述第一 STA发送直连服务响应帧;
所述直连服务响应帧中包括所述第二 STA的设备地址。
所述第一 AP向所述第一 STA发送所述直连服务响应帧 ,用于建议 所述第一 STA与所述第二 STA建立直连服务; 但是所述第一 STA是否 与所述第二 STA建立直连服务, 可以由所述第一 STA决定, 或所述第 一 STA与所述第二 STA协商确定。
所述第一 AP还可以为所述第一 STA分配用于直连通信的无线信 道, 所述第一直连服务管理信息还可以包括第一信道信息, 所述第一 信道信息包括所述第一 AP为所述第一 STA分配的用于直连通信的无 线信道的信息, 所述第一直连服务响应帧中还包括所述第一信道信 所述第一 AP还可以为所述直连服务请求分配第一组标识, 所述 第一组标识与所述第二 STA的设备地址对应; 相应地, 所述第一直连 月良务管理信息还可以包括所述第一组标识,所述直连良务响应帧中还 包括所述第一组标识。
需要说明的是, 一个组标识可以对应多个提供相同服务的 STA的 设备地址。
示例性的, 所述直连月良务响应帧可以如图 32所示; 其中, 长度 ( length )可变, 用于表示直连服务响应帧中行为细节的长度。
由于无线信号间容易相互干扰, 无线信道资源有限, 由第一 AP 分配直连服务的信道信息,可以避免 STA间的直连通信与所述第一 AP 所在信道的信号相互干扰, 保证通信质量; 第一 AP也可以不分配信 道, STA间的直连通信可以在特定的信道上进行, 例如目前 WiFi直连 技术使用的 2.4G信道 1、 6或 11; 或者也可以由 STA间协商选择信道建 立直连服务, 本发明对此不作限定。
当所述第一 STA收到所述直连良务响应帧后, 就可以从所述直连 服务响应帧中获取组地址和信道信息, 在对应的信道上与所述第二 STA建立直连, 继而进行数据交互。
需要说明的是, 具体实现中, 可以有多种方式区分所述直连服务 响应帧表示请求成功还是失败。可以在所述直连服务响应帧中还包括 状态标识, 例如状态标识为 0表示失败, 状态标识为 1表示成功; 也可 以通过所述直连服务响应帧中的组标识来表示, 例如组标识为 -1时表 示失败; 也可以在直连服务响应帧中, 长度为 0表示失败, 即组标识, 组地址和信道信息均为空; 本发明实施例对此不作限定。
当所述服务请求状态为第二请求状态时, 所述第一 AP执行如下 1508 ~ 1509:
1508、 所述第一 AP根据所述直连服务请求帧查询所述第一 AP的 直连服务管理表;
所述直连服务管理表中包括服务名称和组地址,还可以包括信道 信息, 组标识和设备标识;
所述组地址通常是提供直连服务的 STA的设备地址。
1509、 当所述第一 AP的直连服务管理表中存在一条已有直连服 务管理信息的服务名称与所述第二直连服务请求帧中的服务名称相 同,且所述已有直连服务管理信息的组地址与所述第一 STA的设备地 址相同时, 将所述已有直连服务管理信息从所述第一 AP的直连服务 管理表中删除;
可选的, 所述第一 AP可以将所述已有直连服务管理信息中组标 识回收进组标识池,将所述已有直连月良务管理信息中信道信息对应的 信道资源回收。
可选的, 所述第一 AP在更新了直连服务管理表之后, 可以向所 述第一 STA返回一个应答消息, 例如 ACK ( affirmative
acknowledgement, 肯定应答 )消息或 NACK( negative acknowledgment, 否定回答) 消息。
图 16是本发明实施例提供的一种获取直连服务的方法流程图,本 实施例中, 所述获取直连服务的方法由第一站点 STA实施。 如图 16所 示, 所述方法包括:
1601、第一站点 STA向接入点第一 AP发送直连服务请求帧,所述 直连服务请求帧中包括服务请求状态和服务名称;
所述直连服务请求帧中的服务名称, 也可以是服务标识, 例如当 服务标识全局唯一时, 就可以根据服务标识请求获取直连服务。 本发 明实施例中,以服务名称为例进行说明,但并不作为对本发明的限定。
当所述直连服务请求帧中的服务请求状态为第一请求状态时,用 于所述第一 STA向所述第一 AP请求获取直连服务。所述第一 STA可以 在扫描获得可用 AP及其服务目录信息后, 根据服务标识, 向所述第 一 AP请求直连服务。
可选的, 当所述第一 STA在通过如本发明中图 5所示的服务发现 的方法获取到服务信息后, 期望与支持 Wi-Fi直连的某个设备建立直 连服务时, 所述第一 STA可以在直连服务请求帧中进一步携带该设备 的设备名称或者设备标识, 向所述第一 AP请求与该设备建立直连服 务。 本发明实施例中, 以设备名称为例进行说明, 但并不作为对本发 明的限定。
当所述直连服务请求帧中的服务请求状态为第二请求状态时,用 于所述第一 STA向所述第一 AP请求关闭所述第一 STA提供的某个直 连服务, 使所述第一 AP删除相关的直连服务管理信息, 收回组标识 和信道资源, 具体可以参见如图 15所示的管理直连服务的方法, 在此 不再赘述。 当支持 WiFi直连功能的 STA不处于工作状态时, 通过关闭 WiFi直连服务,可以降低设备的资源消耗,让出可信道资源。可选的, 当所述服务请求状态为第二请求状态时, 所述第一 STA接收所述第一 AP返回的应答消息,例如 ACK ( affirmative acknowledgement, 肯定应 答) 消息或 NACK ( negative acknowledgment,否定回答) 消息。
示例性的, 所述直连服务请求帧可以如图 30所示; 其中, 长度 ( length )可变, 用于表示直连服务请求帧中行为细节的长度。
当所述服务请求状态为第一请求状态时, 执行 1602 ~ 1603。
1602、 所述第一 STA接收所述第一 AP返回的直连服务响应帧; 所述直连良务响应帧中包括组地址,还可以包括组标识和信道信 所述组地址通常为提供直连服务的 STA的设备地址。
示例性的, 所述直连月良务响应帧可以如图 32所示; 其中, 长度 ( length )可变, 用于表示直连服务响应帧中行为细节的长度。
1603、 当根据所述直连服务响应帧确定直连请求成功时, 所述第 一 STA与所述直连月良务响应帧中组地址对应的第二 STA建立直连月^ 务;
可选地, 如果所述直连服务响应帧中还包括信道信息, 所述第一 STA与所述直连良务响应帧中组地址对应的第二 STA建立直连 务 具体为: 所述第一 STA在所述信道信息对应的无线信道上与所述第二 STA建立直连服务。
由于无线信号间容易相互干扰, 无线信道资源有限, 由第一 AP 分配直连服务的信道信息,可以避免 STA间的直连通信与所述第一 AP 所在信道的信号相互干扰, 保证通信质量; 第一 AP也可以不分配信 道, STA间的直连通信可以在特定的信道上进行, 例如目前 WiFi直连 技术使用的 2.4G信道 1、 6或 11; 或者也可以由 STA间协商选择信道建 立直连服务, 本发明对此不作限定。
所述第一 STA与所述第二 STA建立直连后, 可以进行数据交互。 当根据所述直连服务响应帧确定直连请求失败时, 结束; 需要说明的是, 具体实现中, 可以有多种方式区分所述直连服务 响应帧表示请求成功还是失败。可以在所述直连服务响应帧中还包括 状态标识, 例如状态标识为 0表示失败, 状态标识为 1表示成功; 也可 以通过所述直连服务响应帧中的组标识来表示, 例如组标识为 -1时表 示失败; 也可以直连良务响应帧中, 长度为 0表示失败, 即组标识, 组地址和信道信息均为空; 本发明实施例对此不作限定。 如图 17所示,是本发明实施例提供的一种用于获取直连服务的第 一站点 STA结构示意图, 所述第一 STA包括发送单元 1701 , 接收单元 1702和服务建立单元 1703。 其中,
所述发送单元 1701 , 用于向第一接入点 AP发送直连服务请求帧, 所述直连服务请求帧中包括服务请求状态和服务名称;
所述直连服务请求帧中的服务名称, 也可以是服务标识, 例如当 服务标识全局唯一时, 就可以根据服务标识请求获取直连服务。 本发 明实施例中,以服务名称为例进行说明,但并不作为对本发明的限定。
示例性的, 所述直连服务请求帧可以如图 30所示; 其中, 长度 ( length )可变, 用于表示直连服务请求帧中行为细节的长度。
当所述服务请求状态为第一请求状态, 所述第一 STA在扫描获 得可用 AP及其服务目录信息后, 可以根据服务标识, 向所述第一 AP 请求直连服务。 可选的, 所述直连服务请求帧中还可以包括设备名称 或设备标识。 当所述第一 STA在通过如本发明图 5所示的服务发现的 方法获取到服务信息后, 期望与支持 Wi-Fi直连的某个设备建立直连 服务时, 所述第一 STA可以在直连服务请求帧中进一步携带该设备的 设备名称或设备标识, 向所述第一 AP请求与该设备建立直连服务。
所述接收单元 1702, 用于接收所述第一 AP返回的直连服务响应 帧; 所述直连良务响应帧中包括组地址,还可以包括组标识和信道信 所述组地址通常为提供直连服务的 STA的设备地址。
由于无线信号间容易相互干扰, 无线信道资源有限, 由第一 AP 分配直连服务的信道信息,可以避免 STA间的直连通信与所述第一 AP 所在信道的信号相互干扰, 保证通信质量; 第一 AP也可以不分配信 道, STA间的直连通信可以在特定的信道上进行, 例如目前 WiFi直连 技术使用的 2.4G信道 1、 6或 11; 或者也可以由 STA间协商选择信道建 立直连服务, 本发明对此不作限定。
示例性的, 所述直连月良务响应帧可以如图 32所示; 其中, 长度 ( length )可变, 用于表示直连服务响应帧中行为细节的长度。
所述服务建立单元 1703,用于当根据所述直连服务响应帧确定直 连请求成功时, 与所述直连良务响应帧中组地址对应的第二 STA建立 直连服务;
可选地, 如果所述直连服务响应帧中还包括信道信息, 所述服务 建立单元 1703具体用于在所述信道信息对应的无线信道上与所述第 二 STA建立直连服务。
可选地, 所述第一 STA还包括判断单元, 用于根据所述直连服务 响应帧判断直连服务请求是否成功。
具体实现中, 可以有多种方式来判读直连服务请求是否成功。 可 以在所述直连良务响应帧中还包括状态标识, 例如状态标识为 0表示 失败, 状态标识为 1表示成功; 也可以通过所述直连良务响应帧中的 组标识来表示, 例如组标识为 - 1时表示失败; 也可以在如图所示的直 连服务响应帧中, 长度为 0表示失败, 即组标识, 组地址和信道信息 均为空; 本发明实施例对此不作限定。
当所述服务请求状态为第二请求状态时, 用于所述第一 STA向所 述第一 AP请求关闭所述第一 STA提供的某个直连服务, 使所述第一 AP删除相关的直连服务管理信息, 收回组标识和信道资源, 具体可 以参见如图 15所示的管理直连服务的方法, 在此不再赘述。 当支持 WiFi直连功能的 STA不处于工作状态时, 通过关闭 WiFi直连服务, 可 以降低设备的资源消耗, 让出信道资源。
可选地, 当所述服务请求状态为第二请求状态时, 所述接收单元 1702, 还用于接收所述 AP返回的应答消息, 例如 ACK或 NACK。
需要说明的是, 所述第一 STA上还包括天线, 用于发送和接收无 线信号; 所述天线与所述发送单元 1701和所述接收单元 1702相连。 如图 18所示,是本发明实施例提供的一种用于管理直连服务的第 一接入点 AP结构示意图, 所述第一 AP包括接收单元 1801 , 第一获取 单元 1802, 探测单元 1803, 查询单元 1804, 第二获取单元 1805和发送 单元 1806。 其中,
所述接收单元 1801 , 用于接收第一站点 STA的直连服务请求帧; 所述直连服务请求帧中包括服务请求状态和服务名称;还可以包 括设备名称。
所述直连服务请求帧中的服务名称和设备名称,也可以是服务标 识和设备标识; 例如当 务标识和设备标识是全局统一分配时, 就可 以根据服务标识和设备标识请求获取直连服务。 本发明实施例中, 以 服务名称和设备名称为例进行说明, 但并不作为对本发明的限定。
示例性的, 所述直连服务请求帧可以如图 30所示; 其中, 长度 ( length )可变, 用于表示直连服务请求帧中行为细节的长度。
所述第一获取单元 1802,用于当所述服务请求状态为第一请求状 态时, 获取第二 STA的设备地址;
所述第一获取单元 1802具体用于, 根据所述直连服务请求帧中 的服务名称查询所述第一 AP的服务信息表; 当所述第一 AP的服务 信息表中存在一条已有服务信息的服务名称与所述直连服务请求帧 中的服务名称相同, 且所述已有服务信息中设备能力为支持 Wi-Fi直 连时, 获取所述已有服务信息中的设备标识, 即为所述第二 STA的 设备标识; 根据所述第二 STA的设备标识, 获取所述第二 STA的设 备地址;
或者, 当所述直连服务请求帧中包括设备名称时, 获取所述直连 服务请求帧中的设备标识, 即为所述第二 STA的设备标识; 根据所述 第二 STA的设备标识, 获取所述第二 STA的设备地址。 由于直连服务 对设备之间的距离有要求, 因此只由关联到所述第一 AP的 STA提供。 所述第一 AP在查询所述第一 AP的服务信息表时, 均要同时满足 BSSID与所述第一 AP的 MAC地址相同。
所述第一获取单元 1802, 根据所述第二 STA的设备标识获取所 述第二 STA的设备地址具体包括: 根据所述第二 STA的设备标识查 询所述第一 AP的地址对应关系表, 获取所述第二 STA的设备地址; 所述地址对应关系表中包括设备地址与设备标识的对应关系。
所述探测单元 1803,用于根据所述第一获取单元 1802获取的所述 第二 STA的设备地址,探测所述第一 STA与所述第二 STA之间的距离; 所述查询单元 1804, 用于查询所述第一 AP的直连服务管理表; 示例性的, 所述直连服务管理表可以如图 31所示。
所述查询单元 1804, 具体用于当服务请求状态为第一请求状态 时, 当所述探测单元 1803探测到的所述第一 STA与所述第二 STA之间 的距离不大于直连距离时,根据所述直连服务请求帧中的服务名称和 所述第二 STA的设备地址查询所述第一 AP的直连服务管理表;
所述直连服务管理表中包括服务名称和组地址,还可以包括信道 信息, 组标识, 务标识和设备名称;
所述组地址通常是提供直连服务的 STA的设备地址。
所述直连距离可以为所述第一 AP上预先设定的距离, 也可以是 所述第二 STA申明的设备能力中携带的, 本发明对此不作限定。
所述第二获取单元 1805 , 用于为所述第一 STA的直连服务请求, 获取直连服务管理信息; 具体用于,
当所述第一 AP的直连服务管理表中存在一条已有直连服务管理 信息的服务名称与所述直连服务请求帧中的服务名称相同,且所述已 有直连服务管理信息的组地址与所述第二 STA的设备地址相同时, 获 取所述已有直连服务管理信息;
当所述第一 AP的直连服务管理表中任意一条直连服务管理信息 的服务名称和组地址与所述直连服务请求帧中的服务名称和所述第 二 STA的设备地址不同时, 获取第一直连服务管理信息, 并在所述第 一 AP的直连服务管理表中记录所述第一直连服务管理信息; 所述第 一直连服务管理信息包括所述直连服务请求帧中的服务名称和所述 第二 STA的设备地址; 所述直连服务管理信息还可以包括第一组标识 和第一信道信息。
所述第一信道信息包括所述第一 AP为所述第一 STA分配的用于 直连通信的无线信道的信息; 所述第一组标识与所述第二 STA的设备 地址对应, 是所述第一 AP为所述第一 STA的直连服务请求分配组标 识; 需要说明的是, 一个组标识可以对应多个提供相同服务的 STA的 设备地址。
所述发送单元 1806,用于根据所述获取单元 1805获取的直连服务 管理信息, 向所述第一 STA发送直连服务响应帧 ;
所述直连良务响应帧中包括组地址,还可以包括组标识和信道信 由于无线信号间容易相互干扰, 无线信道资源有限, 由第一 ΑΡ 分配直连服务的信道信息,可以避免 STA间的直连通信与所述第一 ΑΡ 所在信道的信号相互干扰, 保证通信质量; 第一 ΑΡ也可以不分配信 道, STA间的直连通信可以在特定的信道上进行, 例如目前 WiFi直连 技术使用的 2.4G信道 1、 6或 11; 或者也可以由 STA间协商选择信道建 立直连服务, 本发明对此不作限定。
示例性的, 所述直连月良务响应帧可以如图 32所示; 其中, 长度 ( length )可变, 用于表示直连服务响应帧中行为细节的长度。
可选的, 如图 18a所示, 所述第一 AP还包括直连管理单元 1807; 可选的, 所述查询单元 1804, 具体还用于当服务请求状态为第二 请求状态时,根据所述直连服务请求帧中的服务名称和所述第一 STA 的设备地址, 查询所述 AP的直连服务管理表;
所述直连管理单元 1807,用于当所述直连服务请求帧中的服务请 求状态为第二请求状态时, 当所述第一 AP的直连服务管理表中存在 一条已有直连服务管理信息的服务名称与所述直连服务请求帧中的 服务名称相同, 且所述已有直连服务管理信息的组地址与所述第一 STA的设备地址相同时,将所述已有直连服务管理信息从所述第一 AP 的直连月良务管理表中删除。
可选的, 所述直连管理单元 1807, 还用于将所述已有直连服务管 理信息中组标识回收进组标识池,将所述已有直连服务管理信息中信 道信息对应的信道资源回收。
可选的, 所述发送单元 1806, 还用于在所述直连管理单元 1807更 新所述直连服务管理表之后, 向所述第一 STA返回应答消息, 例如 ACK或 NACK。 需要说明的是, 所述第一 AP上还包括天线, 用于发送和接收无 线信号; 所述天线与所述接收单元 1801和所述发送单元 1806相连。 如图 19所示, 本发明实施例提供了一种直连服务管理系统, 所述 系统包括如本发明图 17所示的第一站点 STA和如本发明图 18所示的 第一接入点 AP; 所述第一 STA和所述第一 AP交互查找可以提供直连 服务的第二 STA,并通过所述第一 AP管理直连服务; 所述系统还包括 所述第二 STA, 所述第一 STA和所述第二 STA可以进行直连通信。
通过本发明实施例提供的获取和管理直连服务的技术方案, AP 可以代理发现提供直连服务的 STA,并管理 STA之间的直连通信, STA 无需周期性监听信道上其他设备的请求, 降低了 STA的资源开销和能 耗。
采用本发明实施例提供的技术方案, 第一 AP可以代理第一 STA 查找网络中的服务信息, 并且所述第一 AP可以通过本地查找和远程 查找, 为用户提供更大范围、 更丰富的服务信息, 满足用户根据服务 需求选择网络的需求; 并且 AP可以代理发现提供直连服务的 STA, 并 管理 STA之间的直连通信, 这样网络中提供服务的 STA也无需周期性 监听信道上其他设备的查找请求, 降低了提供服务的 STA的资源开销 和能耗; 此外, 第一 STA无论在关联前还是关联后, 都可以通过第一 AP获取服务信息, 可以避免第一 STA关联到一个 AP后, 发现没有所 需服务再脱离, 导致在不同 AP间进行频繁的关联和脱离的问题, 保 证用户可以更快速准确地接入可提供服务的网络, 提高了用户体验。 同时, 关联到第一 AP的第一 STA可以在第一 AP上申明或取消服务信 息, 第一 STA无需周期性监听信道上其他设备的查找请求, 第一 AP 还可以将在所述第一 AP上申明的设备信息和服务信息扩散到网络中 可访问的相邻 AP, 也可以接收可访问的相邻 AP提供的服务信息, 从 而可以向用户提供更丰富的服务信息; 最后, 由于 AP上维护的服务 信息, 是经过验证关联到 AP上的 STA发布的, 保证了安全性, 从而保 证了服务的可靠性。
本领域普通技术人员可以理解实现上述实施例方法中的全部或 部分步骤是可以通过程序来指令相关的硬件完成,所述的程序可以存 储于计算机可读存储介质中, 所述存储介质可以是 ROM/RAM, 磁盘 或光碟等。
以上所述, 仅为本发明较佳的具体实施方式, 但本发明的保护范 围并不局限于此,任何熟悉本技术领域的技术人员在本发明揭露的技 术范围内, 可轻易想到的变化或替换, 都应涵盖在本发明的保护范围 之内。

Claims

权 利 要 求
1、 一种服务发现的方法, 其特征在于, 包括:
第一接入点 AP接收来自第一站点 STA的服务发现请求帧,所述 服务发现请求帧中包括 M个服务查询项, 所述 M为大于等于 0的整 数;
根据所述服务发现请求帧, 查询所述第一 AP的服务信息表, 获 取满足所述 M个服务查询项的查询结果;
向所述第一 STA返回服务发现响应帧, 所述服务发现响应帧中 包括所述查询结果。
2、 根据权利要求 1所述的方法, 其特征在于, 所述获取满足所 述 M个服务查询项的查询结果, 具体包括:
获取所述第一 AP的服务信息表中,同时满足所述 M个服务查询 项的查询结果。
3、 根据权利要求 1所述的方法, 其特征在于, 所述获取满足所 述 M个服务查询项的查询结果, 具体包括:
获取所述第一 AP的服务信息表中,同时满足所述 M个服务查询 项的所有服务信息;
向第二 AP转发所述服务发现请求帧, 并接收所述第二 AP返回 的服务发现响应帧, 所述第二 AP返回的服务发现响应帧中包括所述 第二 AP的服务信息表中满足所述 M个服务查询项的所有服务信息; 所述查询结果具体包括: 所述第一 AP的服务信息表中满足所述 M个服务查询项的所有服务信息,和所述第二 AP返回的服务发现响 应帧中包括的服务信息。
4、 根据权利要求 1所述的方法, 其特征在于, 所述获取满足所 述 M个服务查询项的查询结果, 具体包括: 当所述第一 AP的服务信息表中存在至少一条服务信息满足所述 M个服务查询项时, 获取所述第一 AP的服务信息表中, 满足所述 M 个服务查询项的所有服务信息;
当所述第一 AP的服务信息表中任意一条服务信息都不满足所述 M个服务查询项时, 向第二 AP转发所述服务发现请求帧, 并接收所 述第二 AP返回的服务发现响应帧, 所述第二 AP返回的服务发现响 应帧中包括所述第二 AP的服务信息表中满足所述 M个服务查询项的 所有服务信息, 获取所述第二 AP返回的服务发现响应帧中包括的服 务信息。
5、 根据权利要求 1至 4任一项所述的方法, 其特征在于, 在所 述第一 AP接收来自第一 STA的服务发现请求帧之前,所述方法还包 括:
所述第一 AP接收所述第一 STA广播发送的探测请求帧,所述探 测请求帧中包括服务信息元素;
向所述第一 STA返回探测响应帧, 所述探测响应帧中包括服务 信息元素, 所述月良务信息元素包括月良务目录项。
6、 根据权利要求 1至 4任一项所述的方法, 其特征在于, 在所 述第一 AP接收来自第一 STA的服务发现请求帧之前,所述方法还包 括:
所述第一 AP广播发送信标帧,所述信标帧中包括服务信息元素, 所述服务信息元素包括服务目录项。
7、 一种服务发现的方法, 其特征在于, 包括:
第一站点 STA向第一接入点 AP发送服务发现请求帧,所述服务 发现请求帧中包括 M个服务查询项, 所述 M为大于等于 0的整数; 接收所述第一 AP返回的服务发现响应帧, 所述服务发现响应帧 中包括满足所述 M个服务查询项的查询结果。
8、 根据权利要求 7所述的方法, 其特征在于, 在所述 STA向第 一 AP发送服务发现请求帧之前, 所述方法还包括:
所述第一 STA广播发送的探测请求帧, 所述探测请求帧中包括 服务信息元素;
接收所述第一 AP返回的探测响应帧, 所述探测响应帧中包括服 务信息元素, 所述服务信息元素包括服务目录项。
9、 根据权利要求 7所述的方法, 其特征在于, 在所述第一 STA 向第一 AP发送服务发现请求帧之前, 所述方法还包括:
接收所述第一 AP广播发送的信标帧, 所述信标帧中包括服务信 息元素, 所述服务信息元素包括服务目录项。
10、 一种用于服务发现的第一接入点 AP, 其特征在于, 包括: 接收单元, 用于接收来自第一站点 STA的服务发现请求帧, 所 述服务发现请求帧中包括 M个服务查询项; 所述 M为大于等于 0的 整数。
查询单元, 用于根据所述服务发现请求帧, 查询所述第一 AP的 服务信息表, 获取满足所述 M个服务查询项的查询结果;
发送单元, 用于向所述第一 STA返回服务发现响应帧, 所述服 务发现响应帧中包括所述查询结果。
11、 根据权利要求 10所述的第一 AP, 其特征在于, 所述查询单 元具体包括:
本地子单元, 用于根据所述服务发现请求帧, 查询所述第一 AP 的服务信息表,获取所述第一 AP的服务信息表中满足所述 M个服务 查询项的所有服务信息;
远程子单元, 用于向第二 AP转发所述服务发现请求帧, 并接收 所述第二 AP返回的服务发现响应帧, 所述第二 AP返回的服务发现 响应帧中包括所述第二 AP的服务信息表中满足所述 M个服务查询项 的所有服务信息, 获取所述第二 AP返回的服务发现响应帧中包含的 服务信息;
结果获取子单元, 用于获取满足所述 M个服务查询项的查询结 果, 所述查询结果具体包括所述本地子单元获取的服务信息, 和所述 远程子单元获取的服务信息。
12、 根据权利要求 10所述的第一 AP, 其特征在于, 所述查询单 元具体包括:
查找子单元, 用于根据所述服务发现请求帧, 查询所述第一 AP 的服务信息表;
远程子单元, 用于当所述查找子单元的查找结果为: 所述第一 AP的服务信息表中任意一条服务信息都不满足所述 M个服务查询项 时, 向第二 AP转发所述服务发现请求帧, 并接收所述第二 AP返回 的服务发现响应帧, 所述第二 AP返回的服务发现响应帧中包括所述 第二 AP的服务信息表中满足所述 M个服务查询项的所有服务信息; 获取所述第二 AP返回的服务发现响应帧中包括的服务信息;
本地子单元, 用于当所述查找子单元的查找结果为: 所述第一 AP 的服务信息表中存在至少一条服务信息满足所述 M 个服务查询 项,获取所述第一 AP的服务信息表中,满足所述 M个服务查询项的 所有服务信息。
13、根据权利要求 10至 12任一项所述的第一 AP, 其特征在于, 所述第一 AP还包括扫描单元;
所述扫描单元, 用于广播发送信标帧, 所述信标帧中包括服务信 息元素, 所述服务信息元素包括服务目录项; 或者, 用于接收所述第 一 STA广播发送的探测请求帧,并向所述第一 STA返回探测响应帧, 所述探测请求帧中包括服务信息元素,所述探测响应帧中包括服务信 息元素, 所述服务信息元素包括服务目录项。
14、 一种用于服务发现的第一站点 STA, 其特征在于, 包括: 发送单元, 用于向第一接入点 AP发送服务发现请求帧, 所述服 务发现请求帧中包括 M个月良务查询项;
接收单元, 用于接收所述第一 AP返回的服务发现响应帧, 所述 服务发现响应帧中包括满足所述 M个服务查询项的查询结果。
15、 根据权利要求 14所述的第一 STA, 其特征在于, 所述第一 STA还包括扫描单元;
所述扫描单元, 用于接收所述第一 AP广播发送的信标帧, 所述 信标帧中包括服务信息元素, 所述服务信息元素包括服务目录项; 或 者, 用于广播发送探测请求帧, 并接收所述第一 AP返回的探测响应 帧, 所述探测请求帧中包括服务信息元素, 所述探测响应帧中包括服 务信息元素, 所述服务信息元素包括服务目录项。
16、 一种服务发现系统, 其特征在于, 包括至少一个如权利要求 10至 13任一项所述的第一接入点 AP和如权利要求 14至 15任一项所述 的第一站点 STA。
17、 一种服务注册的方法, 其特征在于, 包括:
第一接入点 AP接收来自第一站点 STA的服务通告请求帧,所述服 务通告请求帧中包括所述第一 STA的设备地址和至少一个服务申明 项, 所述服务申明项包括服务名称;
获取所述第一 STA的设备标识;
根据所述至少一个服务申明项,获取所述至少一个服务申明项中 每个良务申明项对应的良务标识; 在所述第一 AP的服务信息表中记录所述至少一个服务申明项中 每个服务申明项对应的服务信息,所述服务信息包括基本服务集标识 BSSID, 设备标识, 服务标识和服务申明项;
向所述第一 STA返回服务通告响应帧, 所述服务通告响应帧中包 括所述 STA的设备标识和所述至少一个服务申明项中每个服务申明 项对应的服务申明应答项;所述服务申明应答项包括服务标识和服务 名称。
18、 根据权利要求 17所述的方法, 其特征在于, 所述获取所述第 一 STA的设备标识具体包括:
根据所述第一 STA的设备地址, 查询所述 AP的地址对应关系表, 所述地址对应关系表中包括设备地址与设备标识的对应关系,
当所述 AP的地址对应关系表中一条已有地址对应关系的设备地 址与所述第一 STA的设备地址相同时, 获取所述已有地址对应关系的 设备标识, 即为所述第一 STA的设备标识;
当所述 AP的地址对应关系表中任意一条地址对应关系的设备地 址与所述第一 STA的设备地址都不相同时,从设备标识池中分配所述 第一 STA的设备标识, 并在所述地址对应关系表中记录所述第一 STA 的设备地址与设备标识的地址对应关系。
19、 根据权利要求 17所述的方法, 其特征在于, 所述服务通告请 求帧中还包括所述第一 STA的设备标识;
相应地, 所述获取所述第一 STA的设备标识具体包括:
从所述服务通告请求帧中获取所述第一 STA的设备标识。
20、 根据权利要求 17至 19任一项所述的方法, 其特征在于, 所述 根据所述至少一个服务申明项,获取所述至少一个服务申明项中每个 服务申明项对应的服务标识包括: 所述第一 AP根据所述至少一个服务申明项中第一服务申明项的 服务名称, 查询所述第一 AP的服务信息表;
当所述第一 AP的服务信息表中任意一条服务信息的服务名称与 所述第一服务申明项的服务名称均不相同时,根据所述第一服务申明 项的服务名称分配第一服务标识;
当所述第一 AP的服务信息表中存在一条已有服务信息的服务名 称与所述第一服务申明项的服务名称相同时,获取所述已有服务信息 的服务标识,即为所述第一服务申明项的服务名称对应的第一服务标 识。
21、 根据权利要求 20所述的方法, 其特征在于, 所述在所述第一 AP的服务信息表中记录所述至少一个服务申明项中每个服务申明项 对应的服务信息包括:
所述第一 AP获取第一服务信息, 所述第一服务信息包括所述第 一 AP的 BSSID, 所述第一 STA的设备标识, 所述第一服务标识和所述 第一服务申明项;
并在所述第一 AP的服务信息表中记录所述第一服务信息。
22、 根据权利要求 17至 21任一项所述的方法, 其特征在于, 所述 方法还包括:
所述第一 AP向第二 AP发送第一服务维护帧, 所述第一服务维护 帧中包括第一维护状态和所述至少一个服务申明项中每个服务申明 项对应的服务信息,以使所述第二 AP更新所述第二 AP的服务信息表。
23、 根据权利要求 17至 22任一项所述的方法, 其特征在于, 所述 方法还包括:
所述第一 AP接收来自所述第一 STA的第二服务维护帧,所述第二 服务维护帧中包括第二维护状态和至少一个服务维护项; 所述第一 AP根据所述第二服务维护帧, 更新所述第一 AP的服务 信息表。
24、根据权利要求 23所述的方法,其特征在于,所述方法还包括: 向第二 AP转发所述第二服务维护帧, 以使所述第二 AP更新所述 第二 AP的服务信息表。
25、 根据权利要求 17至 22任一项所述的方法, 其特征在于, 所述 方法还包括:
所述第一 AP感知所述第一 STA脱离;
将所述第一 AP的服务信息表中,所述第一 STA申明的所有服务信 息删除。
26、 根据权利要求 17至 25任一项所述的方法, 其特征在于, 所述 方法还包括:
所述第一 AP接收第三服务维护帧, 所述第三服务维护帧中包括 第一维护状态和至少一条服务信息,或者第二维护状态和至少一个服 务维护项;
所述第一 AP根据所述第三服务维护帧, 更新所述第一 AP的服务 信息表。
27、 根据权利要求 17至 26任一项所述的方法, 其特征在于, 所述 服务通告请求帧中还包括设备能力; 相应地, 所述服务信息表中还包 括设备能力。
28、 一种服务注册方法, 其特征在于, 包括:
第一站点 STA向第一接入点 AP发送服务通告请求帧,所述服务通 告请求帧中包括所述 STA的设备地址和至少一个服务申明项,所述服 务申明项包括服务名称;
接收来自所述第一 AP的服务通告响应帧, 所述服务通告响应帧 中包括所述 STA的设备标识和所述至少一个服务申明项中每个服务 申明项对应的服务申明应答项;所述服务申明应答项包括服务标识和 服务名称。
29、根据权利要求 28所述的方法,其特征在于,所述方法还包括: 所述第一 STA向所述第一 AP发送服务维护帧, 以使所述第一 AP 根据所述服务维护帧, 更新所述第一 AP的服务信息表;
所述服务维护帧中包括第二维护状态和至少一个服务维护项;所 述服务维护项包括基本服务集标识 BSSID , 设备标识和服务标识。
30、 根据权利要求 28或 29所述的方法, 其特征在于, 所述服务通 告请求帧中还包括设备能力。
31、 一种用于服务注册的第一接入点 AP, 其特征在于, 包括: 接收单元, 用于接收来自第一站点 STA的服务通告请求帧, 所述 服务通告请求帧中包括所述第一 STA的设备地址和至少一个服务申 明项, 所述服务申明项包括服务名称;
第一获取单元, 用于获取所述 STA的设备标识;
第二获取单元, 用于根据所述至少一个服务申明项, 获取所述至 少一个服务申明项中每个服务申明项对应的服务标识;
记录单元, 用于在所述第一 AP的服务信息表中记录所述至少一 个服务申明项中每个服务申明项对应的服务信息,所述服务信息包括 基本服务集标识 BSSID, 设备标识, 服务标识和服务申明项;
发送单元, 用于向所述第一 STA返回服务通告响应帧, 所述服务 通告响应帧中包括所述第一 STA的设备标识和所述至少一个服务申 明项中每个服务申明项对应的服务申明应答项;所述服务申明应答项 包括服务标识和服务名称。
32、 根据权利要求 31所述的第一 AP, 其特征在于, 所述第一获 取单元具体用于,
根据所述第一 STA的设备地址,查询所述第一 AP的地址对应关系 表, 所述地址对应关系表中包括设备地址与设备标识的对应关系; 当所述第一 AP的地址对应关系表中一条已有地址对应关系的设 备地址与所述第一 STA的设备地址相同时, 获取所述已有地址对应关 系的设备标识, 即为所述第一 STA的设备标识;
当所述第一 AP的地址对应关系表中任意一条地址对应关系的设 备地址与所述第一 STA的设备地址都不相同时,从设备标识池中分配 所述第一 STA的设备标识, 并在所述地址对应关系表中记录所述第一 STA的设备地址与设备标识的地址对应关系。
33、 根据权利要求 31所述的第一 AP, 其特征在于, 所述服务通 告请求帧中还包括所述第一 STA的设备标识, 所述第一获取单元具体 用于, 从所述服务通告请求帧中获取所述第一 STA的设备标识。
34、 根据权利要求 31至 33任一项所述的第一 AP, 其特征在于, 所述第二获取单元具体用于,
根据所述至少一个服务申明项中第一服务申明项的服务名称,查 询所述第一 AP的服务信息表;
当所述第一 AP的服务信息表中任意一条服务信息的服务名称与 所述第一服务申明项的服务名称均不相同时,根据所述第一服务申明 项的服务名称分配第一服务标识;
当所述第一 AP的服务信息表中存在一条已有服务信息的服务名 称与所述第一服务申明项的服务名称相同时,获取所述已有服务信息 的服务标识,即为所述第一服务申明项的服务名称对应的第一服务标 识。
35、 根据权利要求 34所述的第一 AP, 其特征在于, 所述记录单 元具体用于,
获取第一服务信息, 所述第一服务信息包括所述第一 AP的 BSSID, 所述第一 STA的设备标识, 所述第一服务标识和所述第一服 务申明项;
并在所述 AP的服务信息表中记录所述第一服务信息。
36、 根据权利要求 31至 35任一项所述的第一 AP, 其特征在于, 所述第一 AP还包括维护单元;
所述维护单元, 用于接收来自所述第一 STA的第二服务维护帧, 所述第二服务维护帧中包括第二维护状态和至少一个服务维护项;根 据所述第二服务维护帧, 更新所述第一 AP的服务信息表; 并向第二 AP转发所述第二服务维护帧, 以使所述第二 AP更新所述第二 AP的服 务信息表。
37、 根据权利要求 36所述的第一 AP, 其特征在于,
所述维护单元, 还用于向第二 AP发送第一服务维护帧, 所述第 一服务维护帧中包括第一维护状态和所述至少一个服务申明项中每 个服务申明项对应的服务信息, 以使所述第二 AP更新所述第二 AP的 服务信息表。
38、 根据权利要求 36或 37所述的第一 AP, 其特征在于, 所述维 护单元, 还用于接收第三服务维护帧, 所述第三服务维护帧中包括第 一维护状态和至少一条服务信息,或者第二维护状态和至少一个服务 维护项; 并根据所述第三服务维护帧, 更新所述第一 AP的服务信息 表。
39、 一种用于服务注册的第一站点 STA, 其特征在于, 包括: 发送单元, 用于向第一接入点 AP发送服务通告请求帧, 所述服 务通告请求帧中包括所述第一 STA的设备地址和至少一个服务申明 项, 所述服务申明项包括服务名称;
接收单元, 用于接收来自所述第一 ΑΡ的服务通告响应帧, 所述 服务通告响应帧中包括所述第一 STA的设备标识和所述至少一个服 务申明项中每个服务申明项对应的服务申明应答项;所述服务申明应 答项包括服务标识和服务名称。
40、 根据权利要求 39所述的第一 STA, 其特征在于, 所述发送单 元还用于向所述第一 ΑΡ发送第二服务维护帧, 所述第二服务维护帧 中包括第二维护状态和至少一个服务维护项。
41、 一种服务注册系统, 其特征在于, 包括如权利要求 31至 38任 一项所述的用于服务注册的第一接入点 ΑΡ和如权利要求 39至 40任一 项所述的用于服务注册的第一站点 STA。
42、 如权利要求 41所述的系统, 其特征在于, 还包括第二 AP, 所述第二 AP为所述第一 AP可访问的相邻 AP。
43、 一种管理直连服务的方法, 其特征在于, 包括:
第一接入点 AP接收第一站点 STA发送的直连服务请求帧,所述 直连服务请求帧中包括服务请求状态和服务名称;
当所述服务请求状态为第一请求状态时,
所述第一 AP获取第二 STA的设备地址;
所述第一 AP根据所述第二 STA的设备地址,探测所述第一 STA 与第二 STA之间的距离探测所述第一 STA与第二 STA之间的距离; 当所述第一 STA与所述第二 STA之间的距离不大于直连距离时, 所述第一 AP查询所述第一 AP的直连服务管理表;
当所述第一 AP的直连服务管理表中不存在一条已有直连服务管 理信息,所述已有直连服务管理信息的服务名称与所述直连服务请求 帧中的服务名称相同,且所述已有直连服务管理信息的组地址与所述 第二 STA的设备地址相同时,所述第一 AP在所述第一 AP的直连服 务管理表中记录第一直连服务管理信息,所述第一直连服务管理信息 包括所述直连服务请求帧中的服务名称和所述第二 STA的设备地址; 并向所述第一 STA发送直连服务响应帧, 所述直连服务响应帧中包 括所述第二 STA的设备地址。
44、 根据权利要求 43所述的方法, 其特征在于, 所述第一直连 服务管理信息中还包括第一信道信息,所述第一信道信息包括所述第 一 AP为所述第一 STA分配的用于直连通信的无线信道的信息。
45、 根据权利要求 43或 44所述的方法, 其特征在于, 所述方法 还包括:
当所述第一 AP的直连服务管理表中存在一条已有直连服务管理 信息的服务名称与所述直连服务请求帧中的服务名称相同,且所述已 有直连服务管理信息的组地址与所述第二 STA的设备地址相同时, 所述第一 AP向所述第一 STA发送直连服务响应帧,所述直连服务响 应帧中包括所述已有直连服务管理信息中的组地址。
46、 根据权利要求 43至 45任一项所述的方法, 其特征在于, 所 述第一 AP获取第二 STA的设备地址具体包括:
所述第一 AP根据所述直连服务请求帧中的服务名称查询所述第 一 AP的服务信息表;
当所述第一 AP的服务信息表中存在一条已有服务信息的服务名 称与所述直连服务请求帧中的服务名称相同,且所述已有服务信息中 设备能力为支持 Wi-Fi直连时, 所述第一 AP获取所述已有服务信息 中的设备标识, 即为所述第二 STA的设备标识;
所述第一 AP根据所述第二 STA的设备标识,获取所述第二 STA 的设备地址。
47、 根据权利要求 43至 45任一项所述的方法, 其特征在于, 所 述直连服务请求帧中还包括设备名称;
相应地, 所述第一 AP获取第二 STA的设备地址具体包括: 所述第一 AP获取所述直连服务请求帧中的设备标识, 即为所述 第二 STA的设备标识;
所述第一 AP根据所述第二 STA的设备标识,获取所述第二 STA 的设备地址。
48、 根据权利要求 43至 47任一项所述的方法, 其特征在于, 当 所述服务请求状态为第二请求状态时, 所述方法还包括:
所述第一 AP根据所述直连服务请求帧, 查询所述第一 AP的直 连服务管理表;
当所述第一 AP的直连服务管理表中存在一条已有直连服务管理 信息的服务名称与所述直连服务请求帧中的服务名称相同,且所述已 有直连服务管理信息的组地址与所述第一 STA的设备地址相同时, 将所述已有直连服务管理信息从所述第一 AP的直连服务管理表中删 除。
49、 一种获取直连服务的方法, 其特征在于, 包括:
第一站点 STA向第一接入点 AP发送直连服务请求帧,所述直连 服务请求帧中包括服务请求状态和服务名称;
当所述服务请求状态为第一请求状态时,
所述第一 STA接收所述第一 AP返回的直连服务响应帧,所述直 连服务响应帧中包括组地址;
当根据所述直连服务响应帧确定直连请求成功时,所述第一 STA 与所述直连良务响应帧中组地址对应的第二 STA建立直连 务。
50、 根据权利要求 49所述的方法, 其特征在于, 所述直连服务 响应帧中还包括信道信息;
相应地, 所述与所述直连良务响应帧中组地址对应的第二 STA 建立直连服务具体包括: 所述第一 STA在所述信道信息对应的无线 信道上与所述第二 STA建立直连服务。
51、 一种用于管理直连服务的第一接入点 AP, 其特征在于, 包 括:
接收单元, 用于接收第一站点 STA的直连服务请求帧, 所述直 连服务请求帧中包括服务请求状态和服务名称;
第一获取单元, 用于当所述服务请求状态为第一请求状态时, 获 取第二 STA的设备地址;
探测单元, 用于根据所述第一获取单元获取的所述第二 STA的 设备地址, 探测所述第一 STA与所述第二 STA之间的距离;
查询单元, 用于查询所述第一 AP的直连服务管理表;
第二获取单元, 用于为所述第一 STA的直连服务请求, 获取直 连服务管理信息, 所述直连服务管理信息包括组地址和服务名称; 发送单元, 用于根据所述获取单元获取的直连服务管理信息, 向 所述第一 STA发送直连服务响应帧, 以使所述第一 STA与所述第二 STA建立直连良务, 所述直连良务响应帧中包括所述组地址。
52、 根据权利要求 51所述的第一 AP, 其特征在于, 所述第一获 取单元具体用于,
根据所述直连服务请求帧中的服务名称查询所述第一 AP的服务 信息表; 当所述第一 AP的服务信息表中存在一条已有服务信息的服 务名称与所述直连服务请求帧中的服务名称相同,且所述已有服务信 息中设备能力为支持 Wi-Fi直连时, 获取所述已有服务信息中的设备 标识, 即为所述第二 STA的设备标识; 根据所述第二 STA的设备标 识, 获取所述第二 STA的设备地址; 或者,
当所述直连服务请求帧中包括设备名称时,获取所述直连服务请 求帧中的设备标识, 即为所述第二 STA的设备标识; 根据所述第二 STA的设备标识, 获取所述第二 STA的设备地址。
53、 根据权利要求 51或 52所述的第一 AP, 其特征在于, 所述 查询单元, 具体用于当服务请求状态为第一请求状态时, 当所述探测 单元探测到的所述第一 STA与所述第二 STA之间的距离不大于直连 距离时, 根据所述直连服务请求帧中的服务名称和所述第二 STA的 设备地址查询所述第一 AP的直连服务管理表。
54、 根据权利要求 51至 53任一项所述的第一 AP, 其特征在于, 第二获取单元具体用于,
当所述第一 AP的直连服务管理表中存在一条已有直连服务管理 信息的服务名称与所述直连服务请求帧中的服务名称相同,且所述已 有直连服务管理信息的组地址与所述第二 STA的设备地址相同时, 获 取所述已有直连服务管理信息;
当所述第一 AP的直连服务管理表中任意一条直连服务管理信息 的服务名称和组地址与所述直连服务请求帧中的服务名称和所述第 二 STA的设备地址不同时, 获取第一直连服务管理信息, 并在所述第 一 AP的直连服务管理表中记录所述第一直连服务管理信息; 所述第 一直连服务管理信息包括所述直连服务请求帧中的服务名称和所述 第二 STA的设备地址。
55、 根据权利要求 51至 54任一项所述的第一 AP, 其特征在于, 所述第一 AP还包括直连管理单元;
所述查询单元, 具体还用于当服务请求状态为第二状态时, 根据 所述直连服务请求帧中的服务名称和所述第一 STA的设备地址, 查询 所述第一 AP的直连服务管理表;
所述直连管理单元,用于当所述直连服务请求帧中的服务请求状 态为第二请求状态时, 当所述第一 AP的直连服务管理表中存在一条 已有直连服务管理信息的服务名称与所述直连服务请求帧中的服务 名称相同,且所述已有直连服务管理信息的组地址与所述第一 STA的 设备地址相同时, 将所述已有直连服务管理信息从所述第一 AP的直 连服务管理表中删除。
56、一种用于获取直连服务的第一站点 STA,其特征在于,包括: 发送单元, 用于向第一接入点 AP发送直连服务请求帧, 所述直 连服务请求帧中包括服务请求状态和服务名称;
接收单元, 用于接收所述第一 AP返回的直连服务响应帧, 所述 直连月良务响应帧中包括组地址;
服务建立单元,用于当根据所述直连服务响应帧确定直连请求成 功时, 与所述直连服务响应帧中组地址对应的第二 STA建立直连服 务。
57、 根据权利要求 56所述的第一 STA, 其特征在于, 所述直连服 务响应帧中还包括信道信息;
相应地, 所述服务建立单元具体用于, 当根据所述直连服务响应 帧确定直连请求成功时,在所述信道信息指定的无线信道上与所述第 二 STA建立直连服务。
58、 根据权利要求 56或 57所述的第一 STA, 其特征在于, 所述第 一 STA还包括判断单元,用于根据所述直连服务响应帧判断直连服务 请求是否成功。
59、 一种直连服务管理系统, 其特征在于, 包括如权利要求 51至 55任一项所述的第一接入点 AP和如权利要求 56至 58任一项所述的第 一站点 STA。
60、 根据权利要求 59所述的系统, 其特征在于, 所述系统还包括 第二 STA, 所述第二 STA为提供直连服务的设备。
PCT/CN2012/078314 2012-07-06 2012-07-06 一种服务注册与发现的方法,设备和系统 Ceased WO2014005330A1 (zh)

Priority Applications (11)

Application Number Priority Date Filing Date Title
KR1020177002559A KR101727090B1 (ko) 2012-07-06 2012-07-06 서비스를 등록 및 발견하는 방법, 기기, 및 시스템
PCT/CN2012/078314 WO2014005330A1 (zh) 2012-07-06 2012-07-06 一种服务注册与发现的方法,设备和系统
CN201280000930.6A CN103891355B (zh) 2012-07-06 2012-07-06 一种服务注册与发现的方法,设备和系统
ES16202340T ES2727442T3 (es) 2012-07-06 2012-07-06 Registrar y descubrir un servicio
EP12880569.4A EP2858421B1 (en) 2012-07-06 2012-07-06 Method, device, and system for discovering service
EP16202340.2A EP3223564B1 (en) 2012-07-06 2012-07-06 Registering and discovering a service
KR1020157001243A KR101702606B1 (ko) 2012-07-06 2012-07-06 서비스를 등록 및 발견하는 방법, 기기, 및 시스템
JP2015518775A JP6068630B2 (ja) 2012-07-06 2012-07-06 サービスを登録して発見するための方法、デバイス、およびシステム
ES12880569.4T ES2624429T3 (es) 2012-07-06 2012-07-06 Método, dispositivo y sistema de descubrimiento de servicio
US14/587,213 US9794865B2 (en) 2012-07-06 2014-12-31 Methods, devices, and systems for registering and discovering service
US15/703,636 US10433241B2 (en) 2012-07-06 2017-09-13 Methods, devices, and systems for registering and discovering service

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
PCT/CN2012/078314 WO2014005330A1 (zh) 2012-07-06 2012-07-06 一种服务注册与发现的方法,设备和系统

Related Child Applications (1)

Application Number Title Priority Date Filing Date
US14/587,213 Continuation US9794865B2 (en) 2012-07-06 2014-12-31 Methods, devices, and systems for registering and discovering service

Publications (1)

Publication Number Publication Date
WO2014005330A1 true WO2014005330A1 (zh) 2014-01-09

Family

ID=49881274

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2012/078314 Ceased WO2014005330A1 (zh) 2012-07-06 2012-07-06 一种服务注册与发现的方法,设备和系统

Country Status (7)

Country Link
US (2) US9794865B2 (zh)
EP (2) EP2858421B1 (zh)
JP (1) JP6068630B2 (zh)
KR (2) KR101702606B1 (zh)
CN (1) CN103891355B (zh)
ES (2) ES2624429T3 (zh)
WO (1) WO2014005330A1 (zh)

Cited By (9)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2016136159A1 (en) * 2015-02-23 2016-09-01 Canon Kabushiki Kaisha Wireless communication apparatus and control method thereof
EP3031254A4 (en) * 2014-08-13 2016-11-23 Mediatek Inc SERVICE DISCOVERY WITH LOW POWER CONSUMPTION IN WIRELESS COMMUNICATION NETWORKS
US20170048788A1 (en) * 2014-04-26 2017-02-16 Huawei Device Co., Ltd. Service Discovery Method and Electronic Device
US9788171B2 (en) 2014-02-11 2017-10-10 Telefonaktiebolaget Lm Ericsson (Publ) Methods for service acquisition in device-to-device operation
JP2017533660A (ja) * 2014-10-31 2017-11-09 華為技術有限公司Huawei Technologies Co.,Ltd. デバイス間発見方法および装置
JP2018518095A (ja) * 2015-04-23 2018-07-05 エルジー エレクトロニクス インコーポレイティド 無線通信システムにおいてnanプロキシサーバーに登録する方法及び装置
US10433241B2 (en) 2012-07-06 2019-10-01 Huawei Technologies Co., Ltd. Methods, devices, and systems for registering and discovering service
CN112437141A (zh) * 2020-06-12 2021-03-02 支付宝(杭州)信息技术有限公司 辅助区块链网络中的节点建立p2p直连的方法
US11095729B2 (en) 2014-08-13 2021-08-17 Mediatek Inc. Service discovery in multi-medium communications networks

Families Citing this family (29)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
AU2013352890B2 (en) * 2012-11-29 2015-09-10 Lg Electronics Inc. Method for setting communication in Wi-Fi direct service system, and apparatus therefor
KR20150098619A (ko) * 2012-12-17 2015-08-28 엘지전자 주식회사 무선랜 시스템에서 서비스 발견 방법 및 장치
US9876862B1 (en) * 2013-02-19 2018-01-23 Marvell International Ltd. Service identification with reduced ambiguity
US20150269207A1 (en) * 2014-03-18 2015-09-24 Cong Deng Simple and efficient method for recycling device identifiers
JP6381330B2 (ja) * 2014-07-23 2018-08-29 キヤノン株式会社 通信装置、通信装置の制御方法、プログラム
US10264515B2 (en) * 2014-12-22 2019-04-16 Qualcomm Incorporated Enhanced access network query protocol (ANQP) signaling to scale to support large numbers of service providers at an access point (AP)
US9998982B2 (en) * 2014-12-22 2018-06-12 Qualcomm Incorporated Enhanced access network query protocol (ANQP) signaling for radio access network (RAN) sharing
US10735543B2 (en) * 2015-06-05 2020-08-04 Apple Inc. Device-to-device caching
JP2017046227A (ja) * 2015-08-27 2017-03-02 株式会社バッファロー 無線通信システム、端末装置、アクセスポイント、及びプログラム
JP6655913B2 (ja) 2015-09-02 2020-03-04 キヤノン株式会社 通信装置、制御方法及びプログラム
KR102156093B1 (ko) * 2015-11-10 2020-09-15 후아웨이 테크놀러지 컴퍼니 리미티드 서비스 네트워크를 선택하는 방법 및 네트워크, 및 관리 장치
US10171277B2 (en) 2016-07-14 2019-01-01 Huawei Technologies Co., Ltd. Frame format and design of wake-up frame for a wake-up receiver
US10524304B2 (en) * 2016-07-14 2019-12-31 Huawei Technologies Co., Ltd. MAC frame design of wake-up frame for wake-up receiver
US10445107B2 (en) 2016-07-14 2019-10-15 Huawei Technologies Co., Ltd. Security design for a wake up frame
EP3306896B1 (en) * 2016-10-07 2025-10-22 Nokia Technologies Oy Access to services provided by a distributed data storage system
US10172076B2 (en) * 2016-10-13 2019-01-01 GM Global Technology Operations LLC Unified in-vehicle Wi-Fi service
WO2018084825A1 (en) * 2016-11-01 2018-05-11 Hewlett-Packard Development Company, L.P. Service implementations via resource agreements
CN106851775A (zh) * 2017-02-03 2017-06-13 惠州Tcl移动通信有限公司 基于Wi‑FiAware协议的互连方法及系统
US11190554B2 (en) * 2017-06-20 2021-11-30 Samsung Electronics Co., Ltd. System and method for discovery and access of uplink services
US10750435B2 (en) * 2018-06-18 2020-08-18 Blackberry Limited Network address policy information received in a pre-associated state
CN111615219B (zh) * 2019-04-30 2022-02-22 维沃移动通信有限公司 一种pc5链路建立方法、设备及系统
US11252689B2 (en) * 2019-07-12 2022-02-15 Charter Communications Operating, Llc Wi-fi access point coordinated transmission of data
KR20230021644A (ko) 2020-06-09 2023-02-14 삼성전자주식회사 초광대역 시스템에서 서비스 정보를 교환하기 위한 방법 및 장치
US11153812B1 (en) * 2020-06-19 2021-10-19 Cisco Technology, Inc. Provisioning site specific policies in wireless LAN deployments
CN112135335B (zh) * 2020-09-23 2024-02-20 广州巨网时代科技有限公司 一种接入网络的方法、装置
CN112804662B (zh) * 2021-03-18 2021-07-30 成都极米科技股份有限公司 提供无线感知业务的方法、装置、终端设备及存储介质
US11677859B2 (en) * 2021-08-16 2023-06-13 Cisco Technology, Inc. Federated service registries for access providers
US20240397568A1 (en) * 2023-05-24 2024-11-28 Qualcomm Incorporated Managing a group of wi-fi-enabled wearable or handheld wireless devices using a shared address
US12489691B2 (en) * 2023-06-14 2025-12-02 GM Global Technology Operations LLC Method for persisting service discovery learning

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN1894899A (zh) * 2003-10-14 2007-01-10 英特尔公司 用于无线局域网(wlan)的服务发现方法
EP2034661A1 (en) * 2007-09-07 2009-03-11 Deutsche Telekom AG Method and system for distributed, localized authentication in the framework of 802.11
WO2011073516A1 (en) * 2009-12-16 2011-06-23 Nokia Corporation System, method, and apparatus for performing reliable network, capability, and service discovery
CN102325352A (zh) * 2005-01-18 2012-01-18 交互数字技术公司 Wlan接入点以及在wlan接入点中使用的方法

Family Cites Families (30)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US6983095B2 (en) * 2003-11-17 2006-01-03 Fiber Optic Network Solutions Corporation Systems and methods for managing optical fibers and components within an enclosure in an optical communications network
US7394210B2 (en) * 2004-09-29 2008-07-01 Tir Technology Lp System and method for controlling luminaires
JP2006101293A (ja) 2004-09-30 2006-04-13 Sanyo Electric Co Ltd 通信装置、通信プログラム及び通信方法
EP1701486A1 (en) * 2005-03-07 2006-09-13 BRITISH TELECOMMUNICATIONS public limited company Route selection in multi-hop cellular network
US7688046B2 (en) * 2005-07-25 2010-03-30 Apple Inc. Power converters having varied switching frequencies
JP4671422B2 (ja) 2006-01-31 2011-04-20 キヤノン株式会社 通信システム、通信装置及びそれらの表示方法
KR101375481B1 (ko) 2007-07-06 2014-03-19 삼성전자주식회사 통신 시스템에서 통신 모드 결정 방법 및 장치
US20090240794A1 (en) 2008-03-20 2009-09-24 Huaiyu Liu Techniques utilizing a layer-2 proxy for energy-efficient service discovery and connectivity in networks
US9104731B2 (en) 2008-07-10 2015-08-11 Sybase, Inc. Relocated joins in a distributed query processing system
CN102090045B (zh) * 2008-07-11 2015-09-16 马维尔国际贸易有限公司 服务发现方法
KR101511386B1 (ko) 2008-10-15 2015-04-13 엘지전자 주식회사 터널 다이렉트 링크 설정 무선 네트워크에서의 다이렉트 링크 설정 절차
EP2246009A1 (en) * 2009-05-02 2010-11-03 Braun GmbH Oscillatory system for a motorized drive unit
US8768323B2 (en) * 2009-06-23 2014-07-01 Intel Corporation Service discovery in a wireless network
CN101965029B (zh) 2009-07-21 2013-10-02 华为终端有限公司 支持切换的处理方法、通信装置及通信系统
US9900759B2 (en) * 2009-11-04 2018-02-20 Qualcomm Incorporated Method and apparatus for peer discovery in a wireless communication network
US8762543B2 (en) 2009-12-15 2014-06-24 Intel Corporation Method and apparatus for autonomous peer discovery and enhancing link reliability for wireless peer direct links
US8559340B2 (en) * 2009-12-22 2013-10-15 Samsung Electronics Co., Ltd. Method and apparatus for service discovery in Wi-Fi direct network
US9391853B2 (en) * 2009-12-23 2016-07-12 Apple Inc. Efficient service advertisement and discovery in a peer-to-peer networking environment with dynamic advertisement and discovery periods based on operating conditions
US8737370B2 (en) 2010-05-17 2014-05-27 Qualcomm Incorporated Methods and apparatuses for direct link setup
US9078186B2 (en) * 2010-10-20 2015-07-07 Lg Electronics Inc. Method of transmitting and receiving data in a multi radio access technology system using an access point and apparatus therefor
FR2977420A1 (fr) * 2011-06-30 2013-01-04 France Telecom Technique d'obtention par un terminal d'une information relative a un acces a un service
CN103179634A (zh) 2011-12-21 2013-06-26 株式会社Ntt都科摩 一种伙伴发现和选择方法、装置及系统
KR101849925B1 (ko) 2012-02-24 2018-04-18 삼성전자주식회사 무선 통신 네트워크에서 디바이스 탐색 방법 및 장치
US8867514B2 (en) * 2012-03-20 2014-10-21 Qualcomm Incorporated System and method of infrastructure service discovery
US9002352B2 (en) 2012-04-18 2015-04-07 Qualcomm Incorporated System and method of service discovery
CN103891355B (zh) 2012-07-06 2018-07-13 华为技术有限公司 一种服务注册与发现的方法,设备和系统
US9654960B2 (en) 2013-05-31 2017-05-16 Qualcomm Incorporated Server-assisted device-to-device discovery and connection
US9980121B2 (en) 2014-01-26 2018-05-22 Lg Electronics Inc. Method and apparatus for performing discovery in wireless communication system
WO2015119329A1 (ko) 2014-02-07 2015-08-13 엘지전자 주식회사 무선 통신 시스템에서 디스커버리를 수행하는 방법 및 장치
WO2015152657A1 (ko) 2014-04-02 2015-10-08 엘지전자 주식회사 무선 통신 시스템에서 nan 단말의 신호 송수신 방법 및 장치

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN1894899A (zh) * 2003-10-14 2007-01-10 英特尔公司 用于无线局域网(wlan)的服务发现方法
CN102325352A (zh) * 2005-01-18 2012-01-18 交互数字技术公司 Wlan接入点以及在wlan接入点中使用的方法
EP2034661A1 (en) * 2007-09-07 2009-03-11 Deutsche Telekom AG Method and system for distributed, localized authentication in the framework of 802.11
WO2011073516A1 (en) * 2009-12-16 2011-06-23 Nokia Corporation System, method, and apparatus for performing reliable network, capability, and service discovery

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
See also references of EP2858421A4 *

Cited By (12)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US10433241B2 (en) 2012-07-06 2019-10-01 Huawei Technologies Co., Ltd. Methods, devices, and systems for registering and discovering service
US9788171B2 (en) 2014-02-11 2017-10-10 Telefonaktiebolaget Lm Ericsson (Publ) Methods for service acquisition in device-to-device operation
US20170048788A1 (en) * 2014-04-26 2017-02-16 Huawei Device Co., Ltd. Service Discovery Method and Electronic Device
EP3031254A4 (en) * 2014-08-13 2016-11-23 Mediatek Inc SERVICE DISCOVERY WITH LOW POWER CONSUMPTION IN WIRELESS COMMUNICATION NETWORKS
US10484857B2 (en) 2014-08-13 2019-11-19 Mediatek Inc. Service discovery with low power consumption in wireless communications networks
US11095729B2 (en) 2014-08-13 2021-08-17 Mediatek Inc. Service discovery in multi-medium communications networks
JP2017533660A (ja) * 2014-10-31 2017-11-09 華為技術有限公司Huawei Technologies Co.,Ltd. デバイス間発見方法および装置
WO2016136159A1 (en) * 2015-02-23 2016-09-01 Canon Kabushiki Kaisha Wireless communication apparatus and control method thereof
JP2016158032A (ja) * 2015-02-23 2016-09-01 キヤノン株式会社 無線通信装置およびその制御方法
JP2018518095A (ja) * 2015-04-23 2018-07-05 エルジー エレクトロニクス インコーポレイティド 無線通信システムにおいてnanプロキシサーバーに登録する方法及び装置
CN112437141A (zh) * 2020-06-12 2021-03-02 支付宝(杭州)信息技术有限公司 辅助区块链网络中的节点建立p2p直连的方法
CN112437141B (zh) * 2020-06-12 2023-02-03 支付宝(杭州)信息技术有限公司 辅助区块链网络中的节点建立p2p直连的方法

Also Published As

Publication number Publication date
CN103891355B (zh) 2018-07-13
KR101702606B1 (ko) 2017-02-03
US9794865B2 (en) 2017-10-17
ES2624429T3 (es) 2017-07-14
CN103891355A (zh) 2014-06-25
KR20170014022A (ko) 2017-02-07
EP2858421B1 (en) 2017-02-22
KR101727090B1 (ko) 2017-04-14
KR20150023032A (ko) 2015-03-04
US20150117430A1 (en) 2015-04-30
EP3223564B1 (en) 2019-02-20
EP3223564A3 (en) 2017-11-15
EP3223564A2 (en) 2017-09-27
EP2858421A4 (en) 2015-12-02
EP2858421A1 (en) 2015-04-08
ES2727442T3 (es) 2019-10-16
US10433241B2 (en) 2019-10-01
JP6068630B2 (ja) 2017-01-25
US20180007619A1 (en) 2018-01-04
JP2015525993A (ja) 2015-09-07

Similar Documents

Publication Publication Date Title
CN103891355B (zh) 一种服务注册与发现的方法,设备和系统
US11943703B2 (en) Network address policy information received in a pre-associated state
US9191861B2 (en) Tethering method and mobile device adapted thereto
US8768323B2 (en) Service discovery in a wireless network
US10484866B2 (en) Device-to-device identification conflict solution method and device-to-device user equipment
US20140349579A1 (en) Method, Device, and System for Establishing Device-To-Device Connection
US9807677B2 (en) Service discovery method and device in wireless LAN system
CN101895875B (zh) 无线网络中网关设备提供差异化服务的方法及系统
CN101299696B (zh) 移动局域网及其实现业务连续性的方法
TW201218845A (en) Methods and apparatus to discover network capabilities available via wireless networks
KR20140098070A (ko) 와이파이 다이렉트 네트워크를 통한 지원 서비스 탐색 방법 및 디바이스
JP2016220195A (ja) 無線通信方法、無線通信システム、端末管理装置及び仮想端末
CN100550806C (zh) 实现网络服务提供商选择的方法及用户端设备
CN101161016B (zh) 发现网络服务提供商发现的方法及装置
JP6304781B2 (ja) サービスを登録して発見するための方法、デバイス、およびシステム
CN102264059A (zh) 基于用户标识的通信方法、装置及系统
CN102098777B (zh) 家庭基站接入网关的获取方法、家庭基站的注册方法
KR102015413B1 (ko) 로컬 네트워크에서의 인터페이스 설정장치 및 방법
CA3097946C (en) Network address policy information received in a pre-associated state

Legal Events

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

Ref document number: 12880569

Country of ref document: EP

Kind code of ref document: A1

REEP Request for entry into the european phase

Ref document number: 2012880569

Country of ref document: EP

ENP Entry into the national phase

Ref document number: 2015518775

Country of ref document: JP

Kind code of ref document: A

NENP Non-entry into the national phase

Ref country code: DE

ENP Entry into the national phase

Ref document number: 20157001243

Country of ref document: KR

Kind code of ref document: A