Using Default Login.
\n"; } if (!empty($_REQUEST['action']) && $_REQUEST['action'] == 'FORM') $continue_up = true; else { echo "\n"; echo "\n"; echo "\n"; echo "
 Email* 
 Password* 

*You can set it as default in ".basename(__FILE__)."
\n\n"; } if ($continue_up) { $not_done = false; $referer = 'http://uploading.com/'; $captcha = (isset($_REQUEST['step']) && $_REQUEST['step'] == 'captcha') ? true : false; // Login echo "\n
\n
Login to uploading.com
\n"; $cookie = array(); if (!empty($_REQUEST['up_login']) && !empty($_REQUEST['up_pass'])) { if ($captcha && empty($_POST['recaptcha_response_field'])) html_error("You didn't enter the image verification code."); $page = geturl('uploading.com', 80, '/', '', $cookie, 0, 0, $_GET['proxy'], $pauth);is_page($page); $cookie = GetCookiesArr($page, $cookie); if (empty($cookie['SID'])) html_error('Login Error: SID cookie not found.'); $post = array(); $post['email'] = $_REQUEST['up_login']; $post['password'] = $_REQUEST['up_pass']; $post['remember'] = 'on'; if ($captcha) { $post['recaptcha_challenge_field'] = $_POST['recaptcha_challenge_field']; $post['recaptcha_response_field'] = $_POST['recaptcha_response_field']; } $ajax_req = geturl('uploading.com', 80, '/general/login_form/?ajax', $referer."\r\nX-Requested-With: XMLHttpRequest", $cookie, $post, 0, $_GET['proxy'], $pauth);is_page($ajax_req); $json = Get_Reply($ajax_req); if (!empty($json['error'])) html_error('Login Error... MSG: ' . $json['error']); if (!empty($json['answer']) && isset($json['answer']['captcha']) && $json['answer']['captcha'] == true) { $data = array('action' => 'FORM', 'step' => 'captcha'); if (!preg_match('@build_recaptcha\s*\([^,|\)]+,\s*[\'|\"](\w+)[\'|\"]\s*\)@i', $page, $pid)) html_error('Error: Login captcha data not found.'); Show_reCaptcha($pid[1], $data, ($upload_acc['uploading_com']['user'] && $upload_acc['uploading_com']['pass'])); exit; } $cookie = GetCookiesArr($ajax_req, $cookie); if (empty($cookie['u']) || empty($cookie['remembered_user'])) html_error('Login Error: Login cookies not found.'); // Yes.... u=1 is needed. :D } else html_error("Login Failed: Email or Password are empty. Please check login data.", 0); // Retrive upload ID echo "\n
Retrive upload ID
\n"; $page = geturl('uploading.com', 80, '/', $referer, $cookie, 0, 0, $_GET['proxy'], $pauth);is_page($page); if (!preg_match('@upload_url[\s|\t]*:[\s|\t|\r|\n]*[\'|\"](https?://([^\|\'|\"|\r|\n|\s|\t]+\.)?uploading\.com/[^\'|\"|\r|\n|\s|\t]+)@i', $page, $up)) html_error('Error: Cannot find upload server.', 0); $post = array('name' => urlencode($lname), 'size' => getSize($lfile)); $page = geturl('uploading.com', 80, '/files/generate/?ajax', $referer."\r\nX-Requested-With: XMLHttpRequest", $cookie, $post, 0, $_GET['proxy'], $pauth);is_page($page); $json = Get_Reply($page); if (empty($json['file']['file_id'])) html_error('Upload id not found.'); if (empty($json['file']['link'])) html_error('Download link not found. Upload aborted.'); $post = array(); $post['Filename'] = $lname; $post['folder_id'] = 0; $post['file'] = $json['file']['file_id']; $post['SID'] = $cookie['SID']; $post['Upload'] = 'Submit Query'; $up_url = $up[1]; // Uploading echo "\n"; $url = parse_url($up_url); $upfiles = upfile($url['host'], 80, $url['path'].($url['query'] ? '?'.$url['query'] : ''), $referer, $cookie, $post, $lfile, $lname, 'file', '', $_GET['proxy'], $pauth, 'Shockwave Flash'); // Upload Finished echo "\n"; is_page($upfiles); $download_link = $json['file']['link']; } function Get_Reply($page) { if (!function_exists('json_decode')) html_error('Error: Please enable JSON in php.'); $json = substr($page, strpos($page, "\r\n\r\n") + 4); $json = substr($json, strpos($json, '{'));$json = substr($json, 0, strrpos($json, '}') + 1); $rply = json_decode($json, true); if (!$rply || (is_array($rply) && count($rply) == 0)) html_error('Error getting json data.'); return $rply; } // Edited For upload.php usage. function Show_reCaptcha($pid, $inputs, $default_login) { if (!is_array($inputs)) html_error("Error parsing captcha data."); // Themes: 'red', 'white', 'blackglass', 'clean' echo "\n"; echo "\n

\n"; foreach ($inputs as $name => $input) echo "\n"; if (!$default_login) echo "\t\n\t\t\n\t\t\n\t
 Email 
 Password 


"; echo ""; echo "
"; echo "\n"; echo "\n"; echo "
\n\n"; exit; } //[14-7-2012] Written by Th3-822. ?>