Dan Boneh Public Key Encryption from trapdoor permutations PKCS 1 Online Cryptography Course Dan Boneh.

Slides:



Advertisements
Similar presentations
Dan Boneh Message integrity Message Auth. Codes Online Cryptography Course Dan Boneh.
Advertisements

ElGamal Security Public key encryption from Diffie-Hellman
Data Security 1 El_Gamal Cryptography. Data Security2 Introduction El_Gamal is a public-key cryptosystem technique El_Gamal is a public-key cryptosystem.
Online Cryptography Course Dan Boneh
1 Generic Conversions for Constructing IND-CCA2 Public-key Encryption in the Random Oracle Model Tatsuaki Okamoto NTT.
CS555Topic 191 Cryptography CS 555 Topic 19: Formalization of Public Key Encrpytion.
Dan Boneh Authenticated Encryption Active attacks on CPA-secure encryption Online Cryptography Course Dan Boneh.
11 Provable Security. 22 Given a ciphertext, find the corresponding plaintext.
Dan Boneh Message Integrity A Parallel MAC Online Cryptography Course Dan Boneh.
Lecture 3.3: Public Key Cryptography III CS 436/636/736 Spring 2012 Nitesh Saxena.
The RSA Cryptosystem Dan Boneh Stanford University.
CMSC 414 Computer and Network Security Lecture 6 Jonathan Katz.
The RSA Cryptosystem Dan Boneh Stanford University.
A Designer’s Guide to KEMs Alex Dent
CMSC 414 Computer and Network Security Lecture 7 Jonathan Katz.
CS470, A.SelcukRSA1 CS 470 Introduction to Applied Cryptography Instructor: Ali Aydin Selcuk.
1 CIS 5371 Cryptography 9. Data Integrity Techniques.
1 Introduction to Information Security , Spring 2015 Lecture 7: Applied cryptography: asymmetric Eran Tromer Slides credit: John Mitchell, Stanford.
Dan Boneh Public Key Encryption from trapdoor permutations The RSA trapdoor permutation Online Cryptography Course Dan Boneh.
Dan Boneh Public Key Encryption from trapdoor permutations RSA in practice Online Cryptography Course Dan Boneh.
Dan Boneh Authenticated Encryption Definitions Online Cryptography Course Dan Boneh.
Dan Boneh Public Key Encryption from trapdoor permutations Public key encryption: definitions and security Online Cryptography Course Dan Boneh.
Dan Boneh Authenticated Encryption Case study: TLS Online Cryptography Course Dan Boneh.
Dan Boneh Stream ciphers The One Time Pad Online Cryptography Course Dan Boneh.
8. Data Integrity Techniques
Lecture 3.2: Public Key Cryptography II CS 436/636/736 Spring 2014 Nitesh Saxena.
Cryptography Lecture 8 Stefan Dziembowski
Dan Boneh Public key encryption from Diffie-Hellman The ElGamal Public-key System Online Cryptography Course Dan Boneh.
RSA Implementation. What is Encryption ? Encryption is the transformation of data into a form that is as close to impossible as possible to read without.
Lecture 11 Chosen-Ciphertext Security Stefan Dziembowski MIM UW ver 1.0.
Public Key Encryption and the RSA Public Key Algorithm CSCI 5857: Encoding and Encryption.
1 Lect. 13 : Public Key Encryption RSA ElGamal. 2 Shamir Rivest Adleman RSA Public Key Systems  RSA is the first public key cryptosystem  Proposed in.
Dan Boneh Block ciphers More attacks on block ciphers Online Cryptography Course Dan Boneh.
On OAEP, PSS, and S/MIME John Linn RSA Laboratories S/MIME WG, San Diego IETF, 13 December 2000.
Dan Boneh Public Key Encryption from trapdoor permutations Is RSA a one-way function? Online Cryptography Course Dan Boneh.
CS555Spring 2012/Topic 111 Cryptography CS 555 Topic 11: Encryption Modes and CCA Security.
1 Number Theory and Advanced Cryptography 5. Cryptanalysis of RSA Chih-Hung Wang Sept Part I: Introduction to Number Theory Part II: Advanced Cryptography.
Cryptography Lecture 11 Stefan Dziembowski
Copyright © The OWASP Foundation Permission is granted to copy, distribute and/or modify this document under the terms of the OWASP License. The OWASP.
Multiple Encryption & DES  clearly a replacement for DES was needed Vulnerable to brute-force key search attacks Vulnerable to brute-force key search.
Encryption Types & Modes Chapter 9 Encryption Types –Stream Ciphers –Block Ciphers Encryption Modes –ECB - Electronic Codebook –CBC - Cipher Block Chaining.
Modes of Usage Dan Fleck CS 469: Security Engineering These slides are modified with permission from Bill Young (Univ of Texas) 11 Coming up: Modes of.
Dan Boneh Stream ciphers Pseudorandom Generators Online Cryptography Course Dan Boneh.
Public Key Encryption with keyword Search Author: Dan Boneh Rafail Ostroversity Giovanni Di Crescenzo Giuseppe Persiano Presenter: 陳昱圻.
Dan Boneh Collision resistance Introduction Online Cryptography Course Dan Boneh.
CHES 2002 Presented at the workshop CHES 2002, August 13-15, 2002, Redwood Shores, California, USA.
Dan Boneh Public key encryption from Diffie-Hellman The ElGamal Public-key System Online Cryptography Course Dan Boneh.
Rennes, 02/10/2014 Cristina Onete Attacks on RSA. Safe modes.
Odds and ends Tweakable encryption
Attacking RSA Brian Winant Reference “Twenty Years of Attacks on the RSA Cryptosystem” By Dan Boneh In Notices of the American Mathematical.
Public Key Algorithms Lesson Introduction ●Modular arithmetic ●RSA ●Diffie-Hellman.
Template vertLeftWhite2 Authenticated Encryption Attacking non-atomic decryption Online Cryptography Course Dan Boneh.
Tae-Joon Kim Jong yun Jun
Dan Boneh Introduction Course Overview Online Cryptography Course Dan Boneh.
DIGITAL SIGNATURE IMPLEMENTATION
Dan Boneh Stream ciphers PRG Security Defs Online Cryptography Course Dan Boneh.
Dan Boneh Odds and ends Deterministic Encryption Online Cryptography Course Dan Boneh.
Dan Boneh Public Key Encryption from trapdoor permutations Constructions Online Cryptography Course Dan Boneh Goal: construct chosen-ciphertext secure.
RSA Pubic Key Encryption CSCI 5857: Encoding and Encryption.
Dan Boneh Authenticated Encryption CBC paddings attacks Online Cryptography Course Dan Boneh.
1 Introduction to Information Security , Spring 2016 Lecture 4: Applied cryptography: asymmetric Zvi Ostfeld Slides credit: Eran Tromer.
Dan Boneh Collision resistance Timing attacks on MAC verification Online Cryptography Course Dan Boneh.
Prof. Reuven Aviv, Nov 2013 Public Key Infrastructure1 Prof. Reuven Aviv Tel Hai Academic College Department of Computer Science Problem Set 1: Cryptography.
Dan Boneh Public Key Encryption from trapdoor permutations Public key encryption: definitions and security Online Cryptography Course Dan Boneh.
Authenticated encryption
Cryptography Lecture 26.
Real-world Security of Public Key Crypto
Cryptography Lecture 22.
Cryptography Lecture 25.
Presentation transcript:

Dan Boneh Public Key Encryption from trapdoor permutations PKCS 1 Online Cryptography Course Dan Boneh

Dan Boneh RSA encryption in practice Never use textbook RSA. RSA in practice (since ISO standard is not often used) : Main questions: – How should the preprocessing be done? – Can we argue about security of resulting system? msg key Preprocessing ciphertext RSA

Dan Boneh PKCS1 v1.5 PKCS1 mode 2:(encryption) Resulting value is RSA encrypted Widely deployed, e.g. in HTTPS 02random padFFmsg RSA modulus size (e.g bits) 16 bits

Dan Boneh Attack on PKCS1 v1.5 (Bleichenbacher 1998) PKCS1 used in HTTPS:  attacker can test if 16 MSBs of plaintext = ’02’ Chosen-ciphertext attack: to decrypt a given ciphertext c do: – Choose r  Z N. Compute c’ r e  c = ( r  PKCS1 ( m ) ) e – Send c’ to web server and use response Attacker Web Server d ciphertext c=c= c yes: continue no: error Is this PKCS1? 02

Dan Boneh Baby Bleichenbacher Suppose N is N = 2 n (an invalid RSA modulus). Then: Sending c reveals msb( x ) Sending 2 e ⋅ c = (2x) e in Z N reveals msb(2x mod N) = msb 2 (x) Sending 4 e ⋅ c = (4x) e in Z N reveals msb(4x mod N) = msb 3 (x) … and so on to reveal all of x Attacker Web Server d ciphertext c=c= c yes: continue no: error is msb=1? 1 compute xc d in Z N

Dan Boneh HTTPS Defense (RFC 5246) Attacks discovered by Bleichenbacher and Klima et al. … can be avoided by treating incorrectly formatted message blocks … in a manner indistinguishable from correctly formatted RSA blocks. In other words: 1. Generate a string R of 46 random bytes 2. Decrypt the message to recover the plaintext M 3. If the PKCS#1 padding is not correct pre_master_secret = R

Dan Boneh PKCS1 v2.0: OAEP New preprocessing function: OAEP [BR94] Thm [FOPS’01] : RSA is a trap-door permutation  RSA-OAEP is CCA secure when H,G are random oracles in practice: use SHA-256 for H and G H + G + plaintext to encryptwith RSA rand.msg check pad on decryption. reject CT if invalid.  {0,1} n-1

Dan Boneh OAEP Improvements OAEP+: [Shoup’01]  trap-door permutation F F-OAEP+ is CCA secure when H,G,W are random oracles. SAEP+: [B’01] RSA (e=3) is a trap-door perm  RSA-SAEP+ is CCA secure when H,W are random oracle. r H + G + mW(m,r)r H + m During decryption validate W(m,r) field.

Template vertLeftWhite2 How would you decrypt an SAEP ciphertext ct ? r H + mW(m,r) RSA ciphertext (x,r) RSA -1 (sk,ct), (m,w) xH(r), output m if w = W(m,r) (x,r) RSA -1 (sk,ct), (m,w) rH(x), output m if w = W(m,r) (x,r) RSA -1 (sk,ct), (m,w) xH(r), output m if r = W(m,x) xr

Dan Boneh Subtleties in implementing OAEP [M ’00] OAEP- decrypt(ct): error = 0; if ( RSA -1 (ct) > 2 n-1 ) { error =1; goto exit; } if ( pad(OAEP -1 (RSA -1 (ct))) != “01000” ) { error = 1; goto exit; } Problem: timing information leaks type of error  Attacker can decrypt any ciphertext Lesson: Don’t implement RSA-OAEP yourself !

Dan Boneh End of Segment