Function at 0x422790
Capabilities:
Enumerate files on windows

Disassembly:
push 0xffffffffffffffff
push 0x59a31c
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
sub esp, 0x258
mov eax, dword [0x65ca8c]
push ebx
push esi
mov ebx, ecx
mov dword [esp + 0xc], eax
mov ecx, dword [ebx + 8]
lea edx, [esp + 0xc]
push ecx
push str._stemplate.dat
push edx
mov dword [esp + 0x274], 0
call fcn.0057f8fb
mov ecx, dword [esp + 0x18]
add esp, 0xc
lea eax, [esp + 0x120]
push eax
push ecx
call dword [sym.imp.KERNEL32.dll_FindFirstFileA]
mov esi, eax
cmp esi, 0xffffffff
mov dword [esp + 0x18], esi
jne 0x42281e
lea ecx, [esp + 0xc]
mov dword [esp + 0x268], eax
call fcn.00586b33
pop esi
pop ebx
mov ecx, dword [esp + 0x258]
mov dword fs:[0], ecx
add esp, 0x264
ret
push ebp
push edi
mov edx, dword [0x65ca8c]
mov dword [esp + 0x10], edx
mov ecx, dword [ebx + 8]
lea eax, [esp + 0x154]
push eax
push ecx
lea edx, [esp + 0x18]
push 0x637020
push edx
mov byte [esp + 0x280], 1
call fcn.0057f8fb
mov eax, dword [esp + 0x20]
push 0x639060
push eax
call fcn.0056bf3f
mov ebp, eax
add esp, 0x18
test ebp, ebp
je 0x4229f1
push ebp
lea ecx, [esp + 0x2c]
push pe_nt_image_headers32
push ecx
call fcn.0056c11a
add esp, 0xc
test eax, eax
je 0x4229e4
mov ecx, 2
mov edi, str.version
lea esi, [esp + 0x28]
xor edx, edx
repe cmpsd dword [esi], dword es:[edi]
jne 0x4229e4
lea eax, [esp + 0x24]
lea ecx, [esp + 0x30]
push eax
push 0x636fe4
push ecx
call fcn.0056c333
add esp, 0xc
cmp eax, 1
jne 0x4229e4
cmp dword [esp + 0x24], 1
jne 0x4229e4
push ebp
lea edx, [esp + 0x2c]
push pe_nt_image_headers32
push edx
call fcn.0056c11a
add esp, 0xc
test eax, eax
je 0x4229e4
push ebp
lea eax, [esp + 0x2c]
push pe_nt_image_headers32
push eax
call fcn.0056c11a
add esp, 0xc
test eax, eax
je 0x4229e4
mov ecx, 5
mov edi, str.name
lea esi, [esp + 0x28]
xor edx, edx
repe cmpsb byte [esi], byte es:[edi]
jne 0x4229e4
lea eax, [esp + 0x2d]
test eax, eax
je 0x4229e4
lea ecx, [esp + 0x2d]
push 0xd
push ecx
call fcn.0056aa70
add esp, 8
test eax, eax
je 0x422937
mov byte [eax], 0
lea edx, [esp + 0x2d]
push 0xa
push edx
call fcn.0056aa70
add esp, 8
test eax, eax
je 0x42294d
mov byte [eax], 0
mov eax, dword [0x65ca8c]
mov dword [esp + 0x18], eax
mov dword [esp + 0x1c], eax
lea eax, [esp + 0x2d]
lea ecx, [esp + 0x1c]
push eax
push 0x636fa0
push ecx
mov byte [esp + 0x27c], 2
call fcn.0057f8fb
mov edx, dword [esp + 0x1c]
add esp, 0xc
lea eax, [esp + 0x18]
push edx
push 0x636fa0
push eax
call fcn.0057f8fb
mov edi, dword [ebx + 0x14]
lea esi, [ebx + 0xc]
add esp, 0xc
lea ecx, [edi + 1]
push 0xffffffffffffffff
push ecx
mov ecx, esi
call fcn.00422ce0
mov edx, dword [esi + 4]
lea eax, [esp + 0x18]
push eax
lea esi, [edx + edi*8]
mov ecx, esi
call fcn.00586c6c
lea ecx, [esp + 0x1c]
push ecx
lea ecx, [esi + 4]
call fcn.00586c6c
lea ecx, [esp + 0x1c]
mov byte [esp + 0x270], 3
call fcn.00586b33
lea ecx, [esp + 0x18]
mov byte [esp + 0x270], 1
call fcn.00586b33
push ebp
call fcn.0056bd58
mov esi, dword [esp + 0x24]
add esp, 4
lea edx, [esp + 0x128]
push edx
push esi
call dword [sym.imp.KERNEL32.dll_FindNextFileA]
test eax, eax
mov byte [esp + 0x270], 0
lea ecx, [esp + 0x10]
je 0x422a1a
call fcn.00586b33
jmp 0x422820
call fcn.00586b33
push esi
call dword [sym.imp.KERNEL32.dll_FindClose]
lea ecx, [esp + 0x14]
mov dword [esp + 0x270], 0xffffffff
call fcn.00586b33
mov ecx, dword [esp + 0x268]
pop edi
pop ebp
pop esi
pop ebx
mov dword fs:[0], ecx
add esp, 0x264
ret