Can someone share a simple code that only checks the serial number. No name or anything else. And i want to have a php as well that i can insert the MD5 hash tags for security on my serial numbers along with it emailing me info. If you make a code i use HTTPS not HTTP. Would really appreciate it. If you want to take it a step further i would like it to add a counter to each installation that updates the php so i now if someone is abusing the installer.
Here is a code i have been trying. Includes everything i requested. But it only returns no match.
Here is a code i have been trying. Includes everything i requested. But it only returns no match.
Code:
-- Gets the username and serial from the text fields named UserName -- And UserSerial. sUsername = SessionVar.Expand("%UserName%"); sPassword = SessionVar.Expand("%UserSerial%"); -- Setup the data to be sent. (No md5 though) sCheckScriptURL = "https://www.flysimware.com/authenticate.php"; tValuesToPass = {reguser = sUsername, regserial = sPassword}; nSubmitMethod = SUBMITWEB_POST; nTimeout = 20; nPort = 80; tAuthData = nil; tProxyData = nil; -- Just some simple stuff to set up strProductName = SessionVar.Expand("%ProductName%"); -- Email address you want to receive the details on strEmailTo = "[email protected]"; -- Location of the mail script to send the details out. strURL = "https://www.flysimware.com/mail.php"; -- System Variable Values About The User Passed For The Email userinfo = System.GetUserInfo(); regowner = userinfo.RegOwner; netdetails = System.GetLANInfo(); nicaddress = netdetails.NIC; regorganization = userinfo.RegOrganization; driveserial = Drive.GetInformation(_SourceDrive).SerialNumber; time = System.GetTime(TIME_FMT_AMPM); current_time = System.GetTime(1); date = System.GetDate(DATE_FMT_EUROPE); current_date = System.GetDate(2); emailaddress = "strEmailTo"; -- Prepare the message to be sent local strMessage = ""; strMessage = strMessage.."Product: "..strProductName.."\r\n"; strMessage = strMessage.."Name: "..SessionVar.Expand("%UserName%").."\r\n"; strMessage = strMessage.."Serial: "..SessionVar.Expand("%UserSerial%").."\r\n"; strMessage = strMessage.."Info: "..regowner.."\r\n"; strMessage = strMessage.."Mac Address: "..nicaddress.."\r\n"; strMessage = strMessage.."Reg Organization: "..regorganization.."\r\n"; strMessage = strMessage.."Drive Serial: "..driveserial.."\r\n"; strMessage = strMessage.."Registration Time: "..current_time.."\r\n"; strMessage = strMessage.."Registration Date: "..current_date; local strSubject = "Registration for "..strProductName; local strFrom = emailaddress; local strTo = strEmailTo; -- Create the message data to be sent to the mail.php script: local tblValues = {MailTo=strTo,MailFrom=strFrom,MailSubject=strSubject,MailMessage=strMessage}; local nLastError = Application.GetLastError(); -- Show a dialog box while the persons details are being checked StatusDlg.Show(); StatusDlg.ShowProgressMeter(true); StatusDlg.SetTitle("Validating"); StatusDlg.SetStatusText("Please wait while your details are being checked with the server..."); -- Presto Send to the web and hide the activation dialog box sResult = HTTP.Submit(sCheckScriptURL, tValuesToPass, nSubmitMethod, nTimeout, nPort, tAuthData, tProxyData); local strResult = HTTP.Submit(strURL,tblValues,SUBMITWEB_POST); StatusDlg.Hide(); -- The details were correct. (the installer received a value of one) if sResult == "1" then -- The username and password was right Screen.Next(); else -- Those details provided were wrong. Or no longer in the database. Dialog.Message("ERROR", "Those details are invalid. Or they have been removed from the server", MB_OK, MB_ICONSTOP); end
Comment