2
$\begingroup$

I am taking an Internet Security Class and we received some practice problems and answers, but I do not know how to do these problems , an explanation would be greatly appreciated

Try to compute the following value:(the number is in hexadecimal and each represents a polynomial in GF(2^8)

1) {02} * {87}

answer:

{02} = {0000 0010} = x
{87} = {1000 0111} = x

-> {02} * {87} = (000 1110) XOR (0001 1011) = 0001 0101 = {15}

$\endgroup$
2
  • 1
    $\begingroup$ This question is impossible to answer unless you tell us the representation that you are using for $GF(2^8)$. What is your irreducible polynomial? (But your XOR operation is for addition, not multiplication. Also where do "000 1110" and "0001 1011" come from?) $\endgroup$
    – TonyK
    Mar 15, 2015 at 0:50
  • 2
    $\begingroup$ Oh, I see $-$ you get (correctly) "1 0000 1110" for the multiplication, and reduce it mod "1 0001 1011". So if that is your irreducible polynomial, your answer looks correct. $\endgroup$
    – TonyK
    Mar 15, 2015 at 0:52

1 Answer 1

8
$\begingroup$

To carry out the operation, we need to know the irreducible polynomial that is being used in this representation. By reverse-engineering the answer, I can see that the irreducible polynomial must be $x^8+x^4+x^3+x+1$ (Rijndael's finite field). To carry out a product of any two polynomials then, what you want to do is multiply them and then use the relation $x^8+x^4+x^3+x+1\equiv 0$, or in other words $x^8\equiv x^4+x^3+x+1$, to eliminate any terms $x^k$ where $k\geq 8$, reducing modulo 2 as you go along.

The binary {0000 0010} corresponds to the polynomial $x$ (i.e., $0x^7+0x^6+0x^5+0x^4+0x^3+0x^2+1x^1+0x^0$), while the binary {1000 0111} corresponds to $x^7+x^2+x+1$ (i.e., $1x^7+0x^6+0x^5+0x^4+0x^3+1x^2+1x^1+1x^0$). So to do the multiplication, we calculate

\begin{align*} x*(x^7+x^2+x+1) &= x^8 +x^3+x^2+x \\ &\equiv (x^4+x^3+x+1) + x^3+x^2+x \\ &= x^4+2x^3+x^2+2x+1 \\ &\equiv x^4+x^2+1 \end{align*} which is represented in binary as {0001 0101}.

$\endgroup$

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .