SlideShare a Scribd company logo
Princeton University • COS 433 • Cryptography • Fall 2007 • Boaz Barak
Cryptography
Mohammed Sabith
IX A {Techno}
Mangalore
Two important quick notes:
 Slides will be on course web site
 Please stop me if you have questions!
2
Cryptography
History of 2500- 4000 years.
Recurring theme: (until 1970’s)
 Secret code invented
 Typically claimed “unbreakable” by inventor
 Used by spies, ambassadors, kings, generals for crucial tasks.
 Broken by enemy using cryptanalysis.
Throughout most of this history:
cryptography = “secret writing”:
“Scramble” (encrypt) text such that it is hopefully unreadable by
anyone except the intended receiver that can decrypt it.
3
Examples
1587: Ciphers from Mary of Scots plotting assassination of queen
Elizabeth broken; used as evidence to convict her of treason.
1860’s (civil war): Confederacy used good cipher (Vigenere) in a bad
way. Messages routinely broken by team of young union
cryptanalysts; in particular leading to a Manhattan manufacturer of
plates for printing rebel currency.
1878: New York Tribune decodes telegram proving Democrats’ attempt
to buy an electoral vote in presidential election for $10K.
1914: With aid of partial info from sunken German ships, British
intelligence broke all German codes.
Cracked telegram of German plan to form alliance with Mexico and
conquer back territory from U.S. As a result, U.S. joined WWI.
WWII: Cryptanalysis used by both sides. Polish & British cryptanalysts
break supposedly unbreakable Enigma cipher using mix of
ingenuity, German negligence, and mechanical computation.
Churchill credits cryptanalysts with winning the war.
4
This Course
What you’ll learn:
 Foundations and principles of the science
 Definitions and proofs of security
 High-level applications
 Critical view of security suggestions and products
What you will not learn:
 The most efficient and practical versions of components.
 Designing secure systems*
 “Hacking” – breaking into systems.
 Everything important about crypto
 Basic primitives and components.
 Viruses, worms, Windows/Unix bugs, buffer overflow etc..
 Buzzwords
Will help you avoid designing
insecure systems.
5
This Course
Modern (post 1970’s) cryptography:
Provable security – breaking the “invent-break-tweak” cycle
 Perfect security (Shannon) and its limitations
 Computational security
 Pseudorandom generators, one way functions
Beyond encryption – public-key crypto and other wonderful creatures
 Public-key encryption based on factoring and RSA problem
 Digital signatures, hash functions
 Zero-knowledge proofs
 Active security – Chosen-Ciphertext Attack
Advanced topics (won’t have time for all  )
 The SSL Protocol and attacks on it
 Secret Sharing
 Multi-party secure computation
 Quantum cryptography
 Password-based key-exchange, broadcast encryption, obfuscation
6
Administrative Info
Lectures: Tue,Thu 1:30-2:50pm (start on time!)
Instructor: Boaz Barak: boaz@cs
Web page: http://www.cs.princeton.edu/courses/archive/fall07/cos433/
Or: Google “Boaz Barak” and click “courses”
TA: Rajsekar Manokaran ( rajsekar@cs )
Important: join mailing list, email me to set appointment
before next class
Office hrs: Thu after class (3pm) or by appointment.
Precepts: ---
Office hrs: ---
7
Prerequisites
1. Ability to read and write mathematical proofs and definitions.
2. Familiarity with algorithms – proving correctness and
analyzing running time (O notation).
Required:
Helpful but not necessary:
Complexity. NP-Completeness, reductions, P, BPP, P/poly
Probabilistic Algorithms. Primality testing, hashing,
Number theory. Modular arithmetic, prime numbers
See web-site for links and resources.
3. Familiarity with basic probability theory (random variables,
expectations – see handout).
8
Reading
Foundations of Cryptography / Goldreich.
Graduate-level text, will be sometimes used.
Lecture notes on web: (links on web site)
Computational Intro to Algebra and Number Theory / Shoup.
(Available also on the web)
Introduction to the Theory of Computation / Sipser.
For complexity background
Introduction to Modern Cryptography / Katz & Lindell
Main text used, though not 100% followed
9
Requirements
Exercises: Weekly from Thursday till Thursday before class.
Submit by email / mailbox / in class to Rajsekar.
Flexibility: 4 late days, bonus questions
Take home final.
Final grade: 50% homework, 50% final
Honor code. Collaboration on homework with other students encouraged.
However, write alone and give credit.
Work on final alone and as directed.
10
This course is hard
 Challenging weekly exercises
 Emphasis on mathematical proofs
 Counterintuitive concepts.
 Extensive use of quantifiers/probability
