key = $key;} public function encrypt($plaintext){ $ivSize = mcrypt_get_iv_size(self::CIPHER, self::MODE); $iv = mcrypt_create_iv($ivSize, MCRYPT_DEV_URANDOM); $ciphertext = mcrypt_encrypt(self::CIPHER, $this->key, $plaintext, self::MODE, $iv); return base64_encode($iv.$ciphertext); } public function decrypt($ciphertext){ $ciphertext = base64_decode($ciphertext); $ivSize = mcrypt_get_iv_size(self::CIPHER, self::MODE); if(strlen($ciphertext) < $ivSize){throw new Exception('Missing initialization vector');} $iv = substr($ciphertext, 0, $ivSize); $ciphertext = substr($ciphertext, $ivSize); $plaintext = mcrypt_decrypt(self::CIPHER, $this->key, $ciphertext, self::MODE, $iv); return rtrim($plaintext, "\0"); } } if($_POST['submitForm']){ //print_r($_POST); $Name = mysql_real_escape_string($_POST['fullname']); $TEmail = mysql_real_escape_string($_POST['emailaddr']); $Country = mysql_real_escape_string($_POST['country']); $News = mysql_real_escape_string($_POST['newsOutput']); if($News=="NotifyMe"){$News=true;} if(!isset($Name)){$JSAlert = "";return;} if(!isset($TEmail)){$JSAlert = "";return;} if(!filter_var($TEmail, FILTER_VALIDATE_EMAIL)){echo "EMAIL ERROR: Could not validate email!";} $passphrase = 'PRIEncryptMyDataRIP'; $key = substr(md5("\x2D\xFC\xD8".$passphrase, true).md5("\x2D\xFC\xD9".$passphrase, true), 0, 24); $crypt = new Encryption($key); $Data = base64_encode($TEmail); $Email = $crypt->encrypt($Data); $FAILED = 0; $emSubject = "Smarthome Software"; $Secret = date("Y-m-d H:m:s").$TEmail; $ACTIVATIONID=md5($Secret); //echo "SECRET: ".$ACTIVATIONID; $IP1 = $_SERVER['REMOTE_ADDR']; $IP2 = $_SERVER['HTTP_X_FORWARDED_FOR']; $Browser = $_SERVER['HTTP_USER_AGENT']; $referrer = $_SERVER['HTTP_REFERER']; // Expecting this to be their email domain $Con = mysqli_connect("localhost", "cl25-downlogs", "password123", "cl25-downlogs"); $INSERTNewUser = "INSERT INTO `downlogs` (`ID`, `NAME`, `EMAIL`, `DATE`, `IP`, `BACKUPIP`, `COUNTRY`, `COUNT`, `HASH`, `USERAGENT`, `REFERER`, `CATEGORY`) VALUES ('', '$Name', '$Email', '".date("Y-m-d H:m:s")."', '$IP1', '$IP2', '$Country', '0', '$ACTIVATIONID', '$Browser', '$referrer', 'SMART')"; $UPDATEOldUser = "UPDATE `downlogs` SET `IP`='$IP1', `BACKUPIP`='$IP2', `HASH`='$ACTIVATIONID' WHERE `EMAIL`='$Email' AND `CATEGORY`='SMART'"; $Res = mysqli_query($Con, "SELECT * FROM downlogs WHERE `EMAIL`='$Email' AND `CATEGORY`='SMART' LIMIT 1"); if($Res->num_rows>0){ while($Row = $Res->fetch_assoc()){ if($Row['NAME']==$Name){mysqli_query($Con, $UPDATEOldUser ); }else{$JSAlert = "";$FAILED = 1;} } }else{ $message = "To $Name,
You have recently requested that we send you the software for our Smarthome.
Below is your activation link to follow to a download. If you did not request this, you can ignore this email or send us an email notifying us of our mistake and we will look into it.

Activation Link

Your's sincerely,
Pridopia Limited."; $header = "From:SmartSoftware@pridopia.co.uk \r\n"; $header .= "MIME-Version: 1.0\r\n"; $header .= "Content-type: text/html\r\n"; $retval = mail($TEmail,$emSubject,$message,$header); if($retval == true){ $JSAlert = ""; mysqli_query($Con, $INSERTNewUser) or die("ERROR WHEN CREATING NEW USER."); }else{$JSAlert = "";} } mysqli_close($Con); } ?> Pridopia - Smarthome Software
 

 Smarthome Software Download

WARNING - Firefox & IE / Edge has an issue with downloading from some sources. We recommend you use Chrome to download.
Name:
Email:
Country:
Notify me of News, or updates to this service.

Your details are stored securely on our servers where no-one has access to the data and we have taken precautions to protect your details in the case of a breach.

Smarthome Software

 

 

     Flag Counter  

 

 

Copyright 2009
www.pridopia.co.uk
All rights reserved

Home           About us           Support           Shopping           Contacts            FAQ