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

Disassembly:
mov eax, 0x1c54
call fcn.00439c50
mov eax, dword [0x483ca0]
xor eax, esp
mov dword [esp + 0x1c50], eax
push esi
mov esi, dword [esp + 0x1c60]
push edi
mov edi, dword [esp + 0x1c60]
test edi, edi
je 0x40da4f
cmp byte [edi], 0
je 0x40da4f
push ebp
push edi
lea eax, [esp + 0x260]
push str._s
push eax
call fcn.0043a459
push 0x200
lea eax, [esp + 0x46c]
push eax
lea eax, [esp + 0x270]
push eax
call fcn.0040fa60
add esp, 0x18
lea eax, [esp + 0xc]
push eax
lea eax, [esp + 0x460]
push eax
call dword [sym.imp.KERNEL32.dll_FindFirstFileW]
mov ebp, eax
cmp ebp, 0xffffffff
jne 0x40d852
push 0x200
lea eax, [esp + 0x860]
push eax
push edi
call fcn.0040fa60
add esp, 0xc
lea eax, [esp + 0x85c]
push eax
call dword [sym.imp.KERNEL32.dll_RemoveDirectoryW]
pop ebp
pop edi
xor al, al
pop esi
mov ecx, dword [esp + 0x1c50]
xor ecx, esp
call fcn.004396df
add esp, 0x1c54
ret
push ebx
mov ecx, 0x463db4
lea eax, [esp + 0x3c]
lea esp, [esp]
mov dx, word [eax]
cmp dx, word [ecx]
jne 0x40d886
test dx, dx
je 0x40d882
mov dx, word [eax + 2]
cmp dx, word [ecx + 2]
jne 0x40d886
add eax, 4
add ecx, 4
test dx, dx
jne 0x40d860
xor eax, eax
jmp 0x40d88b
sbb eax, eax
or eax, 1
test eax, eax
je 0x40d976
mov eax, 0x463db8
lea ecx, [esp + 0x3c]
lea esp, [esp]
mov dx, word [ecx]
cmp dx, word [eax]
jne 0x40d8c6
test dx, dx
je 0x40d8c2
mov dx, word [ecx + 2]
cmp dx, word [eax + 2]
jne 0x40d8c6
add ecx, 4
add eax, 4
test dx, dx
jne 0x40d8a0
xor eax, eax
jmp 0x40d8cb
sbb eax, eax
or eax, 1
test eax, eax
je 0x40d976
push 0x200
lea eax, [esp + 0x864]
push eax
lea eax, [esp + 0x44]
push eax
call fcn.0040f9f0
lea eax, [esp + 0x86c]
push eax
push edi
lea eax, [esp + 0x274]
push 0x461410
push eax
call fcn.0043a459
push 0x200
lea eax, [esp + 0x480]
push eax
lea eax, [esp + 0x284]
push eax
call fcn.0040fa60
mov ebx, dword [esp + 0x38]
lea eax, [esp + 0x488]
add esp, 0x28
and ebx, 0xfffffff8
push ebx
push eax
call dword [sym.imp.KERNEL32.dll_SetFileAttributesW]
test bl, 0x10
je 0x40d94e
lea eax, [esp + 0x260]
push esi
push eax
call fcn.0040d790
add esp, 8
lea eax, [esp + 0x260]
push esi
push eax
call fcn.00439380
add esp, 8
test eax, eax
je 0x40d968
cmp byte [esi], 0
jne 0x40d976
lea eax, [esp + 0x460]
push eax
call dword [sym.imp.KERNEL32.dll_DeleteFileW]
lea eax, [esp + 0x10]
push eax
push ebp
call dword [sym.imp.KERNEL32.dll_FindNextFileW]
test eax, eax
jne 0x40d853
push ebp
call dword [sym.imp.KERNEL32.dll_FindClose]
push 0x200
lea eax, [esp + 0xc64]
push eax
push edi
call fcn.0040fa60
add esp, 0xc
lea eax, [esp + 0xc60]
push eax
call dword [sym.imp.KERNEL32.dll_RemoveDirectoryW]
push 0
push 0x400
lea eax, [esp + 0x1468]
push eax
push 0
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push 0
push 0x1000
call dword [sym.imp.KERNEL32.dll_FormatMessageW]
push 0x400
lea eax, [esp + 0x1064]
push eax
lea eax, [esp + 0x1468]
push eax
call fcn.0040f9f0
add esp, 0xc
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
mov esi, eax
push esi
call fcn.004031d0
push eax
push esi
lea eax, [esp + 0x106c]
push eax
push edi
push str.End_of_RemoveAllFile:_path___s___s__error_code:__d__error:__s
push 0xb31
push 0x46360c
push 3
push str.Utility::RemoveAllFile
push dword [0x4868e8]
call fcn.0040a4c0
add esp, 0x2c
mov al, 1
pop ebx
pop ebp
pop edi
pop esi
mov ecx, dword [esp + 0x1c50]
xor ecx, esp
call fcn.004396df
add esp, 0x1c54
ret
mov ecx, dword [esp + 0x1c58]
xor al, al
pop edi
pop esi
xor ecx, esp
call fcn.004396df
add esp, 0x1c54
ret