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

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x4d9e49
mov eax, dword fs:[0]
push eax
sub esp, 0x2ec
mov eax, dword [0x5176f0]
xor eax, ebp
mov dword [ebp - 0x10], eax
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
push 0x4fc918
lea ecx, [ebp - 0x48]
call fcn.00404aa0
mov dword [ebp - 4], 0
mov ecx, dword [ebp + 8]
call fcn.004041a0
push eax
call fcn.00404fc0
add esp, 4
movzx eax, al
test eax, eax
jne 0x405098
mov byte [ebp - 0x2f1], 1
mov dword [ebp - 4], 0xffffffff
lea ecx, [ebp - 0x48]
call fcn.00404250
mov al, byte [ebp - 0x2f1]
jmp 0x4052cf
mov dword [ebp - 0x29c], 0
push 0x24c
push 0
lea ecx, [ebp - 0x298]
push ecx
call fcn.004b28e0
add esp, 0xc
push 0x4fcb14
mov edx, dword [ebp + 8]
push edx
lea eax, [ebp - 0x2c]
push eax
call fcn.00402e60
add esp, 0xc
mov dword [ebp - 0x2f8], eax
lea ecx, [ebp - 0x29c]
push ecx
mov ecx, dword [ebp - 0x2f8]
call fcn.004041a0
push eax
call dword [sym.imp.KERNEL32.dll_FindFirstFileW]
mov dword [ebp - 0x4c], eax
lea ecx, [ebp - 0x2c]
call fcn.00404250
cmp dword [ebp - 0x4c], 0xffffffff
jne 0x40512d
mov ecx, dword [ebp + 8]
call fcn.004041a0
push eax
call dword [sym.imp.KERNEL32.dll_RemoveDirectoryW]
mov byte [ebp - 0x2f2], 0
mov dword [ebp - 4], 0xffffffff
lea ecx, [ebp - 0x48]
call fcn.00404250
mov al, byte [ebp - 0x2f2]
jmp 0x4052cf
lea edx, [ebp - 0x270]
push edx
lea ecx, [ebp - 0x2d4]
call fcn.00404aa0
mov byte [ebp - 4], 1
lea eax, [ebp - 0x2d4]
push eax
push 0x4fc914
call fcn.00407500
add esp, 8
movzx ecx, al
test ecx, ecx
jne 0x405179
lea edx, [ebp - 0x2d4]
push edx
push 0x4fcb1c
call fcn.00407500
add esp, 8
movzx eax, al
test eax, eax
je 0x40518d
mov byte [ebp - 4], 0
lea ecx, [ebp - 0x2d4]
call fcn.00404250
jmp 0x405290
push 0
lea ecx, [ebp - 0x2d4]
call fcn.004041a0
push eax
lea ecx, [ebp - 0x48]
call fcn.004027d0
cmp eax, 0xffffffff
jne 0x4051bc
mov byte [ebp - 4], 0
lea ecx, [ebp - 0x2d4]
call fcn.00404250
jmp 0x405290
push 0x4fcb24
mov ecx, dword [ebp + 8]
push ecx
lea edx, [ebp - 0x2b8]
push edx
call fcn.00402e60
add esp, 0xc
mov byte [ebp - 4], 2
lea eax, [ebp - 0x2d4]
push eax
lea ecx, [ebp - 0x2b8]
call fcn.004026e0
mov ecx, dword [ebp - 0x29c]
and ecx, 1
je 0x40520c
push 0x80
lea ecx, [ebp - 0x2b8]
call fcn.004041a0
push eax
call dword [sym.imp.KERNEL32.dll_SetFileAttributesW]
mov edx, dword [ebp - 0x29c]
and edx, 0x10
je 0x405228
lea eax, [ebp - 0x2b8]
push eax
call fcn.004052f0
add esp, 4
jmp 0x405272
mov ecx, dword [ebp + 8]
push ecx
lea ecx, [ebp - 0x2f0]
call fcn.004041c0
mov byte [ebp - 4], 3
lea ecx, [ebp - 0x2f0]
call fcn.004041a0
push eax
call dword [sym.imp.SHLWAPI.dll_PathRemoveFileSpecW]
lea edx, [ebp - 0x2f0]
push edx
lea eax, [ebp - 0x2b8]
push eax
call fcn.00406b70
add esp, 8
mov byte [ebp - 4], 2
lea ecx, [ebp - 0x2f0]
call fcn.00404250
mov byte [ebp - 4], 1
lea ecx, [ebp - 0x2b8]
call fcn.00404250
mov byte [ebp - 4], 0
lea ecx, [ebp - 0x2d4]
call fcn.00404250
lea ecx, [ebp - 0x29c]
push ecx
mov edx, dword [ebp - 0x4c]
push edx
call dword [sym.imp.KERNEL32.dll_FindNextFileW]
test eax, eax
jne 0x40512d
mov eax, dword [ebp - 0x4c]
push eax
call dword [sym.imp.KERNEL32.dll_FindClose]
mov byte [ebp - 0x2f3], 1
mov dword [ebp - 4], 0xffffffff
lea ecx, [ebp - 0x48]
call fcn.00404250
mov al, byte [ebp - 0x2f3]
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
mov ecx, dword [ebp - 0x10]
xor ecx, ebp
call fcn.004ae123
mov esp, ebp
pop ebp
ret