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

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x76c
mov eax, dword [0x1003004]
push ebx
push esi
push edi
mov dword [ebp - 4], eax
push 0x105
lea eax, [ebp - 0x318]
push eax
call dword [sym.imp.KERNEL32.dll_GetSystemDirectoryA]
push dword [0x100300c]
mov esi, dword [sym.imp.USER32.dll_wsprintfA]
lea eax, [ebp - 0x318]
push eax
lea eax, [ebp - 0x210]
push 0x1001310
push eax
call esi
add esp, 0x10
push 0
push 0x10000080
push 3
push 0
push 3
push 0x80000000
lea eax, [ebp - 0x210]
push eax
call dword [sym.imp.KERNEL32.dll_CreateFileA]
mov ebx, dword [sym.imp.KERNEL32.dll_FreeLibrary]
mov edi, eax
cmp edi, 0xffffffff
je 0x1001e00
push 0
push edi
call dword [sym.imp.KERNEL32.dll_GetFileSize]
push edi
mov dword [ebp - 0x738], eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
cmp dword [ebp - 0x738], 0xffffffff
je 0x1001e00
cmp dword [ebp - 0x738], 0x4e20
jae 0x1001e00
lea eax, [ebp - 0x760]
push eax
lea eax, [ebp - 0x758]
push eax
lea edi, [ebp - 0x740]
call fcn.01001c82
mov edi, eax
test edi, edi
je 0x1001dcb
lea eax, [ebp - 0x75c]
push eax
lea eax, [ebp - 0x210]
push eax
call dword [ebp - 0x740]
test eax, eax
jne 0x1001df9
lea eax, [ebp - 0x318]
push eax
lea eax, [ebp - 0x730]
push 0x1001300
push eax
call esi
add esp, 0xc
push 3
lea eax, [ebp - 0x730]
push eax
lea eax, [ebp - 0x210]
push eax
call dword [sym.imp.KERNEL32.dll_MoveFileExA]
test edi, edi
je 0x1001e00
push edi
call ebx
push dword [0x100300c]
mov edi, dword [sym.imp.KERNEL32.dll_LoadLibraryA]
call edi
mov esi, eax
lea eax, [ebp - 0x210]
push eax
mov dword [ebp - 0x74c], esi
call edi
test eax, eax
mov dword [ebp - 0x73c], eax
je 0x100203f
test esi, esi
je 0x100203f
cmp eax, esi
je 0x100202e
lea eax, [ebp - 0x740]
push eax
lea eax, [ebp - 0x754]
push eax
lea edi, [ebp - 0x738]
call fcn.01001c82
xor edi, edi
cmp eax, edi
mov dword [ebp - 0x760], eax
jne 0x1001e71
push dword [ebp - 0x73c]
call ebx
mov eax, esi
jmp 0x1002041
push 0x20a
lea eax, [ebp - 0x524]
push eax
push esi
call dword [sym.imp.KERNEL32.dll_GetModuleFileNameA]
lea eax, [ebp - 0x768]
push eax
lea eax, [ebp - 0x210]
push eax
call dword [ebp - 0x738]
mov dword [ebp - 0x734], eax
lea eax, [ebp - 0x76c]
push eax
lea eax, [ebp - 0x524]
push eax
call dword [ebp - 0x738]
cmp dword [ebp - 0x734], edi
mov dword [ebp - 0x750], eax
je 0x1002018
cmp eax, edi
je 0x1002018
push dword [ebp - 0x734]
mov esi, dword [sym.imp.KERNEL32.dll_LocalAlloc]
push edi
call esi
push dword [ebp - 0x750]
mov dword [ebp - 0x748], eax
push 0
call esi
push dword [ebp - 0x748]
mov esi, dword [sym.imp.KERNEL32.dll_LocalLock]
mov dword [ebp - 0x744], eax
call esi
push dword [ebp - 0x744]
mov edi, eax
call esi
xor esi, esi
cmp edi, esi
mov dword [ebp - 0x738], eax
je 0x1001fc4
cmp eax, esi
je 0x1001fc4
push edi
push dword [ebp - 0x734]
lea eax, [ebp - 0x524]
push esi
push eax
call dword [ebp - 0x754]
test eax, eax
je 0x1001fc4
push dword [ebp - 0x738]
lea eax, [ebp - 0x210]
push dword [ebp - 0x750]
push esi
push eax
call dword [ebp - 0x754]
test eax, eax
je 0x1001fc4
lea eax, [ebp - 0x764]
push eax
lea eax, [ebp - 0x75c]
push eax
mov esi, 0x100115c
push esi
push edi
call dword [ebp - 0x740]
lea eax, [ebp - 0x764]
push eax
lea eax, [ebp - 0x758]
push eax
push esi
push dword [ebp - 0x738]
call dword [ebp - 0x740]
mov eax, dword [ebp - 0x75c]
mov edx, dword [ebp - 0x758]
mov ecx, dword [eax + 8]
mov esi, dword [edx + 8]
cmp ecx, esi
ja 0x1001fc4
jb 0x1001fb6
mov eax, dword [eax + 0xc]
mov edx, dword [edx + 0xc]
cmp eax, edx
ja 0x1001fc4
jae 0x1001fc4
mov eax, dword [ebp - 0x73c]
push dword [ebp - 0x74c]
jmp 0x1001fd0
mov eax, dword [ebp - 0x74c]
push dword [ebp - 0x73c]
mov dword [ebp - 0x734], eax
call ebx
cmp dword [ebp - 0x748], 0
mov esi, dword [sym.imp.KERNEL32.dll_LocalUnlock]
mov edi, dword [sym.imp.KERNEL32.dll_LocalFree]
je 0x1001ffd
push dword [ebp - 0x748]
call esi
push dword [ebp - 0x748]
call edi
cmp dword [ebp - 0x744], 0
je 0x1002026
push dword [ebp - 0x744]
call esi
push dword [ebp - 0x744]
call edi
jmp 0x1002026
push dword [ebp - 0x73c]
mov dword [ebp - 0x734], esi
call ebx
push dword [ebp - 0x760]
jmp 0x1002035
mov dword [ebp - 0x734], esi
push eax
call ebx
mov eax, dword [ebp - 0x734]
jmp 0x1002041
or eax, esi
mov ecx, dword [ebp - 4]
pop edi
pop esi
pop ebx
call fcn.010018d0
leave
ret