Commercial access control encryption method and system based on Hamming code coding and multi-layer encryption

CN119299128APending Publication Date: 2025-01-10CHINA LIFE INSURANCE CO LTD SHANGHAI BRANCH
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202411249528.2
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-09-06
Publication Date
2025-01-10

AI Technical Summary

Technical Problem

[0003]数据易泄露:传统二维码直接将用户信息明文展示,容易被破解,导致用户信息泄露

Benefits of technology

[0044] 1. The present invention adopts multi-layer encryption technology, including asymmetric encryption, symmetric encryption and Hamming code encoding, which effectively improves the security of the access control system and prevents malicious attacks and information leakage;

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119299128A_ABST
    Figure CN119299128A_ABST
Patent Text Reader

Abstract

The invention provides a commercial access control encryption method and system based on Hamming code coding and multilayer encryption, and the method comprises the steps: encrypting the identity information of a user through employing an asymmetric encryption method, and obtaining the encrypted user information; symmetrically encrypting the encrypted user information to generate final encrypted data; performing Hamming code encoding on the final encrypted data to generate encoded data; the coded data is converted into a Data Matrix code image, and the access control system obtains the coded data by scanning the Data Matrix code image. By combining asymmetric encryption, symmetric encryption and Hamming code coding, the security of the access control system is effectively improved, the data confidentiality and integrity are enhanced, and the interoperability between access control systems of different brands is realized.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the field of security technology, and in particular to a commercial access control encryption method and system based on Hamming code encoding and multi-layer encryption. Background Art

[0002] Traditional access control systems usually use QR codes or simple encryption methods to verify user identities, which have the following shortcomings:

[0003] Data is easy to leak: Traditional QR codes directly display user information in plain text, which can be easily cracked, leading to user information leakage.

[0004] Insufficient security: Simple encryption methods are easy to crack and cannot effectively prevent malicious attacks.

[0005] Poor interoperability: Access control systems of different brands use different encryption algorithms and encoding methods, making it impossible to achieve interoperability.

[0006] Even though some access control systems based on encryption technology have emerged in the existing technology, there are still some problems, including: High complexity of encryption algorithms: Some encryption algorithms are too complex and difficult to implement and maintain. Low encryption efficiency: Some encryption algorithms are inefficient, resulting in poor user experience. Insufficient security performance: Some encryption algorithms have security vulnerabilities and are easily attacked. Summary of the invention

[0007] In view of the defects in the prior art, the object of the present invention is to provide a commercial access control encryption method and system based on Hamming code encoding and multi-layer encryption.

[0008] The first aspect of the present invention provides a commercial access control encryption method based on Hamming code encoding and multi-layer encryption, comprising:

[0009] An asymmetric encryption method is used to encrypt the user's identity information to obtain encrypted user information;

[0010] Symmetrically encrypt the encrypted user information to generate the final encrypted data;

[0011] Perform Hamming code encoding on the final encrypted data to generate encoded data;

[0012] The encoded data is converted into a Data Matri ix code image, and the access control system obtains the encoded data by scanning the Data Matri ix code image.

[0013] Optionally, in a first implementation of the first aspect of the present invention, before encrypting the user's identity information using an asymmetric encryption method to obtain the encrypted user information, the method further includes: obtaining the user's identity information, including: user ID, name, and password;

[0014] The user's identity information is encrypted using an asymmetric encryption method to obtain encrypted user information, including:

[0015] A pair of keys is generated using an asymmetric encryption method; the generated public key is used to encrypt the user's identity information to obtain the encrypted user information.

[0016] Optionally, in a second implementation of the first aspect of the present invention, symmetrically encrypting the encrypted user information to generate final encrypted data includes:

[0017] Get the current timestamp, device ID and random number to generate a temporary key;

[0018] Combine the current timestamp, device ID and random number to generate a string;

[0019] Use the hash function to hash the generated string to obtain a temporary key;

[0020] The encrypted user information is symmetrically encrypted using a temporary key to generate the final encrypted data.

