Top Banner
www.fakengineer.com Seminar on Seminar on (ENCODING AND DECODING TECHNIQUES)
15
Welcome message from author
This document is posted to help you gain knowledge. Please leave a comment to let me know what you think about it! Share it to your friends and learn new things together.
Transcript
Page 1: Seminar on (ENCODING AND DECODING TECHNIQUES)

www.fakengineer.com

Seminar onSeminar on

(ENCODING AND DECODING TECHNIQUES)

Page 2: Seminar on (ENCODING AND DECODING TECHNIQUES)

www.fakengineer.com

Introduction

• What is Cryptography

• Why we need Cryptography

Page 3: Seminar on (ENCODING AND DECODING TECHNIQUES)

www.fakengineer.com

Some terms associated with Cryptography

• Plaintext• Ciphertext• Encryption• Decryption• Key

Page 4: Seminar on (ENCODING AND DECODING TECHNIQUES)

www.fakengineer.com

Methods for Encryption/Decryption

Conventional Methods

Public key Methods

Page 5: Seminar on (ENCODING AND DECODING TECHNIQUES)

www.fakengineer.com

Conventional methods

Character-level encryption

• Substitutional

•Transpositional

Bit-level encryption

Page 6: Seminar on (ENCODING AND DECODING TECHNIQUES)

www.fakengineer.com

Data encryption standard (DES)

• Bit-level encryption• Designed by IBM and adopted by the U.S

government for nonmilitary use• Encrypts a 64-bit plaintext using a 56-bit key• The text is put through 19 different

procedures to create a 64-bit ciphertext

Page 7: Seminar on (ENCODING AND DECODING TECHNIQUES)

www.fakengineer.com

Page 8: Seminar on (ENCODING AND DECODING TECHNIQUES)

www.fakengineer.com

Publickey Encryption

Page 9: Seminar on (ENCODING AND DECODING TECHNIQUES)

www.fakengineer.com

RSA Encryption

• Rivest, Shamir, Adleman encryption

• Public key encryption technique• One party uses a public key, kp

• Other party uses a private key, ks

• Both use a number, N

Page 10: Seminar on (ENCODING AND DECODING TECHNIQUES)

www.fakengineer.com

Page 11: Seminar on (ENCODING AND DECODING TECHNIQUES)

www.fakengineer.com

Encryption algorithm (RSA)

• Encode the data to be encrypted as a number to create the plaintext P

• Calculate the ciphertext C=Pkp modulo N

• Send C as ciphertext

Page 12: Seminar on (ENCODING AND DECODING TECHNIQUES)

www.fakengineer.com

Decryption algorithm (RSA)

• Receive C, the ciphertext

• Calculate plaintext P=Cks modulo N

• Decode P to the original data

Page 13: Seminar on (ENCODING AND DECODING TECHNIQUES)

www.fakengineer.com

Example of RSA

• Let Kp=5, Ks=77, and N=119

• Let the character F is encoded as 6 (sixth char in alphabet)

• We calculate 6Kp modulo 119 =41• At the receiver side, we calculate 41Ks modulo

119=6 • Decode 6 as F

Page 14: Seminar on (ENCODING AND DECODING TECHNIQUES)

www.fakengineer.com

Choosing Kp, Ks and N

• First choose 2 prime numbers p and q (we choose 7 and 17)

• Calculate N=p*q (N=7*17=119)• Select Kp such that it is not a factor of (p-

1)*(q-1) (we choose 5, not factor of 96)• Select Ks such that (Kp*Ks) modulo (p-

1)*(q-1)=1 (4*96+1=385 and 385/5=77)

Page 15: Seminar on (ENCODING AND DECODING TECHNIQUES)

www.fakengineer.com