Optimizing Robustness while Generating Shared Secret Safe Primes Emil Ong and John Kubiatowicz University of California, Berkeley.

Slides:



Advertisements
Similar presentations
Number Theory Algorithms and Cryptography Algorithms Prepared by John Reif, Ph.D. Analysis of Algorithms.
Advertisements

Lecture Implementations. The efficiency of a particular cryptographic scheme based on any one of the algebraic structures will depend on a number.
Introduction to Modern Cryptography, Lecture 11 1) More about efficient computation: Montgomery arithmetic, efficient exponentiation 2)Secret Sharing schemes.
Cryptography and Network Security
Chapter 8 – Introduction to Number Theory. Prime Numbers prime numbers only have divisors of 1 and self –they cannot be written as a product of other.
Lecture 8: Primality Testing and Factoring Piotr Faliszewski
COM 5336 Cryptography Lecture 7a Primality Testing
Notation Intro. Number Theory Online Cryptography Course Dan Boneh
Lecture 3.3: Public Key Cryptography III CS 436/636/736 Spring 2012 Nitesh Saxena.
C. Walter, Data Integrity for Modular Arithmetic, CHES 2000 CHES 2000 Data Integrity in Hardware for Modular Arithmetic Colin Walter Computation Department,
Scott CH Huang COM5336 Cryptography Lecture 14 XTR Cryptosystem Scott CH Huang COM 5336 Cryptography Lecture 10.
The XTR public key system (extended version of Crypto 2000 presentation) Arjen K. Lenstra Citibank, New York Technical University Eindhoven Eric R. Verheul.
Session 4 Asymmetric ciphers.
CNS2010handout 8 :: introduction to number theory1 computer and network security matt barrie.
The RSA Cryptosystem and Factoring Integers (II) Rong-Jaye Chen.
1 Cryptosystems Based on Discrete Logarithms. 2 Outline [1] Discrete Logarithm Problem [2] Algorithms for Discrete Logarithm –A trivial algorithm –Shanks’
Introduction to Modern Cryptography Homework assignments.
Cryptography Lecture 11: Oct 12. Cryptography AliceBob Cryptography is the study of methods for sending and receiving secret messages. adversary Goal:
Cryptography1 CPSC 3730 Cryptography Chapter 9 Public Key Cryptography and RSA.
1 Hidden Exponent RSA and Efficient Key Distribution author: He Ge Cryptology ePrint Archive 2005/325 PDFPDF 報告人:陳昱升.
Fall 2010/Lecture 311 CS 426 (Fall 2010) Public Key Encryption and Digital Signatures.
Chapter 8 – Introduction to Number Theory Prime Numbers
Practical Private Computation of Vector Addition-Based Functions Yitao Duan and John Canny Computer Science Division University of California, Berkeley.
RSA Question 2 Bob thinks that p and q are primes but p isn’t. Then, Bob thinks ©Bob:=(p-1)(q-1) = Á(n). Is this true ? Bob chooses a random e (1 < e
Lecture 6: Public Key Cryptography
1 CIS 5371 Cryptography 8. Asymmetric encryption-.
Dan Boneh Intro. Number Theory Intractable problems Online Cryptography Course Dan Boneh.
Topic 18: RSA Implementation and Security
CSE 321 Discrete Structures Winter 2008 Lecture 10 Number Theory: Primality.
Quadratic Residuosity and Two Distinct Prime Factor ZK Protocols By Stephen Hall.
The RSA Algorithm Rocky K. C. Chang, March
Integers Number Theory = Properties of Integers

Calculating Discrete Logarithms John Hawley Nicolette Nicolosi Ryan Rivard.
Information Security and Management 4. Finite Fields 8
CS 312: Algorithm Analysis Lecture #3: Algorithms for Modular Arithmetic, Modular Exponentiation This work is licensed under a Creative Commons Attribution-Share.
Experimenting with Shared Generation of RSA Keys Michael Malkin Thomas Wu Dan Boneh Stanford University *Supported by DARPA.
RSA Ramki Thurimella.
Cryptography Dec 29. This Lecture In this last lecture for number theory, we will see probably the most important application of number theory in computer.
Cryptography Lecture 7: RSA Primality Testing Piotr Faliszewski.
Introduction to Algorithms Second Edition by Cormen, Leiserson, Rivest & Stein Chapter 31.
Advanced Algebraic Algorithms on Integers and Polynomials Prepared by John Reif, Ph.D. Analysis of Algorithms.
Strength of Cryptographic Systems Dr. C F Chong, Dr. K P Chow Department of Computer Science and Information Systems The University of Hong Kong.
CS461/ECE422 Spring 2012 Nikita Borisov — UIUC1.  Text Chapters 2 and 21  Handbook of Applied Cryptography, Chapter 8 
Chapter 3 (B) – Key Management; Other Public Key Cryptosystems.
Scott CH Huang COM 5336 Cryptography Lecture 6 Public Key Cryptography & RSA Scott CH Huang COM 5336 Cryptography Lecture 6.
The Cost of Fault Tolerance in Multi-Party Communication Complexity Binbin Chen Advanced Digital Sciences Center Haifeng Yu National University of Singapore.
Lecture 6.1: Misc. Topics: Number Theory CS 250, Discrete Structures, Fall 2011 Nitesh Saxena.
9/22/15UB Fall 2015 CSE565: S. Upadhyaya Lec 7.1 CSE565: Computer Security Lecture 7 Number Theory Concepts Shambhu Upadhyaya Computer Science & Eng. University.
CS Modular Division and RSA1 RSA Public Key Encryption To do RSA we need fast Modular Exponentiation and Primality generation which we have shown.
RSA cryptosystem--preview Suppose n=p  q and  (n)=(p-1)(q-1), where p and q are big primes. Select (find) a and b, such that a  b=1 mod  (n). K=(n,p,q,a,b),
Implementation Issues for Public Key Algorithms
Almost Entirely Correct Mixing With Applications to Voting Philippe Golle Dan Boneh Stanford University.
EPFL-IC-IIF-LACAL Marcelo E. Kaihara April 27 th, 2007 Algorithms for public-key cryptology Montgomery Arithmetic.
Lecture 3.1: Public Key Cryptography I CS 436/636/736 Spring 2015 Nitesh Saxena.
Dan Boneh Intro. Number Theory Arithmetic algorithms Online Cryptography Course Dan Boneh.
Implementation of Public Key Encryption Algorithms
Introduction to Elliptic Curve Cryptography CSCI 5857: Encoding and Encryption.
Chapter 1 Algorithms with Numbers. Bases and Logs How many digits does it take to represent the number N >= 0 in base 2? With k digits the largest number.
Lecture 6. RSA Use in Encryption to encrypt a message M the sender: – obtains public key of recipient PU={e,n} – computes: C = M e mod n, where 0≤M
1 The RSA Algorithm Rocky K. C. Chang February 23, 2007.
CSE565: Computer Security Lecture 7 Number Theory Concepts
RSA and El Gamal Cryptosystems
RSA Cryptosystem Bits PCs Memory MB ,000 4GB 1,020
Cryptography Lecture 22.
Lecture 20 Guest lecturer: Neal Gupta
Threshold RSA Cryptography
Cryptography Lecture 18.
Cryptography Lecture 20.
Cryptography Lecture 16.
Presentation transcript:

Optimizing Robustness while Generating Shared Secret Safe Primes Emil Ong and John Kubiatowicz University of California, Berkeley

Motivation Several multi-party algorithms need or benefit from using safe primes Usually, for RSA moduli (e.g. Shoup’s RSA signature scheme) In many of these algorithms, the safe primes must be shared secrets to preserve security

Generating safe primes as shared secrets: Prior Work Algesheimer, Camenish, and Shoup (CRYPTO ’00) Developed several novel mechanisms for modular arithmetic  Honest-but-curious model

Our contribution A safe prime generation method which is robust and “efficient” Use a robust form of distributed sieving to find safe prime candidates Provide optimized methods for multiparty modular arithmetic

High Level Overview 1. Find a safe prime candidate Sieve for rough numbers – those without small prime factors Ensure the number is 2. Test the compositeness via a distributed Miller-Rabin test

1. Each player finds a random “rough” integer (i.e. one relatively prime to the product of the first b primes, ) 2. The players generate additive shares such that 3. Players choose a random 4. Locally compute to obtain an additive share of Distributed Sieving (Malkin, Wu, and Boneh, NDSS’99)

1. Each player finds a random “rough” integer (i.e. one relatively prime to the product of the first b primes, ) Need to prove each is genuinely rough 2. The players generate additive shares such that Prefer threshold (polynomial) sharing 3. Players choose a random Need to share the polynomially, prove their size 4. Locally compute to obtain an additive share of Making Distributed Sieving Robust

1. Each player finds a random “rough” integer Each is shared polynomially along with a ZK proof 2. The are multiplied using the usual method (Ben-Or, Goldwasser, and Wigderson) 3. Players choose a random and share them polynomially, along with a proof of size 4. Locally compute to obtain an additive share of Robust Distributed Sieving

High Level Overview 1. Find a safe prime candidate Sieve for rough numbers – those without small prime factors Ensure the number is 2. Test the compositeness via a distributed Miller-Rabin test

Distributed Miller-Rabin Input: Secret shares of prime candidate 1. Locally compute e = (φ – 1) / 2 2. Repeat m times: a. Choose a random g (0 ≤ g ≤ φ - 1) b. Compute shares of g e mod φ c. If g e mod φ, output failure 3. Output success

Modular exponentiation (Algesheimer, Camenish, and Shoup, CRYPTO ‘00) Compute shares of g e mod φ 1. Reshare the bits of e as β 1,…, β n 2. c=(g-1)* β n For i=n-1 downto 1, Do 1. d=(g-1)*β i c=((c 2 mod φ) * d) mod φ 4. Output c Note that

Optimization: Lookup tables Alternate perspective: is a “lookup” of a 2 element table: 1 and g Problem: Sharing bits of a secret can be expensive Idea: Try to optimize by doing a lookup in an arbitrarily sized table Break the exponent into larger pieces than bits → fewer shares

Compute shares of g e mod φ 1. Precompute g 0 mod φ, g 1 mod φ, …, g η-1 mod φ 2. Reshare e in base-η as η 1,…,η ω (ω=n/η) 3. c=LOOKUP(η ω ) 4. For i=ω-1 downto 1, Do 1. d=LOOKUP(η i ) 2. c=((c η mod φ) * d) mod φ 5. Output c Result: The number of modular multiplications is reduced from 2log 2 e to log 2 e+ω Generalized Modular Exponentiation

Input: g 0 mod φ, g 1 mod φ, …, g η-1 mod φ, For i=0 to η-1, do Locally compute Normalization ( Adapted from Bar-Ilan and Beaver, PODC 1989 ): Lookup procedure

Summary Robust distributed sieving for safe prime candidate selection Improvements to modular arithmetic in the multiparty setting Current work: implementation

Conclusions and Lessons Modular arithmetic optimizations can be useful in general Safe prime generation is still slow (up to 5 minutes locally) The algorithm is non-trivial to implement If possible, avoid safe primes for now while we optimize further ☺

Thank you! Check our website soon for an extended version of the paper: