PHP和ColdFusion9中的AES加密产生了不同的结果.有人可以帮帮我吗?
以下PHP代码
$key = "12345678123456781234567812345678";
$iv = "1234567812345678";
$data = "This is a plain string.";
echo base64_encode(mcrypt_encrypt(MCRYPT_RIJNDAEL_128, $key, $data, MCRYPT_MODE_CBC, $iv));
Run Code Online (Sandbox Code Playgroud)
给我G + tdEOfQTtVCQGxW3N5uzkqN207OyfIPxS6zf2xrKKY =
而下面的ColdFusion代码
<cfset thePlainData = "This is a plain string." />
<cfset theKey = "12345678123456781234567812345678" />
<cfset theAlgorithm = "AES/CBC/PKCS5Padding" />
<cfset theEncoding = "base64" />
<cfset theIV = "1234567812345678" />
<cfset encryptedString = encrypt(thePlainData, theKey, theAlgorithm, theEncoding, theIV) />
Run Code Online (Sandbox Code Playgroud)
给我KLt55n5/T3ee6xVq9VGFbyCacJznkHEqC/RDRhL + 4nw =
知道我哪里错了吗?提前致谢.