Electronic lock dynamic risk self-adaptive lock control method based on AI
By analyzing the power supply waveform and vibration spectrum of the electronic lock, differentiating mechanical vibration scenarios and constructing a migration probability map, the problem of lag in the response of traditional electronic locks to mechanical vibration attacks is solved, achieving adaptive lock control protection and improving the security and protection flexibility of electronic locks.
Patent Information
- Application Number
- CN202511511642.2
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-10-22
- Publication Date
- 2025-11-21
- Estimated Expiration
- 2045-10-22
AI Technical Summary
Traditional electronic locks lack the ability to predict malicious attacks related to mechanical vibration, resulting in lagging security protection and difficulty in intercepting covert mechanical vibration-related attacks.
By collecting the power supply voltage waveform of the electronic lock, extracting the power supply glitch characteristics and performing vibration spectrum similarity analysis, distinguishing mechanical vibration-related disturbance scenarios, obtaining the register bit flip probability distribution, constructing a migration probability map, and monitoring and adjusting the protection strategy in real time, adaptive locking is achieved.
It effectively distinguishes between mechanical vibration and ordinary interference, strengthens the protection of high-risk registers in a targeted manner, identifies potential attack paths in advance, flexibly adjusts protection strategies, and enhances the security and adaptability of electronic locks in complex scenarios.
Smart Images

Figure CN120995316A_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of electronic lock security control technology, specifically to an AI-based dynamic risk adaptive locking control method for electronic locks. Background Technology
[0002] Electronic locks are now widely used in smart homes, financial security, public facility management and other scenarios, but the chain of risks caused by mechanical vibration has become a key issue restricting their safety performance.
[0003] Traditional electronic locks lack the ability to predict malicious attack paths associated with mechanical vibrations. In practical applications, some malicious attackers exploit power disturbances and register bit flipping vulnerabilities caused by the mechanical vibrations of electronic locks. Through specific operations, they induce abnormal migrations in the core state nodes of the electronic lock, ultimately breaching the lock's security protection. The passive protection mode of traditional electronic locks is insufficient to intercept covert mechanical vibration-related attacks, making electronic locks vulnerable to such attacks and resulting in a significant lag in security protection.
[0004] To address this, the present invention provides an AI-based dynamic risk adaptive locking control method for electronic locks. Summary of the Invention
[0005] The purpose of this invention is to provide an AI-based dynamic risk adaptive locking control method for electronic locks to solve the aforementioned background problems.
[0006] The objective of this invention can be achieved through the following technical solutions: The AI-based dynamic risk adaptive locking control method for electronic locks includes the following steps: The power supply voltage waveform of the electronic lock is collected and the power supply glitch features are extracted. The vibration spectrum is obtained and similarity analysis is performed to obtain the similarity. Based on the power supply glitch features and similarity, it is determined whether the power supply glitch is related to mechanical vibration. Based on the determination results, the power supply disturbance scenario is classified. Obtain the bit flip probability distribution of the electronic lock register under all power disturbance scenarios, distinguish the register disturbance type based on the bit flip probability distribution, and formulate differentiated parity check and hierarchical mirror storage strategies based on the register disturbance type. Core state nodes are extracted based on register perturbation types. These nodes are then used to construct a migration probability map of the core state nodes by combining historical mechanical vibration-related attack cases. A path migration model is then constructed based on the migration probability map, and high-risk migration paths are output. Based on high-risk migration paths, real-time path local matching analysis is performed on electronic locks. If a local match is found, a phase-aware state machine is established for freezing and vibration period monitoring, thereby realizing the dynamic adjustment of adaptive lock control protection strategies in mechanically coupled scenarios.
[0007] As a further aspect of the present invention: the method for determining whether a power supply glitch is related to mechanical vibration is as follows: The similarity of the vibration spectrum is used to determine whether mechanical vibration glitches are triggered. If triggered, the voltage drop depth, drop duration, and vibration spectrum similarity are obtained. A three-dimensional criterion is established. If the voltage drop depth, drop duration period, and vibration spectrum similarity satisfy the three-dimensional criterion, then it is a power supply glitch associated with mechanical vibration.
[0008] As a further aspect of the present invention: the similarity of the vibration spectrum is obtained as follows: During the drop duration, vibration signals are synchronously acquired to obtain a vibration acceleration sequence synchronized with the voltage sampling period; The vibration acceleration sequence is preprocessed to obtain the vibration spectrum sequence; A vibration spectrum benchmark library was established for electronic locks under different historical application scenarios. Similarity analysis was performed on the vibration spectrum sequences and vibration spectrum benchmark libraries under different scenarios to obtain the similarity.
[0009] As a further aspect of the present invention: the method for distinguishing the register perturbation type is as follows: Obtain the scene amplification factor of all registers, and classify the scene amplification factor of all registers using a clustering algorithm to obtain high-risk registers and low-risk registers.
[0010] As a further aspect of the present invention: the method for obtaining the scene amplification factor of the register is as follows: The power disturbance scenarios are classified into mechanical vibration-related power disturbance scenarios and ordinary electromagnetic interference scenarios. Extract the total number of bit flips, the number of scene cycles, and the number of bits in the registers for different power disturbance scenarios from the historical log data of the electronic lock; By constructing a bit-flip probability equation, the total number of bit flips, the number of scenario cycles, and the number of bits in the register for different power disturbance scenarios are input into the bit-flip probability equation to obtain the bit-flip probability for different registers corresponding to power disturbance scenarios. The ratio of the bit-flip probability in the power disturbance scenario with mechanical vibration correlation, the bit-flip probability in the ordinary electromagnetic interference scenario, and the bit-flip probability in the normal operating condition scenario are calculated to obtain the scenario amplification factor.
[0011] As a further aspect of the present invention: the high-risk migration path is output in the following manner: The migration probability map of mechanical vibration-related scenarios is obtained, and a path migration model is constructed using the Markov chain algorithm to output high-risk migration paths.
[0012] As a further aspect of the present invention, the path migration model is constructed as follows: Based on the characteristics of mechanically coupled fluctuation moments, the vulnerable time window bound to the fluctuation moment is determined; Obtain the migration probability map and vulnerability time window, as well as the node attack weights of the initial node set; Based on the migration probability graph and the vulnerability time window, and combined with the node attack weights of the initial node set, a forward scan of the Markov chain is performed to obtain the node migration probability under different time lengths. High-risk migration paths are selected based on the node migration probability under different time lengths.
[0013] As a further aspect of the present invention, the method for obtaining the migration probability map is as follows: Retrieve high-risk and low-risk data blocks from differentiated parity checking and tiered mirroring storage strategies; Extract the core state nodes of high-risk and low-risk data blocks respectively, and extract the node attack weight of the core state nodes. Associate the node attack weights with all core state nodes to construct an initial node set; Obtain the number of matching cases for low-risk data blocks and high-risk data blocks in the corresponding core status nodes, and then obtain the migration probabilities of low-risk and high-risk data blocks through the migration probability equation. Using the initial node set as vertices and the migration probability as the weight of the directed edges, a migration probability graph of the mechanical vibration associated scenario is constructed.
[0014] As a further aspect of the present invention: the method for obtaining the node attack weight is as follows: Obtain the scene amplification coefficients for low-risk and high-risk data blocks, and perform normalization processing to obtain the node influence coefficients; Obtain the probability of each core state node being tampered with in the historical attack case library, and combine it with the node influence coefficient corresponding to each core state node; The product of the probability of each core state node being tampered with and the node influence coefficient will be used as the node attack weight for each node.
[0015] As a further aspect of the present invention, the method for performing the real-time path local matching analysis is as follows: Continuously monitor the complete migration path of the electronic lock. If the current complete migration path of the electronic lock partially matches the high-risk migration path, but does not reach the end point of the high-risk migration path, then extract the vibration main frequency phase angle and drop duration period of the electronic lock under the current working condition. If the sampling point in the drop duration of the electronic lock meets the mechanical coupling fluctuation moment, and the phase angle of the vibration main frequency is in the sensitive range, then the state machine clock of the electronic lock is frozen, and vibration period monitoring is started.
[0016] The beneficial effects of this invention are: (1) In the power disturbance scenario classification step, power spike features are extracted by collecting the power supply voltage waveform of the electronic lock, and power spikes associated with mechanical vibration are determined by combining vibration spectrum similarity analysis, thereby classifying the power disturbance scenario. This can effectively distinguish different scenarios such as mechanical vibration associated type, ordinary electromagnetic interference type, and normal working condition type, reducing the confusion between special disturbances caused by mechanical vibration and ordinary interference, providing accurate scenario basis for subsequent targeted lock control protection, reducing protection deviations caused by scenario misjudgment, and improving the effectiveness of electronic lock risk identification from the source.
[0017] (2) In the process of distinguishing register disturbance types and formulating storage strategies, high-risk and low-risk registers are distinguished based on the bit flip probability distribution of registers under various power disturbance scenarios, and differentiated parity check and hierarchical mirror storage strategies are formulated. Adaptive protection methods are adopted for registers with different risk levels. High-risk registers are strengthened in terms of verification and storage protection to reduce the impact of bit flips, while low-risk registers are balanced in terms of storage efficiency and basic protection. This can reduce the waste of resources caused by excessive protection while ensuring the reliability of register data, which is conducive to improving the security and rationality of electronic lock core data storage. (3) Extract core state nodes from register disturbance types, construct node migration probability maps by combining historical mechanical vibration-related attack cases, and then construct path migration models and output high-risk migration paths by combining vulnerable time windows. This step can identify malicious attack paths that electronic locks may face in mechanical vibration scenarios in advance, realize proactive prediction of potential risk paths, provide a clear direction for timely interception of malicious attacks, and enhance the forward-looking risk prevention and control capabilities of electronic locks.
[0018] (4) In the adaptive lock control protection strategy adjustment step, a local coincidence analysis is performed on the real-time path of the electronic lock based on the high-risk migration path. When a coincidence occurs, a phase-aware state machine freeze and vibration cycle monitoring are established, and the protection strategy is dynamically adjusted. This process can flexibly adjust the protection measures according to the real-time operating conditions and risk status of the electronic lock. When there is a risk, the state machine freeze and other protection actions are activated in a timely manner. After confirming safety, normal operation is restored reasonably. This effectively intercepts malicious risks and reduces the impact of fixed protection strategies on the normal use of the electronic lock, thereby improving the flexibility and adaptability of the electronic lock in complex mechanical coupling scenarios. Attached Figure Description
[0019] The invention will now be further described with reference to the accompanying drawings.
[0020] Figure 1 This is a flowchart of the AI-based dynamic risk adaptive locking control method for electronic locks according to the present invention; Figure 2This is the logic diagram for determining whether mechanical vibration-type burr verification is triggered in this invention. Figure 3 This is a block diagram of the AI-based dynamic risk adaptive locking control system for electronic locks according to the present invention. Detailed Implementation
[0021] The technical solutions of the embodiments of the present invention will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of the present invention, and not all embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of the present invention.
[0022] Example 1 Please see Figure 1 As shown, this invention is an AI-based dynamic risk adaptive locking control method for electronic locks, comprising the following steps: S1. Collect the power supply voltage waveform of the electronic lock and extract the power supply glitch features. Obtain the vibration spectrum and perform similarity analysis to obtain the similarity. Based on the power supply glitch features and similarity, determine whether it is a power supply glitch related to mechanical vibration. Based on the determination results, classify the power supply disturbance scenario. The method for acquiring the power supply voltage waveform of the electronic lock and extracting power supply glitches is as follows: Preferably, during the sampling period, the voltage waveform output by the electronic lock power supply is acquired through the analog-to-digital conversion unit of the electronic lock, and the voltage waveform is preprocessed to obtain the purified voltage. ; The preprocessing includes: time-domain moving average filtering and frequency-domain low-pass filtering; Define the voltage recognition range for abnormal voltage drop characteristics, and extract the purified voltage based on the voltage recognition range to obtain the voltage recognition segment; Calculate the start and end times of the voltage recognition segment to obtain the drop duration period; By establishing a fall depth equation: Obtain the voltage drop depth ,in, This represents the minimum voltage during the duration of the drop. The rated voltage of the electronic lock power supply is denoted by k, which represents the voltage sampling number. The fall rate and fall duration period are used as characteristics of power glitches. Where n is the sampling sequence number corresponding to the start time of the voltage identification segment, and m is the sampling sequence number corresponding to the end time of the voltage identification segment. The sampling sequence number is determined by the sampling period of the analog-to-digital conversion unit. The method for obtaining the similarity score by acquiring the vibration spectrum of the electronic lock and performing a similarity analysis with the vibration spectrum of historical scenes is as follows: During the drop duration, the electronic lock's built-in triaxial accelerometer synchronously collects vibration signals and obtains a vibration acceleration sequence synchronized with the voltage sampling period. The vibration acceleration sequence is preprocessed (Fast Fourier Transform) to obtain the vibration spectrum sequence; We acquire vibration spectrum benchmark libraries established by electronic locks in different historical application scenarios, and perform similarity analysis between vibration spectrum sequences and vibration spectrum benchmark libraries in different scenarios to obtain similarity scores. It should be noted that the correlation coefficient of the spectral envelope is used to calculate the similarity between the vibration spectrum sequences in different scenarios. The closer the correlation coefficient is to 1, the higher the similarity. The method for determining whether a power glitch is related to mechanical vibration based on its characteristics and similarity is as follows: like Figure 2 As shown, if the similarity of the vibration spectrum is higher than or equal to the preset similarity value, mechanical vibration glitch verification is triggered to determine whether it is a power glitch associated with mechanical vibration. If the similarity of the vibration spectrum is lower than the preset similarity value, mechanical vibration glitch verification will not be triggered. Preferably, the verification method for triggering mechanical vibration-type burrs is: combining the drop depth of voltage drop. Duration of the decline And establish a three-dimensional criterion based on vibration spectrum similarity to determine whether it is a mechanical vibration-related burr: when , Furthermore, when the similarity between the vibration spectrum and the reference spectrum of the mechanical vibration scene is greater than a preset similarity value (such as a preset similarity value of 0.7), the three-dimensional criterion is established. If the voltage drop depth Duration of the decline If the vibration spectrum similarity satisfies the three-dimensional criteria, it is determined to be a power supply glitch associated with mechanical vibration; otherwise, it is determined to be a voltage fluctuation caused by simple vibration interference. in, , The effective identification range for drop depth includes the lower and upper limits. , The lower and upper limits of the effective identification range for the duration of the fall are determined by those skilled in the art through statistical analysis of measured data of mechanical vibration and simple vibration. If the power supply glitches are related to mechanical vibration, then the current scenario will be classified as a power supply disturbance scenario related to mechanical vibration. Understandably, the purpose of identifying power supply glitches associated with mechanical vibration is: Objective 1: To categorize power disturbance scenarios in electronic locks and prevent confusion between special power disturbances caused by mechanical vibration and ordinary electromagnetic interference or voltage fluctuations under normal operating conditions. Based on the judgment results, scenarios can be divided into mechanical vibration-related, ordinary electromagnetic interference, and normal operating condition scenarios. Failure to identify power spikes related to mechanical vibration can easily lead to misjudgment of scenarios, which will serve as the basis for subsequent targeted protection.
[0023] Objective 2: To lay the foundation for subsequent analysis of register bit flipping risks and the development of differentiated protection strategies. Mechanical vibration-related scenarios are one of the key scenarios that can trigger register bit flipping. Only by classifying the types of power disturbance scenarios, distinguishing between high-risk and low-risk registers, and developing appropriate parity checking and hierarchical mirroring storage strategies can we prevent errors in this judgment from directly causing subsequent register risk analysis and protection strategies to deviate from actual needs.
[0024] S2. Obtain the bit flip probability distribution of the electronic lock register under all power disturbance scenarios, distinguish the register disturbance type based on the bit flip probability distribution, and formulate differentiated parity check and hierarchical mirror storage strategies based on the register disturbance type. The method for obtaining the bit-flip probability distribution of the electronic lock register under all power disturbance scenarios, and distinguishing the register disturbance type based on the bit-flip probability distribution, is as follows: If the power supply glitches are related to mechanical vibration, then obtain the bit flip probability distribution of the register group of the electronic lock state machine under all power supply disturbance scenarios. It should be noted that the register group includes registers for: latch drive, risk level, and behavior mode; The method for obtaining the bit flip probability distribution of the register group of the electronic lock state machine under all power disturbance scenarios is as follows: The power disturbance scenario is marked as j, where j=1 represents the power disturbance scenario associated with mechanical vibration (i.e., power glitches associated with mechanical vibration), j=2 represents the ordinary electromagnetic interference scenario, and j=3 represents the normal operating condition scenario. It should be noted that for power disturbance scenarios associated with mechanical vibration: the power bus voltage drop depth and duration must fall within the judgment range for mechanical vibration association, and the similarity between the synchronously collected vibration spectrum and the historical benchmark library of mechanical vibration scenarios must be higher than a preset threshold. In ordinary electromagnetic interference scenarios: the power bus experiences abnormal voltage drops, but the drop characteristics do not meet the judgment range (i.e., the judgment range consisting of the upper and lower limits of the effective identification range of the drop depth and the drop duration period); and the vibration spectrum matches the electromagnetic interference scenario benchmark library, but the similarity with the mechanical vibration scenario benchmark library is below the threshold. Normal operating conditions: The power bus voltage is stable and does not meet the requirements for abnormal voltage drop fluctuations; at the same time, the vibration signal is within the vibration range when the electronic lock is working normally. Extract the total number of bit flips in the registers under different power disturbance scenarios from the historical log data of the electronic lock. Number of scene loops The number of bits in the register ; Where i is the register number; By constructing a bit-flip probability equation: Obtain the bit flip probability of different registers i corresponding to power disturbance scenario j ; The ratio of the bit-flip probability in the power disturbance scenario with mechanical vibration correlation, the normal electromagnetic interference scenario, and the normal operating condition scenario is calculated to obtain the scenario amplification factor. It is understandable that the purpose of obtaining the scene magnification factor is: Function 1: To support the differentiation of register disturbance types and clarify the basis for risk level classification; the scenario amplification factor is the ratio of the bit flip probability in mechanical vibration-related and ordinary electromagnetic interference scenarios to the bit flip probability in normal operating conditions, which can intuitively reflect the degree of amplification of register bit flip risk by different disturbance scenarios. By classifying the scenario amplification factors of all registers through clustering algorithms, high-risk registers and low-risk registers can be distinguished, providing a clear risk level classification standard for subsequent targeted protection strategies; Secondly, it provides data for calculating the attack weight of core state nodes. The node attack weight requires first normalizing the scenario amplification coefficients of low-risk and high-risk data blocks to obtain the node influence coefficient, and then multiplying it by the probability of the core state node being tampered with. The accuracy of the scenario amplification coefficient directly determines the rationality of the node influence coefficient, thus affecting the calculation result of the node attack weight. The node attack weight is a crucial parameter for constructing the initial node set and migration probability graph, providing data support for subsequent prediction of high-risk migration paths. Thirdly, it ensures the adaptability of protection strategies to actual risk scenarios. The scenario amplification factor reflects the difference in risk to registers under different disturbance scenarios. Based on this distinction between high-risk and low-risk registers, the subsequent differentiated parity checking and hierarchical mirrored storage strategies can be matched to actual risks. Without a scenario amplification factor, over-protection of low-risk registers wastes resources, while insufficient protection of high-risk registers fails to address core risk scenarios such as mechanical vibration. Obtain the scene amplification factor of all registers, and classify the scene amplification factor of all registers using the K-Means clustering algorithm in artificial intelligence (AI) to obtain high-risk registers and low-risk registers; Those skilled in the art will understand that the scenario amplification coefficients corresponding to each register i are used to form a coefficient dataset to be clustered; K-Means unsupervised clustering is performed on the coefficient dataset of each register: the number of clusters is set to 2 (corresponding to high-risk and low-risk classes). The K-Means algorithm automatically divides the register coefficient dataset into two clusters through iterative optimization (randomly initializing cluster centers, calculating the distance from data points to cluster centers and assigning clusters, updating cluster centers until the centers are stable). Since mechanical vibration amplifies the bit flip risk of high-risk registers more significantly, the cluster containing the larger coefficient dataset value after clustering corresponds to the high-risk register perturbation type; the other cluster corresponds to the low-risk register perturbation type. Among them, the method of formulating differentiated parity checking and hierarchical mirrored storage strategies based on register perturbation type is as follows: Preferably, the method for formulating parity check storage strategies for coupled scenarios is as follows: For high-risk registers (such as latch drive registers, which are directly affected by mechanical vibration), a 4-bit data block + 2-bit cross-register group interleaved parity bit architecture is adopted: The parity bits of the 4-bit data block are distributed and stored in the free bit segments of adjacent low-risk registers (such as behavior mode registers). This utilizes the stability of low-risk registers in mechanically associated scenarios to reduce the synchronous damage of parity bits caused by local failures in high-risk registers. For low-risk registers, an 8-bit data block plus a 1-bit parity check bit is used to balance storage efficiency and basic error correction capability. For power supply waveforms in power disturbance scenarios associated with mechanical vibration, mechanical coupling fluctuation timing analysis is performed. If the fluctuation occurs during a mechanical coupling fluctuation, a mirror storage strategy that associates vibration with anomaly is constructed by combining a parity check storage strategy. It should be noted that the method for analyzing mechanically coupled fluctuations is as follows: after determining that the power disturbance is related to mechanical vibration, the duration of the voltage waveform drop is immediately locked (from the starting sampling point n to the ending point m), and the power bus voltage waveform and the vibration signal from the triaxial accelerometer are extracted simultaneously during this period; the voltage waveform is filtered at 50Hz power frequency to eliminate grid interference, and the vibration main frequency component is extracted using a sliding window FFT to establish a time-aligned voltage-vibration dual-mode data stream; Based on time-aligned data streams, the phase correlation between instantaneous voltage fluctuations and vibration acceleration is calculated: taking the voltage drop trough as a reference, the time offset Δt of the most recent vibration peak is detected, and the normalized phase difference Δθ = 360° × (Δt / T) is calculated in combination with the vibration dominant frequency period T; at the same time, the energy proportion of the voltage waveform in the mechanically sensitive frequency band of 10-100Hz is statistically analyzed, and when the energy proportion exceeds 40%, it is marked as a strong mechanical coupling feature. If the sampling points during the fall duration simultaneously satisfy the conditions of phase difference Δθ < 45° and low-frequency energy ratio > 40%, then the sampling points are considered as mechanical coupling fluctuation moments; otherwise, they are classified as ordinary electromagnetic disturbance events; the determination results are pushed to the S4 protection engine in real time to trigger the phase-aware protection strategy. The method for constructing a mirrored storage strategy that correlates vibration and anomalies is as follows: If there is a power supply failure, the risk level, behavior pattern and sensor data of the electronic lock are split according to the register type. High-risk register (such as the lock tongue drive register) data is packaged into a high-risk data block, and low-risk register (such as the behavior pattern register) data is packaged into a low-risk data block, and integrated to form layered mirror data. For high-risk data blocks, enhanced verification matching the register architecture is adopted: the 4-bit data block + 2-bit cross-register group interleaved check bit is used, and an additional 1-bit global check bit (for the entire high-risk data block) is added to improve the multi-bit fault repair capability. For low-risk data blocks, use an 8-bit data block + 1-bit regular parity bit to maintain storage efficiency; The mirror data is copied to obtain the main mirror data (the original before the mirror data is copied) and redundant mirror data (the copy after the mirror data is copied). The high-risk data block and the low-risk data block are stored in the regular area of the MCU's built-in Flash according to the original verification format, and the physical address of the high-risk data block is ≥2 storage pages away from the low-risk data block (to reduce the impact of local failures on both types of data at the same time). When storing redundant mirrored data, the main vibration frequency of mechanical vibration is extracted, and the erase / write timing frequency of the Flash storage unit is adjusted to an integer multiple of the non-main vibration frequency. At the same time, for the redundant mirrored high-risk data blocks, an additional 16 bits of CRC check are added for every 128 bits, while the redundant mirrored low-risk data blocks maintain the basic check.
[0025] Example 2 like Figure 1 As shown, this invention is an AI-based dynamic risk adaptive locking control method for electronic locks, which also includes the following steps: S3. Extract core state nodes based on register perturbation types, construct a migration probability map of core state nodes by combining historical mechanical vibration-related attack cases, construct a path migration model by combining the migration probability map, and output high-risk migration paths. The method for extracting core state nodes based on register perturbation types and constructing a migration probability graph of core state nodes by combining historical mechanical vibration-related attack cases is as follows: Extract the latch extension / retraction status and drive motor power threshold from the high-risk data block as core status nodes; Preferably, the bolt extension / retraction state of the electronic lock is obtained from the high-risk data block. and the power threshold of the drive motor of the electronic lock ; The latch extension / retraction states include: 01 - locked state, 00 - half-locked state, and 10 - unlocked state. The normal value for the drive motor's power threshold is 2A, and the abnormal value is 0.5A. Extract the unlock request verification status and user permission registration from low-risk data blocks as core status nodes; Preferably, obtain the unlock request verification status. 001 - Pending verification, 101 - Verification passed, 010 - Verification failed; User permission level :11 - Administrator, 01 - Regular User, 00 - Visitor; Obtain a historical attack case library of electronic locks, extract matching cases related to mechanical vibration, and extract complete attack chains from the matching cases; It should be noted that the vibration spectrum reference library is obtained from raw data collected by a triaxial accelerometer under typical mechanical vibration scenarios; Obtain the scene amplification coefficients for low-risk and high-risk data blocks, and perform normalization processing to obtain the node influence coefficients; Obtain the probability of each core state node being tampered with in the historical attack case library, and combine it with the node influence coefficient corresponding to each core state node; The product of the probability of each core state node being tampered with and its influence coefficient will be used as the node attack weight for each node. ; Node attack weight Associate with all core state nodes to construct an initial node set. ; Based on the extracted matching cases, extract the number of matching cases for low-risk data blocks in the corresponding core status nodes, and the number of matching cases for high-risk data blocks in the corresponding core status nodes. Based on the number of matching cases for low-risk data blocks and the number of matching cases for high-risk data blocks in their corresponding core state nodes, the transition probability equation is used: Obtain the migration probability of low-risk and high-risk data blocks; in, This represents the core state node at the start of the migration, where 'x' is the node identifier, corresponding to the core state node of a low-risk or high-risk data block. For example: , ,belong Specific manifestations; The core status node represents the migration target, where 'y' is the node identifier, and it also corresponds to the core status node of low-risk or high-risk data blocks. For example: , All belong to Specific manifestations; Understandably, obtaining the migration probability of low-risk and high-risk data blocks has a physical meaning based on the statistics of historical mechanical vibration-related attack cases. It quantitatively reflects the actual possibility of state transition between the core state nodes of low-risk and high-risk data blocks, reflects the dynamic change pattern of core nodes of data blocks of different risk levels in risk scenarios, and provides a concrete numerical basis for constructing migration probability maps of mechanical vibration-related scenarios and predicting high-risk migration paths of malicious attacks. It also reflects the tendency of nodes of the two types of data blocks to transition from one state to another, supporting the formulation of subsequent targeted locking and protection strategies. Using the initial node set N as the vertices, and the transition probability... We construct a migration probability graph for mechanical vibration-related scenarios, using directed edge weights. By obtaining the vulnerable time window bound to the fluctuation moment and combining it with the migration probability map of the mechanical vibration-related scenario, a path migration model is constructed using the Markov chain algorithm to output high-risk migration paths that may be maliciously exploited. The method for constructing the path migration model is as follows: S301. Based on the characteristics of mechanically coupled fluctuation moments, determine the vulnerable time window bound to the fluctuation moment; Preferably, the historical mechanical coupling fluctuation moment is used as the starting point of the vulnerable time window, and multiple monitoring periods of fixed duration are set to obtain the probability of high-risk data block nodes being tampered with within all monitoring periods; If the probability of a high-risk data block node being tampered with is lower than a preset threshold, the duration from the start point to the end of the current monitoring period is obtained, and the endpoint of the fluctuation time window is determined based on the start point and duration. Construct a vulnerable time window based on the start and end points of the fluctuation time window; Obtain the sampling period of the analog-to-digital conversion unit and calculate the sampling period as the scan step size of the Markov chain algorithm; S302. Based on the migration probability graph and the vulnerability time window, and combined with the node attack weights of the initial node set, a forward scan of the Markov chain is performed to obtain the node migration probability under different time lengths. Preferably, based on the migration probability map and vulnerable time window of the mechanical vibration associated scenario, the node probability vector (4-dimensional vector, the initial value is obtained by normalizing the node attack weight) and the migration probability matrix (4×4 square matrix, the matrix elements are the migration probabilities between core state nodes, taken from the migration probability map) are determined; then, the forward scan is performed iteratively according to the scan step size: at each step, the current vector is calculated by multiplying the node probability vector of the previous time step by the migration probability matrix, and at the same time, the mechanical vibration vulnerability coefficient (2.5 times) is added to the matrix elements corresponding to high-risk nodes for correction, and finally the node probability vector under 30 step size is obtained, that is, the node migration probability of different step size; It should be noted that the 2.5x correction was obtained by those skilled in the art through experimental comparison of bit flip error rates under no-vibration and vibration scenarios; S303. Based on the node migration probability under different time lengths, screen high-risk migration paths that may be maliciously exploited. Preferably, based on the probability vector of 30 step-size nodes, the complete migration path of all initial normal states, intermediate transition states, and final malicious states is extracted; For example: the complete migration path of bolt locking (high risk normal) - motor 0.5A (high risk abnormal) - verification passed (low risk) - bolt unlocking (high risk malicious); Perform three verifications on each path: Verification 1: Calculate the total migration probability by multiplying the transition probabilities of each node in the path; Verification 2: Check if there are any abnormal states of high-risk nodes (such as motor 0.5A, bolt half-locked or unlocked). Verification 3: The attack weights of all nodes in the cumulative path are finally filtered out. Paths with a total migration probability of ≥5%, containing abnormal states of high-risk nodes, and node attack weights ≥0.8 are integrated to form high-risk migration paths that are susceptible to malicious exploitation. S4. Based on high-risk migration paths, perform real-time path local matching analysis on electronic locks. If a local match is found, establish a phase-aware state machine freeze and vibration cycle monitoring to realize dynamic adjustment of adaptive lock control protection strategy in mechanical coupling scenarios. The method for performing real-time path local matching analysis on electronic locks based on high-risk migration paths is as follows: Continuously monitor the complete migration path of the electronic lock. If the current complete migration path of the electronic lock partially matches the high-risk migration path, but does not reach the end point of the high-risk migration path, then extract the vibration main frequency phase angle and drop duration period of the electronic lock under the current working condition. The method for dynamically adjusting the adaptive locking and protection strategy in mechanically coupled scenarios, by establishing a phase-aware state machine freeze and vibration period monitoring, is as follows: If the sampling point in the drop duration of the electronic lock meets the mechanical coupling fluctuation moment, and the phase angle of the vibration main frequency is in the sensitive range, then the state machine clock of the electronic lock is frozen and vibration period monitoring is started. It should be noted that the mechanical vibration signal is collected by the built-in triaxial accelerometer of the electronic lock. After extracting the dominant vibration frequency component through a sliding window fast Fourier transform, the calculated dominant vibration frequency phase angle falls within a specific phase range that poses the highest risk of interference to the core functions of the electronic lock (such as register data stability and state machine operation), as determined based on historical mechanical vibration-related attack cases and statistical data from measured data. The definition of this specific phase range is directly related to the energy transfer characteristics of mechanical vibration. When the phase angle is within this range, the energy transfer efficiency of vibration to key components such as the electronic lock power supply module and register group is higher, making it easier to aggravate power supply glitches, trigger register bit flips, or cause abnormal migration of core state nodes. Therefore, this specific phase range is set as a sensitive range. Different adaptive control strategies for electronic locks are developed based on the monitoring results of vibration period monitoring. Preferably, the method for formulating different adaptive control strategies for electronic locks is as follows: If the vibration cycle monitoring detects that the phase of the main vibration frequency is in the trough of 180°-270°, and the end point of the high-risk migration path has not been reached while the safety is confirmed by manual inspection, then the state machine clock freeze is lifted and the delayed critical operation is executed. The phase angle sensitive range (180°–270°) was obtained by a person skilled in the art through correlation experiments using simulation data of vibration energy transfer efficiency. If the high-risk migration path is reached, the electronic lock is determined to be in an irreversible malicious state. The security status node data is read from the layered mirror storage area. If the security status node data is read successfully, the verification strategy is determined based on the vibration spectrum similarity analysis results. If the strategy needs to be adjusted, the verification strategy of the electronic lock's register will be adjusted; otherwise, the basic verification will be maintained. Those skilled in the art will understand that the adaptive adjustment of the differential verification strategy for registers can be made as follows: if the vibration spectrum similarity shows that the risk of mechanical vibration association has increased, the verification of high-risk registers (such as latch drive registers) can be strengthened (such as increasing the bit width of cross-register group interleaved verification or supplementing global verification), or the verification format of low-risk registers (such as behavior pattern registers) can be optimized according to the risk changes to balance protection and efficiency. Maintaining basic verification means that when vibration spectrum similarity analysis shows that the risk of the current scenario does not exceed the original protection adaptation range, the initially set differentiated verification scheme (4-bit data block + 2-bit cross-register group interleaved verification for high-risk registers, 8-bit data block + 1-bit regular parity verification for low-risk registers, and additional CRC verification for high-risk data blocks, etc.) is maintained to ensure that the verification strategy adjustment always fits the actual risk of the mechanical vibration-related scenario and is consistent with the locking logic of dynamic adaptation risk.
[0026] Example 3 like Figure 3 As shown, the AI-based electronic lock dynamic risk adaptive locking system includes the following modules: Disturbance correlation module: used to collect the power supply voltage waveform of the electronic lock and extract the power supply glitch features, obtain the vibration spectrum for similarity analysis to obtain the similarity, determine whether it is a power supply glitch related to mechanical vibration based on the power supply glitch features and similarity, and classify the power supply disturbance scenario based on the determination result. The bit flip analysis module is used to obtain the bit flip probability distribution of the electronic lock register under all power disturbance scenarios, distinguish the register disturbance type based on the bit flip probability distribution, and formulate differentiated parity check and hierarchical mirror storage strategies based on the register disturbance type. Path extraction module: Extracts core state nodes based on register perturbation type, which are used to construct a migration probability map of core state nodes by combining historical mechanical vibration-related attack cases, construct a path migration model by combining the migration probability map, and output high-risk migration paths; Strategy adjustment module: Based on high-risk migration paths, the electronic lock performs real-time path local matching analysis. If a local match is found, a phase-aware state machine is established for freezing and vibration cycle monitoring, thereby realizing the dynamic adjustment of adaptive lock control protection strategy in mechanical coupling scenarios.
[0027] The foregoing has provided a detailed description of one embodiment of the present invention, but this description is merely a preferred embodiment and should not be construed as limiting the scope of the invention. All equivalent variations and modifications made within the scope of the present invention should still fall within the scope of the present invention.
Claims
1. An AI-based dynamic risk adaptive locking control method for electronic locks, characterized by: Includes the following steps: The power supply voltage waveform of the electronic lock is collected and the power supply glitch features are extracted. The vibration spectrum is obtained and similarity analysis is performed to obtain the similarity. Based on the power supply glitch features and similarity, it is determined whether the power supply glitch is related to mechanical vibration. Based on the determination results, the power supply disturbance scenario is classified. Obtain the bit flip probability distribution of the electronic lock register under all power disturbance scenarios, distinguish the register disturbance type based on the bit flip probability distribution, and formulate differentiated parity check and hierarchical mirror storage strategies based on the register disturbance type. Core state nodes are extracted based on register perturbation types. These nodes are then used to construct a migration probability map of the core state nodes by combining historical mechanical vibration-related attack cases. A path migration model is then constructed based on the migration probability map, and high-risk migration paths are output. Based on high-risk migration paths, real-time path local matching analysis is performed on electronic locks. If a local match is found, a phase-aware state machine is established for freezing and vibration period monitoring, thereby realizing the dynamic adjustment of adaptive lock control protection strategies in mechanically coupled scenarios.
2. The AI-based dynamic risk adaptive locking control method for electronic locks according to claim 1, characterized in that: The method for determining whether a power supply glitch is related to mechanical vibration is as follows: The similarity of the vibration spectrum is used to determine whether mechanical vibration glitches are triggered. If triggered, the voltage drop depth, drop duration, and vibration spectrum similarity are obtained. A three-dimensional criterion is established. If the voltage drop depth, drop duration period, and vibration spectrum similarity satisfy the three-dimensional criterion, then it is a power supply glitch associated with mechanical vibration.
3. The AI-based dynamic risk adaptive locking control method for electronic locks according to claim 2, characterized in that: The similarity of the vibration spectrum is obtained as follows: During the drop duration, vibration signals are synchronously acquired to obtain a vibration acceleration sequence synchronized with the voltage sampling period; The vibration acceleration sequence is preprocessed to obtain the vibration spectrum sequence; A vibration spectrum benchmark library was established for electronic locks under different historical application scenarios. Similarity analysis was performed on the vibration spectrum sequences and vibration spectrum benchmark libraries under different scenarios to obtain the similarity.
4. The AI-based dynamic risk adaptive locking control method for electronic locks according to claim 1, characterized in that: The method for distinguishing the register perturbation type is as follows: Obtain the scene amplification factor of all registers, and classify the scene amplification factor of all registers using a clustering algorithm to obtain high-risk registers and low-risk registers.
5. The AI-based dynamic risk adaptive locking control method for electronic locks according to claim 4, characterized in that: The method for obtaining the scene amplification factor of the register is as follows: The power disturbance scenarios are classified into mechanical vibration-related power disturbance scenarios and ordinary electromagnetic interference scenarios. Extract the total number of bit flips, the number of scene cycles, and the number of bits in the registers for different power disturbance scenarios from the historical log data of the electronic lock; By constructing a bit-flip probability equation, the total number of bit flips, the number of scenario cycles, and the number of bits in the register for different power disturbance scenarios are input into the bit-flip probability equation to obtain the bit-flip probability for different registers corresponding to power disturbance scenarios. The ratio of the bit-flip probability in the power disturbance scenario with mechanical vibration correlation, the bit-flip probability in the ordinary electromagnetic interference scenario, and the bit-flip probability in the normal operating condition scenario are calculated to obtain the scenario amplification factor.
6. The AI-based dynamic risk adaptive locking control method for electronic locks according to claim 1, characterized in that: The high-risk migration path is output in the following way: The migration probability map of mechanical vibration-related scenarios is obtained, and a path migration model is constructed using the Markov chain algorithm to output high-risk migration paths.
7. The AI-based dynamic risk adaptive locking control method for electronic locks according to claim 6, characterized in that: The path migration model is constructed as follows: Based on the characteristics of mechanically coupled fluctuation moments, the vulnerable time window bound to the fluctuation moment is determined; Obtain the migration probability map and vulnerability time window, as well as the node attack weights of the initial node set; Based on the migration probability graph and the vulnerability time window, and combined with the node attack weights of the initial node set, a forward scan of the Markov chain is performed to obtain the node migration probability under different time lengths. High-risk migration paths are selected based on the node migration probability under different time lengths.
8. The AI-based dynamic risk adaptive locking control method for electronic locks according to claim 7, characterized in that: The method for obtaining the migration probability map is as follows: Retrieve high-risk and low-risk data blocks from differentiated parity checking and tiered mirroring storage strategies; Extract the core state nodes of high-risk and low-risk data blocks respectively, and extract the node attack weight of the core state nodes. Associate the node attack weights with all core state nodes to construct an initial node set; Obtain the number of matching cases for low-risk data blocks and high-risk data blocks in the corresponding core status nodes, and then obtain the migration probabilities of low-risk and high-risk data blocks through the migration probability equation. Using the initial node set as vertices and the migration probability as the weight of the directed edges, a migration probability graph of the mechanical vibration associated scenario is constructed.
9. The AI-based dynamic risk adaptive locking control method for electronic locks according to claim 7, characterized in that: The method for obtaining node attack weight is as follows: Obtain the scene amplification coefficients for low-risk and high-risk data blocks, and perform normalization processing to obtain the node influence coefficients; Obtain the probability of each core state node being tampered with in the historical attack case library, and combine it with the node influence coefficient corresponding to each core state node; The product of the probability of each core state node being tampered with and the node influence coefficient will be used as the node attack weight for each node.
10. The AI-based dynamic risk adaptive locking control method for electronic locks according to claim 1, characterized in that: The method for performing the real-time path local matching analysis is as follows: Continuously monitor the complete migration path of the electronic lock. If the current complete migration path of the electronic lock partially matches the high-risk migration path, but does not reach the end point of the high-risk migration path, then extract the vibration main frequency phase angle and drop duration period of the electronic lock under the current working condition. If the sampling point in the drop duration of the electronic lock meets the mechanical coupling fluctuation moment, and the phase angle of the vibration main frequency is in the sensitive range, then the state machine clock of the electronic lock is frozen, and vibration period monitoring is started.
Citation Information
Patent Citations
Persistent fault analysis method based on voltage burrs
CN120428077A
Power equipment anomaly detection method and system based on multi-modal AI
CN120429788A
Switch loop data extraction method, device and equipment based on phase locking
CN120654164A
Information processing system implementing program structures common to higher level program languages
US3665421A
Voltage glitch detector
WO2025076373A1