Chapter 12 Cryptography (slides edited by Erin Chambers)

Slides:



Advertisements
Similar presentations
Chapter 3 Public Key Cryptography and Message authentication.
Advertisements

Public Key Cryptography Nick Feamster CS 6262 Spring 2009.
CS 483 – SD SECTION BY DR. DANIYAL ALGHAZZAWI (3) Information Security.
Cryptology  Terminology  plaintext - text that is not encrypted.  ciphertext - the output of the encryption process.  key - the information required.
Computer Science CSC 405By Dr. Peng Ning1 CSC 405 Introduction to Computer Security Topic 2. Basic Cryptography (Part II)
1 Counter-measures Threat Monitoring Cryptography as a security tool Encryption Digital Signature Key distribution.
Dr. Lo’ai Tawalbeh Summer 2007 Chapter 9 – Public Key Cryptography and RSA Dr. Lo’ai Tawalbeh New York Institute of Technology (NYIT) Jordan’s Campus INCS.
CC3.12 Erdal KOSE Privacy & Digital Security Encryption.
BY MUKTADIUR RAHMAN MAY 06, 2010 INTERODUCTION TO CRYPTOGRAPHY.
McGraw-Hill©The McGraw-Hill Companies, Inc., Security PART VII.
Cryptography and Network Security Chapter 9. Chapter 9 – Public Key Cryptography and RSA Every Egyptian received two names, which were known respectively.
Public Key Cryptography and the RSA Algorithm
Cryptography1 CPSC 3730 Cryptography Chapter 9 Public Key Cryptography and RSA.
Private-Key Cryptography traditional private/secret/single key cryptography uses one key shared by both sender and receiver if this key is disclosed communications.
Fall 2010/Lecture 311 CS 426 (Fall 2010) Public Key Encryption and Digital Signatures.
Dr.Saleem Al_Zoubi1 Cryptography and Network Security Third Edition by William Stallings Public Key Cryptography and RSA.
Lecture 23 Symmetric Encryption
1 Pertemuan 08 Public Key Cryptography Matakuliah: H0242 / Keamanan Jaringan Tahun: 2006 Versi: 1.
8: Network Security8-1 Symmetric key cryptography symmetric key crypto: Bob and Alice share know same (symmetric) key: K r e.g., key is knowing substitution.
Chapter 13: Electronic Commerce and Information Security Invitation to Computer Science, C++ Version, Fourth Edition SP09: Contains security section (13.4)
Chapter 8.  Cryptography is the science of keeping information secure in terms of confidentiality and integrity.  Cryptography is also referred to as.
Introduction to Public Key Cryptography
Public Key Model 8. Cryptography part 2.
Page 1 Secure Communication Paul Krzyzanowski Distributed Systems Except as otherwise noted, the content of this presentation.
Prime Numbers Prime numbers only have divisors of 1 and self
Chi-Cheng Lin, Winona State University CS 313 Introduction to Computer Networking & Telecommunication Network Security (A Very Brief Introduction)
Chapter 12 Information Systems. 2 Managing Information Information system Software that helps the user organize and analyze data Electronic spreadsheets.
Chapter 20 Symmetric Encryption and Message Confidentiality.
Chapter 12 Information Systems. 2 Chapter Goals Define the role of general information systems Explain how spreadsheets are organized Create spreadsheets.
Day 18. Concepts Plaintext: the original message Ciphertext: the transformed message Encryption: transformation of plaintext into ciphertext Decryption:
Chapter 17 Security. Information Systems Cryptography Key Exchange Protocols Password Combinatorics Other Security Issues 12-2.
Midterm Review Cryptography & Network Security
Chapter 20 Symmetric Encryption and Message Confidentiality.
CS526: Information Security Prof. Sam Wagstaff September 16, 2003 Cryptography Basics.
Module 3 – Cryptography Cryptography basics Ciphers Symmetric Key Algorithms Public Key Algorithms Message Digests Digital Signatures.
Day 37 8: Network Security8-1. 8: Network Security8-2 Symmetric key cryptography symmetric key crypto: Bob and Alice share know same (symmetric) key:
Cryptography Wei Wu. Internet Threat Model Client Network Not trusted!!
Public-Key Encryption
CSCE 715: Network Systems Security Chin-Tser Huang University of South Carolina.
Public Key Cryptography. symmetric key crypto requires sender, receiver know shared secret key Q: how to agree on key in first place (particularly if.
1 Public-Key Cryptography and Message Authentication.
Computer and Network Security Rabie A. Ramadan Lecture 6.
Cryptography and Network Security Chapter 9 - Public-Key Cryptography
PUBLIC-KEY CRYPTOGRAPH IT 352 : Lecture 2- part3 Najwa AlGhamdi, MSc – 2012 /1433.
Encryption No. 1  Seattle Pacific University Encryption: Protecting Your Data While in Transit Kevin Bolding Electrical Engineering Seattle Pacific University.
24-Nov-15Security Cryptography Cryptography is the science and art of transforming messages to make them secure and immune to attacks. It involves plaintext,
Cryptography and Network Security Public Key Cryptography and RSA.
Chapter 3 – Public Key Cryptography and RSA (A). Private-Key Cryptography traditional private/secret/single-key cryptography uses one key shared by both.
Lecture 23 Symmetric Encryption
Chapter 9 Public Key Cryptography and RSA. Private-Key Cryptography traditional private/secret/single key cryptography uses one key shared by both sender.
COMP 424 Lecture 04 Advanced Encryption Techniques (DES, AES, RSA)
+ Security. + What is network security? confidentiality: only sender, intended receiver should “understand” message contents sender encrypts message receiver.
Public Key Algorithms Lesson Introduction ●Modular arithmetic ●RSA ●Diffie-Hellman.
DATA & COMPUTER SECURITY (CSNB414) MODULE 3 MODERN SYMMETRIC ENCRYPTION.
Cryptography and Network Security Third Edition by William Stallings Lecture slides by Lawrie Brown.
Computer Security Lecture 5 Ch.9 Public-Key Cryptography And RSA Prepared by Dr. Lamiaa Elshenawy.
RSA Pubic Key Encryption CSCI 5857: Encoding and Encryption.
Chapter 9 – Public Key Cryptography and RSA Every Egyptian received two names, which were known respectively as the true name and the good name, or the.
CSCE 715: Network Systems Security Chin-Tser Huang University of South Carolina.
CSEN 1001 Computer and Network Security Amr El Mougy Mouaz ElAbsawi.
Cryptography services Lecturer: Dr. Peter Soreanu Students: Raed Awad Ahmad Abdalhalim
Public Key Cryptography. Asymmetric encryption is a form of cryptosystem in which Encryption and decryption are performed using the different keys—one.
PART VII Security.
NET 311 Information Security
Chapter -5 PUBLIC-KEY CRYPTOGRAPHY AND RSA
Modern Cryptography.
Chapter Goals Define cryptography
The RSA Public-Key Encryption Algorithm
Presentation transcript:

Chapter 12 Cryptography (slides edited by Erin Chambers)

2 Cryptography The field of study related to encoded information (comes from Greek word for "secret writing") Encryption The process of converting plaintext into ciphertext Decryption The process of converting ciphertext into plaintext

3 Cryptography plaintext message ciphertext message Encryption Decryption Encrypted(Information) cannot be read Decrypted(Encrypted(Information)) can be

4 Cryptography Cipher An algorithm used to encrypt and decrypt text Key The set of parameters that guide a cipher Neither is any good without the other

Substitution Ciphers A cipher that substitutes one character with another. These can be as simple as swapping a list, or can be based on more complex rules. These are NOT secure anymore, but they used to be quite common. What has changed?

6 Caesar ciphers A B C D E F G H I J K L M N O P Q R S T U V W X Y Z D E F G H I J K L M N O P Q R S T U V W X Y Z A B C Substitute the letters in the second row for the letters in the top row to encrypt a message Encrypt(COMPUTER) gives FRPSXWHU Substitute the letters in the first row for the letters in the second row to decrypt a message Decrypt(Encrypt(COMPUTER)) = Decrypt(FRPSXWHU) = COMPUTER

7 Transposition Cipher T O D A Y + I S + M O N D A Y Write the letters in a row of five, using '+' as a blank. Encrypt by starting spiraling inward from the top left moving counter clockwise Encrypt(TODAY IS MONDAY) gives T+ONDAYMYADOIS+ Decrypt by recreating the grid and reading the letters across the row The key are the dimension of the grid and the route used to encrypt the data

8 Cryptanalysis The process of decrypting a message without knowing the cipher or the key used to encrypt it Substitution and transposition ciphers are easy for modern computers to break To protect information more sophisticated schemes are needed

Encryption on computers Roughly speaking, there are two different broad types of encryption that are used on computers today –Symmetric encryption relies on keeping keys totally secret –Asymmetric encryption actually publicizes one key, but keeps some information private also Neither is really “better” - they just use different principles. In reality, both are vulnerable to attacks.

Symmetric, or private key cryptography Most common type is called a block cipher –Processes the plaintext in fixed sizes blocks Examples include DES, 3DES, and AES All require a secret key which is known by both parties in the communication Main issue here: need to securely swap the key. How can we do this?

DES: Data Encryption Standard Adopted in 1977 by National Bureau of Standards (now NIST) Divides message into blocks of 64 bits, and uses a key of 56 bits Key idea for this: XOR the data with the key –(Remember XOR? How did it work?)

DES In July 1998, DES was officially cracked by a machine built by the EFF –Total cost: under $250,000 –Total time: 6-8 months They then published the details of their approach, which essentially was a brute force attack Note: 56 bits means 2 56 keys to try Also, not as easy as just trying. What do you always do to files before sending them somewhere?

3DES Effort to salvage DES Main algorithm: repeat DES 3 times with different keys (so key size is now 168 bits) Still very secure - brute force attacks would take too long, and that is the only way to attack this algorithm Main problem: SLOW

Advanced Encryption Standard (AES) Designed in response to a call by NIST in 1998, and officially adopted in 2001 Block length is 128 bits, and keys can be 128, 192, or 256 bits. Essentially, proceeds in 4 rounds (which are repeated): –Substitute bytes –Permute –Mix columns –Add round key

Stage 1: substitute bytes AES computes a matrix which maps every 8-bit value to a different 8-bit value Computed using properties of finite fields (go take some math classes to learn more about this)

Stage 2: permute AES then shifts each row, where each row is shifted a different amount

Stage 3: Mix columns Here, the 4 bytes in each column are combined using a linear transformation Essentially, the output of any byte depends on all the input bytes, so this “mixes” them together

Stage 4: Add round key Use XOR to combine the key with the message

Public Key Cryptography First revolution in cryptography in hundreds of years Originally introduced in a paper in 1976: “New directions in cryptography”, by Diffie and Hellman Initially, based on the goal of computing a common secret key (so combines well with AES or other symmetric algorithms)

20 Public/Private Keys What is it? An approach in which each user has two related keys, one public and one private One's public key is distributed freely A person encrypts an outgoing message, using the receiver's public key. Only the receiver's private key can decrypt the message

Basic operations Logarithms: defined as the the exponent to which a fixed number, the base, must be raised to in order to produce that number Examples: –Log 3 9 = 2, since 3 2 = 9 –Log = 3, since 10 3 = 1000 –Log 2 64 = 6, since 2 6 = 64

Basic operations (cont) Modulo operation: just taking remainders a mod b = remainder when a is divided by b Examples: –1 mod 3 = 1 –15 mod 10 = 5 –256 mod 2 = 0

Public and private keys First, choose X, a secret key Then choose Q = a prime number, and A = some other number Set Y = A X mod Q Note that X = log A Y mod Q

Public and private keys Now publish Y, A, and Q, but keep X secret Anyone knows that X = log A Y mod Q, but this is difficult to compute! This is called the discrete logarithm problem - very similar to factoring in terms of difficulty, so no polynomial time algorithm is known. Essentially, computing Y given X is easy, but computing X given Y is much harder. (Go take number theory.)

How to encrypt So I know X, Y, A, and Q (but you don’t know X). You get your own X’, and the tell me Y’=A X’ mod Q We can now compute our own secret key (and use it for AES or some other algorithm) –I will compute (Y’) X mod Q = (A X’ ) X mod Q –You compute (Y) X’ mod Q = (A X ) X’ mod Q These are equal! But an eavesdropper can’t compute them, since they don’t have X or X’

Attacks One downside: this is less secure than pure symmetric encryption There are ways to attack this that do better than brute force Number theory and group theory allow theoretical attacks that are provably better than exponential, but worse than polynomial time So it is NOT known if this problem is really hard! Someone could develop a polynomial time attack. It just hasn’t been done yet.

RSA In 1977, Rivest, Shamir, and Adleman came up with another way to use public key cryptography Rather than secure key exchanges, this one actually lets you encrypt whole messages Today, this is the most commonly used public key cryptosystem on the market

How RSA works Choose 2 prime numbers, p and q Set n=pq Compute  (n) = the number of numbers less than n which are relatively prime to n –(That means numbers which have no common divisors.) Here,  (n) =  (p)  (q) –What is  (p)?  (q)?

RSA (cont.) So  (n) = (p-1)(q-1), which we can compute. Note that this is hard to find if you don’t know p and q, but it’s easy if you do. Now pick a value e, where e is relatively prime to  (n). This is your public key. Compute another value d, where we must have de = 1 mod  (n). This is your private key. –Example: Suppose e = 2, n = 11. Then d = 6, since we know (6)(2) mod 11= 12 mod 11 = 1

Encrypting with RSA Now I have a message m, as well as e and n. I compute c = m e mod n, and send it to you. You have d, so you can compute the value c d mod n = (m e ) d mod n = m 1 mod n. But without d, this is not easy! Equivalent to factoring in difficulty.

31 Public/Private Keys: Other uses Digital signature Data that is appended to a message, made from the message itself and the sender's private key, to ensure the authenticity of the message Digital certificate A representation of a sender's authenticated public key used to minimize malicious forgeries