0% found this document useful (0 votes)
52 views4 pages

CS304 Scribe Week1

This document provides an overview of cryptography concepts including: 1. Cryptography involves developing algorithms for secure communications while cryptanalysis aims to break cryptographic algorithms. 2. There are symmetric-key cryptosystems that use one secret key and public-key cryptosystems that use two keys: a public key and a private key. 3. Cryptography provides security services like confidentiality, integrity, authentication, and non-repudiation. Common cryptographic algorithms like the Caesar cipher, transposition cipher, substitution cipher, and Playfair cipher are also summarized.

Uploaded by

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

CS304 Scribe Week1

This document provides an overview of cryptography concepts including: 1. Cryptography involves developing algorithms for secure communications while cryptanalysis aims to break cryptographic algorithms. 2. There are symmetric-key cryptosystems that use one secret key and public-key cryptosystems that use two keys: a public key and a private key. 3. Cryptography provides security services like confidentiality, integrity, authentication, and non-repudiation. Common cryptographic algorithms like the Caesar cipher, transposition cipher, substitution cipher, and Playfair cipher are also summarized.

Uploaded by

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

[CS304] Introduction to Cryptography and Network Security

Course Instructor: Dr. Dibyendu Roy Winter 2022-2023


Scribed by: Sanskar Patel (202011054) Lecture (Week #1)

1 Cryptography

Cryptography:-
→ In cryptography, we develop the algorithms to get security.
→ Cryptography is the study of secure communications techniques that allow only the sender and
intended recipient of a message to view its contents.

Cryptanalysis:-
→ In cryptanalysis, we try to break the security of designed algorithm.
→ Cryptanalysis is the study of ciphertext, ciphers and cryptosystems with the aim of understand-
ing how they work and finding and improving techniques for defeating or weakening them.

Cryptology:-
→ Cryptology = Cryptography + Cryptanalysis.
→ Cryptology is the science of secure communications.

• NIST: NIST works for development of standard cryptographic algorithm.

2 Types of Cryptosystem
1. Symmetric Key Cryptosystem
• Symmetric key cryptosystem has one secret key.
2. Public Key Cryptosystem
• Public key cryptosystem has two keys: 1. public key and 2. secret key.
• E(P, e) = C
• D(C, d) = P

3 Security services of cryptography


• Confidentiality(Secrecy): Hiding information from undesired users.
• Integrity: Receiver will be able to receive no alteration from the original plaintext.
• Authentication: Identifying that the image from correct/desired source.
• Non-repudiation: Proof that the message is sent by the original sender.

1
Confidentiality:-
• Plaintext: It is original message.
• Encryption Algorithm: It is function to encrypt the message.
• Ciphertext: It is unreadable form of the plaintext.
• Decryption Algorithm: It is function to decrypt the ciphertext.
• Encryption Key: Key for encryption.
• Decryption Key: Key for decryption.

→ Encryption Function:
• (m, Key) = C, where m = message (plaintext), key = encryption key and c = ciphertext.
• Encryption function defined as P X Key = Ciphertext(c)

→ Decryption Function:
• (C, Key) = m, where m = message (plaintext), key = decryption key and c = ciphertext.
• Decryption function defined as C X Key = Plaintext(m)

4 CAESAR Cipher
→ Named after Julius Caeser → Shifting the letters of a message by k places.
agreed value of k = 3.
E.g.: D → G (Right shift by 3).
E(x, 3) = (x + 3)%26 = C
D(C, 3) = (x + 26 − 3)%26

E.g.: INTERNET → LQWHUQHW

5 Transposition Cipher
→ M = m1 m2 m3 ...mt
→ e : permutation on t elements → secret key

→ Encryption: C = me(1) me(2) me(3) me(4) . . . me(t)


→ Decryption: C = me(1) me− 1(2) me− 1(3) me− 1(4) . . . me− 1(t)

Secret Key
1 2 3 4 5 6
6 4 1 3 5 2
E.g.: CAESER

C A E S E R
R S C E A A

2
6 Substitution Cipher
Only difference between Transposition and Substitution is that transposition’s size of domain =
size of codomain.

E.g. e(A) = Z, e(B) = D, e(C) = A

Plain text: A B C
Cipher text: Z D A

7 Affine Cipher
A B C ... Z
0 1 2 ... 25
A → Z26
k = secret key = (a, b)ϵZ26 × Z26 and gcd(a, 26) = 1
→ Encryption:
e(m, k) = (am + b)mod26 = c

→ Decryption:
d(c, k) = ((c − b)a−1 )mod26
a ∗ a−1 = 1mod26

Proof
gcd(x, m) = 1
0 ̸= xϵZm
gcd(x, m) = 1
x ∗m y = 1
xy = 1modm
m∥(xy − 1)
xy − 1 = t  m
1 = t1 m + xy for some t1
∴ gcd(x, m) = t1 m + xy

8 Playfair Cipher
→ Placing secret key in the form of a table with all remaining elements in 5 × 5 table. → I = J so
one of them is excluded(usually J). → For each pair (c[i], c[i+1]) where i is even and c[i] denotes
the character at ith index, we do the following:
1. If both the letters are in the same column: Take the letter below each one (going back to the
top if at the bottom).
2. If both the letters are in the same row: Take the letter to the right of each one (going back
to the leftmost if at the rightmost position).
3. Else: Form a rectangle with the two letters and take the letters on the horizontal opposite
corner of the rectangle.

3
E.g.: Secret key = PLAYFAIR EXAMPLE

Plaintext: HIDE P L A Y F
HI DE I R E X M
↓ ↓ B C D G H
BM OD K N O Q S
Ciphertext: BMOD T U V W Z
→ For odd length, we add an X to the end. ODD → OD DX

You might also like