Abnormality detection method and related equipment

The server detects and confirms the number of terminal devices with abnormal Bluetooth peripherals, and sends abnormal information to avoid large-scale pairing notifications, which solves the problem of pairing notification harassment caused by Bluetooth attacks and improves data security.

CN119277390APending Publication Date: 2025-01-07HONOR DEVICE CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202310839458.5
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2023-07-07
Publication Date
2025-01-07

AI Technical Summary

Technical Problem

During the Bluetooth attack incident, a malicious attacker caused a large-scale terminal device to output pairing notifications by forging a close discovery message, which affected the user experience. How to avoid the large-scale terminal devices output pairing notifications.

Method used

The server determines the number of triggered terminal devices. If the number is greater than the preset value, determines that the Bluetooth peripheral is an abnormal Bluetooth peripheral, and sends exception information to the terminal device in the cell where it is located, which will be triggered by the abnormal Bluetooth peripheral in advance. The terminal device that outputs pairing notifications sends exception information to avoid discarding near discovery messages.

Benefits of technology

It effectively avoids abnormal Bluetooth peripherals triggering the output of pairing notifications of terminal devices within a large range, reducing the probability of data leakage of abnormal Bluetooth connections and ensuring data security.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119277390A_ABST
    Figure CN119277390A_ABST
Patent Text Reader

Abstract

According to the anomaly detection method and the related equipment, in the method, if the number of triggered terminal equipment is larger than a preset value, it is determined that a Bluetooth peripheral is an abnormal Bluetooth peripheral, and abnormal information is sent to the terminal equipment of a cell where the Bluetooth peripheral is located; wherein the triggered terminal equipment refers to terminal equipment which is triggered by the Bluetooth peripheral to output a pairing notification, the pairing notification is used for notifying that the triggered terminal equipment is allowed to establish Bluetooth pairing with the Bluetooth peripheral, and the abnormal information is used for indicating that the Bluetooth peripheral is an abnormal Bluetooth peripheral. According to the embodiment of the invention, the abnormal information can be sent to the terminal equipment which can be triggered by the abnormal Bluetooth peripheral to output the pairing notification in advance, so that the terminal equipment can discard the approaching discovery message when receiving the abnormal information, and the situation that the abnormal Bluetooth peripheral triggers the terminal equipment in a large range to output the pairing notification is avoided.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application relates to the field of terminal technology, and in particular to an anomaly detection method and related equipment. Background Art

[0002] In order to facilitate pairing and connection, pairing and connection can be completed based on proximity discovery technology. Specifically, the Bluetooth peripheral can send a proximity discovery message. When the terminal device scans the proximity discovery message sent by the Bluetooth peripheral, the physical distance between the Bluetooth peripheral and the terminal device can be determined based on the proximity discovery message. When the terminal device determines that the physical distance between the Bluetooth peripheral and the terminal device is within the first range, the terminal device finds that the Bluetooth peripheral is nearby and can output a pairing notification to pair with the Bluetooth peripheral and establish a Bluetooth connection.

[0003] However, with the continuous expansion of Bluetooth communication application scenarios, Bluetooth attacks are becoming more and more common. For example, after knowing the format of the proximity discovery message, a malicious attacker can send a forged proximity discovery message at maximum power, causing terminal devices in a large range to output pairing notifications. These pairing notifications will cause harassment to users and affect their experience. Therefore, how to prevent terminal devices in a large range from outputting pairing notifications is an urgent problem to be solved. Summary of the invention

[0004] The present application provides an anomaly detection method and related devices, which can send abnormal information in advance to terminal devices that will be triggered by abnormal Bluetooth peripherals to output pairing notifications, thereby helping to avoid the abnormal Bluetooth peripherals triggering terminal devices in a large range to output pairing notifications.

[0005] In a first aspect, an embodiment of the present application provides an anomaly detection method, the method comprising:

[0006] Determine the number of triggered terminal devices, where the triggered terminal devices refer to the terminal devices that are triggered by the Bluetooth peripheral device to output a pairing notification, where the pairing notification is used to notify the triggered terminal device to establish Bluetooth pairing with the Bluetooth peripheral device;

[0007] If the number is greater than a preset value, the Bluetooth peripheral is determined to be an abnormal Bluetooth peripheral, and abnormal information is sent to the terminal device in the cell where the Bluetooth peripheral is located, where the abnormal information is used to indicate that the Bluetooth peripheral is an abnormal Bluetooth peripheral.

[0008] It can be seen that in the abnormality detection method described in this aspect, the server can determine the number of triggered terminal devices, and when the number of triggered terminal devices is greater than a preset value, determine that the Bluetooth peripheral is an abnormal Bluetooth peripheral, and send abnormal information to the terminal device. It can send abnormal information in advance to the terminal device that will be triggered by the abnormal Bluetooth peripheral to output pairing notification, which is beneficial for the terminal device to discard the proximity discovery message when receiving the abnormal information, thereby helping to avoid the abnormal Bluetooth peripheral triggering the terminal devices in a large range to output pairing notifications.

