WO2023029920A1 - 防护方法、智能锁及计算机可读存储介质 - Google Patents

防护方法、智能锁及计算机可读存储介质 Download PDF

Info

Publication number
WO2023029920A1
WO2023029920A1 PCT/CN2022/111507 CN2022111507W WO2023029920A1 WO 2023029920 A1 WO2023029920 A1 WO 2023029920A1 CN 2022111507 W CN2022111507 W CN 2022111507W WO 2023029920 A1 WO2023029920 A1 WO 2023029920A1
Authority
WO
WIPO (PCT)
Prior art keywords
light intensity
value
attack
smart lock
intensity values
Prior art date
Application number
PCT/CN2022/111507
Other languages
English (en)
French (fr)
Inventor
王伟刚
陶荣
艾勇
Original Assignee
华为技术有限公司
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by 华为技术有限公司 filed Critical 华为技术有限公司
Priority to EP22863061.2A priority Critical patent/EP4379683A1/en
Publication of WO2023029920A1 publication Critical patent/WO2023029920A1/zh

Links

Images

Classifications

    • GPHYSICS
    • G07CHECKING-DEVICES
    • G07CTIME OR ATTENDANCE REGISTERS; REGISTERING OR INDICATING THE WORKING OF MACHINES; GENERATING RANDOM NUMBERS; VOTING OR LOTTERY APPARATUS; ARRANGEMENTS, SYSTEMS OR APPARATUS FOR CHECKING NOT PROVIDED FOR ELSEWHERE
    • G07C9/00Individual registration on entry or exit
    • G07C9/00174Electronically operated locks; Circuits therefor; Nonmechanical keys therefor, e.g. passive or active electrical keys or other data carriers without mechanical keys
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F21/00Security arrangements for protecting computers, components thereof, programs or data against unauthorised activity
    • G06F21/70Protecting specific internal or peripheral components, in which the protection of a component leads to protection of the entire computer
    • G06F21/86Secure or tamper-resistant housings
    • GPHYSICS
    • G08SIGNALLING
    • G08BSIGNALLING OR CALLING SYSTEMS; ORDER TELEGRAPHS; ALARM SYSTEMS
    • G08B13/00Burglar, theft or intruder alarms
    • G08B13/02Mechanical actuation
    • G08B13/06Mechanical actuation by tampering with fastening
    • GPHYSICS
    • G08SIGNALLING
    • G08BSIGNALLING OR CALLING SYSTEMS; ORDER TELEGRAPHS; ALARM SYSTEMS
    • G08B21/00Alarms responsive to a single specified undesired or abnormal condition and not otherwise provided for
    • G08B21/18Status alarms
    • G08B21/182Level alarms, e.g. alarms responsive to variables exceeding a threshold

