Function at 0x40c242
Capabilities:
Enumerate files on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x464
push ebx
push esi
push edi
mov edi, dword [sym.imp.KERNEL32.dll_EnterCriticalSection]
push 0x422c08
call edi
push 0x422d18
call edi
mov esi, dword [ebp + 8]
lea eax, [ebp - 4]
push eax
lea eax, [ebp - 0xc]
mov ecx, dword [esi + 4]
push eax
lea eax, [ebp - 8]
xor ebx, ebx
push eax
mov dword [ebp - 8], ebx
mov dword [ebp - 0xc], ebx
mov dword [ebp - 4], ebx
call fcn.004015fa
mov eax, dword [ebp - 8]
push 0x40
push dword [ebp + 0xc]
mov word [esi + 0x78], ax
mov word [esi + 0x18c], ax
mov eax, dword [ebp - 4]
mov dword [esi + 0x80], eax
mov eax, dword [ebp - 0xc]
mov dword [esi + 0x7c], eax
lea eax, [esi + 0x10]
push eax
call sub.MSVCRT.dll_memcpy
mov eax, dword [ebp + 0x10]
add esp, 0xc
mov dword [esi + 0x50], eax
mov eax, dword [ebp + 0x14]
test ax, 0x3fff
jne 0x40c2ca
shr eax, 0xe
mov word [esi + 0x76], ax
jmp 0x40c2dc
shr eax, 0xe
inc eax
mov dword [esi + 0x194], 1
mov word [esi + 0x76], ax
mov ax, word [esi + 0x80]
mov ecx, dword [esi + 4]
mov edx, dword [esi + 0x190]
mov word [esi + 0x74], ax
movzx eax, word [esi + 0x18c]
shl edx, 0x14
mov eax, dword [ecx + eax*4 + 0x104]
shl eax, 0xe
cmp eax, edx
mov dword [ebp + 8], eax
ja 0x40c30e
mov dword [ebp + 8], edx
movzx edx, word [esi + 0x76]
mov eax, dword [esi + 0x80]
add edx, eax
shl edx, 0xe
cmp edx, dword [ebp + 8]
jbe 0x40c38d
mov ax, word [esi + 0x78]
push 0xa
inc ax
pop ecx
movzx eax, ax
cdq
idiv ecx
mov ecx, dword [esi + 4]
push ebx
push ebx
mov dword [esi + 0x80], ebx
mov dword [esi + 0x7c], ebx
mov word [esi + 0x74], bx
push edx
mov word [esi + 0x78], dx
mov word [esi + 0x18c], dx
call fcn.004015ff
mov ax, word [esi + 0x78]
mov ecx, dword [esi + 4]
push eax
call fcn.0040164a
test eax, eax
jne 0x40c375
movzx eax, word [esi + 0x78]
mov ecx, dword [esi]
push eax
call fcn.0040118b
test eax, eax
je 0x40c37d
push 1
pop eax
jmp 0x40c5bf
mov ecx, dword [esi]
call fcn.004019e2
test eax, eax
je 0x40c3a0
jmp 0x40c4d6
push dword [esi + 0x80]
mov ax, word [esi + 0x78]
push dword [esi + 0x7c]
push eax
call fcn.004015ff
movzx eax, word [esi + 0x18c]
lea eax, [eax + eax*2]
lea eax, [eax*8 + 0x422c28]
push eax
call edi
and byte [ebp - 0x324], 0
push 0x40
pop ecx
xor eax, eax
lea edi, [ebp - 0x323]
mov ebx, 0x422990
rep stosd dword es:[edi], eax
stosw word es:[edi], ax
stosb byte es:[edi], al
lea eax, [ebp - 0x324]
push ebx
push eax
call sub.MSVCRT.dll_strcpy
lea eax, [ebp - 0x324]
push 0x4221e4
push eax
call sub.MSVCRT.dll_strcat
and byte [ebp - 0x18], 0
xor eax, eax
lea edi, [ebp - 0x17]
push 0xa
stosd dword es:[edi], eax
stosd dword es:[edi], eax
stosb byte es:[edi], al
lea eax, [ebp - 0x18]
push eax
movzx eax, word [esi + 0x18c]
push eax
call dword [sym.imp.MSVCRT.dll__itoa]
and byte [ebp - 0x220], 0
push 0x40
pop ecx
xor eax, eax
lea edi, [ebp - 0x21f]
rep stosd dword es:[edi], eax
stosw word es:[edi], ax
stosb byte es:[edi], al
lea eax, [esi + 0x88]
push eax
lea eax, [ebp - 0x220]
push eax
call sub.MSVCRT.dll_strcpy
lea eax, [ebp - 0x18]
push eax
lea eax, [ebp - 0x220]
push eax
call sub.MSVCRT.dll_strcat
lea eax, [ebp - 0x220]
push str..che
push eax
call sub.MSVCRT.dll_strcat
and byte [ebp - 0x11c], 0
push 0x40
pop ecx
xor eax, eax
lea edi, [ebp - 0x11b]
push ebx
rep stosd dword es:[edi], eax
stosw word es:[edi], ax
stosb byte es:[edi], al
lea eax, [ebp - 0x11c]
push eax
call sub.MSVCRT.dll_strcpy
lea eax, [ebp - 0x220]
push eax
lea eax, [ebp - 0x11c]
push eax
call sub.MSVCRT.dll_strcat
add esp, 0x44
lea eax, [ebp - 0x464]
push eax
lea eax, [ebp - 0x324]
push eax
call dword [sym.imp.KERNEL32.dll_FindFirstFileA]
mov ebx, eax
cmp ebx, 0xffffffff
jne 0x40c4e0
movzx eax, word [esi + 0x18c]
mov esi, dword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
lea eax, [eax + eax*2]
lea eax, [eax*8 + 0x422c28]
push eax
call esi
push 0x422d18
call esi
push 0x422c08
call esi
mov eax, 0x80004005
jmp 0x40c5bf
lea eax, [ebp - 0x220]
push eax
lea eax, [ebp - 0x438]
push eax
call sub.MSVCRT.dll_strcmp
pop ecx
test eax, eax
pop ecx
je 0x40c50d
lea eax, [ebp - 0x464]
push eax
push ebx
call dword [sym.imp.KERNEL32.dll_FindNextFileA]
test eax, eax
je 0x40c526
jmp 0x40c4e0
mov ax, word [esi + 0x18c]
push eax
lea eax, [ebp - 0x11c]
push eax
push esi
call fcn.00401933
test eax, eax
je 0x40c58c
lea eax, [ebp - 0x11c]
push eax
push esi
call fcn.00401082
mov ax, word [esi + 0x18c]
mov ecx, dword [esi + 4]
push eax
call fcn.0040164a
movzx eax, word [esi + 0x18c]
mov ecx, dword [esi]
push eax
call fcn.0040118b
mov ax, word [esi + 0x18c]
push eax
lea eax, [ebp - 0x11c]
push eax
push esi
call fcn.00401933
test eax, eax
je 0x40c58c
movzx eax, word [esi + 0x18c]
mov esi, dword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
lea eax, [eax + eax*2]
lea eax, [eax*8 + 0x422c28]
push eax
call esi
mov edi, 0x8abc0010
jmp 0x40c5a8
movzx eax, word [esi + 0x18c]
mov esi, dword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
lea eax, [eax + eax*2]
lea eax, [eax*8 + 0x422c28]
push eax
call esi
xor edi, edi
push 0x422d18
call esi
push 0x422c08
call esi
push ebx
call dword [sym.imp.KERNEL32.dll_FindClose]
mov eax, edi
pop edi
pop esi
pop ebx
leave
ret 0x10