ENCRYPT
Syntax
ENCRYPT(str[,salt])
Description
ENCRYPT() uses the Unix crypt() call to encrypt str and returns a binary string. The salt parameter must be a string of at least two characters; otherwise, the result is NULL. If you do not specify the salt parameter, a random value is used.
Because the system call requires a null-terminated string, do not pass a string that contains a null byte to ENCRYPT().
If the system does not support crypt(), ENCRYPT() always returns NULL.
Examples
SELECT ENCRYPT('hello');
+------------------+
| ENCRYPT('hello') |
+------------------+
| XROflfjMAx1GA |
+------------------+
1 row in set (0.001 sec)