\AKEncryptionAES
AES implementation in PHP (c) Chris Veness 2005-2011 (http://www.movable-type.co.uk/scripts/aes-php.html) I offer these formulæ & scripts for free use and adaptation as my contribution to the open-source info-sphere from which I have received so much. You are welcome to re-use these scripts [under a simple attribution license or a GPL licence, without any warranty express or implied] provided solely that you retain my copyright notice and a link to this page.
licence. No warranty of any form is offered.
Modified for Akeeba Backup by Nicholas K. Dionysopoulos
Synopsis
class AKEncryptionAES
{
- // members
- protected $Sbox;
- protected $Rcon;
- protected $passwords;
- // methods
- protected static ciphertext Cipher()
- protected static void AddRoundKey()
- protected static void SubBytes()
- protected static void ShiftRows()
- protected static void MixColumns()
- protected static key KeyExpansion()
- protected static void SubWord()
- protected static void RotWord()
- protected static void urs()
- public static encrypted AESEncryptCtr()
- public static decrypted AESDecryptCtr()
- public static string AESDecryptCBC()
Members
protected
- $Rcon
- $Sbox
- $passwords
Methods
protected
- AddRoundKey()
- Cipher() — AES Cipher function: encrypt 'input' with Rijndael algorithm
- KeyExpansion() — Key expansion for Rijndael Cipher(): performs key expansion on cipher key to generate a key schedule
- MixColumns()
- RotWord()
- ShiftRows()
- SubBytes()
- SubWord()
- urs()
public
- AESDecryptCBC() — AES decryption in CBC mode. This is the standard mode (the CTR methods actually use Rijndael-128 in CTR mode, which - technically - isn't AES).
- AESDecryptCtr() — Decrypt a text encrypted by AES in counter mode of operation
- AESEncryptCtr() — Encrypt a text using AES encryption in Counter mode of operation - see http://csrc.nist.gov/publications/nistpubs/800-38a/sp800-38a.pdf