0% found this document useful (0 votes)
2 views

Unit+4

The document discusses the Discrete Logarithmic Problem, which involves finding an integer in a cyclic group that satisfies a specific equation, and highlights the difficulty of reversing this process. It also covers the Diffie Hellman key exchange method for securely sharing cryptographic keys, its applications, vulnerabilities, and the Computational and Decisional Diffie Hellman problems. Additionally, the document explains Elliptical Curve Cryptography, RSA algorithm, and their respective key generation, encryption, and decryption processes, along with their advantages and disadvantages.

Uploaded by

MONISH MONNAT
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
2 views

Unit+4

The document discusses the Discrete Logarithmic Problem, which involves finding an integer in a cyclic group that satisfies a specific equation, and highlights the difficulty of reversing this process. It also covers the Diffie Hellman key exchange method for securely sharing cryptographic keys, its applications, vulnerabilities, and the Computational and Decisional Diffie Hellman problems. Additionally, the document explains Elliptical Curve Cryptography, RSA algorithm, and their respective key generation, encryption, and decryption processes, along with their advantages and disadvantages.

Uploaded by

MONISH MONNAT
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 7

Unit 4

Discrete Logarithmic Problem

It is a computational problem that involves finding an integer value in a cyclic group that satisfies a
given equation.

Problem:- Given a cyclic group G with generator α and an element β € G*, find element x such that
αx= β

Difficulty:- The discrete logarithmic problem is considered a hard problem, especially when N is a
large prime number.

Discrete Logarithmic Problem is a one way function which is easy in one direction anddifficult in
another.

Ex.- Find 46 mod 12 = 10.

Now, we use a prime modulus 17, then find primitive root of 17.

Primitive root is a unique no. which is when raise to different no. doesn’t repeat same no. and the
range of number will be between 1 and n, where n is equal to number whose mod.

3 is generative primitive root such that

3xmod17 gives you unique results whose values lie between 1 and 16 (both inclusive), for all values
of x between 1 and 16 (both inclusive)

31mod 17 = 3 32mod 17 = 9 33mod 17 = 10 34mod 17 = 13


35mod 17 = 5 36mod 17 = 15 37mod 17 = 11 38mod 17 = 16
39mod 17 = 14 310mod 17 = 8 311mod 17 = 7 312mod 17 = 4
313mod 17 = 12 314mod 17 = 2 315mod 17 = 6 316mod 17 = 1

3 as generative primitive root of 17

Now, reverse procedure is hard, which means if we have given value of modulo operation and we
have to determine the value of x then it is a tedious job, it is called as discrete logarithmic problem.

The strength of one way function is it is easy to perform in one direction but is difficult to perform in
opposite direction.

Diffie Hellman Key Exchange

Diffie Hellman key exchange is a method of digital encryption that securely exchanges cryptographic
keys between two parties over a public channel without conversation being transmitted over
internet.

Use of Diffie Hellman Exchange

Its goal is to securely establish a channel to create and share a key for symmetric key algorithms.
Steps in Diffie Hellman Key Exchange

 Alice and Bob agree on two large prime numbers, p and g and a public key exchange
algorithm.
 Alice chooses a secret integer a, and computes A = gamod p and sends A to Bob.
 Bob chooses a secret integer b and computes B = gbmod p and sends B to Alice.
 Alice computes s = Ba mod p and Bob computes s = Ab mod p.
 Alice and Bob now both share secret key which they use to estaiblish a secure
communication channel.

Security of Diffie Hellman

Security of Diffie Hellman relies on fact that it is computationally infeasible for an attacker to
determine the shared key from public value p, g, A and B.

Usage of Diffie Hellman Exchange

 Secure communication protocol:- DH key exchange is use in many secure communication


protocol such as SSL/TLS to establish a secure channel between two parties.
 Virtual Private Network:- It is often used in VPN to establish a secure connection between
clients and server. It allows the client and server to agree on a shared key that can be use
to encrypt and decrypt traffic exchange.
 Secure file transfer protocol :- The Diffie Hellman key exchange is use in many secure file
transfer protocols such as SFTP and FTPS to establish secure channel for transferring files
between two parties.
 Other Applications:- The Diffie Hellman key exchange is use in many other applications
where secure communication is required, such as secure Email, secure web browsing and
secure VoIP.

Drawback and Vulnerabilities in Diffie Hellman

 Susceptibility to MITM Attack:- The protocol doesn’t provide authentication of parties,


making it vulnerable to man in middle attack where attacker impersonate or other parties
and intercept or modify communication.
 Lack of authentication:- Algorithm can be used only for symmetric key exchange. It is
computationally expensive it uses a lot of resources and CPU time. Digital signature cannot
be signed by Diffie Hellman algorithm. Encryption of information cannot be done.
 Logjam attack:- These attacks downgrade TLS connection to 512 bit cryptography allowing
attackers to read and modify data.

Computational Diffie Hellman Problem

Assumption:-

The computational Diffie Hellman assumption is computational hardness assumption about Diffie
Hellman problem. The CDH assumption involvesthe problem of computing the discrete logarithm in
cyclic groups.
The CDH problem illustrates the attack of an evasdropper in Diffie Hellman key exchange protocol to
obtain exchanges secret key.

Definition:-

Consider a cyclic group G of order q. The CDH assumption states that given (g, ga, gb) for a randomly
chosen generator g and random a, b € {a,….., q-1}, it is computationally intractable to compute the
value

Decisional Diffie Hellman Problem

Assumption:-
Its assumption is based on computational hardness assumption about a certain problem involving
discrete logarithms on cyclic group. It is used as basis to prove the security of many cryptographic
protocol, most notably EL Gamal and Cramer Shoup cryptosystem.

