Encryption and Compression

ENCRYPT(str[,salt]) encrypts str using the Unix crypt() system call. If salt is not provided, a random value is used.

AES_ENCRYPT(str, key [, init_vector]) encrypts str with key using the AES algorithm.
AES_DECRYPT (str, key [, init_vector]) decrypts str with key using the AES algorithm.
DES_ENCRYPT(str, key [, init_vector]) encrypts str with key using the Triple-DES algorithm.
DES_DECRYPT(str, key [, init_vector])
decrypts str with key using the Triple-DES algorithm.SHA1(str) and SHA(str) calculates an SHA-1 160-bit checksum for str and returns a string of 40 hex digits.
SHA2(str, hash_length) calculates the SHA-2 family of hash functions (SHA-224, SHA-256, SHA-384, SHA-512). The second argument must have a value of 224, 256, 384, 512, or 0(256).
MD5(str)
calculates an MD5 128-bit checksum for str, and returns a string of 32 hex digits.

PASSWORD(str) returns a hashed password string calculated from str, and returns a nonbinary string in the connection character set.
VALIDATE_ PASSWORD_STRENGTH(str)
returns an integer in the range 0(weak) to 100(strong) indicating the strength of the password str.

COMPRESS(str) returns a compressed version of str as a binary string.
UNCOMPRES(str) returns an uncompressed version of a string str compressed by COMPRESS(str).
UNCOMPRESSERD_LENGTH(str) returns the length of str before compression.

RANOM_BYTES(len) returns a binary string of len random bytes.