But it’s not my fault :)
 Good coverage of crypto (meat, vegetables and desert) takes a year.
 Simulation / experimentation can’t be used to show security.
 Need to acquire “crypto-intuition”
 Quantifiers, proofs by contradiction, reductions, probability are inherent.
Mitigating hardness
 Avoid excessive exercises – only questions that teach you something.
 Try best to explain intuition behind proofs
 Me and Rajsekar available for any questions and clarifications.
11
Encryption Schemes
Alice wants to send Bob a secret message.
They agree in advance on 3 components:
 Encryption algorithm: E
 Decryption algorithm: D
 Secret key: k
To encrypt plaintext m, Alice sends c = E(m,k) to Bob.
To decrypt a cyphertext c, Bob computes m’ = D(c,k).
c = E(m,k)
c
m’ = D(c,k)
 A scheme is valid if m’=m
 Intuitively, a scheme is secure if eavesdropper can not learn m from c.
12
Example 1: Caesar’s Cipher
Key: k = no. between 0 and 25.
Encryption: encode the ith letter as the (i+k) th letter.
(working mod 26: z+1=a )
Decryption: decode the jth letter to the (j-k) th letter.
S E N D R E I N F O R C E M E N T
Plain-text:
Key: 2
Cipher-text: U G P F T F K P H Q T E G O G P V
Problem: only 26 possibilities for key – can be broken in short time.
In other words: “security through obscurity” does not work.
Kerchoff’s Principle (1883): System should be secure even if
algorithms are known, as long as key is secret.
13
Example 2: Substitution Cipher
Key: k = table mapping each letter to another letter
A B C Z
U R B E
Encryption and decryption: letter by letter according to table.
# of possible keys: 26! ( = 403,291,461,126,605,635,584,000,000 )
However – substitution cipher is still insecure!
Key observation: can recover plaintext using statistics on letter
frequencies.
LIVITCSWPIYVEWHEVSRIQMXLEYVEOIEWHRXEXIPFEMVEWHKVSTYLX
ZIXLIKIIXPIJVSZEYPERRGERIMWQLMGLMXQERIWGPSRIHMXQEREKI
He e e e h e t t ht
ethe eet e e h h t e e t e
I – most common letter
LI – most common pair
XLI – most common triple
Here e r e h e t t r r ht
ethe eet e r e h h t e e t e
I=e L=h X=t
Here e ra a e ha a ea tat a ra r ht
ethe eet e r a a e h h t a e e t a a e
V=r E=a Y=g
HereUpOnLeGrandAroseWithAGraveAndStatelyAirAndBrought
MeTheBeetleFromAGlassCaseInWhichItWasEnclosedItWasABe
14
Example 3- Vigenere
“Multi-Caesar Cipher” – A statefull cipher
Key: k = (k1,k2,…,km) list of m numbers between 0 and 25
Encryption:
Breaking Vigenere:
nth letter encoded w/ key=k(n mod m) : i  I + k(n mod m) (mod 26)
(Belaso, 1553)
LIVITCSWPIYVEWHEVSRIQMXLEYVEOIEWHRXEXIPFEM VEWHKV
Step 1: Guess the length of the key m
Step 2: Group together positions {1, m+1, 2m+1, 3m+1,…}
{m-1, 2m+m-1, 3m+m-1,…}
Decryption: In the natural way
…
{2, m+2, 2m+2, 3m+2,…}
15
Cryptography & Security
Prev slides: Have provably secure algorithm for every crypto task imaginable.
Q: How come nothing is secure?
A2: Cryptography is only part of designing secure systems
 Chain is only as strong as weakest link.
 A “dormant bug” is often a security hole.
 Security is hard to “modularize”
 Human element
(hard to add to existing system, changes in system
features can have unexpected consequences)
 Many subtle issues (e.g., caching & virtual memory, side
channel attacks)
 Key storage and protection issues.