[0009] In addition, the anomaly detection method also reduces the number of terminal devices triggered by abnormal Bluetooth peripherals, and reduces the probability of terminal devices establishing Bluetooth connections with abnormal Bluetooth peripherals, thereby reducing the probability of data leakage through abnormal Bluetooth connections (such as reducing the probability of leakage of personal privacy data such as users' call records and text message records), which can effectively ensure data security.

[0010] In conjunction with the first aspect, in an optional implementation manner, determining the number of triggered terminal devices includes:

[0011] Receive Bluetooth pairing information, where the Bluetooth pairing information includes an identifier of a terminal device triggered by each Bluetooth peripheral device and an identifier of each corresponding Bluetooth peripheral device;

[0012] According to the Bluetooth pairing information, the number of terminal device identifiers corresponding to the identifier of the Bluetooth peripheral is obtained, and the number of corresponding terminal device identifiers is used as the number of triggered terminal devices.

[0013] It can be seen that in this implementation, the number of triggered terminal devices can be determined based on the Bluetooth pairing information.

[0014] In combination with the first aspect, in an optional implementation, the Bluetooth pairing information further includes a triggering time of the triggered terminal device, and obtaining the number of terminal device identifiers corresponding to the identifier of the Bluetooth peripheral device according to the Bluetooth pairing information includes:

[0015] According to the Bluetooth pairing information, the number of identifiers of terminal devices corresponding to the identifier of the Bluetooth peripheral device within a preset time period is obtained.

[0016] It can be seen that in this implementation, the number of terminal devices triggered within a preset time period can be counted, which is conducive to ensuring the real-time nature of the counted number, and thus is conducive to ensuring the real-time nature of abnormal Bluetooth peripherals detected based on the counted number.

[0017] In combination with the first aspect, in an optional implementation manner, the Bluetooth pairing information further includes a first cell identifier, where the first cell identifier is used to identify the cell where the Bluetooth peripheral is located, and sending abnormal information to a terminal device in the cell where the Bluetooth peripheral is located includes:

[0018] Based on the first cell identifier, abnormal information is sent to a terminal device in the cell where the Bluetooth peripheral device is located.

[0019] It can be seen that in this implementation, the Bluetooth pairing information may also include the first cell identifier.

[0020] In combination with the first aspect, in an optional implementation manner, the Bluetooth pairing information further includes a second cell identifier, where the second cell identifier is used to identify an adjacent cell of the cell where the Bluetooth peripheral is located, and the method further includes:

[0021] Based on the second cell identifier, abnormal information is sent to terminal devices in a cell adjacent to the cell where the Bluetooth peripheral device is located.

[0022] It can be seen that in this implementation, the Bluetooth pairing information may also include the second cell identifier.

[0023] In a second aspect, an embodiment of the present application provides another anomaly detection method, the method comprising:

[0024] Receive abnormal information; the abnormal information is used to indicate abnormal Bluetooth peripherals;

[0025] According to the abnormal information, determine whether the Bluetooth peripheral corresponding to the proximity discovery message is an abnormal Bluetooth peripheral;

[0026] If so, the proximity discovery message is discarded.

[0027] It can be seen that in the anomaly detection method described in this aspect, the terminal device can determine whether to discard the proximity discovery message based on the anomaly information, which can effectively avoid the interference of abnormal Bluetooth peripherals.

[0028] In conjunction with the second aspect, in an optional implementation, the abnormal information includes an identifier of the abnormal Bluetooth peripheral, and judging whether the Bluetooth peripheral corresponding to the proximity discovery message is the abnormal Bluetooth peripheral according to the abnormal information includes:

[0029] According to the identifier of the abnormal Bluetooth peripheral and the identifier of the Bluetooth peripheral corresponding to the proximity discovery message, it is determined whether the Bluetooth peripheral corresponding to the proximity discovery message is an abnormal Bluetooth peripheral.

[0030] In conjunction with the second aspect, in an optional implementation, the method is applied to a terminal device in a cell where the abnormal Bluetooth peripheral is located; or, a terminal device in a cell adjacent to the cell where the abnormal Bluetooth peripheral is located.

[0031] In a third aspect, an embodiment of the present application provides another anomaly detection method, the method comprising:

[0032] In response to the proximity discovery message, a pairing notification is triggered to output, where the pairing notification is used to notify the triggered terminal device to allow the Bluetooth peripheral device to establish a Bluetooth pairing; the triggered terminal device refers to the terminal device that is triggered by the Bluetooth peripheral device to output the pairing notification;

[0033] Upload Bluetooth pairing information to the server, the Bluetooth pairing information includes the identifier of the triggered terminal device and the identifier of the Bluetooth peripheral device, and the Bluetooth pairing information is used to determine the number of terminal devices triggered by the Bluetooth peripheral device.

[0034] It can be seen that in the anomaly detection method described in this method, when the terminal device is triggered by the Bluetooth peripheral to output a pairing notification, the Bluetooth pairing information can be uploaded to the server, which is helpful for the server to determine the number of terminal devices triggered by the Bluetooth peripheral.

[0035] In combination with the third aspect, in an optional implementation, the Bluetooth pairing information also includes a triggering time of the triggered terminal device, and the Bluetooth pairing information is also used to determine the number of terminal devices triggered by the Bluetooth peripheral within a preset time period.

[0036] In combination with the third aspect, in an optional implementation, the Bluetooth pairing information further includes a first cell identifier and / or a second cell identifier, the first cell identifier is used to identify the cell where the Bluetooth peripheral is located, and the second cell identifier is used to identify an adjacent cell of the cell where the Bluetooth peripheral is located.

[0037] In a fourth aspect, an embodiment of the present application provides an anomaly detection system, the system comprising: a triggered terminal device, a server, and a terminal device in a cell where a Bluetooth peripheral is located;

[0038] The triggered terminal device is used to upload Bluetooth pairing information to the server; the triggered terminal device refers to the terminal device that is triggered by the Bluetooth peripheral to output the pairing notification; the pairing notification is used to notify the triggered terminal device to allow the Bluetooth peripheral to establish Bluetooth pairing; the Bluetooth pairing information includes the identifier of the triggered terminal device and the identifier of the Bluetooth peripheral;

[0039] The server is used to determine the number of triggered terminal devices based on the Bluetooth pairing information, and to determine that the Bluetooth peripheral is an abnormal Bluetooth peripheral if the determined number is greater than a preset value, and send abnormal information to the terminal device in the cell where the Bluetooth peripheral is located; the abnormal information is used to indicate that the Bluetooth peripheral is an abnormal Bluetooth peripheral;

[0040] The terminal device in the cell where the Bluetooth peripheral is located is used to receive the abnormal information, and to determine whether the Bluetooth peripheral corresponding to the proximity discovery message is an abnormal Bluetooth peripheral based on the abnormal information; if so, the proximity discovery message is discarded.

[0041] It can be seen that in the abnormality detection system described in this aspect, the triggered terminal device can upload Bluetooth pairing information to the server. The server can determine the number of triggered terminal devices based on the Bluetooth pairing information, and send abnormal information to the terminal devices in the cell where the Bluetooth peripheral is located when the number of triggered terminal devices is greater than a preset value. The abnormal information can be sent in advance to the terminal device that will be triggered by the abnormal Bluetooth peripheral to output pairing notification, which is beneficial for the terminal device to discard the proximity discovery message when receiving the abnormal information, thereby helping to avoid the abnormal Bluetooth peripheral triggering the terminal devices in a large range to output pairing notifications.

[0042] In a fifth aspect, an embodiment of the present application provides a server, including a memory, one or more processors, and one or more programs; wherein the one or more programs are stored in the memory, and characterized in that when the one or more processors execute the one or more programs, the server implements: determining the number of triggered terminal devices, where the triggered terminal device refers to a terminal device that is triggered by a Bluetooth peripheral to output a pairing notification, and the pairing notification is used to notify the triggered terminal device to allow the Bluetooth peripheral to establish a Bluetooth pairing;

[0043] If the number is greater than a preset value, the Bluetooth peripheral is determined to be an abnormal Bluetooth peripheral, and abnormal information is sent to the terminal device in the cell where the Bluetooth peripheral is located, where the abnormal information is used to indicate that the Bluetooth peripheral is an abnormal Bluetooth peripheral.

[0044] In conjunction with the fifth aspect, in an optional implementation manner, the server is configured to determine the number of triggered terminal devices, including:

[0045] Receive Bluetooth pairing information, where the Bluetooth pairing information includes an identifier of a terminal device triggered by each Bluetooth peripheral device and an identifier of each corresponding Bluetooth peripheral device;

[0046] According to the Bluetooth pairing information, the number of terminal device identifiers corresponding to the identifier of the Bluetooth peripheral is obtained, and the number of corresponding terminal device identifiers is used as the number of triggered terminal devices.

[0047] In conjunction with the fifth aspect, in an optional implementation, the Bluetooth pairing information further includes a triggering time of the triggered terminal device, and the server is configured to obtain, according to the Bluetooth pairing information, the number of terminal device identifiers corresponding to the identifier of the Bluetooth peripheral device, including:

[0048] According to the Bluetooth pairing information, the number of identifiers of terminal devices corresponding to the identifier of the Bluetooth peripheral device within a preset time period is obtained.

[0049] In conjunction with the fifth aspect, in an optional implementation manner, the Bluetooth pairing information further includes a first cell identifier, the first cell identifier is used to identify the cell where the Bluetooth peripheral is located, and the server is used to send abnormal information to the terminal device in the cell where the Bluetooth peripheral is located, including:

[0050] Based on the first cell identifier, abnormal information is sent to a terminal device in the cell where the Bluetooth peripheral device is located.

[0051] In conjunction with the fifth aspect, in an optional implementation manner, the Bluetooth pairing information further includes a second cell identifier, where the second cell identifier is used to identify an adjacent cell of the cell where the Bluetooth peripheral is located, and the server is further used to:

[0052] Based on the second cell identifier, abnormal information is sent to terminal devices in a cell adjacent to the cell where the Bluetooth peripheral device is located.

[0053] In addition, in this aspect, the beneficial effects of the above-mentioned various optional implementations can refer to the beneficial effects of the first aspect and related implementations, and will not be repeated here.

[0054] In the sixth aspect, an embodiment of the present application provides a terminal device, including a touch screen, a memory, one or more processors, and one or more programs; wherein the one or more programs are stored in the memory, and it is characterized in that when the one or more processors execute the one or more programs, the terminal device implements: receiving abnormal information; the abnormal information is used to indicate an abnormal Bluetooth peripheral; based on the abnormal information, determining whether the Bluetooth peripheral corresponding to the proximity discovery message is an abnormal Bluetooth peripheral; if so, discarding the proximity discovery message.

[0055] In conjunction with the sixth aspect, in an optional implementation, the abnormal information includes an identifier of the abnormal Bluetooth peripheral, and the terminal device is used to determine whether the Bluetooth peripheral corresponding to the proximity discovery message is an abnormal Bluetooth peripheral according to the abnormal information, including:

[0056] According to the identifier of the abnormal Bluetooth peripheral and the identifier of the Bluetooth peripheral corresponding to the proximity discovery message, it is determined whether the Bluetooth peripheral corresponding to the proximity discovery message is an abnormal Bluetooth peripheral.

[0057] In combination with the sixth aspect, in an optional implementation, the method is applied to a terminal device in a cell where the abnormal Bluetooth peripheral is located; or, a terminal device in a cell adjacent to the cell where the abnormal Bluetooth peripheral is located.

[0058] In another embodiment, the terminal device may be enabled to implement:

[0059] In response to the proximity discovery message, a pairing notification is triggered to output, where the pairing notification is used to notify the triggered terminal device to allow the Bluetooth peripheral device to establish a Bluetooth pairing; the triggered terminal device refers to the terminal device that is triggered by the Bluetooth peripheral device to output the pairing notification;

[0060] Upload Bluetooth pairing information to the server, the Bluetooth pairing information includes the identifier of the triggered terminal device and the identifier of the Bluetooth peripheral device, and the Bluetooth pairing information is used to determine the number of terminal devices triggered by the Bluetooth peripheral device.

[0061] In combination with the sixth aspect, in an optional implementation, the Bluetooth pairing information also includes a triggering time of the triggered terminal device, and the Bluetooth pairing information is also used to determine the number of terminal devices triggered by the Bluetooth peripheral within a preset time period.

[0062] In combination with the sixth aspect, in an optional implementation, the Bluetooth pairing information also includes a first cell identifier and / or a second cell identifier, the first cell identifier is used to identify the cell where the Bluetooth peripheral is located, and the second cell identifier is used to identify an adjacent cell of the cell where the Bluetooth peripheral is located.

[0063] In addition, in this aspect, the beneficial effects of the above-mentioned various optional implementations can be referred to the beneficial effects of the relevant implementations of the second and third aspects, and will not be repeated here.

[0064] In a seventh aspect, an embodiment of the present application provides a computer program product, which, when executed on a server, enables the server to execute the method of the first aspect or any one of the implementations of the first aspect.

[0065] In an eighth aspect, an embodiment of the present application provides a computer program product. When the computer program product runs on a terminal device, the terminal device executes the method of the second aspect or any one of the implementations of the second aspect; or executes the method of the third aspect or any one of the implementations of the third aspect.

[0066] In the ninth aspect, an embodiment of the present application provides a computer-readable storage medium, which stores a computer program. When the computer program is executed by a processor, it implements the method of the first aspect or any one of the embodiments of the first aspect; executes the method of the second aspect or any one of the embodiments of the second aspect; or executes the method of the third aspect or any one of the embodiments of the third aspect. BRIEF DESCRIPTION OF THE DRAWINGS

[0067] In order to more clearly illustrate the technical solutions in the embodiments of the present application, the drawings required for use in the embodiments of the present application will be described below.

[0068] Figure 1 It is a schematic diagram of the process of establishing a pairing connection;

[0069] Figure 2 It is an interface diagram of a terminal device;

[0070] Figure 3It is a structural diagram of an anomaly detection system provided by the implementation of this application;

[0071] Figure 4 It is a flowchart of an anomaly detection method provided in an embodiment of the present application;

[0072] Figure 5 It is a flowchart of another anomaly detection method provided in an embodiment of the present application;

[0073] Figure 6 A schematic diagram of the structure of a server provided in an embodiment of the present application;

[0074] Figure 7 A schematic diagram of the structure of an electronic device provided in an embodiment of the present application;

[0075] Figure 8 A schematic diagram of a software architecture provided for an embodiment of the present application. DETAILED DESCRIPTION

[0076] The technical solutions in the embodiments of the present application will be described below in conjunction with the drawings in the embodiments of the present application.

[0077] In the description of the embodiments of the present application, unless otherwise specified, " / " means or, for example, A / B can mean A or B; "and / or" in this article is only a description of the association relationship of associated objects, indicating that there can be three relationships, for example, A and / or B can mean: A exists alone, A and B exist at the same time, and B exists alone. In addition, in the description of the embodiments of the present application, "at least one" means one or more items.

[0078] It should be pointed out that the "equal to" involved in the embodiments of the present application can be used in conjunction with "greater than", and is applicable to the technical solution adopted when "greater than" is used, and can also be used in conjunction with "less than", and is applicable to the technical solution adopted when "less than" is used. It should be noted that when "equal to" is used in conjunction with "greater than", it cannot be used in conjunction with "less than"; when "equal to" is used in conjunction with "less than", it cannot be used in conjunction with "greater than".

[0079] In order to solve the problem of pairing and connecting Bluetooth peripherals with terminal devices, a method for pairing and connecting based on proximity discovery messages (which can be BLE broadcast messages) is proposed. Optionally, the physical distance between the terminal device and the Bluetooth peripheral can be achieved through RSSI ranging. The physical distance is inversely proportional to RSSI. The larger the RSSI, the smaller the physical distance between the terminal device and the Bluetooth peripheral; the smaller the RSSI, the larger the physical distance between the terminal device and the Bluetooth peripheral. For example, it can be specifically expressed as:

[0080]

[0081] Wherein, r is the physical distance between the terminal device and the Bluetooth peripheral device, A is the preset signal strength when the Bluetooth peripheral device is 1 meter away from the terminal device, and n is the preset environmental attenuation factor.

[0082] like Figure 1 As shown, a schematic diagram of a process for establishing a pairing connection is shown. The Bluetooth peripheral can send a proximity discovery message. When the terminal device scans (receives) the proximity discovery message, the terminal device performs a received signal strength indication (RSSI) ranging based on the proximity discovery message, and determines the physical distance between the terminal device and the Bluetooth peripheral based on the RSSI ranging result. The terminal device can determine whether the physical distance is within the first range. If so, it outputs a pairing notification so that the terminal device can pair with the Bluetooth peripheral and establish a Bluetooth connection.

[0083] For example, Figure 2 This is a schematic diagram of an interface of a terminal device. Figure 2 As shown, the Bluetooth peripheral 201 can send a proximity discovery message. When the terminal device 202 scans (or receives) the proximity discovery message sent by the Bluetooth peripheral 201, it can determine the physical distance between the Bluetooth peripheral 201 and the terminal device 202 based on the proximity discovery message. When the terminal device 202 determines that the physical distance between the Bluetooth peripheral 201 and the terminal device 202 is within the first range, the pairing notification 202-1 can be displayed on the interface. The pairing notification 202-1 is used to notify that the Bluetooth peripheral 201 is allowed to establish a Bluetooth pairing with the terminal device 202. For example, the pairing notification 202-1 displays the Bluetooth peripheral logo 202-2 ( Figure 2 Taking the icon of a Bluetooth peripheral as an example, the identifier 202-2 may also be the model of the Bluetooth peripheral), as well as an "Allow" control 202-3 and a "Reject" control 202-4. A user clicking the "Allow" control 202-3 may trigger the Bluetooth peripheral 201 to pair with the terminal device 202 and establish a Bluetooth connection. A user clicking the "Reject" control 202-4 may trigger the terminal device 202 to delete the pairing notification. It should be noted that the pairing notification shown in the embodiment of the present application is only for illustrative purposes, and the pairing notification may also be in other forms, for example, the pairing notification may also be a voice notification, without limitation.

[0084] With the continuous expansion of Bluetooth communication application scenarios, Bluetooth attack incidents are becoming more and more common. For example, after knowing the format of the proximity discovery message, a malicious attacker can send a forged proximity discovery message at the maximum transmission power, causing terminal devices within a large range to output pairing notifications. These pairing notifications will cause harassment to users and affect the user experience. It should be noted that a forged proximity discovery message may refer to a proximity discovery message whose actual transmission power is greater than the reported transmission power. Optionally, the proximity discovery message may carry a "tx power" field, and the "tx power" field is used to report the transmission power of the proximity discovery message. Therefore, how to prevent terminal devices within a large range from outputting pairing notifications is an urgent problem to be solved.

[0085] The embodiment of the present application proposes an abnormality detection method and related equipment. In this method, the server can determine the number of triggered terminal devices. If the number is greater than a preset value, the Bluetooth peripheral is determined to be an abnormal Bluetooth peripheral, and abnormal information is sent to the terminal device in the cell where the Bluetooth peripheral is located; wherein the triggered terminal device refers to the terminal device that is triggered by the Bluetooth peripheral to output a pairing notification, the pairing notification is used to notify the triggered terminal device to allow the Bluetooth peripheral to establish a Bluetooth pairing with the Bluetooth peripheral, and the abnormal information is used to indicate that the Bluetooth peripheral is an abnormal Bluetooth peripheral.

[0086] See also Figure 3 , shows a schematic diagram of the structure of an anomaly detection system. Figure 3 As shown, the abnormality detection system may include a server 301, a Bluetooth peripheral 302, and a plurality of terminal devices 303 (such as Figure 3 As shown, it may include terminal device 3031, terminal device 3032, terminal device 3033, and terminal device 3034, etc.). Among them, the Bluetooth peripheral 302 is used to send a proximity discovery message; wherein the terminal device 3031 and the terminal device 3032 are used to be triggered by the Bluetooth peripheral 302 to output the pairing notification 300; the server 301 is used to determine the number of terminal devices triggered by the Bluetooth peripheral 302 (for example, the number of terminal devices triggered by the Bluetooth peripheral 302 is determined based on the Bluetooth pairing information from the terminal device 3031 and the terminal device 3032), and is used to determine that the Bluetooth peripheral 302 is an abnormal Bluetooth peripheral when the number is greater than a preset value, and send abnormal information to the terminal device in the cell where the Bluetooth peripheral 302 is located, and the abnormal information is used to indicate that the Bluetooth peripheral 302 is an abnormal Bluetooth peripheral. For example, it is assumed that the terminal devices in the cell where the Bluetooth peripheral 302 is located include terminal devices 3033 and terminal devices 3034, and the server 301 can send the abnormal information to the terminal device 3034.

[0087] It can be seen that when the server determines that the Bluetooth peripheral is an abnormal Bluetooth peripheral, it can send abnormal information in advance to the terminal device that will be triggered by the abnormal Bluetooth peripheral to output pairing notification, which is beneficial for the terminal device to discard the proximity discovery message when receiving the abnormal information, thereby helping to avoid the abnormal Bluetooth peripheral triggering terminal devices within a large range to output pairing notifications, that is, avoiding terminal devices within a large range from being harassed by the Bluetooth peripheral.

[0088] Optionally, the server 301 described in the embodiment of the present application can be a server or a combination of multiple servers. The server 301 can be an independent physical server, a server cluster or a distributed system composed of multiple physical servers, or a cloud server that provides basic cloud computing services such as cloud services, cloud databases, cloud computing, cloud functions, cloud storage, network services, cloud communications, content delivery networks (CDN), middleware services, domain name services, security services, and big data and artificial intelligence platforms, etc.

[0089] Optionally, the Bluetooth peripherals 302 described in the embodiment of the present application are not limited to Bluetooth headsets, mobile phones, Bluetooth mice, tablet computers, laptop computers, desktop computers, display screens, Bluetooth keyboards, Bluetooth printers, Bluetooth fax machines, Internet of Vehicles devices, etc.

[0090] Optionally, the terminal device 303 described in the embodiment of the present application may include but is not limited to portable electronic devices such as mobile phones, tablet computers, personal digital assistants (PDAs), wearable devices, etc. Exemplary embodiments of portable electronic devices include but are not limited to portable electronic devices equipped with iOS, Android, Microsoft or other operating systems. The above-mentioned portable electronic devices may also be other portable electronic devices, such as laptop computers with touch-sensitive surfaces (e.g., touch panels). It should also be understood that in some other embodiments of the present application, the terminal device may not be a portable electronic device, but a desktop computer with a touch-sensitive surface (e.g., a touch panel).

[0091] The method of the embodiment of the present application is described in detail below with reference to the accompanying drawings.

[0092] See also Figure 4 , Figure 4 FIG. 1 shows a flow chart of an anomaly detection method. Figure 4 The steps may include but are not limited to:

[0093] S401: The server determines the number of triggered terminal devices.

[0094] The triggered terminal device refers to the terminal device that is triggered by the Bluetooth peripheral to output the pairing notification. Figure 2 As shown, the triggered terminal device may refer to the terminal device 202 that is triggered by the Bluetooth peripheral 201 to output the pairing notification, which will not be described in detail. Figure 3 As shown, the triggered terminal devices may refer to the terminal devices 3031 and 3032 that are triggered by the Bluetooth peripheral device 302 to output the pairing notification, which will not be described in detail.

[0095] The pairing notification is used to notify the triggered terminal device to establish Bluetooth pairing with the Bluetooth peripheral. Figure 2 As shown, the pairing notification 202-1 is used to notify the triggered terminal device 202 to allow the Bluetooth peripheral device 201 to establish Bluetooth pairing, that is, the user clicks the "Allow" control 202-3 to trigger the terminal device 202 to pair with the Bluetooth peripheral device 201 and establish a Bluetooth connection.

[0096] In an optional implementation, step S401 includes: the server receives Bluetooth pairing information, which includes the identifier of the terminal device triggered by each Bluetooth peripheral and the corresponding identifier of each Bluetooth peripheral; the server can obtain the number of terminal device identifiers corresponding to the identifier of the Bluetooth peripheral based on the Bluetooth pairing information, and use the number of corresponding terminal device identifiers as the number of triggered terminal devices.

[0097] In another optional implementation, step S401 includes: the server obtains the number of triggered terminal devices based on the identifier of the Bluetooth peripheral. For example, the identifiers of multiple Bluetooth peripherals are "00-01-6C-06-A6-29", "01-03-6D-06-A6-29" and "01-03-6D-06-06-27". The number of triggered terminal devices corresponding to the identifiers of each Bluetooth peripheral is described in conjunction with Table 1. As shown in Table 1, when the identifier of the Bluetooth peripheral is "00-01-6C-06-A6-29", the number of terminal devices triggered by the identifier of the Bluetooth peripheral is "2"; when the identifier of the Bluetooth peripheral is "01-03-6D-06-A6-29", the number of terminal devices triggered by the identifier of the Bluetooth peripheral is "3"; when the identifier of the Bluetooth peripheral is "01-03-6D-06-06-27", the number of terminal devices triggered by the identifier of the Bluetooth peripheral is "1".

[0098] Table 1

[0099] Bluetooth peripheral identification The number of triggered terminal devices 00-01-6C-06-A6-29 2 01-03-6D-06-A6-29 3 01-03-6D-06-06-27 1

[0100] It should be noted that the identifiers of the above-mentioned Bluetooth peripherals and the corresponding numbers of triggered terminal devices can be determined by the server itself or obtained by the server from other devices, without limitation.

[0101] It should be noted that the above implementation is described using the Bluetooth peripheral identifier as the Bluetooth peripheral media access control (MAC) address as an example. In other implementations, the Bluetooth peripheral identifier may also be other types, such as the Bluetooth peripheral manufacturer code, without limitation.

[0102] S402: If the number is greater than a preset value, the server determines that the Bluetooth peripheral is an abnormal Bluetooth peripheral.

[0103] In an optional implementation, step S402 includes: if the number is greater than a preset value, the server determines that the Bluetooth peripheral is an abnormal Bluetooth peripheral, and if the number is less than or equal to the preset value, the server determines that the Bluetooth peripheral is a normal Bluetooth peripheral. It should be noted that the preset value can be a default value or a user-defined value, for example, the preset value is 3, which is not limited.

[0104] S403: The server sends abnormal information to the terminal device in the cell where the Bluetooth peripheral device is located. Correspondingly, the terminal device in the cell where the Bluetooth peripheral device is located receives the abnormal information from the server.

[0105] The abnormal information is used to indicate that the Bluetooth peripheral is an abnormal Bluetooth peripheral.

[0106] Optionally, the abnormal information may include an identifier of the abnormal Bluetooth peripheral device.

[0107] Furthermore, the method may also include the following steps: Figure 4 Indicated by dotted line):

