Function at 0x40b548
Capabilities:
Enumerate files on windows
Enumerate files recursively
Get file size
Write file on windows

Disassembly:
push ebp
mov ebp, esp
mov ecx, 0x31
push 0
push 0
dec ecx
jne 0x40b550
push ebx
push esi
push edi
mov dword [ebp - 4], eax
mov eax, dword [ebp - 4]
call fcn.00403a84
mov edi, 0x41513c
xor eax, eax
push ebp
push 0x40ba89
push dword fs:[eax]
mov dword fs:[eax], esp
mov eax, 0x416b14
mov edx, 0x40baa0
call fcn.00403770
call fcn.0040799c
lea eax, [ebp - 0x154]
push eax
lea eax, [ebp - 0x158]
mov ecx, 0x40bb0c
mov edx, dword [ebp - 4]
call fcn.004038e0
mov eax, dword [ebp - 0x158]
call fcn.00403a94
push eax
call sub.kernel32.dll_FindFirstFileA
mov esi, eax
cmp esi, 0xffffffff
je 0x40ba58
lea eax, [ebp - 8]
lea edx, [ebp - 0x128]
mov ecx, 0x104
call fcn.0040387c
test byte [ebp - 0x154], 0x10
je 0x40b62f
mov eax, dword [ebp - 8]
mov edx, 0x40bb18
call fcn.004039e0
je 0x40ba43
mov eax, dword [ebp - 8]
mov edx, 0x40bb24
call fcn.004039e0
je 0x40ba43
push dword [ebp - 4]
push dword [ebp - 8]
push 0x40bb30
lea eax, [ebp - 0x15c]
mov edx, 3
call fcn.00403954
mov eax, dword [ebp - 0x15c]
call fcn.0040b548
jmp 0x40ba43
cmp word [edi], 0
jne 0x40b63b
inc dword [0x416b30]
mov eax, dword [0x416b30]
cmp eax, dword [0x416b2c]
jl 0x40ba43
lea eax, [ebp - 0x160]
push eax
mov eax, dword [ebp - 8]
call fcn.00403894
mov edx, eax
sub edx, 2
mov ecx, 3
mov eax, dword [ebp - 8]
call fcn.00403af4
mov eax, dword [ebp - 0x160]
lea edx, [ebp - 0xc]
call fcn.004053d4
mov edx, dword [0x416b08]
mov eax, dword [ebp - 0xc]
call fcn.00403b7c
test eax, eax
je 0x40b691
mov bl, 3
jmp 0x40b693
mov bl, 1
cmp bl, 3
jne 0x40b75e
mov eax, dword [0x416b04]
call fcn.00403894
test eax, eax
jne 0x40b6b1
mov bl, 2
jmp 0x40b75e
cmp dword [ebp - 0x134], 0x9600000
jbe 0x40b6c4
mov bl, 2
jmp 0x40b75e
mov eax, dword [ebp - 0xc]
mov edx, 0x40bb3c
call fcn.004039e0
jne 0x40b707
cmp dword [ebp - 0x134], 0x7530
jae 0x40b6e3
mov bl, 2
jmp 0x40b75e
lea eax, [ebp - 0x164]
mov ecx, dword [ebp - 8]
mov edx, dword [ebp - 4]
call fcn.004038e0
mov eax, dword [ebp - 0x164]
call fcn.004056c4
test al, al
jne 0x40b75e
mov bl, 2
jmp 0x40b75e
mov edx, dword [ebp - 8]
mov eax, 0x40bb48
call fcn.00403b7c
test eax, eax
je 0x40b75e
mov edx, dword [ebp - 8]
mov eax, 0x40bb58
call fcn.00403b7c
test eax, eax
jne 0x40b75e
mov edx, dword [ebp - 8]
mov eax, 0x40bb6c
call fcn.00403b7c
test eax, eax
jne 0x40b75e
mov edx, dword [ebp - 8]
mov eax, 0x40bb80
call fcn.00403b7c
test eax, eax
jne 0x40b75e
mov edx, dword [ebp - 8]
mov eax, 0x40bb98
call fcn.00403b7c
test eax, eax
jne 0x40b75e
mov bl, 2
cmp bl, 3
jne 0x40b7d8
inc word [edi]
mov edx, dword [ebp - 8]
mov eax, dword [ebp - 4]
call fcn.0040af08
test al, al
je 0x40b796
lea eax, [ebp - 0x168]
mov ecx, 0x40bb30
mov edx, dword [0x416b00]
call fcn.004038e0
mov eax, dword [ebp - 0x168]
call fcn.0040b548
push dword [0x416ae0]
push 0x40bbb0
lea edx, [ebp - 0x170]
movzx eax, word [edi]
call fcn.00405350
push dword [ebp - 0x170]
push 0x40bbbc
lea eax, [ebp - 0x16c]
mov edx, 4
call fcn.00403954
mov eax, dword [ebp - 0x16c]
call fcn.0040587c
dec word [edi]
cmp bl, 1
jne 0x40ba02
cmp dword [0x416b3c], 0x64
setl al
sub al, 1
jb 0x40b806
jne 0x40b819
mov edx, 0x40bbcc
mov eax, dword [ebp - 0xc]
call fcn.00403b7c
test eax, eax
sete byte [ebp - 0x11]
jmp 0x40b819
mov edx, 0x40bcd4
mov eax, dword [ebp - 0xc]
call fcn.00403b7c
test eax, eax
setne byte [ebp - 0x11]
cmp byte [ebp - 0x11], 0
je 0x40ba02
lea eax, [ebp - 0x174]
mov ecx, dword [ebp - 8]
mov edx, dword [ebp - 4]
call fcn.004038e0
mov eax, dword [ebp - 0x174]
lea edx, [ebp - 0x10]
call fcn.00409d34
mov eax, dword [ebp - 0x10]
call fcn.00403894
test eax, eax
jle 0x40ba02
push 0
push 0x80
push 4
push 0
push 0
push 0x40000000
mov eax, dword [0x416ad0]
call fcn.00403a94
push eax
call sub.kernel32.dll_CreateFileA_1
mov dword [0x416b58], eax
push 2
push 0
push 0
mov eax, dword [0x416b58]
push eax
call sub.kernel32.dll_SetFilePointer_1
push 0
mov eax, dword [0x416b58]
push eax
call sub.kernel32.dll_GetFileSize_1
mov dword [0x416b40], eax
cmp dword [0x416b40], 0xed800
jle 0x40b960
push 0x40bd14
lea edx, [ebp - 0x17c]
mov eax, dword [0x416b40]
call fcn.00405350
push dword [ebp - 0x17c]
push 0x40bd28
lea edx, [ebp - 0x180]
mov eax, 0xed800
call fcn.00405350
push dword [ebp - 0x180]
lea eax, [ebp - 0x178]
mov edx, 4
call fcn.00403954
mov eax, dword [ebp - 0x178]
call fcn.0041367c
push 0xc8
mov ecx, 0x40bd34
mov edx, 0x40bd44
mov eax, 0x80000002
call fcn.00406934
push 0x40bd8c
mov edx, 0x40bd44
mov ecx, 0x40bd98
mov eax, 0x80000002
call fcn.00406844
push 0
mov edx, 0x40bd44
mov ecx, 0x40bda8
mov eax, 0x80000002
call fcn.00406934
push 0
mov edx, 0x40bd44
mov ecx, 0x40bdb8
mov eax, 0x80000002
call fcn.00406934
call fcn.004035b0
cmp word [edi], 0
jne 0x40b988
push 0x40bdc8
push dword [ebp - 4]
push dword [ebp - 8]
push 0x40bdc8
push dword [ebp - 0x10]
lea eax, [ebp - 0x10]
mov edx, 5
call fcn.00403954
jmp 0x40b9c9
push 0x40bdc8
lea edx, [ebp - 0x184]
movzx eax, word [edi]
call fcn.00405350
push dword [ebp - 0x184]
push 0x40bdd4
push dword [0x416b10]
push 0x40bde0
push dword [ebp - 8]
push 0x40bdc8
push dword [ebp - 0x10]
lea eax, [ebp - 0x10]
mov edx, 8
call fcn.00403954
push 0
push 0x416b48
mov eax, dword [ebp - 0x10]
call fcn.00403894
push eax
lea eax, [ebp - 0x10]
call fcn.00403aec
push eax
mov eax, dword [0x416b58]
push eax
call sub.kernel32.dll_WriteFile_1
mov eax, dword [0x416b58]
push eax
call sub.kernel32.dll_CloseHandle_1
lea eax, [ebp - 0x10]
xor edx, edx
call fcn.00403bc4
cmp word [edi], 0
jne 0x40ba43
mov edx, 0x40bda8
mov ecx, dword [0x416b30]
mov eax, dword [0x416b68]
call fcn.00406bc4
lea eax, [ebp - 0x188]
mov ecx, dword [ebp - 8]
mov edx, dword [ebp - 4]
call fcn.004038e0
mov ecx, dword [ebp - 0x188]
mov edx, 0x40bd98
mov eax, dword [0x416b68]
call fcn.00406b18
lea eax, [ebp - 0x154]
push eax
push esi
call sub.kernel32.dll_FindNextFileA
test eax, eax
jne 0x40b5c2
push esi
call sub.kernel32.dll_FindClose
xor eax, eax
pop edx
pop ecx
pop ecx
mov dword fs:[eax], edx
push 0x40ba90
lea eax, [ebp - 0x188]
mov edx, 0xd
call fcn.00403740
lea eax, [ebp - 0x10]
mov edx, 4
call fcn.00403740
ret