CNS Mod-1
CNS Mod-1
Security
Department of
Computer Science and Engineering
GIET, University Gunupur
UNIT-1
INTRODUCTION & NUMBER THEORY
Security services:
CONTD.
• Encryption
– The mathematical function mapping plaintext to
ciphertext using the specified key:
Y = EK(X) or E(K, X)
• Decryption
– The mathematical function mapping cipher text to
plaintext using the specified key:
X = DK(Y) or D(K, X) = E
SYMMETRIC CIPHER MODEL
CONVENTIONAL CRYPTOSYSTEM
MODEL
Formula: Ciphertext(C):E(k,p)=(p+k)mod26
Plaintext(p):D(k,C)=(C-k)mod26
For Example, key=3
plaintext: hello how are you
cipher text: KHOOR KRZ DUH BRX
MONOALPHEBATIC CIPHER
•Cyclic Group:
•Exponentiation: Repeated application of operator
example: a3 = a.a.a
Cyclic Group: Every element is a power of some fixed element,
i.e., b = ak for some a and every b in group a is said to be a
generator of the group
Example: {1, 2, 4, 8} with mod 12 multiplication, the
generator is 2.
20=1, 21=2, 22=4, 23=8, 24=4, 25=8
CONTD.
Ring:
A group with two operations: addition and multiplication
The group is abelian with respect to addition: a+b=b+a
Multiplication and additions are both associative:
a+(b+c)=(a+b)+c a.
(b.c)=(a.b).c
Multiplication distributes over
addition, a.(b+c)=a.b+a.c
Commutative Ring:
Multiplication is commutative,
i.e., a.b = b.a
CONTD.
•Subtraction:
a-b mod n = a+(-b) mod n
•Multiplication:
a.b mod n
derived from repeated addition
can get a.b=0 where neither a,b=0
eg 2.5 mod 10
CONTD.
•Division:
a/b mod n
is multiplication by inverse of b: a/b = a.b-1 mod n
if n is prime b-1 mod n exists s.t b.b-1 = 1 mod n
• eg 2.3=1 mod 5 hence 4/2=4.3=2 mod 5
integers modulo n with addition and multiplication form a
commutative ring with the laws of
CONTD.