symmetric encrypbon cs642 computer security
play

Symmetric encrypBon CS642: Computer Security Professor - PowerPoint PPT Presentation

Symmetric encrypBon CS642: Computer Security Professor Ristenpart h9p://www.cs.wisc.edu/~rist/ rist at cs dot wisc dot edu University of Wisconsin CS 642


  1. Symmetric ¡encrypBon ¡ CS642: ¡ ¡ Computer ¡Security ¡ Professor ¡Ristenpart ¡ h9p://www.cs.wisc.edu/~rist/ ¡ rist ¡at ¡cs ¡dot ¡wisc ¡dot ¡edu ¡ University ¡of ¡Wisconsin ¡CS ¡642 ¡

  2. Symmetric ¡encrypBon ¡ key ¡generaBon ¡ R k ¡ Kg ¡ Handled ¡ in ¡TLS ¡key ¡ exchange ¡ K ¡ OpBonal ¡ R ¡ M ¡or ¡ ¡ Enc ¡ C ¡ C ¡ Dec ¡ error ¡ M ¡ C ¡is ¡a ¡ciphertext ¡ Correctness: ¡ ¡D( ¡K ¡, ¡E(K,M,R) ¡) ¡= ¡M ¡ ¡with ¡probability ¡1 ¡over ¡randomness ¡used ¡

  3. In ¡TLS ¡symmetric ¡encrypBon ¡underlies ¡the ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡Record ¡Layer ¡ h9p://amazon.com ¡ K ¡ K ¡ R ¡ M ¡or ¡ ¡ C’ ¡ Dec ¡ Enc ¡ C ¡ error ¡ M ¡ What ¡security ¡properBes ¡do ¡we ¡need ¡from ¡symmetric ¡encrypBon? ¡ 1) ¡ConfidenBality: ¡should ¡not ¡learn ¡any ¡informaBon ¡about ¡M ¡ 2) ¡AuthenBcity: ¡ ¡should ¡not ¡be ¡able ¡to ¡forge ¡messages ¡ O[en ¡referred ¡to ¡as ¡AuthenBcated ¡EncrypBon ¡security ¡ ¡

  4. Back ¡to ¡our ¡applicaBon ¡ h9p://amazon.com ¡ Internet ¡ ¡M ¡ ¡ ¡ ¡K ¡ Does ¡OTP ¡provide ¡a ¡secure ¡channel? ¡ Integrity ¡easily ¡violated ¡ Reuse ¡of ¡K ¡for ¡messages ¡M,M’ ¡ ¡leaks ¡M ¡ ¡ ¡ ¡ ¡M’ ¡ EncrypBng ¡same ¡message ¡twice ¡under ¡K ¡leaks ¡the ¡message ¡equality ¡ K ¡must ¡be ¡as ¡large ¡as ¡message ¡ Message ¡length ¡revealed ¡

  5. Cryptography ¡as ¡computaBonal ¡science ¡ Use ¡computaBonal ¡intractability ¡as ¡basis ¡for ¡confidence ¡in ¡systems ¡ 1. ¡Design ¡a ¡cryptographic ¡scheme ¡ 2. ¡Provide ¡proof ¡that ¡no ¡a9acker ¡ Goldwasser, ¡Micali ¡ ¡and ¡Blum ¡circa ¡1980’s ¡ with ¡limited ¡computaBonal ¡resources ¡ can ¡break ¡it ¡ Example: ¡ Security ¡proofs ¡(reducBons) ¡ Formal ¡definiBons ¡ A9acker ¡can ¡not ¡ ¡ A9acker ¡can ¡ ¡ Breaking ¡scheme ¡ Scheme ¡semanBcs ¡ recover ¡credit ¡card ¡ recover ¡credit ¡card ¡ Security ¡ Can ¡factor ¡ Can ¡not ¡factor ¡ Breaking ¡assumpBons ¡ large ¡composite ¡ large ¡composite ¡ As ¡long ¡as ¡assumpBons ¡holds ¡ numbers ¡ numbers ¡ we ¡believe ¡ ¡in ¡security ¡of ¡scheme! ¡ But ¡no ¡one ¡knows ¡how ¡to ¡ Provable ¡security ¡yields ¡ do ¡this. ¡It’s ¡been ¡studied ¡ 1) ¡well-­‑defined ¡assumpBons ¡and ¡security ¡goals ¡ for ¡a ¡very ¡long ¡Bme! ¡ 2) ¡cryptanalysts ¡can ¡focus ¡on ¡assumpBons ¡and ¡models ¡

  6. Typical ¡assumpBons ¡ • Basic ¡atomic ¡primiBves ¡are ¡hard ¡to ¡break: ¡ – Factoring ¡of ¡large ¡composites ¡intractable ¡ – RSA ¡permutaBon ¡hard-­‑to-­‑invert ¡ – Block ¡ciphers ¡(AES, ¡DES) ¡are ¡good ¡pseudorandom ¡ funcBons ¡(PRFs) ¡ – Hash ¡funcBons ¡are ¡collision ¡resistant ¡ Confidence ¡in ¡atomic ¡primiBves ¡is ¡gained ¡by ¡cryptanalysis, ¡ public ¡design ¡compeBBons ¡

  7. Block ¡ciphers ¡ key ¡generaBon ¡ Implements ¡ Key ¡is ¡a ¡uniformly ¡ ¡ R ¡ Kg ¡ a ¡family ¡of ¡permutaBons ¡ ¡ selected ¡bit ¡string ¡of ¡ on ¡n ¡bit ¡strings, ¡ length ¡k ¡ one ¡permutaBon ¡for ¡each ¡K ¡ K ¡ M ¡ E ¡ C ¡ C ¡ D ¡ M ¡ E: ¡{0,1} k ¡x ¡{0,1} n ¡-­‑> ¡{0,1} n ¡ Security ¡goal: ¡ ¡ ¡ ¡E(K,M) ¡is ¡indisBnguishable ¡from ¡random ¡n-­‑bit ¡string ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡for ¡anyone ¡without ¡K ¡

  8. Block ¡cipher ¡security ¡ E: ¡{0,1} k ¡x ¡{0,1} n ¡-­‑> ¡{0,1} n ¡ PRF ¡Security ¡Game ¡ Adversary ¡gets ¡to ¡submit ¡ M 1 ¡ dis$nct ¡messages ¡to ¡oracle ¡ Fn(M) ¡ C 1 ¡ If ¡b ¡== ¡1 ¡then ¡ ¡ M 2 ¡ ¡ ¡ ¡ ¡ ¡ ¡C ¡<-­‑ ¡E(K,M) ¡ C 2 ¡ If ¡b ¡== ¡0 ¡then ¡ b' ¡ ¡ ¡ ¡ ¡ ¡ ¡C ¡<-­‑$ ¡{0,1} n ¡ … ¡ Ret ¡C ¡ Adversary ¡outputs ¡guess ¡b’ ¡of ¡b ¡ b ¡is ¡a ¡uniformly ¡sampled ¡bit ¡ ¡ Wins ¡if ¡b’ ¡= ¡b ¡ and ¡K ¡is ¡uniformly ¡sampled ¡key ¡ Insecure ¡if ¡adversary ¡wins ¡with ¡probability ¡close ¡to ¡1 ¡ Both ¡hidden ¡from ¡adversary ¡ Secure ¡if ¡no ¡adversary ¡can ¡get ¡probability ¡more ¡than ¡1/2 ¡ Security ¡goal: ¡ ¡ ¡ ¡E(K,M) ¡is ¡indisBnguishable ¡from ¡random ¡n-­‑bit ¡string ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡for ¡anyone ¡without ¡K ¡

  9. One-­‑Bme ¡pad ¡is ¡not ¡a ¡secure ¡PRF ¡ PRF ¡Security ¡Game ¡ Adversary ¡gets ¡to ¡submit ¡ M 1 ¡ dis$nct ¡messages ¡to ¡oracle ¡ Fn(M) ¡ C 1 ¡ If ¡b ¡== ¡1 ¡then ¡ ¡ M 2 ¡ ¡ ¡ ¡ ¡ ¡ ¡C ¡<-­‑ ¡K ¡ ¡ ¡ ¡ ¡M ¡ C 2 ¡ If ¡b ¡== ¡0 ¡then ¡ b' ¡ ¡ ¡ ¡ ¡ ¡ ¡C ¡<-­‑$ ¡{0,1} n ¡ … ¡ Ret ¡C ¡ Adversary ¡outputs ¡guess ¡b’ ¡of ¡b ¡ b ¡is ¡a ¡uniformly ¡sampled ¡bit ¡ ¡ Wins ¡if ¡b’ ¡= ¡b ¡ and ¡K ¡is ¡uniformly ¡sampled ¡key ¡ Insecure ¡if ¡adversary ¡wins ¡with ¡probability ¡close ¡to ¡1 ¡ Both ¡hidden ¡from ¡adversary ¡ Secure ¡if ¡no ¡adversary ¡can ¡get ¡probability ¡more ¡than ¡1/2 ¡ Security ¡goal: ¡ ¡ ¡ ¡E(K,M) ¡is ¡indisBnguishable ¡from ¡random ¡n-­‑bit ¡string ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡for ¡anyone ¡without ¡K ¡

  10. One-­‑Bme ¡pad ¡is ¡not ¡a ¡secure ¡PRF ¡ Adversary ¡gets ¡to ¡submit ¡ PRF ¡Security ¡Game ¡ dis$nct ¡messages ¡to ¡oracle ¡ M 1 ¡ = ¡1 n ¡ Fn(M) ¡ C 1 ¡ Adversary ¡ If ¡b ¡== ¡1 ¡then ¡ ¡ C 1 ¡<-­‑ ¡Fn(1 n ) ¡ M 2 ¡ ¡= ¡1 n-­‑1 0 ¡ ¡ ¡ ¡ ¡ ¡ ¡C ¡<-­‑ ¡K ¡ ¡ ¡ ¡ ¡M ¡ C 2 ¡<-­‑ ¡Fn(1 n-­‑1 0) ¡ C 2 ¡ If ¡b ¡== ¡0 ¡then ¡ If ¡C 1 ¡ ¡ ¡ ¡C 2 ¡== ¡0 n-­‑1 1 ¡then ¡ ¡ ¡ ¡ ¡ ¡ ¡C ¡<-­‑$ ¡{0,1} n ¡ ¡ ¡ ¡ ¡ ¡ ¡Ret ¡1 ¡ Ret ¡C ¡ Ret ¡0 ¡ Adversary ¡outputs ¡guess ¡b’ ¡of ¡b ¡ b ¡is ¡a ¡uniformly ¡sampled ¡bit ¡ ¡ Wins ¡if ¡b’ ¡= ¡b ¡ and ¡K ¡is ¡uniformly ¡sampled ¡key ¡ Insecure ¡if ¡adversary ¡wins ¡with ¡probability ¡close ¡to ¡1 ¡ Both ¡hidden ¡from ¡adversary ¡ Secure ¡if ¡no ¡adversary ¡can ¡get ¡probability ¡more ¡than ¡1/2 ¡ If ¡b ¡= ¡1 ¡then: ¡ C 1 ¡ ¡ ¡ ¡ ¡ ¡C 2 ¡ ¡ ¡= ¡(1 n ¡ ¡ ¡ ¡ ¡K) ¡ ¡ ¡ ¡ ¡ ¡ ¡(1 n-­‑1 0 ¡ ¡ ¡ ¡ ¡ ¡K) ¡ ¡ ¡ ¡ ¡= ¡ ¡ ¡0 n-­‑1 1 ¡ If ¡b ¡= ¡0 ¡then ¡C 1 ¡ ¡and ¡C 2 ¡ ¡are ¡both ¡random ¡n-­‑bit ¡strings. ¡Their ¡xor ¡equals ¡0 n-­‑1 1 ¡ ¡ with ¡probability ¡at ¡most ¡1/2 n ¡

  11. Data ¡encrypBon ¡standard ¡(DES) ¡ L0 ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡R0 ¡ Originally ¡called ¡Lucifer ¡ -­‑ team ¡at ¡IBM ¡ F K1 ¡ -­‑ input ¡from ¡NSA ¡ -­‑ standardized ¡by ¡NIST ¡ ¡in ¡1976 ¡ + L1 ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡R1 ¡ n ¡= ¡64 ¡ Number ¡of ¡keys: ¡ k ¡= ¡56 ¡ 72,057,594,037,927,936 ¡ F K2 ¡ Split ¡64-­‑bit ¡input ¡into ¡L0,R0 ¡of ¡32 ¡bits ¡each ¡ Repeat ¡Feistel ¡round ¡16 ¡Bmes ¡ + Each ¡round ¡applies ¡funcBon ¡F ¡using ¡ ¡ L2 ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡ ¡R2 ¡ separate ¡round ¡key ¡ … ¡ … ¡

Download Presentation
Download Policy: The content available on the website is offered to you 'AS IS' for your personal information and use only. It cannot be commercialized, licensed, or distributed on other websites without prior consent from the author. To download a presentation, simply click this link. If you encounter any difficulties during the download process, it's possible that the publisher has removed the file from their server.

Recommend


More recommend