CN114745324A - Equipment identification method, device, storage medium and routing equipment - Google Patents

Equipment identification method, device, storage medium and routing equipment Download PDF

Info

Publication number
CN114745324A
CN114745324A CN202110017163.0A CN202110017163A CN114745324A CN 114745324 A CN114745324 A CN 114745324A CN 202110017163 A CN202110017163 A CN 202110017163A CN 114745324 A CN114745324 A CN 114745324A
Authority
CN
China
Prior art keywords
target electronic
information
electronic equipment
equipment
preset
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.)
Pending
Application number
CN202110017163.0A
Other languages
Chinese (zh)
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.)
Shenzhen Qihu Intelligent Technology Co ltd
Original Assignee
Shenzhen Qihu Intelligent Technology 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
Application filed by Shenzhen Qihu Intelligent Technology Co ltd filed Critical Shenzhen Qihu Intelligent Technology Co ltd
Priority to CN202110017163.0A priority Critical patent/CN114745324A/en
Publication of CN114745324A publication Critical patent/CN114745324A/en
Pending legal-status Critical Current

Links

Images

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L45/00Routing or path finding of packets in data switching networks
    • H04L45/74Address processing for routing

Abstract

The application discloses a device identification method, a device, a storage medium and a routing device, wherein the method comprises the steps of obtaining address information of target electronic equipment and judging whether the address information of the target electronic equipment is random address information or not; under the condition that the address information is determined to be random address information, acquiring auxiliary information of the target electronic equipment, and matching the auxiliary information of the target electronic equipment with a preset corresponding table; and under the condition that the matching degree of the auxiliary information of the target electronic equipment and the auxiliary information corresponding to any equipment address information connected with the routing equipment in the preset corresponding table is greater than or equal to the preset matching degree, adding the address information of the target electronic equipment into the preset corresponding table. According to the embodiment, the target electronic equipment can be ensured to be accurately and quickly identified after being replaced by the random address information, corresponding functions such as application identification and equipment identification are correspondingly executed, and normal use experience of a user can be guaranteed while the safety of the electronic equipment is improved.

Description

