SlideShare a Scribd company logo
Common Factor Attack on RSA
Assessing the Public Key Infrastructure
Vineet Kumar
Computer Science & Engineering Department
Jadavpur University, Kolkata
http://vntkumar8.github.io
November 20, 2017
RSA
The most widely used Public Key Cryptographic primitive
RSA has stood the test of nearly 40 years of attacks, making it the
algorithm of choice for encrypting Internet credit-card transactions
securing e-mail , authenticating phone calls and others
Vineet Kumar Common Factor Attack on RSA November 20, 2017 2 / 22
Its all started with...
Die Hellman's Direction
Figure: New Directions in Cryptography [1976]
Vineet Kumar Common Factor Attack on RSA November 20, 2017 3 / 22
Idea of Public Key Crypto
 Each party A has a public key PKA others can use to encrypt
messages to A:
C = PKA(M)
 Each party A also has a secret key SKA for decrypting a received
ciphertext C :
M = SKA(C )
Vineet Kumar Common Factor Attack on RSA November 20, 2017 4 / 22
Idea of Public Key Crypto
In 1976, Marty Hellman and Whit Die, invented the notion of
public-key cryptography
 Each party A has a public key PKA others can use to encrypt
messages to A:
C = PKA(M)
 Each party A also has a secret key SKA for decrypting a received
ciphertext C :
M = SKA(C )
Vineet Kumar Common Factor Attack on RSA November 20, 2017 4 / 22
Idea of Public Key Crypto
In 1976, Marty Hellman and Whit Die, invented the notion of
public-key cryptography
 Each party A has a public key PKA others can use to encrypt
messages to A:
C = PKA(M)
 Each party A also has a secret key SKA for decrypting a received
ciphertext C :
M = SKA(C )
 It is easy to compute public/secret key pairs.
