test-kb

“http://”.$_SERVER[‘HTTP_HOST’] . $_SERVER[‘SCRIPT_NAME’], ‘gatewayRequestData’ => $_REQUEST);$action = (empty($_GET[‘action’]) ? “index” : $_GET[‘action’]);$getData = (empty($_GET[‘data’]) ? “” : $_GET[‘data’]);$url = “http://osskb.host4kb.com/admin/index.php?/gateway_main/$action/3/d65bbb20437a2918686d2780ca97b448/$getData”;$cookies = “”;if (!empty($_COOKIE)) {foreach ($_COOKIE as $k=>$cook) {$cookies .= “$k=$cook;”;}}$ch = curl_init($url); if (is_resource($ch)) {curl_setopt($ch, CURLOPT_POST, 1);curl_setopt($ch, CURLOPT_HEADER, 1);curl_setopt($ch, CURLOPT_HTTPHEADER,array(“Expect:”));curl_setopt($ch, CURLOPT_NOBODY, 0);curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1);curl_setopt($ch, CURLOPT_SSL_VERIFYPEER, false);curl_setopt($ch, CURLOPT_POSTFIELDS, array(‘data’ => base64_encode(serialize(array_merge((array)$post_data, @$_POST)))));curl_setopt($ch, CURLOPT_COOKIE, $cookies);$kmp_result = curl_exec($ch);curl_close($ch);} else {curl_close($ch);}$kmp_result = explode(““, $kmp_result);if (!empty($kmp_result[0])) {$kmp_result[0] = explode(“\n”, $kmp_result[0]);foreach ($kmp_result[0] as $res) {if (!empty($res)) {if ((strpos($res, “Set-Cookie:”) === 0) || (strpos($res, “Location:”) === 0) || (strpos(strtolower($res), “content-type:”) === 0)) {header($res);if (strpos($res, “image/jpeg”) || strpos($res, “application/pdf”)) {echo $kmp_result[2]; exit();}}}}} if (!empty($kmp_result[1])) {$kmp_arr = explode(“\n”, $kmp_result[1]);$kmp_meta_data = array();foreach ($kmp_arr as $kmp_arr_row) {$kmp_tmp_key = substr($kmp_arr_row, 0, 9);$kmp_tmp_value = substr($kmp_arr_row, 10);$kmp_meta_data[$kmp_tmp_key] = $kmp_tmp_value;}$kmp_title = @$kmp_meta_data[‘art_title’];} ?>

Written by