Have a look at the BlobSplitter apex class by @MetaDaddy in the question Mimic MySQL AES_ENCRYPT in Apex. You can use EncodingUtil.convertToHex() to get a ... ... <看更多>
Encoding provides all you need to encrypt to base64 encoding and decrypt from base64 encoding. Convert string to base64. string txt = "Test"; ... ... <看更多>