Function at 0x411afd
Capabilities:
Get common file path
Get file size
Move file

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x664
push ebx
push esi
push edi
lea eax, [ebp - 0x354]
xor edi, edi
push 0x105
push eax
mov dword [ebp - 4], edi
call dword [sym.imp.KERNEL32.dll_GetSystemDirectoryA]
push dword [0x425038]
mov esi, dword [sym.imp.USER32.dll_wsprintfA]
lea eax, [ebp - 0x354]
push eax
lea eax, [ebp - 0x24c]
push str._s_s
push eax
call esi
add esp, 0x10
lea eax, [ebp - 0x24c]
push edi
push 0x10000080
push 3
push edi
push 3
push SysReAllocString
push eax
call dword [sym.imp.KERNEL32.dll_CreateFileA]
mov edi, dword [sym.imp.KERNEL32.dll_FreeLibrary]
mov ebx, eax
cmp ebx, 0xffffffff
je 0x411be9
push 0
push ebx
call dword [sym.imp.KERNEL32.dll_GetFileSize]
push ebx
mov dword [ebp - 8], eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
cmp dword [ebp - 8], 0xffffffff
je 0x411be9
cmp dword [ebp - 8], 0x4e20
jae 0x411be9
lea eax, [ebp - 0x38]
push eax
lea eax, [ebp - 0x30]
push eax
lea eax, [ebp - 0x20]
push eax
call fcn.00411db8
add esp, 0xc
mov ebx, eax
lea eax, [ebp - 0x28]
push eax
lea eax, [ebp - 0x24c]
push eax
call dword [ebp - 0x20]
test eax, eax
jne 0x411be6
lea eax, [ebp - 0x354]
push eax
lea eax, [ebp - 0x458]
push str._sodbccp32.bad
push eax
call esi
add esp, 0xc
lea eax, [ebp - 0x458]
push 3
push eax
lea eax, [ebp - 0x24c]
push eax
call dword [sym.imp.KERNEL32.dll_MoveFileExA]
push ebx
call edi
push dword [0x425038]
mov esi, dword [sym.imp.KERNEL32.dll_LoadLibraryA]
call esi
mov ebx, eax
lea eax, [ebp - 0x24c]
push eax
mov dword [ebp - 0x14], ebx
call esi
mov esi, eax
test esi, esi
mov dword [ebp - 0x18], esi
je 0x411d76
test ebx, ebx
je 0x411d76
cmp esi, ebx
je 0x411d6b
lea eax, [ebp - 0x20]
push eax
lea eax, [ebp - 0x24]
push eax
lea eax, [ebp - 0x2c]
push eax
call fcn.00411db8
add esp, 0xc
mov dword [ebp - 0x38], eax
test eax, eax
jne 0x411c47
push esi
call edi
mov eax, ebx
jmp 0x411d7a
lea eax, [ebp - 0x664]
push 0x20a
push eax
push ebx
call dword [sym.imp.KERNEL32.dll_GetModuleFileNameA]
lea eax, [ebp - 0x3c]
push eax
lea eax, [ebp - 0x24c]
push eax
call dword [ebp - 0x2c]
mov dword [ebp - 0xc], eax
lea eax, [ebp - 0x40]
push eax
lea eax, [ebp - 0x664]
push eax
call dword [ebp - 0x2c]
cmp dword [ebp - 0xc], 0
mov dword [ebp - 0x34], eax
je 0x411d60
test eax, eax
je 0x411d60
push dword [ebp - 0xc]
mov esi, dword [sym.imp.KERNEL32.dll_LocalAlloc]
push 0
call esi
push dword [ebp - 0x34]
mov dword [ebp - 0x10], eax
push 0
call esi
push dword [ebp - 0x10]
mov esi, dword [sym.imp.KERNEL32.dll_LocalLock]
mov dword [ebp - 0x1c], eax
call esi
push dword [ebp - 0x1c]
mov ebx, eax
call esi
xor esi, esi
mov dword [ebp - 8], eax
cmp ebx, esi
je 0x411d27
cmp eax, esi
je 0x411d27
push ebx
lea eax, [ebp - 0x664]
push dword [ebp - 0xc]
push esi
push eax
call dword [ebp - 0x24]
test eax, eax
je 0x411d27
push dword [ebp - 8]
lea eax, [ebp - 0x24c]
push dword [ebp - 0x34]
push esi
push eax
call dword [ebp - 0x24]
test eax, eax
je 0x411d27
lea eax, [ebp - 0xc]
mov esi, 0x425148
push eax
lea eax, [ebp - 0x30]
push eax
push esi
push ebx
call dword [ebp - 0x20]
lea eax, [ebp - 0xc]
push eax
lea eax, [ebp - 0x28]
push eax
push esi
push dword [ebp - 8]
call dword [ebp - 0x20]
push dword [ebp - 0x28]
push dword [ebp - 0x30]
call fcn.00411d8a
pop ecx
cmp al, 0x3c
pop ecx
je 0x411d7f
jle 0x411d32
cmp al, 0x3e
jg 0x411d32
mov eax, dword [ebp - 0x14]
push dword [ebp - 0x18]
mov dword [ebp - 4], eax
call edi
cmp dword [ebp - 0x10], 0
mov esi, dword [sym.imp.KERNEL32.dll_LocalUnlock]
mov ebx, dword [sym.imp.KERNEL32.dll_LocalFree]
je 0x411d4e
push dword [ebp - 0x10]
call esi
push dword [ebp - 0x10]
call ebx
cmp dword [ebp - 0x1c], 0
je 0x411d66
push dword [ebp - 0x1c]
call esi
push dword [ebp - 0x1c]
call ebx
jmp 0x411d66
push esi
mov dword [ebp - 4], ebx
call edi
push dword [ebp - 0x38]
jmp 0x411d6f
mov dword [ebp - 4], ebx
push esi
call edi
mov eax, dword [ebp - 4]
jmp 0x411d7a
mov eax, esi
or eax, ebx
pop edi
pop esi
pop ebx
leave
ret
mov eax, dword [ebp - 0x18]
push dword [ebp - 0x14]
mov dword [ebp - 4], eax
jmp 0x411d30