[0108] S404: The terminal device determines whether the Bluetooth peripheral corresponding to the proximity discovery message is an abnormal Bluetooth peripheral based on the abnormal information. If it is an abnormal Bluetooth peripheral, the proximity discovery message is discarded.

[0109] The Bluetooth peripheral device corresponding to the proximity discovery message refers to the Bluetooth peripheral device that sends the proximity discovery message.

[0110] In an optional implementation, step S404 specifically includes: judging whether the Bluetooth peripheral corresponding to the proximity discovery message is an abnormal Bluetooth peripheral according to the identifier of the abnormal Bluetooth peripheral and the identifier of the Bluetooth peripheral corresponding to the proximity discovery message. That is, the terminal device can compare the identifier of the abnormal Bluetooth peripheral with the identifier of the Bluetooth peripheral carried by the proximity discovery message. When the identifier of the Bluetooth peripheral carried by the proximity discovery message matches the identifier of the abnormal Bluetooth peripheral carried by the abnormal information, it is determined that the Bluetooth peripheral corresponding to the proximity discovery message is an abnormal Bluetooth peripheral, and the proximity discovery message can be discarded; when the identifier of the Bluetooth peripheral carried by the proximity discovery message fails to match the identifier of the abnormal Bluetooth peripheral carried by the abnormal information, it is determined that the Bluetooth peripheral corresponding to the proximity discovery message is a normal Bluetooth peripheral, and the proximity discovery message can be processed normally.

