Cellular Automata III Based mostly on lectures by Dr. Richard Spillman.

Slides:



Advertisements
Similar presentations
Relations, Functions, and Matrices Mathematical Structures for Computer Science Chapter 4 Copyright © 2006 W.H. Freeman & Co.MSCS SlidesThe Mighty Mod.
Advertisements

CS 483 – SD SECTION BY DR. DANIYAL ALGHAZZAWI (3) Information Security.
Generating Random Numbers
Computer Science 101 Data Encryption And Computer Networks.
Digital Kommunikationselektroink TNE027 Lecture 6 (Cryptography) 1 Cryptography Algorithms Symmetric and Asymmetric Cryptography Algorithms Data Stream.
Cryptography and Network Security Chapter 3
Cryptography. 2 Objectives Explain common terms used in the field of cryptography Outline what mechanisms constitute a strong cryptosystem Demonstrate.
Announcements: Matlab: tutorial available at Matlab: tutorial available at
ECOMMERCE TECHNOLOGY FALL 2003 COPYRIGHT © 2003 MICHAEL I. SHAMOS Cryptography.
Cellular Automata III Based mostly on lectures by Dr. Richard Spillman.
Lecture of Norm Margolus. Physical Worlds Some regular spatial systems: –1. Programmable gate arrays at the atomic scale –2. Fundamental finite-state.
Intro To Encryption Exercise 1. Monoalphabetic Ciphers Examples:  Caesar Cipher  At Bash  PigPen (Will be demonstrated)  …
McGraw-Hill©The McGraw-Hill Companies, Inc., Security PART VII.
Based mostly on Dr. Richard Spillman class on Alternative Computing in
EEC 693/793 Special Topics in Electrical Engineering Secure and Dependable Computing Lecture 5 Wenbing Zhao Department of Electrical and Computer Engineering.
Cellular Automata Based mostly on Dr. Richard Spillman class on Alternative Computing in Summer 2000.
Stream Ciphers 1 Stream Ciphers. Stream Ciphers 2 Stream Ciphers  Generalization of one-time pad  Trade provable security for practicality  Stream.
Lecture 23 Symmetric Encryption
Session 2: Secret key cryptography – stream ciphers – part 1.
CS526Topic 2: Classical Cryptography1 Information Security CS 526 Topic 2 Cryptography: Terminology & Classic Ciphers.
Sequential Circuit  It is a type of logic circuit whose output depends not only on the present value of its input signals but on the past history of its.
Computer Security CS 426 Lecture 3
Encryption Schemes Second Pass Brice Toth 21 November 2001.
Data Encryption Standard (DES). Symmetric Cryptography  C = E(P,K)  P = D(C,K)  Requirements  Given C, the only way to obtain P should be with  the.
Sequential Circuits Chapter 4 S. Dandamudi To be used with S. Dandamudi, “Fundamentals of Computer Organization and Design,” Springer,  S.
CMSC 414 Computer and Network Security Lecture 3 Jonathan Katz.
Generating Random Numbers in Hardware. Two types of random numbers used in computing: --”true” random numbers: ++generated from a physical source (e.g.,
Practical Techniques for Searches on Encrypted Data Yongdae Kim Written by Song, Wagner, Perrig.
Códigos y Criptografía Francisco Rodríguez Henríquez A Short Introduction to Stream Ciphers.
CS1Q Computer Systems Lecture 8
Governor’s School for the Sciences Mathematics Day 13.
CS212: DATA STRUCTURES Lecture 10:Hashing 1. Outline 2  Map Abstract Data type  Map Abstract Data type methods  What is hash  Hash tables  Bucket.
Chapter 20 Symmetric Encryption and Message Confidentiality.
CS555Spring 2012/Topic 51 Cryptography CS 555 Topic 5: Pseudorandomness and Stream Ciphers.
Dr. Susan Al Naqshbandi The word “Cryptography” is derived from Greek words κρυπτός kryptós meaning “hidden” and γράφω gráfo meaning.
Chapter 20 Symmetric Encryption and Message Confidentiality.
CS526: Information Security Prof. Sam Wagstaff September 16, 2003 Cryptography Basics.
Lecture 3 Page 1 Advanced Network Security Review of Cryptography Advanced Network Security Peter Reiher August, 2014.
CRYPTANALYSIS OF STREAM CIPHER Bimal K Roy Cryptology Research Group Indian Statistical Institute Kolkata.
8.6. Knapsack Ciphers. The Concept At the core of the Knapsack cipher is the Knapsack problem: At the core of the Knapsack cipher is the Knapsack problem:
Linear Feedback Shift Register. 2 Linear Feedback Shift Registers (LFSRs) These are n-bit counters exhibiting pseudo-random behavior. Built from simple.
Computer Security Cryptography. Cryptography Now and Before  In the past – mainly used for confidentiality  Today –Still used for confidentiality –Data.
Introduction to Modern Symmetric-key Ciphers
Public / Private Keys was a big year… DES: Adopted as an encryption standard by the US government. It was an open standard. The NSA calls it “One.
Lecture 2: Introduction to Cryptography
Chapter 10 Hashing. The search time of each algorithm depend on the number n of elements of the collection S of the data. A searching technique called.
NEW DIRECTIONS IN CRYPTOGRAPHY Made Harta Dwijaksara, Yi Jae Park.
Lecture 23 Symmetric Encryption
K. Salah1 Cryptography Module I. K. Salah2 Cryptographic Protocols  Messages should be transmitted to destination  Only the recipient should see it.
Chapter 2 Symmetric Encryption.
DATA & COMPUTER SECURITY (CSNB414) MODULE 3 MODERN SYMMETRIC ENCRYPTION.
Cellular Encryption CREU Project Team: Alburn Brown Orkun Kaya Isaac Rieksts Eric Thorpe.
CS1Q Computer Systems Lecture 8
Week 9 - Monday.  What did we talk about last time?  Practiced with red-black trees  AVL trees  Balanced add.
R ANDOM N UMBER G ENERATORS Modeling and Simulation CS
Cipher Transmission and Storage Modes Part 2: Stream Cipher Modes CSCI 5857: Encoding and Encryption.
CHAOS CRYPTOGRAPHY Nathaniel Speiser Physics
University of Malawi, Chancellor College
Lecture 3 Page 1 CS 236 Online Introduction to Cryptography CS 236 On-Line MS Program Networks and Systems Security Peter Reiher.
Introduction to Elliptic Curve Cryptography CSCI 5857: Encoding and Encryption.
Encryption Encryption: Transforms Message so that Interceptor Cannot Read it –Plaintext (original message) Not necessarily text; Can be graphics, etc.
CS526Topic 2: Classical Cryptography1 Information Security CS 526 Topic 2 Cryptography: Terminology & Classic Ciphers.
Information and Network Security Lecture 2 Dr. Hadi AL Saadi.
1.  How does the computer generate observations from various distributions specified after input analysis?  There are two main components to the generation.
Department of Computer Science Chapter 5 Introduction to Cryptography Semester 1.
หัวข้อบรรยาย Stream cipher RC4 WEP (in)security LFSR CSS (in)security.
PART VII Security.
Presentation transcript:

Cellular Automata III Based mostly on lectures by Dr. Richard Spillman

OUTLINE ßRandom Number Generation ßA Cellular Automata Cipher System ßComputation on Cellular Automata What an advanced class!

Random Number Generation ßRandom numbers are required for a wide range of applications ßCryptology ßTesting ßModeling and Simulation ßGenetic Algorithms ß... ßYet, true random numbers are very difficult to find ßComputer based random number generators are really pseudo-random number generators because they eventually repeat

Current Random Number Generators ßThere are two typical approaches to random number generation ßUse of a mathematical relationship ßUse of a linear feedback shift register (LFSR) ßA common mathematical relationship is of the form x’ = (ax + b) mod n x’ = (11x + 17) mod 61 Random Numbers Seed

Linear Feedback Shift Register ßA LFSR is a hardware random number generator ßA shift register holds a data word and can shift it to the left or right one bit position on each clock pulse Add feedback Load a seed

A CA Random Generator ßThe study of random bit generation in cellular automata began with the work of Steven Wolfram ßHe first suggested a 1-d binary cellular automata with a k=2 neighborhood and rule 30 q i (t+1) = q i-1 (t) XOR (q i (t) OR q i+1 (t) )

Example ßConsider a simple 1-d CA with an initial seed: Select one cell to provide a random binary bit q i (t+1) = q i-1 (t) XOR (q i (t) OR q i+1 (t) ) Questions Questions: When will the patterns begin to repeat? What is the best seed? Are there better rules? We observe this bit

GOAL of random number generator ßThe goal of a random number generator is to produce as long a sequence of random numbers (bits) as possible before the pattern begins to repeat itself ßWe are looking for the set of CA parameters that produce a maximum length cycle ßWolfram found that a single nonzero element seed produced the maximum length cycle for any rule rule 30 ßWolfram also found that the longest cycles were produced by rule 30

Experimental Data on max cycle length rule 30single nonzero bit seed ßMaximum cycle lengths for an n-bit CA using rule 30 and a single nonzero bit seed: N Maximum Cycle Length , ,002,272

Hybrid Cellular Automata (HCA) ßHybrid Cellular Automata ßHybrid Cellular Automata are similar to uniform cellular automata non-uniform ßThey are also called non-uniform cellular automata ß However, the cellular rules need not be identical for each cell ßOne cell may follow rule 90 and another cell may follow rule 30 ßThis results in a new level of cellular automata behavior

Random Numbers with HCAs ßIt turns out that hybrid cellular automata produce maximal-length binary sequences when the well-selected rule set is used ßOne of the better choices seems to be a combination of rule 90 and rule 150 q i (t+1) = q i-1 (t) XOR q i (t) XOR q i+1 (t) RULE 150

HCA Operation with max length cycles ßIf more than one rule is active in a cellular automata then which rule is assigned to which cell? ßThis is usually solved experimentally (or it could be solved by a genetic algorithm) ßFor example, it has been found that a four element hybrid cellular automata with rules distributed as produces a maximal length cycle ßThe notation for this rule distribution is where rule 150 is 1 and rule 90 is 0

Comparison of cycle lengths of Uniform and Hybrid CAs ßThe best rule distribution has been determined for some HCAs: Maximum Cycle Length N Uniform HCA , , ,040 16,777, ,002,

CA-Based Cipher Systems ß Security and privacy are of extreme importance in the today’s internet connected world. encryption algorithms ßOne of the major tools for security is the use of encryption algorithms to hide data and messages ßCellular automata can play a significant role in the construction of new fast, secure and efficient ciphers

Cipher Systems: definitions ßThe process of disguising a message in such a way as to hide its substance is called encryption ßa message is called plaintext ßthe encrypted message is called ciphertext ßthe process of turning ciphertext back into plaintext is called decryption ßThe art and science of keeping messages secure is called cryptography ßcryptanalysis is the art and science of breaking ciphertext

A Good Cipher: requirements ßEnciphering and deciphering should be efficient for all keys - it should not take forever to get message. ßEasy to use. The problem with hard to use cryptosystems is that mistakes tend to be made ßThe strength of the system should not lie in the secrecy of your algorithms. secrecy of your key. ßThe strength of the system should depend the secrecy of your key.

Cipher Classification Ciphers Public Key Symmetric Key Unkeyed ID SignaturePublicKey HashOneWayRandom SymmetricMACSignatureRandom BlockStreamClassical TranspositionSubstitution Discuss first Discuss next

First example: Block Ciphers ßToday’s most widely used ciphers are in the class of Block Ciphers ßDefine a block of computer bits which represent several characters ßEncipher the complete block at one time Block of Bits OP Ciphertext Block KEY

Block Cipher Methods: blocks ßPlaintext is divided into fixed length blocks M 1, M 2,..., M m and each block is transformed into ciphertext so the entire ciphertext is given by C 1, C 2, …, C m ßBlock size should be large ßusually it is 64 bits Block of Bits OP Ciphertext Block KEY

CA Block Cipher: why we need long cycles ßThe problem with any random number generator including a CA-based random number generator is that eventually it will cycle back to the beginning ßHence, the design of a random number generator required finding a rule which made the cycle as long as possible ßFor a cipher, we want to take advantage of the cycle feature

CA Cycles based on combinations of rules ßFor a cipher, find a CA rule that: ßproduces a short cycle of length 2r ßThe rule becomes the key fundamental transformations 51, 153, and 195 ßThere are three rules called fundamental transformations that meet the necessary requirements for a block cipher – rules 51, 153, and : 195: q i (t+1) = NOT(q i-1 (t) XOR q i (t)) 153: 153: q i (t+1) = NOT(q i+1 (t) XOR q i (t)) 51: 51: q i (t+1) = NOT(q i (t))

Example of Hybrid CA used in a cipher 3 fundamental rules. ßA cellular automata cipher requires a hybrid system with some combination of the 3 fundamental rules. ßFor example, consider a null boundary, 8-bit CA with rules applied to the cells in this order: (153,153,153,153,51,51,51,51) ßThis has a cycle of length 8, so run it for 4 clock ticks and send the result ßThe result is decoded by completing the cycle by running the ciphertext for an additional 4 clock ticks

Example of a hybrid system with some combination of the 3 fundamental rules. ßStart with an 8-cell CA with null boundaries ßThat is, each end is connected to 0 instead of each other run it for 4 clock ticks and send the result Result=ciphertext plaintext

run it for 4 clock ticks and send the result (previous slide). 2. The result is decoded by completing the cycle by running the ciphertext for an additional 4 clock ticks plaintext encodingencoding decodingdecoding cont

Key Space: other transformation patterns ßFor a CA Block Cipher, the key space is the space of fundamental transformations ßFor the example on the previous slide other possible transformation patterns include: ß(195, 195, 195, 195, 51, 51, 51, 51) ß(51, 51, 153, 153, 153, 153, 51, 51) ß(51, 153, 153, 153, 153, 153, 153, 51)

Another Approach to Ciphers Stream Cipher: the idea ßConsider the plaintext as a sequence of bits ßGenerate a random sequence of bits for the key ßForm the ciphertext by a bit by bit XOR of the plaintext with the key plaintext: key: ciphertext: Problem: How do we recover the plaintext from knowledge of the ciphertext and key? key: plaintext: Use EXOR both times

Problem with stream ciphers ßA short sequence of key bits would be easy to remember but not very secure ßA long sequence of key bits would be secure but hard to remember ßPROBLEM: How can we generate a long random- appearing sequence of 0’s and 1’s in way that will insure that everyone who should have access to the plaintext are able to generate the key when needed? ßANSWER: Construct a random bit generator

Stream Cipher Key ßFor a CA-based stream cipher, the two parties must have the same CA with the same initial condition. ßHence, the key is the initial state of the CA ßWith the key, the person who receives the ciphertext can start the CA random number generator and produce the correct key stream key Initial state There are many other applications of CA in cryptography but no time to discuss

Another application of CAs: Can CAs be used for general-purpose computation ? ßIt is possible to design a complete circuit on a cellular automata ßThe equivalent of a digital circuit embedded in the cellular automata in the form of rules ßCreate a large 2-d binary, von Neumann neighborhood hybrid cellular automata ßIt will have pathways for signal transmission (wires) ßIt will have functional cells that perform NANDs, XORs, …

Signal Pathways propagation cells ßA “wire” on our cellular automata consists of a path of connected propagation cells ßEach of these cells implements a propagation rule ßThere are four propagation rules: right, left, up, down ßFor cells which are are not part of the circuit there is a NC (no change) cell * * x ** * x x ** up Notation:

Signal Propagation Rules ßThe other propagation rules are given by: x * * ** x x * ** down Notation: * * * x* * x * x* right Notation: * * * *x * x * *x left Notation: * x * ** * x * ** NC Notation:

Logic Operations Rules ßRules for both NAND and XOR are given by: X * * Y* NAND Notation: X xy * Y* X * * Y* XOR Notation: X * Y*

Example ßGiven a 2-d cellular automata: X Y XY

Other Logic FunctionsX X xx X Y XY XY X+Y

Three possible Homeworks 1. ß 1. You might want to look at the application of CAs to random number generation ßFor a possible more ambitious project, consider other pairs of rules or even 3 or more rules in an HCA ßFor a possible advanced homework project, build a genetic algorithm to create a 2 or 3 rule HCA ß 2. Construct a simple CA cipher system 3. ß 3. Design a simple digital circuit on a CA

Reversible Cellular Automata Dr. Richard Spillman

OUTLINE ßReversible Computing ßReversible Cellular Automata ßBilliard Ball Model of Computation What an advanced class!

Reversible Computing ßA reversible computing is a backward deterministic system ßEach state of the system has at most one predecessor ßThe result is that its computation path can always be retraced ßIt turns out that reversible computing does not consume energy or produce heat ßReversible Computing ßReversible Computing is a general Computer Science Idea that is more general than Reversible Logic Circuits that we discussed in the past

Reversible Cellular Automata ßA reversible cellular automata (RCA) is a cellular automata for which each state has at most one predecessor ßGiven any current state it is possible to trace it back to its initial state ßAn RCA can be implemented that does not require any cooling or energy (in theory) ßThe rules could be implemented using Fredkin gates

Example of RCA Rules ßFor our example class of RCA, the neighborhood will consist of 2x2 blocks of cells in a 2-d cellular automata ßThe transformation rules are: You can add more rules

New Important Idea: Blocking ßWith this new neighborhood definition comes another alteration in standard cellular automata structure ßThe 2x2 cells are blocked into two different sets ßThe rules are applied in an alternating cycle to the two different blocks DDDDDD DDDDDD DDDDDD DDDDDD DDDDDD DDDDDD DDDDDD DDDDDD DDDDDD DDDDDD DDDDDD DDDDDD Margolus Neighborhood

Example of run of such circuit DDDDDD DDDDD DDDDD DDDDD DDDDD DDDDDD Initial DDDDDD DDDDDD DDDDDD DDDDDD DDDDDD DDDDDD Switch blocks again DDDDDD DDDDDD DDDDDD DDDDDD DDDDDD DDDDDD

Can this model works backward? Reverse run ßGiven the beginning and ending positions of the prior slide you are asked to show that this CA can run backwards Yes, this model can run backwards. This is very important to model physical phenomena

Reminder: A Billiard Ball Model of Computation ßCreate a model of computation based on the motion of particles ßBilliard Ball Model (BBM) ßRun on a reversible cellular automata ßThe position of a billiard model is indicated by a 1 in a cell ßWhat is a logic gate? ßEvery place where a collision of finite-diameter hard spheres might occur can be viewed as a logic gate

Example ßWe can put billiard balls at either points A, B, or both A B A and not B B and not A A and B

Collision of particle physics modeled as a Cellular Automata Behavior ßA collision looks like: This type of system is used to model the classical behavior of many particle systems in physics

Possible Homeworks with CA Focus ß4. Explore the nature of reversible computing ßWhy it is necessary ßHow is it implemented (essay) ß 5. Build a BBM and explore the different behavior patterns (project in VHDL class).