Data verification
The additive decomposition of data into independent pieces using a linear congruential generation function addresses security and efficiency issues in key verification, ensuring secure and fast error detection without exposing the data.
Patent Information
- Application Number
- FR2023002830
- Authority / Receiving Office
- FR · FR
- Patent Type
- Applications
- Current Assignee / Owner
- Filing Date
- 2023-03-24
- Publication Date
- 2024-09-27
AI Technical Summary
Existing methods for verifying and detecting errors in encryption and decryption keys are inadequate in terms of security and efficiency, often making the data accessible during the verification process.
A method involving additive decomposition of data into N independent pieces, using a linear congruential generation function to verify equality among these pieces without storing the original data, ensuring secure and fast error detection.
The method provides secure and efficient verification of encryption and decryption keys, minimizing data accessibility risks while reducing computational time and resource usage.
Smart Images

Figure 00000000_0000_ABST
Abstract
Description
Title of the invention: Verification of data Technical field
[0001] The present description relates generally to the processing of sensitive and / or secret data, and, more particularly, to the security of the processing of such data. The present description relates more to the verification and error detection of such data, such as an encryption and / or decryption key. Prior art
[0002] Various techniques for securing secret and / or sensitive data are used today. Data encryption is one of them, and consists of applying one or more cryptographic algorithms to data. Many cryptographic algorithms use encryption and / or decryption keys.
[0003] Before using an encryption and / or decryption key, it is common to check whether the encryption key stored in memory is correct, i.e. does not contain any errors.
[0004] It would be desirable to be able to improve at least in part certain aspects of the error verification and / or detection methods. Summary of the invention
[0005] There is a need for more effective security of sensitive and / or secret data.
[0006] There is a need for more effective encryption and / or decryption key security.
[0007] One embodiment overcomes all or part of the drawbacks of the methods for verifying and / or detecting errors in data.
[0008] One embodiment provides a more secure method for verifying and / or detecting errors in data.
[0009] One embodiment provides a method for verifying and / or detecting errors in data that does not make said data accessible.
[0010] One embodiment provides a method for verifying and / or detecting errors in data having an additive decomposition.
[0011] One embodiment provides a method for verifying and / or detecting errors in data that is faster to execute.
[0012] An embodiment provides a method for verifying a first data item equal to the sum, modulo the dimension of a space comprising said first data item, of N second data items independent of the first data item, N being an integer, comprising a step of verifying (404) a first equality among the N second equalities given by the following mathematical formula: [Math 1] LCG(k) = ^j*LCG(Mk) + E^LCG(Xï) )m <W( / H)dans laQuelle : - LCG( ) represents the image of a data by a linear congruential generation function; - Xi represents one of said at least second data, i varying from 1 to N; - N represents the number of said at least two second data; - mod( ) represents the modulo operand; - m represents the modulus of said function; - j is an integer ranging from 0 to N-1; and - in which Mk represents the image of said dimension by said function
[0013] Another embodiment provides an electronic device adapted to implement a method for verifying a first data item equal to the sum, modulo the dimension of a space comprising said first data item, of N second data items independent of the first data item, N being an integer, comprising a step of verifying a first equality among the N second equalities given by the following mathematical formula: [Math 2] LCG(k) = ( j*LCG(Mk} + Y^lLCG(Xi) )mod(mj in the0uelle : - LCG( ) represents the image of a data by a linear congruential generation function; - Xi represents one of said at least second data, i varying from 1 to N; - N represents the number of said at least two second data; - mod( ) represents the modulo operand; - m represents the modulus of said function; - j is an integer ranging from 0 to N-1; and - in which Mk represents the image of said dimension by said function.
[0014] According to one embodiment, the first data is not stored in memory, the image of the first data by the function is stored in memory, and said N second data are stored in memory.
[0015] According to one embodiment, at least one of said N second data is obtained randomly.
[0016] According to one embodiment, said dimension is a prime number.
[0017] According to one embodiment, the linear congruential generation function is defined by the following mathematical formula: [Math 3] LCG: Z LCG (Z) = (a*Z) mod(m) in which: - Z is a data; - a is the multiplier of said first function; and - * represents the multiplication operation.
[0018] According to one embodiment, to calculate the image of a variable by the function, the following successive steps are implemented: - decomposition of said variable into a polynomial; - application of said function to said polynomial.
[0019] According to one embodiment, the image of a radical of said polynomial by said function has already been calculated previously.
[0020] According to one embodiment, the integer N is greater than or equal to two.
[0021] According to one embodiment, the first data is an encryption key and / or decryption.
[0022] According to one embodiment, said first data is secret data that can be used in different types of cryptography algorithms such as elliptic curve cryptography algorithms, RSA encryption, signature algorithms such as those known under the trade name CRYSTALS-Dilithium, or key encapsulation algorithms known under the trade name CRYSTALS-Kyber. Brief description of the drawings
[0023] These characteristics and advantages, as well as others, will be explained in detail in the following description of particular embodiments given without limitation in relation to the attached figures among which:
[0024] [Fig.l] represents, very schematically and in the form of blocks, an example of an electronic device adapted to implement the embodiments described in relation to figures 2 to 4;
[0025] [Fig.2] represents, very schematically and in the form of blocks, an example of arithmetic decomposition of a data item;
[0026] [Fig.3] represents, very schematically and in the form of blocks, a linear congruential generation function; and
[0027] [Fig.4] represents a block diagram illustrating an embodiment of a method for verifying an encryption and / or decryption key. Description of the embodiments
[0028] The same elements have been designated by the same references in the different figures. In particular, the structural and / or functional elements common to the different embodiments may have the same references and may have identical structural, dimensional and material properties.
[0029] For the sake of clarity, only the steps and elements useful for understanding the described embodiments have been shown and are detailed.
[0030] Unless otherwise specified, when referring to two elements connected to each other, this means directly connected without intermediate elements other than conductors, and when referring to two elements connected (in English "coupled") to each other, this means that these two elements can be connected or be connected by means of one or more other elements.
[0031] In the following description, when reference is made to absolute position qualifiers, such as the terms "front", "back", "top", "bottom", "left", "right", etc., or relative position qualifiers, such as the terms "above", "below", "upper", "lower", etc., or to orientation qualifiers, such as the terms "horizontal", "vertical", etc., reference is made unless otherwise specified to the orientation of the figures.
[0032] Unless otherwise specified, the expressions "about", "approximately", "substantially", and "of the order of" mean to within 10%, preferably to within 5%.
[0033] The embodiments described below relate to the verification and / or error detection of data, for example, before its use or storage in memory. More specifically, this concerns the verification and / or error detection of sensitive and / or secret data, such as an encryption and / or decryption key.
[0034] The embodiments described below relate, more particularly, to a cyclic redundancy checking method, or verification method, in which the data being verified is never made accessible. For this, the verification method uses a decomposition of this data into several data and a linear congruential generation (LCG) function. The type of decomposition used here is an additive decomposition. This is described in detail in relation to [Fig.2]. In addition, a detailed description of a linear congruential generation function is provided in relation to [Fig.3]. The verification method itself is described in relation to [Fig.4].
[0035] [Fig.l] is a block diagram representing, very schematically, an architecture of an example of an electronic device 100 adapted to execute the mode of implementation of the cyclic redundancy control method, or verification method, of a data item described below.
[0036] The electronic device 100 comprises a processor 101 (CPU) adapted to implement different processing of data stored in memories and / or provided by other circuits of the device 100.
[0037] The electronic device 100 further comprises different types of memories 102 (MEM), including, for example, a non-volatile memory, a volatile memory 103, and / or a read-only memory 104. Each memory 102 is adapted to store different types of data.
[0038] The electronic device 100 further comprises, for example, a secure element 103 (SE) adapted to process sensitive and / or secret data. The secure element 103 may comprise its own processor(s), its own memory(s), etc.
[0039] In the remainder of the description, sensitive data and secret data are data whose content is not intended to be public, and therefore whose access is restricted to certain people and / or particular circuits. An encryption and / or decryption key is considered to be sensitive and / or secret data since such a key makes it possible to encode sensitive and / or secret data, and / or to decode encrypted data.
[0040] The electronic device 100 may further comprise interface circuits 104 (IO / OUT) adapted to send and / or receive data originating from outside the device 100. The interface circuits 104 may further be adapted to implement a data display, for example, a display screen.
[0041] The electronic device 100 further comprises different circuits 105 (FCT) adapted to perform different functions. For example, the circuits 105 may comprise measurement circuits, data conversion circuits, etc.
[0042] The electronic device 100 further comprises one or more data buses 106 adapted to transfer data between its different components.
[0043] [Fig.2] illustrates, very schematically and in the form of blocks, an example of additive decomposition of a data item 200 (k).
[0044] The data 200, called data k in the remainder of the description, is data forming part of a space of dimension Mk. According to a preferred embodiment, the dimension Mk is a prime number. The data k may be, for example, sensitive and / or secret data adapted to be used by a device of the type of the device 100 described in relation to [Fig.l]. According to one embodiment, the data k is an encryption and / or decryption key. According to a particular embodiment, the data k is an encryption and / or decryption key, and more precisely an elliptic curve cryptography key, the integer Mk represents the field of the elliptic curve by which the data k is obtained.
[0045] According to one embodiment, the data k is not stored in a conventional manner in a memory of the electronic device, but is decomposed into N data 201-1 (XI), ..., 201-N (XN) which are themselves stored in one or more memories of the electronic device. This type of decomposition is called additive decomposition, since the sum, modulo Mk, of the N data 201-1 to 201-N is equal to the data k. According to one embodiment, N is an integer greater than or equal to one. According to a preferred embodiment, N is an integer greater than or equal to two.
[0046] In other words, the data k is given by the following mathematical formula A: [Math 4] = mod(MkVans la9ueUe • 1 / y J - the data Xi represents the data 201-1, ..., to 201-N; and - mod( ) represents the operator expressing congruence, also called the modulo operator.
[0047] Thus according to a first example, if N is equal to two, then: [Math 5] Æ = Xl + X2Ou [Math 6] k — Xl+X2-Mk
[0048] Thus according to a second example, if N is equal to three, then: [Math 7] Æ = Xl + X2 + X3ou [Math 8] k = XI + X2 + X3 - MÆOu [Math 9] k = X1 + X2 + X3 - 2 *Mk
[0049] According to one embodiment, the data 201-1 to 201-N, hereinafter called data XI to XN, are all independent of the data k. In other words, the data XI to XN are only linked to the data k by the mathematical formula A given previously, that is to say the sum of the data XI to XN.
[0050] According to an example, the decomposition of the data k is obtained by using a random data generation function. Nl data XI to XN-1 are, for example, randomly generated, and the last data XN is obtained by applying the formula A.
[0051] There are a multitude of possible additive decompositions for a data item. It is therefore possible to change the decomposition data, for example if the data XI, ..., XN have become accessible. It is sufficient, for example, to generate Nl new random data and to determine the last one by applying the formula A.
[0052] [Fig.3] illustrates, very schematically and in the form of blocks, a mode of implementation of a function 300 (LGC).
[0053] The function 300 is a linear congruential generation function, or linear congruential generator 300, adapted to receive, as input, a data item X and to provide, as output, a data item LCG(X) whose expression is dependent on two parameters a and m. The parameter a is called the multiplier of the function 300. The parameter m is called the modulus of the function 300. According to an example, the parameters a and m are integers.
[0054] The data LCG(X) is given by the following mathematical formula: [Math 10] LCG(X) = (a*X) JWfZ( / n) in which * represents the multiplication operator.
[0055] A function of the type of function 300 is generally used in random number generators. The person skilled in the art will know how to choose appropriate values of the parameters a and m so as to optimize the characteristics of function 300. Examples of optimized values of these parameters are given in the article entitled "Tables of linear congruential generators of different sizes and good lattice structure" by Pierre L'Ecuyer, published in January 1999 in the magazine Mathematics of Computation.
[0056] According to one embodiment, to minimize the calculation times and resources of a device executing the function 300, it is possible to use a polynomial decomposition of a data item to calculate its image more quickly by the function 300.
[0057] According to an example, if we consider a data D, or variable D, belonging to a space of dimension L, and its decomposition into a polynomial of rank P, P being an integer, of radical r, and of coefficients dO, dl, ..., dP-1. The data D is therefore given by the following mathematical formula: [Math 11] D = modQ
[0058] The image LCG(D) of the data D by the function 300 is given by the following mathematical formula: [Math 12] LCG(D) =
[0059] To optimize the calculation time of the LCG(D) image, it is sufficient to record, beforehand, the values of the LCG(ri) images, j being an integer varying from 0 to P-1.
[0060] [Fig.4] is a block diagram representing a mode of implementation of a cyclic redundancy control method, or method of verifying the data k defined in relation to [Fig.2] and using the function 300 described in relation to [Fig.3].
[0061] The method for verifying the data k is a cyclic redundancy control method for detecting transmission, combination and / or algorithm application errors.
[0062] This verification method is suitable for being implemented by the device 100 described in relation to [Fig.l], or by a device of the type of device 100.
[0063] In an initialization step 401 (LCG(k)), a data item LCG(k) representing the image of the data item k by the function 300 is obtained. According to one embodiment, the image LCG(k) is calculated and stored in a memory of the device 100, but the data item k itself is not stored in memory. This step can be implemented as soon as the data k is generated. An example of a technique for calculating the data LCG(k) is described in relation to [Fig.3].
[0064] In another initialization step 402 (XI, ..., XN), the decomposition of the data k into the data XI to XN is obtained, for example, using the technique described in relation to [Fig. 2]. According to one embodiment, the data XI to XN are all stored in one or more memories of the device 100. This step can also be implemented as soon as the data k is generated.
[0065] At a step 403 (LCG(Xl), ..., LCG(XN)), subsequent to step 402, data LCG(Xl) to LCG(XN) representing the images of the data XI to XN by the function 300 are obtained. According to one embodiment, the images LCG(Xl) to LCG(XN) are calculated and stored in a memory of the device 100. This step can be implemented as soon as the data k is generated, like step 402.
[0066] At a step 404 (Bj), subsequent to steps 401 and 403, N second equalities Bj, j being an integer varying from 0 to N-1, are verified. Each equality Bj is given by the following mathematical formula: [Math 13] (Bj): LCG(k) = ^LCG(Mk) + ^LCGiXi) ) mod\m\
[0067] To perform these checks, the data obtained in steps 401 to 403 are used.
[0068] If one of the equalities Bj is verified (output Y) then the next step is a step 405 (Success). Otherwise (output N), the next step is a step 406 (Error).
[0069] In practice, step 404 can be implemented iteratively, by incrementing the integer j by one. More particularly, step 404 begins with the verification of equality B0, if this is not verified, then equality B1 is verified and so on.
[0070] At step 405, one of the equalities Bj has been verified, it is therefore considered that the data XI to XN are correct and allow the data k to be obtained. The data XI to XN can be used instead of the data k in all linear operations with respect to the sum modulo Mk.
[0071] At step 406, none of the equalities Bj have been verified. The decomposition of the data k into the data XI to XN therefore presents errors, and the data XI to XN cannot therefore be used to obtain the data k.
[0072] An advantage of this verification method is that it is faster to implement than a conventional cyclic redundancy checking method.
[0073] Another advantage of this method is that the risk of making the data k accessible is much lower than with a conventional cyclic redundancy method. Indeed, the data k is not stored in memory, and data XI to XN are all independent of data k. Therefore, all data XI to XN would need to be accessed to obtain data k.
[0074] Yet another advantage of this method is that it can be used in devices implementing different types of cryptographic algorithms such as elliptic curve cryptographic algorithms, RSA encryption, signature algorithms such as those known under the trade name CRYSTALS-Dilithium, or key encapsulation algorithms known under the trade name CRYSTALS-Kyber. Thus, the data K can be secret data used in any of the algorithms mentioned above.
[0075] Various embodiments and variations have been described. Those skilled in the art will understand that certain features of these various embodiments and variations could be combined, and other variations will occur to those skilled in the art.
[0076] Finally, the practical implementation of the embodiments and variants described is within the reach of those skilled in the art from the functional indications given above.
Claims
Claims
1. Verification method, implemented by a processor of an electronic device further comprising a memory, of a first data item (k) equal to the sum, modulo the dimension (Mk) of a space comprising said first data item (k), of N second data items (XI, ..., XN) independent of the first data (k), N being an integer, comprising a step of verifying (404) a first equality (Bj) among the N second equalities given by the following mathematical formula: [Math 14] LCG(k) = ( j*LCG(Mk}+ L^LCG(Xi) )mod(m) in which: - LCG( ) represents the image of a data by a linear congruential generation function (300); - Xi represents one of said at least second data, i varying from 1 to N; - N represents the number of said at least two second data; - mod( ) represents the modulo operand; - m represents the modulo of said function (300); - j is an integer varying from 0 to N-1; and - in which Mk represents the image of said dimension (Mk) by said function (300).
2. The method of claim 1, wherein the first data (k) is not stored in said memory, the image of the first data (k) by the function (300) is stored in said memory, and said N second data (XI, ..., XN) are stored in said memory.
3. Method according to claim 1 or 2, wherein at least one of said N second data (XI, ..., XN) is obtained randomly.
4. A method according to any one of claims 1 to 3, wherein said dimension (Mk) is a prime number.
5. Method according to any one of claims 1 to 4, in which the linear congruential generation function (300) is defined by the following mathematical formula: [Math 16] LCG:Z~* LCG (Z') = (a*Z) »wxZ(m) in which: - Z is a data; - a is the multiplier of said first function (300); and - * represents the multiplication operation.
6. Method according to any one of claims 1 to 5, in which to calculate the image of a variable by the function (300), the following successive steps are implemented: - decomposition of said variable into a polynomial; - application of said function (300) to said polynomial.
7. Method according to claim 6, wherein the image of a radical (r) of said polynomial by said function (300) has already been calculated previously.
8. A method according to any one of claims 1 to 7, wherein the integer N is greater than or equal to two.
9. Method according to any one of claims 1 to 8, in which the first data (k) is an encryption and / or decryption key.
10. Method according to any one of claims 1 to 9, wherein said first data (k) is a secret data which can be used in different types of cryptography algorithms such as elliptic curve cryptography algorithms, RSA encryption, signature algorithms such as those known under the trade name CRYSTALS-Dilithium, or key encapsulation algorithms known under the trade name CRYSTALS-Kyber.
11. Electronic device, comprising a processor and a memory, the processor being adapted to implement a method for verifying a first data item (k) equal to the sum, modulo the dimension (Mk) of a space comprising said first data item (k), of N second data items (XI, ..., XN) independent of the first data item (k), N being an integer, comprising a step of verifying (404) a first equality (Bj) among the N second equalities given by the following mathematical formula: [Math 15] LCG(k) = ( j*LCG(Mk)}mod(mj in which: - LCG( ) represents the image of a data item by a linear congruential generation function (300); - Xi represents one of said at least second data items, i varying from 1 to N; - N represents the number of said at least two second data items; - mod( ) represents the modulo operand; - m represents the modulus of said function (300); - j is an integer ranging from 0 to N-1; and - in which Mk represents the image of said dimension (Mk) by said function (300).
Citation Information
Patent Citations
Cryptographic device with updatable shared matrix
EP3698513B1
