Function at 0x51b0d0
Capabilities:
Check if file exists
Get file attributes

Disassembly:
push 0xffffffffffffffff
push 0x86e9d0
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
sub esp, 0x9c
push ebx
mov ebx, dword [esp + 0xb0]
push ebp
push esi
push edi
xor esi, esi
mov edi, ecx
push ebx
mov dword [esp + 0x1c], esi
call dword [sym.imp.KERNEL32.dll_GetFileAttributesW]
cmp eax, 0xffffffff
je 0x51b63b
test al, 0x10
je 0x51b22f
push ebx
lea ecx, [esp + 0x18]
call fcn.00831f5f
push str..
lea ecx, [esp + 0x18]
mov dword [esp + 0xb8], esi
call fcn.008322dc
lea ecx, [esp + 0x48]
call fcn.005f3c35
mov eax, dword [esp + 0x14]
mov byte [esp + 0xb4], 1
cmp dword [eax - 8], 0x104
jge 0x51b1d8
push esi
push eax
lea ecx, [esp + 0x50]
call fcn.005f3cfa
cmp eax, esi
je 0x51b1d8
mov bl, 2
lea ecx, [esp + 0x48]
call fcn.005f3f20
lea ecx, [esp + 0x48]
mov ebp, eax
call fcn.005f3ee3
test eax, eax
jne 0x51b1d4
mov eax, dword [esp + 0x48]
push 0x10
lea ecx, [esp + 0x4c]
call dword [eax + 0x38]
cmp eax, esi
jne 0x51b1d4
lea ecx, [esp + 0x10]
push ecx
lea ecx, [esp + 0x4c]
call fcn.005f3fef
mov eax, dword [eax]
push 1
push eax
mov ecx, edi
mov byte [esp + 0xbc], bl
call fcn.0051b0d0
lea ecx, [esp + 0x10]
mov esi, eax
mov byte [esp + 0xb4], 1
call fcn.00831eeb
test esi, esi
jle 0x51b1cd
add dword [esp + 0x18], esi
cmp esi, 0xffffffff
je 0x51b202
xor esi, esi
cmp ebp, esi
jne 0x51b168
lea ecx, [esp + 0x48]
mov byte [esp + 0xb4], 0
call fcn.005f3c74
lea ecx, [esp + 0x14]
mov dword [esp + 0xb4], 0xffffffff
call fcn.00831eeb
jmp 0x51b63b
lea ecx, [esp + 0x48]
mov byte [esp + 0xb4], 0
call fcn.005f3c74
lea ecx, [esp + 0x14]
mov dword [esp + 0xb4], 0xffffffff
call fcn.00831eeb
or eax, 0xffffffff
jmp 0x51b63f
mov edx, dword [edi + 0x1c]
mov ebp, dword [sym.imp.USER32.dll_GetParent]
push edx
call ebp
push eax
call fcn.0082dfdb
mov eax, dword [eax + 0x1c]
push eax
call ebp
push eax
call fcn.0082dfdb
mov ecx, dword [eax + 0x1c]
push ebx
push esi
push 0x71e
push ecx
call dword [sym.imp.USER32.dll_SendMessageW]
cmp eax, 2
jne 0x51b26d
mov eax, 1
jmp 0x51b63f
cmp eax, 3
jne 0x51b27c
mov eax, 0xfffffffd
jmp 0x51b63f
cmp eax, esi
je 0x51b28a
mov eax, 0xfffffffe
jmp 0x51b63f
mov eax, dword [edi + 0xfc4]
mov ecx, dword [edi + 0xfe4]
cmp eax, ecx
jl 0x51b2a2
or eax, 0xffffffff
jmp 0x51b63f
push ebx
lea ecx, [esp + 0x14]
call fcn.00617650
mov edx, dword [esp + 0x10]
mov ecx, 0x9ce3b8
push edx
mov dword [esp + 0xb8], 3
call fcn.005239e0
mov dword [esp + 0x14], eax
mov eax, dword [esp + 0x10]
push eax
mov ecx, 0x9ce3b8
call fcn.00523b00
mov ebp, dword [edi + 0xfbc]
mov dword [esp + 0x1c], eax
cmp ebp, esi
je 0x51b37a
mov eax, ebp
mov ebp, dword [ebp]
lea ecx, [esp + 0x48]
lea esi, [eax + 8]
push esi
call fcn.00831c58
mov ecx, dword [esi + 8]
lea eax, [esi + 0x10]
mov dword [esp + 0x50], ecx
mov edx, dword [esi + 0xc]
push eax
lea ecx, [esp + 0x5c]
mov byte [esp + 0xb8], 4
mov dword [esp + 0x58], edx
call fcn.00831c58
mov ecx, dword [esi + 0x18]
mov edx, dword [esi + 0x1c]
mov dword [esp + 0x60], ecx
mov dword [esp + 0x64], edx
mov eax, dword [esi + 0x20]
mov dword [esp + 0x68], eax
mov ecx, dword [esi + 0x24]
mov dword [esp + 0x6c], ecx
mov edx, dword [esp + 0x58]
push ebx
push edx
call fcn.005fc4b7
add esp, 8
test eax, eax
je 0x51b38f
lea ecx, [esp + 0x58]
mov byte [esp + 0xb4], 7
call fcn.00831eeb
lea ecx, [esp + 0x48]
mov byte [esp + 0xb4], 3
call fcn.00831eeb
test ebp, ebp
jne 0x51b2eb
xor esi, esi
cmp dword [esp + 0x14], esi
je 0x51b3cf
test byte [edi + 0xfe0], 0x10
je 0x51b627
jmp 0x51b3e4
lea ecx, [esp + 0x58]
mov byte [esp + 0xb4], 6
call fcn.00831eeb
lea ecx, [esp + 0x48]
mov byte [esp + 0xb4], 3
call fcn.00831eeb
lea ecx, [esp + 0x10]
mov dword [esp + 0xb4], 0xffffffff
call fcn.00617ec0
mov eax, 1
jmp 0x51b63f
cmp dword [esp + 0x1c], esi
je 0x51b3e4
mov eax, dword [edi + 0xfe0]
test ah, 1
je 0x51b627
mov eax, dword [0x98b454]
mov dword [esp + 0x20], eax
mov dword [esp + 0x30], eax
lea ecx, [esp + 0x20]
mov byte [esp + 0xb4], 9
call fcn.00831e73
lea ecx, [esp + 0x30]
mov dword [esp + 0x28], esi
mov dword [esp + 0x2c], esi
call fcn.00831e73
mov dword [esp + 0x40], esi
mov dword [esp + 0x44], esi
push ebx
lea ecx, [esp + 0x34]
mov byte [esp + 0xb8], 0xa
mov dword [esp + 0x2c], esi
mov dword [esp + 0x30], esi
mov dword [esp + 0x3c], 0
mov dword [esp + 0x40], 0
call fcn.00832082
lea eax, [esp + 0x30]
lea ecx, [esp + 0x20]
push eax
call fcn.00832032
push 0x5c
lea ecx, [esp + 0x34]
call fcn.00825d01
cmp eax, 0xffffffff
jle 0x51b496
inc eax
lea ecx, [esp + 0x1c]
push eax
push ecx
lea ecx, [esp + 0x38]
call fcn.00825b00
push eax
lea ecx, [esp + 0x24]
mov byte [esp + 0xb8], 0xb
call fcn.00832032
lea ecx, [esp + 0x1c]
mov byte [esp + 0xb4], 0xa
call fcn.00831eeb
lea edx, [esp + 0x7c]
push edx
push ebx
call fcn.005fc8a8
add esp, 8
cmp eax, esi
jne 0x51b4e7
mov eax, dword [esp + 0x94]
mov ecx, dword [esp + 0x98]
mov edx, dword [esp + 0xa0]
mov dword [esp + 0x28], eax
lea eax, [esp + 0x1c]
mov dword [esp + 0x2c], ecx
push eax
lea ecx, [esp + 0x74]
mov dword [esp + 0x20], edx
call fcn.005f1535
mov ecx, dword [esp + 0x70]
mov edx, dword [esp + 0x74]
mov dword [esp + 0x38], ecx
mov dword [esp + 0x3c], edx
mov eax, dword [edi + 0xfc0]
mov dword [esp + 0x18], eax
mov eax, dword [edi + 0xfc8]
cmp eax, esi
jne 0x51b53a
mov ecx, dword [edi + 0xfd0]
push 0x30
lea edx, [edi + 0xfcc]
push ecx
push edx
call fcn.0082b3f5
mov ecx, dword [edi + 0xfd0]
lea edx, [ecx + ecx*2]
shl edx, 4
dec ecx
cmp ecx, esi
lea eax, [edx + eax - 0x2c]
jl 0x51b53a
inc ecx
mov edx, dword [edi + 0xfc8]
mov dword [eax], edx
mov dword [edi + 0xfc8], eax
sub eax, 0x30
dec ecx
jne 0x51b526
mov ebp, dword [edi + 0xfc8]
mov ecx, dword [esp + 0x18]
push 1
mov eax, dword [ebp]
mov dword [edi + 0xfc8], eax
mov dword [ebp + 4], ecx
mov dword [ebp], esi
mov ecx, dword [edi + 0xfc4]
lea esi, [ebp + 8]
inc ecx
push esi
mov dword [edi + 0xfc4], ecx
call fcn.0051ebd0
lea edx, [esp + 0x20]
mov ecx, esi
push edx
call fcn.00832032
mov eax, dword [esp + 0x28]
lea edx, [esp + 0x30]
mov dword [esi + 8], eax
mov ecx, dword [esp + 0x2c]
mov dword [esi + 0xc], ecx
push edx
lea ecx, [esi + 0x10]
call fcn.00832032
mov eax, dword [esp + 0x38]
mov ecx, dword [esp + 0x3c]
mov dword [esi + 0x18], eax
mov dword [esi + 0x1c], ecx
mov edx, dword [esp + 0x40]
mov dword [esi + 0x20], edx
mov eax, dword [esp + 0x44]
mov dword [esi + 0x24], eax
mov eax, dword [edi + 0xfc0]
test eax, eax
je 0x51b5bc
mov dword [eax], ebp
jmp 0x51b5c2
mov dword [edi + 0xfbc], ebp
mov eax, dword [esp + 0xc0]
mov dword [edi + 0xfc0], ebp
test eax, eax
mov dword [esp + 0x18], 1
je 0x51b5e3
push ebp
mov ecx, edi
call fcn.0051cae0
mov ecx, dword [edi + 0x1c]
push ecx
call dword [sym.imp.USER32.dll_GetParent]
push eax
call fcn.0082dfdb
mov edx, dword [eax + 0x1c]
push ebx
push 0
push 0x71d
push edx
call dword [sym.imp.USER32.dll_SendMessageW]
lea ecx, [esp + 0x30]
mov byte [esp + 0xb4], 0xc
call fcn.00831eeb
lea ecx, [esp + 0x20]
mov byte [esp + 0xb4], 3
call fcn.00831eeb
lea ecx, [esp + 0x10]
mov dword [esp + 0xb4], 0xffffffff
call fcn.00617ec0
mov eax, dword [esp + 0x18]
mov ecx, dword [esp + 0xac]
pop edi
pop esi
pop ebp
pop ebx
mov dword fs:[0], ecx
add esp, 0xa8
ret 8