Function at 0x40caad
Capabilities:
Check if file exists
Delete directory
Enumerate files on windows
Get disk information
Move file

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x2b4
push ebx
push esi
push edi
mov edi, dword [ebp + 8]
mov ebx, ecx
mov ecx, edi
mov dword [ebp - 0x14], ebx
call fcn.004014ae
mov eax, dword [edi + 0x22c]
add eax, 0x870
push eax
call fcn.0041bbf9
call fcn.0043d5bb
push eax
lea ecx, [ebp - 0x1c]
call fcn.0043bbe8
mov esi, dword [ebp + 0xc]
test byte [esi + 0x28], 1
je 0x40cb5f
mov eax, dword [edi + 0x22c]
lea ecx, [ebp - 0x60]
add eax, 0x870
push eax
call fcn.00403e75
push ecx
push dword [ebx + 4]
lea ecx, [ebp - 0x60]
call fcn.00431740
xor ecx, ecx
inc ecx
cmp eax, ecx
je 0x40cb29
lea ecx, [ebp - 0x60]
call fcn.00404a25
mov ebx, 0x800704c7
jmp 0x40d1e1
mov ebx, dword [ebp - 0x34]
mov dword [ebp - 0x18], ebx
cmp dword [ebp - 0x38], ebx
je 0x40cb46
push 2
pop eax
cmp dword [ebp - 0x38], eax
je 0x40cb43
mov dword [ebp - 0x18], ecx
cmp ebx, eax
jne 0x40cb46
mov dword [ebp - 0x18], eax
lea eax, [ebp - 0x40]
push eax
lea ecx, [ebp - 0x1c]
call fcn.0043c5cb
lea ecx, [ebp - 0x60]
call fcn.00404a25
mov ebx, dword [ebp - 0x14]
jmp 0x40cb65
mov eax, dword [ebp + 8]
mov dword [ebp - 0x18], eax
mov ecx, dword [esi + 0x2c]
sub ecx, 0x10
call fcn.0043cad2
add eax, 0x10
lea ecx, [ebp - 0xc]
mov dword [ebp - 0xc], eax
mov eax, dword [eax - 0xc]
dec eax
push eax
call fcn.0043b8a7
push 0x5c
pop ecx
cmp ax, cx
je 0x40cb94
push ecx
lea ecx, [ebp - 0xc]
call fcn.0043c971
call fcn.0043d5bb
push eax
lea ecx, [ebp - 4]
call fcn.0043bbe8
test byte [esi + 0x28], 2
je 0x40cd0c
push str.ck_W_h
call sym.Dismx86.exe_DismMultiLanguage
push eax
mov ecx, edi
call fcn.0047ee05
mov ecx, dword [edi + 0x22c]
mov esi, 0x870
add ecx, esi
call fcn.0044ccce
push eax
mov eax, dword [edi + 0x22c]
add eax, esi
push eax
push dword [0x4ad284]
call dword [sym.imp.SHLWAPI.dll_StrCmpNIW]
test eax, eax
jne 0x40cc15
push 0x10
push 0x48f30c
call sym.Dismx86.exe_DismMultiLanguage
push eax
push 0x49252c
call sym.Dismx86.exe_DismMultiLanguage
push eax
push dword [ebx + 4]
call dword [sym.imp.USER32.dll_MessageBoxW]
mov ebx, 0x80004005
jmp 0x40d1cb
mov eax, dword [edi + 0x22c]
lea ecx, [ebp + 8]
add eax, esi
push eax
call fcn.0043c2b8
push 0x5c
lea ecx, [ebp + 8]
call fcn.0043c971
mov esi, dword [ebp + 8]
xor eax, eax
push eax
push eax
push eax
push eax
push eax
mov word [ebp - 0x270], ax
lea eax, [ebp - 0x270]
push 0x105
push eax
push esi
call dword [sym.imp.KERNEL32.dll_GetVolumeInformationW]
mov eax, dword [edi + 0x22c]
push ecx
mov ecx, esp
add eax, 0x870
push eax
push str.Format.com__s__FS:NTFS__Q__X__Y
push ecx
call fcn.0044af44
add esp, 0xc
xor dl, dl
xor ecx, ecx
call fcn.0044b9b6
mov ebx, eax
pop ecx
test ebx, ebx
je 0x40cce7
mov eax, dword [edi + 0x22c]
push ebx
add eax, 0x870
push eax
push 0x4925a8
call sym.Dismx86.exe_DismMultiLanguage
push eax
lea eax, [ebp + 8]
push eax
call fcn.0044af44
add esp, 0x10
mov edi, eax
push 0x10
push 0x48f30c
call sym.Dismx86.exe_DismMultiLanguage
push eax
mov eax, dword [ebp - 0x14]
push dword [edi]
push dword [eax + 4]
call dword [sym.imp.USER32.dll_MessageBoxW]
mov ecx, dword [ebp + 8]
lea ecx, [ecx - 0x10]
call fcn.0043d912
test ebx, ebx
jle 0x40ccda
movzx ebx, bx
or ebx, 0x80070000
lea ecx, [esi - 0x10]
call fcn.0043d912
jmp 0x40d1cb
cmp word [ebp - 0x270], 0
je 0x40ccff
lea eax, [ebp - 0x270]
push eax
push esi
call dword [sym.imp.KERNEL32.dll_SetVolumeLabelW]
lea ecx, [esi - 0x10]
call fcn.0043d912
jmp 0x40cf8e
push str.Windows
lea edx, [ebp - 0xc]
lea ecx, [ebp - 8]
call fcn.0043baed
pop ecx
push dword [eax]
call dword [sym.imp.SHLWAPI.dll_PathFileExistsW]
mov ecx, dword [ebp - 8]
mov esi, eax
add ecx, 0xfffffff0
call fcn.0043d912
test esi, esi
je 0x40cf8e
push str.Windows.old_
lea edx, [ebp - 0xc]
lea ecx, [ebp - 8]
call fcn.0043baed
pop ecx
push eax
lea ecx, [ebp - 4]
call fcn.0043c5cb
mov ecx, dword [ebp - 8]
lea ecx, [ecx - 0x10]
call fcn.0043d912
xor edi, edi
lea eax, [ebp - 8]
inc edi
push edi
push str.Windows.old._.3d_
push eax
call fcn.0044af44
add esp, 0xc
lea edx, [ebp - 0xc]
lea ecx, [ebp - 0x10]
push eax
call fcn.00431d91
pop ecx
push eax
lea ecx, [ebp - 4]
call fcn.0043c5cb
mov ecx, dword [ebp - 0x10]
lea ecx, [ecx - 0x10]
call fcn.0043d912
mov ecx, dword [ebp - 8]
lea ecx, [ecx - 0x10]
call fcn.0043d912
mov ebx, dword [sym.imp.KERNEL32.dll_CreateDirectoryW]
jmp 0x40cdf8
call dword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 0xb7
jne 0x40ceb0
inc edi
lea eax, [ebp - 8]
push edi
push str.Windows.old._.3d_
push eax
call fcn.0044af44
add esp, 0xc
lea edx, [ebp - 0xc]
lea ecx, [ebp - 0x10]
push eax
call fcn.00431d91
pop ecx
push eax
lea ecx, [ebp - 4]
call fcn.0043c5cb
mov ecx, dword [ebp - 0x10]
lea ecx, [ecx - 0x10]
call fcn.0043d912
mov ecx, dword [ebp - 8]
lea ecx, [ecx - 0x10]
call fcn.0043d912
mov esi, dword [ebp - 4]
push 0
push esi
call ebx
test eax, eax
je 0x40cda8
push 0x2a
lea edx, [ebp - 0xc]
lea ecx, [ebp - 0x10]
call fcn.00431d08
pop ecx
lea ecx, [ebp - 0x2b0]
push ecx
push dword [eax]
call dword [sym.imp.KERNEL32.dll_FindFirstFileW]
mov ecx, dword [ebp - 0x10]
mov edi, eax
mov dword [ebp - 8], edi
lea ecx, [ecx - 0x10]
call fcn.0043d912
cmp edi, 0xffffffff
je 0x40cf71
mov ebx, dword [sym.imp.SHLWAPI.dll_StrCmpIW]
test byte [ebp - 0x2b0], 0x10
je 0x40ceba
lea ecx, [ebp - 0x284]
call fcn.0044cdbe
test al, al
jne 0x40cf5b
push str._RECYCLE.BIN
mov eax, ecx
push eax
call ebx
test eax, eax
je 0x40cf5b
push str.System_Volume_Information
lea eax, [ebp - 0x284]
push eax
call ebx
test eax, eax
je 0x40cf5b
push str.Boot
lea eax, [ebp - 0x284]
push eax
call ebx
test eax, eax
je 0x40cf5b
push 0xb
push str.Windows.old
lea eax, [ebp - 0x284]
push eax
call dword [sym.imp.SHLWAPI.dll_StrCmpNIW]
jmp 0x40cf02
mov ebx, 0x80070005
jmp 0x40d1ce
push str.bootmgr
lea eax, [ebp - 0x284]
push eax
call ebx
test eax, eax
je 0x40cf5b
push str.pagefile.sys
lea eax, [ebp - 0x284]
push eax
call ebx
test eax, eax
je 0x40cf5b
push str.swapfile.sys
lea eax, [ebp - 0x284]
push eax
call ebx
test eax, eax
je 0x40cf5b
push str.hiberfil.sys
lea eax, [ebp - 0x284]
push eax
call ebx
test eax, eax
je 0x40cf5b
lea eax, [ebp - 0x284]
push eax
lea edx, [ebp - 4]
lea ecx, [ebp - 0x20]
call fcn.0043baed
pop ecx
lea edx, [ebp - 0xc]
lea ecx, [ebp - 0x10]
mov ebx, dword [eax]
lea eax, [ebp - 0x284]
push eax
call fcn.0043baed
pop ecx
push 0
push ebx
push dword [eax]
call dword [sym.imp.KERNEL32.dll_MoveFileExW]
mov ecx, dword [ebp - 0x10]
mov ebx, eax
add ecx, 0xfffffff0
call fcn.0043d912
mov ecx, dword [ebp - 0x20]
add ecx, 0xfffffff0
call fcn.0043d912
test ebx, ebx
je 0x40cfcf
mov ebx, dword [sym.imp.SHLWAPI.dll_StrCmpIW]
lea eax, [ebp - 0x2b0]
push eax
push edi
call dword [sym.imp.KERNEL32.dll_FindNextFileW]
test eax, eax
jne 0x40ce40
push esi
call dword [sym.imp.SHLWAPI.dll_PathIsDirectoryEmptyW]
test eax, eax
je 0x40cf83
push esi
call dword [sym.imp.KERNEL32.dll_RemoveDirectoryW]
lea ecx, [ebp - 8]
call fcn.00439a21
mov edi, dword [ebp + 8]
push str.ck_W_e
call sym.Dismx86.exe_DismMultiLanguage
push eax
mov ecx, edi
call fcn.0047ee05
mov esi, dword [ebp + 0xc]
push edi
push ecx
push dword [ebp - 0xc]
mov eax, dword [esi + 0x28]
mov edx, dword [esi + 0x34]
and eax, 0xfffffffc
mov ecx, dword [esi + 0x24]
push eax
call fcn.0040ca01
cmp dword [edi + 0x238], 0
mov ebx, eax
je 0x40d028
mov ebx, 0x800704c7
jmp 0x40d1cb
xor ecx, ecx
call fcn.0044cca7
mov ebx, eax
lea eax, [ebp - 0x284]
push eax
push 0x4926fc
call sym.Dismx86.exe_DismMultiLanguage
push eax
lea eax, [ebp + 8]
push eax
call fcn.0044af44
add esp, 0xc
mov edi, eax
push 0x30
push 0x48f30c
call sym.Dismx86.exe_DismMultiLanguage
push eax
mov eax, dword [ebp - 0x14]
push dword [edi]
push dword [eax + 4]
call dword [sym.imp.USER32.dll_MessageBoxW]
mov ecx, dword [ebp + 8]
lea ecx, [ecx - 0x10]
call fcn.0043d912
lea ecx, [ebp - 8]
call fcn.00439a21
jmp 0x40d03d
test ebx, ebx
je 0x40d129
test byte [esi + 0x28], 2
mov esi, dword [ebp - 4]
jne 0x40d0f2
cmp dword [esi - 0xc], 0
je 0x40d0f2
push 0x2a
lea edx, [ebp - 4]
lea ecx, [ebp + 8]
call fcn.00431d08
pop ecx
lea ecx, [ebp - 0x2b0]
push ecx
push dword [eax]
call dword [sym.imp.KERNEL32.dll_FindFirstFileW]
mov ecx, dword [ebp + 8]
mov edi, eax
add ecx, 0xfffffff0
mov dword [ebp + 0xc], edi
call fcn.0043d912
cmp edi, 0xffffffff
je 0x40d0f2
mov esi, edi
lea eax, [ebp - 0x284]
push eax
lea edx, [ebp - 0xc]
lea ecx, [ebp - 8]
call fcn.0043baed
pop ecx
lea edx, [ebp - 4]
lea ecx, [ebp - 0x20]
mov edi, dword [eax]
lea eax, [ebp - 0x284]
push eax
call fcn.0043baed
pop ecx
push 1
push edi
push dword [eax]
call dword [sym.imp.KERNEL32.dll_MoveFileExW]
mov ecx, dword [ebp - 0x20]
lea ecx, [ecx - 0x10]
call fcn.0043d912
mov ecx, dword [ebp - 8]
lea ecx, [ecx - 0x10]
call fcn.0043d912
lea eax, [ebp - 0x2b0]
push eax
push esi
call dword [sym.imp.KERNEL32.dll_FindNextFileW]
test eax, eax
jne 0x40d07b
push esi
call dword [sym.imp.KERNEL32.dll_FindClose]
mov esi, dword [ebp - 4]
push esi
call dword [sym.imp.SHLWAPI.dll_PathIsDirectoryEmptyW]
test eax, eax
je 0x40d0f2
push esi
call dword [sym.imp.KERNEL32.dll_RemoveDirectoryW]
mov edx, ebx
lea ecx, [ebp - 0x10]
call fcn.0043c2ea
push 0x10
push 0x48f30c
mov edi, eax
call sym.Dismx86.exe_DismMultiLanguage
push eax
mov eax, dword [ebp - 0x14]
push dword [edi]
push dword [eax + 4]
call dword [sym.imp.USER32.dll_MessageBoxW]
mov ecx, dword [ebp - 0x10]
lea ecx, [ecx - 0x10]
call fcn.0043d912
jmp 0x40d1ce
lea eax, [ebp - 0x24]
mov ebx, 0x870
push eax
mov eax, dword [edi + 0x22c]
add eax, ebx
push eax
call sym.Dismx86.exe_DismGetSystemInfoByPath
mov ecx, dword [edi + 0x22c]
mov eax, dword [ebp - 0x24]
push ecx
mov dword [edi + 0x22c], eax
mov dword [ebp - 0x24], ecx
call dword [sym.imp.OLEAUT32.dll_SysStringLen]
test byte [esi + 0x28], 1
je 0x40d1c9
push 0x492740
call sym.Dismx86.exe_DismMultiLanguage
push eax
mov ecx, edi
call fcn.0047ee05
push dword [ebp - 0x18]
mov eax, dword [edi + 0x22c]
push dword [ebp - 0x1c]
add eax, ebx
push eax
call fcn.0040c090
test eax, eax
je 0x40d1c9
push eax
push 0x492750
call sym.Dismx86.exe_DismMultiLanguage
push eax
lea eax, [ebp + 8]
push eax
call fcn.0044af44
add esp, 0xc
mov esi, eax
push 0x10
push 0x4880b0
call sym.Dismx86.exe_DismMultiLanguage
push eax
mov eax, dword [ebp - 0x14]
push dword [esi]
push dword [eax + 4]
call dword [sym.imp.USER32.dll_MessageBoxW]
mov ecx, dword [ebp + 8]
lea ecx, [ecx - 0x10]
call fcn.0043d912
xor ebx, ebx
mov esi, dword [ebp - 4]
lea ecx, [esi - 0x10]
call fcn.0043d912
mov ecx, dword [ebp - 0xc]
add ecx, 0xfffffff0
call fcn.0043d912
mov ecx, dword [ebp - 0x1c]
add ecx, 0xfffffff0
call fcn.0043d912
pop edi
pop esi
mov eax, ebx
pop ebx
leave
ret 8