Function at 0x495020
Capabilities:
Get common file path
Get program files directory

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x5a1157
mov eax, dword fs:[0]
push eax
sub esp, 0x21c
mov eax, dword [0x63434c]
xor eax, ebp
mov dword [ebp - 0x10], eax
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov esi, ecx
mov eax, dword fs:[0x2c]
mov edx, dword [0x63ec50]
mov edx, dword [eax + edx*4]
mov eax, dword [0x63ce8c]
cmp eax, dword [edx + 4]
jg 0x4952ae
cmp dword [0x60e578], 0
je 0x49528e
push 0x208
lea eax, [ebp - 0x218]
push 0
push eax
call fcn.0055c530
add esp, 0xc
lea eax, [ebp - 0x218]
push 0
push 0x26
push eax
push 0
call dword [sym.imp.SHELL32.dll_SHGetSpecialFolderPathW]
push 0x5bb5a8
lea eax, [esi + 0x10]
push eax
lea eax, [ebp - 0x220]
push eax
call fcn.004297b0
push str.wpscloudsvr.exe
push eax
lea eax, [ebp - 0x21c]
mov dword [ebp - 4], 0
push eax
call fcn.004297b0
add esp, 0x18
mov edx, dword [eax]
mov ecx, edx
mov byte [ebp - 4], 1
lea esi, [ecx + 2]
mov ax, word [ecx]
add ecx, 2
test ax, ax
jne 0x4950e1
sub ecx, esi
sar ecx, 1
push ecx
push edx
mov ecx, 0x60e518
call fcn.0042e2d0
mov edx, dword [ebp - 0x21c]
or esi, 0xffffffff
add edx, 0xfffffff0
mov eax, esi
lock xadd dword [edx + 0xc], eax
dec eax
test eax, eax
jg 0x49511c
mov ecx, dword [edx]
push edx
mov eax, dword [ecx]
call dword [eax + 4]
mov edx, dword [ebp - 0x220]
mov eax, esi
mov dword [ebp - 4], 0xffffffff
add edx, 0xfffffff0
lock xadd dword [edx + 0xc], eax
dec eax
test eax, eax
jg 0x495140
mov ecx, dword [edx]
push edx
mov eax, dword [ecx]
call dword [eax + 4]
call fcn.004291f0
mov ecx, eax
test ecx, ecx
je 0x4952e4
mov eax, dword [ecx]
call dword [eax + 0xc]
add eax, 0x10
mov dword [ebp - 0x21c], eax
lea eax, [ebp - 0x218]
mov dword [ebp - 4], 2
test eax, 0xffff0000
jne 0x495182
movzx eax, ax
lea ecx, [ebp - 0x21c]
push eax
call fcn.00429d30
jmp 0x4951b2
lea ecx, [ebp - 0x218]
lea edx, [ecx + 2]
jmp 0x495190
mov ax, word [ecx]
add ecx, 2
test ax, ax
jne 0x495190
sub ecx, edx
lea eax, [ebp - 0x218]
sar ecx, 1
push ecx
push eax
lea ecx, [ebp - 0x21c]
call fcn.0042a000
push str.Kingsoftoffice6_
lea eax, [ebp - 0x21c]
mov dword [ebp - 4], 3
push eax
lea eax, [ebp - 0x228]
push eax
call fcn.004297b0
push str.wpscloudsvr.exe
push eax
lea eax, [ebp - 0x224]
mov byte [ebp - 4], 4
push eax
call fcn.004297b0
add esp, 0x18
mov edx, dword [eax]
mov ecx, edx
mov byte [ebp - 4], 5
lea edi, [ecx + 2]
mov ax, word [ecx]
add ecx, 2
test ax, ax
jne 0x4951f5
sub ecx, edi
sar ecx, 1
push ecx
push edx
mov ecx, 0x60e530
call fcn.0042e2d0
mov edx, dword [ebp - 0x224]
mov eax, esi
add edx, 0xfffffff0
lock xadd dword [edx + 0xc], eax
dec eax
test eax, eax
jg 0x49522d
mov ecx, dword [edx]
push edx
mov eax, dword [ecx]
call dword [eax + 4]
mov edx, dword [ebp - 0x228]
mov eax, esi
add edx, 0xfffffff0
lock xadd dword [edx + 0xc], eax
dec eax
test eax, eax
jg 0x49524a
mov ecx, dword [edx]
push edx
mov eax, dword [ecx]
call dword [eax + 4]
mov edx, dword [ebp - 0x21c]
mov dword [ebp - 4], 0xffffffff
add edx, 0xfffffff0
lock xadd dword [edx + 0xc], esi
dec esi
test esi, esi
jg 0x49526c
mov ecx, dword [edx]
push edx
mov eax, dword [ecx]
call dword [eax + 4]
push 0xe
push str.InstallService
mov ecx, 0x60e548
call fcn.0042e2d0
push 0x10
push str.UninstallService
mov ecx, 0x60e560
call fcn.0042e2d0
mov eax, 0x60e518
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
mov ecx, dword [ebp - 0x10]
xor ecx, ebp
call fcn.00557e89
mov esp, ebp
pop ebp
ret
push 0x63ce8c
call fcn.00558348
add esp, 4
cmp dword [0x63ce8c], 0xffffffff
jne 0x49506f
push 0x5afe10
call fcn.0055865a
push 0x63ce8c
call fcn.005582fe
add esp, 8
jmp 0x49506f
push 0x80004005
call fcn.00429b00
int3