[0111] Optionally, step S404 may be executed by a Bluetooth chip in the terminal device.

[0112] It should be noted that the terminal device in step S404 refers to the terminal device of the cell where the Bluetooth peripheral device is located. In other implementations, the terminal device may also be a terminal device of a cell adjacent to the cell where the Bluetooth peripheral device is located.

[0113] It can be seen that according to an abnormality detection method provided in an embodiment of the present application, the server can determine the number of triggered terminal devices, and when the number of triggered terminal devices is greater than a preset value, determine that the Bluetooth peripheral is an abnormal Bluetooth peripheral, and send abnormal information to the terminal device. It can send abnormal information in advance to the terminal device that will be triggered by the Bluetooth peripheral to output pairing notifications, which is beneficial for the terminal device to discard the proximity discovery message when receiving the abnormal information, thereby helping to avoid the abnormal Bluetooth peripheral triggering terminal devices in a large range to output pairing notifications.

[0114] In addition, the anomaly detection method also reduces the number of terminal devices triggered by abnormal Bluetooth peripherals, and reduces the probability of terminal devices establishing Bluetooth connections with abnormal Bluetooth peripherals, thereby reducing the probability of data leakage through abnormal Bluetooth connections (such as reducing the probability of leakage of personal privacy data such as users' call records and text message records), which can effectively ensure data security.

[0115] See also Figure 5 , Figure 5 It is a flowchart of another anomaly detection method provided in an embodiment of the present application. Figure 5 The method described Figure 4 Compared with the method described above, Figure 5 The method described is described by taking the example of the server determining the number of triggered terminal devices based on the received Bluetooth pairing information. Figure 5 As shown, the method includes but is not limited to:

[0116] S501: The Bluetooth peripheral device sends a proximity discovery message, and correspondingly, the terminal device receives the proximity discovery message.

[0117] Optionally, step S501 specifically includes: the Bluetooth peripheral device sends a BLE broadcast message, and correspondingly, the terminal device receives the BLE broadcast message.

[0118] S502: When the terminal device determines, based on the proximity discovery message, that the physical distance between itself and the Bluetooth peripheral device is within a first range, output a pairing notification.

[0119] Optionally, step S502 specifically includes: the terminal device may perform RSSI ranging based on the proximity discovery message, and obtain the physical distance between the terminal device and the Bluetooth peripheral based on the RSSI ranging. When the physical distance between the terminal device and the Bluetooth peripheral is within the first range, the terminal device outputs a pairing notification, that is, the terminal device that outputs the pairing notification is a terminal device triggered by the Bluetooth peripheral; when the physical distance between the terminal device and the Bluetooth peripheral is outside the first range, the terminal device may discard the proximity discovery message. It should be noted that the first range can be any distance interval, for example, the first range is a distance interval of 0 cm to 20 cm, a distance interval of 20 cm to 50 cm, etc., without limitation.

[0120] S503: The terminal device uploads the Bluetooth pairing information to the server, and correspondingly, the server receives the Bluetooth pairing information.

[0121] The terminal device refers to the triggered terminal device. The Bluetooth pairing information includes the identifier of the terminal device triggered by the Bluetooth peripheral device and the identifier of the Bluetooth peripheral device. Figure 3 As shown, taking the triggered terminal device 3031 as an example, the triggered terminal device 3031 can upload Bluetooth pairing information to the server 301, and the Bluetooth pairing information includes the identifier of the terminal device 3031 and the identifier of the Bluetooth peripheral 302; for another example, taking the triggered terminal device 3032 as an example, the triggered terminal device 3032 can upload Bluetooth pairing information to the server 301, and the Bluetooth pairing information includes the identifier of the terminal device 3032 and the identifier of the Bluetooth peripheral 302.

[0122] Optionally, step S503 may include: the terminal device encrypts the Bluetooth pairing information based on an encryption algorithm to obtain encrypted information, and uploads the encrypted information to the server. Correspondingly, the server may receive the encrypted information and decrypt the encrypted information based on a decryption algorithm corresponding to the encryption algorithm to obtain the Bluetooth pairing information. It should be noted that the embodiments of the present application do not limit the encryption algorithm and the decryption algorithm. For example, the encryption algorithm may be a public key encryption algorithm, and the decryption algorithm may be a private key decryption algorithm.

[0123] S504: The server determines the number of triggered terminal devices according to the Bluetooth pairing information.

[0124] In an optional implementation, step S504 specifically includes: the server obtains the number of terminal device identifiers corresponding to the identifier of the Bluetooth peripheral according to the Bluetooth pairing information, and uses the number of corresponding terminal device identifiers as the number of triggered terminal devices.

[0125] For example, the server receives 6 Bluetooth pairing information, among which the first Bluetooth pairing information includes: the terminal device identifier is "00-00-60-00-06-20", and the Bluetooth peripheral identifier is "00-01-6C-06-A6-29" (that is, the terminal device identifier triggered by the Bluetooth peripheral is "00-00-60-00-06-20", and the Bluetooth peripheral identifier is "00-01-6C-06-A6-29"). The second Bluetooth pairing information includes: the terminal device identifier is "00-02-60-05-06-20", and the Bluetooth peripheral identifier is "00-01-6C-06-A6-29"; the third Bluetooth pairing information includes: the terminal device identifier is "01-03-6D-05-06-20", and the Bluetooth peripheral identifier is "01-03-6D-06-A6-29"; the fourth Bluetooth pairing information includes: the terminal device identifier is "0 1-03-6D-A5-D6-25, the Bluetooth peripheral identifier is "01-03-6D-06-A6-29"; the fifth Bluetooth pairing information includes: the terminal device identifier is "01-01-6D-A5-06-25", the Bluetooth peripheral identifier is "01-03-6D-06-A6-29"; the sixth Bluetooth pairing information includes: the terminal device identifier is "01-06-6D-05-06-27", the Bluetooth peripheral identifier is "01-03-6D-06-A6-29" The server can determine the terminal device identifiers corresponding to the identifiers of the Bluetooth peripherals based on the above 6 Bluetooth pairing information. That is, when the Bluetooth peripheral identifier is "00-01-6C-06-A6-29", the corresponding terminal device identifiers are "00-00-60-00-06-20" and "00-02-60-05-06-20"; when the Bluetooth peripheral identifier is "0 When the Bluetooth peripheral device's identifier is "01-03-6D-06-06-27", the corresponding terminal device's identifier is "01-06-6D-05-06-27", as shown in Table 2.

[0126] Table 2

[0127]

[0128] Then, if the identification of the Bluetooth peripheral is "00-01-6C-06-A6-29", the number of corresponding terminal device identifications "2" can be used as the number of triggered terminal devices. If the identification of the Bluetooth peripheral is "01-03-6D-06-A6-29", the number of corresponding terminal device identifications "3" can be used as the number of triggered terminal devices. If the identification of the Bluetooth peripheral is "01-03-6D-06-06-27", the number of corresponding terminal device identifications "1" can be used as the number of triggered terminal devices.

[0129] It should be noted that the above implementation is described by taking the identification of the Bluetooth peripheral as the MAC address of the Bluetooth peripheral and the identification of the terminal device as the MAC address of the terminal device as an example. In other implementations, the identification of the Bluetooth peripheral can also be other types, such as the manufacturer code of the Bluetooth peripheral, without limitation. Similarly, the identification of the terminal device can also be other types, such as the manufacturer code of the terminal device.

[0130] Furthermore, the Bluetooth pairing information may also include the triggering time of the triggered terminal device. Based on this, step S504 may also include: determining the number of terminal devices triggered within a preset time period. That is to say, the server can obtain the triggering time of the triggered terminal device, and obtain the identifier of the terminal device corresponding to the identifier of the Bluetooth peripheral within the preset time period, and use the identifier of the terminal device corresponding to the identifier of the Bluetooth peripheral within the preset time period as the number of terminal devices triggered within the preset time period. It should be noted that the preset time period can be a time period set according to business experience or needs. For example, the preset time period is the closest to 1 minute from the current moment, or the time period from 00:00 on the same day to the current moment, etc. It can be seen that in this embodiment, the number of terminal devices triggered within the preset time period can be counted, which is conducive to ensuring the real-time nature of the counted number, thereby facilitating the real-time nature of abnormal Bluetooth peripherals detected based on the counted number.

[0131] Optionally, step S504 may be performed periodically. Optionally, step S504 may also be performed when a trigger operation is detected. For example, when the server receives Bluetooth pairing information and determines that a trigger operation is detected, step S504 may be performed. Not limited.

[0132] S505: If the number is greater than the preset value, the server determines that the Bluetooth peripheral is an abnormal Bluetooth peripheral.

[0133] S506: The server sends abnormal information to the terminal device in the cell where the Bluetooth peripheral device is located. Correspondingly, the terminal device in the cell where the Bluetooth peripheral device is located receives the abnormal information from the server.

[0134] Furthermore, the Bluetooth pairing information may also include a first cell identifier. The first cell identifier is used to identify the cell where the Bluetooth peripheral is located. Based on this, step S506 includes: based on the first cell identifier, sending abnormal information to the terminal device in the cell where the Bluetooth peripheral is located. It should be noted that the cell where the Bluetooth peripheral is located can also be understood as the cell where the triggered terminal device is located, that is, the cell where the triggered terminal device is located is used as the cell where the Bluetooth peripheral is located.

[0135] Furthermore, the Bluetooth pairing information may also include a second cell identifier. The second cell identifier is used to identify an adjacent cell of the cell where the Bluetooth peripheral is located. Based on this, after step S506, the method further includes: based on the second cell identifier, sending abnormal information to the terminal device of the adjacent cell of the cell where the Bluetooth peripheral is located. It should be noted that the number of adjacent cells of the cell where the Bluetooth peripheral is located can be one or more, so the number of second cell identifiers can also be one or more. One or more second cell identifiers can be obtained separately or simultaneously (for example, obtaining an identifier list, which includes one or more second cell identifiers). Similarly, the adjacent cell of the cell where the Bluetooth peripheral is located can also be understood as the adjacent cell of the cell where the triggered terminal device is located, that is, the adjacent cell of the cell where the triggered terminal device is located is used as the adjacent cell of the cell where the Bluetooth peripheral is located.

[0136] Furthermore, the method may also include the following steps: Figure 5 Indicated by dotted line):

[0137] S507: The terminal device determines whether the Bluetooth peripheral corresponding to the proximity discovery message is an abnormal Bluetooth peripheral based on the abnormal information. If it is an abnormal Bluetooth peripheral, the proximity discovery message is discarded.

