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

CHAPTER Digital Signature

This document discusses digital signatures and the El Gamal digital signature algorithm. It explains that digital signatures use public key cryptography to provide authentication, with the signature created by encrypting the message with the sender's private key. The signature can be verified by decrypting it with the sender's public key. It then provides step-by-step details of the El Gamal digital signature algorithm, including key generation, signature creation and verification, and provides an example to illustrate how it works.

Uploaded by

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

CHAPTER Digital Signature

This document discusses digital signatures and the El Gamal digital signature algorithm. It explains that digital signatures use public key cryptography to provide authentication, with the signature created by encrypting the message with the sender's private key. The signature can be verified by decrypting it with the sender's public key. It then provides step-by-step details of the El Gamal digital signature algorithm, including key generation, signature creation and verification, and provides an example to illustrate how it works.

Uploaded by

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

Chapter Four

Digital Signature

Md. Rafiqul Islam

Digital signature
# Like a handwritten signature.
# Cryptographic technique.
# Public key cryptosystem is used in digital
signature method.
# unforgivable: means only the originator should
be able to produce/ compute the signature
value.
# Verifiable: means others should be able to check
that the signature has come from the originator.
Md. Rafiqul Islam

Simple digital signature


Kp
Message
m

Encryption
algorithm

Digital
signature
S

Signature creation process

Message is encrypted using private key (Kp) of the


creator or originator.

Md. Rafiqul Islam

Signature verification
Kpub
Signature
S

Decryption
algorithm

Message
m

Verification process

Signature is decrypted using public key (Kpub) of


the originator.

Md. Rafiqul Islam

Signature verification
Suppose that A wants to send a signed message to
B. Then,
1)A uses his private key Kp, A to produce signature
and sends it to B.
S = E (m, Kp, A ).
2) After receiving the signed message B will verify
the signature as follows:
D(S, Kpub, A) = m.

Md. Rafiqul Islam

Digital signature at a glance


For B:

For A:
m

Kp, A

Encryptio
n
Algorith
m

Kpub,

Sending end:

Signature creation

Md. Rafiqul Islam

Decrypti
on
algorith
m

Receiving end:

Signature verification

Signature verification
A sends signature to B, thus B verifies that:
# A signed m (since As public key is matched).
# No one else signed m (since only A must have
the private key).
# A signed m and not m' (since S can be produced
only from m not from m').
Non-repudiation:
There is no way to deny that A has signed m. In
other words A can not say that he does not
produce S.
Md. Rafiqul Islam

Encrypted signature
Suppose that A sends message and B receives it.
1) A produces signature S:
S = E(Kp, A, m).
2) Now A enciphers (encrypts) S using Bs public key:
C = E(Kpub, B, S).
3) B receives C and deciphers it:
S = D(Kp, B, C).
4) B verifies that A signed m:
m = D(Kpub, A, S).
Md. Rafiqul Islam

Encrypted signature at a glance


For B:

For A:
m

Kp, A

Kp, B
C

Encryption
algorithm
Kpub,B

Decryption
algorithm

Encryption
algorithm
C

Md. Rafiqul Islam

Kpub,A

Sending end

Decryption
algorithm

m
Receiving end

Digital Signature Scheme


El Gamal Algorithm
Key generation:
1. Choose a prime p and two integers, c and x,
such that c < p and x < p.
2. Calculate y = cx mod p.
3. Compute q that is a prime factor of (p 1), that
means p should be chosen so that (p-1) has a
large prime factor, q.
4. x is the private key and (p, c, y )is the public
key.
Md. Rafiqul Islam

10

El Gamal Algorithm
Signature Creation:
1. Compute a random integer k, 0 < k < p-1, which is
relatively prime to (p-1) and which has not been used
before. Suppose z = p 1, then gcd (k, z) = 1
2. Compute:
i) t = ck mod p
ii) s = b (m xt ) mod z;
where b is the m-inv of k and z, so kb mod z = 1.
The message signature is then (s, t).
Md. Rafiqul Islam

11

El Gamal Algorithm
Signature verification:
A recipient receives (s, t). He uses the public key
(p, c, y) and compute:
i) v1 = yt.ts mod p and
ii) v2 = Cm mod p
If v1 = v2, the recipient can accept the signature.

Md. Rafiqul Islam

12

Example of El Gamal Algorithm


Key Generation:
1. Let p = 13, C = 5 and x = 11 ( c < p and x < p )
2 compute:
y = cx mod p = 511 mod 13 = 8
Then 11 is the private key and (13, 5, 8) is the
public key.

Md. Rafiqul Islam

13

Example [cont..]
Signature Generation:public key (p, c, y) = (13, 5, 8)
1. Choose z = p-1 = 13 1 = 12
2. Choose k = 7 ( k < z ) and gcd ( k, z ) = gcd ( 7, 12 ) = 1
3. Compute t = ck mod p = 57 mod 13 = 8;
4. kb mod z = 1, 7b mod 12 = 1, b = 7 [Extended Euclidian
algorithm]
5. s = b ( m xt ) mod z [use of private key x]
6. suppose the message, m = 104
7. s = 7 ( 104 11 8 ) mod 12 = 4
The message signature is ( s, t ) = ( 4, 8 )
Md. Rafiqul Islam

14

Example[cont..]
Verification:
Compute:
v1 = yt.ts mod p = 88.84 mod 13 = 1
v2 = cm mod p = 5104 mod 13 = 1
Since v1 = v2, the signature is verified.

Md. Rafiqul Islam

1515

Thank You.
Md. Rafiqul Islam

16

You might also like