Function at 0x40acb8
Capabilities:
Delete file
Get common file path
Move file

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x304
push ebx
push esi
push edi
push 0
push dword [ebp + 8]
call fcn.0040b1ca
mov ebx, dword [sym.imp.KERNEL32.dll_lstrcpyA]
pop ecx
pop ecx
mov esi, eax
push dword [ebp + 8]
lea eax, [ebp - 0x304]
neg esi
sbb esi, esi
push eax
inc esi
call ebx
push 1
lea eax, [ebp - 0x304]
pop edi
push edi
push eax
call fcn.0040b02b
pop ecx
lea eax, [ebp - 0x304]
pop ecx
push dword [0x4178ac]
push eax
call dword [sym.imp.KERNEL32.dll_lstrcmpiA]
test eax, eax
jne 0x40ad18
mov dword [0x417bcc], edi
push dword [ebp + 8]
call dword [sym.imp.KERNEL32.dll_DeleteFileA]
neg eax
sbb eax, eax
inc eax
cmp dword [0x417838], 0
mov dword [ebp - 4], eax
je 0x40ad4d
test eax, eax
jne 0x40ad57
mov eax, dword [0x417ccc]
test eax, eax
je 0x40af6a
push 0
push dword [ebp + 8]
push edi
push 4
call eax
cmp dword [ebp - 4], 0
je 0x40af6a
cmp dword [0x4178e8], 0
je 0x40af6a
test esi, esi
je 0x40af6a
push dword [ebp + 8]
lea eax, [ebp - 0x104]
push eax
call ebx
lea eax, [ebp - 0x104]
push edi
push eax
call fcn.0040b02b
pop ecx
lea eax, [ebp - 0x104]
pop ecx
push dword [0x4178ac]
push eax
call dword [sym.imp.KERNEL32.dll_lstrcmpiA]
test eax, eax
je 0x40af6a
lea eax, [ebp - 0x104]
push 0
push eax
mov dword [0x417840], edi
call fcn.0040b02b
mov eax, dword [0x4177f0]
pop ecx
cmp eax, 2
pop ecx
jne 0x40ae94
lea eax, [ebp - 0x204]
push 0x100
push eax
call dword [sym.imp.KERNEL32.dll_GetWindowsDirectoryA]
mov ebx, dword [sym.imp.KERNEL32.dll_lstrlenA]
lea eax, [ebp - 0x204]
push eax
call ebx
cmp byte [ebp + eax - 0x205], 0x5c
mov esi, dword [sym.imp.KERNEL32.dll_lstrcatA]
je 0x40ae05
lea eax, [ebp - 0x204]
push 0x4140ec
push eax
call esi
lea eax, [ebp - 0x204]
push str.WININIT.INI
push eax
call esi
lea eax, [ebp - 0x204]
push edi
push eax
call dword [sym.imp.KERNEL32.dll__lopen]
mov edi, dword [sym.imp.KERNEL32.dll__lwrite]
mov esi, eax
cmp esi, 0xffffffff
jne 0x40ae4b
lea eax, [ebp - 0x204]
push 0
push eax
call dword [sym.imp.KERNEL32.dll__lcreat]
mov esi, eax
push 0xa
push str._rename__r_n
push esi
call edi
jmp 0x40ae56
push 2
push 0
push esi
call dword [sym.imp.KERNEL32.dll__llseek]
cmp esi, 0xffffffff
je 0x40af6a
lea eax, [ebp - 0x104]
push eax
lea eax, [ebp - 0x204]
push str.NUL_s_r_n
push eax
call dword [sym.imp.USER32.dll_wsprintfA]
add esp, 0xc
lea eax, [ebp - 0x204]
push eax
call ebx
push eax
lea eax, [ebp - 0x204]
push eax
push esi
call edi
jmp 0x40af63
cmp eax, edi
jne 0x40aeaa
push 4
push 0
push dword [ebp + 8]
call dword [sym.imp.KERNEL32.dll_MoveFileExA]
jmp 0x40af6a
lea eax, [ebp - 0x104]
push eax
lea eax, [ebp - 0x204]
push str.del__s_r_n
push eax
call dword [sym.imp.USER32.dll_wsprintfA]
add esp, 0xc
lea eax, [ebp - 0x104]
push 0x100
push eax
call dword [sym.imp.KERNEL32.dll_GetWindowsDirectoryA]
mov ebx, dword [sym.imp.KERNEL32.dll_lstrlenA]
lea eax, [ebp - 0x104]
push eax
call ebx
cmp byte [ebp + eax - 0x105], 0x5c
mov esi, dword [sym.imp.KERNEL32.dll_lstrcatA]
je 0x40af05
lea eax, [ebp - 0x104]
push 0x4140ec
push eax
call esi
lea eax, [ebp - 0x104]
push 0x4147fc
push eax
call esi
lea eax, [ebp - 0x104]
push edi
push eax
call dword [sym.imp.KERNEL32.dll__lopen]
mov esi, eax
cmp esi, 0xffffffff
jne 0x40af3b
lea eax, [ebp - 0x104]
push 0
push eax
call dword [sym.imp.KERNEL32.dll__lcreat]
mov esi, eax
jmp 0x40af46
push 2
push 0
push esi
call dword [sym.imp.KERNEL32.dll__llseek]
cmp esi, 0xffffffff
je 0x40af6a
lea eax, [ebp - 0x204]
push eax
call ebx
push eax
lea eax, [ebp - 0x304]
push eax
push esi
call dword [sym.imp.KERNEL32.dll__lwrite]
push esi
call dword [sym.imp.KERNEL32.dll__lclose]
mov eax, dword [ebp - 4]
pop edi
pop esi
pop ebx
leave
ret