9
Page : 1 Cellular & Wireless Networks Technical University of Braunschweig IDA: Institute of Computer and Network Engineering Tutorial-5 Mobile Security Fundamentals-I Theory of Secret-Key Ciphers, Block Ciphers Fundamentals of Cellular and Wireless Networks Lecture ID: ET- IDA-113/114 20.05.2012 , v07 Prof. W. Adi

T05 Security Fund Block I v7

Embed Size (px)

DESCRIPTION

Ejercicios de seguridad móvil

Citation preview

crypto

Tutorial-5Mobile Security Fundamentals-ITheory of Secret-Key Ciphers, Block Ciphers

Fundamentals ofCellular and Wireless Networks

Lecture ID: ET- IDA-113/114

20.05.2012 , v07

Prof. W. Adibfolieq.drwPage : Nr. Cellular & Wireless NetworksTechnical University of BraunschweigIDA: Institute of Computer and Network EngineeringUnicity Distance nu

Where r is theclear text redundancyH(Z)= Key entropy, H(x)=Information entropy, N information length, K key lengthPlain Text Padding PTP: Random patternN BitsL Bits paddingClear text redundancy unuNNLn+=NLNrr+=

H(X)

Clear textandAfter PTP:

Shannon security theorem: Perfect Security condition is H (Z) H (X)New unicity distance:Summary of security fundamentalsbfolieq.drwPage : Nr. Cellular & Wireless NetworksTechnical University of BraunschweigIDA: Institute of Computer and Network EngineeringProblem 5-1: The following two mapping functions, F and transposition are to be used as a round operation in a block cipher.

Prove that the given function F is an involutionCompute the cipher text Y = R1, L1 for an input R=9, L=11 using two rounds with the keys K1=2, K2=3. Take n=4 bits.Decipher the cryptogram Y

LRKi+|*|n( )2|*| means that only the first n- LSB bits of the product are takennnnnFTranspositionsquaringbfolieq.drwPage : Nr. Cellular & Wireless NetworksTechnical University of BraunschweigIDA: Institute of Computer and Network EngineeringSolution 5-1:

1. Involution proof for function F

L+ R.K2RKL + R.K2 + R.K2RL=Same as input !F * F = 1 F=F-1=> F is an Involution+|*|n( )2|*|n means multiply and take as a result only thefirst n LSB bits of the productF+|*|n( )2FLRKInputbfolieq.drwPage : Nr. Cellular & Wireless NetworksTechnical University of BraunschweigIDA: Institute of Computer and Network EngineeringSolution 5-1:

2. Encryption11921011 + 0100 = 1111100131001 +0111=1110 1111+|*|4( )2+|*|4( )2|*|4 means multiply and take only the thefirst 4 LSB bits of the productn=4 bits36151357411111110Cryptogram Y = 1111 111049Clear text = (11 9 )decimal (1011 1001)binarybfolieq.drwPage : Nr. Cellular & Wireless NetworksTechnical University of BraunschweigIDA: Institute of Computer and Network EngineeringSolution 5-1:

3. Decryption141531110 + 0111 = 100111112+|*|4( )2+|*|4( )2|*|4 means multiply and take only the thefirst 4 LSB bits of the productn=4 bits135936471111 + 0100 = 1011 = 11 9Clear Text = 11 9941111 1110Cryptogram Y = 1111 1110bfolieq.drwPage : Nr. Cellular & Wireless NetworksTechnical University of BraunschweigIDA: Institute of Computer and Network EngineeringProblem 5-2:A cipher encrypting an information block of 250 bits. The entropy of the information source is 150 bits. The key length of the cipher is 64 bits.How many cryptogram (cipher text) bits are at least necessary for an attacker to observe, in order to be theoretically capable to break the cipher.

Solution 5-2:The minimum number of cipher text bits necessary to enable theoretically breaking the cipher is the unicity distance nu Where:

K is the cipher key length and r the clear text redundancyThe Information redundancy is :

= 250 150 / 250 = 0.40

The minimum number of cryptogram bits to break the cipher is nu = K/r = 64/0.4 = 160 bits

bfolieq.drwPage : Nr. Cellular & Wireless NetworksTechnical University of BraunschweigIDA: Institute of Computer and Network EngineeringProblem 5-3:A cipher having a key length of 80 bits is encrypting a clear text information block of length 800 bitshaving an information entropy of 300 bits.

Compute the unicity distance of the cipher.Find the new unicity distance if a random pattern of 1000 bits is appended to the information block.How much Is the change in the new channel data rate

Solution 5-3:1. The unicity distance can be found by substituting in the formula: , r is to be computed. = 800-300/800 = 0.625, = 80 / 0.625 = 128 bits

2. The new unicity distance nu = (800 +1000/800) 128 =288 bits

3. 800 useful data bits and 1000 non-useful random bits are appended to enhance security however, these additional random bits include no transmitted information. percentage of useful data is = 800 / (800 + 1000) = 44% thus the channel data rate is reduced by 100% -44% = 56%

unuNNLn+=

bfolieq.drwPage : Nr. Cellular & Wireless NetworksTechnical University of BraunschweigIDA: Institute of Computer and Network EngineeringProblem 5-4:A cipher is to be designed with a unicity distance of 2500 bits.

Compute the key length required for the cipher if the encrypted clear text block length is 1000 bits and clear text entropy is 500 bits.Find the required data compression to reduce the key length by 20% without reducing the system security (unicity distance).The unicity distance is to be increased to 3000 bits, how many random bits are to be padded to the information block to achieve the new unicity distance

Solution 5-4:1. The key length can be found by substituting in the relation: Where: nu=2500

and = 1000-500/1000 = 0.5, 2500 = K/0.5 => K = 1250 bits

2. To reduce the key length by 20%= 1250 x 0.2 = 250 bits to become 1000 bits, and still keep the unicity distance unchanged =2500, the new redundancy is r = K/nu= 1000/2500 = 0.4 to find the new data length, substitute in the redundancy formula 0.4 =(N-500)/N => N=833 bits (data compressed to 833 bits)

3. 3000 = [(L + 833)/833] 2500 => L=167 random bits are to be appended to 833

unuNNLn+=

bfolieq.drwPage : Nr. Cellular & Wireless NetworksTechnical University of BraunschweigIDA: Institute of Computer and Network Engineering