[0138] The terminal device in step S507 may be a terminal device in the cell where the Bluetooth peripheral device is located or a terminal device in a cell adjacent to the cell where the Bluetooth peripheral device is located.

[0139] It should be noted that the terminal device described in step S507 and the terminal device described in steps S501 to S503 may be the same terminal device or different terminal devices, without limitation.

[0140] It should be noted that for the relevant description of steps S505 to S507, please refer to Figure 4 The relevant steps will not be repeated here.

[0141] It can be seen that according to another abnormality detection method provided in an embodiment of the present application, the triggered terminal device can upload Bluetooth pairing information to the server. The server can determine the number of triggered terminal devices based on the Bluetooth pairing information, and send abnormal information to the terminal device when the number of triggered terminal devices is greater than a preset value. The abnormal information can be sent in advance to the terminal device that will be triggered by the abnormal Bluetooth peripheral to output pairing notification, which is beneficial for the terminal device to discard the proximity discovery message when receiving the abnormal information, thereby helping to avoid the abnormal Bluetooth peripheral triggering the terminal devices in a large range to output pairing notifications.

[0142] The present application embodiment also provides a server 600, such as Figure 6 , which shows a schematic diagram of the structure of a server 600. The server 600 may be used to implement the method described in the above method embodiment, and the details may refer to the description in the above method embodiment.

[0143] The server may include one or more processors 601. The processor may be used to implement some or all of the functions of the above-mentioned server through a logic circuit or running a computer program. The processor 601 may be a general-purpose processor or a dedicated processor, etc. For example, it may be a baseband processor, a digital signal processor, an application-specific integrated circuit, a field programmable gate array or other programmable logic device, a discrete gate or transistor logic device, a discrete hardware component or a central processing unit (CPU). The baseband processor may be used to process communication protocols and communication data, and the central processing unit may be used to control communication devices (such as base stations, baseband chips, terminals, terminal chips, DUs or CUs, etc.), execute software programs, and process data of software programs.

[0144] Optionally, the server 600 may include one or more memories 602, on which instructions 604 may be stored, and the instructions may be executed on the processor 601, so that the server 600 performs the method described in the above method embodiment. Optionally, data may also be stored in the memory 602. The processor 601 and the memory 602 may be provided separately or integrated together.

[0145] The memory 602 may include, but is not limited to, non-volatile memory such as a hard disk drive (HDD) or a solid-state drive (SSD), random access memory (RAM), erasable programmable ROM (EPROM), ROM or portable read-only memory (CD-ROM), etc.

[0146] Optionally, the server 600 may further include a transceiver 605 and an antenna 606. The transceiver 605 may be referred to as a transceiver unit, a transceiver, or a transceiver circuit, etc., for implementing a transceiver function. The transceiver 605 may include a receiver and a transmitter, the receiver may be referred to as a receiver or a receiving circuit, etc., for implementing a receiving function; the transmitter may be referred to as a transmitter or a transmitting circuit, etc., for implementing a transmitting function.

[0147] In one possible design, the processor 601 is used to determine the number of triggered terminal devices, where the triggered terminal devices refer to terminal devices that are triggered by the Bluetooth peripheral to output pairing notifications, where the pairing notifications are used to notify the triggered terminal devices to allow Bluetooth pairing to be established with the Bluetooth peripheral;

[0148] The processor 601 is further configured to determine that the Bluetooth peripheral is an abnormal Bluetooth peripheral if the number is greater than a preset value;

[0149] The transceiver 605 is used to send abnormal information to the terminal device in the cell where the Bluetooth peripheral is located, and the abnormal information is used to indicate that the Bluetooth peripheral is an abnormal Bluetooth peripheral.

[0150] In an optional implementation manner, the processor 601 is configured to determine the number of triggered terminal devices, including:

[0151] The transceiver 605 is used to receive Bluetooth pairing information, where the Bluetooth pairing information includes an identifier of a terminal device triggered by each Bluetooth peripheral device and an identifier of each corresponding Bluetooth peripheral device;

[0152] The processor 601 is used to obtain the number of terminal device identifiers corresponding to the identifier of the Bluetooth peripheral device according to the Bluetooth pairing information, and use the number of corresponding terminal device identifiers as the number of triggered terminal devices.

[0153] In an optional implementation, the Bluetooth pairing information further includes a triggering time of the triggered terminal device, and the processor 601 is configured to obtain, according to the Bluetooth pairing information, the number of terminal device identifiers corresponding to the identifier of the Bluetooth peripheral device, including:

[0154] According to the Bluetooth pairing information, the number of identifiers of terminal devices corresponding to the identifier of the Bluetooth peripheral device within a preset time period is obtained.

[0155] In an optional implementation, the Bluetooth pairing information further includes a first cell identifier, which is used to identify the cell where the Bluetooth peripheral is located, and the transceiver 605 is used to send abnormal information to the terminal device in the cell where the Bluetooth peripheral is located, including:

[0156] Based on the first cell identifier, abnormal information is sent to a terminal device in the cell where the Bluetooth peripheral device is located.

[0157] In an optional implementation, the Bluetooth pairing information further includes a second cell identifier, where the second cell identifier is used to identify a neighboring cell of the cell where the Bluetooth peripheral is located, and the transceiver 605 is further used to:

[0158] Based on the second cell identifier, abnormal information is sent to terminal devices in a cell adjacent to the cell where the Bluetooth peripheral device is located.

[0159] In another possible design, the processor 601 may include a transceiver for implementing the receiving and sending functions. For example, the transceiver may be a transceiver circuit, or an interface, or an interface circuit. The transceiver circuit, interface, or interface circuit for implementing the receiving and sending functions may be separate or integrated. The above-mentioned transceiver circuit, interface, or interface circuit may be used for reading and writing code / data, or the above-mentioned transceiver circuit, interface, or interface circuit may be used for transmitting or delivering signals.

[0160] In another possible design, optionally, the processor 601 may store an instruction 603, and the instruction 603 runs on the processor 601, which can enable the server 600 to execute the method described in the above method embodiment. The instruction 603 may be solidified in the processor 601, in which case the processor 601 may be implemented by hardware.

[0161] Figure 7 The schematic diagram of the structure of the electronic device 100 is shown. The electronic device 100 may be the terminal device in the above embodiment, without limitation.

[0162] The following is a detailed description of the embodiment using the electronic device 100 as an example. It should be understood that: Figure 7 The electronic device 100 shown is only an example, and the electronic device 100 may have more Figure 7 More or fewer components may be shown, two or more components may be combined, or there may be a different configuration of components. Figure 7 The various components shown in the EMBODIMENTS 2000 may be implemented in hardware, software, or a combination of hardware and software, including one or more signal processing and / or application specific integrated circuits.

[0163] See also Figure 7 , Figure 7 A schematic structural diagram of an electronic device 100 provided in an embodiment of the present application is shown.

[0164] The electronic device 100 may include a processor 110, an external memory interface 120, an internal memory 121, a universal serial bus (USB) interface 130, a charging management module 140, a power management module 141, a battery 142, an antenna 1, an antenna 2, a mobile communication module 150, a wireless communication module 160, an audio module 170, a speaker 170A, a receiver 170B, a microphone 170C, an earphone interface 170D, a sensor module 180, a button 190, a motor 191, an indicator 192, a camera 193, a display screen 194, and a subscriber identification module (SIM) card interface 195, etc. The sensor module 180 may include a pressure sensor 180A, a gyroscope sensor 180B, an air pressure sensor 180C, a magnetic sensor 180D, an acceleration sensor 180E, a distance sensor 180F, a proximity light sensor 180G, a fingerprint sensor 180H, a temperature sensor 180J, a touch sensor 180K, an ambient light sensor 180L, a bone conduction sensor 180M, etc.

[0165] It is to be understood that the structure illustrated in the embodiment of the present application does not constitute a specific limitation on the electronic device 100. In other embodiments of the present application, the electronic device 100 may include more or fewer components than shown in the figure, or combine some components, or split some components, or arrange the components differently. The components shown in the figure may be implemented in hardware, software, or a combination of software and hardware.

[0166] The processor 110 may include one or more processing units, for example, the processor 110 may include an application processor (AP), a modem processor, a graphics processor (GPU), an image signal processor (ISP), a controller, a video codec, a digital signal processor (DSP), a baseband processor, and / or a neural-network processing unit (NPU), etc. Different processing units may be independent devices or integrated into one or more processors.

[0167] In some embodiments, the processor 110 may be configured to determine whether the Bluetooth peripheral device corresponding to the proximity discovery message is an abnormal Bluetooth peripheral device based on the abnormal information.

[0168] The controller can generate operation control signals according to the instruction operation code and timing signal to complete the control of instruction fetching and execution.

[0169] The processor 110 may also be provided with a memory for storing instructions and data. In some embodiments, the memory in the processor 110 is a cache memory. The memory may store instructions or data that the processor 110 has just used or cyclically used. If the processor 110 needs to use the instruction or data again, it may be directly called from the memory. This avoids repeated access, reduces the waiting time of the processor 110, and thus improves the efficiency of the system.

[0170] In some embodiments, the processor 110 may include one or more interfaces. The interface may include an inter-integrated circuit (I2C) interface, an inter-integrated circuits sound (I2S) interface, a pulse code modulation (PCM) interface, a universal asynchronous receiver / transmitter (UART) interface, a mobile industry processor interface (MIPI), a general-purpose input / output (GPIO) interface, a subscriber identity module (SIM) interface, and / or a universal serial bus (USB) interface, etc.

[0171] The I2C interface is a bidirectional synchronous serial bus, including a serial data line (SDA) and a serial clock line (SCL). In some embodiments, the processor 110 may include multiple groups of I2C buses. The processor 110 may be coupled to the touch sensor 180K, the charger, the flash, the camera 193, etc. through different I2C bus interfaces. For example: the processor 110 may be coupled to the touch sensor 180K through the I2C interface, so that the processor 110 communicates with the touch sensor 180K through the I2C bus interface, thereby realizing the touch function of the electronic device 100.

[0172] The I2S interface can be used for audio communication. In some embodiments, the processor 110 can include multiple I2S buses. The processor 110 can be coupled to the audio module 170 via the I2S bus to achieve communication between the processor 110 and the audio module 170. In some embodiments, the audio module 170 can transmit an audio signal to the wireless communication module 160 via the I2S interface to achieve the function of answering a call through a Bluetooth headset.

[0173] The PCM interface can also be used for audio communication, sampling, quantizing and encoding analog signals. In some embodiments, the audio module 170 and the wireless communication module 160 can be coupled via a PCM bus interface. In some embodiments, the audio module 170 can also transmit audio signals to the wireless communication module 160 via the PCM interface to realize the function of answering calls via a Bluetooth headset. Both the I2S interface and the PCM interface can be used for audio communication.

