Fault enabled viruses against smart cards 1 2 1 Samiya - - PowerPoint PPT Presentation

fault enabled viruses against smart cards
SMART_READER_LITE
LIVE PREVIEW

Fault enabled viruses against smart cards 1 2 1 Samiya - - PowerPoint PPT Presentation

Fault enabled viruses against smart cards 1 2 1 Samiya HAMADOUCHE , Jean-Louis LANET , Mohamed MEZGHICHE 1 LIMOSE Laboratory, University


slide-1
SLIDE 1

Fault ¡enabled ¡viruses ¡against ¡smart ¡cards ¡

¡

¡

Fault ¡enabled ¡viruses ¡against ¡smart ¡cards ¡ Jean-­‑Louis ¡LANET ¡

Samiya ¡HAMADOUCHE ¡ ¡ ¡, ¡Jean-­‑Louis ¡LANET ¡ ¡ ¡ ¡, ¡Mohamed ¡MEZGHICHE ¡ LIMOSE ¡Laboratory, ¡University ¡of ¡Boumerdès ¡(Algeria) ¡ INRIA ¡LHS-­‑PEC, ¡Rennes ¡ SDTA ¡2014 ¡ Clermont ¡Ferrand, ¡France, ¡ 5th ¡of ¡December ¡

1 ¡ 1 ¡ 2 ¡ 1 ¡ 2 ¡

slide-2
SLIDE 2

Outline ¡

¡

¡

Fault ¡enabled ¡viruses ¡against ¡smart ¡cards ¡ Jean-­‑Louis ¡LANET ¡

¡ ¡Context ¡ ¡ ¡ ¡MoSvaSon ¡ ¡ ¡Example ¡: ¡Get ¡the ¡secret ¡key ¡ ¡ ¡The ¡proposed ¡approach ¡ ¡ ¡Concepts ¡ ¡ ¡Principal ¡ ¡ ¡Conclusion ¡and ¡future ¡work ¡

slide-3
SLIDE 3

Smart ¡Card ¡

¡

¡

Fault ¡enabled ¡viruses ¡against ¡smart ¡cards ¡ Jean-­‑Louis ¡LANET ¡

¡ ¡Computer ¡with ¡reduced ¡resources ¡ ¡ ¡Secured ¡device ¡that ¡stores ¡and ¡processes ¡ ¡ ¡ ¡ ¡ ¡sensiSve ¡data ¡ ¡ ¡Many ¡uses ¡ ¡ ¡ ¡Telecom ¡ ¡ ¡ ¡ ¡Banking ¡ ¡ ¡ ¡IdenSty ¡(passport, ¡etc.) ¡ ¡ ¡Transport ¡ ¡ ¡Others ¡… ¡ ¡ ¡Java ¡Card ¡Pla[orm ¡

Context ¡

1 ¡

slide-4
SLIDE 4

Java ¡Card ¡security ¡

¡

¡

Fault ¡enabled ¡viruses ¡against ¡smart ¡cards ¡ Jean-­‑Louis ¡LANET ¡

¡ ¡Security ¡assured ¡by ¡: ¡ ¡Java ¡language ¡ ¡ ¡Embedded ¡security ¡mechanisms ¡ ¡ ¡ ¡ ¡ ¡(byte ¡code ¡verifier, ¡firewall ¡, ¡transacSon, ¡etc.) ¡ ¡ ¡ ¡ ¡ ¡

Context ¡

2 ¡

slide-5
SLIDE 5

Java ¡Card ¡security ¡

¡

¡

Fault ¡enabled ¡viruses ¡against ¡smart ¡cards ¡ Jean-­‑Louis ¡LANET ¡

¡ ¡Security ¡assured ¡by ¡: ¡ ¡Java ¡language ¡ ¡ ¡Embedded ¡security ¡mechanisms ¡ ¡ ¡ ¡ ¡ ¡(byte ¡code ¡verifier, ¡firewall ¡, ¡transacSon, ¡etc.) ¡ ¡ ¡ ¡SensiSve ¡data ¡to ¡protect ¡ ¡ ¡ ¡ ¡ ¡

Attacks Physical Logical Combined

Context ¡

2 ¡

slide-6
SLIDE 6

Fault ¡A]acks ¡

¡

¡

Fault ¡enabled ¡viruses ¡against ¡smart ¡cards ¡ Jean-­‑Louis ¡LANET ¡

