Electronic scale data encryption protection method and device based on security encryption chip

By adopting a data encryption protection method based on a secure encryption chip in the electronic scale, using historical data features to build encryption constraints, encrypting and verifying real-time data, the problem of security risks in the data transmission and storage of electronic scales is solved, and the problem of security risks in the data transmission and storage process of electronic scales is realized. High security and reliability of data.

CN118764328BActive Publication Date: 2025-02-18SINXIN INFORMATION TECH CO LTD +1
View PDF 1 Cites 0 Cited by

Patent Information

Application Number
CN202411254668.9
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2024-09-09
Publication Date
2025-02-18
Estimated Expiration
2044-09-09

AI Technical Summary

Technical Problem

Existing electronic scales have security risks in data transmission and storage, resulting in data vulnerability to attack and tampering.

Method used

Adopt the data encryption protection method of electronic scales based on a secure encryption chip, and obtain the historical encrypted data of the target electronic scale, perform key feature identification and encryption constraint construction, encrypt and verify the data in real time, and send the encrypted data to the cloud and merchants. Mobile server.

Benefits of technology

Effectively prevent data from being illegally accessed or tampered with, improving the security and reliability of data.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN118764328B_ABST
    Figure CN118764328B_ABST
Patent Text Reader

Abstract

The present application provides a data encryption protection method and device for an electronic scale based on a security encryption chip, which relates to the field of data protection technology, including: obtaining historical encrypted data of a target electronic scale; performing centralized feature recognition to construct a first encryption constraint; collecting real-time data for initial encryption; performing constraint adjustment and optimization on the initial verification key to obtain a real-time verification key; verifying the initial encrypted monitoring data; and sending the real-time encrypted monitoring data to a cloud big data platform and a merchant mobile service terminal for data supervision and weighing display. This application can solve the technical problem in the prior art that data is vulnerable to attack and tampering due to security risks in the data transmission and storage process of existing electronic scales. By using historical data features to construct encryption constraints, encrypting and verifying real-time data, data can be prevented from being illegally accessed or tampered with, thereby improving data security and reliability.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application relates to the field of data protection technology, and in particular to an electronic scale data encryption protection method and device based on a security encryption chip. Background Art

[0002] With the rapid development of information technology and the improvement of consumption levels, consumers have higher and higher requirements for product quality and services. In addition, the increasing attention paid by all sectors of society to the protection of consumer rights has prompted the public to pay more attention to and be more sensitive to fraudulent consumption issues such as short weight and selling inferior goods as good ones. Electronic scales collect data through weight sensors and transmit these data to the cloud or merchant service end for processing and storage. However, existing electronic scales have certain security risks in the process of data transmission and storage. The lack of effective security measures in the design allows merchants to easily tamper with weighing data through physical or software means. Secondly, due to the lack of in-depth analysis and utilization of historical data, data protection is also insufficient, and it is impossible to effectively prevent data from being tampered with or leaked.

[0003] In summary, the prior art has a technical problem in which data is vulnerable to attack and tampering due to security risks in the data transmission and storage process of the existing electronic scales. Summary of the invention

[0004] The purpose of this application is to provide a data encryption protection method and device for an electronic scale based on a security encryption chip, so as to solve the technical problem in the prior art that the data is vulnerable to attack and tampering due to security risks in the data transmission and storage process of the existing electronic scales.

[0005] In view of the above problems, the present application provides an electronic scale data encryption protection method and device based on a security encryption chip.

[0006] In a first aspect, the present application provides an electronic scale data encryption protection method based on a security encryption chip, wherein the electronic scale data encryption protection method based on a security encryption chip is implemented by an electronic scale data encryption protection device based on a security encryption chip, wherein the electronic scale data encryption protection method based on a security encryption chip includes: obtaining multiple historical encrypted data of a target electronic scale in a preset historical window, wherein the multiple historical encrypted data include multiple historical verification keys; performing centralized feature recognition on the multiple historical verification keys to generate a key centralized feature set, and constructing a first encryption constraint condition based on the key centralized feature set; collecting real-time monitoring data of a weight sensor of the target electronic scale, performing initial encryption on the real-time monitoring data using a security encryption chip, and obtaining initial encrypted monitoring data, wherein the initial encrypted monitoring data includes an initial key; obtaining an initial verification key, and performing constraint adjustment and optimization on the initial verification key based on the first encryption constraint condition until a preset number of adjustments are met to obtain a real-time verification key; using the real-time verification key to verify the initial encrypted monitoring data to obtain real-time encrypted monitoring data; and sending the real-time encrypted monitoring data to a cloud big data platform and a merchant mobile service end for data supervision and weighing display.

[0007] In the second aspect, the present application also provides an electronic scale data encryption protection device based on a security encryption chip, which is used to execute the electronic scale data encryption protection method based on a security encryption chip as described in the first aspect, wherein the electronic scale data encryption protection device based on a security encryption chip includes: a historical data acquisition module, the historical data acquisition module is used to obtain multiple historical encrypted data of the target electronic scale in a preset historical window, wherein the multiple historical encrypted data include multiple historical verification keys; a constraint condition construction module, the constraint condition construction module is used to perform centralized feature recognition on the multiple historical verification keys, generate a centralized feature set of keys, and construct a first encryption constraint condition based on the centralized feature set of keys; an initial encryption module, the initial encryption module is used to collect the target electronic scale The real-time monitoring data of the weight sensor of the scale is initially encrypted by a security encryption chip to obtain initial encrypted monitoring data, wherein the initial encrypted monitoring data includes an initial key; a verification key optimization module, the verification key optimization module is used to obtain an initial verification key, and based on the first encryption constraint condition, the initial verification key is constrained and adjusted to optimize until a preset number of adjustments are met to obtain a real-time verification key; a data verification module, the data verification module is used to verify the initial encrypted monitoring data using the real-time verification key to obtain real-time encrypted monitoring data; a data transmission module, the data transmission module is used to send the real-time encrypted monitoring data to a cloud big data platform and a merchant mobile service terminal for data supervision and weighing display.

[0008] One or more technical solutions provided in this application have at least the following technical effects or advantages:

[0009] By obtaining multiple historical encrypted data of the target electronic scale in a preset historical window, wherein the multiple historical encrypted data include multiple historical verification keys; performing centralized feature recognition on the multiple historical verification keys, generating a centralized feature set of keys, and constructing a first encryption constraint condition based on the centralized feature set of keys; collecting real-time monitoring data of the weight sensor of the target electronic scale, using a secure encryption chip to perform initial encryption on the real-time monitoring data, and obtaining initial encrypted monitoring data, wherein the initial encrypted monitoring data includes an initial key; obtaining an initial verification key, and performing constraint adjustment and optimization on the initial verification key based on the first encryption constraint condition until the preset adjustment times are met, and obtaining a real-time verification key; using the real-time verification key to verify the initial encrypted monitoring data, and obtaining real-time encrypted monitoring data; and sending the real-time encrypted monitoring data to the cloud big data platform and the merchant mobile service end for data supervision and weighing display. In other words, by constructing encryption constraints using historical data features, encrypting and verifying real-time data, data can be prevented from being illegally accessed or tampered with, thereby improving data security and reliability.

[0010] The above description is only an overview of the technical solution of the present application. In order to more clearly understand the technical means of the present application, it can be implemented according to the contents of the specification, and in order to make the above and other purposes, features and advantages of the present application more obvious and easy to understand, the specific implementation methods of the present application are specifically cited below. It should be understood that the content described in this section is not intended to identify the key or important features of the embodiments of the present application, nor is it intended to limit the scope of the present application. Other features of the present application will become easy to understand through the following description. BRIEF DESCRIPTION OF THE DRAWINGS

[0011] In order to more clearly illustrate the technical solutions in the present application or the prior art, the drawings required for use in the embodiments or the description of the prior art will be briefly introduced below. Obviously, the drawings in the following description are only exemplary, and for ordinary technicians in this field, other drawings can be obtained based on the provided drawings without paying any creative work.

[0012] Figure 1 This is a flow chart of the electronic scale data encryption protection method based on the security encryption chip of this application;

[0013] Figure 2 This is a schematic diagram of the structure of the electronic scale data encryption protection device based on the security encryption chip of the present application.

[0014] Explanation of the accompanying drawings: historical data collection module 11, constraint condition construction module 12, initial encryption module 13, verification key optimization module 14, data verification module 15, data transmission module 16. DETAILED DESCRIPTION

[0015] This application provides a data encryption protection method and device for electronic scales based on a security encryption chip, which solves the technical problem in the prior art that data is vulnerable to attack and tampering due to security risks in the data transmission and storage process of existing electronic scales. By using historical data features to construct encryption constraints, real-time data is encrypted and verified to prevent data from being illegally accessed or tampered with, thereby improving data security and reliability.

[0016] Below, the technical solutions in the present application will be clearly and completely described with reference to the accompanying drawings. Obviously, the described embodiments are only part of the embodiments of the present application, rather than all of the embodiments of the present application. It should be understood that the present application is not limited to the example embodiments described herein. Based on the embodiments of the present application, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of the present application. It should also be noted that, for the convenience of description, only the parts related to the present application are shown in the accompanying drawings, rather than all of them.

[0017] For example, please refer to the attached Figure 1 The present application provides an electronic scale data encryption protection method based on a security encryption chip, wherein the electronic scale data encryption protection method based on a security encryption chip is applied to an electronic scale data encryption protection device based on a security encryption chip, and the electronic scale data encryption protection method based on a security encryption chip specifically includes the following steps:

[0018] Step 1: Acquire a plurality of historical encrypted data of a target electronic scale in a preset historical window, wherein the plurality of historical encrypted data includes a plurality of historical verification keys.

[0019] Specifically, the encrypted data of the target electronic scale within a certain period of time in the past is accessed, including the historical verification key. The preset historical window refers to a set period of time for collecting historical data, which can be adjusted according to actual needs, such as one day, one week or one month. The multiple historical encrypted data include the encrypted data of the electronic scale within a certain period of time, which has been processed by a certain encryption method. The historical verification key is a value or algorithm result used to verify the integrity and authenticity of the encrypted data. When the data is encrypted or prepared for transmission / storage, a hash function (or other type of verification algorithm) is used to generate a unique verification value (or hash value) for the data. This verification value can be regarded as the "fingerprint" of the data, representing the current state of the data. If the data is tampered with during transmission or storage, the recalculated verification value will not match the original verification value, indicating that the integrity of the data has been compromised. By analyzing these historical verification keys, the historical trends and patterns of data encryption can be understood, and the encryption strategy can be automatically adjusted according to the changes in historical data, so as to better respond to potential security threats.

[0020] Step 2: Perform centralized feature recognition on the multiple historical verification keys to generate a centralized feature set of keys, and construct a first encryption constraint condition based on the centralized feature set of keys.