[0174] The UART interface is a universal serial data bus for asynchronous communication. The bus can be a bidirectional communication bus. It converts the data to be transmitted between serial communication and parallel communication. In some embodiments, the UART interface is generally used to connect the processor 110 and the wireless communication module 160. For example, the processor 110 communicates with the Bluetooth module in the wireless communication module 160 through the UART interface to implement the Bluetooth function. In some embodiments, the audio module 170 can transmit an audio signal to the wireless communication module 160 through the UART interface to implement the function of playing music through a Bluetooth headset.

[0175] The MIPI interface can be used to connect the processor 110 with peripheral devices such as the display screen 194 and the camera 193. The MIPI interface includes a camera serial interface (CSI), a display serial interface (DSI), etc. In some embodiments, the processor 110 and the camera 193 communicate via the CSI interface to implement the shooting function of the electronic device 100. The processor 110 and the display screen 194 communicate via the DSI interface to implement the display function of the electronic device 100.

[0176] The GPIO interface can be configured by software. The GPIO interface can be configured as a control signal or as a data signal. In some embodiments, the GPIO interface can be used to connect the processor 110 with the camera 193, the display 194, the wireless communication module 160, the audio module 170, the sensor module 180, etc. The GPIO interface can also be configured as an I2C interface, an I2S interface, a UART interface, a MIPI interface, etc.

[0177] The USB interface 130 is an interface that complies with the USB standard specification, and specifically can be a Mini USB interface, a Micro USB interface, a USB Type C interface, etc. The USB interface 130 can be used to connect a charger to charge the electronic device 100, and can also be used to transfer data between the electronic device 100 and a peripheral device. It can also be used to connect headphones to play audio through the headphones. The interface can also be used to connect other electronic devices, such as AR devices, etc.

[0178] It is understandable that the interface connection relationship between the modules illustrated in the embodiment of the present application is only a schematic illustration and does not constitute a structural limitation on the electronic device 100. In other embodiments of the present application, the electronic device 100 may also adopt different interface connection methods in the above embodiments, or a combination of multiple interface connection methods.

[0179] The charging management module 140 is used to receive charging input from a charger. The charger may be a wireless charger or a wired charger. In some wired charging embodiments, the charging management module 140 may receive charging input from a wired charger through the USB interface 130. In some wireless charging embodiments, the charging management module 140 may receive wireless charging input through a wireless charging coil of the electronic device 100. While the charging management module 140 is charging the battery 142, it may also power the electronic device through the power management module 141.

[0180] The power management module 141 is used to connect the battery 142, the charging management module 140 and the processor 110. The power management module 141 receives input from the battery 142 and / or the charging management module 140, and supplies power to the processor 110, the internal memory 121, the display screen 194, the camera 193, and the wireless communication module 160. The power management module 141 can also be used to monitor parameters such as battery capacity, battery cycle number, battery health status (leakage, impedance), etc. In some other embodiments, the power management module 141 can also be set in the processor 110. In other embodiments, the power management module 141 and the charging management module 140 can also be set in the same device.

[0181] The wireless communication function of the electronic device 100 can be implemented through the antenna 1, the antenna 2, the mobile communication module 150, the wireless communication module 160, the modem processor and the baseband processor.

[0182] Antenna 1 and antenna 2 are used to transmit and receive electromagnetic wave signals. Each antenna in electronic device 100 can be used to cover a single or multiple communication frequency bands. Different antennas can also be reused to improve the utilization of antennas. For example, antenna 1 can be reused as a diversity antenna for a wireless local area network. In some other embodiments, the antenna can be used in combination with a tuning switch.

[0183] The mobile communication module 150 can provide solutions for wireless communications including 2G / 3G / 4G / 5G, etc., applied to the electronic device 100. The mobile communication module 150 may include at least one filter, a switch, a power amplifier, a low noise amplifier (LNA), etc. The mobile communication module 150 can receive electromagnetic waves from the antenna 1, and filter, amplify, and process the received electromagnetic waves, and transmit them to the modulation and demodulation processor for demodulation. The mobile communication module 150 can also amplify the signal modulated by the modulation and demodulation processor, and convert it into electromagnetic waves for radiation through the antenna 1. In some embodiments, at least some of the functional modules of the mobile communication module 150 can be set in the processor 110. In some embodiments, at least some of the functional modules of the mobile communication module 150 can be set in the same device as at least some of the modules of the processor 110.

[0184] The modem processor may include a modulator and a demodulator. Among them, the modulator is used to modulate the low-frequency baseband signal to be sent into a medium-high frequency signal. The demodulator is used to demodulate the received electromagnetic wave signal into a low-frequency baseband signal. The demodulator then transmits the demodulated low-frequency baseband signal to the baseband processor for processing. After the low-frequency baseband signal is processed by the baseband processor, it is passed to the application processor. The application processor outputs a sound signal through an audio device (not limited to a speaker 170A, a receiver 170B, etc.), or displays an image or video through a display screen 194. In some embodiments, the modem processor may be an independent device. In other embodiments, the modem processor may be independent of the processor 110 and be set in the same device as the mobile communication module 150 or other functional modules.

[0185] The wireless communication module 160 can provide wireless communication solutions including wireless local area networks (WLAN) (such as wireless fidelity (Wi-Fi) networks), bluetooth (BT), global navigation satellite system (GNSS), frequency modulation (FM), near field communication (NFC), infrared (IR), etc., which are applied to the electronic device 100. The wireless communication module 160 can be one or more devices integrating at least one communication processing module. The wireless communication module 160 receives electromagnetic waves via the antenna 2, modulates the frequency of the electromagnetic wave signal and performs filtering, and sends the processed signal to the processor 110. The wireless communication module 160 can also receive the signal to be sent from the processor 110, modulate the frequency of the signal, amplify it, and convert it into electromagnetic waves for radiation through the antenna 2. In some embodiments of the present application, the electronic device can obtain the current location information through the wireless communication module 160.

[0186] In some embodiments, the antenna 1 of the electronic device 100 is coupled to the mobile communication module 150, and the antenna 2 is coupled to the wireless communication module 160, so that the electronic device 100 can communicate with the network and other devices through wireless communication technology. The wireless communication technology may include global system for mobile communications (GSM), general packet radio service (GPRS), code division multiple access (CDMA), wideband code division multiple access (WCDMA), time-division code division multiple access (TD-SCDMA), long term evolution (LTE), BT, GNSS, WLAN, NFC, FM, and / or IR technology. The GNSS may include a global positioning system (GPS), a global navigation satellite system (GLONASS), a Beidou navigation satellite system (BDS), a quasi-zenith satellite system (QZSS) and / or a satellite based augmentation system (SBAS).

[0187] Optionally, the electronic device 100 can communicate with other devices through wireless communication technology. For example, when the electronic device is a terminal device in the cell where the Bluetooth peripheral device is located, the electronic device 100 can receive an abnormal message from the server and a proximity discovery message from the Bluetooth peripheral device through wireless communication technology; for another example, when the electronic device is a triggered terminal device, the electronic device 100 can upload Bluetooth pairing information to the server through wireless communication technology.

[0188] The electronic device 100 implements the display function through a GPU, a display screen 194, and an application processor. The GPU is a microprocessor for image processing, which connects the display screen 194 and the application processor. The GPU is used to perform mathematical and geometric calculations for graphics rendering. The processor 110 may include one or more GPUs that execute program instructions to generate or change display information.

[0189] The electronic device 100 can realize the shooting function through ISP, camera 193, video codec, GPU, display screen 194 and application processor.

[0190] The electronic device 100 implements the display function through a GPU, a display screen 194, and an application processor. The GPU is a microprocessor for image processing, which connects the display screen 194 and the application processor. The GPU is used to perform mathematical and geometric calculations for graphics rendering. The processor 110 may include one or more GPUs that execute program instructions to generate or change display information.

[0191] The display screen 194 is used to display images, videos, etc. The display screen 194 includes a display panel. The display panel can be a liquid crystal display (LCD), an organic light-emitting diode (OLED), an active-matrix organic light-emitting diode or an active-matrix organic light-emitting diode (AMOLED), a flexible light-emitting diode (FLED), Miniled, MicroLed, Micro-oLed, a quantum dot light-emitting diode (QLED), etc. In some embodiments, the electronic device 100 may include 1 or N display screens 194, where N is a positive integer greater than 1.

[0192] In some embodiments, the display screen 194 may be used to display a user interface involved in the embodiments of the present application, the user interface including a pairing notification, and the description of the user interface may refer to the above Figure 2 The content described.

[0193] The electronic device 100 can realize the shooting function through ISP, camera 193, video codec, GPU, display screen 194 and application processor.

[0194] ISP is used to process the data fed back by camera 193. For example, when taking a photo, the shutter is opened, and the light is transmitted to the camera photosensitive element through the lens. The light signal is converted into an electrical signal, and the camera photosensitive element transmits the electrical signal to ISP for processing and converts it into an image visible to the naked eye. ISP can also perform algorithm optimization on the noise, brightness, and skin color of the image. ISP can also optimize the exposure, color temperature and other parameters of the shooting scene. In some embodiments, ISP can be set in camera 193.

[0195] The camera 193 is used to capture still images or videos. The object generates an optical image through the lens and projects it onto the photosensitive element. The photosensitive element can be a charge coupled device (CCD) or a complementary metal-oxide-semiconductor (CMOS) phototransistor. The photosensitive element converts the optical signal into an electrical signal, and then passes the electrical signal to the ISP to be converted into a digital image signal. The ISP outputs the digital image signal to the DSP for processing. The DSP converts the digital image signal into an image signal in a standard RGB, YUV or other format. In some embodiments, the electronic device 100 may include 1 or N cameras 193, where N is a positive integer greater than 1.

[0196] The digital signal processor is used to process digital signals, and can process not only digital image signals but also other digital signals. For example, when the electronic device 100 is selecting a frequency point, the digital signal processor is used to perform Fourier transform on the frequency point energy.

[0197] Video codecs are used to compress or decompress digital videos. The electronic device 100 may support one or more video codecs. Thus, the electronic device 100 may play or record videos in a variety of coding formats, such as Moving Picture Experts Group (MPEG) 1, MPEG2, MPEG3, MPEG4, etc.

[0198] NPU is a neural network (NN) computing processor. By drawing on the structure of biological neural networks, such as the transmission mode between neurons in the human brain, it can quickly process input information and can also continuously self-learn. Through NPU, applications such as intelligent cognition of electronic device 100 can be realized, such as image recognition, face recognition, voice recognition, text understanding, etc.

[0199] The external memory interface 120 can be used to connect an external memory card, such as a Micro SD card, to expand the storage capacity of the electronic device 100. The external memory card communicates with the processor 110 through the external memory interface 120 to implement a data storage function, such as storing music, video and other files in the external memory card.

[0200] The internal memory 121 can be used to store computer executable program codes, which include instructions. The internal memory 121 may include a program storage area and a data storage area. Among them, the program storage area may store an operating system, an application required for at least one function (such as a sound playback function, an image playback function, etc.), etc. The data storage area may store data created during the use of the electronic device 100 (such as audio data, a phone book, etc.), etc. In addition, the internal memory 121 may include a high-speed random access memory, and may also include a non-volatile memory, such as at least one disk storage device, a flash memory device, a universal flash storage (UFS), etc. The processor 110 executes various functional applications and data processing of the electronic device 100 by running instructions stored in the internal memory 121, and / or instructions stored in a memory provided in the processor.

