Nist 04 Digsig
Nist 04 Digsig
Nist 04 Digsig
kubob krbob
x u y y u x
Digital Signatures
Recap
Message authentication provides security services of
authentication and integrity
It does not provide non-repudiation
Digital signatures
Should provide us the same functionality as regular
signatures
Must depend on the message
Binding the signature to the message
Must be information unique to the signer that cannot be
forged
6
Digital Signature
Anyone can verify the signature with the public key
No one else can generate a signature since the private
key is know only to the owner
Alice Bob
Sig(x)
x
x
KUA
KRA
Compare
7
x
KUA
Sig(x)
KRA
Compare
Setup:
Public key: KU ={n, b}
Private key: KR = {p, q, a}
Here a b = 1 mod (n)
(n) = (p 1)(q 1)
9
10
Drawbacks
Alice y
x
d
x x
kAB kAB
eKR[ h(x) ]
kuA
Hash Bob
Or MAC
krA Verify
x || e KR[ h(x) ]
Skema pada Digital Signature
Bila Pengirim sebagai inisiator dibantu
menggunakan random session key
Pada skema lain bisa juga messagenya tidak
dienkripsi namun untuk memastikan keabsahan
cukup mengenkripsi hashnya menggunakan private
key dari pengirim
Hybrid Digital Signature using AES
Contoh Pemakaian RSA
Cari kode ciphertext dari proses enkripsi dan plain text dari proses
dekripsi, dengan menggunakan algoritma teknik enkripsi RSA (Rivest,
Shamir, Adelman). Plain text yang dijadikan input adalah nama anda
dan untuk nilai N, Ks dan Kp harus ditentukan sebelumnya.
- (n) = (p 1) (q 1)
= (13 1) (31 1)
= 12 x 30
= 360
3. Menentukan nilai Kp. Karena nilai Kp tidak boleh merupakan nilai factorial dari
(n) yang bersifat bilangan prima, maka sebelumnya dicari nilai factorial dari
(n), yaitu :
- (n) = 360
= 2^3 x 3^2 x 5
Jadi untuk nilai Kp tidak boleh bernilai 2, 3 atau 5. Dan disini ditentukan Kp = 7
4. Menentukan nilai Ks, Nilai Ks dapat ditentukan dengan rumus sebagai berikut :
(Kp x Ks) mod (n) = 1
(7 x Ks) mod 360 = 1
Sehingga untuk menentukan nilai Ks dengan cara termudah adalah
Ks = "(m x 360 + 1)" /1 = 1
kemudian
(721 -1) / 360 = modulo 0
720 / 360 = 2 modulo 0
Jadi dapat ditentukan bahwa nilai Ks adalah 103.
Setup
Public Verification
What is b ?
What is b?
b = a
b = a
What is ?
Verification gives
a x - a = x
19
Drawbacks
Modular Roots
Definition
Let m,n be natural numbers, c be an integer and gcd(c,n)
=1
Let xm = c mod n for some integer x
Then x is called the m-th root of c modulo n
And c is called an m-th power residue modulo n
Example: x2 = c mod n
x is called a square root mod n
c is called a quadratic residue mod n
If the prime factors of n are known, then
We can use CRT to find the m-th roots modulo n
Otherwise, it is considered to be a hard problem, as hard
as integer factorization for large n
You can also have the m-th root modulo a prime number
23
Setup
Choose a large prime number p
Choose a prime number q that divides p -1
Choose a number Zp* that is the q-th root of 1 mod p
What is the order of ?
Choose a private key KR = a {2,3,4,,q 1}
Compute the public key KU = b = a mod p
Keys:
Public: KU ={p, q, , b}
Private: KR = {a}
Let h(.) be a secure hash function (e.g., SHA-1 or RIPE-MD)
24
Public Verification
Setup
Choose a prime number p that is L bits long where L is a
multiple of 64 bits, larger than 512 bits and smaller than
1024 bits
Choose a prime number q that divides p -1 and is 160 bits
long
Choose a number Zp* that is the q-th root of 1 mod p
What is the order of ?
Choose
Compute a the
private keykey
public KR KU
= a=b{2,3,4,,q
= a mod p1}
Keys:
Public: KU ={p, q, , b}
Private: KR = {a}
Let h(.) be the secure hash algorithm (SHA-1)
27
Public Verification
ECDSA
Blind Signatures
Undeniable signatures
Requires the cooperation of the signer to verify the
signature
One-time signature
A new public key is required for verification for each
signature
32
Other References
http://www.epic.org/crypto/dss/
http://www.itl.nist.gov/fipspubs/fip186.htm