plas71k

betti1965 - FULL DECODED FILE

Dec 2nd, 2012
150
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
PHP 3.00 KB | None | 0 0
  1. <?php
  2. define("POPUP_DOM_PATH", dirname(dirname(__FILE__)) . "/");
  3. $cpath = POPUP_DOM_PATH . "install/";
  4. require_once POPUP_DOM_PATH . "popup-domination.php";
  5. $popdom    = new PopUp_Domination();
  6. $in = $popdom->in();
  7. if (count($_POST) > 0) {
  8.     $arr                  = array(
  9.         "receipt_key"
  10.     );
  11.     $errormsg     = "";
  12.     $show_form     = true;
  13.     $newarr = array();
  14.     foreach ($arr as $a) {
  15.         $val                                                  = trim($in[$a]);
  16.         $newarr[$a] = $val;
  17.     }
  18.     foreach ($newarr as $a => $b) {
  19.         ${$a} = $b;
  20.     }
  21.     $showform       = true;
  22.     $check = $install = $failed = false;
  23.     $key                 = $receipt_key;
  24.     if ($key == "PD2S0A1H2") {
  25.         $install   = true;
  26.         $showform    = false;
  27.         $code = $popdom->resetcode();
  28.         define("INSTALL_SESH_KEY", $code);
  29.         header("Location: step2.php?step=" . INSTALL_SESH_KEY);
  30.     } else {
  31.         $chkurl = "http://www.popupdomination.com/thanks-secure/check_receipt.php?receipt_key=" . urlencode(base64_encode($_POST["receipt_key"])) . "&url=" . urlencode(base64_encode($url)) . "&type=plugin";
  32.         if (function_exists("curl_init")) {
  33.             $ch = curl_init();
  34.             curl_setopt($ch, CURLOPT_USERAGENT, "Mozilla/5.0 (compatible; Konqueror/4.0; Microsoft Windows) KHTML/4.0.80 (like Gecko)");
  35.             curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1);
  36.             curl_setopt($ch, CURLOPT_URL, $chkurl);
  37.             curl_setopt($ch, CURLOPT_HTTPGET, 1);
  38.             curl_setopt($ch, CURLOPT_TIMEOUT, 60);
  39.             $resp = curl_exec($ch);
  40.             if (!$resp) {
  41.                 $response = @file_get_contents($chkurl);
  42.                 if (!$response) {
  43.                     $errormsg = "cURL Error: " . curl_error($ch);
  44.                 } else {
  45.                     $check = true;
  46.                 }
  47.             } else {
  48.                 $check = true;
  49.             }
  50.             curl_close($ch);
  51.         } else {
  52.             $response = @file_get_contents($chkurl);
  53.             if (!$response) {
  54.                 $errormsg = "Error: cURL is not installed on this server. file_get_contents failed.";
  55.             } else {
  56.                 $check = true;
  57.             }
  58.         }
  59.     }
  60.     if ($check) {
  61.         if (substr($resp, 0, 4) == "true") {
  62.             $showform                 = false;
  63.             $install = true;
  64.         } else {
  65.             $failed = true;
  66.         }
  67.     }
  68.     if ($failed) {
  69.         $errormsg = "You License key doesn't match our database, sorry about that! Don't worry, nothing has been installed on your site yet. Double check your receipt key send in your email recouped. If you continue to have trouble verifying your license key, try contacting our support desk.";
  70.     } else {
  71.         $code = $popdom->resetcode();
  72.         session_start();
  73.         $_SESSION["sesh_key"] = $code;
  74.         header("Location: step2.php?step=" . $code);
  75.     }
  76. }
  77. ?>
Add Comment
Please, Sign In to add comment