<?php

include_once "WXBizDataCrypt.php";


$appid = 'wx4f4bc4dec97d474b';
$sessionKey = 'tiihtNczf5v6AKRyjwEUhQ==';

$encryptedData="cL+hFit+CDKmkRyJXO5fgFaNDzb0Af3WNPB/2MEYzy5cCjp/h5cWaTw3Fk7DoHTCOwK0VUfLE01Qa7MjjZ2PhoyqchgPbx2fILmJZEvmoa0pVQ5MQR2yMeKjSQg3lLo1z0Cb8WxCqKIVLoAytQmzH9OP0V4fEpF8J+J3mFDRO6zCJPUX4utwLQPNH76YO7tX9AaHp9mq3PVT9+m8g8V4yuLADy4Z1+fVF7rGz1cg1Z0TJYMIpVXVaGw5GHUzWAioQ0u7OceZtf9znOqRr/6qpgJ0Yl0evaIJv+uSpf/Xz4ZZla6s1VJO2YNVYo3Q/rlbemFXQ1UkQ8cxtmQhVDVD+pu5US3Silmsz8Amo251Qn+BJ+2IJcHlMJHIKMgucl3mamBnMu7Dxz5IARJ35qN3jAlkGrI4LVIGmjrigu9deyX9aKaQBqfolmTMbgdcpfzRIrRwO0mJVq/8Fy6769Odb8d8uANkDBvYlw3GG9Sh3Z90QWj//FUSzCURmgKFehpiels0DC03cvW4ldLeApswRw==";

$iv = "vpAlUp1xweY7CHOdCSOt9g==";

$pc = new WXBizDataCrypt($appid, $sessionKey);
$errCode = $pc->decryptData($encryptedData, $iv, $data );

if ($errCode == 0) {
    print($data . "\n");
} else {
    print($errCode . "\n");
}