Equipment identification method, device, storage medium and routing equipment
Technical Field
The present application relates to the field of computer technologies, and in particular, to a device identification method, apparatus, storage medium, and routing device.
Background
At present, functions of mobile phones are increasingly diversified, for example, many mobile phone manufacturers provide a random Access Control (MAC) Address for the mobile phones, so that the MAC Address of the mobile phone changes randomly when the mobile phone is connected to WIFI every time, and the risk of personal privacy leakage caused by collecting the MAC Address can be avoided.
However, functions such as application identification and device identification on the router all depend on accurate identification of the device, and when the device is connected with the router by using the generated random MAC address, the router cannot accurately and quickly identify the device, which not only affects the functions such as application identification and device identification of the router, but also affects the use experience of the router connected with a user.
Disclosure of Invention
The embodiment of the application provides a device identification method, a device, a storage medium and a routing device, which can accurately identify an electronic device under the condition that the electronic device generates a random address, and bring continuous use experience to a user.
In a first aspect, an embodiment of the present application provides an apparatus identification method, where the method is applied to a routing apparatus, and includes:
acquiring address information of target electronic equipment, and judging whether the address information of the target electronic equipment is random address information or not;
under the condition that the address information of the target electronic equipment is determined to be random address information, acquiring auxiliary information of the target electronic equipment, and matching the auxiliary information of the target electronic equipment with a preset corresponding table; the auxiliary information of the target electronic equipment is used for representing the model information of the target electronic equipment; the preset corresponding table comprises a plurality of pieces of equipment address information connected with the routing equipment and auxiliary information corresponding to each piece of equipment address information;
and under the condition that the matching degree of the auxiliary information of the target electronic equipment and the auxiliary information corresponding to any equipment address information connected with the routing equipment in the preset corresponding table is greater than or equal to the preset matching degree, adding the address information of the target electronic equipment into the preset corresponding table.
In an alternative of the first aspect, determining whether the address information of the target electronic device is random address information includes:
judging whether a preset character string exists in the address information of the target electronic equipment or not;
and under the condition that the preset character string exists in the address information of the target electronic equipment, determining the address information of the target electronic equipment as random address information.
In yet another alternative of the first aspect, the method further comprises:
under the condition that the preset character string does not exist in the address information of the target electronic equipment, acquiring auxiliary information of the target electronic equipment;
and adding the address information of the target electronic equipment and the auxiliary information of the target electronic equipment into a preset corresponding table.
In another alternative of the first aspect, after the auxiliary information of the target electronic device is obtained, before the auxiliary information of the target electronic device is matched with the preset mapping table, the method further includes:
matching the auxiliary information of the target electronic equipment with a preset first database, and determining the category information of the target electronic equipment; the preset first database comprises a plurality of different equipment model information and category information corresponding to each equipment model information;
matching auxiliary information of the target electronic equipment with a preset corresponding table, comprising:
under the condition that the category information of the target electronic equipment is determined to be the intelligent electronic equipment, matching the auxiliary information of the target electronic equipment with a preset corresponding table; the address information of the intelligent electronic equipment is random address information.
In yet another alternative of the first aspect, the obtaining auxiliary information of the target electronic device includes:
determining data information of the target electronic equipment from the hypertext transfer protocol information sent by the target electronic equipment;
matching the data information of the target electronic equipment with a preset second database; the preset second database comprises a plurality of different pieces of equipment data information connected with the routing equipment and model information corresponding to each piece of equipment data information;
and under the condition that the data information of the target electronic equipment is successfully matched with the preset second database, taking the model information corresponding to the equipment data information connected with the routing equipment in the preset second database as auxiliary information of the target electronic equipment.
In yet another alternative of the first aspect, the obtaining auxiliary information of the target electronic device includes:
acquiring hostname information of target electronic equipment from dynamic host configuration protocol information sent by the target electronic equipment;
and determining the model information of the target electronic equipment according to the hostname information of the target electronic equipment, and taking the model information of the target electronic equipment as auxiliary information of the target electronic equipment.
In a second aspect, an embodiment of the present application provides an apparatus for identifying a device, where the apparatus is applied to a routing device, and includes:
the first acquisition module is used for acquiring the address information of the target electronic equipment and judging whether the address information of the target electronic equipment is random address information or not;
the second acquisition module is used for acquiring the auxiliary information of the target electronic equipment under the condition that the address information of the target electronic equipment is determined to be random address information, and matching the auxiliary information of the target electronic equipment with a preset corresponding table; the auxiliary information of the target electronic equipment is used for representing the model information of the target electronic equipment; the preset corresponding table comprises a plurality of pieces of equipment address information connected with the routing equipment and auxiliary information corresponding to each piece of equipment address information;
the first processing module is used for adding the address information of the target electronic equipment into the preset corresponding table under the condition that the matching degree of the auxiliary information of the target electronic equipment and the auxiliary information corresponding to any one of the equipment address information connected with the routing equipment in the preset corresponding table is larger than or equal to the preset matching degree.
In an alternative of the second aspect, the first obtaining module includes:
the judging unit is used for judging whether a preset character string exists in the address information of the target electronic equipment or not;
the first determining unit is used for determining the address information of the target electronic equipment as random address information under the condition that the preset character string is detected to exist in the address information of the target electronic equipment.
In yet another alternative of the second aspect, the apparatus further comprises:
the third acquisition module is used for acquiring the auxiliary information of the target electronic equipment under the condition that the preset character string does not exist in the address information of the target electronic equipment;
and the second processing module is used for adding the address information of the target electronic equipment and the auxiliary information of the target electronic equipment into the preset corresponding table.
In yet another alternative of the second aspect, the apparatus further comprises:
the third processing module is used for matching the auxiliary information of the target electronic equipment with a preset first database after the auxiliary information of the target electronic equipment is obtained and before the auxiliary information of the target electronic equipment is matched with a preset corresponding table, and determining the category information of the target electronic equipment; the preset first database comprises a plurality of different equipment model information and category information corresponding to each equipment model information;
the second obtaining module is specifically configured to:
under the condition that the category information of the target electronic equipment is determined to be the intelligent electronic equipment, matching the auxiliary information of the target electronic equipment with a preset corresponding table; the address information of the intelligent electronic equipment is random address information.
In yet another alternative of the second aspect, the second obtaining module includes:
the third determining unit is used for determining data information of the target electronic equipment from the hypertext transfer protocol information sent by the target electronic equipment;
the processing unit is used for matching the data information of the target electronic equipment with a preset second database; the preset second database comprises a plurality of different pieces of equipment data information connected with the routing equipment and model information corresponding to each piece of equipment data information;
and the fourth determining unit is used for taking the model information corresponding to the equipment data information connected with the routing equipment in the preset second database as the auxiliary information of the target electronic equipment under the condition that the data information of the target electronic equipment is successfully matched with the preset second database.
In yet another alternative of the second aspect, the second obtaining module further includes:
the acquisition unit is used for acquiring the hostname information of the target electronic equipment from the dynamic host configuration protocol information sent by the target electronic equipment;
and the fifth determining unit is used for determining the model information of the target electronic equipment according to the hostname information of the target electronic equipment and taking the model information of the target electronic equipment as auxiliary information of the target electronic equipment.
In a third aspect, an embodiment of the present application further provides an apparatus for identifying a device, including a processor and a memory; the processor is connected with the memory; a memory for storing executable program code; the processor reads the executable program code stored in the memory to run a program corresponding to the executable program code, so as to execute the device identification method provided by the first aspect of the embodiments of the present application or any implementation manner of the first aspect.
In a fourth aspect, an embodiment of the present application provides a routing device, including the device identification apparatus provided in the implementation manner of the third aspect.
In a fifth aspect, an embodiment of the present application further provides a computer storage medium, where a computer program is stored in the computer storage medium, where the computer program includes program instructions, and when the program instructions are executed by a processor, the apparatus identification method provided in the first aspect of the present application or any implementation manner of the first aspect may be implemented.
It can be understood that the computer storage medium provided in the fifth aspect is used to execute the device identification method provided in the first aspect or any implementation manner of the first aspect, and therefore, beneficial effects that can be achieved by the computer storage medium may refer to the beneficial effects in the device identification method provided in the first aspect or any implementation manner of the first aspect, and are not described herein again.
In the embodiment of the application, whether the address information of the target electronic device is random address information or not can be judged after the address information of the target electronic device is obtained, the auxiliary information of the target electronic device is obtained to be matched with the preset corresponding table under the condition that the address information is determined to be a random address, if the matching degree of the auxiliary information is larger than or equal to the preset matching degree, the obtained address information is added into the preset corresponding table, the fact that the routing device can still accurately and quickly recognize after the target electronic device is replaced with the random address information can be guaranteed, corresponding functions such as application recognition and device recognition can be correspondingly executed, and normal use experience of a user can be guaranteed while safety of the electronic device is improved.
Drawings
In order to more clearly illustrate the technical solutions in the embodiments of the present application, the drawings needed to be used in the embodiments will be briefly described below, and it is obvious that the drawings in the following description are only some embodiments of the present application, and it is obvious for those skilled in the art to obtain other drawings without creative efforts.
Fig. 1 is a schematic architecture diagram of an apparatus identification system according to an embodiment of the present application;
fig. 2 is a schematic flowchart of an apparatus identification method according to an embodiment of the present application;
fig. 3 is a schematic diagram illustrating an effect of a preset mapping table according to an embodiment of the present application;
fig. 4 is a schematic flowchart of another device identification method according to an embodiment of the present application;
fig. 5 is a schematic diagram illustrating an effect of presetting a first database according to an embodiment of the present application;
fig. 6 is a schematic diagram illustrating an effect of another preset mapping table provided in the embodiment of the present application;
fig. 7 is a schematic diagram illustrating an effect of another preset mapping table provided in the embodiment of the present application;
fig. 8 is a schematic structural diagram of an apparatus identification device according to an embodiment of the present application;
fig. 9 is a schematic structural diagram of a routing device according to an embodiment of the present application.
Detailed Description
The technical solutions in the embodiments of the present application will be clearly and completely described below with reference to the drawings in the embodiments of the present application.
The terms "first," "second," "third," and the like in the description and claims of this application and in the above-described drawings are used for distinguishing between different objects and not for describing a particular order. Furthermore, the terms "include" and "have," as well as any variations thereof, are intended to cover a non-exclusive inclusion. For example, a process, method, system, article, or apparatus that comprises a list of steps or elements is not limited to only those steps or elements listed, but may alternatively include other steps or elements not listed, or inherent to such process, method, article, or apparatus.
Referring to fig. 1, fig. 1 is a schematic diagram illustrating an architecture of an equipment identity system according to an embodiment of the present disclosure.
As shown in fig. 1, the device identification system includes a routing device 10 and an electronic device, wherein:
the routing device 10 may be a computer system or device that provides data transformation services across multiple networks, such as, but not limited to, a router, an electronic device that may support hotspots, and the like. Taking the router device 10 as an example, the router may allocate an Internet Protocol (IP) address to an electronic device to be connected to the router, where the IP address may correspond to a Media Access Control (MAC) address of the electronic device, and transmit or receive data to or from the respective corresponding electronic devices through different IP addresses. When the electronic device which has completed connection with the router is connected with the router again, the router can accurately identify the electronic device through the MAC address sent by the electronic device and execute the corresponding application function by combining the data transmitted by the electronic device. The connection mode of the router and the electronic device can be wireless connection or wired connection.
The electronic device may be one or more electronic devices, which may include electronic device 20a, electronic device 20b, electronic device 20c, and so on. The electronic device can be connected with the routing device 10 to realize data transmission with different electronic devices. Taking the router device 10 as an example, the electronic device may establish a connection with the router through a wireless connection or a wired connection. Possibly, when the electronic device is wirelessly connected with the router, the electronic device can search the name of the router to be wirelessly connected by turning on a wireless local area network in the system setting and correspondingly input the router password to realize connection with the router. Possibly, when the electronic device is in wired connection with the router, the electronic device can find the network corresponding to the name of the router in the network and Internet settings and input the password to realize connection with the router.
The electronic device related in the embodiment of the present application may be a mobile phone, a tablet Computer, a desktop Computer, a laptop Computer, a notebook Computer, an Ultra-mobile Personal Computer (UMPC), a handheld Computer, a netbook, a Personal Digital Assistant (PDA), a routing device, a virtual reality device, and the like.
Referring to fig. 2, fig. 2 is a schematic flowchart illustrating an apparatus identification method according to an embodiment of the present disclosure.
As shown in fig. 2, the device identification method is applied to a routing device, and includes:
step 201, obtaining address information of the target electronic device, and determining whether the address information of the target electronic device is random address information.
Specifically, after the routing device completes connection with the target electronic device, the routing device may obtain the MAC address of the target electronic device, and determine whether the MAC address is a generated random address.
Specifically, the routing device is taken as a router, and the target electronic device and the router are in wireless connection. The user can find out and open the wireless local area network in the system setting of the target electronic equipment so as to search the surrounding wireless local area network, and when the target electronic equipment searches the name corresponding to the router in the wireless local area network, the user can select to establish connection with the router. Possibly, when the target electronic device is connected with the router for the first time, the connection is needed to be completed according to the password input by the user and corresponding to the router. It is possible that when the target electronic device is not initially connected to the router, the connection with the router may be automatically completed when the target electronic device opens the wireless local area network. When the target electronic device is not initially connected with the router, if the target electronic device does not select to record the router password when being connected with the router each time, the router password still needs to be input again to complete connection when the target electronic device searches the name corresponding to the router.
Further, after the router completes connection with the target electronic device, the MAC address sent by the target electronic device may be acquired, and whether the target electronic device is the electronic device that is connected for the first time may be determined by combining the saved and allocated address correspondence. Specifically, the router may search for whether the obtained MAC address of the target electronic device exists in a relationship between the MAC address of the connected electronic device and the IP address corresponding to the MAC address, and if not, characterize the target electronic device as a newly connected electronic device or an electronic device with a modified MAC address, and if so, characterize the target electronic device as a connected electronic device.
When determining that the obtained MAC address of the target electronic device does not exist in the relationship between the MAC address of the connected electronic device and the respective corresponding IP address, which is already stored in the router, it may be further determined whether the MAC address of the target electronic device is the generated random MAC address. It should be noted that the random MAC address is automatically generated by the electronic device connected to the router, that is, after the electronic device establishes a connection with the router by using the MAC address, the electronic device establishes a connection with the router again by using the generated random MAC address.
Step 202, under the condition that the address information of the target electronic device is determined to be random address information, acquiring auxiliary information of the target electronic device, and matching the auxiliary information of the target electronic device with a preset corresponding table.
Specifically, the auxiliary information of the target electronic device is used for characterizing model information of the target electronic device. The model information of the electronic device may be, but is not limited to, a brand, a model, system version information, and the like of the electronic device.
Specifically, the preset mapping table includes a plurality of device address information connected to the routing device and auxiliary information corresponding to each device address information. Specifically, the routing device may obtain the MAC address of each new electronic device and the auxiliary information corresponding to each new electronic device after the initial connection with each new electronic device is successful, and store the MAC addresses and the auxiliary information in the preset corresponding table one by one in a corresponding manner. For example, taking a routing device as a router as an example, refer to fig. 3 for a schematic effect diagram of a preset mapping table provided in the embodiment of the present application. As shown in fig. 3, the preset correspondence table can be viewed by the client where the login router is located, and three pieces of device auxiliary information currently connected with the router, respective corresponding MAC addresses, and IP addresses allocated in correspondence with the respective MAC addresses are presented in the preset correspondence table. The MAC address of the equipment with the auxiliary information of Ipad8 is 0C, EE, E6, FE, 01, CF, and the IP address correspondingly allocated to the router is 192.168.3.103; the MAC address of the device with the auxiliary information of Miipcam is C4:6A: B7:09:59:08, and the IP address correspondingly allocated to the router is 192.168.3.105; the MAC address of the device with auxiliary information of Huaweix10 is 34:60: B3:10: F6:1E, and the corresponding allocated IP address of the router is 192.168.3.106. In the preset correspondence table, connection valid time corresponding to each device is also displayed, for example, the valid time of the device with auxiliary information of Ipaid8 is 00:38:48, the valid time of the device with auxiliary information of Miipcam is 01:48:07, and the valid time of the device with auxiliary information of Huaweix10 is 01:40: 26.
Specifically, after determining that the MAC address of the target electronic device belongs to the random MAC address, the routing device may obtain auxiliary information of the target electronic device through data information sent or received by the target electronic device, and match the obtained auxiliary information with auxiliary information stored in a preset correspondence table of the routing device.
Step 203, adding the address information of the target electronic device to the preset corresponding table when the matching degree of the auxiliary information of the target electronic device and the auxiliary information corresponding to any device address information connected with the routing device in the preset corresponding table is greater than or equal to the preset matching degree.
Specifically, the routing device may match auxiliary information of the target electronic device with any one of auxiliary information in a preset correspondence table, and when the matching degree is greater than or equal to the preset matching degree, may determine that the target electronic device is an electronic device already connected to the routing device, and add the MAC address of the target electronic device to the MAC address corresponding to the auxiliary information of the target electronic device in the preset correspondence table.
It should be noted that the aforementioned preset matching degree may be set by the routing device by default, for example, the preset matching degree may be set by default to 100%, and the preset matching degree in this embodiment is not limited to 100%.
In the embodiment of the application, whether the address information of the target electronic device is random address information or not can be judged after the address information of the target electronic device is obtained, the auxiliary information of the target electronic device is obtained to be matched with the preset corresponding table under the condition that the address information is determined to be a random address, if the matching degree of the auxiliary information is larger than or equal to the preset matching degree, the obtained address information is added into the preset corresponding table, the fact that the routing device can still accurately and quickly recognize after the target electronic device is replaced with the random address information can be guaranteed, corresponding functions such as application recognition and device recognition can be correspondingly executed, and normal use experience of a user can be guaranteed while safety of the electronic device is improved.
As an embodiment of the present application, refer to a flowchart of another device identification method shown in fig. 4.
As shown in fig. 4, the device identification method is applied to a routing device, and includes:
step 401, determining whether a preset character string exists in the address information of the target electronic device.
Step 402, determining the address information of the target electronic device as random address information under the condition that the preset character string exists in the address information of the target electronic device.
Specifically, to better distinguish whether the obtained target electronic device is an electronic device already connected to the routing device, whether the MAC address is a random MAC address may be determined according to a character string corresponding to the MAC address of the target electronic device. Specifically, for example, when the router is used as a router, the router may determine whether the character string at the preset position is a preset character string according to the character string corresponding to the MAC address of the target electronic device, and if it is detected that the character string at the preset position is the preset character string, the MAC address of the target electronic device is used as a random MAC address.
Illustratively, the target electronic device MAC address is 36: 43:6E:6A:9A:09 (the MAC address is represented by 12 16-ary numbers), and the second bit of the MAC address in the preset character string in the router is 2, 6, a, or E, that is, when the router detects that the second bit character string in the acquired MAC address of the target electronic device is any one of 2, 6, a, or E, it may determine that the MAC address of the target electronic device is a random MAC address.
And step 403, acquiring auxiliary information of the target electronic equipment, and matching the auxiliary information of the target electronic equipment with a preset corresponding table.
Specifically, step 403 is identical to step 202, and is not described herein again.
Step 404, when the matching degree between the auxiliary information of the target electronic device and the auxiliary information corresponding to any one of the device address information connected with the routing device in the preset correspondence table is greater than or equal to the preset matching degree, adding the address information of the target electronic device to the preset correspondence table.
Specifically, step 404 is identical to step 203, and is not described herein again.
Step 405, acquiring auxiliary information of the target electronic device when detecting that the preset character string does not exist in the address information of the target electronic device.
And step 406, adding the address information of the target electronic device and the auxiliary information of the target electronic device to a preset corresponding table.
Specifically, when the routing device detects that the character string corresponding to the MAC address of the target electronic device does not have the preset character string, the target electronic device may be used as the electronic device to be connected for the first time, and then the auxiliary information of the target electronic device may be further obtained and added to the preset correspondence table together with the MAC address, so that the routing device may quickly identify when the electronic device generates the random MAC address and is connected to the routing device.
As another embodiment of the present application, after acquiring the auxiliary information of the target electronic device, before matching the auxiliary information of the target electronic device with the preset mapping table, the method further includes:
matching the auxiliary information of the target electronic equipment with a preset first database, and determining the category information of the target electronic equipment; the preset first database comprises a plurality of different pieces of equipment model information and category information corresponding to each piece of equipment model information;
matching the auxiliary information of the target electronic equipment with a preset corresponding table, comprising:
and matching the auxiliary information of the target electronic equipment with a preset corresponding table under the condition that the category information of the target electronic equipment is determined to be the intelligent electronic equipment.
Specifically, after it is determined that the MAC address of the target electronic device belongs to the random MAC address, some MAC addresses of the non-intelligent electronic devices may also exist in the random MAC address, where the MAC addresses of the non-intelligent electronic devices meet the condition of determining as the random MAC address, for example, a preset character string exists in a character string corresponding to the MAC address of the non-intelligent electronic device. It can be understood that the non-intelligent electronic device is an intelligent electronic device which cannot generate a random MAC address, and in order to more accurately distinguish the intelligent electronic device which can generate the random MAC address from the non-intelligent electronic device which satisfies that the MAC address belongs to the random MAC address, the routing device may match the auxiliary information of the target electronic device with the preset first database after acquiring the auxiliary information of the target electronic device to determine the category of the target electronic device, and match the auxiliary information of the target electronic device with the preset correspondence table in a case where the target electronic device is determined to be the intelligent device according to the category of the target electronic device.
Specifically, taking a routing device as a router as an example, refer to an effect schematic diagram of presetting a first database provided in the embodiment of the present application shown in fig. 5. As shown in fig. 5, the preset first database can be checked by logging in the client where the router is located, and the preset first database includes three pieces of device auxiliary information currently connected with the router, respective corresponding device categories, and whether each respective corresponding device belongs to the intelligent electronic device. When the auxiliary information of the target electronic equipment acquired by the router is Ipad8, the auxiliary information can be matched with a preset first database to obtain that the equipment type is a flat plate, and the target electronic equipment is determined to be intelligent electronic equipment; when the router acquires that the auxiliary information of the target electronic equipment is Miipcam, the router can be matched with a preset first database to correspondingly acquire that the equipment type is a camera, and the target electronic equipment is determined not to be intelligent electronic equipment; when the auxiliary information of the target electronic equipment acquired by the router is Huaweix10, the auxiliary information can be matched with a preset first database to obtain that the equipment type is a mobile phone, and the target electronic equipment is determined to be intelligent electronic equipment. It is to be understood that the embodiments of the present application are not limited to the auxiliary information of the electronic device mentioned above.
As another embodiment of the present application, acquiring auxiliary information of a target electronic device includes:
determining data information of the target electronic equipment from hypertext transfer protocol information sent by the target electronic equipment;
matching the data information of the target electronic equipment with a preset second database; the preset second database can comprise a plurality of different pieces of equipment data information connected with the routing equipment and model information corresponding to each piece of equipment data information;
and under the condition that the data information of the target electronic equipment is successfully matched with the preset second database, taking the model information corresponding to the equipment data information connected with the routing equipment in the preset second database as auxiliary information of the target electronic equipment.
Specifically, after the routing device is connected with the target electronic device, the routing device may forward data sent by the target electronic device to other devices, where when the data sent by the target electronic device is a Hypertext Transfer Protocol (HTTP), data information may be obtained from user-agent information of the HTTP Protocol according to a configuration file preset by the routing device in a data transmission channel, and the data information is matched with a preset second database, and model information corresponding to the data information in the preset second database is used as auxiliary information of the target electronic device when matching is successful.
As another embodiment of the present application, acquiring auxiliary information of a target electronic device may further include:
acquiring hostname information of target electronic equipment from dynamic host configuration protocol information sent by the target electronic equipment;
and determining the model information of the target electronic equipment according to the hostname information of the target electronic equipment, and taking the model information of the target electronic equipment as auxiliary information of the target electronic equipment.
Specifically, after the routing device completes connection with the target electronic device, the target electronic device may request an IP address from the routing device through a Dynamic Host Configuration Protocol (DCHP), and the routing device may obtain the hostname information from header information of the DCHP Protocol sent by the target electronic device. The hostname information obtained by the routing device from the electronic devices of different brands is different, for example, when the routing device is taken as a router, and the possible electronic devices wirelessly connected with the router are Huacheng series, the hostname information obtained by the router can be in the form of a device specific model plus a character string. When the possible electronic device wirelessly connected with the router is an apple series, the hostname information acquired by the router may be in the form of a device specific model. When the possible electronic device wirelessly connected with the router is a millet series, the hostname information acquired by the router may be in the form of a device specific model plus a user name.
As another embodiment of the present application for acquiring the auxiliary information of the target electronic device, when the target electronic device supports a Multicast Domain Name System (MDNS), the MDNS packet may be further sent to the routing device, and the routing device may acquire the device model of the target electronic device according to the Domain Name information in the MDNS packet. The MDNS packet may not be limited to include a domain name, a multicast address, a device model, an IP address, etc. of the target electronic device.
As another embodiment of the present application, for obtaining the auxiliary information of the target electronic device, the routing device may further obtain a device identifier of the target electronic device according to a broadcast sent by the connected target electronic device. For example, taking a router device as an example, when a target electronic device is a hua-qi series, the target electronic device, after being connected to the router, may send a User Datagram Protocol (UDP) broadcast to any device connected to the router, and the router may extract device uuid information from the UDP broadcast after receiving the UDP broadcast sent by the target electronic device, and use the device uuid information as a device identifier of the hua-qi series electronic device, that is, when the router extracts the device uuid information from the broadcast sent by the target electronic device, it may determine that the target electronic device is the hua-qi series electronic device.
As another embodiment of the present application, for obtaining the auxiliary information of the target electronic device, the routing device may further obtain a device model of the target electronic device according to a request sent by an application executed by the target electronic device. For example, when the target electronic device uses the application program, the application program sends out an acquisition request, and when the routing device receives the acquisition request sent by the application program, the device model can be extracted from the acquisition request. If the routing device extracts the uid information or the m2 information from the acquisition request, the device model information included in the uid information or the m2 information may be the device model of the target electronic device.
With reference to the above embodiment of obtaining auxiliary information of a target electronic device, please refer to fig. 6, where fig. 6 shows an effect schematic diagram of another preset mapping table provided in the embodiment of the present application. As shown in fig. 6, a preset correspondence table can be viewed by a client where a login router is located, and MAC addresses of three devices currently connected to the router, host name (Hostname) information, Domain name (Domain name) information, and device type (Devicetype) information of respective corresponding MAC addresses are presented in the preset correspondence table, where the host name (Hostname) information, the Domain name (Domain name) information, and the device type (Devicetype) information can be used to represent auxiliary information of an electronic device. Specifically, host name (Hostname) information, Domain name (Domain name) information, and device type (Devicetype) information of an electronic device having a MAC address of 0C: EE: E6: FE:01: CF are Ipad, Ipad8, respectively, host name (Hostname) information, Domain name (Domain name) information, and device type (Devicetype) information of an electronic device having a MAC address of C4:6A: B7:09:59:08 are Miipcam, and Miipcam, respectively, host name (Hostname) information, Domain name (Domain name) information, and device type (Devicetype) information of an electronic device having a MAC address of 34:60: B3:10: F6:1E are huidname, Huawei, and Huaweix10, respectively.
With reference to fig. 6, a schematic diagram of an effect of another preset mapping table provided in the embodiment of the present application shown in fig. 7 may also be referred to. As shown in FIG. 7, MAC addresses corresponding to electronic devices having Hostname (Hostname) information, Domain name (Domain name) information, and device type (DeviceType) information of Huawei, and Huaweix10 respectively include 34:60: B3:10: F6:1E and 3E:43:6E:6A:9A:09, the MAC address characterizing the electronic device becomes a random MAC address, and 3E:43:6E:6A:9A:09 is the current MAC address of the electronic device.
Referring to fig. 8, fig. 8 illustrates an apparatus identifier according to an embodiment of the present disclosure.
As shown in fig. 8, the apparatus identification device 800 may include at least a first obtaining module 801, a second obtaining module 802, and a first processing module 803, where:
a first obtaining module 801, configured to obtain address information of a target electronic device, and determine whether the address information of the target electronic device is random address information;
a second obtaining module 802, configured to obtain auxiliary information of the target electronic device and match the auxiliary information of the target electronic device with a preset mapping table when it is determined that the address information of the target electronic device is random address information; the auxiliary information of the target electronic equipment is used for representing the model information of the target electronic equipment; the preset corresponding table comprises a plurality of pieces of equipment address information connected with the routing equipment and auxiliary information corresponding to each piece of equipment address information;
the first processing module 803 is configured to, when a matching degree between the auxiliary information of the target electronic device and auxiliary information corresponding to any one of the device address information connected to the routing device in the preset correspondence table is greater than or equal to the preset matching degree, add the address information of the target electronic device to the preset correspondence table.
In some possible embodiments, the first obtaining module 801 includes:
the judging unit is used for judging whether a preset character string exists in the address information of the target electronic equipment or not;
the first determining unit is used for determining the address information of the target electronic equipment as random address information under the condition that the preset character string is detected to exist in the address information of the target electronic equipment.
In some possible embodiments, the device identification apparatus 800 further includes:
the third acquisition module is used for acquiring the auxiliary information of the target electronic equipment under the condition that no preset character string exists in the address information of the target electronic equipment;
and the second processing module is used for adding the address information of the target electronic equipment and the auxiliary information of the target electronic equipment into the preset corresponding table.
In some possible embodiments, the device identification apparatus 800 further includes:
the third processing module is used for matching the auxiliary information of the target electronic equipment with a preset first database after the auxiliary information of the target electronic equipment is obtained and before the auxiliary information of the target electronic equipment is matched with a preset corresponding table, and determining the category information of the target electronic equipment; the preset first database comprises a plurality of different equipment model information and category information corresponding to each equipment model information;
the second obtaining module 802 is specifically configured to:
under the condition that the category information of the target electronic equipment is determined to be intelligent electronic equipment, matching the auxiliary information of the target electronic equipment with a preset corresponding table; the address information of the intelligent electronic equipment is random address information.
In some possible embodiments, the second obtaining module 802 includes:
the third determining unit is used for determining data information of the target electronic equipment from the hypertext transfer protocol information sent by the target electronic equipment;
the processing unit is used for matching the data information of the target electronic equipment with a preset second database; the preset second database comprises a plurality of different pieces of equipment data information connected with the routing equipment and model information corresponding to each piece of equipment data information;
and the fourth determining unit is used for taking the model information corresponding to the equipment data information connected with the routing equipment in the preset second database as the auxiliary information of the target electronic equipment under the condition that the data information of the target electronic equipment is successfully matched with the preset second database.
In some possible embodiments, the second obtaining module 802 further includes:
the acquisition unit is used for acquiring hostname information of the target electronic equipment from the dynamic host configuration protocol information sent by the target electronic equipment;
and the fifth determining unit is used for determining the model information of the target electronic equipment according to the hostname information of the target electronic equipment and taking the model information of the target electronic equipment as auxiliary information of the target electronic equipment.
In the embodiment of the application, whether the address information of the target electronic device is random address information or not can be judged after the address information of the target electronic device is obtained, the auxiliary information of the target electronic device is obtained to be matched with the preset corresponding table under the condition that the address information is determined to be a random address, if the matching degree of the auxiliary information is larger than or equal to the preset matching degree, the obtained address information is added into the preset corresponding table, the fact that the routing device can still accurately and quickly recognize after the target electronic device is replaced with the random address information can be guaranteed, corresponding functions such as application recognition and device recognition can be correspondingly executed, and normal use experience of a user can be guaranteed while safety of the electronic device is improved.
Referring to fig. 9, fig. 9 is a schematic structural diagram of a routing device according to an embodiment of the present disclosure.
As shown in fig. 9, the routing device 900 may include: at least one processor 901, at least one network interface 904, a user interface 903, memory 905, and at least one communication bus 902.
The communication bus 902 can be used for realizing the connection communication of the above components.
The user interface 903 may include keys, and the selectable user interfaces may include standard wired interfaces and wireless interfaces.
The network interface 904 may optionally include a bluetooth module, an NFC module, a Wi-Fi module, or the like.
Processor 901 may include one or more processing cores, among other things. The processor 901 interfaces with various interfaces and circuitry throughout the electronic device 900 to perform various functions of the routing device 900 and process data by executing or executing instructions, programs, code sets, or instruction sets stored in the memory 905, as well as invoking data stored in the memory 905. Optionally, the processor 901 may be implemented in at least one hardware form of DSP, FPGA, and PLA. The processor 901 may integrate one or a combination of a CPU, a GPU, a modem, and the like. The CPU mainly processes an operating system, a user interface, an application program and the like; the GPU is used for rendering and drawing the content required to be displayed by the display screen; the modem is used to handle wireless communications. It is understood that the modem may not be integrated into the processor 901, but may be implemented by a single chip.
The memory 905 may include a RAM or a ROM. Optionally, the memory 905 includes a non-transitory computer readable medium. The memory 905 may be used to store instructions, programs, code, sets of codes, or sets of instructions. The memory 905 may include a program storage area and a data storage area, wherein the program storage area may store instructions for implementing an operating system, instructions for at least one function (such as a touch function, a sound playing function, an image playing function, etc.), instructions for implementing the above-described method embodiments, and the like; the storage data area may store data and the like referred to in the above respective method embodiments. The memory 905 may optionally be at least one memory device located remotely from the processor 901. As shown in fig. 9, the memory 905, which is a type of computer storage medium, may include therein an operating system, a network communication module, a user interface module, and a device identification application program.
In particular, the processor 901 may be configured to invoke a device identification application stored in the memory 905, and specifically perform the following operations:
acquiring address information of target electronic equipment, and judging whether the address information of the target electronic equipment is random address information or not;
under the condition that the address information of the target electronic equipment is determined to be random address information, acquiring auxiliary information of the target electronic equipment, and matching the auxiliary information of the target electronic equipment with a preset corresponding table; the auxiliary information of the target electronic equipment is used for representing the model information of the target electronic equipment; the preset corresponding table comprises a plurality of pieces of equipment address information connected with the routing equipment and auxiliary information corresponding to each piece of equipment address information;
and under the condition that the matching degree of the auxiliary information of the target electronic equipment and the auxiliary information corresponding to any equipment address information connected with the routing equipment in the preset corresponding table is greater than or equal to the preset matching degree, adding the address information of the target electronic equipment into the preset corresponding table.
In some possible embodiments, when the processor 901 determines whether the address information of the target electronic device is random address information, the following specific steps are performed:
judging whether a preset character string exists in the address information of the target electronic equipment or not;
and under the condition that the preset character string exists in the address information of the target electronic equipment, determining that the address information of the target electronic equipment is random address information.
In some possible embodiments, the processor 901 further performs:
under the condition that the preset character string does not exist in the address information of the target electronic equipment, acquiring auxiliary information of the target electronic equipment;
and adding the address information of the target electronic equipment and the auxiliary information of the target electronic equipment into a preset corresponding table.
In some possible embodiments, after the processor 901 obtains the auxiliary information of the target electronic device, before matching the auxiliary information of the target electronic device with the preset correspondence table, the processor is further configured to perform:
matching the auxiliary information of the target electronic equipment with a preset first database, and determining the category information of the target electronic equipment; the preset first database comprises a plurality of different equipment model information and category information corresponding to each equipment model information;
when the processor 901 matches the auxiliary information of the target electronic device with the preset mapping table, it is configured to:
under the condition that the category information of the target electronic equipment is determined to be the intelligent electronic equipment, matching the auxiliary information of the target electronic equipment with a preset corresponding table; the address information of the intelligent electronic equipment is random address information.
In some possible embodiments, the processor 901, when obtaining the auxiliary information of the target electronic device, is configured to perform:
determining data information of the target electronic equipment from hypertext transfer protocol information sent by the target electronic equipment;
matching the data information of the target electronic equipment with a preset second database; the preset second database comprises a plurality of different pieces of equipment data information connected with the routing equipment and model information corresponding to each piece of equipment data information;
and under the condition that the data information of the target electronic equipment is successfully matched with the preset second database, taking the model information corresponding to the equipment data information connected with the routing equipment in the preset second database as auxiliary information of the target electronic equipment.
In some possible embodiments, the processor 901, when obtaining the auxiliary information of the target electronic device, is configured to perform:
acquiring hostname information of target electronic equipment from dynamic host configuration protocol information sent by the target electronic equipment;
and determining the model information of the target electronic equipment according to the hostname information of the target electronic equipment, and taking the model information of the target electronic equipment as auxiliary information of the target electronic equipment.
Embodiments of the present application also provide a computer-readable storage medium, which stores instructions that, when executed on a computer or a processor, cause the computer or the processor to perform one or more of the steps in the embodiments shown in fig. 2 or fig. 4. The respective constituent modules of the above-described routing device, if implemented in the form of software functional units and sold or used as independent products, may be stored in the computer-readable storage medium.
In the above embodiments, the implementation may be wholly or partially realized by software, hardware, firmware, or any combination thereof. When implemented in software, may be implemented in whole or in part in the form of a computer program product. The computer program product includes one or more computer instructions. When loaded and executed on a computer, cause the processes or functions described in accordance with the embodiments of the application to occur, in whole or in part. The computer may be a general purpose computer, a special purpose computer, a network of computers, or other programmable device. The computer instructions may be stored in or transmitted over a computer-readable storage medium. The computer instructions may be transmitted from one website, computer, server, or data center to another website, computer, server, or data center by wire (e.g., coaxial cable, fiber optic, Digital Subscriber Line (DSL)), or wirelessly (e.g., infrared, wireless, microwave, etc.). The computer-readable storage medium can be any available medium that can be accessed by a computer or a data storage device, such as a server, a data center, etc., that incorporates one or more of the available media. The usable medium may be a magnetic medium (e.g., floppy Disk, hard Disk, magnetic tape), an optical medium (e.g., Digital Versatile Disk (DVD)), or a semiconductor medium (e.g., Solid State Disk (SSD)), among others.
It will be understood by those skilled in the art that all or part of the processes of the methods of the embodiments described above can be implemented by a computer program, which can be stored in a computer-readable storage medium, and can include the processes of the embodiments of the methods described above when the program is executed. And the aforementioned storage medium includes: various media that can store program codes, such as ROM, RAM, magnetic or optical disks. The technical features in the present examples and embodiments may be arbitrarily combined without conflict.
The above-described embodiments are only preferred embodiments of the present application, and are not intended to limit the scope of the present application, and various modifications and improvements made to the technical solutions of the present application by those skilled in the art without departing from the design spirit of the present application should fall within the protection scope defined by the claims of the present application.

