Skip to content

Instantly share code, notes, and snippets.

@CHEF-KOCH CHEF-KOCH/idm.au3
Created Nov 17, 2016

Embed
What would you like to do?
Internet Download Manager Trial reset
#RequireAdmin
#include <Date.au3>
#include <String.au3>
FileInstall("idm_reset.reg",@TempDir & "\idm_reset.reg",1)
FileInstall("idm_trial.reg",@TempDir & "\idm_trial.reg",1)
FileInstall("idm_reg.reg",@TempDir & "\idm_reg.reg",1)
FileInstall("SetACLx32.exe",@TempDir & "\SetACLx32.exe",1)
FileInstall("SetACLx64.exe",@TempDir & "\SetACLx64.exe",1)
Global $setacl = (@OSArch = "X86") ? '"' & @TempDir & "\SetACLx32.exe" & '"' : '"' & @TempDir & "\SetACLx64.exe" & '"'
Global $version = 21
Global $urlForum = "http://bit.ly/IDMresetTrialForum"
Global $urlDownload = "http://bit.ly/IDMresetTrial"
Global $isAuto = isAuto()
Global $allkey[6]
$allkey[0] = '{6DDF00DB-1234-46EC-8356-27E7B2051192}'
$allkey[1] = '{7B8E9164-324D-4A2E-A46D-0165FB2000EC}'
$allkey[2] = '{D5B91409-A8CA-4973-9A0B-59F713D25671}'
$allkey[3] = '{5ED60779-4DE2-4E07-B862-974CA4FF2E9C}'
$allkey[4] = ''
$allkey[5] = '{07999AC3-058B-40BF-984F-69EB1E554CA7}'
Func SetOwner($owner)
; $owner : everyone or nobody
Switch $owner
case "everyone"
$owner = "S-1-1-0"
case "nobody"
$owner = "S-1-0-0"
EndSwitch
For $i=0 To UBound($allkey)-1 Step 1
If $allkey[$i] <> "" Then
RunWait($setacl & ' -on HKCU\Software\Classes\CLSID\' & $allkey[$i] & ' -ot reg -actn setowner -ownr "n:' & $owner & '" -silent',"",@SW_HIDE)
RunWait($setacl & ' -on HKCU\Software\Classes\Wow6432Node\CLSID\' & $allkey[$i] & ' -ot reg -actn setowner -ownr "n:' & $owner & '" -silent',"",@SW_HIDE)
RunWait($setacl & ' -on HKLM\Software\Classes\CLSID\' & $allkey[$i] & ' -ot reg -actn setowner -ownr "n:' & $owner & '" -silent',"",@SW_HIDE)
RunWait($setacl & ' -on HKLM\Software\Classes\Wow6432Node\CLSID\' & $allkey[$i] & ' -ot reg -actn setowner -ownr "n:' & $owner & '" -silent',"",@SW_HIDE)
EndIf
Next
EndFunc
Func SetPermission($permission)
; $permission : read or full
For $i=0 To UBound($allkey)-1 Step 1
If $allkey[$i] <> "" Then
RunWait($setacl & ' -on HKCU\Software\Classes\CLSID\' & $allkey[$i] & ' -ot reg -actn ace -ace "n:everyone;p:' & $permission & '" -actn setprot -op "dacl:p_nc;sacl:p_nc" -silent',"",@SW_HIDE)
RunWait($setacl & ' -on HKCU\Software\Classes\Wow6432Node\CLSID\' & $allkey[$i] & ' -ot reg -actn ace -ace "n:everyone;p:' & $permission & '" -actn setprot -op "dacl:p_nc;sacl:p_nc" -silent',"",@SW_HIDE)
RunWait($setacl & ' -on HKLM\Software\Classes\CLSID\' & $allkey[$i] & ' -ot reg -actn ace -ace "n:everyone;p:' & $permission & '" -actn setprot -op "dacl:p_nc;sacl:p_nc" -silent',"",@SW_HIDE)
RunWait($setacl & ' -on HKLM\Software\Classes\Wow6432Node\CLSID\' & $allkey[$i] & ' -ot reg -actn ace -ace "n:everyone;p:' & $permission & '" -actn setprot -op "dacl:p_nc;sacl:p_nc" -silent',"",@SW_HIDE)
EndIf
Next
EndFunc
Func Reset()
$allkey[4] = RegSearch('cDTvBFquXk0')
SetOwner("everyone")
SetPermission("full")
; reset everything
RunWait('reg import "' & @TempDir & "\idm_reset.reg" & '"',"",@SW_HIDE)
If $allkey[4] <> "" Then
RegDelete("HKEY_CURRENT_USER\Software\Classes\CLSID\" & $allkey[4])
RegDelete("HKEY_CURRENT_USER\Software\Classes\Wow6432Node\CLSID\" & $allkey[4])
RegDelete("HKEY_LOCAL_MACHINE\Software\Classes\CLSID\" & $allkey[4])
RegDelete("HKEY_LOCAL_MACHINE\Software\Classes\Wow6432Node\CLSID\" & $allkey[4])
EndIf
EndFunc
Func autorun($s)
Switch $s
; Disable autorun
Case "off"
RunWait('reg delete "HKCU\Software\DownloadManager" /v "auto_reset_trial" /f',"",@SW_HIDE)
RunWait('reg delete "HKCU\Software\Microsoft\Windows\CurrentVersion\Run" /v "IDM trial reset" /f',"",@SW_HIDE)
; Enable autorun
Case "trial"
RunWait('reg add "HKCU\Software\DownloadManager" /v "auto_reset_trial" /t "REG_SZ" /d "' & _DateAdd("D",15,@YEAR & "/" & @MON & "/" & @MDAY) & '" /f',"",@SW_HIDE)
RunWait('reg add "HKCU\Software\Microsoft\Windows\CurrentVersion\Run" /v "IDM trial reset" /t "REG_SZ" /d "\"' & @ScriptFullPath & '\" /trial" /f',"",@SW_HIDE)
EndSwitch
EndFunc
Func Trial()
Reset()
RunWait('reg import "' & @TempDir & "\idm_trial.reg" & '"',"",@SW_HIDE)
SetPermission("read")
SetOwner("nobody")
EndFunc
Func TrialSilent()
Local $auto_reset_trial = RegRead("HKCU\Software\DownloadManager","auto_reset_trial")
Local $day_to_reset = _DateDiff("D",@YEAR & "/" & @MON & "/" & @MDAY,$auto_reset_trial)
If $day_to_reset <= 0 Then
Trial()
autorun("trial")
If GotUpdate() Then
$Download = (MsgBox(1,"IDM trial reset","Update me now?")==1)
If $Download Then ShellExecute($urlDownload)
EndIf
EndIf
EndFunc
Func Register($FName = "IDM trial reset")
Reset()
autorun("off")
RunWait('reg import "' & @TempDir & "\idm_reg.reg" & '"',"",@SW_HIDE)
If $allkey[4] <> "" Then
RegWrite("HKEY_CURRENT_USER\Software\Classes\CLSID\" & $allkey[4])
RegWrite("HKEY_CURRENT_USER\Software\Classes\Wow6432Node\CLSID\" & $allkey[4])
RegWrite("HKEY_LOCAL_MACHINE\Software\Classes\CLSID\" & $allkey[4])
RegWrite("HKEY_LOCAL_MACHINE\Software\Classes\Wow6432Node\CLSID\" & $allkey[4])
EndIf
RunWait('reg add "HKCU\Software\DownloadManager" /v "FName" /t "REG_SZ" /d "' & $FName & '" /f',"",@SW_HIDE)
SetPermission("read")
SetOwner("nobody")
EndFunc
Func GotUpdate()
Local $info = InetRead("http://pastebin.com/raw.php?i=uYr0cstV",1)
If $info <> "" Then
Local $latest = _StringBetween(BinaryToString($info),"<version>","</version>")[0]
Return ($latest > $version)
Else
Return 0
EndIf
EndFunc
Func isAuto()
Local $checkTime = _DateIsValid(RegRead("HKCU\Software\DownloadManager","auto_reset_trial"))
Local $Autorun = FileExists("""" & _StringBetween("" & RegRead("HKCU\Software\Microsoft\Windows\CurrentVersion\Run","IDM trial reset"),"""","""") & """")
return $Autorun*$checkTime
EndFunc
Func clearTemp()
; Delete temp file
FileDelete(@TempDir & "\idm_reset.reg")
FileDelete(@TempDir & "\idm_trial.reg")
FileDelete(@TempDir & "\idm_reg.reg")
FileDelete(@TempDir & "\SetACLx32.exe")
FileDelete(@TempDir & "\SetACLx64.exe")
FileDelete(@TempDir & "\reg_query.tmp")
EndFunc
Func RegSearch($value = "")
$key = ""
$DOS = RunWait(@ComSpec & " /c reg query hkcr\clsid /s > " & @TempDir & "\reg_query.tmp", "", @SW_HIDE, 0x10000)
$find = StringSplit(_getDOSOutput('findstr /N /I ' & $value & ' ' & @TempDir & "\reg_query.tmp"),':')[1]
$find = Number($find)-1
$find = _getDOSOutput('findstr /N . ' & @TempDir & "\reg_query.tmp" & ' | findstr /b ' & $find & ':')
If StringInStr($find,"{") AND StringInStr($find,"}") Then
$key = "{" & _StringBetween($find,"{","}")[0] & "}"
EndIf
Return $key
EndFunc
Func _getDOSOutput($command)
Local $text = '', $Pid = Run('"' & @ComSpec & '" /c ' & $command, '', @SW_HIDE, 2 + 4)
While 1
$text &= StdoutRead($Pid, False, False)
If @error Then ExitLoop
Sleep(10)
WEnd
Return StringStripWS($text, 7)
EndFunc ;==>_getDOSOutput
Windows Registry Editor Version 5.00
[-HKEY_CURRENT_USER\Software\Classes\CLSID\{7B8E9164-324D-4A2E-A46D-0165FB2000EC}]
[-HKEY_CURRENT_USER\Software\Classes\Wow6432Node\CLSID\{7B8E9164-324D-4A2E-A46D-0165FB2000EC}]
[-HKEY_LOCAL_MACHINE\Software\Classes\CLSID\{7B8E9164-324D-4A2E-A46D-0165FB2000EC}]
[-HKEY_LOCAL_MACHINE\Software\Classes\Wow6432Node\CLSID\{7B8E9164-324D-4A2E-A46D-0165FB2000EC}]
[-HKEY_CURRENT_USER\Software\Classes\CLSID\{6DDF00DB-1234-46EC-8356-27E7B2051192}]
[-HKEY_CURRENT_USER\Software\Classes\Wow6432Node\CLSID\{6DDF00DB-1234-46EC-8356-27E7B2051192}]
[-HKEY_LOCAL_MACHINE\Software\Classes\CLSID\{6DDF00DB-1234-46EC-8356-27E7B2051192}]
[-HKEY_LOCAL_MACHINE\Software\Classes\Wow6432Node\CLSID\{6DDF00DB-1234-46EC-8356-27E7B2051192}]
[-HKEY_CURRENT_USER\Software\Classes\CLSID\{D5B91409-A8CA-4973-9A0B-59F713D25671}]
[-HKEY_CURRENT_USER\Software\Classes\Wow6432Node\CLSID\{D5B91409-A8CA-4973-9A0B-59F713D25671}]
[-HKEY_LOCAL_MACHINE\Software\Classes\CLSID\{D5B91409-A8CA-4973-9A0B-59F713D25671}]
[-HKEY_LOCAL_MACHINE\Software\Classes\Wow6432Node\CLSID\{D5B91409-A8CA-4973-9A0B-59F713D25671}]
[-HKEY_CURRENT_USER\Software\Classes\CLSID\{5ED60779-4DE2-4E07-B862-974CA4FF2E9C}]
[-HKEY_CURRENT_USER\Software\Classes\Wow6432Node\CLSID\{5ED60779-4DE2-4E07-B862-974CA4FF2E9C}]
[-HKEY_LOCAL_MACHINE\Software\Classes\CLSID\{5ED60779-4DE2-4E07-B862-974CA4FF2E9C}]
[-HKEY_LOCAL_MACHINE\Software\Classes\Wow6432Node\CLSID\{5ED60779-4DE2-4E07-B862-974CA4FF2E9C}]
[-HKEY_CURRENT_USER\Software\Classes\CLSID\{07999AC3-058B-40BF-984F-69EB1E554CA7}]
[-HKEY_CURRENT_USER\Software\Classes\Wow6432Node\CLSID\{07999AC3-058B-40BF-984F-69EB1E554CA7}]
[-HKEY_LOCAL_MACHINE\Software\Classes\CLSID\{07999AC3-058B-40BF-984F-69EB1E554CA7}]
[-HKEY_LOCAL_MACHINE\Software\Classes\Wow6432Node\CLSID\{07999AC3-058B-40BF-984F-69EB1E554CA7}]
[HKEY_CURRENT_USER\Software\DownloadManager]
"FName"=-
"LName"=-
"Email"=-
"Serial"=-
[HKEY_LOCAL_MACHINE\Software\Internet Download Manager]
"FName"=-
"LName"=-
"Email"=-
"Serial"=-
[HKEY_LOCAL_MACHINE\Software\Wow6432Node\Internet Download Manager]
"FName"=-
"LName"=-
"Email"=-
"Serial"=-
Windows Registry Editor Version 5.00
[HKEY_CURRENT_USER\Software\DownloadManager]
"FName"="IDM trial reset"
"LName"="CHEF-KOCH"
"Email"="your@email.com"
"Serial"="9QNBL-L2641-Y7WVE-QEN3I"
[HKEY_CURRENT_USER\Software\Classes\CLSID\{6DDF00DB-1234-46EC-8356-27E7B2051192}]
"MData"=hex(0):21,9e,ac,77,b5,b5,26,3c,9d,ff,86,40,2d,b9,55,6c,13,17,81,2f,93,54,\
2e,ab,2c,34,ca,dc,32,1f,a4,b0,c6,cc,4c,83,48,84,2c,1e,68,5f,4d,d7,ac,41,2e,\
52,5c,6a,4a,78,7c,3b,39,8d,b3,d5,62,d6,a0,e8,12,e5,46,8f,3c,f2,5c,68,ee,21,\
15,a4,0a,99,ab,bf,d8,2c,5c,77,3b,01,33,e9,9b,4f,12,8e,c4,a7,a1,35,9f,eb,15,\
a4,0a,99,ab,bf,d8,2c,ef,ac,0d,ee,9b,62,b8,89,1c,42,98,d2,36,ce,b3,9e,e7,56,\
88,5b,cc,7f,1d,40,34,a2,cd,43,fe,e6,97,15,40,11,6c,23,3f,1a,3c,92,0b,f9,20,\
e6,17,ac,22,68,8f,45,30,16,84,0d,f4,de,9c,e8,e5,a9,15,5d,d9,1c,22,d2,1b,76,\
2d,b4,c4,bb,e8,84,71,b7,16,8a,2e,35,a0,a8,66,49,b7,1a,ec,38,0b,5f,4e,35,4e,\
59,31,63,cd,d2,af,85,4e,90,32,ea,15,44,53,e0,8d,7b,af,34,b8,fe,c8,ec,2c,ef,\
8a,26,01,77,38,5b,df,31,59,65,36,d8,51,ef,7f,20,6d,43,d6,c2,e8,d6,17,18,16,\
a4,d0,f3,ea,f7,83,c5,55,00
[HKEY_CURRENT_USER\Software\Classes\Wow6432Node\CLSID\{6DDF00DB-1234-46EC-8356-27E7B2051192}]
"MData"=hex(0):21,9e,ac,77,b5,b5,26,3c,9d,ff,86,40,2d,b9,55,6c,13,17,81,2f,93,54,\
2e,ab,2c,34,ca,dc,32,1f,a4,b0,c6,cc,4c,83,48,84,2c,1e,68,5f,4d,d7,ac,41,2e,\
52,5c,6a,4a,78,7c,3b,39,8d,b3,d5,62,d6,a0,e8,12,e5,46,8f,3c,f2,5c,68,ee,21,\
15,a4,0a,99,ab,bf,d8,2c,5c,77,3b,01,33,e9,9b,4f,12,8e,c4,a7,a1,35,9f,eb,15,\
a4,0a,99,ab,bf,d8,2c,ef,ac,0d,ee,9b,62,b8,89,1c,42,98,d2,36,ce,b3,9e,e7,56,\
88,5b,cc,7f,1d,40,34,a2,cd,43,fe,e6,97,15,40,11,6c,23,3f,1a,3c,92,0b,f9,20,\
e6,17,ac,22,68,8f,45,30,16,84,0d,f4,de,9c,e8,e5,a9,15,5d,d9,1c,22,d2,1b,76,\
2d,b4,c4,bb,e8,84,71,b7,16,8a,2e,35,a0,a8,66,49,b7,1a,ec,38,0b,5f,4e,35,4e,\
59,31,63,cd,d2,af,85,4e,90,32,ea,15,44,53,e0,8d,7b,af,34,b8,fe,c8,ec,2c,ef,\
8a,26,01,77,38,5b,df,31,59,65,36,d8,51,ef,7f,20,6d,43,d6,c2,e8,d6,17,18,16,\
a4,d0,f3,ea,f7,83,c5,55,00
[HKEY_LOCAL_MACHINE\Software\Classes\CLSID\{6DDF00DB-1234-46EC-8356-27E7B2051192}]
"MData"=hex(0):21,9e,ac,77,b5,b5,26,3c,9d,ff,86,40,2d,b9,55,6c,13,17,81,2f,93,54,\
2e,ab,2c,34,ca,dc,32,1f,a4,b0,c6,cc,4c,83,48,84,2c,1e,68,5f,4d,d7,ac,41,2e,\
52,5c,6a,4a,78,7c,3b,39,8d,b3,d5,62,d6,a0,e8,12,e5,46,8f,3c,f2,5c,68,ee,21,\
15,a4,0a,99,ab,bf,d8,2c,5c,77,3b,01,33,e9,9b,4f,12,8e,c4,a7,a1,35,9f,eb,15,\
a4,0a,99,ab,bf,d8,2c,ef,ac,0d,ee,9b,62,b8,89,1c,42,98,d2,36,ce,b3,9e,e7,56,\
88,5b,cc,7f,1d,40,34,a2,cd,43,fe,e6,97,15,40,11,6c,23,3f,1a,3c,92,0b,f9,20,\
e6,17,ac,22,68,8f,45,30,16,84,0d,f4,de,9c,e8,e5,a9,15,5d,d9,1c,22,d2,1b,76,\
2d,b4,c4,bb,e8,84,71,b7,16,8a,2e,35,a0,a8,66,49,b7,1a,ec,38,0b,5f,4e,35,4e,\
59,31,63,cd,d2,af,85,4e,90,32,ea,15,44,53,e0,8d,7b,af,34,b8,fe,c8,ec,2c,ef,\
8a,26,01,77,38,5b,df,31,59,65,36,d8,51,ef,7f,20,6d,43,d6,c2,e8,d6,17,18,16,\
a4,d0,f3,ea,f7,83,c5,55,00
[HKEY_LOCAL_MACHINE\Software\Classes\Wow6432Node\CLSID\{6DDF00DB-1234-46EC-8356-27E7B2051192}]
"MData"=hex(0):21,9e,ac,77,b5,b5,26,3c,9d,ff,86,40,2d,b9,55,6c,13,17,81,2f,93,54,\
2e,ab,2c,34,ca,dc,32,1f,a4,b0,c6,cc,4c,83,48,84,2c,1e,68,5f,4d,d7,ac,41,2e,\
52,5c,6a,4a,78,7c,3b,39,8d,b3,d5,62,d6,a0,e8,12,e5,46,8f,3c,f2,5c,68,ee,21,\
15,a4,0a,99,ab,bf,d8,2c,5c,77,3b,01,33,e9,9b,4f,12,8e,c4,a7,a1,35,9f,eb,15,\
a4,0a,99,ab,bf,d8,2c,ef,ac,0d,ee,9b,62,b8,89,1c,42,98,d2,36,ce,b3,9e,e7,56,\
88,5b,cc,7f,1d,40,34,a2,cd,43,fe,e6,97,15,40,11,6c,23,3f,1a,3c,92,0b,f9,20,\
e6,17,ac,22,68,8f,45,30,16,84,0d,f4,de,9c,e8,e5,a9,15,5d,d9,1c,22,d2,1b,76,\
2d,b4,c4,bb,e8,84,71,b7,16,8a,2e,35,a0,a8,66,49,b7,1a,ec,38,0b,5f,4e,35,4e,\
59,31,63,cd,d2,af,85,4e,90,32,ea,15,44,53,e0,8d,7b,af,34,b8,fe,c8,ec,2c,ef,\
8a,26,01,77,38,5b,df,31,59,65,36,d8,51,ef,7f,20,6d,43,d6,c2,e8,d6,17,18,16,\
a4,d0,f3,ea,f7,83,c5,55,00
[HKEY_CURRENT_USER\Software\DownloadManager]
"scansk"=hex(0):6f,4e,79,b5,cc,8b,50,bb,f4,b7,e2,6d,2e,38,d2,8b,ad,10,0b,03,a6,\
1b,53,30,6b,b8,8b,92,d6,04,22,c7,55,b9,a5,33,4d,a8,4e,9b,00,00,00,00,00,00,\
00,00,00,00
[HKEY_CURRENT_USER\Software\Classes\CLSID\{7B8E9164-324D-4A2E-A46D-0165FB2000EC}]
"scansk"=hex(0):6f,4e,79,b5,cc,8b,50,bb,f4,b7,e2,6d,2e,38,d2,8b,ad,10,0b,03,a6,\
1b,53,30,6b,b8,8b,92,d6,04,22,c7,55,b9,a5,33,4d,a8,4e,9b,00,00,00,00,00,00,\
00,00,00,00
[HKEY_CURRENT_USER\Software\Classes\Wow6432Node\CLSID\{7B8E9164-324D-4A2E-A46D-0165FB2000EC}]
"scansk"=hex(0):6f,4e,79,b5,cc,8b,50,bb,f4,b7,e2,6d,2e,38,d2,8b,ad,10,0b,03,a6,\
1b,53,30,6b,b8,8b,92,d6,04,22,c7,55,b9,a5,33,4d,a8,4e,9b,00,00,00,00,00,00,\
00,00,00,00
[HKEY_LOCAL_MACHINE\Software\Classes\CLSID\{7B8E9164-324D-4A2E-A46D-0165FB2000EC}]
"scansk"=hex(0):6f,4e,79,b5,cc,8b,50,bb,f4,b7,e2,6d,2e,38,d2,8b,ad,10,0b,03,a6,\
1b,53,30,6b,b8,8b,92,d6,04,22,c7,55,b9,a5,33,4d,a8,4e,9b,00,00,00,00,00,00,\
00,00,00,00
[HKEY_LOCAL_MACHINE\Software\Classes\Wow6432Node\CLSID\{7B8E9164-324D-4A2E-A46D-0165FB2000EC}]
"scansk"=hex(0):6f,4e,79,b5,cc,8b,50,bb,f4,b7,e2,6d,2e,38,d2,8b,ad,10,0b,03,a6,\
1b,53,30,6b,b8,8b,92,d6,04,22,c7,55,b9,a5,33,4d,a8,4e,9b,00,00,00,00,00,00,\
00,00,00,00
Windows Registry Editor Version 5.00
[HKEY_CURRENT_USER\Software\DownloadManager]
"Serial"=""
[HKEY_CURRENT_USER\Software\Classes\CLSID\{5ED60779-4DE2-4E07-B862-974CA4FF2E9C}]
"scansk"=hex(0):91,1d,ac,d6,90,5c,42,ea,ba,1a,ac,08,1a,18,2f,16,2a,a8,0a,aa,24,bf,\
0c,fc,4e,7b,3b,76,f7,70,93,58,5c,03,03,7e,04,ab,b0,7e,00,00,00,00,00,00,00,\
00,00,00
[HKEY_CURRENT_USER\Software\Classes\Wow6432Node\CLSID\{5ED60779-4DE2-4E07-B862-974CA4FF2E9C}]
"scansk"=hex(0):91,1d,ac,d6,90,5c,42,ea,ba,1a,ac,08,1a,18,2f,16,2a,a8,0a,aa,24,bf,\
0c,fc,4e,7b,3b,76,f7,70,93,58,5c,03,03,7e,04,ab,b0,7e,00,00,00,00,00,00,00,\
00,00,00
[HKEY_CURRENT_USER\Software\DownloadManager]
"scansk"=hex(0):91,1d,ac,d6,90,5c,42,ea,ba,1a,ac,08,1a,18,2f,16,2a,a8,0a,aa,24,bf,\
0c,fc,4e,7b,3b,76,f7,70,93,58,5c,03,03,7e,04,ab,b0,7e,00,00,00,00,00,00,00,\
00,00,00
[HKEY_LOCAL_MACHINE\Software\Classes\CLSID\{5ED60779-4DE2-4E07-B862-974CA4FF2E9C}]
"scansk"=hex(0):91,1d,ac,d6,90,5c,42,ea,ba,1a,ac,08,1a,18,2f,16,2a,a8,0a,aa,24,bf,\
0c,fc,4e,7b,3b,76,f7,70,93,58,5c,03,03,7e,04,ab,b0,7e,00,00,00,00,00,00,00,\
00,00,00
[HKEY_LOCAL_MACHINE\Software\Classes\Wow6432Node\CLSID\{5ED60779-4DE2-4E07-B862-974CA4FF2E9C}]
"scansk"=hex(0):91,1d,ac,d6,90,5c,42,ea,ba,1a,ac,08,1a,18,2f,16,2a,a8,0a,aa,24,bf,\
0c,fc,4e,7b,3b,76,f7,70,93,58,5c,03,03,7e,04,ab,b0,7e,00,00,00,00,00,00,00,\
00,00,00
#include <core.au3>
#include <GUIConstantsEx.au3>
AutoItSetOption("TrayMenuMode",1)
If $CmdLine[0] = 0 Then
GUI()
Else
Switch $CmdLine[1]
Case "/trial"
TrialSilent()
clearTemp()
Case Else
GUI()
EndSwitch
EndIf
Func GUI()
#Region ### START Koda GUI section ###
$GUI = GUICreate("IDM trial reset", 325, 112, -1, -1)
$tabMain = GUICtrlCreateTab(1, 0, 325, 112)
$tabTrialReset = GUICtrlCreateTabItem("Trial reset")
$btReset = GUICtrlCreateButton("Reset the IDM trial now", 78, 40, 180, 35)
$cbAutorun = GUICtrlCreateCheckbox("Automatically", 128, 80, 80, 20)
$tabRegister = GUICtrlCreateTabItem("Register")
$btReg = GUICtrlCreateButton("Register IDM now", 78, 40, 180, 35)
$lbReg = GUICtrlCreateLabel("If IDM will be blocked then Register again or use Trial reset", 27, 80, 282, 17)
$tabHelp = GUICtrlCreateTabItem("Help")
GUICtrlSetState(-1,$GUI_SHOW)
$lbHelp = GUICtrlCreateLabel("", 15, 35, 308, 50)
GUICtrlSetData(-1, StringFormat("Trial reset ---> Reset the IDM trial, fix blocked, fake serial...\r\nRegister -----> Register IDM"))
$btForum = GUICtrlCreateButton("Chat about this tool", 56, 80, 105, 25)
$btUpdate = GUICtrlCreateButton("Check for update", 166, 80, 105, 25)
GUICtrlCreateTabItem("")
GUICtrlSetState($cbAutorun,$isAuto ? 1 : 4)
GUISetState(@SW_SHOW)
#EndRegion ### END Koda GUI section ###
While 1
$nMsg = GUIGetMsg()
Switch $nMsg
Case $GUI_EVENT_CLOSE
clearTemp()
Exit
Case $btReset
GUICtrlSetData($btReset,"Please wait...")
Trial()
GUICtrlSetData($btReset,"Reset the IDM trial now")
MsgBox(0,"Reset IDM trial","You have 30 day trial now!")
Case $cbAutorun
If GUICtrlRead($cbAutorun) = 1 Then
GUICtrlSetData($btReset,"Please wait...")
Trial()
autorun("trial")
GUICtrlSetData($btReset,"Reset the IDM trial now")
MsgBox(0,"Auto reset","The IDM trial will be reset automatically.")
Else
autorun("off")
MsgBox(0,"Auto reset","The IDM trial will NOT be reset automatically.")
EndIf
Case $btReg
$Name = InputBox("Register IDM","Type your name here: ","IDM trial reset","","","130")
If @error <> 1 Then
If StringLen($Name) = 0 Then $Name = "IDM trial reset"
GUICtrlSetData($btReg,"Please wait...")
Register($Name)
GUICtrlSetState($cbAutorun,4)
GUICtrlSetData($btReg,"Register IDM now")
MsgBox(0,"Register IDM","IDM is registered now!")
EndIf
Case $btForum
ShellExecute($urlForum)
Case $btUpdate
GUICtrlSetData($btUpdate,"Please wait...")
If GotUpdate() Then
$Download = (MsgBox(1,"IDM trial reset","Update me now?")==1)
If $Download Then ShellExecute($urlDownload)
Else
MsgBox(0,"IDM trial reset","No update was found!")
EndIf
GUICtrlSetData($btUpdate,"Check for update")
EndSwitch
WEnd
EndFunc
@pkumarprakash

This comment has been minimized.

Copy link

pkumarprakash commented Dec 15, 2018

How you know this code is correct. is this code written in visual basic ? can you tell me how to write a code for registry

@gnanaprakash2918

This comment has been minimized.

Copy link

gnanaprakash2918 commented May 19, 2019

Tell me how to write a code for registry

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.