Function at 0x413b80
Capabilities:
Check os version
Get common file path
Get file system object information

Disassembly:
push ebx
mov ebx, esp
sub esp, 8
and esp, 0xfffffff8
add esp, 4
push ebp
mov ebp, dword [ebx + 4]
mov dword [esp + 4], ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x48f4ec
mov eax, dword fs:[0]
push eax
push ebx
sub esp, 0x7b8
mov eax, dword [0x4c9070]
xor eax, ebp
mov dword [ebp - 0x14], eax
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov edi, ecx
mov dword [ebp - 0x778], edi
lea eax, [edi + 0x30]
push str.sys_title
mov ecx, eax
mov dword [ebp - 0x798], eax
call dword [sym.imp.DuiLib.dll_public:_class_DuiLib::CControlUI____thiscall_DuiLib::CPaintManagerUI::FindControl_wchar_t_const__const]
mov esi, eax
test esi, esi
je 0x413c58
mov eax, dword [edi + 0xae0]
mov ecx, dword [eax + 0xc]
cmp dword [ecx - 0xc], 0
jne 0x413c3d
push dword [eax + 4]
lea eax, [ebp - 0x77c]
push eax
call fcn.00413b20
push 1
mov dword [ebp - 4], 0
mov ecx, esi
push dword [eax]
call dword [sym.imp.DuiLib.dll_public:_void___thiscall_DuiLib::CControlUI::SetString_wchar_t_const___bool_]
mov dword [ebp - 4], 0xffffffff
or eax, 0xffffffff
mov edx, dword [ebp - 0x77c]
add edx, 0xfffffff0
lock xadd dword [edx + 0xc], eax
dec eax
test eax, eax
jg 0x413c58
mov ecx, dword [edx]
push edx
mov eax, dword [ecx]
call dword [eax + 4]
jmp 0x413c58
cmp byte [eax + 8], 0
je 0x413c50
push 1
push ecx
mov ecx, esi
call dword [sym.imp.DuiLib.dll_public:_void___thiscall_DuiLib::CControlUI::SetString_wchar_t_const___bool_]
jmp 0x413c58
mov eax, dword [esi]
push ecx
mov ecx, esi
call dword [eax + 0x2c]
mov eax, dword [edi + 0xae0]
mov ecx, dword [edi + 0xb54]
cmp dword [eax + 4], 1
setne al
movzx eax, al
push eax
call dword [sym.imp.DuiLib.dll_public:_void___thiscall_DuiLib::CEditUI::SetReadOnly_bool_]
mov edx, dword [edi + 0xae0]
cmp dword [edx + 4], 1
jne 0x413c8f
mov ecx, dword [edi + 0xb54]
push dword [edx + 0x14]
mov eax, dword [ecx]
call dword [eax + 0x2c]
lea eax, [ebp - 0x76c]
push eax
push 0x11
push dword [edi + 4]
call dword [sym.imp.SHELL32.dll_SHGetSpecialFolderLocation]
mov esi, dword [sym.imp.SHELL32.dll_SHGetFileInfoW]
test eax, eax
js 0x413cee
push 0x2b4
lea eax, [ebp - 0x768]
push 0
push eax
call fcn.0046ea70
add esp, 0xc
lea eax, [ebp - 0x768]
push 0x4009
push 0x2b4
push eax
push 0
push dword [ebp - 0x76c]
call esi
push dword [ebp - 0x76c]
mov dword [edi + 0xaf8], eax
call dword [sym.imp.ole32.dll_CoTaskMemFree]
mov ecx, edi
call fcn.004144e0
mov eax, dword [edi + 0xb64]
mov ecx, dword [edi + 0xaf8]
movaps xmm0, xmmword [0x4afcf0]
movups xmmword [ebp - 0x28], xmm0
mov dword [eax + 0xe10], ecx
lea eax, [ebp - 0x77c]
push eax
push 0x11
push dword [edi + 4]
mov dword [ebp - 0x18], 0
mov dword [ebp - 0x790], str.374DE290_123F_4565_9164_39C4925E467B
mov dword [ebp - 0x78c], str.31C0DD25_9439_4F12_BF41_7FF4EDA38722
call dword [sym.imp.SHELL32.dll_SHGetSpecialFolderLocation]
test eax, eax
js 0x4140b0
push 0x2b4
lea eax, [ebp - 0x4b0]
push 0
push eax
call fcn.0046ea70
add esp, 0xc
lea eax, [ebp - 0x4b0]
push 0x4208
push 0x2b4
push eax
push 0
push dword [ebp - 0x77c]
call esi
test eax, eax
js 0x4140a4
push 0x40
call fcn.0046c52d
add esp, 4
mov dword [ebp - 0x770], eax
mov ecx, eax
call fcn.00410b30
mov esi, eax
lea edx, [ebp - 0x4a4]
lea eax, [edx + 2]
mov dword [ebp - 0x784], eax
lea ecx, [esi + 4]
nop dword [eax + eax]
mov ax, word [edx]
add edx, 2
test ax, ax
jne 0x413db0
sub edx, dword [ebp - 0x784]
lea eax, [ebp - 0x4a4]
sar edx, 1
push edx
push eax
call fcn.004046a0
mov eax, dword [ebp - 0x4ac]
xorps xmm0, xmm0
mov dword [esi + 0x18], eax
mov ecx, dword [edi + 0xb64]
movd eax, xmm0
movups xmmword [ebp - 0x7c4], xmm0
or dword [ebp - 0x7bc], 0x60
or dword [ebp - 0x7b8], 0x60
or eax, 0x6f
mov dword [ebp - 0x7c4], eax
lea eax, [ebp - 0x4a4]
movups xmmword [ebp - 0x7b4], xmm0
mov dword [ebp - 0x7b4], eax
mov eax, dword [ebp - 0x4ac]
push 0
mov dword [ebp - 0x7ac], eax
mov dword [ebp - 0x7a8], eax
lea eax, [ebp - 0x7c4]
push 0
movq qword [ebp - 0x7a4], xmm0
push eax
mov dword [ebp - 0x7a0], esi
mov dword [ebp - 0x7a4], 0
call dword [sym.imp.DuiLib.dll_public:_struct_DuiLib::DTV_ITEM_INFO____thiscall_DuiLib::CTreeViewExUI::InsertItem_struct_DuiLib::DTV_ITEM___struct_DuiLib::DTV_ITEM_INFO___struct_DuiLib::DTV_ITEM_INFO__]
mov dword [ebp - 0x76c], eax
test eax, eax
je 0x4140a4
xor eax, eax
mov dword [ebp - 0x780], eax
nop dword [eax + eax]
push 0
push dword [ebp + eax*4 - 0x28]
lea eax, [ebp - 0x6c0]
push eax
push dword [edi + 4]
call dword [sym.imp.SHELL32.dll_SHGetSpecialFolderPathW]
test eax, eax
je 0x413ebf
push 0x40
call fcn.0046c52d
add esp, 4
mov dword [ebp - 0x770], eax
mov ecx, eax
call fcn.00410b30
mov esi, eax
lea ecx, [ebp - 0x6c0]
mov edx, esi
call fcn.00418660
push ecx
push dword [ebp - 0x76c]
mov ecx, edi
push esi
call fcn.004169d0
mov eax, dword [ebp - 0x780]
inc eax
mov dword [ebp - 0x780], eax
cmp eax, 5
jb 0x413e70
push 0x110
lea eax, [ebp - 0x1c4]
mov dword [ebp - 0x1c8], 0x114
push 0
push eax
call fcn.0046ea70
add esp, 0xc
lea eax, [ebp - 0x1c8]
push eax
call dword [sym.imp.KERNEL32.dll_GetVersionExW]
test eax, eax
je 0x41400e
cmp dword [ebp - 0x1c4], 6
jb 0x41400e
push str.Shell32.dll
call dword [sym.imp.KERNEL32.dll_LoadLibraryW]
mov dword [ebp - 0x770], eax
test eax, eax
je 0x41400e
push str.SHGetKnownFolderPath
push eax
call dword [sym.imp.KERNEL32.dll_GetProcAddress]
mov esi, eax
xor eax, eax
mov dword [ebp - 0x788], esi
mov dword [ebp - 0x784], eax
test esi, esi
je 0x414002
lea ecx, [ebp - 0x15]
push ecx
lea ecx, [ebp - 0x16]
push ecx
lea ecx, [ebp - 0x17]
push ecx
lea ecx, [ebp - 0x18]
push ecx
lea ecx, [ebp - 0x19]
push ecx
lea ecx, [ebp - 0x1a]
push ecx
lea ecx, [ebp - 0x1b]
push ecx
lea ecx, [ebp - 0x1c]
push ecx
lea ecx, [ebp - 0x1e]
push ecx
lea ecx, [ebp - 0x20]
push ecx
lea ecx, [ebp - 0x24]
push ecx
push str._08x__04hx__04hx__02hhx_02hhx__02hhx_02hhx_02hhx_02hhx_02hhx_02hhx
push dword [ebp + eax*4 - 0x790]
call fcn.00425950
add esp, 0x34
lea eax, [ebp - 0x780]
push eax
push 0
push 0
lea eax, [ebp - 0x24]
push eax
call esi
test eax, eax
jne 0x413fec
push 0x40
call fcn.0046c52d
add esp, 4
mov dword [ebp - 0x79c], eax
mov ecx, eax
call fcn.00410b30
mov ecx, dword [ebp - 0x780]
mov esi, eax
mov edx, esi
call fcn.00418660
push ecx
push dword [ebp - 0x76c]
mov ecx, edi
push esi
call fcn.004169d0
push dword [ebp - 0x780]
call dword [sym.imp.ole32.dll_CoTaskMemFree]
mov esi, dword [ebp - 0x788]
mov eax, dword [ebp - 0x784]
inc eax
mov dword [ebp - 0x784], eax
cmp eax, 2
jb 0x413f48
push dword [ebp - 0x770]
call dword [sym.imp.KERNEL32.dll_FreeLibrary]
mov ecx, dword [edi + 0xb64]
push 0
push 0
push 0
push dword [ebp - 0x76c]
call dword [sym.imp.DuiLib.dll_public:_int___thiscall_DuiLib::CTreeViewExUI::SortChildren_struct_DuiLib::DTV_ITEM_INFO___int__int____stdcall___struct_DuiLib::DTV_ITEM_INFO___struct_DuiLib::DTV_ITEM_INFO___long_int___long_int_]
mov dword [ebp - 0x794], 0
mov dword [ebp - 0x790], 0
mov dword [ebp - 0x78c], 0
lea ecx, [ebp - 0x794]
mov dword [ebp - 4], 1
call fcn.00417e10
mov ecx, dword [ebp - 0x794]
mov esi, ecx
cmp ecx, dword [ebp - 0x790]
je 0x414087
push ecx
push dword [ebp - 0x76c]
mov ecx, edi
push dword [esi]
call fcn.004169d0
add esi, 4
cmp esi, dword [ebp - 0x790]
jne 0x414066
mov ecx, dword [ebp - 0x794]
mov dword [ebp - 4], 0xffffffff
test ecx, ecx
je 0x4140a4
mov eax, dword [ebp - 0x78c]
sub eax, ecx
sar eax, 2
push eax
push ecx
call fcn.0041dde0
push dword [ebp - 0x77c]
call dword [sym.imp.ole32.dll_CoTaskMemFree]
mov eax, dword [edi + 0xae0]
mov edi, dword [eax + 0x1c]
cmp edi, dword [eax + 0x20]
je 0x414373
mov ecx, dword [ebp - 0x778]
nop dword [eax + eax]
mov edx, dword [ecx + 0xb5c]
mov dword [ebp - 0x770], edx
test edx, edx
je 0x414361
mov eax, dword [edx]
mov ecx, edx
mov eax, dword [eax + 0xb8]
call eax
mov ecx, eax
call dword [sym.imp.DuiLib.dll_public:_wchar_t_const____thiscall_DuiLib::CDuiString::operator_wchar_t_const__void_const]
lea ecx, [ebp - 0x1f8]
mov esi, eax
call dword [sym.imp.DuiLib.dll_public:_void___thiscall_DuiLib::CDialogBuilder::constructor_void_]
mov eax, dword [ebp - 0x778]
mov ecx, eax
push 0
push 0x4cd82c
push 0x4cc648
add eax, 0x28
mov dword [ebp - 4], 2
neg ecx
push 0
push dword [ebp - 0x798]
sbb ecx, ecx
and ecx, eax
push ecx
push 0
push ecx
mov eax, esp
lea ecx, [ebp - 0x1f8]
mov dword [eax], esi
call dword [sym.imp.DuiLib.dll_public:_class_DuiLib::CControlUI____thiscall_DuiLib::CDialogBuilder::Create_class_DuiLib::STRINGorID__wchar_t_const___class_DuiLib::IDialogBuilderCallback___class_DuiLib::CPaintManagerUI___class_DuiLib::CControlUI__]
push 0
push eax
call fcn.0048e49a
mov esi, eax
add esp, 0x14
test esi, esi
jne 0x41416f
lea ecx, [ebp - 0x1f8]
mov dword [ebp - 4], 0xffffffff
call dword [sym.imp.DuiLib.dll_public:_void___thiscall_DuiLib::CDialogBuilder::destructor_void_]
jmp 0x41435b
mov ecx, dword [ebp - 0x770]
add ecx, 0x808
push esi
mov eax, dword [ecx]
call dword [eax + 0x10]
lea ecx, [ebp - 0x1f8]
mov dword [ebp - 4], 0xffffffff
call dword [sym.imp.DuiLib.dll_public:_void___thiscall_DuiLib::CDialogBuilder::destructor_void_]
mov eax, dword [edi + 0xc]
mov ecx, esi
mov dword [ebp - 0x770], eax
mov eax, dword [edi + 4]
mov dword [ebp - 0x77c], eax
mov al, byte [edi]
push str.text
mov byte [ebp - 0x771], al
call dword [sym.imp.DuiLib.dll_public:_class_DuiLib::CControlUI____thiscall_DuiLib::CContainerUI::FindSubControl_wchar_t_const__]
mov esi, eax
test esi, esi
je 0x414207
cmp byte [ebp - 0x771], 0
mov ecx, esi
je 0x4141fc
push 1
push dword [ebp - 0x77c]
call dword [sym.imp.DuiLib.dll_public:_void___thiscall_DuiLib::CControlUI::SetString_wchar_t_const___bool_]
mov eax, dword [ebp - 0x770]
test eax, eax
je 0x414207
cmp word [eax], 0
je 0x414207
push eax
push str.ext:_s
push esi
call dword [sym.imp.DuiLib.dll_public:_void___cdecl_DuiLib::CControlUI::StringFormat_wchar_t_const__]
add esp, 0xc
jmp 0x414207
mov eax, dword [esi]
push dword [ebp - 0x77c]
call dword [eax + 0x2c]
push 3
push dword [edi + 8]
lea eax, [ebp - 0xac]
lea ecx, [ebp - 0xb0]
mov dword [ebp - 0xb0], eax
call fcn.00404030
mov dword [ebp - 4], 3
mov eax, dword [ebp - 0xb0]
mov dword [ebp - 0x770], eax
call fcn.00404a20
mov ecx, eax
test ecx, ecx
je 0x414454
mov eax, dword [ecx]
mov eax, dword [eax + 0xc]
call eax
lea esi, [eax + 0x10]
mov dword [ebp - 0x76c], esi
mov edx, dword [ebp - 0x770]
mov byte [ebp - 4], 4
test edx, edx
je 0x4142a3
test edx, 0xffff0000
jne 0x414293
movzx eax, dx
mov ecx, eax
mov dword [ebp - 0x770], eax
call fcn.00403d20
test eax, eax
je 0x4142b8
push dword [ebp - 0x770]
lea ecx, [ebp - 0x76c]
push eax
call fcn.00403330
jmp 0x4142b2
mov ecx, edx
lea esi, [ecx + 1]
mov al, byte [ecx]
inc ecx
test al, al
jne 0x414298
sub ecx, esi
jmp 0x4142a5
xor ecx, ecx
push ecx
push edx
lea ecx, [ebp - 0x76c]
call fcn.00403450
mov esi, dword [ebp - 0x76c]
mov byte [ebp - 4], 6
lea ecx, [ebp - 0xac]
mov eax, dword [ebp - 0xb0]
cmp eax, ecx
je 0x4142d5
push eax
call fcn.00471958
add esp, 4
push 0x101
push esi
lea ecx, [ebp - 0x28]
call fcn.0041cd10
mov ecx, dword [ebp - 0x778]
lea eax, [ebp - 0x28]
push eax
mov byte [ebp - 4], 7
lea ecx, [ecx + 0xb1c]
call fcn.0041c190
mov ecx, dword [ebp - 0x28]
test ecx, ecx
je 0x414317
or eax, 0xffffffff
lock xadd dword [ecx + 0x20], eax
jne 0x414317
mov ecx, dword [ebp - 0x28]
xor edx, edx
call fcn.00410410
mov dword [ebp - 0x28], 0
mov byte [ebp - 4], 8
mov ecx, dword [ebp - 0x18]
test ecx, ecx
je 0x41433c
mov eax, dword [ecx]
mov eax, dword [eax + 8]
call eax
test eax, eax
je 0x41433c
mov edx, dword [eax]
mov ecx, eax
push 1
call dword [edx]
mov dword [ebp - 4], 0xffffffff
add esi, 0xfffffff0
or eax, 0xffffffff
lock xadd dword [esi + 0xc], eax
dec eax
test eax, eax
jg 0x41435b
mov ecx, dword [esi]
push esi
mov eax, dword [ecx]
call dword [eax + 4]
mov ecx, dword [ebp - 0x778]
mov eax, dword [ecx + 0xae0]
add edi, 0x10
cmp edi, dword [eax + 0x20]
jne 0x4140d0
mov edi, dword [ebp - 0x778]
mov ecx, dword [edi + 0xae0]
mov eax, dword [ecx + 0x20]
sub eax, dword [ecx + 0x1c]
sar eax, 4
test eax, eax
je 0x4143a3
mov ecx, dword [edi + 0xb5c]
add ecx, 0x848
push 0
push 0
push 0
mov eax, dword [ecx]
call dword [eax + 8]
mov ecx, dword [edi + 0xb60]
call dword [sym.imp.DuiLib.dll_public:_class_DuiLib::CListHeaderUI____thiscall_DuiLib::CVListUI::GetHeader_void_const]
test eax, eax
je 0x4143bd
push 0
mov ecx, eax
call dword [sym.imp.DuiLib.dll_public:_int___thiscall_DuiLib::CListHeaderUI::SetSortColumn_int_]
mov esi, dword [edi + 0xae0]
mov eax, dword [esi + 0x10]
cmp dword [eax - 0xc], 0
jne 0x414426
cmp byte [0x4cb764], 0
je 0x41445e
lea ecx, [ebp - 0x788]
mov byte [0x4cb764], 0
call fcn.00417540
mov dword [ebp - 4], 9
mov ecx, dword [edi + 0xae0]
add ecx, 0x10
push eax
call fcn.0040a720
mov dword [ebp - 4], 0xffffffff
or eax, 0xffffffff
mov edx, dword [ebp - 0x788]
add edx, 0xfffffff0
lock xadd dword [edx + 0xc], eax
dec eax
test eax, eax
jg 0x414426
mov ecx, dword [edx]
push edx
mov eax, dword [ecx]
call dword [eax + 4]
mov eax, dword [edi + 0xae0]
mov ecx, edi
push dword [eax + 0x10]
call fcn.004155d0
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
mov ecx, dword [ebp - 0x14]
xor ecx, ebp
call fcn.0046be2f
mov esp, ebp
pop ebp
mov esp, ebx
pop ebx
ret
push 0x80004005
call fcn.00404ad0
mov ecx, 1
sub ecx, dword [eax - 4]
mov eax, dword [eax - 8]
sub eax, 0x104
or ecx, eax
jge 0x41447f
push 0x104
lea ecx, [esi + 0x10]
call fcn.00404530
push dword [esi + 0x10]
push 0x104
call dword [sym.imp.KERNEL32.dll_GetCurrentDirectoryW]
mov esi, dword [edi + 0xae0]
mov eax, dword [esi + 0x10]
test eax, eax
jne 0x41449e
xor ecx, ecx
jmp 0x4144b0
push dword [eax - 8]
push eax
call fcn.00474f18
mov ecx, eax
add esp, 8
test ecx, ecx
js 0x4144c9
mov eax, dword [esi + 0x10]
cmp ecx, dword [eax - 8]
jg 0x4144c9
mov dword [eax - 0xc], ecx
xor edx, edx
mov eax, dword [esi + 0x10]
mov word [eax + ecx*2], dx
jmp 0x414426
push 0x80070057
call fcn.00404ad0
int3