Claims (10)

1. A device identification method is applied to a routing device, and is characterized by comprising the following steps:
acquiring address information of target electronic equipment, and judging whether the address information of the target electronic equipment is random address information or not;
under the condition that the address information of the target electronic equipment is determined to be random address information, acquiring auxiliary information of the target electronic equipment, and matching the auxiliary information of the target electronic equipment with a preset corresponding table; the auxiliary information of the target electronic equipment is used for representing the model information of the target electronic equipment; the preset corresponding table comprises a plurality of pieces of equipment address information connected with the routing equipment and auxiliary information corresponding to each piece of equipment address information;
and under the condition that the matching degree of the auxiliary information of the target electronic equipment and the auxiliary information corresponding to any equipment address information connected with the routing equipment in the preset corresponding table is greater than or equal to the preset matching degree, adding the address information of the target electronic equipment into the preset corresponding table.
2. The method of claim 1, wherein the determining whether the address information of the target electronic device is random address information comprises:
judging whether a preset character string exists in the address information of the target electronic equipment or not;
and under the condition that the preset character string exists in the address information of the target electronic equipment, determining that the address information of the target electronic equipment is random address information.
3. The method of claim 2, further comprising:
under the condition that the preset character string does not exist in the address information of the target electronic equipment, acquiring auxiliary information of the target electronic equipment;
and adding the address information of the target electronic equipment and the auxiliary information of the target electronic equipment into the preset corresponding table.
4. The method according to claim 1, wherein after the obtaining of the auxiliary information of the target electronic device and before the matching of the auxiliary information of the target electronic device with a preset mapping table, the method further comprises:
matching the auxiliary information of the target electronic equipment with a preset first database, and determining the category information of the target electronic equipment; the preset first database comprises a plurality of different pieces of equipment model information and category information corresponding to each piece of equipment model information;
the matching the auxiliary information of the target electronic device with a preset corresponding table comprises:
matching the auxiliary information of the target electronic equipment with a preset corresponding table under the condition that the category information of the target electronic equipment is determined to be intelligent electronic equipment; the address information of the intelligent electronic equipment is random address information.
5. The method of claim 4, wherein the obtaining the auxiliary information of the target electronic device comprises:
determining data information of the target electronic equipment from hypertext transfer protocol information sent by the target electronic equipment;
matching the data information of the target electronic equipment with a preset second database; the preset second database comprises a plurality of different pieces of equipment data information connected with the routing equipment and model information corresponding to each piece of equipment data information;
and under the condition that the data information of the target electronic equipment is successfully matched with the preset second database, taking the model information corresponding to the equipment data information connected with the routing equipment in the preset second database as the auxiliary information of the target electronic equipment.
6. The method according to claim 4 or 5, wherein the obtaining the auxiliary information of the target electronic device comprises:
acquiring hostname information of the target electronic equipment from dynamic host configuration protocol information sent by the target electronic equipment;
and determining the model information of the target electronic equipment according to the hostname information of the target electronic equipment, and taking the model information of the target electronic equipment as auxiliary information of the target electronic equipment.
7. An apparatus for identifying a device, the apparatus being applied to a routing device, comprising:
the first acquisition module is used for acquiring the address information of the target electronic equipment and judging whether the address information of the target electronic equipment is random address information or not;
the second acquisition module is used for acquiring auxiliary information of the target electronic equipment under the condition that the address information of the target electronic equipment is determined to be random address information, and matching the auxiliary information of the target electronic equipment with a preset corresponding table; the auxiliary information of the target electronic equipment is used for representing the model information of the target electronic equipment; the preset corresponding table comprises a plurality of pieces of equipment address information connected with the routing equipment and auxiliary information corresponding to each piece of equipment address information;
the first processing module is configured to add the address information of the target electronic device to the preset correspondence table when a matching degree between the auxiliary information of the target electronic device and auxiliary information corresponding to any one of the device address information connected to the routing device in the preset correspondence table is greater than or equal to a preset matching degree.
8. An apparatus identification device, comprising a processor, a memory, and a communication interface;
the processor is connected with the memory and the communication interface;
the memory for storing executable program code;
the processor runs a program corresponding to the executable program code by reading the executable program code stored in the memory for performing the method of any one of claims 1-6.
9. A routing device, characterized in that it comprises the device identification means of claim 8.
10. A computer-readable storage medium, on which a computer program is stored, which, when being executed by a processor, carries out the method according to any one of claims 1-6.
CN202110017163.0A 2021-01-07 2021-01-07 Equipment identification method, device, storage medium and routing equipment Pending CN114745324A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202110017163.0A CN114745324A (en) 2021-01-07 2021-01-07 Equipment identification method, device, storage medium and routing equipment

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202110017163.0A CN114745324A (en) 2021-01-07 2021-01-07 Equipment identification method, device, storage medium and routing equipment

Publications (1)

Publication Number Publication Date
CN114745324A true CN114745324A (en) 2022-07-12

Family

ID=82274306

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202110017163.0A Pending CN114745324A (en) 2021-01-07 2021-01-07 Equipment identification method, device, storage medium and routing equipment

Country Status (1)

Country Link
CN (1) CN114745324A (en)

Similar Documents

Publication Publication Date Title
US11310239B2 (en) Network connection method, hotspot terminal and management terminal
JP6726426B2 (en) Login-free method and device between terminals
WO2017024842A1 (en) Internet access authentication method, client, computer storage medium
US10516666B2 (en) Authentication method, apparatus, and system
WO2020007158A1 (en) Network access method and apparatus
CN111405042B (en) Electronic device discovery method and device, storage medium and electronic device
US20160323331A1 (en) Electronic share server, screen sharing method, and program for electronic share server
KR20210110335A (en) Smart device network configuration method and related devices
CN105306485A (en) Network access authentication methods, authentication server and authentication system
KR102248755B1 (en) Network system, access point and connecting method thereof
CN105959188B (en) Method and device for controlling user terminal to be on-line
CN108093390B (en) Intelligent device discovery method based on characteristic information
US20120213213A1 (en) Method of pairing computer and wireless electronic device
CN106165497B (en) Method implemented by a communication terminal, corresponding terminal and storage medium
CN114697879B (en) Bluetooth pairing method, electronic device, chip and storage medium
WO2017088294A1 (en) Method and device for establishing wireless connection
CN107534859B (en) Network authentication method, client, terminal equipment and platform
CN112333062A (en) Control method and control device for household equipment and computer readable storage medium
JP6406045B2 (en) Karaoke system, address lease server, management server, karaoke equipment
CN108737350B (en) Information processing method and client
CN114745324A (en) Equipment identification method, device, storage medium and routing equipment
KR20130123149A (en) Method for data network access authentication and an electronic device thereof
US9781757B2 (en) Connection information sharing server, a method of sharing connection information, and a program for connection information sharing server
CN108476166B (en) Communication method, mobile terminal, release terminal and communication system
KR102633012B1 (en) A system for providing USB tethering services and method thereof

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination