@ 2015-11-09T03:36:43Z <?php
$sSecretKey = 'TrueID2015tRUEid';
$json = json_encode({
"trueid": "0864073341",
"ssoid": "19041211",
"access_token": "171|1.c31e0e8fe71d8215f1ff95__3600.1442364865- 19041211|7c938d42413cbdcf23500388375",
"thaiid": "5101599032198",
"channel": "trueid",
"paytype": "credit",
"total": "1010.87",
"lang": "th",
"payment": {
"count": "2", "invoicelist": [
{
"invoice_number": "0001392172791881","invoice_amount": "320.47", "amount": "320.47", "company_code": "RM", "service_number": "0864073341", "ban_number": "16652487", "due_date": "18/10/2015", "bill_month": "102015"
}, {"invoice_number": "000139217279xxxx", "invoice_amount": "660.93",
"amount": "660.93",
"company_code": "AC", "service_number": "NF0095630I", "ban_number": "150024746305", "due_date": "20/10/2015", "bill_month": "102015"} ]
} });
$encrypt = fnEncrypt($json, $sSecretKey);
function fnEncrypt($sValue, $sSecretKey) {
$iv = base64_decode('Jc8EZ9nZPbWZEoV4ad8/CQ==');
$sValue = pkcs5_pad($sValue, mcrypt_get_block_size(MCRYPT_RIJNDAEL_128, MCRYPT_MODE_CBC));
$sValue = mcrypt_encrypt(MCRYPT_RIJNDAEL_128, $sSecretKey, $sValue, MCRYPT_MODE_CBC, $iv);
$sValue = base64_encode($sValue);
return $sValue; }
function pkcs5_pad($text, $blocksize) {
$pad = $blocksize - (strlen($text) % $blocksize); $pad2 = $text . str_repeat(chr($pad), $pad); return $pad2;
}
Enable javascript to submit You have javascript disabled. You will not be able to edit any code.
Here you find the average performance (time & memory) of each version. A grayed out version indicates it didn't complete successfully (based on exit-code).
Version System time (s) User time (s) Memory (MiB) 5.6.15 0.007 0.080 18.19 5.6.14 0.010 0.043 18.22 5.6.13 0.007 0.037 18.28 5.6.12 0.020 0.073 21.14 5.6.11 0.013 0.030 21.13 5.6.10 0.013 0.080 21.08 5.6.9 0.010 0.077 20.97 5.6.8 0.003 0.070 20.38 5.5.30 0.007 0.043 18.02 5.5.29 0.000 0.090 17.95 5.5.28 0.003 0.070 20.95 5.5.27 0.023 0.033 20.66 5.5.26 0.010 0.063 20.79 5.5.25 0.003 0.040 20.59 5.5.24 0.017 0.077 20.25
preferences:dark mode live preview
141.81 ms | 1394 KiB | 7 Q