implementing aes mysql compatible