Publishing PKA does not compromise SKA
It is computationally infeasible to obtain SKA from PKA (One Way
Functions)
Vineet Kumar Common Factor Attack on RSA November 20, 2017 4 / 22
Vineet Kumar Common Factor Attack on RSA November 20, 2017 5 / 22
RSA explained
PK = (n, e) where n = pq and gcd(e, φ(n)) = 1
SK = d where de = 1 mod φ(n)
Encryption/decryption are simple:
* C = PK (M) = M
e mod n
* M = SK (C ) = C
d mod n
Security of RSA relies on inability to factor product n of two primes p, q.
Vineet Kumar Common Factor Attack on RSA November 20, 2017 6 / 22
Strength of RSA
Factoring is hard
GNFS is best known algorithm for factorization
Vineet Kumar Common Factor Attack on RSA November 20, 2017 7 / 22
Common Factor Attack - Idea
What if we didn't have to factor ?
Vineet Kumar Common Factor Attack on RSA November 20, 2017 8 / 22
Common Factor Attack - Idea
N1 = p × q
N2 = p × r
Vineet Kumar Common Factor Attack on RSA November 20, 2017 8 / 22
Common Factor Attack - Idea
N1 = p × q
N2 = p × r
gcd(N1, N2) = p
Vineet Kumar Common Factor Attack on RSA November 20, 2017 8 / 22
Exploiting the idea
Heninger2012 Lenstra2012
Vineet Kumar Common Factor Attack on RSA November 20, 2017 9 / 22
Certicate
and its manipulation  I
certicate as looks in browser same certicate when exported as .pem
Vineet Kumar Common Factor Attack on RSA November 20, 2017 10 / 22
Certicate
and its manipulation  II
$ openssl x509 -in mailgooglecom.crt -out cert -text
Segregate the public key from the certicate
Vineet Kumar Common Factor Attack on RSA November 20, 2017 11 / 22
Imitation Game - I
Collected 7GB of 1024 bit Moduli  8GB of 2048 bit Moduli
FastGCD on dataset
computation ran on
0.4% of TLS Hosts are compromised due to Common Factor Attack
compared to 0.75% of Heninger et al. [Late 2015]
Vineet Kumar Common Factor Attack on RSA November 20, 2017 12 / 22
Imitation Game - I
Collected 7GB of 1024 bit Moduli  8GB of 2048 bit Moduli
FastGCD on dataset
computation ran on
0.4% of TLS Hosts are compromised due to Common Factor Attack
compared to 0.75% of Heninger et al. [Late 2015]
Reason of Such Vulnerability
sloppy implementations of RSA in embedded systems, especially in routers,
rewalls, and other network devices
less entropy for PRNGs
Vineet Kumar Common Factor Attack on RSA November 20, 2017 12 / 22
Our observation
In 2015, 0.4% of TLS Hosts were compromised compared to
0.75% that was reported in 2012
Computational Bottleneck
Enormous Memory  Huge Computational Power is required.
Hasting et al. [2016] did a massive batchwise gcd comptation ever using
quad 6-core 3.40GHz Intel Xeon E7-8893 processors with 3 TB RAM 
required over 500 GB of memory
Can we parallelize Batchwise GCD Computation?
Vineet Kumar Common Factor Attack on RSA November 20, 2017 13 / 22
Our Proposed Solution
1 Divide dataset randomly into parts
Vineet Kumar Common Factor Attack on RSA November 20, 2017 14 / 22
Our Proposed Solution
1 Divide dataset randomly into parts
largest data-size that a single node can handle
Vineet Kumar Common Factor Attack on RSA November 20, 2017 14 / 22
Our Proposed Solution
1 Divide dataset randomly into parts
2 Apply the batch-GCD algorithm over each part separately
Vineet Kumar Common Factor Attack on RSA November 20, 2017 14 / 22
Our Proposed Solution
1 Divide dataset randomly into parts
2 Apply the batch-GCD algorithm over each part separately
Obviously, the method will miss the instances where gcd(N1, N2)  1 and
N1 and N2 are in dierent partitions
Vineet Kumar Common Factor Attack on RSA November 20, 2017 14 / 22
Our Proposed Solution
1 Divide dataset randomly into parts
2 Apply the batch-GCD algorithm over each part separately
3 To overcome this, use multiple random divisions of the dataset and
aggregate the results using Union
Vineet Kumar Common Factor Attack on RSA November 20, 2017 14 / 22
One Complete Iteration
Input Dataset of RSA Moduli D
· · ·d2d1 dp−1 dp
· · ·v2v1 vp−1 vp
Set of Vulnerable RSA Moduli V
randomPartition
batchGCD
setUnion
Figure: One complete iteration of the proposed Parallelized Algorithm.
Vineet Kumar Common Factor Attack on RSA November 20, 2017 15 / 22
Algorithm
Input : Set of moduli D, constraint m, accuracy
Output: V  set of vulnerable moduli in D
1 p ← ceiling(|D|/m) ;
2 k ← chooseIteration(m, p, ) ;
3 for i ← 1 to k do
4 {d1, d2, . . . , dp} ← randomPartition(D, p) ;
5 {v1, v2, . . . , vp} ← batchGCD({d1, d2, . . . , dp}) ;
6 Vi ← setUnion({v1, v2, . . . , vp}) ;
7 end
8 V ← setUnion({V1, V2, . . . , Vk}) ;
Algorithm 1: Parallelized Common Factor Attack
Vineet Kumar Common Factor Attack on RSA November 20, 2017 16 / 22
Proof
GD
g1
g2
g3
g4
Figure: Illustrative partition of
graph GD into subgraphs
{g1, g2, . . . , gp}.
undirected graph GD with RSA moduli
Ni as vertices
edges present between vertices
{Ni, Nj} i gcd(Ni, Nj)  1
(illustrated as solid edges)
partition the graph GD into mutually
exclusive subgraphs {g1, g2, . . . , gp}
batchGCD on each subset will yield all
edges within each subgraph, but will
miss the edges e(Ni ,Nj ) in GD where Ni
and Nj belong to two dierent
subgraphs (illustrated as dotted edges)
Vineet Kumar Common Factor Attack on RSA November 20, 2017 17 / 22
Proof
GD
g1
g2
g3
g4
Figure: Illustrative
partition of graph
GD into subgraphs
{g1, g2, . . . , gp}.
The probability that we will miss a specic edge
e(Ni ,Nj ) in GD after one execution of the parallel
batchGCD algorithm on {d1, d2, . . . , dp} can be
computed as Pi=1
Pi=1 = 1 −
total number of edges in {g1, g2, . . . , gp}
total number of edges in GD
≈ 1 −
edges in complete supergraph of {g1, g2, . . . , gp}
edges in complete supergraph of GD
≈ 1 −
p × m
2
mp
2
= 1 −
m − 1
mp − 1
=
m(p − 1)
mp − 1
.
Vineet Kumar Common Factor Attack on RSA November 20, 2017 18 / 22
Proof
GD
g1
g2
g3
g4
Figure: Illustrative
partition of graph
GD into subgraphs
{g1, g2, . . . , gp}.
probability that we will miss a specic edge e(Ni ,Nj )
in GD after k independent executions of the parallel
batchGCD algorithm
Pi=k = (Pi=1)k ≈
m(p − 1)
mp − 1
k
.
∴ fraction of edges recovered after k iterations is
≈ 1 − m(p−1)
mp−1
k
Vineet Kumar Common Factor Attack on RSA November 20, 2017 19 / 22
Proof
GD
g1
g2
g3
g4
Figure: Illustrative
partition of graph
GD into subgraphs
{g1, g2, . . . , gp}.
probability that we will miss a specic edge e(Ni ,Nj )
in GD after k independent executions of the parallel
batchGCD algorithm
Pi=k = (Pi=1)k ≈
m(p − 1)
mp − 1
k
.
∴ fraction of edges recovered after k iterations is
≈ 1 − m(p−1)
mp−1
k
Another interpretation of the values of and k as
≈ 1 −
|D| − |D|/p
|D| − 1
k
, that is,
k ≈
log (1 − )
log (|D| − |D|/p) − log (|D| − 1)
.
Vineet Kumar Common Factor Attack on RSA November 20, 2017 19 / 22
Results
1 2 3 4 5 6 7 8
70
75
80
85
90
95
100
Number of iterations (k )
Percentageaccuracy()
p = 2
p = 4
p = 8
p = 16
p = 32
Figure: Relationship between , p and k from experimental data.
Vineet Kumar Common Factor Attack on RSA November 20, 2017 20 / 22
Vineet Kumar Common Factor Attack on RSA November 20, 2017 21 / 22
Thank You!
Vineet Kumar Common Factor Attack on RSA November 20, 2017 22 / 22

More Related Content

What's hot

Diffie hellman key exchange algorithm
Diffie hellman key exchange algorithmDiffie hellman key exchange algorithm
Diffie hellman key exchange algorithm
Sunita Kharayat
 
Ch9
Ch9Ch9
Cryptography and network security
 Cryptography and network security Cryptography and network security
Cryptography and network security
Mahipesh Satija
 
AES KEY EXPANSION .pptx
AES KEY EXPANSION .pptxAES KEY EXPANSION .pptx
AES KEY EXPANSION .pptx
AhmudulHassan
 
RSA algorithm
RSA algorithmRSA algorithm
RSA algorithm
Arpana shree
 
Kerberos
KerberosKerberos
Kerberos
RafatSamreen
 
Information and network security 13 playfair cipher
Information and network security 13 playfair cipherInformation and network security 13 playfair cipher
Information and network security 13 playfair cipher
Vaibhav Khanna
 
Elliptical curve cryptography
Elliptical curve cryptographyElliptical curve cryptography
Elliptical curve cryptography
Barani Tharan
 
RSA Algorithm - Public Key Cryptography
RSA Algorithm - Public Key CryptographyRSA Algorithm - Public Key Cryptography
RSA Algorithm - Public Key Cryptography
Md. Shafiul Alam Sagor
 