[0021] Specifically, multiple historical verification keys are analyzed, and a neural network is used to identify and extract common features or patterns. Features include the length of the key, the distribution of character types (such as the ratio of uppercase letters, lowercase letters, numbers, and special symbols), entropy (an indicator of the randomness of the key), hash value, etc. These features are gathered together to form a feature set, namely multiple historical verification key feature sets. The optimal target particle point is selected from multiple historical verification key feature sets, and its corresponding historical verification key feature set is used as the key set feature set. The first encryption constraint condition refers to the similarity between the real-time key feature set of the real-time verification key and the key set feature set extracted from the historical verification key, which needs to be lower than a preset similarity threshold. By analyzing and identifying the features of the historical verification key, a more powerful and flexible encryption constraint condition is constructed to protect the data of the electronic scale and prevent unauthorized access and tampering.

[0022] Step three: collect real-time monitoring data of the weight sensor of the target electronic scale, and use a security encryption chip to initially encrypt the real-time monitoring data to obtain initial encrypted monitoring data, wherein the initial encrypted monitoring data includes an initial key.

[0023] Specifically, electronic scales measure weight through weight sensors (such as strain gauges, pressure sensors, etc.) to collect real-time monitoring weight data. The real-time monitoring data is initially encrypted using a secure encryption chip to obtain initial encrypted monitoring data, including the encrypted weight data and the initial secret key. The secure encryption chip is usually a dedicated hardware module designed to perform data encryption and decryption operations, and integrates a variety of encryption algorithms, such as AES, RSA, etc., to meet different encryption requirements. In order to protect the security of critical data, high security measures are adopted for data storage to ensure that the data is not illegally accessed or tampered with during the storage process. The secure encryption chip is designed with security in mind, including preventing physical attacks, side channel attacks, etc., to ensure the security of the encryption process. Each device or data packet has a globally unique code, which ensures the identification and tracking of each data packet, and increases the security and traceability of the data. The encryption chip has a key management function that can generate, store and update encryption keys, and uses an independent burning system to store data, ensuring the security of the data writing process and preventing the data from being tampered with during the writing process. In devices such as electronic scales, secure encryption chips are used to protect the security of data transmission. For example, data transmission between the button and the main board, and between the weight plate and the main board can be encrypted through the serial port using a security encryption chip, effectively preventing unauthorized access or tampering during data transmission, thereby ensuring the confidentiality and integrity of the data. By using a security encryption chip to initially encrypt data, the security of real-time monitoring data during transmission and storage is ensured to prevent unauthorized access and data leakage.

[0024] Step 4: Obtain an initial verification key, and perform constraint adjustment on the initial verification key based on the first encryption constraint condition until a preset number of adjustments is met to obtain a real-time verification key.

[0025] Specifically, an initial verification key is obtained to verify and protect the integrity and authenticity of the weighing data. Feature recognition is performed on the initial verification key to obtain a feature set, and the similarity between the feature set and the feature set in the key set is calculated to obtain the initial similarity. The initial similarity is compared with the similarity threshold of the first encryption constraint condition. If the initial similarity is greater, the initial similarity is subtracted from the preset similarity threshold, and then divided by the preset similarity threshold to obtain the first verification adjustment coefficient. According to the first verification adjustment coefficient and the first encryption constraint condition, the initial verification key is subjected to constraint adjustment optimization until the preset number of adjustments is met to obtain the real-time verification key. Alternatively, the key adjustment network layer is used to identify the verification adjustment coefficient and the initial verification key to obtain the first adjustment verification key. It is determined whether the similarity between the feature set of the first adjustment verification key and the feature set in the key set meets the first encryption constraint condition. If not, a second verification adjustment coefficient is obtained. Based on the second verification adjustment coefficient and the first encryption constraint condition, the first adjustment verification key is further subjected to constraint adjustment optimization until the preset number of adjustments is met to obtain the real-time verification key. By adjusting the optimization process through constraints, it is ensured that the real-time verification key meets both security requirements and has sufficient performance.

[0026] Step 5: Use the real-time verification key to verify the initial encrypted monitoring data to obtain real-time encrypted monitoring data.

[0027] Specifically, the initial encrypted monitoring data is verified using the real-time verification key to ensure the integrity and non-tampering of the data. Through the verification process, real-time encrypted monitoring data is generated, which is verified and protected data for further processing and transmission. By using the real-time verification key to verify the initial encrypted monitoring data, the integrity and security of the data are ensured, and the data is prevented from being illegally tampered with or leaked during transmission and storage, thereby protecting the privacy and data security of users.

[0028] Step 6: Send the real-time encrypted monitoring data to the cloud big data platform and the merchant mobile service terminal for data supervision and weighing display.

[0029] Specifically, the verified and encrypted real-time monitoring data is sent to the cloud big data platform and the merchant mobile service end. The cloud big data platform is a remote server used to store and analyze large amounts of data. The merchant mobile service end is a mobile device or system used by merchants to receive and process data. On the cloud big data platform, the real-time encrypted monitoring data is stored, analyzed and monitored, such as monitoring the weight changes during the circulation of goods. The real-time encrypted monitoring data is displayed on the merchant mobile service end for merchants to view and use. By sending the real-time encrypted monitoring data to the cloud big data platform, the data is stored, analyzed and monitored, thereby improving the efficiency of data management and utilization. The weighing data is displayed on the merchant mobile service end, which is convenient for merchants to view and manage data in real time and improve the transparency and accessibility of the data. Through data supervision and weighing display, the security of the data is improved and the accuracy and reliability of the data are ensured.

[0030] Further, step 2 of this application includes:

[0031] The first encryption constraint condition is that the similarity between the real-time key feature set of the real-time verification key and the feature set in the key set is lower than a preset similarity threshold.

[0032] Furthermore, the present application also includes the following steps:

[0033] A key feature identifier is used to perform feature identification on the multiple historical verification keys to obtain multiple historical verification key feature sets; a centralized feature identification space is constructed based on the multiple historical verification key feature sets, wherein the centralized feature identification space includes multiple particle points, wherein each particle point corresponds to a historical verification key feature set; a first particle point is randomly extracted from the centralized feature identification space as an identification starting point, and the first particle point is iteratively updated in the centralized feature identification space according to a preset identification step length until a preset iteration stop condition is met to obtain a target particle point; and the historical verification key feature set corresponding to the target particle point is used as the key centralized feature set.

[0034] Specifically, perform data preprocessing on multiple historical verification keys, clean the data, and remove noise and outliers. Then perform standardization or normalization, and divide the processed data into training set, validation set, and test set. Select the appropriate network type according to the complexity of the problem and the characteristics of the data, such as fully connected network, convolutional neural network (CNN), recurrent neural network (RNN), etc. Design the number of layers of the network and the number of neurons in each layer. Select appropriate activation functions (such as ReLU), loss functions (such as cross entropy), and optimizers. Use the training set to train the model and adjust model parameters such as learning rate, batch size, and number of iterations to optimize model performance. Monitor the training process to prevent overfitting or underfitting. Use the validation set to evaluate the performance of the model, adjust the model architecture or parameters, and improve the accuracy and generalization ability of the model. Use the test set to perform a final test on the model to ensure that the model has good generalization ability and can accurately identify new key features.

[0035] The key feature identifier is a neural network-based model that analyzes and identifies features of encryption keys. The historical verification key is provided as input to the key feature identifier, and the model automatically extracts complex features from the input data through its internal neural network structure. The feature outputs of each key are combined to form a feature set. Based on multiple historical verification key feature sets, a multidimensional feature space is constructed. In this space, each dimension represents a feature of the key, and each point (particle point) in the space corresponds to a feature set of historical verification keys. A particle point is randomly selected from the centralized feature recognition space as the recognition starting point. In the encryption or data processing process, the recognition starting point refers to the location or instance where the analysis or processing of data begins.

[0036] Take the first particle point as the recognition starting point, iterate according to the preset recognition step and random iteration direction to obtain the particle point of the first iteration. If the particle aggregation amount in the area where the particle point is located after the first iteration is greater than the aggregation amount in the area where the particle point is located before, the particle point after the iteration is used as the new recognition starting point. Continue to iterate according to the preset recognition step and random iteration direction until the iteration stop condition is met and the area with denser distribution is reached. The particle point at this time is used as the target particle point. On the contrary, if the particle aggregation amount in the area where the first particle point is located is greater than the aggregation amount in the area where the particle point is located after the iteration, call the rand function to generate two random numbers.

[0037] Compare these two random numbers. If the first value is greater than or equal to the second value, add the direction of the first iteration to the taboo iteration direction table to avoid selecting this direction again. Iterate in directions other than the directions in the taboo table with a preset recognition step size until the preset iteration stop condition is met to obtain the target particle point. If the first value is less than the second value, receive the particle point after the first iteration as the recognition starting point, and iterate in the opposite direction of the first iteration with a preset recognition compensation until the preset iteration stop condition is met to obtain the target particle point. The historical verification key feature set corresponding to the final optimal particle point is used as the key set feature set. By analyzing the characteristics of the key, a more powerful and flexible encryption constraint condition is constructed to guide the encryption process of real-time data, ensuring that the data is effectively protected during transmission and storage, thereby improving data security.

[0038] Furthermore, the present application also includes the following steps:

[0039] Taking the first particle point as the recognition starting point, iterating in the concentrated feature recognition space according to a preset recognition step and a random iteration direction to obtain a first iterative particle point; when the first aggregation amount of the first particle point is less than or equal to the first iterative aggregation amount of the first iterative particle point, updating the first iterative particle point as the recognition starting point; randomly iterating the first iterative particle point in the concentrated feature recognition space according to a random iteration direction according to a preset recognition step until a preset iteration stop condition is met to obtain the target particle point, wherein the preset iteration stop condition is that the difference in iterative aggregation amounts of two adjacent iterations is less than or equal to the preset iterative aggregation amount difference.

[0040] Furthermore, the present application also includes the following steps:

[0041] When the first aggregation amount of the first particle point is greater than the first iterative aggregation amount of the first iterative particle point, the rand function is called to randomly generate a first value and a second value; when the first value is greater than or equal to the second value, the random iteration direction of the first iterative particle point is added to the taboo iteration direction table, and the first particle point is used as the recognition starting point, and iteration is performed in the concentrated feature recognition space according to the preset recognition step size and the random iteration direction other than the taboo iteration direction table until the preset iteration stop condition is met to obtain the target particle point, wherein the taboo iteration direction table has a preset iteration; when the first value is less than the second value, the first iterative particle point is accepted as the recognition starting point for iterative update, and in the next iteration, the opposite direction of the random iteration direction of the first iterative particle point is used as the random iteration direction until the preset iteration stop condition is met to obtain the target particle point.

[0042] Specifically, a recognition step size is pre-set, that is, the step size of a single move. Taking the first particle point as the recognition starting point, iteration is performed in the centralized special recognition space, and a direction is randomly selected to move to obtain the first iteration particle point. The first particle point is a starting point randomly extracted from the centralized feature recognition space and is used to start the iteration process. The random iteration direction means that in each iteration, the particle point moves in a randomly selected direction, increasing the complexity and unpredictability of the encryption process. The first iteration particle point refers to the new position obtained from the first particle point by iterating in the preset step size and random direction. After each iteration, the aggregation amount around this particle point is calculated.

[0043] Compare the aggregation amount of the first particle point with that of the first iteration particle point. When the first aggregation amount of the first particle point is less than or equal to the first iteration aggregation amount of the first iteration particle point, use the first iteration particle point as a new recognition starting point. The first aggregation amount refers to the number of particle points in the area with the first particle point as the center and the preset recognition step as the radius. The iteration aggregation amount refers to the number of particle points in the area with the iteration particle point as the center and the preset recognition step as the radius.

[0044] For the first iteration particle point, i.e., the new identification starting point, random iteration is performed according to the preset identification step size and random iteration direction until the preset iteration stop condition is met, and the position at this time is used as the target particle point for final identification. The preset iteration stop condition is that the difference in the iterative aggregation amount between two adjacent iterations is less than or equal to the preset iterative aggregation amount difference, indicating that the area with denser particle distribution has been reached at this time. The aggregation amount difference refers to the difference in the number of particle points in the area around the particle point between two adjacent iterations, indicating the change in the number of particle points around the target particle point after two consecutive iterations. The preset iterative aggregation amount difference is a pre-set threshold value used to determine whether the iterative aggregation amount difference is less than or equal to this threshold value. If this condition is met, the iteration process stops and the target particle point is considered to be the optimal solution in the search space. This preset threshold value is usually determined based on the design goal of the algorithm and the characteristics of the search space. It needs to be small enough to detect subtle changes, but not too small so that the algorithm cannot find the optimal solution in a reasonable time.

[0045] When the first aggregation amount of the first particle point is greater than the first iteration aggregation amount of the first iteration particle point, the random number generation function rand function is called to generate random values, the first value and the second value. If the first value is greater than the second value, the random iteration direction of the first iteration particle point is added to the list of taboo iteration directions. The taboo iteration direction table is used to record the infeasible directions that have been tried in the iteration process to avoid these directions from being repeatedly tried in future iterations. It has a preset iteration and limits the number of directions recorded in the taboo iteration direction table. During the iteration process, the algorithm will select the next search direction according to the taboo iteration direction table. If a direction is marked as taboo in the table, then within a certain number of iterations, the algorithm will avoid selecting this direction again to prevent the algorithm from falling into a local optimal solution and encourage the algorithm to explore new search spaces.

[0046] Taking the first particle point as the identification starting point, iterate according to the preset identification step size and random iteration direction except the taboo iteration direction table until the preset stop condition is met, and the position at this time is used as the target particle point for final identification. The preset iteration stop condition is that the difference in the iterative aggregation amount between two adjacent iterations is less than or equal to the preset iterative aggregation amount difference, indicating that the area with dense particle distribution has been reached.

[0047] If the first value is greater than the second value, the first iteration particle point is used as the identification starting point for iterative update. In the next iteration, the random iteration direction is reversed from the random iteration direction of the current first iteration particle point as the random iteration direction until the preset stop condition is met. The position at this time is used as the target particle point for final identification. Since the inferior solution is accepted, the optimal solution may be missed when iterative identification is performed with the inferior solution. Reverse iteration is required to avoid falling into the local optimal solution and being unable to continue optimization. If the aggregation amount of the new position is better than the previous position after the reverse movement, this position is updated as the new identification starting point.

[0048] In a specific example, assume that the aggregation amount of the first particle point is 50, and the iterative aggregation amount of the first iteration particle point is 60. Because the aggregation amount of the first particle point is less than or equal to the aggregation amount of the first iteration particle point, the first iteration particle point is used as the new recognition starting point and named as the second particle point. Then the second iteration is performed, and the aggregation amount of the second iteration particle point drops to 55. At this time, the aggregation amount of the second particle point is greater than the aggregation amount of the second iteration particle point. The rand function is called to generate two random numbers, 0.8 and 0.3. At this time, the first value is greater than the second value, and the random iteration direction of this iteration is added to the taboo iteration direction table. Continue to use the second particle point as the recognition starting point, and according to the preset recognition compensation, select the random iteration direction other than the taboo iteration direction table for iteration. The new iteration direction causes the aggregation amount to rise to 75, and the second example iteration point at this time is used as the new recognition starting point. Continue to iterate, and each iteration determines whether to change the direction according to the value generated by the rand function, and updates the taboo iteration direction table. The iteration process continues until the preset iteration stop condition is met, such as the change in aggregation amount is less than a certain threshold.

[0049] By performing random iterations in the concentrated feature recognition space, the particle points move in different directions in each iteration, increasing the complexity of the encryption process. The introduction of reverse movement and taboo iteration direction tables prevents particles from falling into local optimal solutions, ensuring that the algorithm can explore a wider search space to find a better encryption solution. The preset iteration stop condition ensures that the iteration process stops after reaching a certain stable state, avoiding unnecessary iterations and improving the efficiency of the algorithm. It effectively improves the encryption security of electronic scale data, prevents unauthorized access and data tampering, and ensures data integrity and confidentiality.

[0050] Further, step 4 of this application includes:

[0051] The key feature identifier is used to perform feature identification on the initial verification key to obtain an initial verification key feature set; the cosine similarity formula is used to calculate the similarity between the initial verification key feature set and the feature set in the key set to obtain an initial similarity; when the initial similarity is greater than a preset similarity threshold in the first encryption constraint condition, the difference between the initial similarity and the preset similarity threshold is compared with the preset similarity threshold to obtain a first verification adjustment coefficient; the initial verification key is subjected to constraint adjustment and optimization according to the first verification adjustment coefficient and the first encryption constraint condition until a preset number of adjustments is met to obtain the real-time verification key.

[0052] Specifically, the initial verification key is input into the key feature identifier for feature recognition to obtain the initial verification key feature set. The initial verification key refers to the key used to verify the integrity and authenticity of the data during the initial encryption process. The cosine similarity formula is used to calculate the similarity between the initial verification key feature set and the feature set in the key set to obtain the initial similarity. The cosine similarity formula is a mathematical formula used to measure the similarity between two vectors. It calculates the cosine value of the angle between the two vectors, and its value is between 0 and 1, where 1 indicates that they are exactly the same and 0 indicates that they are completely different. When the initial similarity is greater than the preset similarity threshold in the first encryption constraint, the difference between the initial similarity and the preset similarity threshold is calculated, and the difference is divided by the preset similarity threshold to obtain the first verification adjustment coefficient. According to the first verification adjustment coefficient and the first encryption constraint, the initial verification key is optimized and adjusted to achieve the best security performance. The optimization is performed multiple times, and the parameters are continuously adjusted until the preset number of adjustments is reached, and the optimization is stopped to avoid excessive adjustment or waste of computing resources. Through constraint adjustment optimization, a real-time verification key is obtained for real-time verification. Comparison of the real-time verification key feature set with the key centralized feature set can ensure the validity of the key, reduce misjudgments and errors, adjust the verification adjustment coefficient and encryption constraints, and adjust the strictness of verification according to actual conditions.

[0053] Furthermore, the present application also includes the following steps:

[0054] The check adjustment coefficient and the initial check key are identified by using the key adjustment network layer to obtain a first adjustment check key; whether the similarity between the first adjustment key feature set of the first adjustment check key and the feature set in the key set satisfies the first encryption constraint condition is determined, and if not, a second check adjustment coefficient is obtained; based on the second check adjustment coefficient and the first encryption constraint condition, the first adjustment check key is constrained and optimized until a preset number of adjustments is met to obtain the real-time check key.

[0055] Specifically, the key adjustment network layer is a network layer used to identify and adjust the verification key. This network layer is used to identify the verification adjustment coefficient and the initial verification key to obtain the first adjusted verification key. Determine whether the similarity between the feature set of the first adjusted verification key and the feature set in the key set meets the first encryption constraint. If not, a second verification adjustment coefficient will be obtained. Based on the second verification adjustment coefficient and the first encryption constraint, the first adjusted verification key is further constrained and optimized until the preset number of adjustments is met to obtain the real-time verification key. Constrained adjustment optimization refers to adjusting the key according to the adjustment coefficient and constraint conditions to find the optimal solution. Through this identification, judgment and adjustment process, it is ensured that the real-time verification key meets the security requirements and has sufficient differences.

[0056] In summary, the electronic scale data encryption protection method based on the security encryption chip provided in this application has the following technical effects:

[0057] By obtaining multiple historical encrypted data of the target electronic scale in a preset historical window, wherein the multiple historical encrypted data include multiple historical verification keys; performing centralized feature recognition on the multiple historical verification keys, generating a centralized feature set of keys, and constructing a first encryption constraint condition based on the centralized feature set of keys; collecting real-time monitoring data of the weight sensor of the target electronic scale, using a secure encryption chip to perform initial encryption on the real-time monitoring data, and obtaining initial encrypted monitoring data, wherein the initial encrypted monitoring data includes an initial key; obtaining an initial verification key, and performing constraint adjustment and optimization on the initial verification key based on the first encryption constraint condition until the preset adjustment times are met, and obtaining a real-time verification key; using the real-time verification key to verify the initial encrypted monitoring data, and obtaining real-time encrypted monitoring data; and sending the real-time encrypted monitoring data to the cloud big data platform and the merchant mobile service end for data supervision and weighing display. In other words, by constructing encryption constraints using historical data features, encrypting and verifying real-time data, data can be prevented from being illegally accessed or tampered with, thereby improving data security and reliability.

[0058] Embodiment 2, based on the same inventive concept as the electronic scale data encryption protection method based on the security encryption chip in the previous embodiment, the present application also provides an electronic scale data encryption protection device based on the security encryption chip, please refer to the attached Figure 2 , the electronic scale data encryption protection device based on the security encryption chip includes:

[0059] The historical data collection module 11 is used to obtain a plurality of historical encrypted data of the target electronic scale in a preset historical window, wherein the plurality of historical encrypted data includes a plurality of historical verification keys.

[0060] The constraint condition construction module 12 is used to perform centralized feature recognition on the multiple historical verification keys, generate a centralized feature set of keys, and construct a first encryption constraint condition based on the centralized feature set of keys.

[0061] The initial encryption module 13 is used to collect real-time monitoring data of the weight sensor of the target electronic scale, and use a security encryption chip to initially encrypt the real-time monitoring data to obtain initial encrypted monitoring data, wherein the initial encrypted monitoring data includes an initial key.

[0062] The verification key optimization module 14 is used to obtain an initial verification key, and to perform constraint adjustment and optimization on the initial verification key based on the first encryption constraint condition until a preset number of adjustments are met to obtain a real-time verification key.

[0063] The data verification module 15 is used to verify the initial encrypted monitoring data using the real-time verification key to obtain real-time encrypted monitoring data.

[0064] The data transmission module 16 is used to send the real-time encrypted monitoring data to the cloud big data platform and the merchant mobile service terminal for data supervision and weighing display.

[0065] Furthermore, the constraint condition building module 12 in the electronic scale data encryption protection device based on the security encryption chip is also used for:

[0066] The first encryption constraint condition is that the similarity between the real-time key feature set of the real-time verification key and the feature set in the key set is lower than a preset similarity threshold.

[0067] Furthermore, the constraint condition building module 12 in the electronic scale data encryption protection device based on the security encryption chip is also used for:

[0068] A key feature identifier is used to perform feature identification on the multiple historical verification keys to obtain multiple historical verification key feature sets; a centralized feature identification space is constructed based on the multiple historical verification key feature sets, wherein the centralized feature identification space includes multiple particle points, wherein each particle point corresponds to a historical verification key feature set; a first particle point is randomly extracted from the centralized feature identification space as an identification starting point, and the first particle point is iteratively updated in the centralized feature identification space according to a preset identification step length until a preset iteration stop condition is met to obtain a target particle point; and the historical verification key feature set corresponding to the target particle point is used as the key centralized feature set.

[0069] Furthermore, the constraint condition building module 12 in the electronic scale data encryption protection device based on the security encryption chip is also used for:

[0070] Taking the first particle point as the recognition starting point, iterating in the concentrated feature recognition space according to a preset recognition step and a random iteration direction to obtain a first iterative particle point; when the first aggregation amount of the first particle point is less than or equal to the first iterative aggregation amount of the first iterative particle point, updating the first iterative particle point as the recognition starting point; randomly iterating the first iterative particle point in the concentrated feature recognition space according to a random iteration direction according to a preset recognition step until a preset iteration stop condition is met to obtain the target particle point, wherein the preset iteration stop condition is that the difference in iterative aggregation amounts of two adjacent iterations is less than or equal to the preset iterative aggregation amount difference.

[0071] Furthermore, the constraint condition building module 12 in the electronic scale data encryption protection device based on the security encryption chip is also used for:

[0072] When the first aggregation amount of the first particle point is greater than the first iterative aggregation amount of the first iterative particle point, the rand function is called to randomly generate a first value and a second value; when the first value is greater than or equal to the second value, the random iteration direction of the first iterative particle point is added to the taboo iteration direction table, and the first particle point is used as the recognition starting point, and iteration is performed in the concentrated feature recognition space according to the preset recognition step size and the random iteration direction other than the taboo iteration direction table until the preset iteration stop condition is met to obtain the target particle point, wherein the taboo iteration direction table has a preset iteration; when the first value is less than the second value, the first iterative particle point is accepted as the recognition starting point for iterative update, and in the next iteration, the opposite direction of the random iteration direction of the first iterative particle point is used as the random iteration direction until the preset iteration stop condition is met to obtain the target particle point.

[0073] Furthermore, the verification key optimization module 14 in the electronic scale data encryption protection device based on the security encryption chip is also used for:

[0074] The key feature identifier is used to perform feature identification on the initial verification key to obtain an initial verification key feature set; the cosine similarity formula is used to calculate the similarity between the initial verification key feature set and the feature set in the key set to obtain an initial similarity; when the initial similarity is greater than a preset similarity threshold in the first encryption constraint condition, the difference between the initial similarity and the preset similarity is compared with the preset similarity to obtain a first verification adjustment coefficient; the initial verification key is subjected to constraint adjustment and optimization according to the first verification adjustment coefficient and the first encryption constraint condition until a preset number of adjustments is met to obtain the real-time verification key.

[0075] Furthermore, the verification key optimization module 14 in the electronic scale data encryption protection device based on the security encryption chip is also used for:

[0076] The check adjustment coefficient and the initial check key are identified by using the key adjustment network layer to obtain a first adjustment check key; whether the similarity between the first adjustment key feature set of the first adjustment check key and the feature set in the key set satisfies the first encryption constraint condition is determined, and if not, a second check adjustment coefficient is obtained; based on the second check adjustment coefficient and the first encryption constraint condition, the first adjustment check key is constrained and optimized until a preset number of adjustments is met to obtain the real-time check key.

[0077] The various embodiments in this specification are described in a progressive manner, and each embodiment focuses on the differences from other embodiments. Figure 1 The electronic scale data encryption protection method based on the security encryption chip and the specific examples in the first embodiment are also applicable to the electronic scale data encryption protection device based on the security encryption chip in this embodiment. Through the above detailed description of the electronic scale data encryption protection method based on the security encryption chip, those skilled in the art can clearly know the electronic scale data encryption protection device based on the security encryption chip in this embodiment, so for the sake of brevity of the specification, it will not be described in detail here. For the device disclosed in the embodiment, since it corresponds to the method disclosed in the embodiment, the description is relatively simple, and the relevant parts can be referred to the method part description.

[0078] The above description of the disclosed embodiments enables those skilled in the art to implement or use the present application. Various modifications to these embodiments will be apparent to those skilled in the art, and the general principles defined herein may be implemented in other embodiments without departing from the spirit or scope of the present application. Therefore, the present application will not be limited to the embodiments shown herein, but will conform to the widest scope consistent with the principles and novel features disclosed herein.

[0079] Obviously, those skilled in the art can make various changes and modifications to the present application without departing from the spirit and scope of the present application. Thus, if these modifications and variations of the present application belong to the scope of the present application and its equivalent technology, the present application is also intended to include these modifications and variations.

Claims

1. An electronic scale data encryption protection method based on a security encryption chip, characterized in that: include: Acquire multiple historical encrypted data of the target electronic scale in a preset historical window, wherein the multiple historical encrypted data include multiple historical verification keys; Performing centralized feature recognition on the multiple historical verification keys to generate a centralized feature set of keys, and constructing a first encryption constraint condition based on the centralized feature set of keys; Collecting real-time monitoring data of the weight sensor of the target electronic scale, and performing initial encryption on the real-time monitoring data using a security encryption chip to obtain initial encrypted monitoring data, wherein the initial encrypted monitoring data includes an initial key; Obtain an initial verification key, and perform constraint adjustment and optimization on the initial verification key based on the first encryption constraint condition until a preset number of adjustments is met to obtain a real-time verification key; Using the real-time verification key to verify the initial encrypted monitoring data to obtain real-time encrypted monitoring data; The real-time encrypted monitoring data is sent to the cloud big data platform and the merchant mobile service terminal for data supervision and weighing display; The centralized feature recognition is performed on the multiple historical verification keys to generate a centralized feature set of keys, including: Using a key feature identifier to perform feature identification on the multiple historical verification keys to obtain multiple historical verification key feature sets; Constructing a centralized feature recognition space based on the multiple historical verification key feature sets, wherein the centralized feature recognition space includes multiple particle points, wherein each particle point corresponds to a historical verification key feature set; Randomly extracting a first particle point from the concentrated feature recognition space as a recognition starting point, iteratively updating the first particle point in the concentrated feature recognition space according to a preset recognition step length until a preset iteration stop condition is met, thereby obtaining a target particle point; The historical verification key feature set corresponding to the target particle point is used as the key concentration feature set.

