Abstract:
The protected method of cryptographic computation includes N computation rounds successively performed to produce an output data from an input data and a private key. The method also includes a first masking stage to mask the input data, so that each intermediate data used or produced by a computation round is masked, and a second masking stage to mask data manipulated inside each computation round.

Description:
FIELD OF THE INVENTION  
         [0001]    The present invention relates to a component and secured method for cryptographic computation with a secret or private key, and more particularly, to the protection of such components against physical attack which are designed to obtain information on the secret or private key through the power consumption or the electromagnetic radiation of the component when it implements the encryption method.  
         BACKGROUND OF THE INVENTION  
         [0002]    Components with strictly controlled access to the services and/or to the data typically have an architecture formed around the microprocessor and a program memory including the secret key. Such components are used for example in smart cards, especially for banking applications, via a control terminal or remote terminal. Such components use one or more secret key encryption or private key encryption methods to compute an output data from an input data. Such a method is used for example to encipher, decipher, authenticate or sign an input message or else verify the signature of the input message.  
           [0003]    To ensure the security of the transactions, the secret key or private key encryption methods are constructed in such a way that it is not possible to determine the secret key used from the knowledge of the input data and/or the output data of the algorithm. However, the security of a component relies on its capacity to keep the secret key that it uses concealed, for this key cannot be modified.  
           [0004]    One method frequently used is the DES (Data Encryption Standard) type method. This method can be used for example to give an enciphered message MS (or output data) encoded on 64 bits, from a plaintext message ME (or input data) also encoded on 64 bits, and a secret 56-bit key K 0 . The main steps of the DES are described in detail with reference to FIG. 1. After an initial permutation IP, the block formed by the permutated bits of the input data is separated into a left-hand part L 0  and a right-hand part R 0 .  
           [0005]    After this, 16 rounds of identical operations are performed. During each round of operations, the right-hand part (R 0 , . . . , R 15 ) of an intermediate data computed during the previous round of operations is combined with a derivative key (M 1 , . . . , M 16 ) during a transformation called a transformation F. The result of the transformation F is then added (XOR operation) to the left-hand part (L 0 , . . . , L 15 ) of the intermediate data computed during the previous round of operations.  
           [0006]    After the 16 th  round of operations, the left-hand part L 16  and right-hand part R 16  of the 16 th  intermediate data are assembled and a final permutation IP −1 , which is the inverse of the initial permutation IP, terminates the procedure. An i-ranking round of operations included between 1 and 16 is described in detail with reference to FIG. 2. The 56 bits of an intermediate key K i-1  computed during the previous round are shifted (operation S i ) to give a new updated intermediate key K i , then 48 bits out of 56 are selected by an operation PC of permutation/compression to provide a derived key M i . M i =PC(K i )=PC(S i (K i-1 )). The association of the steps PC and S i  forms a key computation step ET 2 .  
           [0007]    In parallel, the transformation F is carried out. The right-hand part R i-1  of a piece of intermediate data computed during the previous round is extended to 48 bits by an expansion (operation E), combined with the derived key M by an XOR type operation, replaced by 32 new bits by a substitution operation (represented by the operation SBOX), then permutated once again (operation P). In practice, the operations F, P, E, PC, SBOX are identical for all the rounds. On the contrary, the operations S 1  to S 16  used during the computation of the derived keys K 1  to K 16  are different from one round to another.  
           [0008]    All the characteristics of the operations IP, IP −1 , P, PC, E, SBOX, S i  performed during the implementation of a DES method are known: the computations made, the parameters used, etc. These characteristics are, for example, described in detail in the patent application WO 00/46953 or in the “Data Encryption Standard, FIPS PUB 46”, published on 15 th  Jan. 1977.  
           [0009]    The security of a component using a secret key or private key encryption method lies in its capacity to keep the key that it uses secret. To be secure, a component must be capable especially of keeping concealed the secret key that it uses when it undergoes a DPA (Differential Power Analysis) type analysis. In a DPA analysis, a statistical analysis is made of the consumption of the component, namely the trace left by the component as a function of time. For this purpose, a sample of about 1,000 measurements of traces is used, each trace corresponding to input data ME[i=1 to 1000] that are different and independent with respect to one another. The statistical study validates one or more assumptions made on the value of the bits of the secret key used.  
           [0010]    A specific example of the implementation of a DPA type analysis on a component using a DES type encryption method is described in detail in WO 00/46953, especially in pages 3, 4 of this publication. The DES type encryption method is especially vulnerable to the DPA type attacks at the output of the SBOX operators. More generally, an encryption method is vulnerable to a DPA type analysis at any point where the secret key appears in combination either with the input data or with the output data. Thus, in practice, a DES type method is vulnerable to attack at output of all the operators (XOR, P, E, PC, SBOX, etc) of all the rounds of operations because the secret key is mixed with the input data of the first round of operations.  
           [0011]    For example, with the input data ME being known, and making assumptions on the secret key K 0 , it is possible to predict the value of at least one bit of the intermediate data element (L 1 , R 1 ) given at output of the first round of operations. The prediction is verified, then the assumption made on the secret key is verified.  
           [0012]    To be secure, a component must also be capable of keeping the secret key that it uses concealed, when it undergoes an SPA type analysis (Simple Power Analysis). In an SPA analysis, the component is made to execute the encryption method that it uses several times by applying the same input data ME to it, and, for each execution of the method, the trace left by this execution is measured as a function of time. The trace represents, for example, the power consumption of the component or the electromagnetic energy radiated as a function of time. The set of measurements is then averaged to filter the noise from the measurement and obtain the real trace of the circuit for a fixed input data ME. For example, a set of 10 to 1000 identical measurements may be enough to filter the noise from the measurement and obtain the real trace of the component for a fixed input data ME. After filtering, the different steps of the DES method can be seen clearly on the real trace of the component: initial permutation IP, 16 rounds of operations and then final permutation IP-1.  
           [0013]    A DES type method is sensitive to SPA type analysIs especially at the points where the secret key appears, in its initial form K 0  or in another form (intermediate keys K 1 , . . . , K 16 , derived keys M 1 , . . . , M 16 ). Indeed, by an SPA type analysis it is possible, for each round i of operations, to determine an image of the derived key M i . For example, it is possible to identify the time interval during which the derived key M i  is transferred before the execution of the XOR operation. Since all the derived keys M 1  to M 16  are obtained from the secret key K 0  by known operations, a knowledge of simple images of the derived keys gives a information on the secret key K 0 .  
           [0014]    In general, all the encryption methods are more or less sensitive to DPA type attacks, especially at the places where there appears a predictable intermediate result that is a combination of the input data (or a data derived from the input data) and of the secret or private key (or of a key obtained from the secret or private key) or else that is a combination of the output data (or a data derived from the input data) and of the secret key (or of a key obtained from the secret key). An intermediate result of this kind is indeed predictable, from the input data and/or from the output data and from assumptions on the key used, because the encryption methods used (the operators used, the order of use of these operators, etc) are known. A DPA attack then gives information on the key used by validating the assumptions made.  
           [0015]    In practice, all the methods are sensitive at output of all the operators of all their steps (or sub-steps) using the input data (or a data derived from the input data), once the input data has been mixed with the secret key for a first time. In the same way, all the methods are also sensitive at output of all the operators giving a result that depends on the output data and on the secret or private key, and this is the case once the input data has been mixed for a first time with a secret or private key.  
           [0016]    In the same way, all the encryption methods using secret keys are more or less sensitive to SPA type analysis. Their sensitivity is especially great at places where the key appears alone, in its initial form or during a step known as a critical step, during which the secret key is used either directly or in a derived form obtained by a known law of derived key scheduling. A critical step of this kind is for example an intermediate or derived key scheduling step in which the key is computed from a secret or private key or else from a previously computed intermediate key.  
         SUMMARY OF THE INVENTION  
         [0017]    It is an object of the invention to implement a secured method of cryptographic computation with secret or private key that is made immune to any physical attack of the DPA type, namely a secured method of cryptographic computation whose trace, during the implementation of the method, gives no information on the key that it uses, whatever the input data used by the method, whatever the number of uses of the method, and even if a statistical study of the trace is made.  
           [0018]    Another object of the invention is to implement a secured method of cryptographic computation with secret or private key that is also protected against any SPA type attack.  
           [0019]    With these goals in view, the invention relates to a protected method of cryptographic computation, the method comprising N computation rounds successively performed to produce an output data from an input data and a secret key. According to the invention, the method also comprises a first masking stage to mask the input data, so that each intermediate data used or produced by a computation round is masked, and a second masking stage to mask data manipulated inside each computation round.  
           [0020]    The invention also relates to an electronic component using a method of the kind described here above and here below detailed. The word “masked” (or “mixed”) should be understood here and in the rest of the document in the following sense: in a method according to the invention, a data, a result, an operand are said to be masked if they have a different value during two executions of the method, especially during two executions of the method using the same input data and the same secret or private key.  
           [0021]    Thus, with the invention, the data given by a computation round is masked because the input data is masked before the computation round (first masking stage). The data given by a computation round is therefore different at each execution of the method, even if the input data and the secret key used are identical.  
           [0022]    Furthermore, the second masking stage used in a method according to the invention enables the masking of all data manipulated inside a computation round. Thus, the two masking stages used in the invention enable the masking of each data manipulated during the method, inside or outside the computation rounds. A statistical study of the consumption (or the electromagnetic radiation) of the component using a method according to the invention is therefore bound to fail: it cannot be used to obtain information on the secret key used since the power consumption of the component is decorrelated from the value of the key used.  
           [0023]    To perform the first masking stage, the following steps are preferably performed: a first masking step ET 01  carried out before the first computation round (round  1 ), to mask the input data, and a first unmasking step ET 10  applied after the N th  computation round (round N), to give the non-masked output data.  
           [0024]    To perform the second masking stage, the following steps are preferably performed, in a i-ranking computation round of the method: a second masking step ET 3  to mask a result of a previous step of the i-ranking computation round; a substitution step ET 6  to substitute the masked result by using a masked, non linear operator SBOX′; and a second unmasking step ET 9  to unmask the result of the step ET 6 .  
           [0025]    During the first masking step ET 01 , a first masking parameter is mixed with the input data ME to give a masked input data at the first computation round, the mixing being done through the use of a first linear mixing operator. To provide the method with maximum security, the first masking parameter is preferably chosen randomly at each implementation of the method during the masking step. The first masking parameter can also be chosen randomly only at intervals corresponding to every M cases of implementation of the method. In this case, the same masking parameter is used for the M following cases of implementation.  
           [0026]    The first masking step thus makes it possible, by mixing the data input with a random parameter, to eliminate every correlation between the input data ME and dataan intermediate data obtained from the input data ME and used or produced by a computation round. During the first unmasking step, at the end of the method, the contribution made by the first masking parameter to the result of the N-th computation round is subtracted from the result of the N-th computation round. The unmasking step thus makes it possible, at the end of the method, to retrieve the expected output data. In particular, if the method is performed twice with the same input data and the same secret key, then the output data MS obtained is the same in both cases. On the other hand, the intermediate data are different.  
           [0027]    For the implementation of the second masking stage, the method also preferably comprises a third masking step ET 03 , carried out before the first computation round, to produce the masked non linear operator SBOX′ verifying the following relation, for each data A:  
             SBOX′ ( A@X   3 )= SBOX ( A )# X   2 ,  
           [0028]    where  
           [0029]    X 2  is a second masking parameter,  
           [0030]    X 3  is a third masking parameter,  
           [0031]    SBOX is a known non linear operator,  
           [0032]    “#” is a second mixing operator and  
           [0033]    “@” is a third mixing operator.  
           [0034]    Preferably, at least one of the masking parameters used is randomly chosen at each implementation of the method, to obtain the maximum security.  
           [0035]    According to another embodiment, one of the masking parameters may be randomly chosen every M instances of implementation of the method. Preferably also, the mixing operators are linear. As an example, the XOR operator may be chosen for one of the mixing operators.  
           [0036]    If the method according to the invention comprises a derived key scheduling step to give a derived key from the secret key according to a known key scheduling law, then the method is advantageously complemented by the addition of a fourth masking step, performed before the derived key scheduling step, to mask the secret key so that the scheduled derived key is different at each implementation of the method.  
           [0037]    Thus, the derived key or keys and/or the intermediate scheduled key or keys are all masked by the addition of a random parameter so that an analysis if the power consumption of the component, of the SPA type for example, cannot provide any information on the secret key used. According to an embodiment, during the fourth masking step, a randomly chosen masking parameter is mixed with the secret key via a fourth masking operator, to give a masked secret key, the masked derived key being computed from the masked secret key. 
       
    
    
     BRIEF DESCRIPTION OF THE DRAWINGS  
       [0038]    The invention will be understood more clearly and other features and advantages of the invention shall appear from the following description of exemplary forms of implementation of protected methods of cryptographic computation according to the invention. The description will be made with reference to the appended drawings, of which:  
         [0039]    [0039]FIG. 1, already described, is a flowchart illustrating a DES type known encryption method using a secret key;  
         [0040]    [0040]FIG. 2 already described is a schematic drawing detailing a step of the method of FIG. 1;  
         [0041]    [0041]FIGS. 3 a,    3   b  are schematic drawings illustrating the method secured according to the invention;  
         [0042]    [0042]FIG. 4 is a schematic diagram of another embodiment of the method of FIGS. 3 a,    3   b.   
     
    
     DETAILED DESCRIPTION OF THE PREFERRED EMBODIMENTS  
       [0043]    [0043]FIGS. 3 a,    3   b  show how the DES method of the FIGS. 1, 2 is secured with the invention. To simplify, only the first computation round and the i-ranking computation round have been represented FIGS. 3 a,    3   b  with the characteristic steps of the invention. i is an integer comprised between 1 and 16. As previously explained, a DES method computes an output data from a secret key K 0  and from an input data ME; the DES method comprises 16 computation rounds, preceded by an initial permutation IP (FIG. 3 a ) and followed by a final permutation IP −1  (FIG. 3 b ), inverse of the initial permutation. Each computation round comprises (FIG. 2) a derived key scheduling ET 1 , a transformation step F′ and a combination step ET 8  with an XOR operator.  
         [0044]    The DES method is secured according to the invention by the addition of two masking stages. The first masking stage comprises a masking step ET 01  (FIG. 3 a ) and an unmasking step ET 10  (FIG. 3 b ). The second masking stage is performed at each computation round, it comprises a masking step ET 3 , a substitution step ET 6  by a masked non linear operator SBOX′ and a unmasking step ET 9 .  
         [0045]    In the example of FIGS. 3 a,    3   b,  the method comprises an initialization step ET 0  comprising fourth sub steps ET 00  to ET 03 . The object of the initialization step is to perform the first masking stage (step ET 01 : masking of the input data ME) and to prepare the second masking stage (by computation of the non linear operator SBOX′). The second masking stage is then perform at each computation round. During the step ET 00 , three masking parameters X 1 , X 2 , X 3  are chosen randomly. They are modified for example at each implementation of the method. They may also be modified only each M instances of implementation of the method.  
         [0046]    During the step ET 01 , the left-hand and right-hand parts of the input data are separated and then masked by the parameter X 1 , to thus give a masked left-hand part L′ 0 =L 0  &amp; X 1  and a masked right-hand part R′ 0 =R 0  &amp; X 1 . The masking is done via the first masking operator “&amp;”. The operator “&amp;” is chosen to be linear with respect to the two variables that it mixes. In one embodiment, the operator “&amp;” is an XOR operator. The operator “&amp;” may also be any type of linear operator. In general, the operator “&amp;” has the following properties, whatever the data A, B, C:  
         [0047]    “&amp;” has parity  2 : it takes two arguments as parameters;  
         [0048]    “&amp;” verifies: E(A&amp;B))=E(A)&amp;E(B), E being a linear operator;  
         [0049]    “&amp;” verifies (A⊕B)&amp;C=A⊕(B&amp;C), ⊕ being the XOR operator.  
         [0050]    There is an operator “&amp; −1 ”, the inverse of “&amp;”, such that: (A&amp;B)&amp; −1 A=B,; as the case may be “&amp;” and “&amp; −1 ” may be identical.  
         [0051]    During the step ET 02 , variables VX1=E(X 1 ), VX2=P(X 2 ) are computed. The operators E, P are respectively an expansion, and a simple permutation, as defined in the known DES type method. During the step ET 03 , a new non-linear operator SBOX′ is computed by the relationship:  
           SBOX′=FCT ( SBOX, X   2   , X   3 )  
         [0052]    where SBOX is the non-linear operator used in a known DES method, X 2 , X 3  are the random parameters, and FCT is a function such that:  
         [0053]    SBOX′[A@X 3 ]=SBOX[A]#X 2 , for any value of A.  
         [0054]    “@”, “#” are linear mixing operators having properties similar to those of the operator “&amp;”.  
         [0055]    “&amp; ”, “#” may be different from each other, and they may also be different from the operator “&amp;”.  
         [0056]    The first round of operations is then carried out; it can be sub-divided into nine steps ET 1  to ET 9 . During the key-scheduling step ET 1 , a derived key M 1  is computed from the secret key K 0 . The first updated derived key M 1  is given by the relationship: M 1 =PC(S 1 (K 0 ))=PC(K 1 ). K 1  is a first updated intermediate key, which will be given thereafter at the second round of operations (not shown in FIGS. 4 a,    4   b ). The operators PC, S 1  are respectively a permutation-compression and a bit-shifting operation as defined in the case of a known DES method. The step ET 1  is thus identical to a key-scheduling step as defined in the context of a known DES method.  
         [0057]    The following steps ET 2  to ET 8  form a transformation step F′, that corresponds to the transformation F of a prior art method, modified by the addition of the steps ET 3 , ET 4  and the replacement of the operator SBOX by the new operator SBOX′ according to the invention. During the step ET 2 , an expansion is made on the data R′ 0 . The result E(R′ 0 ) of this operation is then mixed with the parameter X 3  by means of the second masking operator “@”.  
         [0058]    The next step ET 4  is a first unmasking step designed to remove, from the result of the previous operation, the contribution to this result made by the masking parameter X 1 . To this end, the following operation is carried out:  
         [ E ( R′   0 )@ X   3 ]&amp; −1   VX   1   =[E ( R′   0 )@ X   3 ]&amp; −1   E ( X   1 )== E ( R   0 )&amp; E ( X   1 )@ X   3 &amp; −1   E ( X   1 )= E ( R   0 )@ X   3    
         [0059]    During the next step ET 5 , the result of the previous step ET 4  is mixed with the updated derived key M 1  by an XOR operation. The step ET 5  thus gives the result: E(R 0 )@X 3 ⊕M 1 =E(R 0 )⊕M 1 @X 3 .  
         [0060]    During the step ET 6 , the non-linear operation SBOX′ is performed on the result of the previous operation. The step ET 6  gives the result:  
           SBOX′[E ( R   0 )⊕ M   1   @X   3   ]=SBOX[E ( R   0 )⊕ M   1   ]#X   2 .  
         [0061]    This results from the definition of the non-linear operator SBOX′.  
         [0062]    A bit-permutation operation P is then applied to this result (step ET 7 ). We thus obtain:  
           F ′( R′   0 )= P[SBOX[E ( R   0 )⊕ M   1   ]#X   2   ]=P[SBOX[E ( R   0 )⊕ M   1   ]]#P ( X   2 ).  
         [0063]    This result is deduced simply from the linearity of the operator P.  
         [0064]    During the step ET 8 , the result of the permutation P is then added (by means of an XOR operation) to the data L′ 0  computed during the step ET 01 . The step ET 8  is similar to the corresponding step of a known DES method. We then obtain:  
           P[SBOX[E ( R   0 )⊕ M   1   ]]#P ( X   2 )⊕ L′   0   =[P ( SBOX[E ( R   0 )⊕ M   1 ])# P ( X   2 )]⊕ L   0 &amp; X   1   =[P[SBOX[E ( R   0 )⊕ M   1   ]]⊕L   0 ]&amp; X   1   #P ( X   2 ) =R   1 &amp; X   1   #P ( X   2 )  
         [0065]    where R 1  is the right-hand part of the first intermediate data (L 1 , R 1 ) as defined in the context of the known DES type method. Here too, all the above inequalities are deduced from the fact of the linearity of the operators P, &amp;, #.  
         [0066]    The following step ET 9  is a second unmasking step that seeks to remove, from the result of the previous operation, the contribution to this result made by the masking parameter X 2 . To this end, the following operation is carried out:  
         [ R   1 &amp; X   1   #P ( X   2 )]# −1   VX   2   =[R   1 &amp; X   1   #P ( X   2 )]# −1   P ( X   2 )= R   1 &amp; X   1    
         [0067]    At the end of the first round, the updated, intermediate data provided is equal to (L′ 1 , R′ 1 ), with:  
           L′   1   =R′   0   =R   0 &amp; X   1   =L   1 &amp; X   1 , and  R′   1   =R   1 &amp; X   1 .  
         [0068]    Thus, with the DES method according to the invention, the intermediate data (L′ 1 , R′ 1 ) computed during the first round of operations is equal to the intermediate data (L 1 , R 1 ) given by an unsecured, known DES type method, masked by the random parameter X 1  by means of the operator “&amp;”. The second round is then performed, in using the new updated intermediate data (L′ 1 , R′ 1 ) as well as the updated intermediate key K 1  computed during the step ET 1 .  
         [0069]    In general, the i th  round of operations of the method can be sub-divided into nine steps ET 1  to ET 9 . During the step ET 1 , a derived key M 1  is computed from an intermediate key K i-1 , computed during the preceding round, to give an updated derived key M i-1 =PC(Si(K i-1 ))=PC(K i ). K i  is a first updated intermediate key, which will be given thereafter at the next round of operations (not shown in FIGS. 4 a,    4   b ). The operators PC, S i  are respectively a permutation-compression and a bit-shifting operation as defined in the case of a known DES method.  
         [0070]    During the step ET 2 , the expansion is made on the data R′ i-1 . The result E(R′ i-1 ) of this operation is then mixed with the parameter X 3  by means of the second masking operator “@”.  
         [0071]    During the next step ET 4 , the following operation is carried out:  
         [ E ( R′   i-1 )@ X   3 ]&amp; −1   VX   1   =[E ( R′   i-1 )@ X   3 ]&amp; −1   E ( X   1 )= E ( R   i-1 )&amp; E ( X   1 )@ X   3 &amp; −1   E ( X   1 )= E ( R   i-1 )@ X   3    
         [0072]    During the next step ET 5 , the result of the step ET 4  is mixed with the updated derived key M i  by an XOR operation. The step ET 5  thus gives the result:  
           E ( R   i-1 )@ X   3   ⊕M   i   =E ( R   i-1 )⊕ M   i   @X   3 .  
         [0073]    During the step ET 6 , the non-linear operation SBOX′ is performed on the result of the previous operation. The step ET 6  gives the result:  
           SBOX′[E ( R   i-1 )⊕ M   i   @X   3   ]=SBOX[E ( R   i-1 )⊕ M   i   ]#X   2 .  
         [0074]    This results from the very definition of the non-linear operator SBOX′.  
         [0075]    A bit-permutation operation P is then applied to this result (step ET 7 ). We thus obtain:  
           P[SBOX[E ( R   i-1 )⊕ M   i   ]#X   2   ]=P[SBOX[E ( R   i-1 )⊕ M   i   ]]#P ( X   2 ).  
         [0076]    During the step ET 8 , the result of the permutation P is then added (by means of an XOR operation) to the data L′ i-1  computed during the previous round. We then obtain:  
           P[SBOX[E ( R   i-1 )⊕ M   i   ]]#P ( X   2 )⊕ L′   i-1   =[P ( SBOX[E ( R   i-1 )⊕ M   i ])# P ( X   2 )]⊕ L   i-1 &amp; X   1   =[P[SBOX[E ( R   i-1 )⊕ M   i   ]]⊕L   i-1 ]&amp; X   1   #P ( X   2 )= R   i &amp; X   1   #P ( X   2 )  
         [0077]    where R i  is the right-hand part of the i th  updated data (L i , R i ) as defined in the context of the known DES type method. Here too, all the above equalities are deduced from the fact of the linearity of the operators P, &amp;, #.  
         [0078]    The following step ET 9  is a second unmasking step that seeks to remove, from the result of the previous operation, the contribution to this result made by the masking parameter X 2 . To this end, the following operation is performed:  
         [ R   i-1 &amp; X   1   #P ( X   2 )]# −1   VX   2   =[R   i-1 &amp; X   1   #P ( X   2 )]# P ( X   2 )= R   i-1 &amp; X   1    
         [0079]    At the end of the i th  round, the updated, intermediate data provided is equal to (L′ i , R′ i ), with:  
           L′   i   =R′   i-1   =R   i-1 &amp; X   1   =L   i &amp; X   1 , and R′ i =R i &amp;X 1 .  
         [0080]    Thus, with the DES method according to the invention, the intermediate data (L′ i , R′ i ) computed during the i th  round of operations is equal to the intermediate data (L i , R i ) given during the same round by a non-secured, known DES method but masked by the random parameter X 1  by means of the operator “&amp;”.  
         [0081]    The new intermediate data (L′ i , R′ i ) is then given at the next round. The 16 th  round of the method gives the 16 th  intermediate data (L′ 16 , R′ 16 ). During a third and final unmasking step ET 10 , the contribution of the parameter X 1  to the 16 th  data is removed by means of the operator &amp; −1 : L 16 =L′ 16 &amp; −1 X 1 , R 16 =R′ 16 &amp; −1 X 1 .  
         [0082]    The final permutation IP −1 , carried out after the step ET 10 , terminates the DES method according to the invention. The permutation IP −1  is identical to the equivalent permutation of a known type of DES method.  
         [0083]    With the DES method according to the invention, the output data produced is the same as the one given by a known DES method, inasmuch as the input data element ME and the secret key K 0  are identical for the known method and the method according to the invention.  
         [0084]    On the other hand, with a method according to the invention (FIG. 3) and contrary to a known DES method (FIGS.  1 ,  2 ): the intermediate data of type (L′ i , R′ i ) are all masked with the parameter X 1  (first masking stage); and the data (L′ i , R′ i ) are used or produced by the computation round. All the intermediate results produced by an operation of the P, PC, E, S i , SBOX′, XOR ⊕ or other type) are masked by at least one of the parameters X 1 , X 2  or X 3  or by a value derived from these parameters (E(X 1 ), P(X 2 ), etc.); the second masking stage is thus correctly implemented.  
         [0085]    Since X 1 , X 2  or X 3  are chosen randomly at each implementation of the method, the value of all the intermediate results and of all the intermediate data is different at each implementation of the method, whatever the value of the input data (L 0 , R 0 ) or the value of the secret key K 0  used by the method of the invention. In particular, the value of all the intermediate results is different, including in the case where the method is implemented twice with the same input data ME and the same secret key K 0 .  
         [0086]    The presence of at least one random parameter suppress any correlation, at the level of an intermediate result or an intermediate data, between the secret key K 0  and the input data ME. A DPA type statistical analysis therefore does not enable to obtain information on the secret key used by a secured method according to the invention.  
         [0087]    Modifications and/or improvements in the method of FIGS. 3 a,    3   b  are possible, without departing from the framework of the invention. For example, the order in which certain steps of the method are carried out may be modified: The steps IP, ET 01 , round  1 , . . . , round i, . . . , round  16 , ET 10 , IP −1  must be executed in the order presented in FIGS. 4 a,    4   b  if the desired method is has to be similar to that of FIGS. 1, 2.  
         [0088]    The step ET 00  must be performed before the step ET 01 . The step ET 00  may be performed before or in parallel with the step IP. The step ET 02  is performed between the step ET 00  and the step ET 4  of the first round of operations; it may be performed before or in parallel with the step IP, the step ET 01  and the steps ET 1  or ET 2 . The step ET 03  is performed between the step ET 00  and the step ET 6  of the first round of operations; it may be performed before or after the step ET 01 , the steps ET 1 , ET 2 , ET 3  or ET 4 . For reasons of symmetry, the step ET 10  will be carried out after the step IP −1  if the step ET 01  is performed before the step IP. Conversely, the step ET 10  will be performed before the step IP −1  if the step ET 01  is performed after the step IP. In each round i, the step ET 1  must be carried out so that the derived key M i  that it gives is available for the performance of the step ET 5 ; the step ET 1  may for example be carried out in parallel with the steps ET 2 , ET 3  or ET 4 .  
         [0089]    In the example described here above with reference to FIGS. 3 a,    3   b,  three random parameters X 1 , X 2 , X 3  are used. This approach masks all the intermediate results in the most efficient way possible. In another example, it is possible to use only two parameters, the parameters X 1 , X 2 . In this case, the step ET 02  is limited to the computation of P(X 2 ), the steps ET 3 , ET 4  of all the rounds of operations are eliminated, and the step ET 03  is modified to compute a new non-linear operator SBOX″ by the relationship:  
           SBOX″=FCT″ ( SBOX, X   1   , X   2 ),  
         [0090]    with FCT″ being a function such that:  
           SBOX″ ( A &amp; E ( X   1 ))= SBOX ( A )# X   2 .  
         [0091]    Here too, all the intermediate results are masked by a random parameter that is modified at each implementation of the method. In particular, in the i-ranking round, at output of the step ET 2 , the intermediate parameter E(R′ 0 )=E(R 0 )&amp;E(X 1 ) is masked by the derived parameter E(X 1 ). In the same way, at output of the step ET 5 , the intermediate result E(R′ 0 )⊕M i  is masked by the derived parameter E(X 1 ). At output of the step ET 6 , the intermediate result is masked as in the previous example by the parameter X 2 .  
         [0092]    Similarly, in the example described here above with reference to FIGS. 3 a,    3   b,  the three parameters X 1 , X 2 , X 3  are chosen randomly, at each implementation of the method. However, the parameters X 1 , X 2,  X 3  can be modified more or less frequently. For example, it is possible to modify the parameters, especially X 2  and/or X 3  at each performance of a round i of operations. In this case, the steps ET 02 , ET 03  will be performed at each round to take account of the modified parameters X 2 , X 3 .  
         [0093]    In the same spirit, the parameters X 1 , X 2,  X 3  can be modified every M cases of implementation of the method, if it is estimated that M performances are not sufficient to carry out a DPA type attack. M is an integer. In this case, only the step ET 01  is performed during the step ET 0 . The steps ET 00 , ET 02 , ET 03  are performed only at intervals of every M cases of implementation of the method.  
         [0094]    In another major improvement, the method is secured also against SPA type analysis. For this type of analysis, the derived key scheduling steps M i  are particularly vulnerable. The improvement therefore consists in masking the derived keys, in addition to the intermediate results.  
         [0095]    The method of FIGS. 3 a,    3   b  is therefore improved by the addition (see FIG. 4): of the sub-steps ET 05 , ET 06  in the initialization step ET 0 , the steps ET 11 , ET 12  in each of the 16 rounds of operations of the method. With a view to clarity and simplification, only the i th  round of the method has been shown in FIG. 4, accompanied by new steps ET 05 , ET 06 .  
         [0096]    During the step ET 05 , a fourth parameter Y 0  is chosen randomly. The step ET 05  is for example carried out simultaneously with the step ET 00 , or else in parallel with one of the steps IP, ET 01 , ET 02 , ET 03 . During the masking step ET 06 , performed after the step ET 05 , the fourth masking parameter Y 0  is mixed with the secret key K 0 , to give a masked secret key K′ 0 . The mixing is done by the following relationship:  
           K′   0   =K   0   |Y   0 .  
         [0097]    The operator “|” is chosen to be linear with respect to the two variables that it mixes. In one embodiment, the operator “|” is an XOR operator. The operator “|” may also be any type of linear operator. In general, the operator “|” has properties similar to those of the operators “&amp;”, “@” or “#”.  
         [0098]    The first round of operations (not shown in FIG. 4) is then performed. The key scheduling step ET 1  is achieved here no longer directly from the secret key K 0 , but from the masked secret key K′ 0 . The step ET 1  gives a masked derived key M′ 1  according to the relationship:  
           M′   1   =PC ( S   1 ( K′   0 ))= PC ( S   1 ( K   0   |Y   0 ))= PC ( S   1 ( K   0 ))| PC ( S   1 ( Y   0 )).  
         [0099]    The last equality is deduced simply from the fact that the operators PC, S 1  et “|” are linear operators and therefore have especially switching or associative type properties. Since PC(S 1 (K 0 ))=M 1 , it is finally deduced therefrom that M′ 1 =M 1 |PC(S 1 (Y 0 ), M 1  being the scheduled derived key computed according to the DES methodcribed with reference to FIGS. 3 a,    3   b.    
         [0100]    The difference computation step ET 11  is performed, for example, before, in parallel or after the key scheduling step ET 1 . The step ET 11  determines the contribution C i  given by the parameter Y 0  to the masked derived key M′ i . The step ET 11  is similar to the step ET 1 ; the step ET 11  thus comprises an operation S i  to give a masking parameter Y 1 =S 1 (Y 0 ) updated by the shifting of the bits of the parameter Y 0 , and an operation PC to compute the contribution C i . The contribution C 1  is thus computed according to the relationship: C 1 =PC(S 1 (Y 0 )). Finally M′ 1 =M 1 |C 1  is deduced therefrom. The updated masking parameter Y 1  for its part is given at the next round of operations.  
         [0101]    The unmasking step ET 12  is a sub-step of the transformation step F″ (which corresponds to the transformation F′ of the DES method according to FIGS. 4 a,    4   b  modified by the addition of the step ET 12 ); the step ET 12  is carried out between the step ET 5  and the step ET 6 . The step ET 12  seeks to remove the contribution C 1  given by the updated masking parameter Y 1 . For this purpose, the operator “| −1 ”, which is the inverse of the operator “|”, is used. At output of the step ET 12 , we have:  
         ( E ( R   0 )@ X   3   ⊕M′   1 | −1   C   1   =E ( R   0 )@ X   3   ⊕M   1   |C   1 | −1   C   1   =E ( R   0 )@ X   3   ⊕M   1    
         [0102]    Thus, after the removal of the contribution C 1 , the variable that appears at the input of the SBOX′ type operator (step ET 6 ) is equal to E(R 0 )@X 3 ⊕M 1 , i.e. it is identical to the variable that appears at the input of the operator SBOX′ of the DES method described with reference to FIGS. 3 a,    3   b.  Consequently, the output data that appears at output of the transformation F″ is identical to the one that appears at output of the transformation F′ of the method of FIGS. 3 a,    3   b.    
         [0103]    More generally, during the i th  round of operations, the step ET 1  gives a masked, derived key M′ i  according to the relationship:  
           M′   i   =PC ( S   i ( K′   i-1 ))= PC ( S   i ( K   i-1   |Y   i-1 ))= PC ( S   i ( K   i-1 ))| PC ( S   i ( Y   i-1 ))= M′   i   =M   i   |PC ( S   i ( Y   i-i ),  
         [0104]    M i  being the derived key computed according to the DES method described with reference to FIGS. 3 a,    3   b.  It may be recalled that the operators PC are identical for all the rounds of the method (the same characteristics, same parameters, etc.). On the contrary, the bit-shifting operations S i  are different from one round of operations to another.  
         [0105]    The step ET 11  determines the contribution C i  made by the parameter Y i-1  (or more generally Y 0 ) to the masked derived key M′ i . The step ET 11  gives an updated masking parameter Y i =S i (Y i-1 ), and an updated contribution C i  according to the relationship: C i =PC(S i (Y i-1 )). It is finally deduced from this that M′ i =M i |C i . The updated masking parameter Y i  for its part is given at the next round of operations.  
         [0106]    The step ET 12  is performed between the step ET 5  and the step ET 6 . At output of the step ET 12 , we have:  
         ( E ( R   i-1 )@ X   3   ⊕M′   i | −1   C   i   =E ( R   i-1 )@ X   3   ⊕M   i   |C   i | −1   C   i   =E ( R   i-1 )@ X   3   ⊕M   i    
         [0107]    Thus, after elimination of the contribution C i , the variable that appears at the input of the SBOX′ type operator (step ET 6 ) is equal to PE(R i-1 )@X 3 +M i , i.e. it is identical to the variable that appears at the input of the operator SBOX′ of the DES methodcribed with reference to FIGS. 4 a,    4   b.  The output data that appears at output of the transformation step F′ is therefore identical to the one that appears at output of the transformation operation F′ of the method of FIGS. 3 a,    3   b.    
         [0108]    Finally, with the method of FIG. 5, all the intermediate results are masked by at least one of the parameters X 1 , X 2 , X 3  (or a derived form of these parameters). Furthermore, all the intermediate keys K′ i , all the derived keys M′ i , are also masked by the parameter Y 0  or a derived form of Y 0 .