AES_DECRYPT

2023-08-01 06:02:28  Updated

Syntax

AES_DECRYPT(crypt_str,key_str[,init_vector])

Purpose

AES_DECRYPT() returns the plaintext of the crypt_str ciphertext that is decrypted by using the key_str key and the Advanced Encryption Standard (AES) algorithm.

For more information about the init_vector argument, see AES_ENCRYPT.

Examples

obclient> SELECT AES_DECRYPT(AES_ENCRYPT('oceanbase',UNHEX('F3229A0B371ED2D9441B830D21A390C3')),UNHEX('F3229A0B371ED2D9441B830D21A390C3'));
+---------------------------------------------------------------------------------------------------------------------------+
| AES_DECRYPT(AES_ENCRYPT('oceanbase',UNHEX('F3229A0B371ED2D9441B830D21A390C3')),UNHEX('F3229A0B371ED2D9441B830D21A390C3')) |
+---------------------------------------------------------------------------------------------------------------------------+
| oceanbase                                                                                                                 |
+---------------------------------------------------------------------------------------------------------------------------+
1 row in set

Contact Us