¡ ¡Introduce ¡perturbaSons ¡in ¡the ¡execuSon ¡environment ¡of ¡the ¡chip ¡ ¡ ¡Means ¡ ¡ ¡Clock ¡glitches ¡ ¡ ¡Power ¡spikes ¡ ¡ ¡Temperature ¡modificaSon ¡ ¡ ¡ElectromagneSc ¡disturbance ¡ ¡ ¡ ¡IlluminaSon ¡(OpScal ¡a]ack ¡/ ¡Light ¡a]ack) ¡ ¡ ¡… ¡ ¡ ¡ ¡ ¡

Context ¡

3 ¡

slide-7
SLIDE 7

Fault ¡A]acks ¡

¡

¡

Fault ¡enabled ¡viruses ¡against ¡smart ¡cards ¡ Jean-­‑Louis ¡LANET ¡

¡ ¡Fault ¡models: ¡Fault ¡a]acks ¡classificaSon ¡ ¡ ¡Is ¡only ¡available ¡at ¡the ¡binary ¡level, ¡ ¡ ¡Depend ¡on ¡the ¡source ¡(laser ¡or ¡EM). ¡ ¡ ¡

Context ¡

4 ¡

Fault ¡model ¡ Precision ¡ Posi?on ¡ Timing ¡ Fault ¡type ¡ Precise ¡bit ¡error ¡ Bit ¡ full ¡control ¡ full ¡control ¡ BSR* ¡ Precise ¡byte ¡error ¡ Byte ¡ full ¡control ¡ full ¡control ¡ BSR*, ¡random ¡ Unknown ¡byte ¡error ¡ Byte ¡ lose ¡control ¡ full ¡control ¡ BSR*, ¡random ¡ Random ¡error ¡ Variable ¡ no ¡control ¡ parSal ¡control ¡ Random ¡

* ¡BSR ¡: ¡Bit ¡Set ¡(0x00) ¡or ¡Reset ¡(0xFF) ¡

slide-8
SLIDE 8

Outline ¡

¡

¡

Fault ¡enabled ¡viruses ¡against ¡smart ¡cards ¡ Jean-­‑Louis ¡LANET ¡

¡ ¡Context ¡ ¡ ¡ ¡MoSvaSon ¡ ¡ ¡Example ¡: ¡Get ¡the ¡secret ¡key ¡ ¡ ¡The ¡proposed ¡approach ¡ ¡ ¡Concepts ¡ ¡ ¡Principal ¡ ¡ ¡Conclusion ¡and ¡future ¡work ¡

slide-9
SLIDE 9

Fault ¡Enabled ¡Viruses ¡

¡

¡

Fault ¡enabled ¡viruses ¡against ¡smart ¡cards ¡ Jean-­‑Louis ¡LANET ¡

¡ ¡A ¡malicious ¡code ¡that ¡can ¡be ¡loaded ¡into ¡the ¡card ¡without ¡being ¡detected ¡ ¡ ¡ ¡ ¡ ¡ ¡by ¡the ¡security ¡mechanisms ¡ ¡ ¡ ¡AcSvated, ¡aaer ¡being ¡loaded ¡in ¡the ¡card, ¡using ¡a ¡fault ¡injecSon ¡ ¡ ¡ ¡Consequence ¡: ¡modificaSon ¡of ¡the ¡loaded ¡code ¡behavior ¡to ¡a ¡hosSle ¡one ¡

MoSvaSon ¡

5 ¡

slide-10
SLIDE 10

Fault ¡Enabled ¡Viruses ¡

¡

¡

Fault ¡enabled ¡viruses ¡against ¡smart ¡cards ¡ Jean-­‑Louis ¡LANET ¡

Ques?on ¡: ¡ ¡Is ¡it ¡possible ¡to ¡hide ¡a ¡hosSle ¡code ¡inside ¡a ¡well-­‑ typed ¡program ¡and ¡then ¡acSvate ¡it ¡using ¡a ¡fault ¡injecSon ¡

  • nce ¡loaded ¡in ¡the ¡card? ¡

¡ Fault ¡enabled ¡viruses ¡construc?on ¡methodology ¡

MoSvaSon ¡

6 ¡

slide-11
SLIDE 11

Basic ¡idea ¡

¡

¡

Fault ¡enabled ¡viruses ¡against ¡smart ¡cards ¡ Jean-­‑Louis ¡LANET ¡

Inoffensive Code Inoffensive Code

Hostile Code Ins ?? Opcode

  • p1
  • p2

Hypothesis ¡ ¡

¡ ¡Byte ¡code ¡level ¡ ¡ ¡Fault ¡model ¡ ¡ ¡Precise ¡byte ¡error ¡ ¡ ¡Single ¡fault ¡ ¡ ¡ ¡BSR ¡(0x00) ¡ ¡ ¡ ¡Non-­‑encrypted ¡memory ¡

MoSvaSon ¡

7 ¡

slide-12
SLIDE 12

Basic ¡idea ¡

¡

¡

Fault ¡enabled ¡viruses ¡against ¡smart ¡cards ¡ Jean-­‑Louis ¡LANET ¡

To find the instructions sequence to add, at the beginning of the hostile code, respecting a set of defined constraints

Nop (0x00) Ins1

  • p2

Potentially a valid instruction

MoSvaSon ¡

8 ¡

Hypothesis ¡ ¡

¡ ¡Byte ¡code ¡level ¡ ¡ ¡Fault ¡model ¡ ¡ ¡Precise ¡byte ¡error ¡ ¡ ¡Single ¡fault ¡ ¡ ¡ ¡BSR ¡(0x00) ¡ ¡ ¡ ¡Non-­‑encrypted ¡memory ¡

Inoffensive Code Inoffensive Code

Hostile Code Ins ??

slide-13
SLIDE 13

Basic ¡idea ¡

¡

¡

Fault ¡enabled ¡viruses ¡against ¡smart ¡cards ¡ Jean-­‑Louis ¡LANET ¡ Ins …. Ins i …. Ins n

Inoffensive Code Code to hide

?? ?? ??

Start state Arrival state

Ins j

Path

Byte code Instructions

9 ¡

A Constraints Satisfaction Problem

MoSvaSon ¡

slide-14
SLIDE 14

Outline ¡

¡

¡

Fault ¡enabled ¡viruses ¡against ¡smart ¡cards ¡ Jean-­‑Louis ¡LANET ¡

¡ ¡Context ¡ ¡ ¡ ¡MoSvaSon ¡ ¡ ¡Example ¡: ¡Get ¡the ¡secret ¡key ¡ ¡ ¡The ¡proposed ¡approach ¡ ¡ ¡Concepts ¡ ¡ ¡Principal ¡ ¡ ¡Conclusion ¡and ¡future ¡work ¡

slide-15
SLIDE 15

Example ¡: ¡Get ¡the ¡secret ¡key ¡

¡

¡

Fault ¡enabled ¡viruses ¡against ¡smart ¡cards ¡ Jean-­‑Louis ¡LANET ¡

