Function at 0x4059e0
Capabilities:
Get common file path

Disassembly:
push ebx
mov ebx, esp
sub esp, 8
and esp, 0xfffffff8
add esp, 4
push ebp
mov ebp, dword [ebx + 4]
mov dword [esp + 4], ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x418d7d
mov eax, dword fs:[0]
push eax
push ecx
push ebx
sub esp, 0x500
mov eax, dword [0x424140]
xor eax, ebp
mov dword [ebp - 0x1c], eax
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov dword [ebp - 0x10], esp
lea eax, [ebp - 0x228]
push eax
push 0
push 0
push 0x1a
push 0
call dword [sym.imp.SHELL32.dll_SHGetFolderPathW]
test eax, eax
jne 0x405c25
push 0x12
xorps xmm0, xmm0
mov dword [ebp - 0x500], eax
push str.ArcControlServices
lea ecx, [ebp - 0x510]
mov dword [ebp - 0x4fc], eax
movups xmmword [ebp - 0x510], xmm0
call fcn.00404fa0
lea esi, [ebp - 0x228]
mov dword [ebp - 4], 0
mov ecx, esi
lea edx, [ecx + 2]
nop dword [eax]
mov ax, word [ecx]
add ecx, 2
test ax, ax
jne 0x405a80
sub ecx, edx
mov dword [ebp - 0x4e8], 0
sar ecx, 1
xorps xmm0, xmm0
push ecx
push esi
lea ecx, [ebp - 0x4f8]
mov dword [ebp - 0x4e4], 0
movups xmmword [ebp - 0x4f8], xmm0
call fcn.00404fa0
lea eax, [ebp - 0x510]
mov byte [ebp - 4], 1
push eax
lea edx, [ebp - 0x4f8]
lea ecx, [ebp - 0x488]
call fcn.00402100
add esp, 4
mov byte [ebp - 4], 3
mov ecx, dword [ebp - 0x4e4]
cmp ecx, 7
jbe 0x405b1d
mov edx, dword [ebp - 0x4f8]
lea ecx, [ecx*2 + 2]
mov eax, edx
cmp ecx, 0x1000
jb 0x405b13
mov edx, dword [eax - 4]
add ecx, 0x23
sub eax, edx
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x40602c
push ecx
push edx
call fcn.0040bf8e
add esp, 8
xor eax, eax
mov dword [ebp - 0x4e8], 0
mov dword [ebp - 0x4e4], 7
mov word [ebp - 0x4f8], ax
mov byte [ebp - 4], 4
mov ecx, dword [ebp - 0x4fc]
cmp ecx, 7
jbe 0x405b7e
mov edx, dword [ebp - 0x510]
lea ecx, [ecx*2 + 2]
mov eax, edx
cmp ecx, 0x1000
jb 0x405b74
mov edx, dword [eax - 4]
add ecx, 0x23
sub eax, edx
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x40602c
push ecx
push edx
call fcn.0040bf8e
add esp, 8
xor eax, eax
mov byte [ebp - 4], 5
lea edx, [ebp - 0x43c]
mov dword [ebp - 0x500], 0
lea ecx, [ebp - 0x488]
mov dword [ebp - 0x4fc], 7
mov word [ebp - 0x510], ax
mov dword [ebp - 0x43c], eax
mov dword [ebp - 0x438], 0x424a08
call fcn.00402d20
cmp dword [ebp - 0x43c], 0
jne 0x406031
push 0x104
lea eax, [ebp - 0x430]
push eax
push 0
call dword [sym.imp.KERNEL32.dll_GetModuleFileNameW]
test eax, eax
jne 0x405c43
mov ecx, dword [ebp - 0x474]
cmp ecx, 7
jbe 0x405c25
mov edx, dword [ebp - 0x488]
lea ecx, [ecx*2 + 2]
mov eax, edx
cmp ecx, 0x1000
jb 0x405c1b
mov edx, dword [eax - 4]
add ecx, 0x23
sub eax, edx
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x406093
push ecx
push edx
call fcn.0040bf8e
add esp, 8
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
mov ecx, dword [ebp - 0x1c]
xor ecx, ebp
call fcn.0040bb05
mov esp, ebp
pop ebp
mov esp, ebx
pop ebx
ret
lea esi, [ebp - 0x430]
mov ecx, esi
lea edx, [ecx + 2]
nop
mov ax, word [ecx]
add ecx, 2
test ax, ax
jne 0x405c50
sub ecx, edx
mov dword [ebp - 0x460], 0
sar ecx, 1
xorps xmm0, xmm0
push ecx
push esi
lea ecx, [ebp - 0x470]
mov dword [ebp - 0x45c], 0
movups xmmword [ebp - 0x470], xmm0
call fcn.00404fa0
mov byte [ebp - 4], 6
lea ecx, [ebp - 0x4e0]
push 0x16
xorps xmm0, xmm0
mov dword [ebp - 0x4d0], 0
push str.ArcControlServices.exe
movups xmmword [ebp - 0x4e0], xmm0
mov dword [ebp - 0x4cc], 0
call fcn.00404fa0
lea eax, [ebp - 0x4e0]
mov byte [ebp - 4], 7
push eax
lea edx, [ebp - 0x488]
lea ecx, [ebp - 0x458]
call fcn.00402100
add esp, 4
mov byte [ebp - 4], 9
mov ecx, dword [ebp - 0x4cc]
cmp ecx, 7
jbe 0x405d21
mov edx, dword [ebp - 0x4e0]
lea ecx, [ecx*2 + 2]
mov eax, edx
cmp ecx, 0x1000
jb 0x405d17
mov edx, dword [eax - 4]
add ecx, 0x23
sub eax, edx
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x406048
push ecx
push edx
call fcn.0040bf8e
add esp, 8
xor eax, eax
mov dword [ebp - 0x4d0], 0
cmp dword [ebp - 0x444], 7
lea ecx, [ebp - 0x4a8]
push 0xffffffffffffffff
mov word [ebp - 0x4e0], ax
lea eax, [ebp - 0x458]
cmova eax, dword [ebp - 0x458]
push 3
push ecx
push eax
mov dword [ebp - 0x4cc], 7
call fcn.0040b754
mov esi, eax
test esi, esi
jne 0x405dbc
mov ecx, dword [ebp - 0x498]
mov eax, 0x1ff
test cl, 1
mov edx, 0x16d
cmovne eax, edx
mov dword [ebp - 0x43c], eax
mov eax, ecx
shr eax, 0xa
test al, 1
je 0x405dae
mov eax, dword [ebp - 0x494]
cmp eax, 0xa000000c
jne 0x405da0
lea eax, [esi + 4]
jmp 0x405dd2
cmp eax, 0xa0000003
jne 0x405dae
mov eax, 0xa
jmp 0x405dd2
shr ecx, 4
movzx eax, cl
and eax, 1
or eax, 2
jmp 0x405dd2
push esi
mov dword [ebp - 0x43c], 0xffff
call fcn.00401c20
add esp, 4
movzx eax, al
mov dword [ebp - 0x43c], esi
mov dword [ebp - 0x438], 0x424a08
test eax, eax
je 0x405ec3
cmp eax, 1
setne al
test al, al
je 0x405e88
cmp dword [ebp - 0x444], 7
lea ecx, [ebp - 0x4a8]
push 0xffffffffffffffff
push 0x21
lea eax, [ebp - 0x458]
cmova eax, dword [ebp - 0x458]
push ecx
push eax
call fcn.0040b754
test eax, eax
jne 0x40606e
cmp dword [ebp - 0x45c], 7
lea ecx, [ebp - 0x4c8]
mov esi, dword [ebp - 0x4a4]
lea eax, [ebp - 0x470]
cmova eax, dword [ebp - 0x470]
push 0xffffffffffffffff
push 0x21
push ecx
push eax
call fcn.0040b754
test eax, eax
jne 0x406060
mov ecx, dword [ebp - 0x4c8]
mov eax, dword [ebp - 0x4c4]
cmp ecx, dword [ebp - 0x4a8]
jne 0x405e70
cmp eax, esi
je 0x405ecd
cmp eax, esi
jg 0x405e82
jl 0x405e7e
cmp ecx, dword [ebp - 0x4a8]
jae 0x405e82
or al, 0xff
jmp 0x405e84
mov al, 1
test al, al
jle 0x405ecd
cmp dword [ebp - 0x444], 7
lea ecx, [ebp - 0x458]
push 2
cmova ecx, dword [ebp - 0x458]
lea eax, [ebp - 0x470]
cmp dword [ebp - 0x45c], 7
push ecx
cmova eax, dword [ebp - 0x470]
push eax
call fcn.0040b55b
test edx, edx
jne 0x40604d
jmp 0x405ecd
test esi, esi
jne 0x40607c
jmp 0x405e88
mov ecx, dword [ebp - 0x444]
cmp ecx, 7
jbe 0x405f0d
mov edx, dword [ebp - 0x458]
lea ecx, [ecx*2 + 2]
mov eax, edx
cmp ecx, 0x1000
jb 0x405f03
mov edx, dword [eax - 4]
add ecx, 0x23
sub eax, edx
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x406093
push ecx
push edx
call fcn.0040bf8e
add esp, 8
mov ecx, dword [ebp - 0x45c]
xor eax, eax
mov dword [ebp - 0x448], 0
mov dword [ebp - 0x444], 7
mov word [ebp - 0x458], ax
cmp ecx, 7
jbe 0x405fe9
mov edx, dword [ebp - 0x470]
lea ecx, [ecx*2 + 2]
mov eax, edx
cmp ecx, 0x1000
jb 0x405f64
mov edx, dword [eax - 4]
add ecx, 0x23
sub eax, edx
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x406093
push ecx
push edx
call fcn.0040bf8e
add esp, 8
jmp 0x405fe9
mov ecx, dword [ebp - 0x474]
cmp ecx, 7
jbe 0x405c25
mov edx, dword [ebp - 0x488]
lea ecx, [ecx*2 + 2]
mov eax, edx
cmp ecx, 0x1000
jb 0x405c1b
mov edx, dword [eax - 4]
add ecx, 0x23
sub eax, edx
add eax, 0xfffffffc
cmp eax, 0x1f
jbe 0x405c1b
call fcn.0040f39f
call fcn.0040f39f
lea eax, [ebp - 0x488]
mov ecx, str.create_directories
push eax
lea edx, [ebp - 0x43c]
call fcn.00402ca0
call fcn.0040f39f
lea eax, [ebp - 0x458]
push eax
lea eax, [ebp - 0x470]
push eax
call fcn.00402c10
lea ecx, [ebp - 0x470]
mov edx, eax
push ecx
call fcn.00402b80
lea ecx, [ebp - 0x458]
mov edx, eax
push ecx
call fcn.00402b80
lea eax, [ebp - 0x458]
mov ecx, str.exists
push eax
lea edx, [ebp - 0x43c]
call fcn.00402ca0
call fcn.0040f39f
int3