Definitions

  • the present application relates to the field of smart door locks, in particular to a protection method for smart locks, a smart lock and a computer-readable storage medium.
  • smart door locks are also used by more and more ordinary consumers.
  • attack methods targeting the characteristics of smart door locks.
  • some attack tools crack smart door locks by performing electromagnetic attacks (for example, high-voltage electromagnetic attacks) on smart door locks.
  • the electromagnetic waves generated by the attack tools can easily cause the main board of the smart door lock to crash, which may cause the smart door lock to restart and then unlock; in addition, the electromagnetic waves generated by the attack tools may also affect the control circuit of the smart door lock, coupling out the unlock signal, making the door open.
  • the lock receives an interference signal (for example, a similar unlock command), causing the smart door lock to be opened by mistake.
  • the above-mentioned safety hazards of smart door locks have caused a certain degree of trouble to consumers, so it is necessary to improve the safety protection performance of smart door locks.
  • the present application provides a protection method, an intelligent lock and a computer-readable storage medium.
  • the smart door lock can effectively detect electromagnetic attacks (for example, high-voltage electromagnetic attacks), and provide targeted protection, improving the security of smart door locks.
  • a smart lock is provided.
  • the smart lock is installed on the door body, and the smart lock includes: a processor; a memory, coupled to the processor; and a computer program, wherein the computer program is stored on the memory, and when the computer program is executed by the processor, the smart lock executes: After the number of trigger events detected within one cycle is greater than or equal to the first preset value, the number of suspected attacks is increased by 1; wherein, the initial number of suspected attacks is 0, and the number of suspected attacks received for the first time is Add 1 to the initial number, and the number of suspected attacks in subsequent suspected attacks is the number of previous suspected attacks plus 1; obtain the number of suspected attacks detected in the second cycle; the number of suspected attacks detected in the second cycle When the value is greater than or equal to the second preset value, the protection mode is enabled.
  • the smart lock of the present application it can be confirmed that the smart lock is subjected to electromagnetic attacks (for example, high-voltage electromagnetic attacks) through a two-level detection mechanism, wherein the first-level detection mechanism detects that the number of trigger events in the first cycle is greater than or equal to the first Preset value, it is considered that the smart lock is suspected of being attacked; the secondary detection mechanism confirms that the smart lock is subjected to electromagnetic attacks (for example, high-voltage electromagnetic attacks) by detecting that the number of suspected attacks in the second cycle is greater than or equal to the second preset value, and then Make the smart lock turn on the protection mode for active protection.
  • electromagnetic attacks for example, high-voltage electromagnetic attacks
  • the smart lock further includes: a light sensor, coupled to the processor, the light sensor is located on the outer side of the door body, and the light sensor is used to output the light intensity value; the smart lock also executes: obtaining preset Multiple light intensity values within the duration; according to multiple light intensity values, it is determined that it is under attack, and the protection mode is turned on. Based on such a design, it can be further determined that the smart lock is under attack by detecting multiple light intensity values.
  • the smart lock further executes: exiting the protection mode after a third period after the protection mode is enabled. Based on this design, the timeliness of the protection mode can be judged.
  • determining that an attack is under attack based on multiple light intensity values includes: after the detected difference between any two adjacent light intensity values is greater than or equal to a preset threshold of the difference, record The first quantity value plus 1; wherein, the initial value of the first quantity value is 0, the first quantity value recorded for the first time is added to the initial value plus 1, and the first quantity value of subsequent records is added to the previous first quantity value plus 1; After the first quantity value is greater than the preset quantity value threshold, it is determined that an attack has been received. Based on this design, it can be confirmed whether the smart lock is under attack by judging the difference between any two adjacent light intensity values.
  • multiple light intensity values are greater than or equal to a preset threshold. Based on such a design, multiple light intensity values greater than or equal to a preset threshold can be determined as a condition for detecting the difference between any two adjacent light intensity values.
  • the determination of being attacked according to multiple light intensity values includes: the difference between the maximum light intensity value and the minimum light intensity value among the multiple light intensity values is greater than or equal to the preset difference value After the threshold, it is determined to be attacked. Based on such a design, it can be confirmed whether the smart lock is attacked by judging the difference between the maximum light intensity value and the minimum light intensity value among the multiple light intensity values.
  • multiple light intensity values greater than or equal to a preset threshold may be determined as a condition for detecting the difference between the maximum light intensity value and the minimum light intensity value among the multiple light intensity values.
  • the second cycle is greater than or equal to the first cycle; the protection mode is turned on, including at least one of the following: no response to the unlock command, the drive unit of the smart lock is turned off, and the keyboard and NFC of the smart lock are turned off. module, fingerprint module or light sensor. Based on this design, the smart lock can be protected by turning off peripheral devices.
  • exiting the protection mode includes at least one of the following: responding to an unlock instruction, turning on a drive unit of the smart lock, and turning on a keyboard, NFC module, fingerprint module or light sensor of the smart lock. Based on this design, the smart lock can resume normal operation by restarting and turning on the peripheral devices.
  • the timing starting point of the preset duration includes one of the following: the timing starting point of the first cycle, the timing end point of the first cycle, and the time point when the trigger event is first detected in the first cycle;
  • the detection of the trigger event can be detected through the keyboard, NFC module, and fingerprint module of the smart lock. Based on this design, the timing point of the first cycle can be determined, and different types of trigger events can be detected through the keyboard, NFC module and fingerprint module respectively.
  • a smart lock is provided.
  • the smart lock is installed on the door body, and the smart lock includes: a processor; a memory, coupled to the processor; a light sensor, coupled to the processor, the light sensor is located on the outer side of the door body, and the light sensor is used to output light intensity values; And a computer program, wherein the computer program is stored on the memory, and when the computer program is executed by the processor, the smart lock is executed: after the number of trigger events detected in the first cycle is greater than or equal to the first preset value, the suspected The number of attacks plus 1; where the initial number of suspected attacks is 0, the number of suspected attacks when a suspected attack is first received is the initial number plus 1, and the number of suspected attacks when a subsequent suspected attack is the previous suspected attack The number plus 1; obtain multiple light intensity values within the preset time period; according to multiple light intensity values, it is determined that it is under attack, and the protection mode is turned on.
  • the smart lock of the present application it can be confirmed that the smart lock is subjected to electromagnetic attacks (for example, high-voltage electromagnetic attacks) through a two-level detection mechanism, wherein the first-level detection mechanism detects that the number of trigger events in the first cycle is greater than or equal to the first
  • the default value indicates that the smart lock is suspected of being attacked
  • the secondary detection mechanism confirms that the smart lock is under electromagnetic attack (for example, high-voltage electromagnetic attack) by detecting multiple light intensity values within a preset period of time, so that the smart lock can turn on the protection mode for further protection.
  • Active protection for example, high-voltage electromagnetic attacks
  • determining that an attack is under attack based on multiple light intensity values includes: after the detected difference between any two adjacent light intensity values is greater than or equal to a preset threshold of the difference, record The first quantity value plus 1; wherein, the initial value of the first quantity value is 0, the first quantity value recorded for the first time is added to the initial value plus 1, and the first quantity value of subsequent records is added to the previous first quantity value plus 1; After the first quantity value is greater than the preset quantity value threshold, it is determined that an attack has been received. Based on this design, it can be confirmed whether the smart lock is under attack by judging the difference between any two adjacent light intensity values.
  • multiple light intensity values are greater than or equal to a preset threshold. Based on such a design, multiple light intensity values greater than or equal to a preset threshold can be determined as a condition for detecting the difference between any two adjacent light intensity values.
  • the determination of being attacked according to multiple light intensity values includes: the difference between the maximum light intensity value and the minimum light intensity value among the multiple light intensity values is greater than or equal to the preset difference value After the threshold, it is determined to be attacked. Based on such a design, it can be confirmed whether the smart lock is attacked by judging the difference between the maximum light intensity value and the minimum light intensity value among the multiple light intensity values.
  • multiple light intensity values greater than or equal to a preset threshold may be determined as a condition for detecting the difference between the maximum light intensity value and the minimum light intensity value among the multiple light intensity values.
  • a protection method is provided, which is applied to a smart lock.
  • the smart lock is installed on the door, and the method includes: after the number of trigger events detected in the first cycle is greater than or equal to the first preset value, the number of suspected attacks is increased by 1; wherein, the initial number of suspected attacks is 0, the number of suspected attacks at the first suspected attack is the initial number plus 1, and the number of suspected attacks at subsequent suspected attacks is the number of the previous suspected attack plus 1; get the number of suspected attacks detected in the second cycle Quantity; after the number of suspected attacks detected in the second period is greater than or equal to the second preset value, the protection mode is turned on.
  • the smart lock further includes: a light sensor coupled to the processor, the light sensor is located on the outer side of the door body, and the light sensor is used to output a light intensity value.
  • the method also includes: acquiring a plurality of light intensity values within a preset time period; according to the plurality of light intensity values, it is determined that the attack is under attack, and the protection mode is turned on.
  • the method further includes: exiting the protection mode after a third cycle has elapsed after enabling the protection mode.
  • determining that an attack is under attack based on multiple light intensity values includes: after the detected difference between any two adjacent light intensity values is greater than or equal to a preset threshold of the difference, record The first quantity value plus 1; wherein, the initial value of the first quantity value is 0, the first quantity value recorded for the first time is added to the initial value plus 1, and the first quantity value of subsequent records is added to the previous first quantity value plus 1; After the first quantity value is greater than the preset quantity value threshold, it is determined that an attack has been received.
  • the determination of being attacked according to multiple light intensity values includes: the difference between the maximum light intensity value and the minimum light intensity value among the multiple light intensity values is greater than or equal to the preset difference value After the threshold, it is determined to be attacked.
  • the second cycle is greater than or equal to the first cycle; the protection mode is turned on, including at least one of the following: no response to the unlock command, the drive unit of the smart lock is turned off, and the keyboard and NFC of the smart lock are turned off. module, fingerprint module or light sensor.
  • exiting the protection mode includes at least one of the following: responding to an unlock instruction, turning on a drive unit of the smart lock, and turning on a keyboard, NFC module, fingerprint module or light sensor of the smart lock.
  • the timing starting point of the preset duration includes one of the following: the timing starting point of the first cycle, the timing end point of the first cycle, and the time point when the trigger event is first detected in the first cycle;
  • the detection of the trigger event can be detected through the keyboard, NFC module, and fingerprint module of the smart lock.
  • a protection method is provided, which is applied to a smart lock.
  • the smart lock is installed on the door body, and the smart lock includes: a processor; a light sensor coupled to the processor, the light sensor is located on the outer side of the door body, and the light sensor is used to output light intensity values.
  • the method includes: after the number of trigger events detected in the first cycle is greater than or equal to the first preset value, the number of suspected attacks is increased by 1; wherein, the initial number of suspected attacks is 0, and when the number of suspected attacks is first received The number of suspected attacks is the initial number plus 1, and the number of suspected attacks in subsequent suspected attacks is the number of previous suspected attacks plus 1; obtain multiple light intensity values within the preset duration; according to multiple light intensity values, Determined to be attacked, turn on the protection mode.
  • determining that an attack is under attack based on multiple light intensity values includes: after the detected difference between any two adjacent light intensity values is greater than or equal to a preset threshold of the difference, record The first quantity value plus 1; wherein, the initial value of the first quantity value is 0, the first quantity value recorded for the first time is added to the initial value plus 1, and the first quantity value of subsequent records is added to the previous first quantity value plus 1; After the first quantity value is greater than the preset quantity value threshold, it is determined that an attack has been received.
  • the determination of being attacked according to multiple light intensity values includes: the difference between the maximum light intensity value and the minimum light intensity value among the multiple light intensity values is greater than or equal to the preset difference value After the threshold, it is determined to be attacked.
  • a computer-readable storage medium including a computer program.
  • the smart lock executes any of the implementation methods of the third aspect and the third aspect.
  • the fourth aspect and the fourth aspect A method for any implementation of the aspect.
  • a computer program product is provided.
  • the third aspect and any one of the third aspects of the smart lock, and the fourth aspect and any one of the fourth aspects are implemented.
  • Fig. 1 is an application scenario diagram of a smart lock provided by an embodiment of the present application.
  • Fig. 2 is a schematic diagram of a smart lock provided by an embodiment of the present application.
  • Fig. 3 is a block diagram of the software structure of the smart lock provided by an embodiment of the present application.
  • Fig. 4 is a flowchart of a protection method provided by an embodiment of the present application.
  • Fig. 5 is a flowchart of a protection method provided by another embodiment of the present application.
  • Fig. 6 is a flowchart of a protection method provided by another embodiment of the present application.
  • Fig. 7 is a schematic structural diagram of a smart lock provided by an embodiment of the present application.
  • NFC module 15 fingerprint module 16 light sensor 17 power management unit 18 Battery 19 Charge and discharge circuit 20 USB interface twenty one LED twenty two flash module twenty three button twenty four bluetooth module 25 wireless communication module 26 memory 120
  • a and/or B may indicate: A exists alone, A and B exist at the same time, and B exists alone, Wherein A and B can be singular or plural.
  • the character "/" generally indicates that the contextual objects are an "or" relationship.
  • references to "one embodiment” or “some embodiments” or the like in this specification means that a particular feature, structure, or characteristic described in connection with the embodiment is included in one or more embodiments of the present application.
  • appearances of the phrases “in one embodiment,” “in some embodiments,” “in other embodiments,” “in other embodiments,” etc. in various places in this specification are not necessarily All refer to the same embodiment, but mean “one or more but not all embodiments” unless specifically stated otherwise.
  • the terms “including”, “comprising”, “having” and variations thereof mean “including but not limited to”, unless specifically stated otherwise.
  • the term “connected” includes both direct and indirect connections, unless otherwise stated.
  • first and second are used for descriptive purposes only, and cannot be understood as indicating or implying relative importance or implicitly specifying the quantity of indicated technical features.
  • a feature defined as “first” or “second” may explicitly or implicitly include one or more of such features.
  • FIG. 1 is a schematic diagram of an application scenario of a smart lock provided by an embodiment of the present application.
  • the smart lock can be installed on the door body 200 to form a smart door lock, which is suitable for smart home.
  • the protection method of the present application is applied to an intelligent lock.
  • smart home is based on the residence as a platform, using integrated wiring technology, network communication technology, security technology, automatic control Technology, audio and video technology integrates facilities related to home life, builds an efficient management system for residential facilities and family schedules, improves home safety, convenience, comfort, and artistry, and realizes an environmentally friendly and energy-saving living environment.
  • the opposite sides of the door body 200 may be the outside of the door 201 and the inside of the door 202 .
  • the side outside the door 201 may be the outside of the home
  • the side inside the door 202 may be the inside of the home.
  • the keyboard 14, the near field communication (Near Field Communication, NFC) module 15, the fingerprint module 16, the optical sensor 17, etc. can be installed on the surface of the door body 200 facing the outside 201, which can be used by the user to perform unlocking operations and detect the outside of the door. environment.
  • the lock body 12 can be installed on one side of the door body 200 , so as to be conveniently stretched out or accommodated in the door body 200 , and can be switched between locked and unlocked states.
  • FIG. 2 is a schematic diagram of a smart lock provided by an embodiment of the present application.
  • the smart lock 100 may include a processor 110 , a lock body 12 , a drive unit 13 , a keyboard 14 , an NFC module 15 , a fingerprint module 16 and a light sensor 17 .
  • the processor 110 may include but not limited to a MicroController Unit (MCU).
  • the processor 110 is at least integrated with a memory, a micro control unit and a counter (timer). It can be understood that the processor 110 can also be integrated with various types of interfaces, an analog to digital converter (Analog to Digital Converter, ADC), a universal asynchronous receiver transmitter (Universal Asynchronous Receiver/Transmitter, UART), a programmable logic controller (Programmable Logic Controller, PLC), direct memory access (Direct Memory Access, DMA) and other functional modules and electronic components.
  • ADC Analog to Digital Converter
  • UART Universal Asynchronous Receiver/Transmitter
  • PLC programmable logic controller
  • DMA Direct Memory Access
  • memory is used to store program codes and various data.
  • Memory can include read-only memory (Read-Only Memory, ROM), random access memory (Random Access Memory, RAM), programmable read-only memory (Programmable Read-Only Memory, PROM), erasable programmable read-only memory (Erasable Programmable Read-Only Memory, EPROM), One Time Programmable Read-Only Memory (OTPROM), Electronically Erasable Programmable Read-Only Memory, EEPROM, Compact Disc Read-Only Memory (CD-ROM) or other optical disk storage, magnetic disk storage, tape storage, or any other computer-readable medium that can be used to carry or store data.
  • Read-Only Memory Read-Only Memory
  • RAM Random Access Memory
  • PROM Programmable Read-Only Memory
  • PROM Programmable Read-Only Memory
  • EPROM erasable programmable read-only memory
  • OTPROM One Time Programmable Read-Only Memory
  • EEPROM Electrically Erasable Programmable Read-Only Memory
  • processor 110 may consist of an integrated circuit.
  • the processor 110 may be composed of a single packaged integrated circuit, or may be composed of multiple integrated circuits packaged with the same function or different functions.
  • the processor 110 may include one or more central processing units (Central Processing Unit, CPU), a micro control unit, a digital processing chip, a graphics processor, a combination of various control chips, and the like.
  • At least one processor is the control core (Control Core) of the smart lock, which executes various functions and processes data of the smart lock by running or executing programs or modules stored in the memory, and calling data stored in the memory, such as Functions that perform data processing.
  • Control Core Control Core
  • the above-mentioned integrated units implemented in the form of software function modules can be stored in a computer-readable storage medium.
  • the above-mentioned software function modules are stored in a storage medium, including several instructions to make a computer device (which may be a personal computer, a terminal, or a network device, etc.) or a processor (processor) execute part of the protection method of each embodiment of the present application .
  • Computer programs such as program codes, are stored in the memory, and at least one processor can invoke the program codes stored in the memory to perform related functions.
  • the memory stores a plurality of instructions, and the plurality of instructions are executed by at least one processor to implement the protection method.
  • the driving unit 13 is used to drive the lock body 12 to lock or unlock the door body 200 .
  • the driving unit 13 may include but not limited to a motor controlled by the processor 110 to drive the physical movement of the lock body 12 so as to lock or unlock the door 200 by the lock body 12 .
  • the drive unit 13 includes a motor.
  • the keyboard 14 can be installed on the surface of the door body 200 facing the outside 201 for detecting the user's typing operation.
  • the keyboard 14 may include, but not limited to, a numeric keypad for detecting a user's input command, and the input command may include a combination of numbers corresponding to the numeric keypad to form a password command for unlocking the lock body 12 .
  • the NFC module 15 can be installed on the surface of the door body 200 facing the outside 201 for detecting NFC signals.
  • the NFC module 15 can be used to detect the NFC signal of the paired NFC card, and the NFC signal of the paired NFC card can form a password command for unlocking the lock body 12 .
  • the fingerprint module 16 can be installed on the surface of the door body 200 facing the outside 201 of the door, and is used for detecting a pressed fingerprint signal. In some embodiments, the fingerprint module 16 can be used to detect a pre-registered fingerprint signal, and the fingerprint signal can form a password instruction for unlocking the lock body 12 .
  • the light sensor 17 can be installed on the surface of the door body 200 facing the outside 201 of the door, for detecting the light signal of the outside 201 of the door. In some embodiments, light sensor 17 may be used to detect ambient light intensity.
  • the smart lock 100 can form an unlock command to open the lock body 12 by detecting the combination of key input numbers through the keyboard 14, detecting the paired NFC card through the NFC module 15, or detecting a pre-registered fingerprint signal through the fingerprint module 16.
  • the smart lock 100 can also include a power management unit 18, a battery 19, a charging and discharging circuit 20, a USB interface 21, an LED 22, a flash module 23, a button 24, a Bluetooth module 25 and a wireless Communication module 26.
  • the power management unit 18 may include a power management unit (Power Management Unit, PMU) chip, which can be used to realize the conversion, distribution, detection and other functions of power energy management in the smart lock 100 .
  • the battery 19 can be a rechargeable and dischargeable battery.
  • the battery 19 can supply power to each component and module of the smart lock 100 through the power management unit 18 .
  • the charging and discharging circuit 20 can charge the battery 19 through the power management unit 18 .
  • the charging and discharging circuit 20 may include a charging and discharging chip or a charging and discharging management chip.
  • the USB interface 21 can be connected with external devices, so as to realize data and power signal interaction between the smart lock 100 and external devices.
  • the LED 22 and flash module 23 can be used for indicating the working status of smart lock 100.
  • the button 24 can be used for but not limited to changing the working state of the smart lock 100 .
  • the user operation is provided through the key 24 to increase the locking state of the lock body 12 , such as secondary locking.
  • the Bluetooth module 25 can be used to establish a Bluetooth connection with an external device, so as to realize data interaction based on Bluetooth transmission.
  • the Bluetooth module 25 may include but not limited to Bluetooth Low Energy (or called Bluetooth Low Energy, Bluetooth Low Energy, BLE), which has the characteristics of low power consumption.
  • the wireless communication module 26 can be used to establish a wireless communication connection with external devices, so as to realize data interaction based on wireless communication transmission.
  • the wireless communication module 26 may include but not limited to a wireless fidelity (Wireless Fidelity, Wi-Fi) chip, and may establish a wireless communication connection with an external device, for example, a Wi-Fi connection.
  • Wi-Fi wireless Fidelity
  • the smart lock 100 includes not limited to the above-mentioned electronic components and modules, and the structure shown in the embodiment does not constitute a specific limitation to the smart lock 100 .
  • the smart lock 100 may also include other necessary electronic components, modules, circuits, etc., may include more or less components than those shown in the figure, or combine certain components, or split certain components, Or different component arrangements, which are not limited here.
  • the illustrated components can be realized in hardware, software or a combination of software and hardware.
  • FIG. 3 is a software structural block diagram of the smart lock 100 according to an embodiment of the present application.
  • the layered architecture divides the software into several layers, and each layer has a clear role and division of labor. Layers communicate through software interfaces.
  • the software system is divided into three layers, which are application layer, business architecture layer and kernel driver layer from top to bottom.
  • the application layer may include an attack detection business module, a two-machine communication module, an active protection business module, etc.
  • the attack detection service module can be used to detect and judge the electromagnetic attack (for example, high-voltage electromagnetic attack) suffered by the smart lock 100 .
  • the active protection service module can be used to control the smart lock 100 to enter the protection mode and shut down related peripheral devices when obtaining an electromagnetic attack (for example, a high-voltage electromagnetic attack) detected by the attack detection service module. For example, power off the drive unit 13 , the keyboard 14 , the NFC module 15 , the fingerprint module 16 and the light sensor 17 to protect the smart lock 100 and related devices.
  • the dual-computer communication module can be used to establish a communication connection with external devices and realize communication functions.
  • the business framework layer provides application programming interface (Application Programming Interface, API) and programming framework for the business modules of the application layer.
  • the business framework layer includes some predefined functions. As shown in Figure 3, the business framework layer may include an interconnection framework, a sensing framework, a drive framework, and business subsystems, and the business subsystem may include a fingerprint recognition subsystem, a battery management subsystem, and a door lock control subsystem.
  • the driver framework can be used to provide the application layer with a peripheral device (such as a keyboard 14, NFC module 15, fingerprint module 16, light sensor 17, etc.) control interface, respond to the interrupt reported by the peripheral device driver, and process and analyze the interrupt data. Report to the corresponding business module of the application layer. For example, attack detection business module and active protection business module, etc.
  • the interconnection framework can be used to provide a control interface for the application layer business module (such as a two-machine communication module), and respond to and process the data of the corresponding business module.
  • the sensing framework can be used to respond to and process the data of corresponding peripheral devices (eg, NFC module 15 and light sensor 17, etc.) and report to the corresponding business modules of the application layer, such as attack detection business modules and active protection business modules.
  • the fingerprint identification subsystem can be used to respond to and process the data of the corresponding peripheral device (for example, the fingerprint module 16) and report to the corresponding service modules of the application layer, for example, the attack detection service module and the active protection service module.
  • the door lock control subsystem can be used to respond to and process the data of the corresponding peripheral device (for example, the drive unit 13 ) and report to the corresponding business module of the application layer.
  • attack detection business module and active protection business module etc.
  • the battery management subsystem can be used to respond to and process data of corresponding peripheral devices (eg, power management unit 18 ) and report to corresponding business modules of the application layer, such as attack detection business modules and active protection business modules.
  • the kernel layer is the layer between hardware and software.
  • the kernel layer includes at least a fingerprint sensor driver, a light sensor driver, a motor driver, an NFC driver, a button driver, a Bluetooth driver, and the like.
  • the fingerprint sensor driver can correspondingly drive and control the fingerprint module 16 .
  • the light sensor driving can correspondingly drive and control the light sensor 17 .
  • the motor driving can drive and control the driving unit 13 correspondingly.
  • the NFC driver can correspondingly drive and control the NFC module 15 .
  • the key driving can correspond to driving and controlling the keyboard 14 .
  • the Bluetooth driver can correspondingly drive and control the Bluetooth module 25 .
  • the Bluetooth driver may include a corresponding BLE driver, and may correspondingly drive and control the BLE.
  • FIG. 4 is a flow chart of the protection method provided by the embodiment of the present application. Wherein, the protection method is applied to the smart lock 100 . Exemplarily, the protection method may include the following steps:
  • the keyboard 14, the NFC module 15 and the fingerprint module 16 detect trigger events respectively.
  • the keyboard 14 when the keyboard 14 detects a key interruption signal, it can be judged as a key trigger event; when the NFC module 15 detects an NFC signal, it can be judged as an NFC trigger event; when the fingerprint module 16 detects a touch fingerprint signal, it can be judged as a fingerprint trigger event. event.
  • the keyboard 14 , the NFC module 15 and the fingerprint module 16 can respectively send the detected trigger events to the processor 110 .
  • the first period T1 may be 30 milliseconds
  • the first preset value N1 may be three.
  • the processor 110 determines whether the accumulated number of trigger events detected by the keyboard 14 , the NFC module 15 and the fingerprint module 16 in the first period T1 is greater than or equal to the first preset value N1 .
  • the keyboard 14 detects a key trigger event
  • the NFC module 15 detects an NFC trigger event
  • the fingerprint module 16 detects a fingerprint trigger event
  • the processor 110 determines the first The number of trigger events detected in the period T1 is three times, thus satisfying the condition of being greater than or equal to the first preset value N1.
  • the keyboard 14 detects two button trigger events, and the NFC module 15 detects an NFC trigger event, then the processor 110 determines the number of trigger events detected within the first period T1 three times, thus satisfying the condition of being greater than or equal to the first preset value N1.
  • the smart lock 100 determines that the smart lock 100 is under a suspected attack (for example, there is a suspected attack event) according to the above judgment conditions.
  • suspected attacks may include, but are not limited to, electromagnetic wave attacks.
  • the smart lock 100 can use at least one of the keyboard 14 , the NFC module 15 and the fingerprint module 16 to collect input password instructions for comparison and verification of unlocking.
  • the first period T1 can be set to a relatively short time period (for example, 30 milliseconds); and generally speaking, when the user normally unlocks the input, the keypad 14, the NFC module 15 and the fingerprint module 16 At least one operation duration (for example, 1 second or a few seconds) will be longer than the first period T1; in this way, the suspected attack can be effectively distinguished from the user's normal unlocking input, reducing or even preventing misidentification , thereby avoiding or reducing unnecessary processing.
  • the duration of the user's password input operation on the keyboard 14 is generally 5 seconds, which is longer than the first period T1 (eg, 30 milliseconds).
  • the time interval between inputting the i-th password bit and the (i+1)-th password bit i is greater than or equal to 1, and less than or equal to M Any number of ), generally greater than the first period T1. Therefore, the smart lock 100 will not be misidentified as a suspected attack during the normal unlocking input of the user.
  • the smart lock 100 continuously detects multiple (such as three or more) trigger events, then the smart lock 100 considers that it is suspected of being attacked, for example, it is suspected of being attacked by electromagnetic waves, etc. . In a word, the smart lock 100 can accurately identify and distinguish suspected attack and normal unlocking input.
  • S413 is an optional step, and related execution of S413 may be replaced by execution of S414 and S415.
  • the second period T2 can be set to 1 second, and the second preset value N2 can be set to 2.
  • the second period T2 can be set to other durations.
  • the second preset value N2 can be set to other values. This application is not limited.
  • the smart lock determines that the number of suspected attack events detected in the second period T2 is greater than or equal to the second preset value N2, S417 is executed. Otherwise, go back to S411.
  • the second period is greater than, less than or equal to the first period.
  • the second preset value is greater than, smaller than or equal to the first preset value.
  • the light sensor 17 acquires the light intensity value of the current ambient light on the side outside the door 201 within a preset time period (for example, 0.5 seconds), and transmits it to the processor 110 .
  • a preset time period for example, 0.5 seconds
  • S414 and S415 are executed synchronously or simultaneously, and the two branches perform further detection synchronously or simultaneously.
  • the preset duration can be set or adjusted by the user, or set by the manufacturer before leaving the factory, or updated by the manufacturer when upgrading the software.
  • the timing start point of the current preset duration may be the timing start point of the first cycle, may also be the timing end point of the first cycle, and may also be the time point when the trigger event is detected for the first time in the first cycle. This application does not limit this.
  • the smart lock 100 (or the processor 110) can determine whether the range of change of multiple light intensity values (for example, the range of change between the maximum light intensity value and the minimum light intensity value) is greater than or equal to the preset threshold L1 .
  • the preset threshold L1 is a preset light intensity threshold.
  • the smart lock 100 can determine whether the variation range of any two detected adjacent light intensity values is greater than or equal to the difference preset threshold L2, so as to determine the variation range of multiple light intensity values.
  • the light sensor 17 continuously detects multiple light intensity values (for example, five light intensity values) within a preset time period. If the smart lock 100 (or processor 110) judges whether the difference between any two adjacent light intensity values detected is greater than or equal to the difference preset threshold L2; if one is greater than or equal to, record the first amount Value plus 1, wherein the initial value of the first quantity value is 0, the first quantity value of the first record plus 1, and the first quantity value of subsequent records plus 1; if any If the difference above half (which may be referred to as the preset quantitative value threshold) is greater than or equal to the difference preset threshold L2, then the smart lock 100 (or processor 110) judges that the variation range of multiple light intensity values exceeds the preset threshold, It is also confirmed that the smart lock 100 is subject to illegal attacks (for example, high-voltage electromagnetic attacks).
  • illegal attacks for example, high-voltage electromagnetic attacks
  • five light intensity values are continuously detected, which may be referred to as the first light intensity value, the second light intensity value, the third light intensity value, the fourth light intensity value and the fifth light intensity value;
  • There are four differences between adjacent light intensity values which can be called the first difference between the first light intensity value and the second light intensity value, the second difference between the second light intensity value and the third light intensity value, and the third difference between the second light intensity value and the third light intensity value.
  • the difference values of 4 adjacent light intensity values namely the first difference value, the second difference value, the third difference value, and the fourth difference value
  • the difference preset threshold L2 the difference values of 4 adjacent light intensity values
  • the smart lock 100 thinks that the smart lock 100 is under electromagnetic attack (for example, high-voltage electromagnetic attack) .
  • electromagnetic attacks such as high-voltage electromagnetic attacks launched by electric batons
  • multiple flashes usually generate multiple fluctuating light intensity values, and the multiple flashes fluctuate in a state of strong and weak light intensity values, but the multiple light intensity values can all be greater than or equal to the preset threshold L1, and The difference between two adjacent light intensity values will be greater than or equal to the preset difference threshold L2 (for example, the first difference is greater than or equal to the preset difference threshold L2).
  • the smart lock 100 can also first detect that multiple light intensity values are greater than or equal to the preset threshold L2. Set threshold L1.
  • the smart lock when more than half of the difference between any two adjacent light intensity values detected by the smart lock 100 (or the processor 110) is greater than or equal to the difference preset threshold L2, Then the smart lock (or the processor 110 ) can determine that the variation range of the multiple light intensity values exceeds a preset threshold, and confirm that the smart lock 100 is subjected to electromagnetic attack (for example, a high-voltage electromagnetic attack).
  • electromagnetic attack for example, a high-voltage electromagnetic attack
  • the smart lock 100 judges that more than one The change range of the light intensity value does not exceed the preset threshold, and it is considered that there is no electromagnetic attack (for example, no high-voltage electromagnetic attack). For example, in the scenario where the smart lock 100 is always illuminated by strong light, continuous fluctuating light intensity values generally do not appear when the strong light directly shines on the smart lock 100 .
  • the light sensor 17 continuously detects multiple light intensity values (for example, 5 light intensity values), and the smart lock 100 (or processor 110) judges the maximum light intensity value and the minimum light intensity value among the multiple light intensity values. Whether the difference between the intensity values (for example, the first light intensity value is the maximum light intensity value and the third light intensity value is the minimum light intensity value, then judge the difference between the first light intensity value and the third light intensity value) is greater than Or equal to the difference preset threshold L2.
  • the smart lock 100 judges that the magnitude of change of the multiple light intensity values exceeds the preset threshold, and considers that the smart lock 100 is subjected to an electromagnetic attack (for example, a high-voltage electromagnetic attack). attack). If the difference is less than the difference preset threshold L2, then the smart lock 100 (or processor 110) judges that the range of change of the multiple light intensity values does not exceed the preset threshold, and considers that the smart lock 100 is not considered to be under electromagnetic attack (for example, there is no electromagnetic attack). subject to high voltage electromagnetic attack).
  • the smart lock 100 can also detect multiple The light intensity value is greater than or equal to the preset threshold L1.
  • the smart lock 100 (or the processor 110 ) starts the protection mode, and starts the timing of the third period T3.
  • turning on the protection mode includes: turning off the drive unit 13 to prevent interference signals caused by electromagnetic attacks (eg, high-voltage electromagnetic attacks) from falsely triggering the drive unit 13 to open the lock body 12 .
  • electromagnetic attacks eg, high-voltage electromagnetic attacks
  • turning on the protection mode also includes: turning off the peripheral devices of the processor such as the keyboard 14 , the NFC module 15 , the fingerprint module 16 and the light sensor 17 , so as to prevent damage to the peripheral devices.
  • turning on the protection mode also includes: the processor 110 may not respond to any password commands, and does not respond to the detection signals of the keyboard 14, NFC module 15, fingerprint module 16 and light sensor 17, that is, the processor 110 does not respond to the unlock command.
  • closing the keyboard 14 , the NFC module 15 , the fingerprint module 16 and the light sensor 17 may mean disconnecting the power supply to the keyboard 14 , the NFC module 15 , the fingerprint module 16 and the light sensor 17 .
  • the third period T3 may include one of 3 seconds, 5 seconds and other durations.
  • the third period T3 may also be any other length, which is not limited in the present application.
  • the way of timing can be replaced, instead of using the way of counting down the third cycle, but adopting the way of counting up (for example, counting from 0).
  • the smart lock 100 exits the protection mode, the smart lock 100 resumes normal operation, and can return to execute S411 again.
  • the keyboard 14, the NFC module 15, the fingerprint module 16 and the light sensor 17 are powered on again, the drive unit 13 is turned on again, and the processor 110 resumes responding to password commands and detection signals.
  • the protection method of the embodiment of the present application confirms that the smart lock 100 is subjected to electromagnetic attacks (for example, high-voltage electromagnetic attacks) through a two-level detection mechanism, wherein the first-level detection mechanism detects a trigger event within the first cycle (for example, the trigger event includes At least one of the button trigger event, NFC trigger event and fingerprint trigger event) is greater than or equal to the first preset value, it is considered to be suspected of attack; the secondary detection mechanism detects the suspected attack by the preliminary detection mechanism at the primary detection mechanism. Within a set period of time, multiple light intensity values are obtained and the range of change of the multiple light intensity values exceeds a preset threshold, confirming that the smart lock 100 is subjected to electromagnetic attacks (for example, high-voltage electromagnetic attacks).
  • electromagnetic attacks for example, high-voltage electromagnetic attacks
  • the smart lock 100 After confirming the electromagnetic attack, the smart lock 100 (or the processor 110) enters the protection mode for active protection, does not respond to external interrupts, prevents accidental unlocking, and protects the peripheral devices from damage, thereby greatly improving the security of the smart lock 100. safety factor.
  • the above-mentioned secondary detection mechanism is only exemplary, and is not intended to limit the scope of the present application.
  • more detection mechanisms such as a three-level detection mechanism and a four-level detection mechanism can also be used.
  • S413 is an optional step and can be omitted, and the execution of S413 can be replaced by execution of S414 and S415.
  • S414 and S415 are executed synchronously or simultaneously, and the two branches are synchronously or simultaneously for further detection, or S415 can be executed separately, and only one branch is carried out for further detection, and S414 is optional at this time steps can be omitted.
  • Fig. 5 shows a possible flowchart of a protection method according to another embodiment of the present application.
  • the protection method is applied to the smart lock 100 .
  • the protection method may include the following steps:
  • the keyboard 14, the NFC module 15 and the fingerprint module 16 respectively detect trigger events and send them to the processor 110, and the processor 110 judges whether the number of trigger events detected in T1 in the first cycle is greater than or equal to the first preset Value N1.
  • the implementation process of S511 may refer to the aforementioned S411 and S412. When the number of trigger events detected in the first period T1 is greater than or equal to the first preset value N1, execute S512; otherwise, return to execute S511.
  • the light sensor 17 is located on the outside side of the door. Within a preset time period, the light sensor 17 continuously detects a plurality of light intensity values on the side outside the door 201, and judges whether the range of change of the multiple light intensity values exceeds preset threshold.
  • part of the light sensor 17 is located on the outside side of the door, and part is located on the inside side of the door.
  • the light sensor 17 located outside the door continuously monitors multiple light intensity values on the side outside the door 201, and judges whether the variation range of the multiple light intensity values exceeds a preset threshold.
  • the implementation process of S512 may refer to the aforementioned S415 and S416.
  • the smart lock 100 (or the processor 110 ) enables the protection mode for the smart lock 100 .
  • the implementation process of S513 may refer to the aforementioned S417.
  • the protection method of the embodiment of the present application makes the smart lock 100 effectively detect electromagnetic attacks (such as high-voltage electromagnetic attacks) through an active protection mechanism against electromagnetic attacks (such as high-voltage electromagnetic attacks), and performs targeted protection to improve The security of the smart lock 100 is guaranteed.
  • electromagnetic attacks such as high-voltage electromagnetic attacks
  • active protection mechanism against electromagnetic attacks such as high-voltage electromagnetic attacks
  • FIG. 6 shows a possible flow chart of a protection method in another embodiment of the present application.
  • the protection method is applied to the smart lock 100 .
  • the protection method may include the following steps:
  • the keyboard 14, the NFC module 15 and the fingerprint module 16 respectively detect trigger events and send them to the processor 110, and the processor 110 judges whether the number of trigger events detected in T1 in the first cycle is greater than or equal to the first preset Value N1.
  • the implementation process of S611 may refer to the aforementioned S411 and S412. When the number of trigger events detected in the first period T1 is greater than or equal to the first preset value N1, execute S612 and S613 synchronously or simultaneously, and the two branches perform further detection synchronously or simultaneously; otherwise, return to execute S611.
  • the light sensor 17 continuously detects multiple light intensity values on the side outside the door 201 and determines whether the variation range of the multiple light intensity values exceeds a preset value.
  • the implementation process of S612 may refer to the aforementioned S415 and S416.
  • the processor 110 determines whether the number of suspected attack events detected within the second period T2 is greater than or equal to a second preset value N2.
  • the implementation process of S613 may refer to the aforementioned S414.
  • the processor 110 enables the protection mode of the smart lock 100 and starts the timing of the third period T3.
  • the implementation process of S614 may refer to the aforementioned S417 and S418.
  • the processor 110 ends the protection mode, the smart lock 100 resumes normal operation, and may return to execute S611 again.
  • the implementation process of S615 may refer to the aforementioned S419.
  • S611 and S613 are executed synchronously or simultaneously, and the two branches perform further detection synchronously or simultaneously.
  • S612 can be executed separately, and only one branch is performed for further detection.
  • S613 is an optional step, which can be omitted or reserved. In the case of omitting S613, after S612, when the judgment result of S612 is No, execute S611, and when the judgment result of S612 is Yes, execute S614. In the case of retaining S613, after S612, when the judgment result of S612 is No, execute S613, and when the judgment result of S612 is Yes, execute S614.
  • the smart lock 100 by detecting the change characteristics of the trigger event when the smart lock 100 is subjected to an electromagnetic attack (for example, a high-voltage electromagnetic attack) as a first-level detection, and detecting the variation range of the light intensity during the attack as a second-level detection, to It is judged whether the smart lock 100 is subjected to an electromagnetic attack (for example, a high-voltage electromagnetic attack).
  • an electromagnetic attack for example, a high-voltage electromagnetic attack
  • the smart lock 100 is controlled to enter the protection mode for active protection, does not respond to external interrupts, prevents accidental unlocking, and protects various peripheral devices from damage, thereby greatly improving the smart lock.
  • the lock has a safety factor of 100.
  • the above-mentioned electronic device includes corresponding hardware structures and/or software modules for performing each function.
  • the embodiments of the present application can be implemented in the form of hardware or a combination of hardware and computer software in combination with the example units and algorithm steps described in the embodiments disclosed herein. Whether a certain function is executed by hardware or computer software drives hardware depends on the specific application and design constraints of the technical solution. Those skilled in the art may use different methods to implement the described functions for each specific application, but such implementation should not be regarded as exceeding the scope of the embodiments of the present application.
  • the embodiments of the present application may divide the above-mentioned electronic device into functional modules according to the above-mentioned method examples.
  • each functional module may be divided corresponding to each function, or two or more functions may be integrated into one processing module.
  • the above-mentioned integrated modules can be implemented in the form of hardware or in the form of software function modules. It should be noted that the division of modules in the embodiment of the present application is schematic, and is only a logical function division, and there may be other division methods in actual implementation.
  • the technical solution of the embodiment of the present application can not only obtain the light intensity value through the light sensor to perform the subsequent judgment condition or one of the judgment conditions of the change range of the light intensity value, but also can use other sensors to judge.
  • the application does not limit the specific type of sensor.
  • FIG. 7 shows a possible structural schematic diagram of the smart lock involved in the above embodiment.
  • the smart lock 100 includes: a processor 110 and a memory 120 .
  • the processor 110 is coupled to the memory 120, and the coupling in this embodiment of the present application may be a communication connection, may be an electrical connection, or may be in other forms.
  • the memory 120 is used to store computer programs.
  • the processor 110 is used to call the computer program stored in the memory 120, so that the smart lock 100 executes the steps performed by the smart lock in the method provided by the embodiment of the present application. Relevant procedures can refer to the above, and will not be repeated here.
  • the smart lock 100 may further include a display screen; when the display screen has a touch function, the display screen is also called a touch display screen.
  • the operation on the touch screen can be realized by virtual keys.
  • the display screen When the display screen does not have a touch function, the display screen is also called a non-touch display screen. Operations on the non-touch display can be achieved through physical keys.
  • the present application provides a computer program product.
  • the smart lock is made to execute the steps performed by the smart lock in the protection method provided by the embodiment of the present application.
  • the present application provides a computer-readable storage medium, including a computer program.
  • the computer program runs on the smart lock, the smart lock executes the steps performed by the smart lock in the protection method provided by the embodiment of the present application.
  • the smart lock 100 may not include a display screen.
  • the embodiments of the present application can be implemented by hardware, or by hardware and software.
  • the above functions can be stored in a computer-readable medium.
  • the technical solution of the embodiment of the present application is essentially or the part that contributes to the prior art or all or part of the technical solution can be embodied in the form of a software product, and the computer software product is stored in a storage
  • the medium includes several computer programs to enable a computer device (which may be a personal computer, server, or network device, etc.) or a processor to execute all or part of the steps of the methods described in the various embodiments of the present application.
  • the aforementioned storage medium includes: flash memory, mobile hard disk, read-only memory, random access memory, magnetic disk or optical disk, and other various media capable of storing program codes.

