KCML_AES_Encrypt

Purpose

AES encrypts plaintext into cyphertext$ using a 256 bit key.

Definition

DEFSUB 'KCML_AES_Encrypt(Key$, plaintext$, BYREF cyphertext$) AS Void

Parameters

KeyString containing the key.
plaintextString to encrypt.
cyphertextEncrypted result. This will be REDIMed to size of plaintext$ rounded up to a multiple of 16 bytes.

Description

AES encryption is a popular and secure algorithm that improves on DES. It has been adopted as a standard by the U.S. government. Trailing spaces are clipped from the plain text string unless surrounded by STR() or FLD(). The encryption is performed 16 bytes at a time so the encrypted string will be REDIMed to the next multiple of 16 above the effective length of the plain text string. AES is a symmetric cypher; see the complementary function 'KCML_AES_Decrypt(). For more information about AES see http://en.wikipedia.org/wiki/Advanced_Encryption_Standard.

See also

Internal KCML Functions, Internally defined structures and Internally defined enumerations and constants.