Cryptographic Algorithms: DES and RSA
Cryptographic Algorithms: DES and RSACryptographic Algorithms: DES and RSA
Cryptographic Algorithms: DES and RSA
aritraranjan
 
MD-5 : Algorithm
MD-5 : AlgorithmMD-5 : Algorithm
MD-5 : Algorithm
Sahil Kureel
 
Block Ciphers and the Data Encryption Standard
Block Ciphers and the Data Encryption StandardBlock Ciphers and the Data Encryption Standard
Block Ciphers and the Data Encryption Standard
Dr.Florence Dayana
 
2. public key cryptography and RSA
2. public key cryptography and RSA2. public key cryptography and RSA
2. public key cryptography and RSA
Dr.Florence Dayana
 
Ipsec
IpsecIpsec
Asymmetric Cryptography
Asymmetric CryptographyAsymmetric Cryptography
Asymmetric Cryptography
UTD Computer Security Group
 
Introduction to Cryptography
Introduction to CryptographyIntroduction to Cryptography
Introduction to Cryptography
Popescu Petre
 
Cryptography - Block cipher & stream cipher
Cryptography - Block cipher & stream cipherCryptography - Block cipher & stream cipher
Cryptography - Block cipher & stream cipher
Niloy Biswas
 
Network security cryptographic hash function
Network security  cryptographic hash functionNetwork security  cryptographic hash function
Network security cryptographic hash function
Mijanur Rahman Milon
 

What's hot (20)

Diffie hellman key exchange algorithm
Diffie hellman key exchange algorithmDiffie hellman key exchange algorithm
Diffie hellman key exchange algorithm
 
Ch9
Ch9Ch9
Ch9
 
Cryptography and network security
 Cryptography and network security Cryptography and network security
Cryptography and network security
 
AES KEY EXPANSION .pptx
AES KEY EXPANSION .pptxAES KEY EXPANSION .pptx
AES KEY EXPANSION .pptx
 
RSA algorithm
RSA algorithmRSA algorithm
RSA algorithm
 
Kerberos
KerberosKerberos
Kerberos
 
Information and network security 13 playfair cipher
Information and network security 13 playfair cipherInformation and network security 13 playfair cipher
Information and network security 13 playfair cipher
 
Elliptical curve cryptography
Elliptical curve cryptographyElliptical curve cryptography
Elliptical curve cryptography
 
RSA Algorithm - Public Key Cryptography
RSA Algorithm - Public Key CryptographyRSA Algorithm - Public Key Cryptography
RSA Algorithm - Public Key Cryptography
 
Cryptographic Algorithms: DES and RSA
Cryptographic Algorithms: DES and RSACryptographic Algorithms: DES and RSA
Cryptographic Algorithms: DES and RSA
 
MD-5 : Algorithm
MD-5 : AlgorithmMD-5 : Algorithm
MD-5 : Algorithm
 
Block Ciphers and the Data Encryption Standard
Block Ciphers and the Data Encryption StandardBlock Ciphers and the Data Encryption Standard
Block Ciphers and the Data Encryption Standard
 
2. public key cryptography and RSA
2. public key cryptography and RSA2. public key cryptography and RSA
2. public key cryptography and RSA
 
Ipsec
IpsecIpsec
Ipsec
 
Des
DesDes
Des
 
Asymmetric Cryptography
Asymmetric CryptographyAsymmetric Cryptography
Asymmetric Cryptography
 
Ch02...1
Ch02...1Ch02...1
Ch02...1
 
Introduction to Cryptography
Introduction to CryptographyIntroduction to Cryptography
Introduction to Cryptography
 
Cryptography - Block cipher & stream cipher
Cryptography - Block cipher & stream cipherCryptography - Block cipher & stream cipher
Cryptography - Block cipher & stream cipher
 
Network security cryptographic hash function
Network security  cryptographic hash functionNetwork security  cryptographic hash function
Network security cryptographic hash function
 

Similar to Common Factor Attack on RSA

rsa.ppt
rsa.pptrsa.ppt
GPU Accelerated Domain Decomposition
GPU Accelerated Domain DecompositionGPU Accelerated Domain Decomposition
GPU Accelerated Domain Decomposition
Richard Southern
 
SECRYPT 2018 Presentation: 15th International Conference on Security and Cry...
SECRYPT 2018  Presentation: 15th International Conference on Security and Cry...SECRYPT 2018  Presentation: 15th International Conference on Security and Cry...
SECRYPT 2018 Presentation: 15th International Conference on Security and Cry...
Mriganka Mandal
 
Advanced Encryption Standard Latex Beamer Class Presentation
Advanced Encryption Standard Latex Beamer Class PresentationAdvanced Encryption Standard Latex Beamer Class Presentation
Advanced Encryption Standard Latex Beamer Class PresentationNaimur Rahman
 
Testable Code
Testable CodeTestable Code
Testable Code
linghuazhang
 
Chapter 10 cryptography-public encryption
Chapter 10   cryptography-public encryptionChapter 10   cryptography-public encryption
Chapter 10 cryptography-public encryption
Syaiful Ahdan
 
IRJET- Secure Data on Multi-Cloud using Homomorphic Encryption
IRJET- Secure Data on Multi-Cloud using Homomorphic EncryptionIRJET- Secure Data on Multi-Cloud using Homomorphic Encryption
IRJET- Secure Data on Multi-Cloud using Homomorphic Encryption
IRJET Journal
 
Threshold-optimal DSAECDSA signatures and an application to Bitcoin wallet se...
Threshold-optimal DSAECDSA signatures and an application to Bitcoin wallet se...Threshold-optimal DSAECDSA signatures and an application to Bitcoin wallet se...
Threshold-optimal DSAECDSA signatures and an application to Bitcoin wallet se...
National Chengchi University
 
BRKSEC-2288.pdf
BRKSEC-2288.pdfBRKSEC-2288.pdf
BRKSEC-2288.pdf
HaitamSouissi1
 
Towards ruby-3x3-performance
Towards ruby-3x3-performanceTowards ruby-3x3-performance
Towards ruby-3x3-performance
Vladimir Makarov
 
Factorization Hack of RSA Secret Numbers
Factorization Hack of RSA Secret NumbersFactorization Hack of RSA Secret Numbers
Factorization Hack of RSA Secret Numbers
Universitas Pembangunan Panca Budi
 
Paillier Cryptosystem
Paillier CryptosystemPaillier Cryptosystem
Paillier Cryptosystem
Dejan Radic
 
Watermarking of JPEG2000 Compressed Images with Improved Encryption
Watermarking of JPEG2000 Compressed Images with Improved EncryptionWatermarking of JPEG2000 Compressed Images with Improved Encryption
Watermarking of JPEG2000 Compressed Images with Improved Encryption
Editor IJCATR
 
Shielding Federated Learning Systems against Inference Attacks with ARM Trust...
Shielding Federated Learning Systems against Inference Attacks with ARM Trust...Shielding Federated Learning Systems against Inference Attacks with ARM Trust...
Shielding Federated Learning Systems against Inference Attacks with ARM Trust...
vschiavoni
 
RSA Algorithm.ppt
RSA Algorithm.pptRSA Algorithm.ppt
RSA Algorithm.ppt
ArchanaT30
 
Ntewrok secuirty cs7
Ntewrok secuirty cs7Ntewrok secuirty cs7
Ntewrok secuirty cs7
Infinity Tech Solutions
 
A comparative analysis of the possible attacks on rsa cryptosystem
A comparative analysis of the possible attacks on rsa cryptosystemA comparative analysis of the possible attacks on rsa cryptosystem
A comparative analysis of the possible attacks on rsa cryptosystemIAEME Publication
 
Executing Boolean Queries on an Encrypted Bitmap Index
Executing Boolean Queries on an Encrypted Bitmap IndexExecuting Boolean Queries on an Encrypted Bitmap Index
Executing Boolean Queries on an Encrypted Bitmap Index
Mohamed Ahmed Abdelraheem
 
Elliptic curvecryptography Shane Almeida Saqib Awan Dan Palacio
Elliptic curvecryptography Shane Almeida Saqib Awan Dan PalacioElliptic curvecryptography Shane Almeida Saqib Awan Dan Palacio
Elliptic curvecryptography Shane Almeida Saqib Awan Dan Palacio
Information Security Awareness Group
 

Similar to Common Factor Attack on RSA (20)

rsa.ppt
rsa.pptrsa.ppt
rsa.ppt
 
rsa.ppt
rsa.pptrsa.ppt
rsa.ppt
 
GPU Accelerated Domain Decomposition
GPU Accelerated Domain DecompositionGPU Accelerated Domain Decomposition
GPU Accelerated Domain Decomposition
 
SECRYPT 2018 Presentation: 15th International Conference on Security and Cry...
SECRYPT 2018  Presentation: 15th International Conference on Security and Cry...SECRYPT 2018  Presentation: 15th International Conference on Security and Cry...
SECRYPT 2018 Presentation: 15th International Conference on Security and Cry...
 
Advanced Encryption Standard Latex Beamer Class Presentation
Advanced Encryption Standard Latex Beamer Class PresentationAdvanced Encryption Standard Latex Beamer Class Presentation
Advanced Encryption Standard Latex Beamer Class Presentation
 
Testable Code
Testable CodeTestable Code
Testable Code
 
Chapter 10 cryptography-public encryption
Chapter 10   cryptography-public encryptionChapter 10   cryptography-public encryption
Chapter 10 cryptography-public encryption
 
IRJET- Secure Data on Multi-Cloud using Homomorphic Encryption
IRJET- Secure Data on Multi-Cloud using Homomorphic EncryptionIRJET- Secure Data on Multi-Cloud using Homomorphic Encryption
IRJET- Secure Data on Multi-Cloud using Homomorphic Encryption
 
Threshold-optimal DSAECDSA signatures and an application to Bitcoin wallet se...
Threshold-optimal DSAECDSA signatures and an application to Bitcoin wallet se...Threshold-optimal DSAECDSA signatures and an application to Bitcoin wallet se...
Threshold-optimal DSAECDSA signatures and an application to Bitcoin wallet se...
 
BRKSEC-2288.pdf
BRKSEC-2288.pdfBRKSEC-2288.pdf
BRKSEC-2288.pdf
 
Towards ruby-3x3-performance
Towards ruby-3x3-performanceTowards ruby-3x3-performance
Towards ruby-3x3-performance
 
Factorization Hack of RSA Secret Numbers
Factorization Hack of RSA Secret NumbersFactorization Hack of RSA Secret Numbers
Factorization Hack of RSA Secret Numbers
 
Paillier Cryptosystem
Paillier CryptosystemPaillier Cryptosystem
Paillier Cryptosystem
 
Watermarking of JPEG2000 Compressed Images with Improved Encryption
Watermarking of JPEG2000 Compressed Images with Improved EncryptionWatermarking of JPEG2000 Compressed Images with Improved Encryption
Watermarking of JPEG2000 Compressed Images with Improved Encryption
 
Shielding Federated Learning Systems against Inference Attacks with ARM Trust...
Shielding Federated Learning Systems against Inference Attacks with ARM Trust...Shielding Federated Learning Systems against Inference Attacks with ARM Trust...
Shielding Federated Learning Systems against Inference Attacks with ARM Trust...
 
RSA Algorithm.ppt
RSA Algorithm.pptRSA Algorithm.ppt
RSA Algorithm.ppt
 
Ntewrok secuirty cs7
Ntewrok secuirty cs7Ntewrok secuirty cs7
Ntewrok secuirty cs7
 
