very high order masking efficient
play

Very High-Order Masking: Efficient Implementation and Security - PowerPoint PPT Presentation

Very High-Order Masking: Efficient Implementation and Security Evaluation Anthony Journault and Franois-Xavier Standaert UCL (Louvain-la-Neuve, Belgium) CHES 2017, Taipei, Taiwan Outline Background Masking Barthe et al. masking


  1. Very High-Order Masking: Efficient Implementation and Security Evaluation Anthony Journault and François-Xavier Standaert UCL (Louvain-la-Neuve, Belgium) CHES 2017, Taipei, Taiwan

  2. Outline • Background  Masking  Barthe et al. masking scheme • How fast can be very high-order masking ?  Data representation  AES results and discussion • How can we evaluate security at very high order ?  Limitation of leakage detection strategy  Multi-model approach • Conclusion/Open problems

  3. Outline • Background  Masking  Barthe et al. masking scheme • How fast can be very high-order masking ?  Data representation  AES results and discussion • How can we evaluate security at very high order ?  Limitation of leakage detection strategy  Multi-model approach • Conclusion/Open problems

  4. Masking 1 • Masking (e.g. Boolean encoding) 𝑏 = 𝑏 1 ⨁𝑏 2 ⨁ ⋯ ⨁𝑏 𝑒 • With 𝑏 2 , ⋯ , 𝑏 𝑒 random

  5. Masking 1 • Masking (e.g. Boolean encoding) 𝑏 = 𝑏 1 ⨁𝑏 2 ⨁ ⋯ ⨁𝑏 𝑒 • With 𝑏 2 , ⋯ , 𝑏 𝑒 random • Abstract security  Probing model  Security order 𝑒 − 1 (at best)

  6. Masking 1 • Masking (e.g. Boolean encoding) 𝑏 = 𝑏 1 ⨁𝑏 2 ⨁ ⋯ ⨁𝑏 𝑒 • With 𝑏 2 , ⋯ , 𝑏 𝑒 random • Abstract security • Concrete security  Probing model  Noisy leakage  Security order model  𝑂 = (𝜏 2 ) 𝑒−1 𝑒 − 1 (at best) (under assumptions)

  7. Barthe et al. 2017 masking scheme 2 • Parallel masking scheme by design • All shares manipulated at once

  8. Barthe et al. 2017 masking scheme 2 • Parallel masking scheme by design • All shares manipulated at once • Example of mult. 𝑏 ∗ 𝑐 = 𝑑 for 𝑒 = 3 a b r a b a b r c 1 1 1 1 3 3 1 3 1      a b r a b a b r c 2 2 2 2 1 1 2 1 2 a b r a b a b r c 3 3 3 3 2 2 3 2 3

  9. Outline • Background  Masking  Barthe et al. masking scheme • How fast can be very high-order masking ?  Data representation  AES results and discussion • How can we evaluate security at very high order ?  Limitation of leakage detection strategy  Multi-model approach • Conclusion/Open problems

  10. Data representation and implementation 3 • 32-bit register ……… a30 a31 a32 a1 a2 a3 Secret bit + sum Random Random Random Random Random random bits bit bit bit bit bit

  11. Data representation and implementation 3 • 32-bit register ……… a30 a31 a32 a1 a2 a3 Secret bit + sum Random Random Random Random Random random bits bit bit bit bit bit • Use bitwise operators (XOR, AND, …)

  12. Data representation and implementation 3 • 32-bit register ……… a30 a31 a32 a1 a2 a3 Secret bit + sum Random Random Random Random Random random bits bit bit bit bit bit • Use bitwise operators (XOR, AND, …) • Implementation on 32-bit ARM • Optimal case: register size = nb of shares

  13. Data representation and implementation 3 • 32-bit register ……… a30 a31 a32 a1 a2 a3 Secret bit + sum Random Random Random Random Random random bits bit bit bit bit bit • Use bitwise operators (XOR, AND, …) • Implementation on 32-bit ARM • Optimal case: register size = nb of shares • Well suited for bitslice ciphers 

  14. Implementation Results: AES 4 • Application to AES • Gate level Time Spent (%) representation of AES S-box (Boyar, Randomness Peralta 2010) Non-linear op Linear op 10 cycles to generate 32-bit random value Total = 2 800 000 cycles

  15. Implementation Results: AES 4 • Application to AES • Gate level Time Spent (%) representation of AES S-box (Boyar, Randomness Peralta 2010) Non-linear op Linear op • SNI refreshing of one input of each multiplication 10 cycles to generate 32-bit random value (conservative) Total = 2 800 000 cycles

  16. Implementation Results: AES 4 • Application to AES • Gate level Time Spent (%) representation of AES S-box (Boyar, Randomness Peralta 2010) Non-linear op Linear op • SNI refreshing of one input of each multiplication 80 cycles to generate 32-bit random value (conservative) Total = 9 700 000 cycles

  17. Comparison with Goudarzi-Rivain 5 • Goudarzi-Rivain 2017: Generic ISW implementation and application to bitsliced AES Goudarzi-Rivain This paper 3,821,312 2,783,510

  18. Comparison with Goudarzi-Rivain 5 • Goudarzi-Rivain 2017: Generic ISW implementation and application to bitsliced AES Goudarzi-Rivain This paper 3,821,312 2,783,510 • Same order of magnitude of cycles • Very high-order masking is not out of reach !

  19. Outline • Background  Masking  Barthe et al. masking scheme • How fast can be very high-order masking ?  Data representation  AES results and discussion • How can we evaluate security at very high order ?  Limitation of leakage detection strategy  Multi-model approach • Conclusion/Open problems

  20. Limitations of leakage detection strategy 6 • Evaluator power = 2^30 • If security <= 2^30, security level • What if security > 2^30 ? • Security claims bounded by evaluator power

  21. Limitations of leakage detection strategy 6 • Evaluator power = 2^30 • If security <= 2^30, security level • What if security > 2^30 ? • Security claims bounded by evaluator power We expect 31th-security order (or 31/f-security order)

  22. Multi-Model Approach 7

  23. Multi-Model Approach 7 Probing model Abstract Qualitative Algorithmic security order d Risk captured: Lack of refreshing

  24. Multi-Model Approach 7 Bounded-Moment Probing model Model Abstract Physical Qualitative Qualitative Algorithmic security Physical security order order f d Risk captured: Risk captured: Lack of refreshing Share recombination

  25. Multi-Model Approach 7 Bounded-Moment Noisy Leakage Model Probing model Model Abstract Physical Physical Qualitative Qualitative Quantitative Algorithmic security Physical security Physical security order order order f MI , SNR d Risk captured: Risk captured: Risk captured: Lack of refreshing Share recombination Lack of noise

  26. Multi-Model Approach 7 Bounded-Moment Noisy Leakage Model Probing model Model Abstract Physical Physical Qualitative Qualitative Quantitative Algorithmic security Physical security Physical security order order order f MI , SNR d d + f + SNR + MI => Security level Risk captured: Risk captured: Risk captured: Lack of refreshing Share recombination Lack of noise

  27. Probing security (state of the art) 8 • 2 possible options:  Composable gadgets (SNI) o Simple to analyse o Implementation becomes expensive  Full code evaluation o Hard to analyse o Reduced implementation cost

  28. Bounded-Moment security 9

  29. Bounded-Moment security 9 • Leakage detection hard in practice with 32 shares

  30. Bounded-Moment security 9 • Leakage detection hard in practice with 32 shares • Idea similar to symmetric cryptanalysis: security based on reduced version • Leakage detection on small order (e.g. on 4 shares)

  31. Bounded-Moment security 9 • Leakage detection hard in practice with 32 shares • Idea similar to symmetric cryptanalysis: security based on reduced version • Leakage detection on small order (e.g. on 4 shares) • Extraction of a risk factor f from possible share recombination • Extrapolation of security

  32. Leakage detection results 10

  33. Leakage detection results 11

  34. Noisy Leakage Model 12 • SNR(=0,05) computed with linear regression • MI of the encoding • 31 / 15 / 7 -order security if flaw f = 1 / 2 / 4

  35. Noisy Leakage Model 12 • SNR(=0,05) computed with linear regression • MI of the encoding • 31 / 15 / 7 -order security if flaw f = 1 / 2 / 4

  36. Noisy Leakage Model 12 • SNR(=0,05) computed with linear regression • MI of the encoding • 31 / 15 / 7 -order security if flaw f = 1 / 2 / 4

  37. Noisy Leakage Model 12 • SNR(=0,05) computed with linear regression • MI of the encoding • 31 / 15 / 7 -order security if flaw f = 1 / 2 / 4 • Averaging: multiple apparition of sensitive values

  38. Putting things together 13

  39. Putting things together 13 Horizontal SCA

  40. Putting things together 13 Horizontal SCA Worst case

  41. Putting things together 13 Horizontal SCA Order reduction from flaw f Worst case Order reduction from noise

  42. Outline • Background  Masking  Barthe et al. masking scheme • How fast can be very high-order masking ?  Data representation  AES results and discussion • How can we evaluate security at very high order ?  Limitation of leakage detection strategy  Multi-model approach • Conclusion/Open problems

  43. Conclusion 14

  44. Conclusion 14 • Very high order (32 shares) implementation is not out of reach !

  45. Conclusion 14 • Very high order (32 shares) implementation is not out of reach ! • Multi-model approach proposed to evaluate very HO masked implementations ( security level )

  46. Conclusion 14 • Very high order (32 shares) implementation is not out of reach ! • Multi-model approach proposed to evaluate very HO masked implementations ( security level ) • Based on falsifiable assumptions

Recommend


More recommend