Landscapes

  • Engineering & Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Computer Hardware Design (AREA)
  • Theoretical Computer Science (AREA)
  • Computer Security & Cryptography (AREA)
  • Software Systems (AREA)
  • General Engineering & Computer Science (AREA)
  • Lock And Its Accessories (AREA)

Abstract

本申请涉及一种防护方法、智能锁及计算机可读存储介质。该方法通过两级检测机制来确认智能锁受到电磁攻击(比如,高压电磁攻击),其中一级检测机制通过在第一周期内检测到触发事件的数量大于或等于第一预设值,认为智能锁受到疑似攻击;二级检测机制通过在一级检测机制检测到疑似攻击时的预设时长内,获取多个光强度值并检测多个光强度值的变化幅度超过预设阈值,确认智能锁受到电磁攻击(比如,高压电磁攻击)。经过两级检测机制确认受到电磁攻击后,智能锁进入保护模式进行主动防护,防止误开锁,同时保护各外设器件不受损害,提高了安全性。

Description

防护方法、智能锁及计算机可读存储介质
相关申请的交叉引用
本申请要求于2021年9月6日提交中国专利局、申请号为202111039095.4、申请名称为“防护方法、智能锁及计算机可读存储介质”的中国专利的优先权,其全部内容通过引用结合在本申请中。
技术领域
本申请涉及智能门锁领域,尤其涉及智能锁的防护方法、智能锁及计算机可读存储介质。
背景技术
随着智能家居的广泛应用,智能门锁也被越来越多的普通消费者使用。虽然智能门锁在使用上更为方便,但也存在一些针对智能门锁的特性的攻击方式。比如,一些攻击工具通过对智能门锁进行电磁攻击(比如,高压电磁攻击)来破解智能门锁。比如,攻击工具产生的电磁波容易导致智能门锁的主板死机,可能导致智能门锁重启,进而开锁;另外,攻击工具产生的电磁波也可能影响智能门锁的控制电路,耦合出开锁信号,使得门锁接收到干扰信号(例如,类似的开锁指令),造成智能门锁误开启。智能门锁的上述安全隐患给消费者造成一定程度的困扰,因此需要提高智能门锁的安全防护性能。
发明内容
为了解决上述的技术问题,本申请提供了一种防护方法、智能锁及计算机可读存储介质。通过针对电磁攻击(比如,高压电磁攻击)的主动防护机制,使得智能门锁有效地检测电磁攻击(比如,高压电磁攻击),并针对性地进行防护,提高了智能门锁的安全性。
第一方面,提供一种智能锁。智能锁安装在门体上,智能锁包括:处理器;存储器,耦合至处理器;以及计算机程序,其中计算机程序存储在存储器上,当计算机程序被处理器执行时,使得智能锁执行:在第一周期内检测到的触发事件的数量大于或等于第一预设值后,受到疑似攻击的数量加1;其中,受到疑似攻击的初始数量为0,首次受到疑似攻击时的疑似攻击的数量为初始数量加1,后续受到疑似攻击时的疑似攻击的数量为前一次疑似攻击的数量加1;获取第二周期内检测到的疑似攻击的数量;在第二周期内检测到的疑似攻击的数量大于或等于第二预设值后,开启保护模式。
采用本申请的智能锁,可以通过两级检测机制来确认智能锁受到电磁攻 击(比如,高压电磁攻击),其中一级检测机制通过在第一周期内检测到触发事件的数量大于或等于第一预设值,认为智能锁受到疑似攻击;二级检测机制通过在第二周期内检测疑似攻击的数量大于或等于第二预设值,确认智能锁受到电磁攻击(比如,高压电磁攻击),以使智能锁开启保护模式进行主动防护。
在一种可能的实现方式中,智能锁还包括:光传感器,耦合至处理器,光传感器位于门体的门外一侧,光传感器用于输出光强度值;智能锁还执行:获取预设时长内的多个光强度值;根据多个光强度值,确定受到攻击,开启保护模式。基于这样的设计,可以进一步通过检测多个光强度值来确定智能锁受到攻击。
在一种可能的实现方式中,智能锁还执行:在开启保护模式之后,经过第三周期后,退出保护模式。基于这样的设计,可以判断保护模式的时效性。
在一种可能的实现方式中,根据多个光强度值,确定受到攻击,包括:在检测到的任意两个相邻的光强度值的差值,大于或等于差值预设阈值后,记录第一数量值加1;其中,第一数量值的初始值为0,首次记录的第一数量值为初始值加1,后续记录的第一数量值为前一次的第一数量值加1;在第一数量值大于预设的数量值阈值后,确定受到攻击。基于这样的设计,可以通过判断任意两个相邻光强度值的差值来确认智能锁是否受到攻击。
在一种可能的实现方式中,在检测任意两个相邻的光强度值的差值之前,确定多个光强度值大于或等于预设阈值。基于这样的设计,可以确定多个光强度值大于或等于预设阈值作为检测任意两个相邻的光强度值的差值的条件。
在一种可能的实现方式中,根据多个光强度值,确定受到攻击,包括:在多个光强度值中的最大光强度值与最小光强度值的差值,大于或等于差值预设阈值后,确定受到攻击。基于这样的设计,可以通过判断多个光强度值中的最大光强度值与最小光强度值的差值来确认智能锁是否受到攻击。
在一种可能的实现方式中,在检测多个光强度值中的最大光强度值与最小光强度值的差值之前,确定多个光强度值大于或等于预设阈值。基于这样的设计,可以确定多个光强度值大于或等于预设阈值作为检测多个光强度值中的最大光强度值与最小光强度值的差值的条件。
在一种可能的实现方式中,第二周期大于或等于第一周期;开启保护模式,包括以下的至少一种:不响应开锁指令,关闭智能锁的驱动单元,以及关闭智能锁的键盘、NFC模块、指纹模块或光传感器。基于这样的设计,可以通过关闭外设器件来进行保护智能锁。
在一种可能的实现方式中,退出保护模式,包括以下的至少一种:响应开锁指令,开启智能锁的驱动单元,以及开启智能锁的键盘、NFC模块、指纹模块或光传感器。基于这样的设计,可以通过重启开启外设器件来使智能锁恢复正常工作。
在一种可能的实现方式中,预设时长的计时起点包括以下的一种:第一 周期的计时起点、第一周期的计时终点,及在第一周期内首次检测到触发事件的时间点;触发事件的检测可通过智能锁的键盘、NFC模块、指纹模块来检测。基于这样的设计,可以确定第一周期的计时点,以及通过键盘、NFC模块及指纹模块分别检测不同类型的触发事件。
第二方面,提供一种智能锁。智能锁安装在门体上,智能锁包括:处理器;存储器,耦合至处理器;光传感器,耦合至处理器,光传感器位于门体的门外一侧,光传感器用于输出光强度值;以及计算机程序,其中计算机程序存储在存储器上,当计算机程序被处理器执行时,使得智能锁执行:在第一周期内检测到的触发事件的数量大于或等于第一预设值后,受到疑似攻击的数量加1;其中,受到疑似攻击的初始数量为0,首次受到疑似攻击时的疑似攻击的数量为所述初始数量加1,后续受到疑似攻击时的疑似攻击的数量为前一次疑似攻击的数量加1;获取预设时长内的多个光强度值;根据多个光强度值,确定受到攻击,开启保护模式。
采用本申请的智能锁,可以通过两级检测机制来确认智能锁受到电磁攻击(比如,高压电磁攻击),其中一级检测机制通过在第一周期内检测到触发事件的数量大于或等于第一预设值,认为智能锁受到疑似攻击;二级检测机制通过检测预设时长内的多个光强度值,确认智能锁受到电磁攻击(比如,高压电磁攻击),以使智能锁开启保护模式进行主动防护。
在一种可能的实现方式中,根据多个光强度值,确定受到攻击,包括:在检测到的任意两个相邻的光强度值的差值,大于或等于差值预设阈值后,记录第一数量值加1;其中,第一数量值的初始值为0,首次记录的第一数量值为初始值加1,后续记录的第一数量值为前一次的第一数量值加1;在第一数量值大于预设的数量值阈值后,确定受到攻击。基于这样的设计,可以通过判断任意两个相邻光强度值的差值来确认智能锁是否受到攻击。
在一种可能的实现方式中,在检测任意两个相邻的光强度值的差值之前,确定多个光强度值大于或等于预设阈值。基于这样的设计,可以确定多个光强度值大于或等于预设阈值作为检测任意两个相邻的光强度值的差值的条件。
在一种可能的实现方式中,根据多个光强度值,确定受到攻击,包括:在多个光强度值中的最大光强度值与最小光强度值的差值,大于或等于差值预设阈值后,确定受到攻击。基于这样的设计,可以通过判断多个光强度值中的最大光强度值与最小光强度值的差值来确认智能锁是否受到攻击。
在一种可能的实现方式中,在检测多个光强度值中的最大光强度值与最小光强度值的差值之前,确定多个光强度值大于或等于预设阈值。基于这样的设计,可以确定多个光强度值大于或等于预设阈值作为检测多个光强度值中的最大光强度值与最小光强度值的差值的条件。
第三方面,提供一种防护方法,应用于智能锁。智能锁安装于门体上,该方法包括:在第一周期内检测到的触发事件的数量大于或等于第一预设值后,受到疑似攻击的数量加1;其中,受到疑似攻击的初始数量为0,首次 受到疑似攻击时的疑似攻击的数量为初始数量加1,后续受到疑似攻击时的疑似攻击的数量为前一次疑似攻击的数量加1;获取第二周期内检测到的疑似攻击的数量;在第二周期内检测到的疑似攻击的数量大于或等于第二预设值后,开启保护模式。
在一种可能的实现方式中,智能锁还包括:光传感器,耦合至处理器,光传感器位于门体的门外一侧,光传感器用于输出光强度值。该方法还包括:获取预设时长内的多个光强度值;根据多个光强度值,确定受到攻击,开启保护模式。
在一种可能的实现方式中,该方法还包括:在开启保护模式之后,经过第三周期后,退出保护模式。
在一种可能的实现方式中,根据多个光强度值,确定受到攻击,包括:在检测到的任意两个相邻的光强度值的差值,大于或等于差值预设阈值后,记录第一数量值加1;其中,第一数量值的初始值为0,首次记录的第一数量值为初始值加1,后续记录的第一数量值为前一次的第一数量值加1;在第一数量值大于预设的数量值阈值后,确定受到攻击。
在一种可能的实现方式中,在检测任意两个相邻的光强度值的差值之前,确定多个光强度值大于或等于预设阈值。
在一种可能的实现方式中,根据多个光强度值,确定受到攻击,包括:在多个光强度值中的最大光强度值与最小光强度值的差值,大于或等于差值预设阈值后,确定受到攻击。
在一种可能的实现方式中,在检测多个光强度值中的最大光强度值与最小光强度值的差值之前,确定多个光强度值大于或等于预设阈值。
在一种可能的实现方式中,第二周期大于或等于第一周期;开启保护模式,包括以下的至少一种:不响应开锁指令,关闭智能锁的驱动单元,以及关闭智能锁的键盘、NFC模块、指纹模块或光传感器。
在一种可能的实现方式中,退出保护模式,包括以下的至少一种:响应开锁指令,开启智能锁的驱动单元,以及开启智能锁的键盘、NFC模块、指纹模块或光传感器。
在一种可能的实现方式中,预设时长的计时起点包括以下的一种:第一周期的计时起点、第一周期的计时终点,及在第一周期内首次检测到触发事件的时间点;触发事件的检测可通过智能锁的键盘、NFC模块、指纹模块来检测。
第四方面,提供一种防护方法,应用于智能锁。智能锁安装于门体上,智能锁包括:处理器;光传感器,耦合至处理器,光传感器位于门体的门外一侧,光传感器用于输出光强度值。该方法包括:在第一周期内检测到的触发事件的数量大于或等于第一预设值后,受到疑似攻击的数量加1;其中,受到疑似攻击的初始数量为0,首次受到疑似攻击时的疑似攻击的数量为初始数量加1,后续受到疑似攻击时的疑似攻击的数量为前一次疑似攻击的数量加1;获取预设时长内的多个光强度值;根据多个光强度值,确定受到攻 击,开启保护模式。
在一种可能的实现方式中,根据多个光强度值,确定受到攻击,包括:在检测到的任意两个相邻的光强度值的差值,大于或等于差值预设阈值后,记录第一数量值加1;其中,第一数量值的初始值为0,首次记录的第一数量值为初始值加1,后续记录的第一数量值为前一次的第一数量值加1;在第一数量值大于预设的数量值阈值后,确定受到攻击。
在一种可能的实现方式中,在检测任意两个相邻的光强度值的差值之前,确定多个光强度值大于或等于预设阈值。
在一种可能的实现方式中,根据多个光强度值,确定受到攻击,包括:在多个光强度值中的最大光强度值与最小光强度值的差值,大于或等于差值预设阈值后,确定受到攻击。
在一种可能的实现方式中,在检测多个光强度值中的最大光强度值与最小光强度值的差值之前,确定多个光强度值大于或等于预设阈值。
第五方面,提供一种计算机可读存储介质,包括计算机程序,当计算机程序在智能锁上运行时,使得智能锁执行第三方面以及第三方面任意一种实现方式,第四方面及第四方面任意一种实现方式的方法。
第六方面,提供一种计算机程序产品,当计算机程序产品在智能锁上运行时,使得智能锁第三方面以及第三方面任意一种实现方式,第四方面及第四方面任意一种实现方式的方法。
另外,第三方面至第六方面中任一种可能设计方式所带来的技术效果可参见智能锁相关中不同设计方式所带来的技术效果,此处不再赘述。
附图说明
图1是本申请一实施例提供的智能锁的应用场景图。
图2是本申请一实施例提供的智能锁的示意图。
图3是本申请一实施例提供的智能锁的软件结构框图。
图4是本申请一实施例提供的防护方法的流程图。
图5是本申请另一实施例提供的防护方法的流程图。
图6是本申请又一实施例提供的防护方法的流程图。
图7是本申请一实施例提供的智能锁的结构示意图。
主要元件符号说明
智能锁 100
门体 200
门外 201
门内 202
处理器 110
锁体 12
驱动单元 13
键盘 14
NFC模块 15
指纹模块 16
光传感器 17
电源管理单元 18
电池 19
充放电电路 20
USB接口 21
发光二极管LED 22
闪光模块 23
按键 24
蓝牙模块 25
无线通信模块 26
存储器 120
如下具体实施方式将结合上述附图进一步说明本申请。
具体实施方式
为使本申请实施例的目的、技术方案和优点更加清楚,下面将结合本申请实施例中的附图,对本申请实施例中的技术方案进行清楚、完整地描述。显然,所描述的实施例是本申请一部分实施例,而不是全部的实施例。基于本申请中的实施例,本领域普通技术人员在没有做出创造性劳动前提下所获得的所有其他实施例,都属于本申请保护的范围。
以下实施例中所使用的术语只是为了描述特定实施例的目的,而并非旨在作为对本申请的限制。如在本申请的说明书和所附权利要求书中所使用的那样,单数表达形式“一个”、“一种”、“所述”、“上述”、“该”和“这一”旨在也包括例如“一个或多个”这种表达形式,除非其上下文中明确地有相反指示。还应当理解,在本申请以下各实施例中,“至少一个”、“一个或多个”是指一个或两个以上(包含两个)。术语“和/或”,用于描述关联对象的关联关系,表示可以存在三种关系;例如,A和/或B,可以表示:单独存在A,同时存在A和B,单独存在B的情况,其中A、B可以是单数或者复数。字符“/”一般表示前后关联对象是一种“或”的关系。
在本说明书中描述的参考“一个实施例”或“一些实施例”等意味着在本申请的一个或多个实施例中包括结合该实施例描述的特定特征、结构或特点。由此,在本说明书中的不同之处出现的语句“在一个实施例中”、“在一些实施例中”、“在其他一些实施例中”、“在另外一些实施例中”等不是必然都参考相同的实施例,而是意味着“一个或多个但不是所有的实施例”,除非是以其他方式另外特别强调。术语“包括”、“包含”、“具有”及它们的变形都意味着“包括但不限于”,除非是以其他方式另外特别强调。术语“连接”包括直接连接和间接连接,除非另外说明。
以下,术语“第一”、“第二”仅用于描述目的,而不能理解为指示或暗示相对重要性或者隐含指明所指示的技术特征的数量。由此,限定有“第 一”、“第二”的特征可以明示或者隐含地包括一个或者更多个该特征。
在本申请实施例中,“示例性地”或者“例如”等词用于表示作例子、例证或说明。本申请实施例中被描述为“示例性地”或者“例如”的任何实施例或设计方案不应被解释为比其它实施例或设计方案更优选或更具优势。确切而言,使用“示例性地”或者“例如”等词旨在以具体方式呈现相关概念。
示例性地,图1为本申请一实施例提供的智能锁的应用场景示意图。在一些实施例中,智能锁可安装于门体200上,形成智能门锁,适用于智能家居。本申请的防护方法应用于智能锁中。
为了各实施例和实施方式的描述清楚简洁,给出相关技术的简要介绍:智能家居(smart home或home automation)是以住宅为平台,利用综合布线技术、网络通信技术、安全防范技术、自动控制技术、音视频技术将家居生活有关的设施集成,构建高效的住宅设施与家庭日程事务的管理系统,提升家居安全性、便利性、舒适性、艺术性,并实现环保节能的居住环境。
在一些实施例中,如图1所示,门体200的相对两侧可分别为门外201和门内202。示例性地,门外201一侧可为家居的外面,门内202一侧可为家居的里面。其中,键盘14、近场通信(Near Field Communication,NFC)模块15、指纹模块16、光传感器17等可装设于门体200面向门外201的表面,可供用户进行开锁操作及检测门外环境。处理器110、驱动单元13等可装设于门体200面向门内202的一侧,可以保护这些器件不直接受到门外的攻击或破坏,提高智能锁100的安全性。锁体12可装设于门体200的一侧面,方便伸出或收容于门体200,可以进行锁止及开启的状态切换。
示例性地,图2为本申请一实施例提供的智能锁的示意图。如图2所示,智能锁100可包括处理器110、锁体12、驱动单元13、键盘14、NFC模块15、指纹模块16及光传感器17。
在一些实施例中,处理器110可以包括但不限于一微控制单元(MicroController Unit,MCU)。处理器110上至少集成有存储器、微控制单元和计数器(timer)。可以理解,处理器110还可集成有各类型接口、模数转换器(Analog to Digital Converter,ADC)、通用异步收发传输器(Universal Asynchronous Receiver/Transmitter,UART)、可编程逻辑控制器(Programmable Logic Controller,PLC)、直接存储器访问(Direct Memory Access,DMA)等功能模块及电子元器件。
在一些实施例中,存储器用于存储程序代码和各种数据。存储器可以包括只读存储器(Read-Only Memory,ROM)、随机存储器(Random Access Memory,RAM)、可编程只读存储器(Programmable Read-Only Memory,PROM)、可擦除可编程只读存储器(Erasable Programmable Read-Only Memory,EPROM)、一次可编程只读存储器(One Time Programmable Read-Only Memory,OTPROM)、电子擦除式可复写只读存储器(Electrically-Erasable Programmable Read-Only Memory,EEPROM)、只读光盘(Compact Disc  Read-Only Memory,CD-ROM)或其他光盘存储器、磁盘存储器、磁带存储器、或者能够用于携带或存储数据的计算机可读的任何其他介质。
在一些实施例中,处理器110可以由集成电路组成。例如,处理器110可以由单个封装的集成电路所组成,也可以是由多个相同功能或不同功能封装的集成电路所组成。处理器110可以包括一个或者多个中央处理器(Central Processing Unit,CPU)、微控制单元、数字处理芯片、图形处理器及各种控制芯片的组合等。至少一个处理器是智能锁的控制核心(Control Core),通过运行或执行存储在存储器内的程序或者模块,以及调用存储在存储器内的数据,以执行智能锁的各种功能和处理数据,例如执行数据处理的功能。
上述以软件功能模块的形式实现的集成的单元,可以存储在一个计算机可读取存储介质中。上述软件功能模块存储在一个存储介质中,包括若干指令用以使得一台计算机设备(可以是个人计算机,终端,或者网络设备等)或处理器(processor)执行本申请各个实施例防护方法的部分。
存储器中存储有计算机程序,例如程序代码,且至少一个处理器可调用存储器中存储的程序代码以执行相关的功能。在本申请的一个实施例中,存储器存储多个指令,多个指令被至少一个处理器所执行以实现防护方法。
驱动单元13用于驱动锁体12锁止或开启门体200。在一些实施例中,驱动单元13可包括但不限于一电机,受控于处理器110,以驱动锁体12的物理运动,从而实现锁体12对门体200的锁止或开启。示例性地,驱动单元13包括马达。
键盘14可安装于门体200面向门外201的表面,用于检测用户的键入操作。在一些实施例中,键盘14可包括但不限于数字键盘,用于检测用户的键入指令,键入指令可以包括数字键盘对应的数字组合,以形成密码指令,用于开启锁体12。
NFC模块15可安装于门体200面向门外201的表面,用于检测NFC信号。在一些实施例中,NFC模块15可用于检测配对的NFC卡的NFC信号,配对的NFC卡的NFC信号可形成密码指令,用于开启锁体12。
指纹模块16可安装于门体200面向门外201的表面,用于检测按压指纹信号。在一些实施例中,指纹模块16可用于检测预先录入的指纹信号,指纹信号可形成密码指令,用于开启锁体12。
光传感器17可安装于门体200面向门外201的表面,用于检测门外201的光信号。在一些实施例中,光传感器17可用于检测环境光强度。
可以理解,智能锁100可通过键盘14检测按键输入数字组合、通过NFC模块15检测配对的NFC卡或通过指纹模块16检测预先录入的指纹信号的任一方式来形成开锁指令以开启锁体12。
在一些实施例中,如图2所示,智能锁100还可包括电源管理单元18、电池19、充放电电路20、USB接口21、LED 22、闪光模块23、按键24、蓝牙模块25及无线通信模块26。
在一些实施例中,电源管理单元18可包括电源管理单元(Power Management Unit,PMU)芯片,可用于在智能锁100中实现对电能的变换、分配、检测及其他电能管理的功能。电池19可为可重复充放电电池。电池19可通过电源管理单元18为智能锁100的各元器件及模块供电。充放电电路20可通过电源管理单元18为电池19进行充电。在一些实施方式中,充放电电路20可以包括充放电芯片或充放电管理芯片。USB接口21可连接外部设备,以实现智能锁100与外部设备进行数据及电源信号的交互。LED 22和闪光模块23可用于指示智能锁100的工作状态。按键24可用于但不限于更改智能锁100的工作状态。例如,通过按键24提供用户操作以增加锁体12的锁持状态,如二次锁持等。蓝牙模块25可用于与外部设备建立蓝牙连接,以实现基于蓝牙传输的数据交互。在一些实施例中,蓝牙模块25可包括但不限于低功耗蓝牙(或称蓝牙低功耗,Bluetooth Low Energy,BLE),具有低功耗的特性。无线通信模块26可用于与外部设备建立无线通信连接,以实现基于无线通信传输的数据交互。在一些实施例中,无线通信模块26可包括但不限于无线保真(Wireless Fidelity,Wi-Fi)芯片,可与外部设备建立无线通信连接,例如,Wi-Fi连接。
可以理解,智能锁100包括不限于上述的电子元器件及模块,在实施例示意的结构并不构成对智能锁100的具体限定。在一些实施例中,智能锁100还可包括其他必要的电子元器件、模块及电路等,可以包括比图示更多或更少的部件,或者组合某些部件,或者拆分某些部件,或者不同的部件布置,在此不作限定。图示的部件可以以硬件,软件或软件和硬件的组合实现。
示例性地,图3为本申请一实施例的智能锁100的软件结构框图。如图3所示,分层架构将软件分成若干个层,每一层都有清晰的角色和分工。层与层之间通过软件接口通信。在一些实施例中,将软件系统分为三层,从上至下分别为应用层、业务架构层和内核驱动层。
应用层可以包括攻击检测业务模块、双机通信模块、主动防护业务模块等。在一些实施例中,攻击检测业务模块可用于检测及判断智能锁100所受到的电磁攻击(比如,高压电磁攻击)。主动防护业务模块可用于获取攻击检测业务模块检测到的电磁攻击(比如,高压电磁攻击)时,控制智能锁100进入保护模式,关闭相关外设器件。例如,对驱动单元13、键盘14、NFC模块15、指纹模块16及光传感器17等下电,以保护智能锁100及相关器件。双机通信模块可用于与外部设备建立通信连接并实现通信功能。
业务框架层为应用层的业务模块提供应用编程接口(Application Programming Interface,API)和编程框架。业务框架层包括一些预先定义的函数。如图3所示,业务框架层可以包括互联框架、传感框架、驱动框架及业务子系统等,业务子系统可以包括指纹识别子系统、电池管理子系统及门锁控制子系统等。驱动框架可用于给应用层提供外设器件(例如键盘14、NFC模块15、指纹模块16、光传感器17等)控制接口,对外设器件驱动上报的中断进行响应,并对中断数据进行处理解析,上报至应用层的对应的业 务模块。例如,攻击检测业务模块和主动防护业务模块等。互联框架可用于给应用层业务模块(例如双机通信模块)提供控制接口,并响应及处理对应业务模块的数据。传感框架可用于响应及处理对应外设器件(例如,NFC模块15和光传感器17等)的数据并上报至应用层的对应的业务模块,例如,攻击检测业务模块和主动防护业务模块等。
指纹识别子系统可用于响应及处理对应外设器件(例如,指纹模块16)的数据并上报至应用层的对应的业务模块,例如,攻击检测业务模块和主动防护业务模块等。门锁控制子系统可用于响应及处理对应外设器件(例如,驱动单元13)的数据并上报至应用层的对应的业务模块。例如,攻击检测业务模块和主动防护业务模块等。电池管理子系统可用于响应及处理对应外设器件(例如,电源管理单元18)的数据并上报至应用层的对应的业务模块例如,攻击检测业务模块和主动防护业务模块等。
内核层是硬件和软件之间的层。内核层至少包括指纹传感器驱动,光传感器驱动,马达驱动,NFC驱动、按键驱动、蓝牙驱动等。指纹传感器驱动可对应驱动及控制指纹模块16。光传感器驱动可对应驱动及控制光传感器17。马达驱动可对应驱动及控制驱动单元13。NFC驱动可对应驱动及控制NFC模块15。按键驱动可对应驱动及控制键盘14。蓝牙驱动可对应驱动及控制蓝牙模块25。在一些实施例中,当蓝牙模块25包括低功耗蓝牙(BLE)时,蓝牙驱动可包括对应BLE驱动,可对应驱动及控制BLE。
示例性地,图4为本申请实施例提供的防护方法的流程图。其中,防护方法应用于智能锁100中。示例性地,防护方法可以包括以下步骤:
S411、检测到触发事件。
可选地,键盘14、NFC模块15和指纹模块16分别检测触发事件。在一些实施例中,键盘14检测到按键中断信号时可判断为按键触发事件;NFC模块15检测到NFC信号时可判断为NFC触发事件;指纹模块16检测到触摸指纹信号时可判断为指纹触发事件。
S412、判断第一周期T1内检测到的触发事件数是否大于或等于第一预设值N1。
在一些实施例中,键盘14、NFC模块15和指纹模块16可分别将各自检测到的触发事件发送到处理器110。示例性地,第一周期T1可为30毫秒,第一预设值N1可为3。具体地,处理器110判断第一周期T1内键盘14、NFC模块15和指纹模块16检测到的触发事件数累计是否大于或等于第一预设值N1。
在一些实施例中,在第一周期T1内,键盘14检测到一次按键触发事件,NFC模块15检测到一次NFC触发事件,且指纹模块16检测到一次指纹触发事件,则处理器110判断第一周期T1内检测到的触发事件数为三次,从而满足大于或等于第一预设值N1的条件。
在一些实施例中,在第一周期T1内,键盘14检测到两次按键触发事件,且NFC模块15检测到一次NFC触发事件,则处理器110判断第一周期T1内 检测到的触发事件数为三次,从而满足大于或等于第一预设值N1的条件。
当判断第一周期T1内检测到的触发事件数大于或等于第一预设值N1时,执行S413;否则,返回执行S411。
S413、受到疑似攻击。
可选地,智能锁100(具体可为处理器110)根据上述判断条件,认为智能锁100受到疑似攻击(比如,存在一个疑似攻击事件)。在一些实施例中,疑似攻击可以包括但不限于电磁波攻击。
可选地,智能锁100可以通过键盘14、NFC模块15和指纹模块16中的至少一种方式来采集输入的密码指令,用于解锁的比对验证。可选地,第一周期T1可以设置为一个相对短的时间周期(比如,30毫秒);而一般来说,用户在正常的解锁输入时,对键盘14、NFC模块15和指纹模块16中的至少一个的操作时长(比如,1秒或几秒),会大于第一周期T1;这样,就可以有效地将疑似攻击与用户的正常解锁输入区分开来,减少甚至不会出现误识别的情形,从而避免或减少不必要的处理。示例性地,用户对键盘14的密码输入操作时长一般为5秒,大于第一周期T1(如30毫秒)。此外,假设解锁密码总共有M位,在用户正常输入密码解锁中,输入第i个密码位和第(i+1)个密码位的时间间隔(i为大于或等于1,且小于或等于M的任意数字),一般会大于第一周期T1。因此,也不会出现在用户正常的解锁输入中,被智能锁100误识别为疑似攻击的情形。另外,若是在第一周期T1(比如,30毫秒)内,智能锁100连续检测到多次(如三次及以上)的触发事件,则智能锁100认为受到疑似攻击,例如,受到疑似电磁波攻击等。总之,智能锁100可以准确地识别区分出疑似攻击和正常解锁输入。
示例性地,S413为可选的步骤,有关执行S413可被替换为执行S414和S415。
S414、第二周期T2内受到的疑似攻击数是否大于或等于第二预设值N2。
可选地,在一些实施例中,第二周期T2可以设置为1秒,第二预设值N2可以设置为2。第二周期T2可以设置为其他的时长。第二预设值N2可以设置为其他的数值。本申请不作限制。
可以理解的是,若在第二周期T2(如1秒)内检测到的疑似攻击数为两次以上,则智能锁认为受到非法攻击,需要对智能锁进行保护。当智能锁判断第二周期T2内检测到的疑似攻击事件数大于或等于第二预设值N2时,则执行S417。否则,返回执行S411。
可选地,第二周期大于、小于或等于第一周期。
可选地,第二预设值大于、小于或等于第一预设值。
S415、获取当前预设时长内的多个光强度值。
示例性地,通过光传感器17在预设时长(比如,0.5秒)内,获取门外201一侧当前环境光的光强度值,并传送至处理器110。在S413之后,或在S412之后,同步或者同时执行S414和S415,两条分支同步或同时进行进一步的检测。
可选地,预设时长可以由用户设置或调整,也可由厂商在出厂前设置,也可由厂商在升级软件时更新设置。
示例性地,当前预设时长的计时起点可以为第一周期的计时起点,也可以为第一周期的计时终点,还可以为在第一周期内首次检测到触发事件的时间点。本申请对此不做限定。
S416、多个光强度值的变化幅度是否超过预设阈值。
示例性地,智能锁100(或者处理器110)可判断多个光强度值的变化幅度(比如,最大光强度值与最小光强度值之间的变化幅度),是否大于或等于预设阈值L1。在一些实施例中,预设阈值L1为预设的光强度阈值。
示例性地,智能锁100可判断检测到的任意两个相邻光强度值的变化幅度,是否大于或等于差值预设阈值L2,以此判断多个光强度值的变化幅度。
在一些实施例中,光传感器17在预设时长内,连续检测多个光强度值(例如,五个光强度值)。若智能锁100(或者处理器110)判断检测到的任意两个相邻的光强度值的差值,是否大于或等于差值预设阈值L2;若有一个大于或等于,则记录第一数量值加1,其中第一数量值的初始值为0,首次记录的第一数量值为所述初始值加1,后续记录的第一数量值为前一次的第一数量值加1;若有一半(可称为预设的数量值阈值)以上的差值大于或等于差值预设阈值L2,则智能锁100(或者处理器110)判断多个光强度值的变化幅度超过预设阈值,并确认智能锁100受到非法攻击(比如,高压电磁攻击)。
例如,在预设时长内,连续检测5个光强度值,可称为第一光强度值、第二光强度值、第三光强度值、第四光强度值和第五光强度值;相邻光强度值的差值共有4个,可称为第一光强度值与第二光强度值的第一差值、第二光强度值与第三光强度值的第二差值、第三光强度值与第四光强度值的第三差值,以及第四光强度值与第五光强度值的第四差值。其中,4个相邻光强度值的差值(即第一差值、第二差值、第三差值,以及第四差值),其中若有两个以上的差值(尤其是相邻的差值,比如,第一差值和第二差值)大于或等于差值预设阈值L2,则智能锁100(或者处理器110)认为智能锁100受到电磁攻击(比如,高压电磁攻击)。通常遭受到电磁攻击(比如,电棍发起的高压电磁攻击)会产生闪光。示例性地,多次闪光通常产生多个波动的光强度值,多次闪光以一强一弱的光强度值的状态波动,但多个光强度值均可大于或等于预设阈值L1,且相邻两个光强度值差值会大于或等于差值预设阈值L2(比如,第一差值大于或等于差值预设阈值L2)。
可选地,在智能锁检测任意两个相邻的光强度值的差值,是否大于或等于差值预设阈值L2之前,智能锁100还可先检测到多个光强度值大于或等于预设阈值L1。
因此,在一些实施例中,当智能锁100(或者处理器110)检测到的任意两个相邻光强度值的差值中有一半以上的差值大于或等于差值预设阈值L2时,则智能锁(或者处理器110)可判断多个光强度值的变化幅度超过预 设阈值,并确认智能锁100受到电磁攻击(比如,高压电磁攻击)。可以理解的是,当判断检测到的任意两个相邻光强度值的差值中有一半以上的差值小于差值预设阈值L2时,则智能锁100(或者处理器110)判断多个光强度值的变化幅度不超过预设阈值,并认为没有受到电磁攻击(比如,没有受到高压电磁攻击)。例如,在强光一直照射智能锁100的场景下,强光直射智能锁100的情况通常不会出现连续波动的光强度值。
在一些实施例中,光传感器17连续检测多个光强度值(例如,5个光强度值),智能锁100(或者处理器110)判断多个光强度值中的最大光强度值与最小光强度值的差值(比如,第一光强度值为最大光强度值,第三光强度值为最小光强度值,则判断第一光强度值与第三光强度值的差值),是否大于或等于差值预设阈值L2。若差值大于或等于差值预设阈值L2,则智能锁100(或者处理器110)判断多个光强度值的变化幅度超过预设阈值,并认为智能锁100受到电磁攻击(比如,高压电磁攻击)。若差值小于差值预设阈值L2,则智能锁100(或者处理器110)判断多个光强度值的变化幅度不超过预设阈值,并认为智能锁100认为没有受到电磁攻击(比如,没有受到高压电磁攻击)。
当检测到的多个光强度值的变化幅度超过预设阈值,则执行S417;否则执行S414。
可选地,在智能锁判断多个光强度值中的最大光强度值与最小光强度值的差值,是否大于或等于差值预设阈值L2之前,智能锁100还可先检测到多个光强度值大于或等于预设阈值L1。
S417、开启保护模式,并开启第三周期T3计时。
具体来说,智能锁100(或者处理器110)开启保护模式,并开启第三周期T3计时。
在一些实施例中,开启保护模式包括:关闭驱动单元13,以防止电磁攻击(比如,高压电磁攻击)导致的干扰信号误触发驱动单元13开启锁体12。
进一步地,开启保护模式还包括:可关闭键盘14、NFC模块15、指纹模块16及光传感器17等处理器的外设器件,以防止外设器件损坏。
进一步地,开启保护模式还包括:处理器110可不响应任何密码指令,不响应键盘14、NFC模块15、指纹模块16及光传感器17的检测信号,也即处理器110不响应开锁指令。
在一些实施例中,关闭键盘14、NFC模块15、指纹模块16及光传感器17,可以为断开对键盘14、NFC模块15、指纹模块16及光传感器17的供电。
在一些实施例中,第三周期T3可以包括3秒、5秒等时长的一种。第三周期T3还可为其他任意时长,本申请对此不作限制。
可选地,计时的方式可以替换,不采用第三周期倒计时的方式,而是采用正计时的方式(比如,从0开始计时)。
S418、第三周期T3是否结束。
若第三周期T3计时未结束,则继续执行S418,仍保持保护模式状态; 若第三周期T3计时结束,则执行S419。
可选地,在S417中“开启第三周期T3计时”被替换为“开启计时”,即“倒计时”方式被替换为“正计时”方式,则需比较计时的时长是否大于或等于第三周期。在计时的时长大于或等于第三周期后,执行S419;否则,继续执行S418。
S419、退出保护模式,智能锁100恢复正常工作。
智能锁100(或者处理器110)退出保护模式,智能锁100恢复正常工作,可重新返回执行S411。在一些实施例中,退出保护模式后,键盘14、NFC模块15、指纹模块16及光传感器17恢复供电,重新开启驱动单元13,处理器110恢复响应密码指令及检测信号。
本申请实施例的防护方法,通过两级检测机制来确认智能锁100受到电磁攻击(比如,高压电磁攻击),其中一级检测机制通过在第一周期内检测到触发事件(比如,触发事件包括按键触发事件、NFC触发事件和指纹触发事件中的至少一种)的数量大于或等于第一预设值,认为受到疑似攻击;二级检测机制通过在一级检测机制检测到疑似攻击时的预设时长内,获取多个光强度值并检测多个光强度值的变化幅度超过预设阈值,确认智能锁100受到电磁攻击(比如,高压电磁攻击)。在确认受到电磁攻击后,智能锁100(或者处理器110)进入保护模式进行主动防护,不响应外部中断,防止误开锁,同时保护各外设器件不受损害,从而极大地提升了智能锁100的安全系数。
需要说明的是,上述二级检测机制仅为示例性地,并非用于限制本申请的范围。比如,还可以通过三级检测机制、四级检测机制等更多的检测机制。
需要说明的是,图4所示的流程图中的步骤顺序可以改变,S413为可选的步骤,可以省略,有关执行S413可被替换为执行S414和S415。在S413之后,或在S412之后,同步或者同时执行S414和S415,两条分支同步或同时进行进一步的检测,或者可单独执行S415,仅进行一条分支进行进一步的检测,此时S414为可选的步骤,可以省略。
示例性地,图5示出了本申请另一实施例的防护方法的一种可能的流程图。其中,防护方法应用于智能锁100。示例性地,防护方法可以包括以下步骤:
S511、第一周期T1内检测到的触发事件数是否大于或等于第一预设值N1。
在一些实施例中,键盘14、NFC模块15和指纹模块16分别检测触发事件并发送到处理器110,处理器110判断第一周期内T1内检测的触发事件数是否大于或等于第一预设值N1。在一些实施例中,S511的实现过程可参考前述S411及S412。当第一周期T1内检测到的触发事件数大于或等于第一预设值N1时,执行S512;否则,返回执行S511。
S512、获取门外201一侧的多个光强度值,并判断多个光强度值的变化幅度是否超过预设阈值。
在一些实施例中,光传感器17位于门外一侧,在预设时长内,光传感器17连续检测门外201一侧的多个光强度值,并判断多个光强度值的变化幅度是否超过预设阈值。
在一些实施例中,光传感器17中部分位于门外一侧,部分位于门内一侧。在预设时长内,位于门外一侧的光传感器17连续监测门外201一侧的多个光强度值,并判断多个光强度值的变化幅度是否超过预设阈值。
在一些实施例中,S512的实现过程可参考前述S415及S416。
当判断多个光强度值的变化幅度超过预设阈值时,执行S513;否则,返回执行S511。
S513、对智能锁100开启保护模式。
在一些实施例中,智能锁100(或者处理器110)对智能锁100开启保护模式。在一些实施例中,S513的实现过程可参考前述S417。
本申请的实施例的防护方法,通过针对电磁攻击(比如,高压电磁攻击)的主动防护机制,使得智能锁100有效地检测电磁攻击(比如,高压电磁攻击),并针对性地进行防护,提高了智能锁100的安全性。
示例性地,图6示出了本申请又一实施例的防护方法的一种可能的流程图。其中,防护方法应用于智能锁100中。示例性地,防护方法可以包括以下步骤:
S611,第一周期T1内检测到的触发事件数是否大于或等于第一预设值N1。
在一些实施例中,键盘14、NFC模块15和指纹模块16分别检测触发事件并发送到处理器110,处理器110判断第一周期内T1内检测的触发事件数是否大于或等于第一预设值N1。在一些实施例中,S611的实现过程可参考前述S411及S412。当第一周期T1内检测到的触发事件数大于或等于第一预设值N1时,同步或者同时执行S612及S613,两条分支同步或同时进行进一步的检测;否则,返回执行S611。
S612,获取门外一侧的多个光强度值并判断多个光强度值的变化幅度是否超过预设值。
在一些实施例中,光传感器17连续检测门外201一侧的多个光强度值并判断多个光强度值的变化幅度是否超过预设值。在一些实施例中,S612的实现过程可参考前述S415及S416。
当判断多个光强度值的变化幅度超过预设阈值时,执行S614;否则,执行S613。
S613,判断第二周期T2内检测的疑似攻击事件数是否大于或等于第二预设值N2。
在一些实施例中,处理器110判断第二周期T2内检测的疑似攻击事件数是否大于或等于第二预设值N2。在一些实施例中,S613的实现过程可参考前述S414。
当判断第二周期T2内检测的疑似攻击事件数大于或等于第二预设值N2 时,执行S614;否则返回执行S611。
S614,对智能锁100开启保护模式并判断第三周期T3是否结束。
在一些实施例中,处理器110对智能锁100开启保护模式并开启第三周期T3计时。在一些实施例中,S614的实现过程可参考前述S417及S418。
当判断第三周期T3结束时,执行S615;否则返回继续执行S614。
可替换地,可以采取“倒计时”的方式,也可以采取“正计时”的方式。
S615,退出保护模式,智能锁100恢复正常工作。
在一些实施例中,处理器110结束保护模式,智能锁100恢复正常工作,可重新返回执行S611。在一些实施例中,S615的实现过程可参考前述S419。
需要说明的是,图6所示的流程图中的步骤顺序可以改变。
在S611之后,同步或者同时执行S612和S613,两条分支同步或同时进行进一步的检测。或者,可单独执行S612,仅进行一条分支进行进一步的检测,此时S613为可选的步骤,可以省略,也可以保留。在省略S613的情形下,在S612之后,在S612的判断结果为否时,执行S611,在S612的判断结果为是时,执行614。在保留S613的情形下,在S612之后,在S612的判断结果为否时,执行S613,在S612的判断结果为是时,执行S614。
本申请的实施例的防护方法,通过检测智能锁100受到电磁攻击(比如,高压电磁攻击)时触发事件的变化特征作为一级检测,并检测攻击时的光照强度变化幅度作为二级检测,以判断智能锁100是否受到电磁攻击(比如,高压电磁攻击)。在判断受到电磁攻击(比如,高压电磁攻击)时,控制智能锁100进入保护模式进行主动防护,不响应外部中断,防止误开锁,同时保护各外设器件不受损害,从而极大地提升了智能锁100的安全系数。
需要说明的是,本申请的上述各个实施例的任意步骤、任意技术特征,均可以自由地、任意地组合。组合后的技术方案,也在本申请的范围之内。
可以理解的是,上述电子设备为了实现上述功能,其包含了执行各个功能相应的硬件结构和/或软件模块。本领域技术人员应该很容易意识到,结合本文中所公开的实施例描述的各示例的单元及算法步骤,本申请实施例能够以硬件或硬件和计算机软件的结合形式来实现。某个功能究竟以硬件还是计算机软件驱动硬件的方式来执行,取决于技术方案的特定应用和设计约束条件。本领域技术人员可以对每个特定的应用来使用不同方法来实现所描述的功能,但是这种实现不应认为超出本申请实施例的范围。
本申请实施例可以根据上述方法示例对上述电子设备进行功能模块的划分,例如,可以对应各个功能划分各个功能模块,也可以将两个或两个以上的功能集成在一个处理模块中。上述集成的模块既可以采用硬件的形式实现,也可以采用软件功能模块的形式实现。需要说明的是,本申请实施例中对模块的划分是示意性的,仅仅为一种逻辑功能划分,实际实现时可以有另外的划分方式。
本申请实施例的技术方案不仅可以通过光传感器,获取光强度值,来进行后续的光强度值变化幅度的判断条件或判断条件之一,还可以通过其他的 传感器来进行判断。本申请对于传感器的具体类型不作限定。
在一种示例中,图7示出了上述实施例中所涉及的智能锁的一种可能的结构示意图。如图7所示,智能锁100包括:处理器110和存储器120。其中,处理器110与存储器120耦合,本申请实施例中的耦合可以是通信连接,可以是电性,或其它的形式。具体地,存储器120用于存储计算机程序。处理器110用于调用存储器120中存储的计算机程序,使得智能锁100执行本申请实施例提供的方法中由智能锁所执行的步骤。相关流程可以参照上文,此处不再赘述。
在一些实施例中,智能锁100还可以包括显示屏;在显示屏具有触摸功能时,显示屏又称为触摸显示屏。在触摸显示屏上的操作可以通过虚拟按键实现。在显示屏不具有触摸功能时,显示屏又称为非触摸显示屏。在非触摸显示屏上的操作可以通过物理按键实现。
本申请提供一种计算机程序产品,当所述计算机程序产品在智能锁上运行时,使得智能锁执行本申请实施例提供的防护方法中由智能锁所执行的步骤。
本申请提供一种计算机可读存储介质,包括计算机程序,当计算机程序在智能锁上运行时,使得智能锁执行本申请实施例提供的防护方法中由智能锁所执行的步骤。
可选地,智能锁100可以不包括显示屏。
所属技术领域的技术人员可以清楚地了解到本申请实施例可以用硬件实现,或硬件与软件的方式实现。当使用硬件与软件实现,可以将上述功能存储在计算机可读介质中。基于这样的理解,本申请实施例的技术方案本质上或者说对现有技术做出贡献的部分或者该技术方案的全部或部分可以以软件产品的形式体现出来,该计算机软件产品存储在一个存储介质中,包括若干计算机程序用以使得一台计算机设备(可以是个人计算机,服务器,或者网络设备等)或处理器执行本申请各个实施例所述方法的全部或部分步骤。而前述的存储介质包括:快闪存储器、移动硬盘、只读存储器、随机存取存储器、磁碟或者光盘等各种可以存储程序代码的介质。
以上所述,仅为本申请实施例的具体实施方式,但本申请实施例的保护范围并不局限于此,任何在本申请实施例揭露的技术范围内的变化或替换,都应涵盖在本申请实施例的保护范围之内。因此,本申请实施例的保护范围应以本申请权利要求的保护范围为准。