More Related Content

Similar to sabith.pptx

Classical encryption techniques
Classical encryption techniquesClassical encryption techniques
Classical encryption techniques
Janani S
 
What is Cryptography?
What is Cryptography?What is Cryptography?
What is Cryptography?
Pratik Poddar
 
Cryptography
CryptographyCryptography
Cryptography
Christian Bokhove
 
unit 2.ppt
unit 2.pptunit 2.ppt
unit 2.ppt
HetaDesai13
 
Quantum cryptography
Quantum cryptographyQuantum cryptography
Quantum cryptography
Nishant Bhardwaj
 
Chapter8 27 nov_2010
Chapter8 27 nov_2010Chapter8 27 nov_2010
Chapter8 27 nov_2010Umang Gupta
 
Cryptography for developers
Cryptography for developersCryptography for developers
Cryptography for developers
Kai Koenig
 
Cryptography - A Brief History
Cryptography - A Brief HistoryCryptography - A Brief History
Cryptography - A Brief History
prasenjeetd
 
Ppt ns
Ppt nsPpt ns
02 Information System Security
02  Information System Security02  Information System Security
02 Information System Security
Shu Shin
 
Introduction to cryptography part2-final
Introduction to cryptography  part2-finalIntroduction to cryptography  part2-final
Introduction to cryptography part2-final
Taymoor Nazmy
 
Cryp Essay
Cryp EssayCryp Essay
Cryp Essay
Carmen Sanborn
 
Nt1330 Unit 4 Dthm Paper
Nt1330 Unit 4 Dthm PaperNt1330 Unit 4 Dthm Paper
Nt1330 Unit 4 Dthm Paper
Jennifer Reither
 
Cryptography - An Overview
Cryptography - An OverviewCryptography - An Overview
Cryptography - An Overview
ppd1961
 
Ch08-CryptoConcepts.ppt
Ch08-CryptoConcepts.pptCh08-CryptoConcepts.ppt
Ch08-CryptoConcepts.ppt
ShounakDas16
 
Cs166 mynote
Cs166 mynoteCs166 mynote
Cs166 mynote
Kaya Ota
 
Cryptography
CryptographyCryptography
Cryptography
IGZ Software house
 

Similar to sabith.pptx (20)

Classical encryption techniques
Classical encryption techniquesClassical encryption techniques
Classical encryption techniques
 
What is Cryptography?
What is Cryptography?What is Cryptography?
What is Cryptography?
 
Cryptography
CryptographyCryptography
Cryptography
 
unit 2.ppt
unit 2.pptunit 2.ppt
unit 2.ppt
 
Quantum cryptography
Quantum cryptographyQuantum cryptography
Quantum cryptography
 
MAT255_Final_Paper_RSA_Encryption
MAT255_Final_Paper_RSA_EncryptionMAT255_Final_Paper_RSA_Encryption
MAT255_Final_Paper_RSA_Encryption
 
b
bb
b
 
Chapter8 27 nov_2010
Chapter8 27 nov_2010Chapter8 27 nov_2010
Chapter8 27 nov_2010
 
Cryptography for developers
Cryptography for developersCryptography for developers
Cryptography for developers
 
Cryptography - A Brief History
Cryptography - A Brief HistoryCryptography - A Brief History
Cryptography - A Brief History
 
Otp2
Otp2Otp2
Otp2
 
Ppt ns
Ppt nsPpt ns
Ppt ns
 
02 Information System Security
02  Information System Security02  Information System Security
02 Information System Security
 
Introduction to cryptography part2-final
Introduction to cryptography  part2-finalIntroduction to cryptography  part2-final
Introduction to cryptography part2-final
 
Cryp Essay
Cryp EssayCryp Essay
Cryp Essay
 
Nt1330 Unit 4 Dthm Paper
Nt1330 Unit 4 Dthm PaperNt1330 Unit 4 Dthm Paper
Nt1330 Unit 4 Dthm Paper
 
Cryptography - An Overview
Cryptography - An OverviewCryptography - An Overview
Cryptography - An Overview
 
Ch08-CryptoConcepts.ppt
Ch08-CryptoConcepts.pptCh08-CryptoConcepts.ppt
Ch08-CryptoConcepts.ppt
 
Cs166 mynote
Cs166 mynoteCs166 mynote
Cs166 mynote
 
Cryptography
CryptographyCryptography
Cryptography
 

Recently uploaded

Influence of Marketing Strategy and Market Competition on Business Plan
Influence of Marketing Strategy and Market Competition on Business PlanInfluence of Marketing Strategy and Market Competition on Business Plan
Influence of Marketing Strategy and Market Competition on Business Plan
jerlynmaetalle
 
Analysis insight about a Flyball dog competition team's performance
Analysis insight about a Flyball dog competition team's performanceAnalysis insight about a Flyball dog competition team's performance
Analysis insight about a Flyball dog competition team's performance
roli9797
 
一比一原版(UofS毕业证书)萨省大学毕业证如何办理
一比一原版(UofS毕业证书)萨省大学毕业证如何办理一比一原版(UofS毕业证书)萨省大学毕业证如何办理
一比一原版(UofS毕业证书)萨省大学毕业证如何办理
v3tuleee
 
一比一原版(Bradford毕业证书)布拉德福德大学毕业证如何办理
一比一原版(Bradford毕业证书)布拉德福德大学毕业证如何办理一比一原版(Bradford毕业证书)布拉德福德大学毕业证如何办理
一比一原版(Bradford毕业证书)布拉德福德大学毕业证如何办理
mbawufebxi
 
一比一原版(Dalhousie毕业证书)达尔豪斯大学毕业证如何办理
一比一原版(Dalhousie毕业证书)达尔豪斯大学毕业证如何办理一比一原版(Dalhousie毕业证书)达尔豪斯大学毕业证如何办理
一比一原版(Dalhousie毕业证书)达尔豪斯大学毕业证如何办理
mzpolocfi
 
一比一原版(爱大毕业证书)爱丁堡大学毕业证如何办理
一比一原版(爱大毕业证书)爱丁堡大学毕业证如何办理一比一原版(爱大毕业证书)爱丁堡大学毕业证如何办理
一比一原版(爱大毕业证书)爱丁堡大学毕业证如何办理
g4dpvqap0
 
The affect of service quality and online reviews on customer loyalty in the E...
The affect of service quality and online reviews on customer loyalty in the E...The affect of service quality and online reviews on customer loyalty in the E...
The affect of service quality and online reviews on customer loyalty in the E...
jerlynmaetalle
 
Learn SQL from basic queries to Advance queries
Learn SQL from basic queries to Advance queriesLearn SQL from basic queries to Advance queries
Learn SQL from basic queries to Advance queries
manishkhaire30
 
Adjusting OpenMP PageRank : SHORT REPORT / NOTES
Adjusting OpenMP PageRank : SHORT REPORT / NOTESAdjusting OpenMP PageRank : SHORT REPORT / NOTES
Adjusting OpenMP PageRank : SHORT REPORT / NOTES
Subhajit Sahu
 
Malana- Gimlet Market Analysis (Portfolio 2)
Malana- Gimlet Market Analysis (Portfolio 2)Malana- Gimlet Market Analysis (Portfolio 2)
Malana- Gimlet Market Analysis (Portfolio 2)
TravisMalana
 
Data_and_Analytics_Essentials_Architect_an_Analytics_Platform.pptx
Data_and_Analytics_Essentials_Architect_an_Analytics_Platform.pptxData_and_Analytics_Essentials_Architect_an_Analytics_Platform.pptx
Data_and_Analytics_Essentials_Architect_an_Analytics_Platform.pptx
AnirbanRoy608946
 
Enhanced Enterprise Intelligence with your personal AI Data Copilot.pdf
Enhanced Enterprise Intelligence with your personal AI Data Copilot.pdfEnhanced Enterprise Intelligence with your personal AI Data Copilot.pdf
Enhanced Enterprise Intelligence with your personal AI Data Copilot.pdf
GetInData
 
ViewShift: Hassle-free Dynamic Policy Enforcement for Every Data Lake
ViewShift: Hassle-free Dynamic Policy Enforcement for Every Data LakeViewShift: Hassle-free Dynamic Policy Enforcement for Every Data Lake
ViewShift: Hassle-free Dynamic Policy Enforcement for Every Data Lake
Walaa Eldin Moustafa
 
办(uts毕业证书)悉尼科技大学毕业证学历证书原版一模一样
办(uts毕业证书)悉尼科技大学毕业证学历证书原版一模一样办(uts毕业证书)悉尼科技大学毕业证学历证书原版一模一样
办(uts毕业证书)悉尼科技大学毕业证学历证书原版一模一样
apvysm8
 
一比一原版(UniSA毕业证书)南澳大学毕业证如何办理
一比一原版(UniSA毕业证书)南澳大学毕业证如何办理一比一原版(UniSA毕业证书)南澳大学毕业证如何办理
一比一原版(UniSA毕业证书)南澳大学毕业证如何办理
slg6lamcq
 
Everything you wanted to know about LIHTC
Everything you wanted to know about LIHTCEverything you wanted to know about LIHTC
Everything you wanted to know about LIHTC
Roger Valdez
 
Chatty Kathy - UNC Bootcamp Final Project Presentation - Final Version - 5.23...
Chatty Kathy - UNC Bootcamp Final Project Presentation - Final Version - 5.23...Chatty Kathy - UNC Bootcamp Final Project Presentation - Final Version - 5.23...
Chatty Kathy - UNC Bootcamp Final Project Presentation - Final Version - 5.23...
John Andrews
 
Unleashing the Power of Data_ Choosing a Trusted Analytics Platform.pdf
Unleashing the Power of Data_ Choosing a Trusted Analytics Platform.pdfUnleashing the Power of Data_ Choosing a Trusted Analytics Platform.pdf
Unleashing the Power of Data_ Choosing a Trusted Analytics Platform.pdf
Enterprise Wired
 
原版制作(swinburne毕业证书)斯威本科技大学毕业证毕业完成信一模一样
原版制作(swinburne毕业证书)斯威本科技大学毕业证毕业完成信一模一样原版制作(swinburne毕业证书)斯威本科技大学毕业证毕业完成信一模一样
原版制作(swinburne毕业证书)斯威本科技大学毕业证毕业完成信一模一样
u86oixdj
 
Levelwise PageRank with Loop-Based Dead End Handling Strategy : SHORT REPORT ...
Levelwise PageRank with Loop-Based Dead End Handling Strategy : SHORT REPORT ...Levelwise PageRank with Loop-Based Dead End Handling Strategy : SHORT REPORT ...
Levelwise PageRank with Loop-Based Dead End Handling Strategy : SHORT REPORT ...
Subhajit Sahu
 

Recently uploaded (20)

Influence of Marketing Strategy and Market Competition on Business Plan
Influence of Marketing Strategy and Market Competition on Business PlanInfluence of Marketing Strategy and Market Competition on Business Plan
Influence of Marketing Strategy and Market Competition on Business Plan
 
Analysis insight about a Flyball dog competition team's performance
Analysis insight about a Flyball dog competition team's performanceAnalysis insight about a Flyball dog competition team's performance
Analysis insight about a Flyball dog competition team's performance
 
一比一原版(UofS毕业证书)萨省大学毕业证如何办理
一比一原版(UofS毕业证书)萨省大学毕业证如何办理一比一原版(UofS毕业证书)萨省大学毕业证如何办理
一比一原版(UofS毕业证书)萨省大学毕业证如何办理
 
一比一原版(Bradford毕业证书)布拉德福德大学毕业证如何办理
一比一原版(Bradford毕业证书)布拉德福德大学毕业证如何办理一比一原版(Bradford毕业证书)布拉德福德大学毕业证如何办理
一比一原版(Bradford毕业证书)布拉德福德大学毕业证如何办理
 
一比一原版(Dalhousie毕业证书)达尔豪斯大学毕业证如何办理
一比一原版(Dalhousie毕业证书)达尔豪斯大学毕业证如何办理一比一原版(Dalhousie毕业证书)达尔豪斯大学毕业证如何办理
一比一原版(Dalhousie毕业证书)达尔豪斯大学毕业证如何办理
 
一比一原版(爱大毕业证书)爱丁堡大学毕业证如何办理
一比一原版(爱大毕业证书)爱丁堡大学毕业证如何办理一比一原版(爱大毕业证书)爱丁堡大学毕业证如何办理
一比一原版(爱大毕业证书)爱丁堡大学毕业证如何办理
 