A comparative analysis of the possible attacks on rsa cryptosystem
A comparative analysis of the possible attacks on rsa cryptosystemA comparative analysis of the possible attacks on rsa cryptosystem
A comparative analysis of the possible attacks on rsa cryptosystem
 
Executing Boolean Queries on an Encrypted Bitmap Index
Executing Boolean Queries on an Encrypted Bitmap IndexExecuting Boolean Queries on an Encrypted Bitmap Index
Executing Boolean Queries on an Encrypted Bitmap Index
 
Elliptic curvecryptography Shane Almeida Saqib Awan Dan Palacio
Elliptic curvecryptography Shane Almeida Saqib Awan Dan PalacioElliptic curvecryptography Shane Almeida Saqib Awan Dan Palacio
Elliptic curvecryptography Shane Almeida Saqib Awan Dan Palacio
 

Recently uploaded

Epistemic Interaction - tuning interfaces to provide information for AI support
Epistemic Interaction - tuning interfaces to provide information for AI supportEpistemic Interaction - tuning interfaces to provide information for AI support
Epistemic Interaction - tuning interfaces to provide information for AI support
Alan Dix
 
PCI PIN Basics Webinar from the Controlcase Team
PCI PIN Basics Webinar from the Controlcase TeamPCI PIN Basics Webinar from the Controlcase Team
PCI PIN Basics Webinar from the Controlcase Team
ControlCase
 
PHP Frameworks: I want to break free (IPC Berlin 2024)
PHP Frameworks: I want to break free (IPC Berlin 2024)PHP Frameworks: I want to break free (IPC Berlin 2024)
PHP Frameworks: I want to break free (IPC Berlin 2024)
Ralf Eggert
 
RESUME BUILDER APPLICATION Project for students
RESUME BUILDER APPLICATION Project for studentsRESUME BUILDER APPLICATION Project for students
RESUME BUILDER APPLICATION Project for students
KAMESHS29
 
Transcript: Selling digital books in 2024: Insights from industry leaders - T...
Transcript: Selling digital books in 2024: Insights from industry leaders - T...Transcript: Selling digital books in 2024: Insights from industry leaders - T...
Transcript: Selling digital books in 2024: Insights from industry leaders - T...
BookNet Canada
 
GDG Cloud Southlake #33: Boule & Rebala: Effective AppSec in SDLC using Deplo...
GDG Cloud Southlake #33: Boule & Rebala: Effective AppSec in SDLC using Deplo...GDG Cloud Southlake #33: Boule & Rebala: Effective AppSec in SDLC using Deplo...
GDG Cloud Southlake #33: Boule & Rebala: Effective AppSec in SDLC using Deplo...
James Anderson
 
Encryption in Microsoft 365 - ExpertsLive Netherlands 2024
Encryption in Microsoft 365 - ExpertsLive Netherlands 2024Encryption in Microsoft 365 - ExpertsLive Netherlands 2024
Encryption in Microsoft 365 - ExpertsLive Netherlands 2024
Albert Hoitingh
 
FIDO Alliance Osaka Seminar: FIDO Security Aspects.pdf
FIDO Alliance Osaka Seminar: FIDO Security Aspects.pdfFIDO Alliance Osaka Seminar: FIDO Security Aspects.pdf
FIDO Alliance Osaka Seminar: FIDO Security Aspects.pdf
FIDO Alliance
 
Accelerate your Kubernetes clusters with Varnish Caching
Accelerate your Kubernetes clusters with Varnish CachingAccelerate your Kubernetes clusters with Varnish Caching
Accelerate your Kubernetes clusters with Varnish Caching
Thijs Feryn
 
UiPath Test Automation using UiPath Test Suite series, part 4
UiPath Test Automation using UiPath Test Suite series, part 4UiPath Test Automation using UiPath Test Suite series, part 4
UiPath Test Automation using UiPath Test Suite series, part 4
DianaGray10
 
State of ICS and IoT Cyber Threat Landscape Report 2024 preview
State of ICS and IoT Cyber Threat Landscape Report 2024 previewState of ICS and IoT Cyber Threat Landscape Report 2024 preview
State of ICS and IoT Cyber Threat Landscape Report 2024 preview
Prayukth K V
 
FIDO Alliance Osaka Seminar: Passkeys at Amazon.pdf
FIDO Alliance Osaka Seminar: Passkeys at Amazon.pdfFIDO Alliance Osaka Seminar: Passkeys at Amazon.pdf
FIDO Alliance Osaka Seminar: Passkeys at Amazon.pdf
FIDO Alliance
 
Removing Uninteresting Bytes in Software Fuzzing
Removing Uninteresting Bytes in Software FuzzingRemoving Uninteresting Bytes in Software Fuzzing
Removing Uninteresting Bytes in Software Fuzzing
Aftab Hussain
 
Alt. GDG Cloud Southlake #33: Boule & Rebala: Effective AppSec in SDLC using ...
Alt. GDG Cloud Southlake #33: Boule & Rebala: Effective AppSec in SDLC using ...Alt. GDG Cloud Southlake #33: Boule & Rebala: Effective AppSec in SDLC using ...
Alt. GDG Cloud Southlake #33: Boule & Rebala: Effective AppSec in SDLC using ...
James Anderson
 
Monitoring Java Application Security with JDK Tools and JFR Events
Monitoring Java Application Security with JDK Tools and JFR EventsMonitoring Java Application Security with JDK Tools and JFR Events
Monitoring Java Application Security with JDK Tools and JFR Events
Ana-Maria Mihalceanu
 
Enhancing Performance with Globus and the Science DMZ
Enhancing Performance with Globus and the Science DMZEnhancing Performance with Globus and the Science DMZ
Enhancing Performance with Globus and the Science DMZ
Globus
 
