In: Computer Science
Consider a Linear Feedback Shift Register (LFSR) of degree 8 and the feedback polynomial P(x) = x8 + x4 + x3 + x + 1 where the initialization vector has the value FF in hexadecimal.
a. What is the key for the encryption?
b. What is the period of the output stream?
c. Computer the first two output bytes.
Initial Value : FF = 1111 1111
Feedback Polynomial : x^8 + x^4 + x^3 + x + 1
Byte representation : 1000 1101
The key of encryption followed in LFSR is as follows :
LFSR is a shift register whose input bit is a linear function of
its previous state. Commonly used Linear function is the exclusive
OR (XOR) of the bits of previous state corresponding to the
feedback polynomial.
Period of the output stream : 2^n - 1 = 2^8 - 1 = 255
First Output byte will be the XOR of the 8th 4th 3rd and 1st bits
of initial vector fed again.
Therefore, 8th Bit XOR with 4th Bit : 1 XOR 1 = 0
above resullt XOR with 3rd Bit : 0 XOR 1 = 1
above result XOR with 1st Bit : 1 XOR 1 = 0
So, the first byte will be 1111 1110
HexaDecimal value : FE
For second Byte the initial vector considered will the First
Byte ie the previous state.
Steps followed :
8th Bit XOR 4th Bit : 1 XOR 1 = 0
above result XOR with 3rd Bit : 0 XOR 1 = 1
above result XOR with 1st bit : 1 XOR 0 = 1
Second Byte : 1111 1101
HexaDecimal Value : FD