Claims (20)

  1. 一种智能锁,所述智能锁安装在门体上,其特征在于,所述智能锁包括:
    处理器;
    存储器,耦合至所述处理器;
    以及计算机程序,其中所述计算机程序存储在所述存储器上,当所述计算机程序被所述处理器执行时,使得所述智能锁执行:
    在第一周期内检测到的触发事件的数量大于或等于第一预设值后,受到疑似攻击的数量加1;其中,受到疑似攻击的初始数量为0,首次受到疑似攻击时的疑似攻击的数量为所述初始数量加1,后续受到疑似攻击时的疑似攻击的数量为前一次疑似攻击的数量加1;
    获取第二周期内检测到的疑似攻击的数量;
    在所述第二周期内检测到的疑似攻击的数量大于或等于第二预设值后,开启保护模式。
  2. 根据权利要求1所述的智能锁,其特征在于,所述智能锁还包括:
    光传感器,耦合至所述处理器,所述光传感器位于所述门体的门外一侧,所述光传感器用于输出光强度值;
    所述智能锁还执行:
    获取预设时长内的多个光强度值;
    根据所述多个光强度值,确定受到攻击,开启所述保护模式。
  3. 根据权利要求1或2所述的智能锁,其特征在于,所述智能锁还执行:
    在开启所述保护模式之后,经过第三周期后,退出所述保护模式。
  4. 根据权利要求1-3中任意一项所述的智能锁,其特征在于,
    根据所述多个光强度值,确定受到攻击,包括:
    在检测到的任意两个相邻的光强度值的差值,大于或等于差值预设阈值后,记录第一数量值加1;其中,第一数量值的初始值为0,首次记录的第一数量值为所述初始值加1,后续记录的第一数量值为前一次的第一数量值加1;
    在所述第一数量值大于预设的数量值阈值后,确定受到攻击。
  5. 根据权利要求4所述的智能锁,其特征在于,
    在检测任意两个相邻的光强度值的差值之前,确定所述多个光强度值大于或等于预设阈值。
  6. 根据权利要求1-3中任意一项所述的智能锁,其特征在于,
    根据所述多个光强度值,确定受到攻击,包括:
    在所述多个光强度值中的最大光强度值与最小光强度值的差值,大于或等于差值预设阈值后,确定受到攻击。
  7. 根据权利要求6所述的智能锁,其特征在于,
    在检测所述多个光强度值中的最大光强度值与最小光强度值的差值之前,确定所述多个光强度值大于或等于预设阈值。
  8. 根据权利要求1-7中任意一项所述的智能锁,其特征在于,
    所述第二周期大于或等于所述第一周期;
    开启所述保护模式,包括以下的至少一种:不响应开锁指令,关闭所述智能锁的驱动单元,以及关闭所述智能锁的键盘、NFC模块、指纹模块或光传感器。
  9. 根据权利要求8所述的智能锁,其特征在于,
    退出所述保护模式,包括以下的至少一种:响应开锁指令,开启所述智能锁的驱动单元,以及开启所述智能锁的键盘、NFC模块、指纹模块或光传感器。
  10. 根据权利要求1-9中任意一项所述的智能锁,其特征在于,
    所述预设时长的计时起点包括以下的一种:所述第一周期的计时起点、所述第一周期的计时终点,及在所述第一周期内首次检测到触发事件的时间点;
    所述触发事件的检测可通过所述智能锁的键盘、NFC模块、指纹模块来检测。
  11. 一种智能锁,所述智能锁安装在门体上,其特征在于,所述智能锁包括:
    处理器;
    存储器,耦合至所述处理器;
    光传感器,耦合至所述处理器,所述光传感器位于所述门体的门外一侧,所述光传感器用于输出光强度值;
    以及计算机程序,其中所述计算机程序存储在所述存储器上,当所述计算机程序被所述处理器执行时,使得所述智能锁执行:
    在第一周期内检测到的触发事件的数量大于或等于第一预设值后,受到疑似攻击的数量加1;其中,受到疑似攻击的初始数量为0,首次受到疑似攻击时的疑似攻击的数量为所述初始数量加1,后续受到疑似攻击时的疑似攻击的数量为前一次疑似攻击的数量加1;
    获取预设时长内的多个光强度值;
    根据所述多个光强度值,确定受到攻击,开启所述保护模式。
  12. 根据权利要求11所述的智能锁,其特征在于,
    根据所述多个光强度值,确定受到攻击,包括:
    在检测到的任意两个相邻的光强度值的差值,大于或等于差值预设阈值后,记录第一数量值加1;其中,第一数量值的初始值为0,首次记录的第一数量值为所述初始值加1,后续记录的第一数量值为前一次的第一数量值加1;
    在所述第一数量值大于预设的数量值阈值后,确定受到攻击。
  13. 根据权利要求11所述的智能锁,其特征在于,
    根据所述多个光强度值,确定受到攻击,包括:
    在所述多个光强度值中的最大光强度值与最小光强度值的差值,大于或等于差值预设阈值后,确定受到攻击。
  14. 一种防护方法,应用于智能锁;其特征在于,所述智能锁安装于门体上,所述方法包括:
    在第一周期内检测到的触发事件的数量大于或等于第一预设值后,受到疑似攻击的数量加1;其中,受到疑似攻击的初始数量为0,首次受到疑似攻击时的疑似攻击的数量为所述初始数量加1,后续受到疑似攻击时的疑似攻击的数量 为前一次疑似攻击的数量加1;
    获取第二周期内检测到的疑似攻击的数量;
    在所述第二周期内检测到的疑似攻击的数量大于或等于第二预设值后,开启保护模式。
  15. 根据权利要求14所述的方法,其特征在于,所述智能锁还包括:光传感器,耦合至所述处理器,所述光传感器位于所述门体的门外一侧,所述光传感器用于输出光强度值;
    所述方法还包括:
    获取预设时长内的多个光强度值;
    根据所述多个光强度值,确定受到攻击,开启所述保护模式。
  16. 根据权利要求14或15所述的方法,其特征在于,
    根据所述多个光强度值,确定受到攻击,包括:
    在检测到的任意两个相邻的光强度值的差值,大于或等于差值预设阈值后,记录第一数量值加1;其中,第一数量值的初始值为0,首次记录的第一数量值为所述初始值加1,后续记录的第一数量值为前一次的第一数量值加1;
    在所述第一数量值大于预设的数量值阈值后,确定受到攻击。
  17. 根据权利要求14或15所述的方法,其特征在于,
    根据所述多个光强度值,确定受到攻击,包括:
    在所述多个光强度值中的最大光强度值与最小光强度值的差值,大于或等于差值预设阈值后,确定受到攻击。
  18. 一种防护方法,应用于智能锁;其特征在于,所述智能锁安装于门体上,所述智能锁包括:处理器;光传感器,耦合至所述处理器,所述光传感器位于所述门体的门外一侧,所述光传感器用于输出光强度值;所述方法包括:
    在第一周期内检测到的触发事件的数量大于或等于第一预设值后,受到疑似攻击的数量加1;其中,受到疑似攻击的初始数量为0,首次受到疑似攻击时的疑似攻击的数量为所述初始数量加1,后续受到疑似攻击时的疑似攻击的数量为前一次疑似攻击的数量加1;
    获取预设时长内的多个光强度值;
    根据所述多个光强度值,确定受到攻击,开启所述保护模式。
  19. 一种计算机可读存储介质,其特征在于,所述计算机可读存储介质包括计算机程序,当所述计算机程序在智能锁上运行时,使得所述智能锁执行如权利要求14-18中任意一项所述的方法。
  20. 一种计算机程序产品,其特征在于,当所述计算机程序产品在智能锁上运行时,使得所述智能锁执行如权利要求14-18中任意一项所述的方法。
PCT/CN2022/111507 2021-09-06 2022-08-10 防护方法、智能锁及计算机可读存储介质 WO2023029920A1 (zh)

Priority Applications (1)

Application Number Priority Date Filing Date Title
EP22863061.2A EP4379683A1 (en) 2021-09-06 2022-08-10 Protection method, smart lock, and computer readable storage medium

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
CN202111039095.4A CN115775419A (zh) 2021-09-06 2021-09-06 防护方法、智能锁及计算机可读存储介质
CN202111039095.4 2021-09-06

Publications (1)

Publication Number Publication Date
WO2023029920A1 true WO2023029920A1 (zh) 2023-03-09

Family

ID=85387463

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2022/111507 WO2023029920A1 (zh) 2021-09-06 2022-08-10 防护方法、智能锁及计算机可读存储介质

Country Status (3)

Country Link
EP (1) EP4379683A1 (zh)
CN (1) CN115775419A (zh)
WO (1) WO2023029920A1 (zh)

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
EP2282279A1 (en) * 2009-07-20 2011-02-09 Nxp B.V. Method and device for detection of light attacks
CN102473209A (zh) * 2009-06-29 2012-05-23 维亚塞斯公司 攻击企图的检测方法、记录媒介与应用此方法的安全处理器
CN204833287U (zh) * 2015-07-10 2015-12-02 崔娜 一种信息安全计算机
CN109214173A (zh) * 2017-06-29 2019-01-15 国民技术股份有限公司 安全设备及其抗攻击方法
CN113052128A (zh) * 2021-04-15 2021-06-29 多玛凯拔科技有限公司 一种智能锁抗干扰方法及系统

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102473209A (zh) * 2009-06-29 2012-05-23 维亚塞斯公司 攻击企图的检测方法、记录媒介与应用此方法的安全处理器
EP2282279A1 (en) * 2009-07-20 2011-02-09 Nxp B.V. Method and device for detection of light attacks
CN204833287U (zh) * 2015-07-10 2015-12-02 崔娜 一种信息安全计算机
CN109214173A (zh) * 2017-06-29 2019-01-15 国民技术股份有限公司 安全设备及其抗攻击方法
CN113052128A (zh) * 2021-04-15 2021-06-29 多玛凯拔科技有限公司 一种智能锁抗干扰方法及系统

