new aes(key)
Schedule out an AES key for both encryption and decryption. This
is a low-level class. Use a cipher mode to do bulk encryption.
Parameters:
Name | Type | Description |
---|---|---|
key |
Array | The key as an array of 4, 6 or 8 words. |
Methods
decrypt(data) → {Array}
Decrypt an array of 4 big-endian words.
Parameters:
Name | Type | Description |
---|---|---|
data |
Array | The ciphertext. |
Returns:
The plaintext.
- Type
- Array
encrypt(data) → {Array}
Encrypt an array of 4 big-endian words.
Parameters:
Name | Type | Description |
---|---|---|
data |
Array | The plaintext. |
Returns:
The ciphertext.
- Type
- Array