GenAISummit 2024 May 28 Sri Ambati Keynote: AGI Belongs to The Community in O...
GenAISummit 2024 May 28 Sri Ambati Keynote: AGI Belongs to The Community in O...GenAISummit 2024 May 28 Sri Ambati Keynote: AGI Belongs to The Community in O...
GenAISummit 2024 May 28 Sri Ambati Keynote: AGI Belongs to The Community in O...
Sri Ambati
 
FIDO Alliance Osaka Seminar: The WebAuthn API and Discoverable Credentials.pdf
FIDO Alliance Osaka Seminar: The WebAuthn API and Discoverable Credentials.pdfFIDO Alliance Osaka Seminar: The WebAuthn API and Discoverable Credentials.pdf
FIDO Alliance Osaka Seminar: The WebAuthn API and Discoverable Credentials.pdf
FIDO Alliance
 
Le nuove frontiere dell'AI nell'RPA con UiPath Autopilot™
Le nuove frontiere dell'AI nell'RPA con UiPath Autopilot™Le nuove frontiere dell'AI nell'RPA con UiPath Autopilot™
Le nuove frontiere dell'AI nell'RPA con UiPath Autopilot™
UiPathCommunity
 
Introduction to CHERI technology - Cybersecurity
Introduction to CHERI technology - CybersecurityIntroduction to CHERI technology - Cybersecurity
Introduction to CHERI technology - Cybersecurity
mikeeftimakis1
 

Recently uploaded (20)

Epistemic Interaction - tuning interfaces to provide information for AI support
Epistemic Interaction - tuning interfaces to provide information for AI supportEpistemic Interaction - tuning interfaces to provide information for AI support
Epistemic Interaction - tuning interfaces to provide information for AI support
 
PCI PIN Basics Webinar from the Controlcase Team
PCI PIN Basics Webinar from the Controlcase TeamPCI PIN Basics Webinar from the Controlcase Team
PCI PIN Basics Webinar from the Controlcase Team
 
PHP Frameworks: I want to break free (IPC Berlin 2024)
PHP Frameworks: I want to break free (IPC Berlin 2024)PHP Frameworks: I want to break free (IPC Berlin 2024)
PHP Frameworks: I want to break free (IPC Berlin 2024)
 
RESUME BUILDER APPLICATION Project for students
RESUME BUILDER APPLICATION Project for studentsRESUME BUILDER APPLICATION Project for students
RESUME BUILDER APPLICATION Project for students
 
Transcript: Selling digital books in 2024: Insights from industry leaders - T...
Transcript: Selling digital books in 2024: Insights from industry leaders - T...Transcript: Selling digital books in 2024: Insights from industry leaders - T...
Transcript: Selling digital books in 2024: Insights from industry leaders - T...
 
GDG Cloud Southlake #33: Boule & Rebala: Effective AppSec in SDLC using Deplo...
GDG Cloud Southlake #33: Boule & Rebala: Effective AppSec in SDLC using Deplo...GDG Cloud Southlake #33: Boule & Rebala: Effective AppSec in SDLC using Deplo...
GDG Cloud Southlake #33: Boule & Rebala: Effective AppSec in SDLC using Deplo...
 
Encryption in Microsoft 365 - ExpertsLive Netherlands 2024
Encryption in Microsoft 365 - ExpertsLive Netherlands 2024Encryption in Microsoft 365 - ExpertsLive Netherlands 2024
Encryption in Microsoft 365 - ExpertsLive Netherlands 2024
 
FIDO Alliance Osaka Seminar: FIDO Security Aspects.pdf
FIDO Alliance Osaka Seminar: FIDO Security Aspects.pdfFIDO Alliance Osaka Seminar: FIDO Security Aspects.pdf
FIDO Alliance Osaka Seminar: FIDO Security Aspects.pdf
 
Accelerate your Kubernetes clusters with Varnish Caching
Accelerate your Kubernetes clusters with Varnish CachingAccelerate your Kubernetes clusters with Varnish Caching
Accelerate your Kubernetes clusters with Varnish Caching
 
UiPath Test Automation using UiPath Test Suite series, part 4
UiPath Test Automation using UiPath Test Suite series, part 4UiPath Test Automation using UiPath Test Suite series, part 4
UiPath Test Automation using UiPath Test Suite series, part 4
 
State of ICS and IoT Cyber Threat Landscape Report 2024 preview
State of ICS and IoT Cyber Threat Landscape Report 2024 previewState of ICS and IoT Cyber Threat Landscape Report 2024 preview
State of ICS and IoT Cyber Threat Landscape Report 2024 preview
 
FIDO Alliance Osaka Seminar: Passkeys at Amazon.pdf
FIDO Alliance Osaka Seminar: Passkeys at Amazon.pdfFIDO Alliance Osaka Seminar: Passkeys at Amazon.pdf
FIDO Alliance Osaka Seminar: Passkeys at Amazon.pdf
 
Removing Uninteresting Bytes in Software Fuzzing
Removing Uninteresting Bytes in Software FuzzingRemoving Uninteresting Bytes in Software Fuzzing
Removing Uninteresting Bytes in Software Fuzzing
 
Alt. GDG Cloud Southlake #33: Boule & Rebala: Effective AppSec in SDLC using ...
Alt. GDG Cloud Southlake #33: Boule & Rebala: Effective AppSec in SDLC using ...Alt. GDG Cloud Southlake #33: Boule & Rebala: Effective AppSec in SDLC using ...
Alt. GDG Cloud Southlake #33: Boule & Rebala: Effective AppSec in SDLC using ...
 
Monitoring Java Application Security with JDK Tools and JFR Events
Monitoring Java Application Security with JDK Tools and JFR EventsMonitoring Java Application Security with JDK Tools and JFR Events
Monitoring Java Application Security with JDK Tools and JFR Events
 
Enhancing Performance with Globus and the Science DMZ
Enhancing Performance with Globus and the Science DMZEnhancing Performance with Globus and the Science DMZ
Enhancing Performance with Globus and the Science DMZ
 
GenAISummit 2024 May 28 Sri Ambati Keynote: AGI Belongs to The Community in O...
GenAISummit 2024 May 28 Sri Ambati Keynote: AGI Belongs to The Community in O...GenAISummit 2024 May 28 Sri Ambati Keynote: AGI Belongs to The Community in O...
GenAISummit 2024 May 28 Sri Ambati Keynote: AGI Belongs to The Community in O...
 
FIDO Alliance Osaka Seminar: The WebAuthn API and Discoverable Credentials.pdf
FIDO Alliance Osaka Seminar: The WebAuthn API and Discoverable Credentials.pdfFIDO Alliance Osaka Seminar: The WebAuthn API and Discoverable Credentials.pdf
FIDO Alliance Osaka Seminar: The WebAuthn API and Discoverable Credentials.pdf
 
Le nuove frontiere dell'AI nell'RPA con UiPath Autopilot™
Le nuove frontiere dell'AI nell'RPA con UiPath Autopilot™Le nuove frontiere dell'AI nell'RPA con UiPath Autopilot™
Le nuove frontiere dell'AI nell'RPA con UiPath Autopilot™
 
Introduction to CHERI technology - Cybersecurity
Introduction to CHERI technology - CybersecurityIntroduction to CHERI technology - Cybersecurity
Introduction to CHERI technology - Cybersecurity
 