Definition

Given a finite cyclic group G with generator g is to decide whether there exists integer x,y such that
a= gx, b= gy and c= gxy

Elliptical Curve Cryptography

Cryptography is study of techniques for secure communication in presence of adverseral behavior.

ECC is a asymmetric encryption algorithm that employs the algebraic architecture of elliptical curves
with finite field.

Components of Elliptical Curve Cryptography

1) ECC Keys:-

Private Key:- ECC cryptography’s private key creation is a simple as safely producing a
random integer in a specific range making it highly quick. Any integer in the field represents a valid
ECC private key.
Public Key:- Public key within ECC are EC points which are pair of integers co-ordinates x and
y that (i.e. on curve) Because of its unique features, EC points can be composed to a single co-
ordinates +-1 bit (odd or even).

2) Generator Point:-
ECC cryptosystem establish a special predefined EC points called generator point G (base point) for
elliptical curve over finite fields which can generate any other position in its sub group over elliptic
curve by multiplying G from some integer in the range [0,……r]

The number r is referred to as ordering of cyclic subgroup.


Elliptical curve subgroup typically contain numerous generator points but cryptologists carefully
select one of them to generate the entire group (or subgroup) and is excellent for performance
optimization s in calculations

Encryption Decryption and Key Generation using Elliptical Curve Cryptography

Elliptical curve are defined by mathematical function of cubic function such as

Eg. y2 = x3+ax+b

When a line is drawn it touches curve at 3 points namely P,Q,R

It is symmetric to x axis

ECC Algorithm

Step 1:- ECC Key Exchange

Global Public Elements:-

i) Eq (a,b) = Elliptical curve with parameters a,b and q(prime no. or an integer of form 2m)

ii) G is point on elliptic curve.

ECC key exchange algorithm is similar to Diffie Hellman key exchange algorithm.

User A key generation

Select a private key ἡa ἡa<n

Calculate public key Pa = ἡaX G

User B key generation

Select private key ἡb

Calculate public key Pb = ἡbX G

Calculation of secret key by user A

K = ἡ a X Pb

Calculation of secret key by user B

K =ἡb X Pa

Step 2:- ECC Encryption

Let the message be M

First encode this messege M into point on elliptical curve. Let this point be P m
For encryption chose a random +ve integer k

The cipher point is Cm = { KG, Pm + KPb }

This point is sent to receiver

Step 3:- Decryption

For decryption multiply x co-ordinate with receiver’s secret key

KG X ἡb

Then subtract KG X ἡb from recerived messege y co-ordinate

Pm+ KPb – (KG X ἡb)

Pm+ KPb - kPb

Pm

Euler’s Theorem for identifying prime no.

Statement:- It states that if a and n are coprime positive integers then,

aΦ(n) = 1 (mod n), where Φ(n) is defined as count of integer 1<a< n such that gcd(a,n) = 1

Example :-

If gcd(a,12) = 1, then a4 ≡ 1 (mod 12) because φ(12)=4.

RSA Algorithm

RSA algorithm was proposed by three mathematicians Rivest, Schimer and Aldaman for asymmetric
cryptosystem.

It is asymmetric cryptographic algorithm which works on two keys one is public key and other is
private key.

Public key is use for encryption and private key is use for decryption.

Idea of RSA

The basic idea of RSA is based on fact that it is difficult to factorize a large integer.
Steps in RSA Algorithm

Step 1 Key generation :-A private key and public key are generated. Private key is kept secret while
public key is shared.

Step 2 Key distribution:- The public key is shared between sender and receiver

Step3 Encryption:- Sender uses receiver’s public key to encrypt the message.

Step 4 Decryption:- Receiver uses private key to decrypt the message.

Working steps in RSA

Step1 Consider two large prime numbers p and q.

Step2 Calculate n = pxq

Step 3 Calculate Φ(n) = (p-1)x(q-1)

Step 4 Choose a small no. e co-prime with Φ(n). In other words, GCD(Φ(n), e) =1 and 1<e<Φ(n)

Step 5 Find d such that d X e mod Φ(n) = 1

Step 6 Encryption of message M is given by Me mod n

Step 7 Decryption of cipher text C is given by Cd mod n

Example

Step 1 Consider two prime no. 3 and 5

Step 2 n = p X q so n = 3 X 5 = 15

Step 3 Φ(n) = 2 X4 =8

Step 4 e such that GCD (8, e) =1 and 1<e<8

So e is assume to be 3

Step 5 Now, 3 X d mod 8 =1

So by hit and trial we get d = 3

Step 6 Encryption of messege m =7

73 mod 15 =13

Cipher text is 13

Step 7 At receiver’s end

M = 133 mod 15

2197 mod 15

M =7

We get back message as 7 at receiver’s end


Disadvantages of RSA Algorithm

 Slow processing speed RSA is slow when encrypting and decrypting large amounts of data.

 Large key size RSA requires large keys for security, which increases the need for storage,
computational power, and resources.

 Vulnerability to side-channel attacks Attackers can use information from side channels,
such as power consumption, timing analysis, and electromagnetic radiation, to extract the
private key.

 Weak key generation The algorithm is easier to solve if the prime numbers selected are too
close together or if one of the numbers in a key pair is too small.

 Vulnerability to quantum attacks Quantum computers could break RSA encryption by


factoring large integers in polynomial time using algorithms like Shor's algorithm.

 Not suitable for public data encryption RSA can't be used for public data encryption, like
electoral voting.

 Requires third-party confirmation Sometimes a third party is needed to confirm the


reliability of public keys.

 Padding is necessary Padding is required when using RSA, but it can be difficult to
implement and can make the system vulnerable to attack

You might also like