Function at 0x421b5f
Capabilities:
Enumerate files on windows
Resolve function by parsing pe exports

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
and esp, 0xfffffff8
sub esp, 0x2b4
mov eax, dword [0x475280]
xor eax, esp
mov dword [esp + 0x2b0], eax
mov eax, dword [ebp + 8]
push ebx
push esi
push edi
mov dword [esp + 0x1c], eax
xor esi, esi
mov eax, dword [ebp + 0xc]
mov edi, ecx
push 0x250
mov dword [esp + 0x24], eax
mov ebx, esi
lea eax, [esp + 0x6c]
mov dword [esp + 0x1c], edx
push esi
push eax
call sub.msvcrt.dll_memset
and dword [esp + 0x30], ebx
add esp, 0xc
and dword [esp + 0x10], ebx
test edi, edi
je 0x421fb0
xor eax, eax
cmp ax, word [edi]
je 0x421fb0
lea edx, [esp + 0x10]
mov ecx, edi
call fcn.004219c0
test eax, eax
je 0x421c7a
cmp dword [esp + 0x10], ebx
je 0x421c7a
and dword [esp + 0x14], ebx
test dword [ebp + 0x10], 2
jne 0x421c29
lea edx, [esp + 0x14]
mov ecx, edi
call fcn.00421b1d
test eax, eax
je 0x421c03
cmp dword [esp + 0x14], ebx
jne 0x421c7a
and dword [esp + 0x14], ebx
test dword [ebp + 0x10], 1
jne 0x421c29
lea edx, [esp + 0x14]
mov ecx, edi
call fcn.00421a30
test eax, eax
je 0x421c39
cmp dword [esp + 0x14], 0x80000008
je 0x421c7a
push 0
call dword [sym.imp.KERNEL32.dll_SetLastError]
xor eax, eax
inc eax
jmp 0x421fba
call dword [sym.imp.KERNEL32.dll_GetLastError]
lea edx, [esp + 0x10]
mov dword [esp + 0x14], eax
mov ecx, edi
call fcn.004219c0
test eax, eax
je 0x421c7a
cmp dword [esp + 0x10], ebx
je 0x421c7a
mov esi, dword [esp + 0x14]
push esi
push 0x404ea8
push 0x2000000
push 0x475b0c
call fcn.00420a7f
add esp, 0x10
push esi
jmp 0x421fb2
mov edx, 0x404f50
mov ecx, edi
call fcn.00423aa7
mov dword [esp + 0x64], eax
test eax, eax
je 0x421f56
xor edx, edx
mov ecx, eax
call fcn.00422bac
mov ebx, eax
test ebx, ebx
je 0x421f56
lea ecx, [esp + 0x68]
push ecx
push ebx
call dword [sym.imp.KERNEL32.dll_FindFirstFileW]
mov dword [esp + 0x14], eax
cmp eax, 0xffffffff
je 0x421ef9
push 0x38
lea ecx, [esp + 0x2c]
push 0
push ecx
call sub.msvcrt.dll_memset
add esp, 0xc
xor ecx, ecx
xor eax, eax
mov dword [esp + 0x10], ecx
cmp ax, word [edi]
je 0x421d9a
mov eax, dword [esp + 0x68]
lea edx, [esp + 0x94]
mov dword [esp + 0x28], eax
mov eax, dword [esp + 0x6c]
mov dword [esp + 0x2c], eax
mov eax, dword [esp + 0x70]
mov dword [esp + 0x30], eax
mov eax, dword [esp + 0x74]
mov dword [esp + 0x34], eax
mov eax, dword [esp + 0x78]
mov dword [esp + 0x38], eax
mov eax, dword [esp + 0x7c]
mov dword [esp + 0x44], ecx
mov dword [esp + 0x50], ecx
mov dword [esp + 0x54], ecx
mov dword [esp + 0x58], ecx
mov dword [esp + 0x5c], ecx
mov ecx, dword [esp + 0x84]
mov dword [esp + 0x3c], eax
mov eax, dword [esp + 0x80]
mov dword [esp + 0x40], eax
mov eax, dword [esp + 0x88]
mov dword [esp + 0x4c], ecx
mov ecx, edi
mov dword [esp + 0x48], eax
call fcn.00423aa7
mov dword [esp + 0x50], eax
test eax, eax
je 0x421d8d
push 0x5c
push eax
call dword [sym.imp.msvcrt.dll_wcsrchr]
pop ecx
pop ecx
mov ecx, dword [esp + 0x50]
test eax, eax
je 0x421d77
add eax, 2
mov dword [esp + 0x54], eax
jmp 0x421d7b
mov dword [esp + 0x54], ecx
call fcn.00422f73
mov dword [esp + 0x58], eax
test eax, eax
je 0x421d8d
xor eax, eax
inc eax
jmp 0x421da4
lea ecx, [esp + 0x28]
call fcn.00421973
mov eax, esi
jmp 0x421da8
push 0x57
call dword [sym.imp.KERNEL32.dll_SetLastError]
xor eax, eax
mov dword [esp + 0x10], eax
cmp eax, 1
jne 0x421e3b
test byte [esp + 0x28], 0x10
je 0x421e1a
cmp dword [esp + 0x18], esi
je 0x421e3b
push 0xffffffffffffffff
push dword [esp + 0x58]
push 0xffffffffffffffff
push 0x404f54
push eax
push 0x409
call dword [sym.imp.KERNEL32.dll_CompareStringW]
dec eax
sub eax, 1
je 0x421e3b
push 0xffffffffffffffff
push dword [esp + 0x58]
push 0xffffffffffffffff
push 0x404f58
push 1
push 0x409
call dword [sym.imp.KERNEL32.dll_CompareStringW]
dec eax
sub eax, 1
je 0x421e3b
push dword [esp + 0x20]
mov ecx, dword [esp + 0x1c]
lea eax, [esp + 0x2c]
push dword [esp + 0x20]
push eax
call dword [0x47744c]
call dword [esp + 0x24]
jmp 0x421e37
mov eax, dword [esp + 0x1c]
test eax, eax
je 0x421e3b
push dword [esp + 0x20]
lea ecx, [esp + 0x2c]
push ecx
mov ecx, eax
call dword [0x47744c]
call dword [esp + 0x24]
mov dword [esp + 0x10], eax
cmp dword [esp + 0x50], esi
je 0x421e5e
push dword [esp + 0x50]
push 0
call dword [sym.imp.KERNEL32.dll_GetProcessHeap]
push eax
call dword [sym.imp.KERNEL32.dll_HeapFree]
neg eax
sbb eax, eax
not eax
and dword [esp + 0x50], eax
mov eax, dword [esp + 0x58]
test eax, eax
je 0x421e76
push eax
push 0
call dword [sym.imp.KERNEL32.dll_GetProcessHeap]
push eax
call dword [sym.imp.KERNEL32.dll_HeapFree]
push 0x38
lea eax, [esp + 0x2c]
push 0
push eax
call sub.msvcrt.dll_memset
add esp, 0xc
cmp dword [esp + 0x10], 1
jne 0x421ecc
lea eax, [esp + 0x68]
push eax
push dword [esp + 0x18]
call dword [sym.imp.KERNEL32.dll_FindNextFileW]
cmp eax, 1
je 0x421ccf
call dword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 0x12
jne 0x421ebb
mov dword [esp + 0x24], 1
jmp 0x421eed
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov esi, eax
push esi
push ebx
push 0x404f60
jmp 0x421edb
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov esi, eax
push esi
push ebx
push 0x404fd0
push 0x2000000
push 0x475b0c
call fcn.00420a7f
add esp, 0x14
push dword [esp + 0x14]
call dword [sym.imp.KERNEL32.dll_FindClose]
jmp 0x421f77
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov esi, eax
push esi
push ebx
push 0x405148
push 0x2000000
push 0x475b0c
call fcn.00420a7f
mov ecx, ebx
add esp, 0x14
xor edi, edi
lea edx, [ecx + 2]
mov ax, word [ecx]
add ecx, 2
cmp ax, di
jne 0x421f21
sub ecx, edx
sar ecx, 1
cmp ecx, 0x104
jb 0x421f79
push 0x4051c0
push 0x3000000
push 0x475b0c
call fcn.00420a7f
add esp, 0xc
mov esi, 0xce
jmp 0x421f79
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov esi, eax
push esi
push edi
push 0x4050c0
push 0x2000000
push 0x475b0c
call fcn.00420a7f
add esp, 0x14
xor edi, edi
mov eax, dword [esp + 0x64]
test eax, eax
je 0x421f90
push eax
push edi
call dword [sym.imp.KERNEL32.dll_GetProcessHeap]
push eax
call dword [sym.imp.KERNEL32.dll_HeapFree]
test ebx, ebx
je 0x421fa3
push ebx
push edi
call dword [sym.imp.KERNEL32.dll_GetProcessHeap]
push eax
call dword [sym.imp.KERNEL32.dll_HeapFree]
push esi
call dword [sym.imp.KERNEL32.dll_SetLastError]
mov eax, dword [esp + 0x24]
jmp 0x421fba
push 0x57
call dword [sym.imp.KERNEL32.dll_SetLastError]
xor eax, eax
mov ecx, dword [esp + 0x2bc]
pop edi
pop esi
pop ebx
xor ecx, esp
call fcn.00471d10
mov esp, ebp
pop ebp
ret 0xc