Function at 0x501800
Capabilities:
Delete directory
Delete file
Enumerate files on windows
Enumerate files recursively
Set file attributes

Disassembly:
push 0xffffffffffffffff
push 0x5cfb4c
mov eax, dword fs:[0]
push eax
sub esp, 0x2ac
mov eax, dword [0x65d4e4]
xor eax, esp
mov dword [esp + 0x2a8], eax
push ebx
push ebp
push esi
push edi
mov eax, dword [0x65d4e4]
xor eax, esp
push eax
lea eax, [esp + 0x2c0]
mov dword fs:[0], eax
mov ecx, dword [esp + 0x2d0]
xor ebp, ebp
cmp ecx, ebp
je 0x5019a5
cmp byte [ecx], 0
je 0x5019a5
mov edi, 0xf
mov eax, ecx
mov dword [esp + 0x178], edi
mov dword [esp + 0x174], ebp
mov byte [esp + 0x164], 0
lea esi, [eax + 1]
mov dl, byte [eax]
add eax, 1
test dl, dl
jne 0x501875
sub eax, esi
push eax
push ecx
lea ecx, [esp + 0x168]
call fcn.00409790
lea eax, [esp + 0x54]
push eax
lea ecx, [esp + 0x164]
mov dword [esp + 0x2cc], ebp
call fcn.00425e40
mov ecx, eax
call fcn.00426430
cmp byte [eax], 0x5c
je 0x5018c2
push 0x5c
push 1
lea ecx, [esp + 0x168]
call fcn.00406df0
push 1
push 2
lea ecx, [esp + 0xe8]
call fcn.0040b040
push 0x5f42d8
lea ecx, [esp + 0x164]
push ecx
lea edx, [esp + 0xe8]
push edx
mov byte [esp + 0x2d4], 1
call fcn.00409240
add esp, 8
push eax
call fcn.00409b60
add esp, 8
lea eax, [esp + 0x38]
push eax
lea ecx, [esp + 0xe4]
call fcn.004094f0
mov ebx, 0x10
cmp dword [eax + 0x18], ebx
jb 0x501920
mov eax, dword [eax + 4]
jmp 0x501923
add eax, 4
lea ecx, [esp + 0x17c]
push ecx
push eax
call dword [sym.imp.KERNEL32.dll_FindFirstFileA]
cmp dword [esp + 0x50], ebx
mov esi, eax
mov dword [esp + 0x14], esi
jb 0x50194b
mov edx, dword [esp + 0x3c]
push edx
call fcn.00595eb8
add esp, 4
cmp esi, 0xffffffff
mov dword [esp + 0x50], edi
mov dword [esp + 0x4c], ebp
mov byte [esp + 0x3c], 0
jne 0x5019d2
lea ecx, [esp + 0x12c]
mov byte [esp + 0x2c8], 0
call fcn.00409e00
lea eax, [esp + 0x12c]
push eax
mov dword [esp + method.std::ios_base.virtual_0], vtable.std::ios_base.0
call fcn.005cdcde
add esp, 4
cmp dword [esp + 0x178], ebx
jb 0x5019a5
mov ecx, dword [esp + 0x164]
push ecx
call fcn.00595eb8
add esp, 4
mov eax, 1
mov ecx, dword [esp + 0x2c0]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebp
pop ebx
mov ecx, dword [esp + 0x2a8]
xor ecx, esp
call fcn.005b1988
add esp, 0x2b8
ret
mov ebp, dword [sym.imp.KERNEL32.dll_Sleep]
push 1
push 2
lea ecx, [esp + 0x68]
call fcn.0040b040
lea edx, [esp + 0x1a8]
push edx
lea eax, [esp + 0x164]
push eax
lea ecx, [esp + 0x68]
push ecx
mov byte [esp + 0x2d4], 2
call fcn.00409240
add esp, 8
push eax
call fcn.00409b60
mov edx, dword [esp + 0x184]
and edx, ebx
add esp, 8
cmp dl, bl
jne 0x501ab3
mov edi, 0x5f42e0
lea esi, [esp + 0x1a8]
mov ecx, 2
xor eax, eax
repe cmpsb byte [esi], byte es:[edi]
je 0x501a92
mov edi, 0x5f42dc
lea esi, [esp + 0x1a8]
mov ecx, 3
xor edx, edx
repe cmpsb byte [esi], byte es:[edi]
je 0x501a92
lea eax, [esp + 0x1c]
push eax
lea ecx, [esp + 0x64]
call fcn.004094f0
cmp dword [eax + 0x18], ebx
mov byte [esp + 0x2c8], 3
jb 0x501a72
mov eax, dword [eax + 4]
jmp 0x501a75
add eax, 4
push eax
call fcn.00501800
add esp, 4
cmp dword [esp + 0x34], ebx
jb 0x501b23
mov ecx, dword [esp + 0x20]
push ecx
jmp 0x501b1b
lea ecx, [esp + 0xac]
mov byte [esp + 0x2c8], 1
call fcn.00409e00
lea edx, [esp + 0xac]
push edx
jmp 0x501b3f
push 1
call ebp
lea eax, [esp + 0x1c]
push eax
lea ecx, [esp + 0x64]
call fcn.004094f0
cmp dword [eax + 0x18], ebx
jb 0x501acf
mov eax, dword [eax + 4]
jmp 0x501ad2
add eax, 4
push 0
push eax
call dword [sym.imp.KERNEL32.dll_SetFileAttributesA]
cmp dword [esp + 0x34], ebx
jb 0x501aee
mov ecx, dword [esp + 0x20]
push ecx
call fcn.00595eb8
add esp, 4
lea edx, [esp + 0x1c]
push edx
lea ecx, [esp + 0x64]
call fcn.004094f0
cmp dword [eax + 0x18], ebx
jb 0x501b06
mov eax, dword [eax + 4]
jmp 0x501b09
add eax, 4
push eax
call dword [sym.imp.KERNEL32.dll_DeleteFileA]
cmp dword [esp + 0x34], ebx
jb 0x501b23
mov eax, dword [esp + 0x20]
push eax
call fcn.00595eb8
add esp, 4
lea ecx, [esp + 0xac]
mov byte [esp + 0x2c8], 1
call fcn.00409e00
lea ecx, [esp + 0xac]
push ecx
mov dword [esp + 0xb0], vtable.std::ios_base.0
call fcn.005cdcde
mov esi, dword [esp + 0x18]
add esp, 4
lea edx, [esp + 0x17c]
push edx
push esi
call dword [sym.imp.KERNEL32.dll_FindNextFileA]
test eax, eax
jne 0x5019d8
push esi
call dword [sym.imp.KERNEL32.dll_FindClose]
mov ecx, dword [esp + 0x178]
cmp ecx, ebx
mov edi, dword [esp + 0x164]
mov eax, edi
jae 0x501b8f
lea eax, [esp + 0x164]
mov edx, dword [esp + 0x174]
lea esi, [eax + edx]
test esi, esi
je 0x501bc1
cmp ecx, ebx
mov eax, edi
jae 0x501baa
lea eax, [esp + 0x164]
cmp eax, esi
ja 0x501bc1
cmp ecx, ebx
mov eax, edi
jae 0x501bbb
lea eax, [esp + 0x164]
add eax, edx
cmp esi, eax
jbe 0x501bc6
call fcn.005b1933
push 1
lea ecx, [esp + 0x58]
lea eax, [esp + 0x164]
push ecx
lea ecx, [esp + 0x1c]
mov dword [esp + 0x1c], eax
mov dword [esp + 0x20], esi
call fcn.00500200
mov edx, dword [eax + 4]
mov eax, dword [eax]
push edx
push eax
lea ecx, [esp + 0x1c]
push ecx
lea ecx, [esp + 0x16c]
call fcn.00500240
cmp dword [esp + 0x178], ebx
mov eax, dword [esp + 0x164]
jae 0x501c14
lea eax, [esp + 0x164]
push eax
call dword [sym.imp.KERNEL32.dll_RemoveDirectoryA]
lea ecx, [esp + 0x12c]
mov esi, eax
mov byte [esp + 0x2c8], 0
call fcn.00409e00
lea edx, [esp + 0x12c]
push edx
mov dword [esp + method.std::ios_base.virtual_0], vtable.std::ios_base.0
call fcn.005cdcde
add esp, 4
cmp dword [esp + 0x178], ebx
jb 0x501c65
mov eax, dword [esp + 0x164]
push eax
call fcn.00595eb8
add esp, 4
mov eax, esi
jmp 0x5019aa