Function at 0x518820
Capabilities:
Enumerate files on windows

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x659c52
mov eax, dword fs:[0]
push eax
sub esp, 0x280
mov eax, dword [0x758898]
xor eax, ebp
mov dword [ebp - 0x14], eax
push ebx
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov dword [ebp - 0x10], esp
mov ebx, ecx
xor esi, esi
mov dword [ebp - 4], esi
push 0x88
call fcn.005f43f8
add esp, 4
mov dword [ebp - 0x280], eax
mov byte [ebp - 4], 1
cmp eax, esi
je 0x51887c
mov ecx, eax
call fcn.0049b550
mov esi, eax
mov byte [ebp - 4], 0
mov dword [ebp - 0x288], esi
mov ecx, esi
call fcn.0049c9d0
mov eax, dword [0x75dd28]
push eax
mov ecx, dword [0x75f3d0]
push ecx
lea ecx, [esi + 0x6c]
call fcn.00401980
lea edi, [ebx + 0x14]
lea edx, [ebp - 0x288]
push edx
mov ecx, edi
call fcn.005182f0
push 0x88
call fcn.005f43f8
add esp, 4
mov dword [ebp - 0x280], eax
mov byte [ebp - 4], 2
test eax, eax
je 0x5188d9
mov ecx, eax
call fcn.0049b550
mov esi, eax
jmp 0x5188db
xor esi, esi
mov byte [ebp - 4], 0
mov dword [ebp - 0x284], esi
mov dword [esi + 0x84], 2
mov ecx, esi
call fcn.0049c9d0
mov eax, dword [0x75dd28]
push eax
mov ecx, dword [0x75f3d4]
push ecx
lea ecx, [esi + 0x6c]
call fcn.00401980
lea edx, [ebp - 0x284]
push edx
mov ecx, edi
call fcn.005182f0
cmp byte [ebx + 4], 0
je 0x51897e
xor esi, esi
mov dword [ebp - 0x20], esi
mov dword [ebp - 0x18], esi
xor eax, eax
mov word [ebp - 0x1c], ax
mov byte [ebp - 4], 3
cmp dword [ebx + 8], esi
je 0x51893b
mov eax, dword [ebx + 8]
jmp 0x51893e
lea eax, [ebx + 0xc]
push esi
push eax
push str._sq_.dt
lea ecx, [ebp - 0x20]
call fcn.004021b0
mov eax, dword [ebp - 0x20]
cmp eax, esi
jne 0x518957
lea eax, [ebp - 0x1c]
lea ecx, [ebp - 0x27c]
push ecx
push eax
call dword [sym.imp.KERNEL32.dll_FindFirstFileW]
mov edi, eax
mov dword [ebp - 0x284], edi
cmp edi, 0xffffffff
jne 0x5189a0
mov byte [ebp - 4], 0
lea ecx, [ebp - 0x20]
call fcn.00401210
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 0x14]
xor ecx, ebp
call fcn.0062016f
mov esp, ebp
pop ebp
ret
push 0x5f
lea edx, [ebp - 0x250]
push edx
call fcn.0061fc83
add esp, 8
mov esi, eax
test esi, esi
je 0x518aa2
add esi, 2
movzx eax, word [esi]
push eax
call fcn.006251c4
add esp, 4
test eax, eax
je 0x518aa2
push esi
lea ecx, [ebp - 0x2c]
call fcn.00402180
mov byte [ebp - 4], 4
mov eax, dword [ebp - 0x2c]
test eax, eax
jne 0x5189e9
lea eax, [ebp - 0x28]
push 0x2e
push eax
call fcn.00621ce0
add esp, 8
test eax, eax
je 0x518a90
xor ecx, ecx
mov word [eax], cx
mov eax, dword [ebp - 0x2c]
test eax, eax
jne 0x518a0b
lea eax, [ebp - 0x28]
push eax
call fcn.00623c9c
add esp, 4
mov edi, eax
cmp edi, 2
jle 0x518a90
push 0x88
call fcn.005f43f8
add esp, 4
mov dword [ebp - 0x288], eax
mov byte [ebp - 4], 5
test eax, eax
je 0x518a3f
mov ecx, eax
call fcn.0049b550
jmp 0x518a41
xor eax, eax
mov byte [ebp - 4], 4
mov dword [ebp - 0x280], eax
mov dword [eax + 0x84], edi
mov ecx, eax
call fcn.0049c9d0
mov esi, 2
mov dword [ebp - 0x28c], esi
cmp esi, dword [ebx + 0x1c]
jge 0x518a7e
push esi
lea ecx, [ebx + 0x14]
call fcn.00453c90
mov edx, dword [eax]
cmp edi, dword [edx + 0x84]
jl 0x518a7e
inc esi
jmp 0x518a5d
push 1
lea eax, [ebp - 0x280]
push eax
push esi
lea ecx, [ebx + 0x14]
call fcn.00518310
mov byte [ebp - 4], 3
lea ecx, [ebp - 0x2c]
call fcn.00401210
mov edi, dword [ebp - 0x284]
lea ecx, [ebp - 0x27c]
push ecx
push edi
call dword [sym.imp.KERNEL32.dll_FindNextFileW]
test eax, eax
jne 0x5189a0
push edi
call dword [sym.imp.KERNEL32.dll_FindClose]
mov byte [ebp - 4], 0
lea ecx, [ebp - 0x20]
call fcn.00401210
mov dword [ebp - 4], 0xffffffff
jmp 0x51897e