Function at 0x4066c0
Capabilities:
Check if file exists
Create process on windows
Move file

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x4c7008
mov eax, dword fs:[0]
push eax
sub esp, 0xe0
mov eax, dword [0x50545c]
xor eax, ebp
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov dword [ebp - 0xe8], ecx
mov dword [ebp - 0x74], 0x44
push 0x40
push 0
lea eax, [ebp - 0x70]
push eax
call fcn.004931a0
add esp, 0xc
mov dword [ebp - 0x28], 0
xor ecx, ecx
mov dword [ebp - 0x24], ecx
mov dword [ebp - 0x20], ecx
mov dword [ebp - 0x1c], ecx
push 0x4d31a8
lea ecx, [ebp - 0x18]
call fcn.00412290
mov dword [ebp - 4], 0
mov edx, dword [ebp - 0xe8]
mov eax, dword [edx]
sub eax, 0x10
mov dword [ebp - 0x90], eax
mov ecx, dword [ebp - 0x90]
push ecx
call fcn.00412ee0
add esp, 4
mov dword [ebp - 0x94], eax
mov edx, dword [ebp - 0x94]
add edx, 0x10
mov dword [ebp - 0x2c], edx
mov byte [ebp - 4], 1
mov eax, dword [ebp - 0xe8]
mov ecx, dword [eax + 4]
sub ecx, 0x10
mov dword [ebp - 0x98], ecx
mov edx, dword [ebp - 0x98]
push edx
call fcn.00412ee0
add esp, 4
mov dword [ebp - 0x9c], eax
mov eax, dword [ebp - 0x9c]
add eax, 0x10
mov dword [ebp - 0x10], eax
mov byte [ebp - 4], 2
push 1
lea ecx, [ebp - 0x7c]
push ecx
lea ecx, [ebp - 0x2c]
call fcn.0040f040
mov dword [ebp - 0xa4], eax
mov edx, dword [ebp - 0xa4]
mov eax, dword [edx]
mov ecx, dword [eax - 0xc]
mov dword [ebp - 0xa0], ecx
cmp dword [ebp - 0xa0], 1
jne 0x4067ee
push 0
mov ecx, dword [ebp - 0xa4]
call fcn.0040fd40
movzx edx, ax
mov eax, 0x5c
movzx ecx, ax
cmp edx, ecx
jne 0x4067ee
mov dword [ebp - 0xec], 0
jmp 0x4067f8
mov dword [ebp - 0xec], 1
mov dl, byte [ebp - 0xec]
mov byte [ebp - 0x75], dl
mov eax, dword [ebp - 0x7c]
sub eax, 0x10
mov dword [ebp - 0xa8], eax
mov ecx, dword [ebp - 0xa8]
call fcn.004029d0
movzx ecx, byte [ebp - 0x75]
test ecx, ecx
je 0x40685c
mov edx, 0x4d1934
test edx, edx
jne 0x406835
mov dword [ebp - 0xac], 0
jmp 0x406848
push 0x4d1934
call fcn.004939fc
add esp, 4
mov dword [ebp - 0xac], eax
mov eax, dword [ebp - 0xac]
push eax
push 0x4d1934
lea ecx, [ebp - 0x2c]
call fcn.00411880
mov ecx, str.CommonService.exe
test ecx, ecx
jne 0x406871
mov dword [ebp - 0xb0], 0
jmp 0x406884
push str.CommonService.exe
call fcn.004939fc
add esp, 4
mov dword [ebp - 0xb0], eax
mov edx, dword [ebp - 0xb0]
push edx
push str.CommonService.exe
lea ecx, [ebp - 0x2c]
call fcn.00411880
push str.CommonService
call fcn.00406610
add esp, 4
test eax, eax
jne 0x4068f3
push str.CopyCommonService_start
mov eax, dword [ebp - 0xe8]
push eax
call fcn.00401a70
add esp, 8
mov dword [ebp - 0x80], 1
mov byte [ebp - 4], 1
lea ecx, [ebp - 0x10]
call fcn.004129d0
mov byte [ebp - 4], 0
lea ecx, [ebp - 0x2c]
call fcn.004129d0
mov dword [ebp - 4], 0xffffffff
lea ecx, [ebp - 0x18]
call fcn.004129d0
mov eax, dword [ebp - 0x80]
jmp 0x406aca
mov ecx, dword [ebp - 0x2c]
mov dword [ebp - 0xc0], ecx
mov edx, dword [ebp - 0xc0]
push edx
call dword [sym.imp.SHLWAPI.dll_PathFileExistsW]
test eax, eax
je 0x406912
jmp 0x4069be
mov eax, 0x4d3110
test eax, eax
jne 0x406927
mov dword [ebp - 0xc4], 0
jmp 0x40693a
push 0x4d3110
call fcn.004939fc
add esp, 4
mov dword [ebp - 0xc4], eax
mov ecx, dword [ebp - 0xc4]
push ecx
push 0x4d3110
lea ecx, [ebp - 0x10]
call fcn.00411880
mov edx, dword [ebp - 0x2c]
mov dword [ebp - 0xc8], edx
mov eax, dword [ebp - 0x10]
mov dword [ebp - 0xcc], eax
mov ecx, dword [ebp - 0xc8]
push ecx
mov edx, dword [ebp - 0xcc]
push edx
call dword [sym.imp.KERNEL32.dll_MoveFileW]
mov dword [ebp - 0x14], eax
cmp dword [ebp - 0x14], 0
je 0x40699b
mov eax, dword [ebp - 0x2c]
push eax
mov ecx, dword [ebp - 0x10]
push ecx
push str.CopyCommonService_MoveFile_Succeed___s_____s.
mov edx, dword [ebp - 0xe8]
push edx
call fcn.00401a70
add esp, 0x10
jmp 0x4069be
mov eax, dword [ebp - 0x2c]
push eax
mov ecx, dword [ebp - 0x10]
push ecx
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push str.CopyCommonService_MoveFile_Fail__LastError__d___s_____s.
mov edx, dword [ebp - 0xe8]
push edx
call fcn.00401a70
add esp, 0x14
xor eax, eax
mov word [ebp - 0x44], ax
mov dword [ebp - 0x48], 1
mov ecx, dword [ebp - 0x2c]
mov edx, dword [ecx - 0xc]
mov dword [ebp - 0xd0], edx
mov eax, dword [ebp - 0xd0]
push eax
mov ecx, dword [ebp - 0x2c]
push ecx
lea ecx, [ebp - 0x18]
call fcn.00411880
mov edx, str.___install
test edx, edx
jne 0x4069ff
mov dword [ebp - 0xd4], 0
jmp 0x406a12
push str.___install
call fcn.004939fc
add esp, 4
mov dword [ebp - 0xd4], eax
mov eax, dword [ebp - 0xd4]
push eax
push str.___install
lea ecx, [ebp - 0x18]
call fcn.00411880
mov ecx, dword [ebp - 0x18]
mov dword [ebp - 0xd8], ecx
lea edx, [ebp - 0x28]
push edx
lea eax, [ebp - 0x74]
push eax
push 0
push 0
push 0
push 0
push 0
push 0
mov ecx, dword [ebp - 0xd8]
push ecx
push 0
call dword [sym.imp.KERNEL32.dll_CreateProcessW]
mov dword [ebp - 0x14], eax
push 0x1388
mov edx, dword [ebp - 0x24]
push edx
call dword [sym.imp.KERNEL32.dll_WaitForSingleObject]
push 0
push 0
push str._start_CommonService
push 0x4d2fe8
push 0
push 0
call dword [sym.imp.SHELL32.dll_ShellExecuteW]
mov eax, dword [ebp - 0x14]
push eax
push str.CopyCommonService_start_Result:_08x
mov ecx, dword [ebp - 0xe8]
push ecx
call fcn.00401a70
add esp, 0xc
mov edx, dword [ebp - 0x14]
mov dword [ebp - 0x84], edx
mov byte [ebp - 4], 1
lea ecx, [ebp - 0x10]
call fcn.004129d0
mov byte [ebp - 4], 0
lea ecx, [ebp - 0x2c]
call fcn.004129d0
mov dword [ebp - 4], 0xffffffff
lea ecx, [ebp - 0x18]
call fcn.004129d0
mov eax, dword [ebp - 0x84]
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
mov esp, ebp
pop ebp
ret