Common Factor Attack on RSA

  • 1. Common Factor Attack on RSA Assessing the Public Key Infrastructure Vineet Kumar Computer Science & Engineering Department Jadavpur University, Kolkata http://vntkumar8.github.io November 20, 2017
  • 2. RSA The most widely used Public Key Cryptographic primitive RSA has stood the test of nearly 40 years of attacks, making it the algorithm of choice for encrypting Internet credit-card transactions securing e-mail , authenticating phone calls and others Vineet Kumar Common Factor Attack on RSA November 20, 2017 2 / 22
  • 3. Its all started with... Die Hellman's Direction Figure: New Directions in Cryptography [1976] Vineet Kumar Common Factor Attack on RSA November 20, 2017 3 / 22
  • 4. Idea of Public Key Crypto Each party A has a public key PKA others can use to encrypt messages to A: C = PKA(M) Each party A also has a secret key SKA for decrypting a received ciphertext C : M = SKA(C ) Vineet Kumar Common Factor Attack on RSA November 20, 2017 4 / 22
  • 5. Idea of Public Key Crypto In 1976, Marty Hellman and Whit Die, invented the notion of public-key cryptography Each party A has a public key PKA others can use to encrypt messages to A: C = PKA(M) Each party A also has a secret key SKA for decrypting a received ciphertext C : M = SKA(C ) Vineet Kumar Common Factor Attack on RSA November 20, 2017 4 / 22
  • 6. Idea of Public Key Crypto In 1976, Marty Hellman and Whit Die, invented the notion of public-key cryptography Each party A has a public key PKA others can use to encrypt messages to A: C = PKA(M) Each party A also has a secret key SKA for decrypting a received ciphertext C : M = SKA(C ) It is easy to compute public/secret key pairs. Publishing PKA does not compromise SKA It is computationally infeasible to obtain SKA from PKA (One Way Functions) Vineet Kumar Common Factor Attack on RSA November 20, 2017 4 / 22
  • 7. Vineet Kumar Common Factor Attack on RSA November 20, 2017 5 / 22
  • 8. RSA explained PK = (n, e) where n = pq and gcd(e, φ(n)) = 1 SK = d where de = 1 mod φ(n) Encryption/decryption are simple: * C = PK (M) = M e mod n * M = SK (C ) = C d mod n Security of RSA relies on inability to factor product n of two primes p, q. Vineet Kumar Common Factor Attack on RSA November 20, 2017 6 / 22
  • 9. Strength of RSA Factoring is hard GNFS is best known algorithm for factorization Vineet Kumar Common Factor Attack on RSA November 20, 2017 7 / 22
  • 10. Common Factor Attack - Idea What if we didn't have to factor ? Vineet Kumar Common Factor Attack on RSA November 20, 2017 8 / 22
  • 11. Common Factor Attack - Idea N1 = p × q N2 = p × r Vineet Kumar Common Factor Attack on RSA November 20, 2017 8 / 22
  • 12. Common Factor Attack - Idea N1 = p × q N2 = p × r gcd(N1, N2) = p Vineet Kumar Common Factor Attack on RSA November 20, 2017 8 / 22
  • 13. Exploiting the idea Heninger2012 Lenstra2012 Vineet Kumar Common Factor Attack on RSA November 20, 2017 9 / 22
  • 14. Certicate and its manipulation I certicate as looks in browser same certicate when exported as .pem Vineet Kumar Common Factor Attack on RSA November 20, 2017 10 / 22
  • 15. Certicate and its manipulation II $ openssl x509 -in mailgooglecom.crt -out cert -text Segregate the public key from the certicate Vineet Kumar Common Factor Attack on RSA November 20, 2017 11 / 22
  • 16. Imitation Game - I Collected 7GB of 1024 bit Moduli 8GB of 2048 bit Moduli FastGCD on dataset computation ran on 0.4% of TLS Hosts are compromised due to Common Factor Attack compared to 0.75% of Heninger et al. [Late 2015] Vineet Kumar Common Factor Attack on RSA November 20, 2017 12 / 22
  • 17. Imitation Game - I Collected 7GB of 1024 bit Moduli 8GB of 2048 bit Moduli FastGCD on dataset computation ran on 0.4% of TLS Hosts are compromised due to Common Factor Attack compared to 0.75% of Heninger et al. [Late 2015] Reason of Such Vulnerability sloppy implementations of RSA in embedded systems, especially in routers, rewalls, and other network devices less entropy for PRNGs Vineet Kumar Common Factor Attack on RSA November 20, 2017 12 / 22
  • 18. Our observation In 2015, 0.4% of TLS Hosts were compromised compared to 0.75% that was reported in 2012 Computational Bottleneck Enormous Memory Huge Computational Power is required. Hasting et al. [2016] did a massive batchwise gcd comptation ever using quad 6-core 3.40GHz Intel Xeon E7-8893 processors with 3 TB RAM required over 500 GB of memory Can we parallelize Batchwise GCD Computation? Vineet Kumar Common Factor Attack on RSA November 20, 2017 13 / 22
  • 19. Our Proposed Solution 1 Divide dataset randomly into parts Vineet Kumar Common Factor Attack on RSA November 20, 2017 14 / 22
  • 20. Our Proposed Solution 1 Divide dataset randomly into parts largest data-size that a single node can handle Vineet Kumar Common Factor Attack on RSA November 20, 2017 14 / 22
  • 21. Our Proposed Solution 1 Divide dataset randomly into parts 2 Apply the batch-GCD algorithm over each part separately Vineet Kumar Common Factor Attack on RSA November 20, 2017 14 / 22
  • 22. Our Proposed Solution 1 Divide dataset randomly into parts 2 Apply the batch-GCD algorithm over each part separately Obviously, the method will miss the instances where gcd(N1, N2) 1 and N1 and N2 are in dierent partitions Vineet Kumar Common Factor Attack on RSA November 20, 2017 14 / 22
  • 23. Our Proposed Solution 1 Divide dataset randomly into parts 2 Apply the batch-GCD algorithm over each part separately 3 To overcome this, use multiple random divisions of the dataset and aggregate the results using Union Vineet Kumar Common Factor Attack on RSA November 20, 2017 14 / 22
  • 24. One Complete Iteration Input Dataset of RSA Moduli D · · ·d2d1 dp−1 dp · · ·v2v1 vp−1 vp Set of Vulnerable RSA Moduli V randomPartition batchGCD setUnion Figure: One complete iteration of the proposed Parallelized Algorithm. Vineet Kumar Common Factor Attack on RSA November 20, 2017 15 / 22
  • 25. Algorithm Input : Set of moduli D, constraint m, accuracy Output: V set of vulnerable moduli in D 1 p ← ceiling(|D|/m) ; 2 k ← chooseIteration(m, p, ) ; 3 for i ← 1 to k do 4 {d1, d2, . . . , dp} ← randomPartition(D, p) ; 5 {v1, v2, . . . , vp} ← batchGCD({d1, d2, . . . , dp}) ; 6 Vi ← setUnion({v1, v2, . . . , vp}) ; 7 end 8 V ← setUnion({V1, V2, . . . , Vk}) ; Algorithm 1: Parallelized Common Factor Attack Vineet Kumar Common Factor Attack on RSA November 20, 2017 16 / 22
  • 26. Proof GD g1 g2 g3 g4 Figure: Illustrative partition of graph GD into subgraphs {g1, g2, . . . , gp}. undirected graph GD with RSA moduli Ni as vertices edges present between vertices {Ni, Nj} i gcd(Ni, Nj) 1 (illustrated as solid edges) partition the graph GD into mutually exclusive subgraphs {g1, g2, . . . , gp} batchGCD on each subset will yield all edges within each subgraph, but will miss the edges e(Ni ,Nj ) in GD where Ni and Nj belong to two dierent subgraphs (illustrated as dotted edges) Vineet Kumar Common Factor Attack on RSA November 20, 2017 17 / 22
  • 27. Proof GD g1 g2 g3 g4 Figure: Illustrative partition of graph GD into subgraphs {g1, g2, . . . , gp}. The probability that we will miss a specic edge e(Ni ,Nj ) in GD after one execution of the parallel batchGCD algorithm on {d1, d2, . . . , dp} can be computed as Pi=1 Pi=1 = 1 − total number of edges in {g1, g2, . . . , gp} total number of edges in GD ≈ 1 − edges in complete supergraph of {g1, g2, . . . , gp} edges in complete supergraph of GD ≈ 1 − p × m 2 mp 2 = 1 − m − 1 mp − 1 = m(p − 1) mp − 1 . Vineet Kumar Common Factor Attack on RSA November 20, 2017 18 / 22
  • 28. Proof GD g1 g2 g3 g4 Figure: Illustrative partition of graph GD into subgraphs {g1, g2, . . . , gp}. probability that we will miss a specic edge e(Ni ,Nj ) in GD after k independent executions of the parallel batchGCD algorithm Pi=k = (Pi=1)k ≈ m(p − 1) mp − 1 k . ∴ fraction of edges recovered after k iterations is ≈ 1 − m(p−1) mp−1 k Vineet Kumar Common Factor Attack on RSA November 20, 2017 19 / 22
  • 29. Proof GD g1 g2 g3 g4 Figure: Illustrative partition of graph GD into subgraphs {g1, g2, . . . , gp}. probability that we will miss a specic edge e(Ni ,Nj ) in GD after k independent executions of the parallel batchGCD algorithm Pi=k = (Pi=1)k ≈ m(p − 1) mp − 1 k . ∴ fraction of edges recovered after k iterations is ≈ 1 − m(p−1) mp−1 k Another interpretation of the values of and k as ≈ 1 − |D| − |D|/p |D| − 1 k , that is, k ≈ log (1 − ) log (|D| − |D|/p) − log (|D| − 1) . Vineet Kumar Common Factor Attack on RSA November 20, 2017 19 / 22
  • 30. Results 1 2 3 4 5 6 7 8 70 75 80 85 90 95 100 Number of iterations (k ) Percentageaccuracy() p = 2 p = 4 p = 8 p = 16 p = 32 Figure: Relationship between , p and k from experimental data. Vineet Kumar Common Factor Attack on RSA November 20, 2017 20 / 22
  • 31. Vineet Kumar Common Factor Attack on RSA November 20, 2017 21 / 22
  • 32. Thank You! Vineet Kumar Common Factor Attack on RSA November 20, 2017 22 / 22