[0021] Optionally, in a third implementation of the first aspect of the present invention, the method further includes: performing Hamming code decoding on the encoded data to obtain final encrypted data; decrypting the final encrypted data, and if the decryption is successful, the verification is passed and the user is allowed to pass.

[0022] Optionally, in a fourth implementation of the first aspect of the present invention, decrypting the final encrypted data includes:

[0023] Get the current timestamp and device ID;

[0024] According to the current timestamp and device ID obtained, a hash function or a symmetric encryption algorithm is used to process and obtain a temporary key;

[0025] The final encrypted data is decrypted using the temporary key.

[0026] The second aspect of the present invention provides a commercial access control encryption system based on Hamming code encoding and multi-layer encryption, characterized in that it includes:

[0027] An asymmetric encryption module is used to encrypt the user's identity information using an asymmetric encryption method to obtain encrypted user information;

[0028] The symmetric encryption module is used to symmetrically encrypt the encrypted user information to generate the final encrypted data;

[0029] A Hamming code encoding module, used for performing Hamming code encoding on the final encrypted data to generate encoded data;

[0030] The Data Matri ix code image acquisition module is used to convert the encoded data into a Data Matri ix code image. The access control system obtains the encoded data by scanning the Data Matri ix code image.

[0031] Optionally, in a first implementation of the second aspect of the present invention, before the asymmetric encryption module, the system further includes: obtaining identity information of the user, including: user ID, name, password;

[0032] The asymmetric encryption module comprises: using an asymmetric encryption method to generate a pair of keys; using the generated public key to encrypt the user's identity information to obtain the encrypted user information.

[0033] Optionally, in a second implementation of the second aspect of the present invention, the symmetric encryption module includes:

[0034] Get the current timestamp, device ID and random number to generate a temporary key;

[0035] Combine the current timestamp, device ID and random number to generate a string;

[0036] Use the hash function to hash the generated string to obtain a temporary key;

[0037] The encrypted user information is symmetrically encrypted using a temporary key to generate the final encrypted data.

[0038] Optionally, in a third implementation of the second aspect of the present invention, the system further includes: a decryption module, used to perform Hamming code decoding on the encoded data to obtain final encrypted data; decrypt the final encrypted data, and if the decryption is successful, the verification is passed and the user is allowed to pass.

[0039] Optionally, in a fourth implementation of the second aspect of the present invention, decrypting the final encrypted data includes:

[0040] Get the current timestamp and device ID;

[0041] According to the current timestamp and device ID obtained, a hash function or a symmetric encryption algorithm is used to process and obtain a temporary key;

[0042] The final encrypted data is decrypted using the temporary key.

[0043] Compared with the prior art, the present invention has the following beneficial effects:

[0044] 1. The present invention adopts multi-layer encryption technology, including asymmetric encryption, symmetric encryption and Hamming code encoding, which effectively improves the security of the access control system and prevents malicious attacks and information leakage;

[0045] 2. The present invention adopts a unified encryption algorithm and encoding method, which can achieve interoperability between access control systems of different brands;

[0046] 3. The present invention adopts standard encryption algorithm and encoding method, which is easy to maintain and update;

[0047] 4. The present invention adopts Data Matri ix code image, which is convenient for users to scan quickly and improve user experience;

[0048] 4. The present invention provides a special processing encryption method for a commercial Hamming code access control algorithm. This method effectively improves the security of the access control system by combining asymmetric encryption, symmetric encryption and Hamming code encoding, while enhancing data confidentiality and integrity, and achieving interoperability between access control systems of different brands. BRIEF DESCRIPTION OF THE DRAWINGS

[0049] Other features, objects and advantages of the present invention will become more apparent from the detailed description of non-limiting embodiments made with reference to the following drawings:

[0050] Figure 1 A first flow chart of a commercial access control encryption method based on Hamming code encoding and multi-layer encryption provided by an embodiment of the present invention;

[0051] Figure 2 A second flow chart of a commercial access control encryption method based on Hamming code encoding and multi-layer encryption provided by an embodiment of the present invention;

[0052] Figure 3 A third flow chart of a commercial access control encryption method based on Hamming code encoding and multi-layer encryption provided by an embodiment of the present invention;

[0053] Figure 4 A schematic diagram of the structure of a commercial access control encryption system based on Hamming code encoding and multi-layer encryption provided by an embodiment of the present invention;

[0054] Figure 5 A schematic diagram of the structure of an electronic device provided by an embodiment of the present invention. DETAILED DESCRIPTION

[0055] The embodiment of the present invention provides a commercial access control encryption method and system based on Hamming code encoding and multi-layer encryption, which uses an asymmetric encryption method to encrypt the user's identity information to obtain the encrypted user information; symmetric encryption is performed on the encrypted user information to generate the final encrypted data; the final encrypted data is encoded by Hamming code to generate the encoded data; the encoded data is converted into a Data Matrix code image, and the access control system obtains the encoded data by scanning the Data Matrix code image. The encoded data is decoded by Hamming code to obtain the final encrypted data; the current timestamp and device ID are obtained; according to the obtained current timestamp and device ID, a hash function or a symmetric encryption algorithm is used to process to obtain a temporary key; the final encrypted data is decrypted using the temporary key, and if the decryption is successful, the verification is passed, and the user is allowed to pass. The present invention solves the problems in the prior art that the price list algorithm is highly complex, difficult to implement and maintain, has low encryption efficiency, poor user experience, insufficient security performance, and is easy to be attacked.

[0056] The terms "first", "second", "third", "fourth", etc. (if any) in the specification and claims of the present invention and the above-mentioned drawings are used to distinguish similar objects, and are not necessarily used to describe a specific order or sequence. It should be understood that the data used in this way can be interchanged where appropriate, so that the embodiments described herein can be implemented in an order other than that illustrated or described herein. In addition, the terms "including" or "having" and any variations thereof are intended to cover non-exclusive inclusions, for example, a process, method, system, product or device that includes a series of steps or units is not necessarily limited to those steps or units that are clearly listed, but may include other steps or units that are not clearly listed or inherent to these processes, methods, products or devices.

[0057] For ease of understanding, the specific process of the embodiment of the present invention is described below. Figure 1 The first embodiment of the commercial access control encryption method based on Hamming code encoding and multi-layer encryption in the embodiment of the present invention includes:

[0058] 101. Encrypt the user's identity information using an asymmetric encryption method to obtain encrypted user information;

[0059] In this embodiment, before the user's identity information is encrypted using an asymmetric encryption method and the encrypted user information is obtained, the user's identity information is obtained, including: user ID, name, and password;

[0060] A pair of keys is generated using an asymmetric encryption method; the generated public key is used to encrypt the user's identity information to obtain the encrypted user information.

[0061] 102. Perform symmetric encryption on the encrypted user information to generate final encrypted data;

[0062] In this embodiment, the current timestamp, device ID and random number are first obtained to generate a temporary key; the obtained current timestamp, device ID and random number are then combined to generate a string; the generated string is hashed using a hash function to obtain a temporary key; finally, the encrypted user information is symmetrically encrypted using the temporary key to generate the final encrypted data.

[0063] 103. Perform Hamming code encoding on the final encrypted data to generate encoded data;

[0064] 104. Convert the encoded data into a Data Matrix code image, and the access control system obtains the encoded data by scanning the Data Matrix code image.

[0065] This embodiment effectively improves the security of the access control system by combining asymmetric encryption, symmetric encryption and Hamming code encoding, while enhancing data confidentiality and integrity, and achieving interoperability between access control systems of different brands.

[0066] See also Figure 2 , the second embodiment of the commercial access control encryption method based on Hamming code encoding and multi-layer encryption in the embodiment of the present invention includes:

[0067] 201. Encrypt the user's identity information using an asymmetric encryption method to obtain encrypted user information;

[0068] 202. Perform symmetric encryption on the encrypted user information to generate final encrypted data;

[0069] 203. Perform Hamming code encoding on the final encrypted data to generate encoded data;

[0070] 204. Convert the encoded data into a Data Matrix code image, and the access control system obtains the encoded data by scanning the Data Matrix code image;

[0071] 205. Perform Hamming code decoding on the encoded data to obtain final encrypted data; decrypt the final encrypted data. If the decryption is successful, the verification is passed and the user is allowed to pass.

[0072] In this embodiment, the current timestamp and device ID are obtained;

[0073] According to the current timestamp and device ID obtained, a hash function or a symmetric encryption algorithm is used to process and obtain a temporary key;

[0074] The final encrypted data is decrypted using the temporary key.

[0075] This embodiment combines asymmetric encryption, symmetric encryption and Hamming code encoding technology in the access control system to achieve multiple encryption and improve security. At the same time, a temporary key mechanism is used to enhance data security and anti-tampering capabilities; Hamming code encoding is used to improve data reliability and hide encrypted data.

[0076] See also Figure 3 , a third embodiment of the commercial access control encryption method based on Hamming code encoding and multi-layer encryption in the embodiment of the present invention includes:

[0077] 301. The user logs into the access control system and enters the user ID and password;

[0078] 302. The system obtains the user ID and password, performs asymmetric encryption, and generates encrypted user information;

[0079] In this embodiment, asymmetric encryption includes RSA encryption algorithm or ECC elliptic curve encryption algorithm;

[0080] 303. The system obtains the current timestamp, device ID and random number, and generates a temporary key;

[0081] 304. The system uses the temporary key to symmetrically encrypt the encrypted user information to generate final encrypted data;

[0082] In this embodiment, the symmetric encryption includes AES encryption or ChaCha20 symmetric encryption algorithm;

[0083] 305. The system performs Hamming code encoding on the final encrypted data to generate encoded data;

[0084] In this embodiment, the Hamming code encoding includes an extended Hamming code;

[0085] 306. The system converts the encoded data into a Data Matri ix code image and displays it on the user's mobile phone screen;

[0086] 307. The user scans the Data Matri ix code image, and the access control system obtains the encoded data;

[0087] 308. The access control system decodes the encoded data using the Hamming code to obtain the final encrypted data;

[0088] 309. The access control system obtains the current timestamp and device ID and generates a set of possible temporary keys according to preset rules;

[0089] 310. The access control system uses each possible set of temporary keys to decrypt the final encrypted data. If the decryption is successful, the verification is passed and the user is allowed to pass.

[0090] The above describes the commercial access control encryption method based on Hamming code encoding and multi-layer encryption in the embodiment of the present invention. The following describes the commercial access control encryption system based on Hamming code encoding and multi-layer encryption in the embodiment of the present invention. Figure 4 In an embodiment of the present invention, an embodiment of a commercial access control encryption system based on Hamming code encoding and multi-layer encryption includes:

[0091] An asymmetric encryption module 401 is used to encrypt the user's identity information using an asymmetric encryption method to obtain encrypted user information;

[0092] In this embodiment, the asymmetric encryption module 401 includes: encrypting the user's identity information using an asymmetric encryption method to obtain the user's identity information before obtaining the encrypted user information, including: user ID, name, password;

[0093] Generate a pair of keys using an asymmetric encryption method; encrypt the user's identity information using the generated public key to obtain the encrypted user information;

[0094] Asymmetric encryption methods include: RSA encryption algorithm or ECC elliptic curve encryption algorithm;

[0095] Symmetric encryption module 402, used to symmetrically encrypt the encrypted user information to generate final encrypted data;

[0096] In this embodiment, the symmetric encryption module 402 includes: first obtaining the current timestamp, device ID and random number to generate a temporary key; then combining the obtained current timestamp, device ID and random number to generate a string; using a hash function to hash the generated string to obtain a temporary key; finally, using the temporary key to symmetric encrypt the encrypted user information to generate the final encrypted data.

[0097] Symmetric encryption includes AES encryption or ChaCha20 symmetric encryption algorithm;

[0098] The Hamming code encoding module 403 is used to perform Hamming code encoding on the final encrypted data to generate encoded data;

[0099] In this embodiment, the Hamming code encoding includes an extended Hamming code;

[0100] The Data Matrix code image acquisition module 404 is used to convert the encoded data into a Data Matrix code image. The access control system acquires the encoded data by scanning the Data Matrix code image.

[0101] The decryption module 405 is used to perform Hamming code decoding on the encoded data to obtain the final encrypted data; decrypt the final encrypted data, if the decryption is successful, the verification is passed and the user is allowed to pass;

[0102] In this embodiment, the decryption module 405 includes:

[0103] Get the current timestamp and device ID;

[0104] According to the current timestamp and device ID obtained, a hash function or a symmetric encryption algorithm is used to process and obtain a temporary key;

[0105] The final encrypted data is decrypted using the temporary key.

[0106] above Figure 4 The commercial access control encryption system based on Hamming code encoding and multi-layer encryption in the embodiment of the present invention is described in detail from the perspective of modular functional entities. The electronic device in the embodiment of the present invention is described in detail from the perspective of hardware processing.

[0107] Figure 5 7 is a schematic diagram of the structure of an electronic device provided by an embodiment of the present invention. The electronic device 700 may have relatively large differences due to different configurations or performances, and may include one or more processors (central processing unit, CPU) 710 (for example, one or more processors) and a memory 720, and one or more storage media 730 (for example, one or more mass storage devices) storing application programs 733 or data 732. Among them, the memory 720 and the storage medium 730 can be temporary storage or permanent storage. The program stored in the storage medium 730 may include one or more modules (not shown in the figure), and each module may include a series of instruction operations in the electronic device 700. Furthermore, the processor 710 may be configured to communicate with the storage medium 730 to execute a series of instruction operations in the storage medium 730 on the electronic device 700.

[0108] The electronic device 700 may also include one or more power supplies 740, one or more wired or wireless network interfaces 750, one or more input and output interfaces 750, and / or one or more operating systems 731, such as Windows Server, Mac OS X, Unix, Linux, FreeBSD, etc. It will be appreciated by those skilled in the art that Figure 5 The structure of the electronic device shown does not constitute a limitation on the electronic device, and may include more or less components than shown in the figure, or combine some components, or arrange the components differently.

[0109] The present invention also provides a computer-readable storage medium, which may be a non-volatile computer-readable storage medium or a volatile computer-readable storage medium. Instructions are stored in the computer-readable storage medium. When the instructions are executed on a computer, the computer executes the steps of a commercial access control encryption method based on Hamming code encoding and multi-layer encryption.

[0110] Those skilled in the art can clearly understand that, for the convenience and brevity of description, the specific working process of the above-described system, device, or unit can refer to the corresponding process in the aforementioned method embodiment and will not be repeated here.

[0111] If the integrated unit is implemented in the form of a software functional unit and sold or used as an independent product, it can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of the present invention, in essence, or the part that contributes to the prior art, or all or part of the technical solution can be embodied in the form of a software product, and the computer software product is stored in a storage medium, including a number of instructions for a computer device (which can be a personal computer, a server, or a network device, etc.) to perform all or part of the steps of the method described in each embodiment of the present invention. The aforementioned storage medium includes: U disk, mobile hard disk, read-only memory (ROM), random access memory (RAM), disk or optical disk, etc., various media that can store program codes.

[0112] As described above, the above embodiments are only used to illustrate the technical solutions of the present invention, rather than to limit the same. Although the present invention has been described in detail with reference to the aforementioned embodiments, those skilled in the art should understand that the technical solutions described in the aforementioned embodiments may still be modified, or some of the technical features thereof may be replaced by equivalents. However, these modifications or replacements do not deviate the essence of the corresponding technical solutions from the spirit and scope of the technical solutions of the embodiments of the present invention.

Claims

