-- 创建测试表
drop table if EXISTS t_passwd_2;create table t_passwd_2(pass1 varchar(64));-- 对身份证号加密insert into t_passwd_2 values (hex(aes_encrypt('22230119771011001X', 'dsideal4r5t6y7u!@#')));-- 数据库中存储的样子select * from t_passwd_2;-- 解密select aes_decrypt(unhex(pass1), 'dsideal4r5t6y7u!@#') as pass1 from t_passwd_2;