Function at 0x101294c
Capabilities:
Enumerate files on windows

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x58
mov eax, dword [0x1023018]
xor eax, ebp
mov dword [ebp - 4], eax
mov eax, dword [ebp + 8]
mov ecx, dword [ebp + 0xc]
push edi
xor edi, edi
mov dword [ebp - 0x34], eax
mov dword [ebp - 0x38], ecx
mov dword [ebp - 0x1c], edi
cmp eax, edi
jne 0x101297e
mov eax, 0x80070057
jmp 0x1012b8a
push ebx
push esi
mov esi, 0x1002fbc
push esi
lea eax, [ebp - 0x58]
push eax
call dword [sym.imp.ntdll.dll_RtlInitUnicodeString]
lea eax, [ebp - 0x58]
mov dword [ebp - 0x48], eax
lea eax, [ebp - 0x50]
push eax
push 1
lea eax, [ebp - 0x28]
push eax
mov dword [ebp - 0x50], 0x18
mov dword [ebp - 0x4c], edi
mov dword [ebp - 0x44], 0x40
mov dword [ebp - 0x40], edi
mov dword [ebp - 0x3c], edi
call dword [sym.imp.ntdll.dll_NtOpenDirectoryObject]
cmp eax, edi
jl 0x1012b65
push 0x400
push 8
mov dword [ebp - 0x30], edi
call dword [sym.imp.KERNEL32.dll_GetProcessHeap]
push eax
call dword [sym.imp.KERNEL32.dll_HeapAlloc]
mov ebx, eax
mov dword [ebp - 0x24], ebx
cmp ebx, edi
je 0x1012b11
mov byte [ebp - 0x2c], 1
mov dword [ebp - 0x20], edi
push edi
lea eax, [ebp - 0x30]
push eax
push dword [ebp - 0x2c]
push 1
push 0x400
push ebx
push dword [ebp - 0x28]
call dword [sym.imp.ntdll.dll_NtQueryDirectoryObject]
mov esi, eax
cmp esi, edi
jl 0x1012ac9
mov esi, 0x1002fa8
lea edi, [ebp - 0x18]
movsd dword es:[edi], dword [esi]
movsd dword es:[edi], dword [esi]
movsd dword es:[edi], dword [esi]
movsd dword es:[edi], dword [esi]
xor eax, eax
movsw word es:[edi], word [esi]
mov byte [ebp - 0x2c], 0
cmp ax, word [ebx]
je 0x1012ab3
mov eax, dword [ebx + 4]
test eax, eax
je 0x1012ab3
lea ecx, [ebp - 0x18]
push ecx
push eax
call fcn.01014a50
test eax, eax
je 0x1012ab3
mov ecx, dword [ebx + 4]
mov eax, ecx
lea esi, [eax + 2]
mov dx, word [eax]
inc eax
inc eax
test dx, dx
jne 0x1012a4d
sub eax, esi
sar eax, 1
cmp eax, 8
jbe 0x1012ab3
xor ebx, ebx
lea esi, [ecx + 0x10]
xor eax, eax
inc ebx
mov edi, esi
cmp ax, word [esi]
je 0x1012a94
test ebx, ebx
je 0x1012ab0
movzx eax, word [edi]
push 4
push eax
call dword [sym.imp.msvcrt.dll_iswctype]
pop ecx
pop ecx
test eax, eax
jne 0x1012a87
xor ebx, ebx
inc edi
inc edi
xor eax, eax
cmp ax, word [edi]
jne 0x1012a6f
test ebx, ebx
je 0x1012ab0
lea eax, [ebp - 0x20]
push eax
push dword [ebp - 0x38]
mov eax, dword [ebp - 0x24]
push dword [eax + 4]
push esi
call dword [sym.imp.msvcrt.dll__wtoi]
pop ecx
push eax
call dword [ebp - 0x34]
mov dword [ebp - 0x1c], eax
mov ebx, dword [ebp - 0x24]
xor edi, edi
cmp dword [ebp - 0x1c], edi
jl 0x1012b47
cmp dword [ebp - 0x20], edi
je 0x10129f0
jmp 0x1012b47
cmp esi, 0x8000001a
jne 0x1012ada
mov dword [ebp - 0x20], 1
jmp 0x1012ab5
push esi
call dword [sym.imp.ntdll.dll_RtlNtStatusToDosError]
cmp eax, edi
jle 0x1012aef
and eax, 0xffff
or eax, 0x80070000
push esi
push 0x1002fbc
push 0x1002f28
push 0x20001ec
push 0x102373c
mov dword [ebp - 0x1c], eax
call fcn.0100a7e5
add esp, 0x14
jmp 0x1012ab5
mov esi, dword [sym.imp.KERNEL32.dll_GetLastError]
call esi
cmp eax, edi
jle 0x1012b29
and eax, 0xffff
or eax, 0x80070000
cmp eax, edi
jge 0x1012b40
call esi
cmp eax, edi
jle 0x1012b3b
and eax, 0xffff
or eax, 0x80070000
mov dword [ebp - 0x1c], eax
jmp 0x1012b47
mov dword [ebp - 0x1c], 0x80004005
push dword [ebp - 0x28]
call dword [sym.imp.ntdll.dll_NtClose]
cmp ebx, edi
je 0x1012b85
push ebx
push edi
call dword [sym.imp.KERNEL32.dll_GetProcessHeap]
push eax
call dword [sym.imp.KERNEL32.dll_HeapFree]
jmp 0x1012b85
push eax
push esi
push 0x1002ea8
push 0x20001ed
push 0x102373c
mov dword [ebp - 0x1c], 0x80004005
call fcn.0100a7e5
add esp, 0x14
mov eax, dword [ebp - 0x1c]
pop esi
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
pop edi
call fcn.0100b8d5
leave
ret 8