1. A commercial access control encryption method based on Hamming code encoding and multi-layer encryption, characterized in that: include: An asymmetric encryption method is used to encrypt the user's identity information to obtain encrypted user information; Symmetrically encrypt the encrypted user information to generate the final encrypted data; Perform Hamming code encoding on the final encrypted data to generate encoded data; The encoded data is converted into a Data Matrix code image, and the access control system obtains the encoded data by scanning the Data Matrix code image.

2. The commercial access control encryption method based on Hamming code encoding and multi-layer encryption according to claim 1 is characterized in that: Before the user's identity information is encrypted by the asymmetric encryption method to obtain the encrypted user information, the method further includes: obtaining the user's identity information, including: user ID, name, password; The user's identity information is encrypted using an asymmetric encryption method to obtain encrypted user information, including: A pair of keys is generated using an asymmetric encryption method; the generated public key is used to encrypt the user's identity information to obtain the encrypted user information.

3. The commercial access control encryption method based on Hamming code encoding and multi-layer encryption according to claim 1 is characterized in that: The encrypted user information is symmetrically encrypted to generate final encrypted data, including: Get the current timestamp, device ID and random number to generate a temporary key; Combine the current timestamp, device ID and random number to generate a string; Use the hash function to hash the generated string to obtain a temporary key; The encrypted user information is symmetrically encrypted using a temporary key to generate the final encrypted data.

4. The commercial access control encryption method based on Hamming code encoding and multi-layer encryption according to claim 1 is characterized in that: The method further comprises: performing Hamming code decoding on the encoded data to obtain final encrypted data; decrypting the final encrypted data, and if the decryption is successful, the verification is passed and the user is allowed to pass.

5. The commercial access control encryption method based on Hamming code encoding and multi-layer encryption according to claim 4 is characterized in that: The decrypting of the final encrypted data comprises: Get the current timestamp and device ID; According to the current timestamp and device ID obtained, a hash function or a symmetric encryption algorithm is used to process and obtain a temporary key; The final encrypted data is decrypted using the temporary key.

6. A commercial access control encryption system based on Hamming code encoding and multi-layer encryption, characterized in that: include: An asymmetric encryption module is used to encrypt the user's identity information using an asymmetric encryption method to obtain encrypted user information; The symmetric encryption module is used to symmetrically encrypt the encrypted user information to generate the final encrypted data; A Hamming code encoding module, used for performing Hamming code encoding on the final encrypted data to generate encoded data; The Data Matrix code image acquisition module is used to convert the encoded data into a Data Matrix code image. The access control system obtains the encoded data by scanning the Data Matrix code image.

7. The commercial access control encryption system based on Hamming code encoding and multi-layer encryption according to claim 6 is characterized in that: Before the asymmetric encryption module, the system further includes: obtaining the user's identity information, including: user ID, name, password; The asymmetric encryption module comprises: using an asymmetric encryption method to generate a pair of keys; using the generated public key to encrypt the user's identity information to obtain the encrypted user information.

8. The commercial access control encryption system based on Hamming code encoding and multi-layer encryption according to claim 6 is characterized in that: The symmetric encryption module comprises: Get the current timestamp, device ID and random number to generate a temporary key; Combine the current timestamp, device ID and random number to generate a string; Use the hash function to hash the generated string to obtain a temporary key; The encrypted user information is symmetrically encrypted using a temporary key to generate the final encrypted data.

9. The commercial access control encryption system based on Hamming code encoding and multi-layer encryption according to claim 6 is characterized in that: The system further comprises: a decryption module, which is used to perform Hamming code decoding on the encoded data to obtain final encrypted data; and decrypt the final encrypted data. If the decryption is successful, the verification is passed and the user is allowed to pass.

10. The commercial access control encryption system based on Hamming code encoding and multi-layer encryption according to claim 9 is characterized in that: The decrypting of the final encrypted data comprises: Get the current timestamp and device ID; According to the current timestamp and device ID obtained, a hash function or a symmetric encryption algorithm is used to process and obtain a temporary key; The final encrypted data is decrypted using the temporary key.