Machine learning techniques for sidechannel analysis Annelie Heuser
Outline Side-channel analysis and its terminology Dictionary: Side-channel to Machine learning When can machine learning be helpful? New application: semi-supervised learning
Side-channel analysis cryptography Alice Bob
Side-channel analysis cryptography Alice Bob
Time Sound electromagnetic emanation Side-channel analysis cryptography Alice Bob Side-channel information
Time Sound electromagnetic emanation Side-channel analysis cryptography Alice Bob Side-channel information secret key / sensitive data
<latexit sha1_base64="m1tlk1rdxvlqnsyqch6w9bmgyny=">aaacfhicbzdlsgmxfiyzxmu9vv26crahkpqzexrzdooyor1ap5zmmrahmwrizkjl0idw46u4cagiwxfufbvtarfa+kpgy3/oitl/ealuwhw/nyxfpewv1cxadn1jc2s7t7nbnsrwlfwoekrxa2ky4jjvging9ugzegac1yl+1bhee2daccxvybixzki6knc4jwctvu4e+8agajdcbmowkqs3jbkeyzgnsk8iervcvz8+auxybtfnhefbm0ietvvu5b78tqjxycrqqyxpeg4ezyro4fswudapdysi7zmua1iujgsmmarljfchddq4o7q9endq/p5isgjmmaxsz0igz2zry/o/wiogzkuz4tkkgu Side-channel analysis Measurement setup AES 128 attacking SBox operation in the first round key enumeration feasible
Side-channel analysis Hamming weight model Electromagnetic emanation easily distinguishable regarding HW of intermediate operation Probability 0.12 0.1 0.08 0.06 0.04 0.02 0 0.400 0.350 0.300 0.250 Power Consumption At Time A HW 0 HW 1 HW 2 HW 3 HW 4 HW 5 HW 6 HW 7 HW 8
Side-channel attacks are real in practice Beginning 2016: FBI asks Apple to bypass their encryption Handful methods to break into the encrypted iphone software bugs side-channel attacks glitch attack invasive attacks Documents released by Snowden: NSA is studying the use of side-channel attacks to break into iphones
Side-channel attacks are real in practice attacking Philips Hue smart lamps side-channel attack revealed the global AES-CCM key used to encrypt and verify firmware updates insert malicious update: lamps infect each other with a worm that has the potential to control the device Paper: Eyal Ronen et al, IoT Goes Nuclear: Creating a ZigBee Chain Reaction
Side-channel analysis unprofiled / profiled measurement traces point in time / point of interest intermediate operations / sensitive variable / leakage model distinguisher / attack success rate / guessing entropy
Side-channel analysis unprofiled / profiled measurement traces point in time / point of interest intermediate operations / sensitive variable / leakage model distinguisher / attack success rate / guessing entropy
Side-channel analysis unprofiled / profiled measurement traces point in time / point of interest intermediate operations / sensitive variable / leakage model distinguisher / attack success rate / guessing entropy
Side-channel analysis unprofiled / profiled measurement traces point in time / point of interest intermediate operations / sensitive variable / leakage model distinguisher / attack success rate / guessing entropy
Side-channel analysis to machine learning unprofiled / profiled measurement trace unsupervised / supervised data point in time / point of interest feature intermediate operations / sensitive variable / leakage model label distinguisher / attack classification algorithm success rate / guessing entropy accuracy
Machine learning techniques as side-channel attacks Input: data, labels points of interest from the measurement trace leakage models (intermediate operations) Mainly in supervised scenarios: support vector machines, random forest, Naive Bayes, deep learning
Machine learning techniques as side-channel attacks Input: data, labels points of interest from the measurement trace leakage models (intermediate operations) Mainly in supervised scenarios: support vector machines, random forest, Naive Bayes, deep learning Nature of side-channel leakage is still unknown
Machine learning techniques as side-channel attacks Input: data, labels points of interest from the measurement trace leakage models (intermediate operations) Mainly in supervised scenarios: support vector machines, random forest, Naive Bayes, deep learning Nature of side-channel leakage is still unknown Advantages: suitable in unperfect scenarios more resistant to imprecisions
Machine learning techniques as side-channel attacks Input: data, labels points of interest from the measurement trace leakage models (intermediate operations) Mainly in supervised scenarios: support vector machines, random forest, Naive Bayes, deep learning Nature of side-channel leakage is still unknown Advantages: suitable in unperfect scenarios more resistant to imprecisions Disadvantages: time / computational complexity (additional tuning) community is not yet trusting ( only empirical results )
New perspective Traditional profiled scenario: realistic?
New perspective Semi-supervised learning: a more realistic assessment
Semi-supervised learning Techniques for label prediction: self-training label spreading Classification algorithms: Support vector machines Naive Bayes Template attack (standard + pooled version)
Semi-supervised learning Techniques for label prediction: self-training label spreading Classification algorithms: Support vector machines Naive Bayes Datasets (13 k in total) 100 labeled + 12.9k unlabeled 500 labeled + 12.5k unlabeled 1k labeled + 12k unlabeled 3k labeled + 10k unlabeled 5k labeled + 8k unlabeled 10k labeled + 3k unlabeled Template attack (standard + pooled version)
Semi-supervised learning Techniques for label prediction: self-training label spreading Classification algorithms: Support vector machines Naive Bayes Datasets (13 k in total) 100 labeled + 12.9k unlabeled 500 labeled + 12.5k unlabeled 1k labeled + 12k unlabeled 3k labeled + 10k unlabeled 5k labeled + 8k unlabeled 10k labeled + 3k unlabeled Template attack (standard + pooled version)
<latexit sha1_base64="ulifhbkwc1zgeczihcyner2tpjg=">aaadvxicbzlbbtnaeiadhemtdk3hkpsvkrfxq12ffuvbbhasqkhpwqmoovvmk67ik+w1kjg8gg/cg/ayjgmnptgsvepz75/9nd4gdwwucpntancepx7ydk/be/b8xcv9/sgrcz4ugrfnpamt7djguqhllm6vvkg4tdpboiauf8hyy7v/8v1kuuzikvqlyhkxrsznkjmfpelb67cfiiwms8wcimtzukxlgj0erx+ljcuojlfw3xvd63a7z/knqeo0ja8nnx9n4y/1x+gy1thx4tq9rmj3ka+snctcuekpiuamku2xrwhxmhfarlbbkrfpyzocpkktlwphzxgiv8coqvgzqm0xyqhh6rlvrildaova2lkbodgwktyxmdub1niidtahn0c2cmrhvuahg711cio60m7tmakc6nituqs73tyawdaoi4khqif1uzbrbva4bguagjvusdeoawagmueb1de3y4vkrbmbl+lz7m9n+wmcrqpadxpajaotidnp/68/s3grivjxkox5fswpmpqsu5khyt3zi1ykjc/zqlxbgrni5jnyc8/w6b1uzmiezpdecm2qtxuli/j8fqvarkxd5/f3qul/9q4knxcnpyztqomy1wfnixcpbfwxfs1kjrgkv5awnknwivg1yxhxclxvnbikyrkgk697mbp6fxapk7gokch0mz44ommgtke90d5q7zwqodqr9kk71c413j5sf <latexit sha1_base64="btlmprbiabm1cd/t4w12ailntey=">aaafsnichzrlb9qwemft7hba8mrhymwizyvuydl5ommtlatcahx1ktvv5ws9bzsnegephhwovgd3xa1unlkhloyt3e1uw4mrik/gf/9mphbi53fyskk+lyz2+kt37i6vrn67/+dho7x1x4dlvhwboaiyocuofv6koezfgqxlli7zqvdej8wrh71w80cfrvggwbovl3nxmvdznbyfazcqolvvvv3xfheeprxkfhxzoqnzmmiwjm1n5djgxi0euzpjfwxn6srkxvhjilaber+djjzae4fvrl72x115m2f5jpou6istym7ynvm85mksl6pyqn4bbjiqlih0qers2mzqokkrdgr0uhy8tmp0vffzbpxf3bcxklurh51q0znwokztqraojt1ieswxe3oagaz6anwwgx23gxjnbgxztbczpluysqhstezcqb1smwjrfbph8wbpduirrtkgqtvajo4dqpamm71f2gw7bijkfrzg2qgygvcqmtu2kohoxkbbtgaaatca95q5rdaxmswam02skw7syn2zgm1sk5wjcwtpog6bbektq6uaqcuzvao27hjsmapcaxqiqaal7urslup1wkxyacuftbi2uw1jk3znilaccf1riqn6hsptttjstqignuu13snvwlqjoqrrow7/jnoyziplnqgnbcmmbcaxjetw6rwtdspgmjucntlr2bm3wrppcprlnk1teexaqzcdony2tlhtnq398ozzucuiluhmy/keklye1rya6xilztwrsphzioln4gtclceipk3bj75bzyeyrkosgcevqi3orqh5upaxiq/khmul8vqcct42d1ljkxnah2leszegxajrfsozifuhqcoweigml8hhqrfcrsi44aupjpxn5rl4wrzbc8pmfvpdrzfipnoowz3d9io+sb0zbtky9lr7pr3qqgzr29obbvc70ilel9633o/ez/7x/u/+n/7ftrq4mf7zrjuzpf4/ib1fgg==</latexit> Semi-supervised learning Supervised Semi-supervised
Semi-supervised learning Influence of noise: in high noise scenarios this approach may not be beneficial, optimal signal-to-noise ratio? Number of measurements: in which restricted (practical) scenarios semisupervised learning is beneficial? Number of classes: what is the amount of classes where label predictions can be beneficial? Misclassification of labels: how to limit misclassification of labels? which algorithms cope best with misclassification? Generalisation of models: What are the benefits when considering leakage measurements from different devices and therefore with different leakage distributions?
Questions? annelie.heuser@irisa.fr
Countermeasures
Countermeasures Implementation level countermeasures: masking: adding additional randomness hiding: adding additional noise, decreasing signal-to-noise ratio drawbacks: high implementation overhead, depending on cryptographic primitive
Countermeasures Implementation level countermeasures: masking: adding additional randomness hiding: adding additional noise, decreasing signal-to-noise ratio drawbacks: high implementation overhead, depending on cryptographic primitive Protocol level: Leakage-Resilience modelling attackers with the capability to monitor side-channel information require a side-channel secure initialization in order to obtain a fresh session key for every cryptographic operation drawback: mostly theoretical, not been tested (thoroughly) in practice yet