Advertisement
Guest User

Untitled

a guest
Nov 30th, 2014
769
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Lua 5.31 KB | None | 0 0
  1. local this="Dialog1";--@@Dialog1 -> On Show
  2.  
  3.  
  4.  
  5. File.Delete(_TempFolder.."\\idtemp.dat", false, false, false, nil);
  6.  
  7.  
  8.  
  9.  
  10.  
  11. --StatusDlg.Show(MB_ICONNONE, false);
  12.  
  13. --StatusDlg.SetTitle("iDezender Licenser");
  14.  
  15. --StatusDlg.SetMessage("Connecting iDezender server...");
  16.  
  17. --StatusDlg.SetMeterRange(0, 100);
  18.  
  19. --StatusDlg.SetMeterPos(15);
  20.  
  21.  
  22.  
  23. Progress.StepIt("Progress1");
  24.  
  25.  
  26.  
  27.  
  28.  
  29. IsConnected = HTTP.TestConnection("http://www.google.com/", 40, 80, nil, nil);
  30.  
  31.  
  32.  
  33. if (IsConnected == false) then
  34.  
  35. Dialog.Message("iDezender", "There was an error...\r\n\r\n1. You are not connected to the internet.\r\n2. Motionite servers are offline.", MB_OK, MB_ICONSTOP, MB_DEFBUTTON1);
  36.  
  37. DialogEx.Close(0);
  38.  
  39. Application.Exit(0);
  40.  
  41. end
  42.  
  43.  
  44.  
  45. Progress.StepIt("Progress1");
  46.  
  47.  
  48.  
  49.  
  50.  
  51. regKey = Registry.GetValue(HKEY_LOCAL_MACHINE, "Software\\iDezender", "LC", true);
  52.  
  53.  
  54.  
  55. Progress.StepIt("Progress1");
  56.  
  57. HardwareID = Crypto.MD5DigestFromString(WMI.GetSerial("C:"));
  58.  
  59.  
  60.  
  61. Progress.StepIt("Progress1");
  62.  
  63. Progress.StepIt("Progress1");
  64.  
  65.  
  66.  
  67. Application.Sleep(1500)
  68.  
  69. Progress.StepIt("Progress1");
  70.  
  71. Progress.StepIt("Progress1");
  72.  
  73.  
  74.  
  75. --licensekey = "TEST-e95fdbf442d82783402615f03bc027";
  76.  
  77.  
  78.  
  79. --result = Dialog.Message("Notice", HardwareID, MB_OK, MB_ICONINFORMATION, MB_DEFBUTTON1);
  80.  
  81.  
  82.  
  83.  
  84.  
  85. GetStatus = HTTP.SubmitSecure("https://motionite.com/licensing/idezender.php", {licensekey=regKey,hardwareid=HardwareID}, SUBMITWEB_POST, 20, 443, nil, nil);
  86.  
  87.  
  88.  
  89. Progress.StepIt("Progress1");
  90.  
  91. Progress.StepIt("Progress1");
  92.  
  93. Progress.StepIt("Progress1");
  94.  
  95.  
  96.  
  97. if GetStatus == "suspended" then
  98.  
  99. Dialog.Message("iDezender", "Your license is suspended, please contact us.", MB_OK, MB_ICONSTOP, MB_DEFBUTTON1);
  100.  
  101.  
  102.  
  103.  
  104.  
  105. getKey = Dialog.Input("iDezender", "Paste your new license key here:", "", MB_ICONQUESTION);
  106.  
  107. if getKey == "" then
  108.  
  109. Dialog.Message("iDezender", "You did not enter something, iDezender will exit now...", MB_OK, MB_ICONEXCLAMATION, MB_DEFBUTTON1);
  110.  
  111. DialogEx.Close(0);
  112.  
  113. Application.Exit();
  114.  
  115. elseif getKey ~= "CANCEL" then
  116.  
  117. Registry.CreateKey(HKEY_LOCAL_MACHINE, "Software\\iDezender");
  118.  
  119. Registry.SetValue(HKEY_LOCAL_MACHINE, "Software\\iDezender", "LC", getKey, REG_SZ);
  120.  
  121. Dialog.Message("iDezender", "The license key has been entered, iDezender will now exit. After exit please run iDezender to finalize the validation.", MB_OK, MB_ICONINFORMATION, MB_DEFBUTTON1);
  122.  
  123. DialogEx.Close(0);
  124.  
  125. Application.Exit();
  126.  
  127. elseif getKey == "CANCEL" then
  128.  
  129. DialogEx.Close(0);
  130.  
  131. Application.Exit();
  132.  
  133. end
  134.  
  135.  
  136.  
  137.  
  138.  
  139. result = DialogEx.Close(0);
  140.  
  141. Application.Exit(0);
  142.  
  143. elseif GetStatus == "invalid" then
  144.  
  145. Dialog.Message("iDezender", "Your license is invalid, you either entered the wrong license key or your machine ID has changed.", MB_OK, MB_ICONSTOP, MB_DEFBUTTON1);
  146.  
  147.  
  148.  
  149. getKey = Dialog.Input("iDezender", "Paste your new license key here:", "", MB_ICONQUESTION);
  150.  
  151. if getKey == "" then
  152.  
  153. Dialog.Message("iDezender", "You did not enter something, iDezender will exit now...", MB_OK, MB_ICONEXCLAMATION, MB_DEFBUTTON1);
  154.  
  155. DialogEx.Close(0);
  156.  
  157. Application.Exit();
  158.  
  159. elseif getKey ~= "CANCEL" then
  160.  
  161. Registry.CreateKey(HKEY_LOCAL_MACHINE, "Software\\iDezender");
  162.  
  163. Registry.SetValue(HKEY_LOCAL_MACHINE, "Software\\iDezender", "LC", getKey, REG_SZ);
  164.  
  165. Dialog.Message("iDezender", "The license key has been entered, iDezender will now exit. After exit please run iDezender to finalize the validation.", MB_OK, MB_ICONINFORMATION, MB_DEFBUTTON1);
  166.  
  167. DialogEx.Close(0);
  168.  
  169. Application.Exit();
  170.  
  171. elseif getKey == "CANCEL" then
  172.  
  173. DialogEx.Close(0);
  174.  
  175. Application.Exit();
  176.  
  177. end
  178.  
  179.  
  180.  
  181. result = DialogEx.Close(0);
  182.  
  183. Application.Exit(0);
  184.  
  185. elseif GetStatus == "expired" then
  186.  
  187. Dialog.Message("iDezender", "Your license has been expired.", MB_OK, MB_ICONSTOP, MB_DEFBUTTON1);
  188.  
  189.  
  190.  
  191. getKey = Dialog.Input("iDezender", "Paste your new license key here:", "", MB_ICONQUESTION);
  192.  
  193. if getKey == "" then
  194.  
  195. Dialog.Message("iDezender", "You did not enter something, iDezender will exit now...", MB_OK, MB_ICONEXCLAMATION, MB_DEFBUTTON1);
  196.  
  197. DialogEx.Close(0);
  198.  
  199. Application.Exit();
  200.  
  201. elseif getKey ~= "CANCEL" then
  202.  
  203. Registry.CreateKey(HKEY_LOCAL_MACHINE, "Software\\iDezender");
  204.  
  205. Registry.SetValue(HKEY_LOCAL_MACHINE, "Software\\iDezender", "LC", getKey, REG_SZ);
  206.  
  207. Dialog.Message("iDezender", "The license key has been entered, iDezender will now exit. After exit please run iDezender to finalize the validation.", MB_OK, MB_ICONINFORMATION, MB_DEFBUTTON1);
  208.  
  209. DialogEx.Close(0);
  210.  
  211. Application.Exit();
  212.  
  213. elseif getKey == "CANCEL" then
  214.  
  215. DialogEx.Close(0);
  216.  
  217. Application.Exit();
  218.  
  219. end
  220.  
  221.  
  222.  
  223. result = DialogEx.Close(0);
  224.  
  225. Application.Exit(0);
  226.  
  227. else
  228.  
  229. TextFile.WriteFromString(_TempFolder.."\\idtemp.dat", GetStatus, false);
  230.  
  231. --Dialog.Message("Notice", GetStatus, MB_OK, MB_ICONINFORMATION, MB_DEFBUTTON1);
  232.  
  233.  
  234.  
  235. QarizmaINI = INIFile.GetValue(_TempFolder.."\\idtemp.dat", "iDezender", "qarizma");
  236.  
  237. QarizmaCheck = Crypto.MD5DigestFromString(System.GetDate(DATE_FMT_MONTH)..QarizmaSalt);
  238.  
  239.  
  240.  
  241. Progress.StepIt("Progress1");
  242.  
  243. Progress.StepIt("Progress1");
  244.  
  245.  
  246.  
  247. if QarizmaINI ~= QarizmaCheck then
  248.  
  249. Dialog.Message("iDezender", "You trying to crack iDezender?", MB_OK, MB_ICONSTOP, MB_DEFBUTTON1);
  250.  
  251. result = DialogEx.Close(0);
  252.  
  253. Application.Exit(0);
  254.  
  255. end
  256.  
  257.  
  258.  
  259. Progress.StepIt("Progress1");
  260.  
  261.  
  262.  
  263. Proceed = true;
  264.  
  265.  
  266.  
  267. result = DialogEx.Close(0);
  268.  
  269.  
  270.  
  271.  
  272.  
  273. end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement