0% found this document useful (0 votes)
11 views17 pages

yasika ppt

Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PPTX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
11 views17 pages

yasika ppt

Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PPTX, PDF, TXT or read online on Scribd
You are on page 1/ 17

CRYPTOGRAPHY

&
CYBER SECURITY

G.YASIKA
AP/CSE
ASYMMETRIC CRYPTOGRAPHY
Primes
Primality Testing
Asymmetric key cipher
RSA Cryptosystem
Key Distribution
Key Management
PRIMES
 Prime numbers create a secret key and a public key .
 The private key decrypts messages, while the public key
decrypts them.
 Large prime numbers ensure security, making it difficult for
unauthorized access.
 Prime numbers lock and unlock messages, safeguarding
confidential communication
PRIMALITY TESTING

 Test is a given number is prime or not . It check for


divisors other than 1 and the number itself. A number is
prime if it has no divisors, otherwise it’s composite.
 It includes trial division, modular arithmetic and
probabilistic methods.
 These tests help verify the primality of a number,
ensuring secure cryptographic application
SYMMETRIC VS ASYMMETRIC
ENCRYPTION
AYSYMMETRIC KEY CIPHER

 Asymmetric Key Cipher, also known as Public-Key Cryptography.


It uses a pair of keys.
 A public key for encryption and a private key for decryption. The
public key can be freely distributed, while the private key remains
secret.
 Data encrypted with the public key can only be decrypted with the
corresponding private key. This ensures secure communication
between parties without sharing a secret key.
RSA CRYPTOSYSTEM
• Question: Suppose we have the following RSA parameters:
Two prime numbers: p=61 and q=53 Public exponent: e=17
SOLUTION
• 1. Compute the Modulus n
• n=p×q, n=61n=61×53 n=3233
• 2. Compute the Totient Function ϕ(n)\phi(n)ϕ(n)
• ϕ(n)=(p−1)×(q−1)
• ϕ(n)=(61−1)×(53−1)
• ϕ(n)=60×52
• ϕ(n)=3120
3. Compute the Private Exponent ddd
• We need to find d such that: d×e≡1 (mod ϕ(n)), d = 17 ≡ 1 (mod 3120)
• To find d, use the Extended Euclidean Algorithm to compute the modular
inverse of e modulo ϕ(n)
• Using the Extended Euclidean Algorithm:
• Compute the greatest common divisor (GCD) and coefficients of the
equation: 17d≡1 (mod 3120)
• The result is d=2753
4. Encrypt the Plaintext Message m=42
• The encryption formula is: c= m^e (mod n)c =42^17 (mod 3233)
• Calculating 42^17 modulo 3233: c=2557
• So, the ciphertext is c=2557
5. Decrypt the Ciphertext
• The decryption formula is: m=c^d (mod n ) m =2557^2753 (mod
3233)
• Calculating 2557^2753 modulo 3233: m=42
• So, the decrypted message is m=42, which matches the original
plaintext.
KEY DISTRIBUTION
Key distribution is the method of sharing secret keys between people or
systems in a secure way.
 It ensures that only authorized parties have the key needed to read or
send encrypted messages.
 The process can involve physical exchange, trusted intermediaries, or
automated systems.
 Proper key distribution is crucial for keeping communications safe from
eavesdroppers.
KEY MANAGEMENT

 Key management is the process of handling cryptographic keys


throughout their lifecycle.
 This includes creating, storing, distributing, using, and eventually
retiring or destroying keys.
 It ensures that keys are used securely and efficiently to protect data and
 communications.
 Proper key management is crucial for maintaining the security and
integrity of encrypted information.
DIFFIE HELLMAN KEY EXCHANGE
The Diffie-Hellman key exchange is a cryptographic protocol that
allows two parties to securely establish a shared secret over an insecure
communication channel. This shared secret can then be used to encrypt
subsequent communications using symmetric key encryption.
HOW IT IS WORKS?
• 1. Public and Private Keys:
• Each party generates a private key (a secret number) and a
corresponding public key (a number derived from the private key).
2. Public Parameters: Both parties agree on two numbers: a large
prime number p and a base g (often called the generator), which are
known publicly.
3. Key Exchange:
Party A: Chooses a private key a (a random number).
Computes the public key ( A = g^a mod p ).
Sends A to Party B.
Party B: Chooses a private key b (another random number).
Computes the public key B = g^b mod p.
Sends B to Party A.
3. Shared Secret Calculation:
Party A: Computes the shared secret as S = B^a (mod p)
Party B: Computes the shared secret as S = A^b (mod p)
Despite using different private keys (a and b), both parties compute the
same shared secret S due to the properties of modular arithmetic.
Example:
Public parameters: p = 23, g = 5
Party A: Chooses a = 6 . Computes A = 5^6 mod 23 = 8
Sends A = 8 to Party B.
Party B:Chooses b = 15 Computes B = 5^15 mod 23 = 19.
Sends B = 19 to Party A.Shared Secret: Party A computes S = 19^6 mod
ELLIPTIC CURVE ARITHMETIC

Elliptic Curve Arithmetic involves mathematical operations


on points that lie on an elliptic curve, which is a curve defined
by an equation of the form y2=x3+ax+by.
These operations include point addition and scalar
multiplication, essential in cryptography for creating secure
cryptographic keys.
ELLIPTIC CURVE CRYPTOGRAPHY

Elliptic Curve Cryptography (ECC) is a type of public-key


cryptography that uses the mathematics of elliptic curves for creating
secure cryptographic keys. ECC provides strong security with smaller
key sizes, making it efficient for devices with limited resources.
THANK YOU

You might also like