The affect of service quality and online reviews on customer loyalty in the E...
The affect of service quality and online reviews on customer loyalty in the E...The affect of service quality and online reviews on customer loyalty in the E...
The affect of service quality and online reviews on customer loyalty in the E...
 
Learn SQL from basic queries to Advance queries
Learn SQL from basic queries to Advance queriesLearn SQL from basic queries to Advance queries
Learn SQL from basic queries to Advance queries
 
Adjusting OpenMP PageRank : SHORT REPORT / NOTES
Adjusting OpenMP PageRank : SHORT REPORT / NOTESAdjusting OpenMP PageRank : SHORT REPORT / NOTES
Adjusting OpenMP PageRank : SHORT REPORT / NOTES
 
Malana- Gimlet Market Analysis (Portfolio 2)
Malana- Gimlet Market Analysis (Portfolio 2)Malana- Gimlet Market Analysis (Portfolio 2)
Malana- Gimlet Market Analysis (Portfolio 2)
 
Data_and_Analytics_Essentials_Architect_an_Analytics_Platform.pptx
Data_and_Analytics_Essentials_Architect_an_Analytics_Platform.pptxData_and_Analytics_Essentials_Architect_an_Analytics_Platform.pptx
Data_and_Analytics_Essentials_Architect_an_Analytics_Platform.pptx
 
Enhanced Enterprise Intelligence with your personal AI Data Copilot.pdf
Enhanced Enterprise Intelligence with your personal AI Data Copilot.pdfEnhanced Enterprise Intelligence with your personal AI Data Copilot.pdf
Enhanced Enterprise Intelligence with your personal AI Data Copilot.pdf
 
ViewShift: Hassle-free Dynamic Policy Enforcement for Every Data Lake
ViewShift: Hassle-free Dynamic Policy Enforcement for Every Data LakeViewShift: Hassle-free Dynamic Policy Enforcement for Every Data Lake
ViewShift: Hassle-free Dynamic Policy Enforcement for Every Data Lake
 
办(uts毕业证书)悉尼科技大学毕业证学历证书原版一模一样
办(uts毕业证书)悉尼科技大学毕业证学历证书原版一模一样办(uts毕业证书)悉尼科技大学毕业证学历证书原版一模一样
办(uts毕业证书)悉尼科技大学毕业证学历证书原版一模一样
 
一比一原版(UniSA毕业证书)南澳大学毕业证如何办理
一比一原版(UniSA毕业证书)南澳大学毕业证如何办理一比一原版(UniSA毕业证书)南澳大学毕业证如何办理
一比一原版(UniSA毕业证书)南澳大学毕业证如何办理
 
Everything you wanted to know about LIHTC
Everything you wanted to know about LIHTCEverything you wanted to know about LIHTC
Everything you wanted to know about LIHTC
 
Chatty Kathy - UNC Bootcamp Final Project Presentation - Final Version - 5.23...
Chatty Kathy - UNC Bootcamp Final Project Presentation - Final Version - 5.23...Chatty Kathy - UNC Bootcamp Final Project Presentation - Final Version - 5.23...
Chatty Kathy - UNC Bootcamp Final Project Presentation - Final Version - 5.23...
 
Unleashing the Power of Data_ Choosing a Trusted Analytics Platform.pdf
Unleashing the Power of Data_ Choosing a Trusted Analytics Platform.pdfUnleashing the Power of Data_ Choosing a Trusted Analytics Platform.pdf
Unleashing the Power of Data_ Choosing a Trusted Analytics Platform.pdf
 
原版制作(swinburne毕业证书)斯威本科技大学毕业证毕业完成信一模一样
原版制作(swinburne毕业证书)斯威本科技大学毕业证毕业完成信一模一样原版制作(swinburne毕业证书)斯威本科技大学毕业证毕业完成信一模一样
原版制作(swinburne毕业证书)斯威本科技大学毕业证毕业完成信一模一样
 
Levelwise PageRank with Loop-Based Dead End Handling Strategy : SHORT REPORT ...
Levelwise PageRank with Loop-Based Dead End Handling Strategy : SHORT REPORT ...Levelwise PageRank with Loop-Based Dead End Handling Strategy : SHORT REPORT ...
Levelwise PageRank with Loop-Based Dead End Handling Strategy : SHORT REPORT ...
 