2. The electronic scale data encryption protection method based on the security encryption chip according to claim 1 is characterized in that: The first encryption constraint condition is that the similarity between the real-time key feature set of the real-time verification key and the feature set in the key set is lower than a preset similarity threshold.

3. The electronic scale data encryption protection method based on the security encryption chip according to claim 1 is characterized in that: Randomly extracting a first particle point from the concentrated feature recognition space as a recognition starting point, iteratively updating the first particle point in the concentrated feature recognition space according to a preset recognition step length until a preset iteration stop condition is met, and obtaining a target particle point, including: Taking the first particle point as the recognition starting point, iterating in the concentrated feature recognition space according to a preset recognition step length and a random iteration direction to obtain a first iterative particle point; When the first aggregation amount of the first particle point is less than or equal to the first iterative aggregation amount of the first iterative particle point, updating the first iterative particle point as the identification starting point; The first iterative particle point is randomly iterated in the concentrated feature recognition space according to a preset recognition step size in a random iteration direction until a preset iteration stop condition is met to obtain the target particle point, wherein the preset iteration stop condition is that the difference in iterative aggregation amount between two adjacent iterations is less than or equal to a preset iterative aggregation amount difference.

4. The electronic scale data encryption protection method based on the security encryption chip as claimed in claim 3 is characterized in that: include: When the first aggregation amount of the first particle point is greater than the first iterative aggregation amount of the first iterative particle point, calling the rand function to randomly generate a first value and a second value; When the first value is greater than or equal to the second value, the random iteration direction of the first iteration particle point is added to the taboo iteration direction table, and the first particle point is used as the recognition starting point, and the concentrated feature recognition space is iterated according to the preset recognition step length and the random iteration direction other than the taboo iteration direction table until the preset iteration stop condition is met, and the target particle point is obtained, wherein the taboo iteration direction table has a preset iteration; When the first value is less than the second value, the first iterative particle point is accepted as the identification starting point for iterative update, and in the next iteration, the opposite direction of the random iteration direction of the first iterative particle point is obtained as the random iteration direction until the preset iteration stop condition is met to obtain the target particle point.

5. The electronic scale data encryption protection method based on the security encryption chip according to claim 1, characterized in that: include: Using the key feature identifier to perform feature identification on the initial verification key to obtain an initial verification key feature set; Calculate the similarity between the initial verification key feature set and the feature set in the key set using the cosine similarity formula to obtain an initial similarity; When the initial similarity is greater than a preset similarity threshold in the first encryption constraint condition, the difference between the initial similarity and the preset similarity threshold is divided by the preset similarity threshold to obtain a first verification adjustment coefficient; The initial verification key is subjected to constraint adjustment and optimization according to the first verification adjustment coefficient and the first encryption constraint condition until a preset number of adjustments is met to obtain the real-time verification key.

6. The electronic scale data encryption protection method based on the security encryption chip as claimed in claim 5, characterized in that: include: Using a key adjustment network layer to identify the check adjustment coefficient and the initial check key to obtain a first adjustment check key; Determine whether the similarity between the first adjustment key feature set of the first adjustment verification key and the feature set in the key set satisfies the first encryption constraint condition, and if not, obtain a second verification adjustment coefficient; Based on the second verification adjustment coefficient and the first encryption constraint condition, the first adjustment verification key is constrained and optimized until a preset number of adjustments is met to obtain the real-time verification key.

7. An electronic scale data encryption protection device based on a security encryption chip, characterized in that: The steps for implementing the electronic scale data encryption protection method based on the security encryption chip according to any one of claims 1 to 6, the electronic scale data encryption protection device based on the security encryption chip comprises: A historical data acquisition module, the historical data acquisition module is used to obtain a plurality of historical encrypted data of the target electronic scale in a preset historical window, wherein the plurality of historical encrypted data includes a plurality of historical verification keys; A constraint condition construction module, the constraint condition construction module is used to perform centralized feature recognition on the multiple historical verification keys, generate a centralized feature set of keys, and construct a first encryption constraint condition based on the centralized feature set of keys; An initial encryption module, the initial encryption module is used to collect real-time monitoring data of the weight sensor of the target electronic scale, and use a security encryption chip to initially encrypt the real-time monitoring data to obtain initial encrypted monitoring data, wherein the initial encrypted monitoring data includes an initial key; A verification key optimization module, the verification key optimization module is used to obtain an initial verification key, and perform constraint adjustment and optimization on the initial verification key based on the first encryption constraint condition until a preset number of adjustments is met to obtain a real-time verification key; A data verification module, the data verification module is used to verify the initial encrypted monitoring data using the real-time verification key to obtain real-time encrypted monitoring data; The data transmission module is used to send the real-time encrypted monitoring data to the cloud big data platform and the merchant mobile service terminal for data supervision and weighing display.

Citation Information

Patent Citations

  • Intelligent data encryption method and system

    CN116436601A