How is the AddRoundKey operation performed in AES-256? Can anyone explain to me (or send a link to somewhere) how round keys are added in AES-256? I understand that the round keys is added to the state matrix for each round and how XOR works. But since the state matrix is always 128 bits, how do you add an 256 bit round key?

I might be confused on a higher level right now...
how do you add an 256 bit round key?


Actually, each round key is 128 bits, and so XORing them into the state matrix is easy.

What the AES key expansion process does is take the 256 bit AES key, and generate 15 round keys (one more than the number of AES rounds).  Now, for AES256, the first two round keys are, in fact, 256 bits taken directly from the AES key.  After that, it computed the next round key based on a simple function of the previous two round keys (plus a per round constant).