Keyboard shortcuts

Press or to navigate between chapters

Press S or / to search in the book

Press ? to show this help

Press Esc to hide this help

Operations

addRoundKey :: RoundKey -> State -> State
addRoundKey rk s = generate $ \ i ->
                   generate $ \ j ->
                      lkup s (i , j) ^ lkup rk (i , j)             
subbytes :: State -> State
subbytes s = generate $ \ i ->
             generate $ \ j -> let xij = (s `index` i) `index` j in
                                 sbox xij