goog.crypt.Aes |
key
: !Array.<number>
The key as an array of integers in {0, 255}.
The key must have lengths of 16, 24, or 32 integers for 128-,
192-, or 256-bit encryption, respectively.
|
![]()
AES's AddRoundKey procedure. Add the current round key to the state.
Arguments:
|
code » | ||
![]()
Helper to copy input into the AES state matrix.
|
code » | ||
![]()
No description.
|
code » | ||
![]()
No description.
|
code » | ||
Helper to copy the state matrix into an output array.
|
code » | ||
![]()
AES's InvMixColumns procedure.
|
code » | ||
![]()
AES's InvShiftRows procedure. Shift the values in each row to the right.
|
code » | ||
![]()
AES's KeyExpansion procedure. Create the key schedule from the initial key.
|
code » | ||
![]()
AES's MixColumns procedure. Mix the columns of the state using magic.
|
code » | ||
AES's RotWord procedure.
|
code » | ||
![]()
AES's ShiftRows procedure. Shift the values in each row to the right. Each
row is shifted one more slot than the one above it.
|
code » | ||
![]()
AES's SubBytes procedure. Substitute bytes from the precomputed SBox lookup
into the state.
|
code » | ||
AES's SubWord procedure.
|
code » | ||
![]()
Tests can populate this with a callback, and that callback will get called
each round right after the AddRoundKey step gets executed encrypt().
|
code » | ||
![]()
Tests can populate this with a callback, and that callback will get called
each round right after the MixColumns step gets executed *but only in the
decrypt() function*.
|
code » | ||
![]()
Tests can populate this with a callback, and that callback will get called
each round right after the ShiftRows step gets executed *in both functions
encrypt() and decrypt()*.
|
code » | ||
![]()
Tests can populate this with a callback, and that callback will get called
each round right after the SubBytes step gets executed *in both functions
encrypt() and decrypt()*.
|
code » | ||
![]()
Tests can populate this with a callback, and that callback will get called
before each round on the round key. *Gets called in both the encrypt() and
decrypt() functions.*
|
code » | ||
![]()
Tests can populate this with a callback, and that callback will get called
at the start of each round *in both functions encrypt() and decrypt()*.
|
code » |
![]()
Key length, in words.
|
Code » | |
![]()
The key schedule.
|
Code » | |
![]()
The AES key.
|
Code » | |
![]()
Number of rounds. Based on key length per AES spec.
|
Code » | |
![]()
4x4 byte array containing the current state.
|
Code » | |
![]()
Scratch temporary array for calculation.
|
Code » |
![]()
Asserts that the key's array of integers is in the correct format.
|
code » |
![]()
Block size, in words. Fixed at 4 per AES spec.
|
Code » | |
![]()
No description.
|
Code » | |
![]()
Precomputed InvSBox lookup.
|
Code » | |
![]()
Precomputed lookup of multiplication by 2 in GF(2^8)
|
Code » | |
![]()
Precomputed lookup of multiplication by 3 in GF(2^8)
|
Code » | |
![]()
Precomputed lookup of multiplication by 9 in GF(2^8)
|
Code » | |
![]()
Precomputed lookup of multiplication by 11 in GF(2^8)
|
Code » | |
![]()
Precomputed lookup of multiplication by 13 in GF(2^8)
|
Code » | |
![]()
Precomputed lookup of multiplication by 14 in GF(2^8)
|
Code » | |
![]()
Precomputed RCon lookup.
|
Code » | |
![]()
Precomputed SBox lookup.
|
Code » |