Function at 0x491970
Capabilities:
Enumerate files on windows

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff8
push 0xffffffffffffffff
push 0x517c0d
mov eax, dword fs:[0]
push eax
sub esp, 0x280
mov eax, dword [0x573be0]
xor eax, esp
mov dword [esp + 0x278], eax
push ebx
push esi
push edi
mov eax, dword [0x573be0]
xor eax, esp
push eax
lea eax, [esp + 0x290]
mov dword fs:[0], eax
mov eax, ecx
mov dword [esp + 0x30], eax
mov ecx, dword [eax]
sub ecx, 0x10
call fcn.00420750
lea esi, [eax + 0x10]
mov dword [esp + 0x14], esi
push 0x5c
push esi
mov dword [esp + 0x2a0], 0
call fcn.004ed550
add esp, 8
or ebx, 0xffffffff
test eax, eax
je 0x491ccd
sub eax, esi
sar eax, 1
cmp eax, ebx
je 0x491ccd
push eax
lea eax, [esp + 0x20]
push eax
lea ecx, [esp + 0x1c]
call fcn.0042d780
push eax
lea ecx, [esp + 0x18]
mov byte [esp + 0x29c], 1
call fcn.004222b0
mov byte [esp + 0x298], 0
mov edx, dword [esp + 0x1c]
add edx, 0xfffffff0
mov ecx, ebx
lea eax, [edx + 0xc]
lock xadd dword [eax], ecx
dec ecx
test ecx, ecx
jg 0x491a3a
mov ecx, dword [edx]
push edx
mov eax, dword [ecx]
call dword [eax + 4]
mov esi, dword [esp + 0x14]
push 0x5c
push esi
call fcn.004ed550
mov edi, eax
add esp, 8
test edi, edi
je 0x491ccd
sub edi, esi
sar edi, 1
cmp edi, 0xffffffff
je 0x491ccd
mov eax, dword [esi - 0xc]
sub eax, edi
dec eax
push eax
lea eax, [esp + 0x30]
push eax
lea ecx, [esp + 0x1c]
call fcn.0042c680
push edi
lea eax, [esp + 0x20]
push eax
lea ecx, [esp + 0x1c]
mov byte [esp + 0x2a0], 2
call fcn.0042d780
push eax
lea ecx, [esp + 0x18]
mov byte [esp + 0x29c], 3
call fcn.004222b0
mov byte [esp + 0x298], 2
mov edx, dword [esp + 0x1c]
add edx, 0xfffffff0
mov ecx, ebx
lea eax, [edx + 0xc]
lock xadd dword [eax], ecx
dec ecx
test ecx, ecx
jg 0x491ac3
mov ecx, dword [edx]
push edx
mov eax, dword [ecx]
call dword [eax + 4]
mov esi, dword [esp + 0x14]
push 0x5c
push esi
call fcn.004ed550
mov edi, dword [esp + 0x34]
mov ecx, eax
add esp, 8
test ecx, ecx
je 0x491cac
sub ecx, esi
sar ecx, 1
cmp ecx, 0xffffffff
je 0x491cac
mov eax, dword [esi - 0xc]
sub eax, ecx
dec eax
push eax
lea eax, [esp + 0x28]
push eax
lea ecx, [esp + 0x1c]
call fcn.0042c680
push 1
push 0x54d17c
lea ecx, [esp + 0x1c]
mov byte [esp + 0x2a0], 4
call fcn.00428940
lea ecx, [esp + 0x24]
call fcn.0042c620
mov edx, str.casino
lea ecx, [esp + 0x24]
call fcn.0042c700
mov esi, dword [esp + 0x14]
test al, al
jne 0x491b4f
mov edx, str.poker
lea ecx, [esp + 0x24]
call fcn.0042c700
test al, al
je 0x491c87
lea ecx, [esi - 0x10]
call fcn.00420750
add eax, 0x10
mov dword [esp + 0x28], eax
push 0x54a834
lea ecx, [esp + 0x2c]
mov byte [esp + 0x29c], 5
call fcn.004286d0
lea eax, [esp + 0x34]
push eax
push dword [esp + 0x2c]
call dword [sym.imp.KERNEL32.dll_FindFirstFileW]
mov dword [esp + 0x1c], eax
cmp eax, 0xffffffff
je 0x491c7e
mov byte [esp + 0x1b], 0
lea eax, [esp + 0x60]
push eax
lea ecx, [esp + 0x24]
call fcn.004204a0
mov byte [esp + 0x298], 6
mov eax, dword [esp + 0x20]
mov edx, 0x54ad3c
mov ecx, eax
mov bx, word [ecx]
cmp bx, word [edx]
jne 0x491bdc
test bx, bx
je 0x491bd8
mov bx, word [ecx + 2]
cmp bx, word [edx + 2]
jne 0x491bdc
add ecx, 4
add edx, 4
test bx, bx
jne 0x491bb6
xor ecx, ecx
jmp 0x491be1
sbb ecx, ecx
or ecx, 1
test ecx, ecx
je 0x491c09
push 0x54b720
lea ecx, [esp + 0x24]
call fcn.0042c8c0
test eax, eax
je 0x491c05
push edi
lea ecx, [esp + 0x24]
call fcn.0042c8c0
test eax, eax
jne 0x491c46
mov eax, dword [esp + 0x20]
lea edx, [eax - 0x10]
or ebx, 0xffffffff
mov byte [esp + 0x298], 5
lea eax, [edx + 0xc]
mov ecx, ebx
lock xadd dword [eax], ecx
dec ecx
test ecx, ecx
jg 0x491c2d
mov ecx, dword [edx]
push edx
mov eax, dword [ecx]
call dword [eax + 4]
lea eax, [esp + 0x34]
push eax
push dword [esp + 0x20]
call dword [sym.imp.KERNEL32.dll_FindNextFileW]
test eax, eax
jne 0x491b95
jmp 0x491c5f
lea ecx, [esp + 0x20]
mov byte [esp + 0x1b], 1
mov byte [esp + 0x298], 5
call fcn.004205e0
or ebx, 0xffffffff
push dword [esp + 0x1c]
call dword [sym.imp.KERNEL32.dll_FindClose]
cmp byte [esp + 0x1b], 0
jne 0x491c7e
mov ecx, dword [esp + 0x30]
lea eax, [esp + 0x14]
push eax
call fcn.004222b0
lea ecx, [esp + 0x28]
call fcn.004205e0
mov byte [esp + 0x298], 2
mov edx, dword [esp + 0x24]
add edx, 0xfffffff0
mov ecx, ebx
lea eax, [edx + 0xc]
lock xadd dword [eax], ecx
dec ecx
test ecx, ecx
jg 0x491cac
mov ecx, dword [edx]
push edx
mov eax, dword [ecx]
call dword [eax + 4]
add edi, 0xfffffff0
mov byte [esp + 0x298], 0
lea eax, [edi + 0xc]
mov ecx, ebx
lock xadd dword [eax], ecx
dec ecx
test ecx, ecx
jg 0x491ccd
mov ecx, dword [edi]
push edi
mov eax, dword [ecx]
call dword [eax + 4]
add esi, 0xfffffff0
mov dword [esp + 0x298], 0xffffffff
lea eax, [esi + 0xc]
lock xadd dword [eax], ebx
dec ebx
test ebx, ebx
jg 0x491cef
mov ecx, dword [esi]
push esi
mov eax, dword [ecx]
call dword [eax + 4]
mov ecx, dword [esp + 0x290]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [esp + 0x278]
xor ecx, esp
call fcn.004e8f3a
mov esp, ebp
pop ebp
ret