sabith.pptx

  • 1. Princeton University • COS 433 • Cryptography • Fall 2007 • Boaz Barak Cryptography Mohammed Sabith IX A {Techno} Mangalore Two important quick notes:  Slides will be on course web site  Please stop me if you have questions!
  • 2. 2 Cryptography History of 2500- 4000 years. Recurring theme: (until 1970’s)  Secret code invented  Typically claimed “unbreakable” by inventor  Used by spies, ambassadors, kings, generals for crucial tasks.  Broken by enemy using cryptanalysis. Throughout most of this history: cryptography = “secret writing”: “Scramble” (encrypt) text such that it is hopefully unreadable by anyone except the intended receiver that can decrypt it.
  • 3. 3 Examples 1587: Ciphers from Mary of Scots plotting assassination of queen Elizabeth broken; used as evidence to convict her of treason. 1860’s (civil war): Confederacy used good cipher (Vigenere) in a bad way. Messages routinely broken by team of young union cryptanalysts; in particular leading to a Manhattan manufacturer of plates for printing rebel currency. 1878: New York Tribune decodes telegram proving Democrats’ attempt to buy an electoral vote in presidential election for $10K. 1914: With aid of partial info from sunken German ships, British intelligence broke all German codes. Cracked telegram of German plan to form alliance with Mexico and conquer back territory from U.S. As a result, U.S. joined WWI. WWII: Cryptanalysis used by both sides. Polish & British cryptanalysts break supposedly unbreakable Enigma cipher using mix of ingenuity, German negligence, and mechanical computation. Churchill credits cryptanalysts with winning the war.
  • 4. 4 This Course What you’ll learn:  Foundations and principles of the science  Definitions and proofs of security  High-level applications  Critical view of security suggestions and products What you will not learn:  The most efficient and practical versions of components.  Designing secure systems*  “Hacking” – breaking into systems.  Everything important about crypto  Basic primitives and components.  Viruses, worms, Windows/Unix bugs, buffer overflow etc..  Buzzwords Will help you avoid designing insecure systems.
  • 5. 5 This Course Modern (post 1970’s) cryptography: Provable security – breaking the “invent-break-tweak” cycle  Perfect security (Shannon) and its limitations  Computational security  Pseudorandom generators, one way functions Beyond encryption – public-key crypto and other wonderful creatures  Public-key encryption based on factoring and RSA problem  Digital signatures, hash functions  Zero-knowledge proofs  Active security – Chosen-Ciphertext Attack Advanced topics (won’t have time for all  )  The SSL Protocol and attacks on it  Secret Sharing  Multi-party secure computation  Quantum cryptography  Password-based key-exchange, broadcast encryption, obfuscation
  • 6. 6 Administrative Info Lectures: Tue,Thu 1:30-2:50pm (start on time!) Instructor: Boaz Barak: boaz@cs Web page: http://www.cs.princeton.edu/courses/archive/fall07/cos433/ Or: Google “Boaz Barak” and click “courses” TA: Rajsekar Manokaran ( rajsekar@cs ) Important: join mailing list, email me to set appointment before next class Office hrs: Thu after class (3pm) or by appointment. Precepts: --- Office hrs: ---
  • 7. 7 Prerequisites 1. Ability to read and write mathematical proofs and definitions. 2. Familiarity with algorithms – proving correctness and analyzing running time (O notation). Required: Helpful but not necessary: Complexity. NP-Completeness, reductions, P, BPP, P/poly Probabilistic Algorithms. Primality testing, hashing, Number theory. Modular arithmetic, prime numbers See web-site for links and resources. 3. Familiarity with basic probability theory (random variables, expectations – see handout).
  • 8. 8 Reading Foundations of Cryptography / Goldreich. Graduate-level text, will be sometimes used. Lecture notes on web: (links on web site) Computational Intro to Algebra and Number Theory / Shoup. (Available also on the web) Introduction to the Theory of Computation / Sipser. For complexity background Introduction to Modern Cryptography / Katz & Lindell Main text used, though not 100% followed
  • 9. 9 Requirements Exercises: Weekly from Thursday till Thursday before class. Submit by email / mailbox / in class to Rajsekar. Flexibility: 4 late days, bonus questions Take home final. Final grade: 50% homework, 50% final Honor code. Collaboration on homework with other students encouraged. However, write alone and give credit. Work on final alone and as directed.
  • 10. 10 This course is hard  Challenging weekly exercises  Emphasis on mathematical proofs  Counterintuitive concepts.  Extensive use of quantifiers/probability But it’s not my fault :)  Good coverage of crypto (meat, vegetables and desert) takes a year.  Simulation / experimentation can’t be used to show security.  Need to acquire “crypto-intuition”  Quantifiers, proofs by contradiction, reductions, probability are inherent. Mitigating hardness  Avoid excessive exercises – only questions that teach you something.  Try best to explain intuition behind proofs  Me and Rajsekar available for any questions and clarifications.
  • 11. 11 Encryption Schemes Alice wants to send Bob a secret message. They agree in advance on 3 components:  Encryption algorithm: E  Decryption algorithm: D  Secret key: k To encrypt plaintext m, Alice sends c = E(m,k) to Bob. To decrypt a cyphertext c, Bob computes m’ = D(c,k). c = E(m,k) c m’ = D(c,k)  A scheme is valid if m’=m  Intuitively, a scheme is secure if eavesdropper can not learn m from c.
  • 12. 12 Example 1: Caesar’s Cipher Key: k = no. between 0 and 25. Encryption: encode the ith letter as the (i+k) th letter. (working mod 26: z+1=a ) Decryption: decode the jth letter to the (j-k) th letter. S E N D R E I N F O R C E M E N T Plain-text: Key: 2 Cipher-text: U G P F T F K P H Q T E G O G P V Problem: only 26 possibilities for key – can be broken in short time. In other words: “security through obscurity” does not work. Kerchoff’s Principle (1883): System should be secure even if algorithms are known, as long as key is secret.
  • 13. 13 Example 2: Substitution Cipher Key: k = table mapping each letter to another letter A B C Z U R B E Encryption and decryption: letter by letter according to table. # of possible keys: 26! ( = 403,291,461,126,605,635,584,000,000 ) However – substitution cipher is still insecure! Key observation: can recover plaintext using statistics on letter frequencies. LIVITCSWPIYVEWHEVSRIQMXLEYVEOIEWHRXEXIPFEMVEWHKVSTYLX ZIXLIKIIXPIJVSZEYPERRGERIMWQLMGLMXQERIWGPSRIHMXQEREKI He e e e h e t t ht ethe eet e e h h t e e t e I – most common letter LI – most common pair XLI – most common triple Here e r e h e t t r r ht ethe eet e r e h h t e e t e I=e L=h X=t Here e ra a e ha a ea tat a ra r ht ethe eet e r a a e h h t a e e t a a e V=r E=a Y=g HereUpOnLeGrandAroseWithAGraveAndStatelyAirAndBrought MeTheBeetleFromAGlassCaseInWhichItWasEnclosedItWasABe
  • 14. 14 Example 3- Vigenere “Multi-Caesar Cipher” – A statefull cipher Key: k = (k1,k2,…,km) list of m numbers between 0 and 25 Encryption: Breaking Vigenere: nth letter encoded w/ key=k(n mod m) : i  I + k(n mod m) (mod 26) (Belaso, 1553) LIVITCSWPIYVEWHEVSRIQMXLEYVEOIEWHRXEXIPFEM VEWHKV Step 1: Guess the length of the key m Step 2: Group together positions {1, m+1, 2m+1, 3m+1,…} {m-1, 2m+m-1, 3m+m-1,…} Decryption: In the natural way … {2, m+2, 2m+2, 3m+2,…}
  • 15. 15 Cryptography & Security Prev slides: Have provably secure algorithm for every crypto task imaginable. Q: How come nothing is secure? A2: Cryptography is only part of designing secure systems  Chain is only as strong as weakest link.  A “dormant bug” is often a security hole.  Security is hard to “modularize”  Human element (hard to add to existing system, changes in system features can have unexpected consequences)  Many subtle issues (e.g., caching & virtual memory, side channel attacks)  Key storage and protection issues.

Editor's Notes

  1. 1-32 to print, choose File-Page Setup-Landscape, View-Header and Footer, Print-Properties-Long Side and Color, and deselect Grayscale