0% found this document useful (0 votes)
8 views18 pages

Cryptography 1

Cryptography ppt

Uploaded by

Rachna Singh
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)
8 views18 pages

Cryptography 1

Cryptography ppt

Uploaded by

Rachna Singh
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/ 18

TWO DAYS WORKSHOP

CYBER SECURITY : CRYPTOGRAPHY


Key Speaker
Mr. Anath Mahatha
Asst. Prof. Computer Science
13TH & 14TH MARCH

UTTAM MEMORIAL COLLEGE RAIGARH


Affiliated to : Shaheed Nandkumar Patel Vishwavidyalaya Raigarh (C.G.)
Cryptography
Cryptography is technique of securing information and communications through use of
codes so that only those person for whom the information is intended can understand it
and process it. Thus preventing unauthorized access to information. The prefix “crypt”
means “hidden” and suffix graphy means “writing”. In Cryptography the techniques which
are use to protect information are obtained from mathematical concepts and a set of rule
based calculations known as algorithms to convert messages in ways that make it hard to
decode it. These algorithms are used for cryptographic key generation, digital signing,
verification to protect data privacy, web browsing on internet and to protect confidential
transactions such as credit card and debit card transactions.
Cryptography and Network Security Principles
1. Confidentiality: The degree of confidentiality determines the secrecy of the
information. The principle specifies that only the sender and receiver will be able to
access the information shared between them. Confidentiality compromises if an
unauthorized person is able to access a message.

2. Authentication:
Authentication is the mechanism to identify the user or system or the entity. It
ensures the identity of the person trying to access the information. The
authentication is mostly secured by using username and password. The authorized
person whose identity is preregistered can prove his/her identity and can access the
sensitive information.

3. Integrity:
Integrity gives the assurance that the information received is exact and accurate. If the
content of the message is changed after the sender sends it but before reaching the
intended receiver, then it is said that the integrity of the message is lost.

4. Non-Repudiation:
Non-repudiation is a mechanism that prevents the denial of the message content sent
through a network. In some cases the sender sends the message and later denies it. But
the non-repudiation does not allow the sender to refuse the receiver
Encryption Technique
For the encryption process let us consider the
following example:
The Playfair Cipher Encryption Algorithm:
The Algorithm consists of 2 steps:
1. Generate the key Square(5×5): The key square is a
5×5 grid of alphabets that acts as the key for
encrypting the plaintext. Each of the 25 alphabets must
be unique and one letter of the alphabet (usually J) is
omitted from the table (as the table can hold only 25
alphabets). If the plaintext contains J, then it is
replaced by I.

The initial alphabets in the key square are the unique


alphabets of the key in the order in which they appear
followed by the remaining letters of the alphabet in
order.
2. Algorithm to encrypt the plain text: The plaintext is
split into pairs of two letters (digraphs). If there is an
odd number of letters, a Z is added to the last letter.
For example:
PlainText: "instruments" After Split: 'in' 'st' 'ru' 'me'
'nt' 'sz‘

1. Pair cannot be made with same letter. Break the


letter in single and add a bogus letter to the previous
letter.
Plain Text: “hello”
After Split: ‘he’ ‘lx’ ‘lo’
Here ‘x’ is the bogus letter.
2. If the letter is standing alone in the process of pairing, then
add an extra bogus letter with the alone letter
Plain Text: “helloe”
AfterSplit: ‘he’ ‘lx’ ‘lo’ ‘ez’
Here ‘z’ is the bogus letter.
Rules for Encryption:

If both the letters are in the same column: Take the letter
below each one (going back to the top if at the bottom).
For example:

Diagraph: "me" Encrypted Text: cl Encryption: m -> c e -> l


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).
For example:

Diagraph: "st" Encrypted Text: tl Encryption: s -> t t -> l


If neither of the above rules is true: Form a rectangle with
the two letters and take the letters on the horizontal
opposite corner of the rectangle.
For example:

Diagraph: "nt“
Encrypted Text: rq
Encryption:
n -> r
t -> q
For example:

Plain Text: "instrumentsz"


Encrypted Text: gatlmzclrqtx
Encryption:
i -> g
n -> a
s -> t
t -> l
r -> m
u -> z
m -> c
e -> l
n -> r
t -> q
s -> t
z -> x
Decryption Technique
Decrypting the Playfair cipher is as simple as doing the same
process in reverse. The receiver has the same key and can create
the same key table, and then decrypt any messages made using
that key.
The Playfair Cipher Decryption Algorithm:
The Algorithm consists of 2 steps:

1. Generate the key Square(5×5) at the receiver’s end:


The key square is a 5×5 grid of alphabets that acts as the key for
encrypting the plaintext. Each of the 25 alphabets must be unique and
one letter of the alphabet (usually J) is omitted from the table (as the
table can hold only 25 alphabets). If the plaintext contains J, then it is
replaced by I.

The initial alphabets in the key square are the unique alphabets of the
key in the order in which they appear followed by the remaining
letters of the alphabet in order.

2. Algorithm to decrypt the ciphertext: The ciphertext is split into pairs of


two letters (digraphs).

Note: The ciphertext always have even number of characters.


For example:

CipherText: "gatlmzclrqtx" After Split: 'ga' 'tl' 'mz' 'cl' 'rq' 'tx'
Rules for Decryption:
If both the letters are in the same column: Take the letter above
each one (going back to the bottom if at the top).
For example:

Diagraph: "cl" Decrypted Text: me Decryption: c -> m l -> e


If both the letters are in the same row: Take the letter to the left of each one
(going back to the rightmost if at the leftmost position).
For example:

Diagraph: "tl" Decrypted Text: st Decryption: t -> s l -> t


If neither of the above rules is true: Form a rectangle with the
two letters and take the letters on the horizontal opposite corner
of the rectangle.
For example:

Diagraph: "rq" Decrypted Text: nt Decryption: r -> n q -> t


For example:

Plain Text: "gatlmzclrqtx"


Decrypted Text: instrumentsz
Decryption:
(red)-> (green)
ga -> in
tl -> st
mz -> ru
cl -> me
rq -> nt
tx -> sz
THANKS

You might also like