Function at 0x4017b0
Capabilities:
Create directory
Delete directory
Delete file
Get common file path
Move file
Set file attributes

Disassembly:
sub esp, 0x10c
push ebx
push esi
mov dword [esp + 8], ecx
push edi
mov ecx, 0x41
xor eax, eax
lea edi, [esp + 0x14]
push 0x104
rep stosd dword es:[edi], eax
lea eax, [esp + 0x18]
push eax
call dword [sym.imp.KERNEL32.dll_GetWindowsDirectoryA]
test eax, eax
jne 0x401822
lea ecx, [esp + 0x14]
push 0x104
push ecx
push eax
call dword [sym.imp.KERNEL32.dll_GetModuleFileNameA]
lea edx, [esp + 0x14]
push 0x5c
push edx
call fcn.00403060
mov edx, eax
add esp, 8
test edx, edx
jne 0x401819
lea eax, [esp + 0x14]
push 0x2f
push eax
call fcn.00403060
mov edx, eax
add esp, 8
test edx, edx
je 0x40181c
inc edx
jmp 0x401860
lea edx, [esp + 0x14]
jmp 0x401860
mov edi, str.Temp_
or ecx, 0xffffffff
xor eax, eax
lea edx, [esp + 0x14]
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
mov esi, edi
mov ebx, ecx
mov edi, edx
or ecx, 0xffffffff
repne scasb al, byte es:[edi]
mov ecx, ebx
dec edi
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, ebx
and ecx, 3
rep movsb byte es:[edi], byte [esi]
lea edi, [esp + 0x14]
or ecx, 0xffffffff
repne scasb al, byte es:[edi]
not ecx
dec ecx
lea edx, [esp + ecx + 0x14]
mov edi, str.VMinst
or ecx, 0xffffffff
xor eax, eax
push 0
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
mov eax, ecx
mov esi, edi
mov edi, edx
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
and ecx, 3
rep movsb byte es:[edi], byte [esi]
lea ecx, [esp + 0x18]
push ecx
call dword [sym.imp.KERNEL32.dll_CreateDirectoryA]
lea edx, [esp + 0x14]
push 6
push edx
call dword [sym.imp.KERNEL32.dll_SetFileAttributesA]
cmp eax, 1
jne 0x401a4a
mov edi, 0x4171ac
or ecx, 0xffffffff
xor eax, eax
lea edx, [esp + 0x14]
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
push ebp
mov esi, edi
mov ebx, ecx
mov edi, edx
or ecx, 0xffffffff
repne scasb al, byte es:[edi]
mov ecx, ebx
dec edi
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, ebx
xor ebx, ebx
and ecx, 3
rep movsb byte es:[edi], byte [esi]
lea edi, [esp + 0x18]
or ecx, 0xffffffff
repne scasb al, byte es:[edi]
mov eax, dword [0x41a484]
not ecx
dec ecx
test eax, eax
lea ebp, [esp + ecx + 0x18]
jbe 0x401951
mov dword [esp + 0x14], 0x41a58c
mov edi, dword [esp + 0x14]
or ecx, 0xffffffff
xor eax, eax
lea edx, [esp + 0x18]
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
mov eax, ecx
mov esi, edi
mov edi, ebp
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
and ecx, 3
rep movsb byte es:[edi], byte [esi]
lea ecx, [ebx + 0x6a]
push ecx
mov ecx, dword [esp + 0x14]
push edx
call fcn.00401590
lea eax, [esp + 0x18]
push 6
push eax
call dword [sym.imp.KERNEL32.dll_SetFileAttributesA]
mov edx, dword [esp + 0x14]
mov eax, dword [0x41a484]
inc ebx
add edx, 0x104
cmp ebx, eax
mov dword [esp + 0x14], edx
jb 0x4018f7
test eax, eax
je 0x401983
mov edi, 0x41a58c
or ecx, 0xffffffff
xor eax, eax
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
lea eax, [esp + 0x18]
mov edx, ecx
mov esi, edi
mov edi, ebp
push eax
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, edx
and ecx, 3
rep movsb byte es:[edi], byte [esi]
mov ecx, dword [esp + 0x14]
call fcn.004014e0
push 0xbb8
call dword [sym.imp.KERNEL32.dll_GetCurrentThread]
push eax
call dword [sym.imp.KERNEL32.dll_WaitForSingleObject]
mov eax, dword [0x41a484]
mov dword [esp + 0x10], 0
test eax, eax
jbe 0x401a12
mov ebx, 0x41a58c
mov edi, ebx
or ecx, 0xffffffff
xor eax, eax
push 0x80
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
lea eax, [esp + 0x1c]
mov edx, ecx
mov esi, edi
mov edi, ebp
push eax
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, edx
and ecx, 3
rep movsb byte es:[edi], byte [esi]
call dword [sym.imp.KERNEL32.dll_SetFileAttributesA]
lea ecx, [esp + 0x18]
push ecx
call dword [sym.imp.KERNEL32.dll_DeleteFileA]
cmp eax, 1
je 0x4019f9
push 4
lea edx, [esp + 0x1c]
push 0
push edx
call dword [sym.imp.KERNEL32.dll_MoveFileExA]
mov eax, dword [esp + 0x10]
mov ecx, dword [0x41a484]
inc eax
add ebx, 0x104
cmp eax, ecx
mov dword [esp + 0x10], eax
jb 0x4019ab
lea eax, [esp + 0x18]
push 0x80
mov byte [ebp], 0
push eax
mov byte [ebp - 1], 0
call dword [sym.imp.KERNEL32.dll_SetFileAttributesA]
lea ecx, [esp + 0x18]
push ecx
call dword [sym.imp.KERNEL32.dll_RemoveDirectoryA]
cmp eax, 1
pop ebp
je 0x401a4a
push 4
lea edx, [esp + 0x18]
push 0
push edx
call dword [sym.imp.KERNEL32.dll_MoveFileExA]
pop edi
pop esi
pop ebx
add esp, 0x10c
ret