public void process (APDU apdu ) { short localS ; byte localB ; // get the APDU buffer byte [] apduBuffer = apdu.getBuffer (); if (selectingApplet ()) { return ; } byte receivedByte=(byte)apdu.setIncomingAndReceive(); // any code can be placed here // ... DES keys.getKey (apduBuffer , (short) 0) ; apdu.setOutgoingAndSend ((short) 0 ,16) ; }

B1 B2 ¡ B3 ¡

10 ¡

slide-16
SLIDE 16

Example ¡: ¡Get ¡the ¡secret ¡key ¡

¡

¡

Fault ¡enabled ¡viruses ¡against ¡smart ¡cards ¡ Jean-­‑Louis ¡LANET ¡

OFFSETS INSTRUCTIONS OPERANDS

... ... /*00d6*/ getfield_a_this 1 // DES keys /*00d8*/ aload 4 // L4=> apdubuffer /*00da*/ sconst_0 /*00db*/ invokeinterface nargs: 3, index: 0 , const: 3 , method :4 /*00e0*/ pop // returned byte ... ...

11 ¡

slide-17
SLIDE 17

Example ¡: ¡Get ¡the ¡secret ¡key ¡

¡

¡

Fault ¡enabled ¡viruses ¡against ¡smart ¡cards ¡ Jean-­‑Louis ¡LANET ¡

OFFSETS INSTRUCTIONS OPERANDS

. . . /*00d6*/ getfield_a_this 1 // DES keys /*00d8*/ aload 4 // L4=> apdubuffer /*00da*/ sconst_0 /*00db*/ invokeinterface nargs: 3, index: 2 , const:60 , method :4 /*00e0*/ pop // returned byte ... ...

12 ¡

slide-18
SLIDE 18

Example ¡: ¡Get ¡the ¡secret ¡key ¡

¡

¡

Fault ¡enabled ¡viruses ¡against ¡smart ¡cards ¡ Jean-­‑Louis ¡LANET ¡

OFFSETS INSTRUCTIONS OPERANDS

. . . /*00d6*/ getfield_a_this 1 // DES keys /*00d8*/ aload 4 // L4=> apdubuffer /*00da*/ sconst_0 /*00db*/ invokeinterface 03, 02, 3C, 04 /*00e0*/ pop // returned byte ... ...

12 ¡

slide-19
SLIDE 19

Example ¡: ¡Get ¡the ¡secret ¡key ¡

¡

¡

Fault ¡enabled ¡viruses ¡against ¡smart ¡cards ¡ Jean-­‑Louis ¡LANET ¡

OFFSETS INSTRUCTIONS OPERANDS

. . . /*00d6*/ getfield_a_this 1 // DES keys /*00d8*/ aload 4 // L4=> apdubuffer /*00da*/ sconst_0 /*00db*/ ifle ?? //no operand /*00dc*/ invokeinterface 03, 02, 3C, 04 /*00e1*/ pop // returned byte ... ...

13 ¡

slide-20
SLIDE 20

Example ¡: ¡Get ¡the ¡secret ¡key ¡

¡

¡

Fault ¡enabled ¡viruses ¡against ¡smart ¡cards ¡ Jean-­‑Louis ¡LANET ¡

OFFSETS INSTRUCTIONS OPERANDS

. . . /*00d6*/ getfield_a_this 1 // DES keys /*00d8*/ aload 4 // L4=> apdubuffer /*00da*/ sconst_0 /*00db*/ ifle 8E //was the code of invokeinterface /*00dd*/ sconst_0 // op1: 03 /*00de*/ sconst_m1 // op2: 02 /*00df*/ pop2 // op3: 3C /*00e0*/ sconst_1 // op4: 04 /*00e1*/ pop // returned byte ... ...

13 ¡

slide-21
SLIDE 21

Example ¡: ¡Get ¡the ¡secret ¡key ¡

¡

¡

Fault ¡enabled ¡viruses ¡against ¡smart ¡cards ¡ Jean-­‑Louis ¡LANET ¡

OFFSETS INSTRUCTIONS OPERANDS

. . . /*00d6*/ getfield_a_this 1 // DES keys /*00d8*/ aload 4 // L4=> apdubuffer /*00da*/ sconst_0 /*00db*/ ifle 8E /*00dd*/ sconst_0 // op1: 03 /*00de*/ sconst_m1 // op2: 02 /*00df*/ pop2 // op3: 3C /*00e0*/ sconst_1 // op4: 04 /*00e1*/ pop // returned byte ... ...

14 ¡

slide-22
SLIDE 22

Example ¡: ¡Get ¡the ¡secret ¡key ¡

¡

¡

Fault ¡enabled ¡viruses ¡against ¡smart ¡cards ¡ Jean-­‑Louis ¡LANET ¡

OFFSETS INSTRUCTIONS OPERANDS

. . . /*00d6*/ getfield_a_this 1 // DES keys /*00d8*/ aload 4 // L4=> apdubuffer /*00da*/ sconst_0 /*00db*/ nop 8E /*00dd*/ sconst_0 // op1: 03 /*00de*/ sconst_m1 // op2: 02 /*00df*/ pop2 // op3: 3C /*00e0*/ sconst_1 // op4: 04 /*00e1*/ pop // returned byte ... ...

14 ¡

slide-23
SLIDE 23

Example ¡: ¡Get ¡the ¡secret ¡key ¡

¡

¡

Fault ¡enabled ¡viruses ¡against ¡smart ¡cards ¡ Jean-­‑Louis ¡LANET ¡

OFFSETS INSTRUCTIONS OPERANDS

. . . /*00d6*/ getfield_a_this 1 /*00d8*/ aload 4 /*00da*/ sconst_0 /*00db*/ nop /*00dc*/ invokeinterface 03, 02, 3C, 04 /*00e0*/ pop // returned byte ... ...

14 ¡

slide-24
SLIDE 24

Outline ¡

¡

¡

Fault ¡enabled ¡viruses ¡against ¡smart ¡cards ¡ Jean-­‑Louis ¡LANET ¡

¡ ¡Context ¡ ¡ ¡ ¡MoSvaSon ¡ ¡ ¡Example ¡: ¡Get ¡the ¡secret ¡key ¡ ¡ ¡The ¡proposed ¡approach ¡ ¡ ¡Concepts ¡ ¡ ¡Principal ¡ ¡ ¡Conclusion ¡and ¡future ¡work ¡

slide-25
SLIDE 25

¡

¡

Fault ¡enabled ¡viruses ¡against ¡smart ¡cards ¡ Jean-­‑Louis ¡LANET ¡

¡ ¡Explicit ¡enumeraSon ¡(exhausSve ¡search) ¡ ¡depth ¡first ¡ ¡ ¡ ¡ ¡ ¡=> ¡ExponenSal ¡increasing ¡of ¡possible ¡soluSons ¡number ¡ ¡ ¡ ¡Intelligent ¡enumeraSon ¡ ¡=> ¡Combinatorial ¡OpSmizaSon ¡domain ¡ ¡ (Search ¡techniques) ¡

  • ¡ ¡Model ¡our ¡problem ¡as ¡a ¡Search ¡Tree ¡ ¡
  • ¡ ¡Create ¡and ¡explore ¡the ¡tree ¡nodes ¡using ¡a ¡Branch ¡& ¡Bound ¡method ¡
  • ¡ ¡Paths ¡from ¡the ¡root ¡to ¡the ¡leaves ¡represent ¡possible ¡wanted ¡sequences ¡

The ¡proposed ¡approach ¡

15 ¡

slide-26
SLIDE 26

Concepts ¡

¡

¡

Fault ¡enabled ¡viruses ¡against ¡smart ¡cards ¡ Jean-­‑Louis ¡LANET ¡

¡ ¡Byte ¡code ¡instruc?on ¡

  • ¡Pre-­‑condiSon ¡
  • ¡Post-­‑condiSon ¡
  • ¡Operands ¡number ¡

¡ ¡Memory ¡state ¡

  • ¡Operand ¡stack ¡ ¡(with ¡size ¡maxStack) ¡
  • ¡Local ¡variables ¡stack ¡(with ¡size ¡maxLoc) ¡
  • ¡StackPointer ¡or ¡SP ¡(that ¡indicates ¡the ¡top ¡of ¡the ¡stack) ¡
  • ¡PC ¡(the ¡program ¡counter) ¡ ¡
  • ¡The ¡instrucSon ¡being ¡executed ¡(its ¡opcode) ¡

¡ ¡Some ¡constraints ¡(to ¡respect ¡while ¡adding ¡instrucSons ¡) ¡ ¡

  • ¡No ¡underflow/overflow ¡on ¡the ¡stack ¡ ¡ ¡
  • ¡The ¡post-­‑condiSon ¡of ¡the ¡candidate ¡instrucSon ¡(the ¡one ¡being ¡added) ¡ ¡

¡ ¡ ¡is ¡compaSble ¡with ¡the ¡current ¡stack ¡state ¡ ¡

  • ¡ ¡The ¡maxLoc ¡parameter ¡is ¡respected ¡
  • ¡ ¡…. ¡ ¡

The ¡proposed ¡approach ¡

16 ¡

slide-27
SLIDE 27

Principal ¡

¡

¡

Fault ¡enabled ¡viruses ¡against ¡smart ¡cards ¡

Jean-­‑Louis ¡LANET ¡

The ¡proposed ¡approach ¡

17 ¡

I0 … I i … … … I j … I n

Arrival memory state Ei ¡ Start memory state Ej ¡ Byte code Instructions list (Opcode, PRE, POST, Params)

Sequence to find Known sequence Known sequence

Input

slide-28
SLIDE 28

Principal ¡

¡

¡

Fault ¡enabled ¡viruses ¡against ¡smart ¡cards ¡ Jean-­‑Louis ¡LANET ¡

The ¡proposed ¡approach ¡

18 ¡

Construction

Ij

Choice 1 Choice 2 Choice n

I j-1 :

Arrival memory state Ei ¡ Start memory state Ej ¡ Bytecode Instructions list (Opcode, PRE, POST, Params) Sequence to find Known sequence Known sequence

Input

I0 … I i … … … I j … I n

Candidate instructions

Search Tree ¡ ¡Search ¡Tree ¡: ¡

  • ¡Root ¡: ¡The ¡beginning ¡of ¡the ¡hosSle ¡code ¡
  • ¡Intermediate ¡nodes ¡: ¡candidate ¡instrucSons ¡

(Those ¡respecSng ¡the ¡defined ¡constraints) ¡

  • ¡Leaves ¡: ¡Desired ¡state ¡(Reach ¡the ¡end ¡of ¡the ¡

inoffensive ¡code) ¡ ¡ ¡

¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡

slide-29
SLIDE 29

¡ ¡Search ¡Tree ¡: ¡

  • ¡Root ¡: ¡The ¡beginning ¡of ¡the ¡hosSle ¡code ¡
  • ¡Intermediate ¡nodes ¡: ¡candidate ¡instrucSons ¡

(Those ¡respecSng ¡the ¡defined ¡constraints) ¡

  • ¡Leaves ¡: ¡Desired ¡state ¡(Reach ¡the ¡end ¡of ¡the ¡

inoffensive ¡code) ¡ ¡ ¡

¡ ¡ExploraSon: ¡Depth ¡First ¡Strategy ¡ ¡with ¡2 ¡ bounds ¡(depth, ¡nb ¡soluSon) ¡ ¡ ¡The ¡selecSon ¡of ¡the ¡node ¡to ¡explore ¡: ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡HeurisScs ¡(staSsScal ¡analysis ¡data, ¡the ¡ ¡ ¡ ¡ ¡ ¡ ¡most ¡greedy ¡instrucSon, ¡etc) ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡

Principal ¡

¡

¡

Fault ¡enabled ¡viruses ¡against ¡smart ¡cards ¡ Jean-­‑Louis ¡LANET ¡

The ¡proposed ¡approach ¡

18 ¡

Ij

Choice 1 Choice 2 Choice n Choice1 Choice n Choice ? Choice ? Choice? Choice ?

… … …

Choice 1

… … …… …… ……

I j-1 : I i-1 : I j-2 :

Candidate instructions

Search Tree

slide-30
SLIDE 30

Principal ¡

¡

¡

Fault ¡enabled ¡viruses ¡against ¡smart ¡cards ¡ Jean-­‑Louis ¡LANET ¡

The ¡proposed ¡approach ¡

19 ¡

Son 1 Son 2 … Son n Parent ¡

¡

Operand Stack ¡ Local variables ¡ SP ¡ I j ¡

Data ¡ Pointer ¡to ¡the ¡parent ¡node ¡ ¡ ¡ ¡ ¡ ¡ ¡ Pointers ¡to ¡the ¡possible ¡sons ¡ (candidate ¡instrucSons) ¡

  • Fig. Node structure

¡ ¡

slide-31
SLIDE 31

Principal ¡

¡

¡

Fault ¡enabled ¡viruses ¡against ¡smart ¡cards ¡ Jean-­‑Louis ¡LANET ¡

The ¡proposed ¡approach ¡

20 ¡

Son 1 Son 2 … Son n

Parent ¡

¡

Operand Stack ¡ Local variables ¡ SP ¡ I j ¡

……

…… ……

Son 1 Son 2 … Son n

Parent ¡

¡

Operand Stack ¡ Local variables ¡ SP ¡ I j ¡

Son 1 Son 2 … Son n

Parent ¡

¡

Operand Stack ¡ Local variables ¡ SP ¡ I j ¡

Son 1 Son 2 … Son n

Parent ¡

¡

Operand Stack ¡ Local variables ¡ SP ¡ I j ¡

Son 1 Son 2 … Son n

Parent ¡

¡

Operand Stack ¡ Local variables ¡ SP ¡ I j ¡

Son 1 Son 2 … Son n

Parent ¡

¡

Operand Stack ¡ Local variables ¡ SP ¡ I j ¡

…… …… …………….

Son 1 Son 2 … Son n

¡ ¡1 ¡path ¡=> ¡1 ¡candidate ¡ sequence ¡ ¡ ¡Next ¡step ¡: ¡verify ¡that ¡this ¡ code ¡may ¡be ¡generated ¡by ¡a ¡ compiler ¡(Code ¡Reverse: ¡.cap ¡ to ¡.class ¡to ¡.java) ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ Search Tree

slide-32
SLIDE 32

Current ¡state ¡

¡

¡

Fault ¡enabled ¡viruses ¡against ¡smart ¡cards ¡ Jean-­‑Louis ¡LANET ¡

¡ ¡ ¡ExhausSve ¡search ¡possible ¡for ¡a ¡given ¡state, ¡

¡ ¡for ¡a ¡sequence ¡less ¡or ¡equal ¡to ¡5, ¡ ¡ ¡ ¡circa ¡250 ¡soluSons. ¡ ¡ ¡A ¡sequence ¡of ¡length ¡25, ¡bounded ¡to ¡25 ¡soluSons, ¡less ¡than ¡one ¡ second, ¡ ¡ ¡The ¡best ¡current ¡heurisSc ¡: ¡delta ¡min, ¡ ¡ ¡First ¡opSmizaSon: ¡memory ¡freeing. ¡

¡ ¡ ¡ ¡ ¡ ¡

21 ¡

slide-33
SLIDE 33

Outline ¡

¡

¡

Fault ¡enabled ¡viruses ¡against ¡smart ¡cards ¡ Jean-­‑Louis ¡LANET ¡

¡ ¡Context ¡ ¡ ¡ ¡MoSvaSon ¡ ¡ ¡Example ¡: ¡Get ¡the ¡secret ¡key ¡ ¡ ¡The ¡proposed ¡approach ¡ ¡ ¡Concepts ¡ ¡ ¡Principal ¡ ¡ ¡Conclusion ¡and ¡future ¡work ¡

slide-34
SLIDE 34

Conclusion ¡and ¡future ¡work ¡

¡

¡

Fault ¡enabled ¡viruses ¡against ¡smart ¡cards ¡ Jean-­‑Louis ¡LANET ¡

¡ ¡ ¡It ¡is ¡possible ¡to ¡hide ¡a ¡hosSle ¡code ¡inside ¡an ¡inoffensive ¡one ¡

¡ ¡SaSsfacSon ¡Constraints ¡Problem ¡ ¡ ¡A ¡search ¡Tree-­‑based ¡approach ¡is ¡proposed ¡for ¡sequences ¡ construcSon ¡ ¡ ¡Ongoing ¡work ¡ ¡ ¡Improvement ¡of ¡byte ¡code ¡sequences ¡generaSon ¡tool ¡ ¡ ¡ ¡Experimental ¡evaluaSon ¡of ¡our ¡approach ¡(collecSng ¡metrics, ¡ ¡ ¡ ¡ ¡ ¡ ¡comparison ¡between ¡the ¡different ¡heurisScs, ¡etc) ¡

¡ ¡ ¡ ¡ ¡ ¡

21 ¡

slide-35
SLIDE 35

References ¡

¡

¡

Fault ¡enabled ¡viruses ¡against ¡smart ¡cards ¡ Jean-­‑Louis ¡LANET ¡

[1] ¡S. ¡Hamadouche, ¡J.L. ¡Lanet, ¡“Virus ¡in ¡a ¡smart ¡card: ¡Myth ¡or ¡reality?”, ¡Journal ¡of ¡InformaSon ¡ Security ¡and ¡ApplicaSons, ¡September ¡2013, ¡h]p://dx.doi.org/10.1016/j.jisa.2013.08.005. ¡ ¡ [2] ¡S. ¡Hamadouche, ¡M. ¡Mezghiche, ¡A. ¡Gotlieb, ¡J.L. ¡Lanet, ¡“Vers ¡une ¡approche ¡de ¡construcCon ¡de ¡ virus ¡pour ¡cartes ¡à ¡puce ¡basée ¡sur ¡la ¡résoluCon ¡de ¡contraintes”, ¡In ¡proceedings ¡of ¡AFADL’14, ¡ Paris, ¡June ¡2014. ¡

slide-36
SLIDE 36

¡

¡

Fault ¡enabled ¡viruses ¡against ¡smart ¡cards ¡ Jean-­‑Louis ¡LANET ¡

Thank ¡you ¡for ¡your ¡aVen?on ¡

hamadouche-samiya@umbb.dz jean-louis.lanet@inria.fr samiya.hamadouche@edu.unilim.fr