[0201] The electronic device 100 can implement audio functions such as music playing and recording through the audio module 170, the speaker 170A, the receiver 170B, the microphone 170C, the headphone jack 170D, and the application processor.

[0202] The audio module 170 is used to convert digital audio information into analog audio signal output, and is also used to convert analog audio input into digital audio signals. The audio module 170 can also be used to encode and decode audio signals. In some embodiments, the audio module 170 can be arranged in the processor 110, or some functional modules of the audio module 170 can be arranged in the processor 110.

[0203] The speaker 170A, also called a "speaker", is used to convert an audio electrical signal into a sound signal. The electronic device 100 can listen to music or listen to a hands-free call through the speaker 170A.

[0204] The receiver 170B, also called a "earpiece", is used to convert audio electrical signals into sound signals. When the electronic device 100 receives a call or voice message, the voice can be received by placing the receiver 170B close to the human ear.

[0205] Microphone 170C, also called "microphone" or "microphone", is used to convert sound signals into electrical signals. When making a call or sending a voice message, the user can speak by putting their mouth close to microphone 170C to input the sound signal into microphone 170C. The electronic device 100 can be provided with at least one microphone 170C. In other embodiments, the electronic device 100 can be provided with two microphones 170C, which can not only collect sound signals but also realize noise reduction function. In other embodiments, the electronic device 100 can also be provided with three, four or more microphones 170C to collect sound signals, reduce noise, identify the sound source, realize directional recording function, etc.

[0206] The earphone interface 170D is used to connect a wired earphone and can be a USB interface 130 or a 3.5 mm open mobile terminal platform (OMTP) standard interface or a cellular telecommunications industry association of the USA (CTIA) standard interface.

[0207] The pressure sensor 180A is used to sense the pressure signal and can convert the pressure signal into an electrical signal. In some embodiments, the pressure sensor 180A can be set on the display screen 194. There are many types of pressure sensors 180A, such as resistive pressure sensors, inductive pressure sensors, capacitive pressure sensors, etc. The capacitive pressure sensor can be a parallel plate including at least two conductive materials. When a force acts on the pressure sensor 180A, the capacitance between the electrodes changes. The electronic device 100 determines the intensity of the pressure according to the change in capacitance. When a touch operation acts on the display screen 194, the electronic device 100 detects the touch operation intensity according to the pressure sensor 180A. The electronic device 100 can also calculate the touch position according to the detection signal of the pressure sensor 180A. In some embodiments, touch operations acting on the same touch position but with different touch operation intensities can correspond to different operation instructions. For example: when a touch operation with a touch operation intensity less than the first pressure threshold acts on the short message application icon, an instruction to view the short message is executed. When a touch operation with a touch operation intensity greater than or equal to the first pressure threshold acts on the short message application icon, an instruction to create a new short message is executed. In some other embodiments of the present application, the pressure sensor 180A may also be disposed on the frame of the electronic device 100. The electronic device 100 may calculate the touch point where the user and the electronic device 100 are in contact through the pressure detected by the pressure sensor 180A.

[0208] The gyro sensor 180B can be used to determine the motion posture of the electronic device 100. In some embodiments, the angular velocity of the electronic device 100 around three axes (i.e., x, y, and z axes) can be determined by the gyro sensor 180B. The gyro sensor 180B can be used for anti-shake shooting. For example, when the shutter is pressed, the gyro sensor 180B detects the angle of the shaking of the electronic device 100, calculates the distance that the lens module needs to compensate based on the angle, and allows the lens to offset the shaking of the electronic device 100 through reverse movement to achieve anti-shake. The gyro sensor 180B can also be used for navigation and somatosensory game scenes. In some embodiments of the present application, the electronic device 100 can determine whether the electronic device is flipped back and forth by the user, whether it is in a vertical posture, etc. through the gyro sensor 180B.

[0209] The air pressure sensor 180C is used to measure air pressure. In some embodiments, the electronic device 100 calculates the altitude through the air pressure value measured by the air pressure sensor 180C to assist positioning and navigation.

[0210] The magnetic sensor 180D includes a Hall sensor. The electronic device 100 can use the magnetic sensor 180D to detect the opening and closing of the flip leather case. In some embodiments, when the electronic device 100 is a flip phone, the electronic device 100 can detect the opening and closing of the flip cover according to the magnetic sensor 180D. Then, according to the detected opening and closing state of the leather case or the opening and closing state of the flip cover, the flip cover can be automatically unlocked.

[0211] The acceleration sensor 180E can detect the magnitude of the acceleration of the electronic device 100 in all directions (generally three axes). When the electronic device 100 is stationary, the magnitude and direction of gravity can be detected. It can also be used to identify the posture of the electronic device, and is applied to applications such as horizontal and vertical screen switching and pedometers. In some embodiments of the present application, the electronic device 100 can determine whether the electronic device is flipped forward and backward by the user, whether it is in a vertical posture, etc. through the acceleration sensor 180E.

[0212] The distance sensor 180F is used to measure the distance. The electronic device 100 can measure the distance by infrared or laser. In some embodiments, when shooting a scene, the electronic device 100 can use the distance sensor 180F to measure the distance to achieve fast focusing.

[0213] The proximity light sensor 180G may include, for example, a light emitting diode (LED) and a light detector, such as a photodiode. The light emitting diode may be an infrared light emitting diode. The electronic device 100 emits infrared light outward through the light emitting diode. The electronic device 100 uses a photodiode to detect infrared reflected light from nearby objects. When sufficient reflected light is detected, it can be determined that there is an object near the electronic device 100. When insufficient reflected light is detected, the electronic device 100 can determine that there is no object near the electronic device 100. The electronic device 100 can use the proximity light sensor 180G to detect that the user holds the electronic device 100 close to the ear to talk, so as to automatically turn off the screen to save power. The proximity light sensor 180G can also be used in leather case mode and pocket mode to automatically unlock and lock the screen.

[0214] The ambient light sensor 180L is used to sense the ambient light brightness. The electronic device 100 can adaptively adjust the brightness of the display screen 194 according to the perceived ambient light brightness. The ambient light sensor 180L can also be used to automatically adjust the white balance when taking pictures. The ambient light sensor 180L can also cooperate with the proximity light sensor 180G to detect whether the electronic device 100 is in a pocket to prevent accidental touches.

[0215] The fingerprint sensor 180H is used to collect fingerprints. The electronic device 100 can use the collected fingerprint characteristics to implement fingerprint unlocking, access application locks, fingerprint photography, fingerprint call answering, etc.

[0216] The temperature sensor 180J is used to detect temperature. In some embodiments, the electronic device 100 uses the temperature detected by the temperature sensor 180J to execute a temperature processing strategy. For example, when the temperature reported by the temperature sensor 180J exceeds a threshold, the electronic device 100 reduces the performance of a processor located near the temperature sensor 180J to reduce power consumption and implement thermal protection. In other embodiments, when the temperature is lower than another threshold, the electronic device 100 heats the battery 142 to avoid abnormal shutdown of the electronic device 100 due to low temperature. In other embodiments, when the temperature is lower than another threshold, the electronic device 100 performs a boost on the output voltage of the battery 142 to avoid abnormal shutdown caused by low temperature.

[0217] The touch sensor 180K is also called a "touch panel". The touch sensor 180K can be set on the display screen 194, and the touch sensor 180K and the display screen 194 form a touch screen, also called a "touch screen". The touch sensor 180K is used to detect touch operations acting on or near it. The touch sensor can pass the detected touch operation to the application processor to determine the type of touch event. Visual output related to the touch operation can be provided through the display screen 194. In other embodiments, the touch sensor 180K can also be set on the surface of the electronic device 100, which is different from the position of the display screen 194.

[0218] The bone conduction sensor 180M can obtain a vibration signal. In some embodiments, the bone conduction sensor 180M can obtain a vibration signal of a vibrating bone block of the vocal part of the human body. The bone conduction sensor 180M can also contact the human pulse to receive a blood pressure beat signal. In some embodiments, the bone conduction sensor 180M can also be set in an earphone and combined into a bone conduction earphone. The audio module 170 can parse out a voice signal based on the vibration signal of the vibrating bone block of the vocal part obtained by the bone conduction sensor 180M to realize a voice function. The application processor can parse the heart rate information based on the blood pressure beat signal obtained by the bone conduction sensor 180M to realize a heart rate detection function.

[0219] The key 190 includes a power key, a volume key, etc. The key 190 may be a mechanical key or a touch key. The electronic device 100 may receive key input and generate key signal input related to user settings and function control of the electronic device 100.

[0220] Motor 191 can generate vibration prompts. Motor 191 can be used for incoming call vibration prompts, and can also be used for touch vibration feedback. For example, touch operations acting on different applications (such as taking pictures, audio playback, etc.) can correspond to different vibration feedback effects. For touch operations acting on different areas of the display screen 194, motor 191 can also correspond to different vibration feedback effects. Different application scenarios (for example: time reminders, receiving messages, alarm clocks, games, etc.) can also correspond to different vibration feedback effects. The touch vibration feedback effect can also support customization.

[0221] Indicator 192 may be an indicator light, which may be used to indicate charging status, power changes, messages, missed calls, notifications, etc.

[0222] The SIM card interface 195 is used to connect a SIM card. The SIM card can be connected to and separated from the electronic device 100 by inserting it into the SIM card interface 195 or pulling it out from the SIM card interface 195. The electronic device 100 can support 1 or N SIM card interfaces, where N is a positive integer greater than 1. The SIM card interface 195 can support Nano SIM cards, Micro SIM cards, SIM cards, and the like. Multiple cards can be inserted into the same SIM card interface 195 at the same time. The types of the multiple cards can be the same or different. The SIM card interface 195 can also be compatible with different types of SIM cards. The SIM card interface 195 can also be compatible with external memory cards. The electronic device 100 interacts with the network through the SIM card to implement functions such as calls and data communications. In some embodiments, the electronic device 100 uses an eSIM, i.e., an embedded SIM card. The eSIM card can be embedded in the electronic device 100 and cannot be separated from the electronic device 100.

[0223] The software system of the electronic device 100 may adopt a layered architecture, an event-driven architecture, a micro-core architecture, a micro-service architecture, or a cloud architecture. The embodiment of the present application takes the Android system of the layered architecture as an example to exemplify the software structure of the electronic device 100.

[0224] Figure 8 It is a software structure block diagram of the electronic device 100 according to an embodiment of the present application.

[0225] The layered architecture divides the software into several layers, each with clear roles and division of labor. The layers communicate with each other through software interfaces. In some embodiments, the Android system is divided into four layers, from top to bottom: the application layer, the application framework layer, the Android runtime and system library, and the kernel layer.

[0226] The application layer can include a series of application packages.