Also Published As

Publication number Publication date
CN115775419A (zh) 2023-03-10
EP4379683A1 (en) 2024-06-05

Similar Documents

Publication Publication Date Title
EP3144835B1 (en) Fingerprint recognition-based terminal and method and system for logging in to same in stand-by state
CA2723647C (en) Remote control device with password functions
US20100026487A1 (en) Security system control panel
CN106250747B (zh) 一种信息处理方法及电子设备
TW201640258A (zh) 使用者認證裝置
CN108292336B (zh) 一种指纹采集方法及终端
WO2018165942A1 (zh) 终端设备和识别指纹的方法
CN104462907A (zh) 解锁控制方法和装置、电子设备
CN105045477A (zh) 一种终端解锁方法及终端
CN102638342A (zh) 一种基于振动频率的密码验证方法及装置
CN106780874A (zh) 一种智能门禁系统
WO2023029920A1 (zh) 防护方法、智能锁及计算机可读存储介质
CN204480367U (zh) 一种基于无线网络双向通讯的电子智能锁系统
US9779567B1 (en) Door lock using a mobile device as an input interface
CN105208235A (zh) 一种基于重力加速的汽车加解锁方法、系统及移动终端
US20210110016A1 (en) System and method for authenticating before waking an information handling system
CN207976936U (zh) 一种新型门禁控制系统
CN106506843A (zh) 一种防盗方法和移动终端
CN114201739A (zh) 一种基于指纹的电子设备开机方法和装置
CN210377589U (zh) 一种可通过电子密钥开启的智能锁
CN114049705A (zh) 基于手机软件与物联网通信的智能家居监控方法、系统
TWI430133B (zh) 生物感測啟動裝置、生物特徵感測控制之啟動管理系統及其方法
CN215867891U (zh) 指纹模组、电子设备和车辆
KR101114559B1 (ko) 디지털 도어락 시스템에서의 방범 모드 설정장치 및 그 방법
KR20130017468A (ko) 도어의 잠금 상태 해제방법

Legal Events

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

Ref document number: 22863061

Country of ref document: EP

Kind code of ref document: A1

WWE Wipo information: entry into national phase

Ref document number: 2022863061

Country of ref document: EP

ENP Entry into the national phase

Ref document number: 2022863061

Country of ref document: EP

Effective date: 20240228

NENP Non-entry into the national phase

Ref country code: DE