220 likes | 304 Views
Lecture 6 Overview. The minimum requirements. A symmetric-key cryptosystem A block cipher Capable of supporting a block size of 128 bits Capable of supporting key length of 128, 192, and 256 bits Available on a worldwide, non-exclusive, royalty-free basis. Criteria for Evaluation. Security
E N D
The minimum requirements • A symmetric-key cryptosystem • A block cipher • Capable of supporting a block size of 128 bits • Capable of supporting key length of 128, 192, and 256 bits • Available on a worldwide, non-exclusive, royalty-free basis CS 450/650 Lecture 6: AES
Criteria for Evaluation • Security • Soundness of the mathematical basis for an algorithm’s claimed strength • Research community search for flaws • Computational Efficiency • Memory Requirements • Flexibility • Simplicity CS 450/650 Lecture 6: AES
Advanced Encryption Standard • 10, 12, 14 rounds for 128, 192, 256 bit keys • Regular Rounds (9, 11, 13) • Final Round is different (10th, 12th, 14th) • Each regular round consists of 4 steps • Byte substitution (BSB) • Shift row (SR) • Mix column (MC) • Add Round key (ARK) CS 450/650 Lecture 6: AES
AES Overview Plaintext (128) ARK Subkey0 9 rounds BSB SR Ciphertext (128) ARK Subkey10 CS 450/650 Lecture 6: AES
Round i operations 128-bit substitution boxes confusion transposition step of circular shift confusion Left shift and XOR of bits diffusion and confusion portion of key is XORed confusion Subkeyi CS 450/650 Lecture 6: AES
Shift Row (128-bit) CS 450/650 Lecture 6: AES
Mix Column = * Multiplying by 1 no change Multiplying by 2 shift left one bit Multiplying by 3 shift left one bit and XOR with original value More than 8 bits 100011011 is subtracted CS 450/650 Lecture 6: AES
Add Key = b’x bx kx XOR CS 450/650 Lecture 6: AES
4 bytes 4 bytes 4 bytes 4 bytes 4 bytes 4 bytes 4 bytes 4 bytes Key Generation Circular left shift 1byte S-box XOR XOR Round constant XOR XOR CS 450/650 Lecture 6: AES
DES vs AES CS 450/650 Lecture 6: AES
Lecture 8 Algorithm Background CS 450/650 Fundamentals of Integrated Computer Security Slides are modified from Hesham El-Rewini
Analysis of Algorithms • Algorithms • Time Complexity • Space Complexity • An algorithm whose time complexity is bounded by a polynomial is called a polynomial-time algorithm. • An algorithm is considered to be efficient if it runs in polynomial time. CS 450/650 Lecture 8: Algorithm Background
Time and Space • Should be calculated as function of problem size (n) • Sorting an array of size n, • Searching a list of size n, • Multiplication of two matrices of size n by n • T(n) = function of n (time) • S(n) = function of n (space) CS 450/650 Lecture 8: Algorithm Background
Growth Rate • We Compare functions by comparing their relative rates of growth. 1000n vs. n2 CS 450/650 Lecture 8: Algorithm Background
Definitions • T(n) = O(f(n)): T is bounded above by f The growth rate of T(n) <= growth rate of f(n) • T(n) = W (g(n)): T is bounded below by g The growth rate of T(n) >= growth rate of g(n) • T(n) = Q(h(n)): T is bounded both above and below by h The growth rate of T(n) = growth rate of h(n) • T(n) = o(p(n)): T is dominated by p The growth rate of T(n) < growth rate of p(n) CS 450/650 Lecture 8: Algorithm Background
Time Complexity • C • O(n) • O(log n) • O(nlogn) • O(n2) • … • O(nk) • O(2n) • O(kn) • O(nn) Polynomial O(2log n) Exponential CS 450/650 Lecture 8: Algorithm Background
P, NP, NP-hard, NP-complete • A problem belongs to the class P if the problem can be solved by a polynomial-time algorithm • A problem belongs to the class NP if the correctness of the problem’s solution can be verified by a polynomial-time algorithm • A problem is NP-hard if it is as hard as any problem in NP • Existence of a polynomial-time algorithm for an NP-hard problem implies the existence of polynomial solutions for every problem in NP • NP-complete problems are the NP-hard problems that are also in NP CS 450/650 Lecture 8: Algorithm Background
Relationships between different classes NP NP-hard NP-complete P CS 450/650 Lecture 8: Algorithm Background
Partitioning Problem Given a set of n integers, partition the integers into two subsets such that the difference between the sum of the elements in the two subsets is minimum 13, 37, 42, 59, 86, 100 CS 450/650 Lecture 8: Algorithm Background
Bin Packing Problem • Suppose you are given n items of sizes s1, s2,..., sn • All sizes satisfy 0 si 1 • The problem is to pack these items in the fewest number of bins, • given that each bin has unit capacity CS 450/650 Lecture 8: Algorithm Background
Bin Packing Problem Example (Optimal; Solution) for 7 items of sizes: 0.2, 0.5, 0.4, 0.7, 0.1, 0.3, 0.8. CS 450/650 Lecture 8: Algorithm Background