[0227] like Figure 8 As shown, the application package may include applications such as camera, gallery, calendar, call, map, navigation, WLAN, Bluetooth, music, short message, file browser, etc.

[0228] The application framework layer provides an application programming interface (API) and a programming framework for the applications in the application layer. The application framework layer includes some predefined functions.

[0229] like Figure 8 As shown, the application framework layer may include a window manager, a content provider, a view system, a phone manager, a resource manager, a notification manager, and the like.

[0230] The window manager is used to manage window programs. The window manager can obtain the size of the display screen, determine whether there is a status bar, lock the screen, capture the screen, etc. In the embodiment of the present application, the window manager can obtain the sizes of the two display screens provided by the electronic device 100 and uniformly manage the contents displayed on the two display screens.

[0231] Content providers are used to store and retrieve data and make it accessible to applications. The data may include videos, images, audio, calls made and received, browsing history and bookmarks, phone books, etc.

[0232] The view system includes visual controls, such as controls for displaying text, controls for displaying images, etc. The view system can be used to build applications. A display interface can be composed of one or more views. For example, a display interface including a text notification icon can include a view for displaying text and a view for displaying images.

[0233] The phone manager is used to provide communication functions of the electronic device 100, such as management of call status (including connecting, hanging up, etc.).

[0234] The resource manager provides various resources for applications, such as localized strings, icons, images, layout files, video files, and so on.

[0235] The notification manager allows applications to display notification information in the status bar. It can be used to convey notification-type messages and can disappear automatically after a short stay without user interaction. For example, the notification manager is used to notify download completion, message reminders, etc. The notification manager can also be a notification that appears in the system top status bar in the form of a chart or scroll bar text, such as notifications of applications running in the background, or a notification that appears on the screen in the form of a dialog window (such as a pairing notification). For example, a text message is displayed in the status bar, a prompt sound is emitted, an electronic device vibrates, an indicator light flashes, etc.

[0236] Android Runtime includes core libraries and virtual machines. Android runtime is responsible for scheduling and management of the Android system.

[0237] The core library consists of two parts: one part is the function that needs to be called by the Java language, and the other part is the Android core library.

[0238] The application layer and the application framework layer run in a virtual machine. The virtual machine executes the Java files of the application layer and the application framework layer as binary files. The virtual machine is used to perform functions such as object life cycle management, stack management, thread management, security and exception management, and garbage collection.

[0239] The system library may include multiple functional modules, such as surface manager, media library, 3D graphics processing library (such as OpenGL ES), 2D graphics engine (such as SGL), etc.

[0240] The surface manager is used to manage the display subsystem and provide the fusion of 2D and 3D layers for multiple applications.

[0241] The media library supports playback and recording of a variety of commonly used audio and video formats, as well as static image files, etc. The media library can support a variety of audio and video encoding formats, such as: MPEG4, H.264, MP3, AAC, AMR, JPG, PNG, etc.

[0242] The 3D graphics processing library is used to implement 3D graphics drawing, image rendering, compositing, and layer processing.

[0243] A 2D graphics engine is a drawing engine for 2D drawings.

[0244] The kernel layer is the layer between hardware and software. The kernel layer contains at least display driver, camera driver, audio driver, and sensor driver.

[0245] The following is an illustrative description of the workflow of the software and hardware of the electronic device 100 in conjunction with a Bluetooth pairing scenario.

[0246] When the touch sensor 180K receives a touch operation, the corresponding hardware interrupt is sent to the kernel layer. The kernel layer processes the touch operation into raw input events (including touch coordinates, timestamp of the touch operation, and other information). The raw input events are stored in the kernel layer. The application framework layer obtains the raw input events from the kernel layer and identifies the control corresponding to the input event. For example, if the touch operation is a touch single-click operation and the control corresponding to the single-click operation is an allowed control for pairing notification, the Bluetooth application calls the interface of the application framework layer, and then starts iconnect by calling the kernel layer, and establishes a Bluetooth connection through iconnect.

[0247] As described above, the above embodiments are only used to illustrate the technical solutions of the present application, rather than to limit them. Although the present application has been described in detail with reference to the aforementioned embodiments, those skilled in the art should understand that they can still modify the technical solutions described in the aforementioned embodiments, or make equivalent replacements for some of the technical features therein. However, these modifications or replacements do not cause the essence of the corresponding technical solutions to deviate from the scope of the technical solutions of the embodiments of the present application.

Claims

1. An anomaly detection method, characterized in that: The method comprises: Determine the number of triggered terminal devices, wherein the triggered terminal devices refer to terminal devices that are triggered by the Bluetooth peripheral device to output a pairing notification, wherein the pairing notification is used to notify that the triggered terminal device is allowed to establish a Bluetooth pairing with the Bluetooth peripheral device; If the number is greater than a preset value, the Bluetooth peripheral is determined to be an abnormal Bluetooth peripheral, and abnormal information is sent to a terminal device in a cell where the Bluetooth peripheral is located, wherein the abnormal information is used to indicate that the Bluetooth peripheral is an abnormal Bluetooth peripheral.

2. The method according to claim 1, characterized in that The determining the number of triggered terminal devices includes: Receive Bluetooth pairing information, where the Bluetooth pairing information includes an identifier of a terminal device triggered by each Bluetooth peripheral device and an identifier of each corresponding Bluetooth peripheral device; According to the Bluetooth pairing information, the number of terminal device identifiers corresponding to the identifier of the Bluetooth peripheral is obtained, and the number of corresponding terminal device identifiers is used as the number of triggered terminal devices.

3. The method according to claim 2, characterized in that The Bluetooth pairing information also includes the triggering time of the triggered terminal device, and obtaining the number of terminal device identifiers corresponding to the identifier of the Bluetooth peripheral device according to the Bluetooth pairing information includes: The method further comprises obtaining, according to the Bluetooth pairing information, the number of terminal device identifiers corresponding to the identifier of the Bluetooth peripheral device within a preset time period.

4. The method according to claim 2 or 3, characterized in that The Bluetooth pairing information further includes a first cell identifier, where the first cell identifier is used to identify a cell where the Bluetooth peripheral device is located, and the sending of abnormal information to a terminal device in the cell where the Bluetooth peripheral device is located includes: Based on the first cell identifier, abnormal information is sent to a terminal device in the cell where the Bluetooth peripheral device is located.

5. The method according to any one of claims 2 to 4, characterized in that: The Bluetooth pairing information further includes a second cell identifier, where the second cell identifier is used to identify a neighboring cell of the cell where the Bluetooth peripheral is located. The method further includes: Based on the second cell identifier, the abnormal information is sent to a terminal device in a cell adjacent to the cell where the Bluetooth peripheral device is located.

6. An anomaly detection method, characterized in that: The method comprises: Receive abnormal information; the abnormal information is used to indicate an abnormal Bluetooth peripheral; According to the abnormal information, determining whether the Bluetooth peripheral corresponding to the proximity discovery message is an abnormal Bluetooth peripheral; If so, the proximity discovery message is discarded.

7. The method according to claim 6, characterized in that The abnormal information includes an identifier of the abnormal Bluetooth peripheral device, and judging whether the Bluetooth peripheral device corresponding to the proximity discovery message is an abnormal Bluetooth peripheral device according to the abnormal information includes: According to the identifier of the abnormal Bluetooth peripheral and the identifier of the Bluetooth peripheral corresponding to the proximity discovery message, it is determined whether the Bluetooth peripheral corresponding to the proximity discovery message is an abnormal Bluetooth peripheral.

8. The method according to claim 6 or 7, characterized in that The method is applied to a terminal device in a cell where the abnormal Bluetooth peripheral device is located; or a terminal device in a cell adjacent to the cell where the abnormal Bluetooth peripheral device is located.

9. An anomaly detection method, characterized in that: The method comprises: In response to the proximity discovery message, triggering output of a pairing notification, wherein the pairing notification is used to notify the triggered terminal device to allow Bluetooth pairing to be established with the Bluetooth peripheral device; the triggered terminal device refers to the terminal device that is triggered by the Bluetooth peripheral device to output the pairing notification; Upload Bluetooth pairing information to the server, wherein the Bluetooth pairing information includes an identifier of the triggered terminal device and an identifier of the Bluetooth peripheral device, and the Bluetooth pairing information is used to determine the number of terminal devices triggered by the Bluetooth peripheral device.

10. The method according to claim 9, characterized in that The Bluetooth pairing information also includes the triggering time of the triggered terminal device, and the Bluetooth pairing information is also used to determine the number of terminal devices triggered by the Bluetooth peripheral device within a preset time period.

11. The method according to claim 9 or 10, characterized in that The Bluetooth pairing information further includes a first cell identifier and / or a second cell identifier, wherein the first cell identifier is used to identify a cell where the Bluetooth peripheral device is located, and the second cell identifier is used to identify an adjacent cell of the cell where the Bluetooth peripheral device is located.

12. An anomaly detection system, characterized in that: The system comprises: a triggered terminal device, a server, and a terminal device in a cell where the Bluetooth peripheral device is located; The triggered terminal device is used to upload Bluetooth pairing information to the server; the triggered terminal device refers to a terminal device that is triggered by a Bluetooth peripheral to output a pairing notification; the pairing notification is used to notify that the triggered terminal device is allowed to establish a Bluetooth pairing with the Bluetooth peripheral; the Bluetooth pairing information includes an identifier of the triggered terminal device and an identifier of the Bluetooth peripheral; The server is used to determine the number of terminal devices triggered by the Bluetooth peripheral based on the Bluetooth pairing information, and to determine that the Bluetooth peripheral is an abnormal Bluetooth peripheral if it is determined that the number is greater than a preset value, and send abnormal information to the terminal device in the cell where the Bluetooth peripheral is located; the abnormal information is used to indicate that the Bluetooth peripheral is an abnormal Bluetooth peripheral; The terminal device in the cell where the Bluetooth peripheral is located is used to receive the abnormal information, and to determine whether the Bluetooth peripheral corresponding to the proximity discovery message is an abnormal Bluetooth peripheral based on the abnormal information; if so, the proximity discovery message is discarded.

13. A server comprising a memory, one or more processors, and one or more programs; wherein: The one or more programs are stored in the memory, and it is characterized in that when the one or more processors execute the one or more programs, the server implements the method according to any one of claims 1 to 5.

14. A terminal device, comprising a touch screen, a memory, one or more processors, and one or more programs; wherein: The one or more programs are stored in the memory, and it is characterized in that when the one or more processors execute the one or more programs, the terminal device implements the method as claimed in any one of claims 6 to 8, or implements the method as claimed in any one of claims 9 to 11.

15. A computer program product, characterized in that When the computer program product runs on an electronic device, the electronic device executes the method according to any one of claims 1 to 5, or the method according to any one of claims 6 to 8, or the method according to any one of claims 9 to 11.

16. A computer-readable storage medium, characterized in that: The computer-readable storage medium stores a computer program, and when the computer program is executed by a processor, the method according to any one of claims 1 to 5, or the method according to any one of claims 6 to 8, or the method according to any one of claims 9 to 11 is implemented.