Function at 0x401000
Capabilities:
Get file system object information
Get graphical window text

Disassembly:
sub esp, 0x818
push ebx
push ebp
push esi
push edi
xor ebx, ebx
push 5
mov dword [esp + 0x1c], ebx
call dword [sym.imp.USER32.dll_GetDesktopWindow]
push eax
call dword [sym.imp.USER32.dll_GetWindow]
mov esi, eax
test esi, esi
je 0x4010b0
mov ebp, dword [sym.imp.USER32.dll_GetClassNameA]
push esi
call dword [sym.imp.USER32.dll_GetParent]
test eax, eax
jne 0x40109d
push esi
call dword [sym.imp.USER32.dll_IsWindowVisible]
test eax, eax
je 0x40109d
lea eax, [esp + 0x48]
push 0x80
push eax
push esi
call dword [sym.imp.USER32.dll_GetWindowTextA]
lea ecx, [esp + 0x24]
push 0x24
push ecx
push esi
call ebp
lea edi, [esp + 0x48]
or ecx, 0xffffffff
xor eax, eax
repne scasb al, byte es:[edi]
not ecx
dec ecx
je 0x40109d
lea edx, [esp + 0x24]
push str.Progman
push edx
call fcn.00404270
add esp, 8
test eax, eax
je 0x40109d
lea eax, [esp + ebx*4 + 0x1c8]
mov dword [esp + ebx*4 + 0xc8], esi
push eax
push esi
call dword [sym.imp.USER32.dll_GetWindowThreadProcessId]
inc ebx
push 2
push esi
call dword [sym.imp.USER32.dll_GetWindow]
mov esi, eax
test esi, esi
jne 0x40102f
mov dword [esp + 0x18], ebx
mov ebp, dword [esp + 0x830]
lea ecx, [esp + 0x10]
push ecx
lea edx, [esp + 0x62c]
push 0x200
push edx
mov dword [ebp], 0
call dword [0x408f04]
test eax, eax
je 0x4012f4
mov eax, dword [esp + 0x10]
shr eax, 2
je 0x4012f4
lea ecx, [esp + 0x628]
mov dword [esp + 0x20], eax
mov dword [esp + 0x14], ecx
mov edx, dword [esp + 0x14]
mov eax, dword [edx]
push eax
push 0
push 0x410
call dword [sym.imp.KERNEL32.dll_OpenProcess]
mov ebx, eax
test ebx, ebx
mov dword [esp + 0x1c], ebx
je 0x4012da
lea ecx, [esp + 0x10]
lea edx, [esp + 0x428]
push ecx
push 0x200
push edx
push ebx
call dword [0x408f00]
test eax, eax
je 0x4012da
mov eax, dword [esp + 0x10]
mov edi, 1
and al, 0xfc
cmp eax, 4
jbe 0x4012d3
lea esi, [esp + 0x42c]
mov edx, dword [esi]
lea ecx, [esp + 0x24]
push 0x24
push ecx
push edx
push ebx
call dword [0x408efc]
test eax, eax
je 0x401186
mov ecx, dword [esp + 0x82c]
lea eax, [esp + 0x24]
push eax
push ecx
call fcn.00404270
add esp, 8
test eax, eax
je 0x40119a
mov edx, dword [esp + 0x10]
inc edi
shr edx, 2
add esi, 4
cmp edi, edx
jb 0x401158
jmp 0x4012d3
mov ecx, dword [esp + 0x428]
lea eax, [esp + 0x48]
push 0x80
push eax
push ecx
push ebx
call dword [0x408ef8]
mov eax, dword [esp + 0x834]
test eax, eax
je 0x4011e7
mov edx, dword [ebp]
lea edi, [esp + 0x48]
shl edx, 7
add edx, eax
or ecx, 0xffffffff
xor eax, eax
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
mov eax, ecx
mov esi, edi
mov edi, edx
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
and ecx, 3
rep movsb byte es:[edi], byte [esi]
mov esi, dword [esp + 0x838]
test esi, esi
je 0x4012d0
mov eax, dword [esp + 0x83c]
test eax, eax
je 0x4012d0
mov edi, dword [esp + 0x18]
xor eax, eax
test edi, edi
jbe 0x4012d0
mov ecx, dword [esp + 0x14]
mov edx, dword [ecx]
lea ecx, [esp + 0x1c8]
cmp dword [ecx], edx
je 0x401231
inc eax
add ecx, 4
cmp eax, edi
jb 0x401220
jmp 0x4012d0
mov ebx, dword [esp + eax*4 + 0xc8]
lea edx, [esp + 0x48]
push 0x80
push edx
push ebx
call dword [sym.imp.USER32.dll_GetWindowTextA]
mov edx, dword [ebp]
lea edi, [esp + 0x48]
shl edx, 7
or ecx, 0xffffffff
xor eax, eax
add edx, esi
push 0xfffffffffffffff2
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
push ebx
mov eax, ecx
mov esi, edi
mov edi, edx
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
and ecx, 3
rep movsb byte es:[edi], byte [esi]
call dword [sym.imp.USER32.dll_GetClassLongA]
mov edx, dword [ebp]
mov ecx, dword [esp + 0x83c]
mov dword [ecx + edx*4], eax
mov eax, dword [ebp]
cmp dword [ecx + eax*4], 0
jne 0x4012cc
mov edx, dword [esp + 0x834]
push 0x100
lea ecx, [esp + 0x2cc]
push 0x160
shl eax, 7
push ecx
add eax, edx
push 0
push eax
call dword [sym.imp.SHELL32.dll_SHGetFileInfoA]
mov edx, dword [ebp]
mov ecx, dword [esp + 0x83c]
mov eax, dword [esp + 0x2c8]
mov dword [ecx + edx*4], eax
mov ebx, dword [esp + 0x1c]
inc dword [ebp]
push ebx
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov ecx, dword [esp + 0x14]
mov eax, dword [esp + 0x20]
add ecx, 4
dec eax
mov dword [esp + 0x14], ecx
mov dword [esp + 0x20], eax
jne 0x4010fa
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x818
ret