Function at 0x422ca0
Capabilities:
Check if file exists
Get common file path

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x55b2e1
mov eax, dword fs:[0]
push eax
sub esp, 0x42c
mov eax, dword [0x5b4450]
xor eax, ebp
mov dword [ebp - 0x10], eax
push ebx
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
xor ebx, ebx
push ebx
lea eax, [ebp - 0x434]
push str.Tool_RemoveReg_CAPTShareModule
push eax
mov edi, ecx
call fcn.0040ac70
add esp, 0xc
mov dword [ebp - 4], ebx
call fcn.00442c4d
mov esi, dword [eax + 4]
push 0x206
lea edx, [ebp - 0x41e]
xor ecx, ecx
push ebx
push edx
mov dword [ebp - 0x428], ebx
mov word [ebp - 0x420], cx
call fcn.005373f0
add esp, 0xc
push 0x206
lea ecx, [ebp - 0x216]
xor eax, eax
push ebx
push ecx
mov word [ebp - 0x218], ax
call fcn.005373f0
add esp, 0xc
push 0x58a8c8
lea ecx, [ebp - 0x424]
call fcn.00401210
mov byte [ebp - 4], 1
mov edx, dword [esi + 0x628]
push edx
lea eax, [ebp - 0x424]
push str._sSMK.DLL
push eax
call fcn.00405ba0
add esp, 0xc
push 0x104
lea ecx, [ebp - 0x218]
push ecx
call dword [sym.imp.KERNEL32.dll_GetSystemDirectoryW]
lea edx, [ebp - 0x218]
push edx
call dword [sym.imp.SHLWAPI.dll_PathAddBackslashW]
mov eax, dword [ebp - 0x424]
cmp dword [eax - 4], 1
jle 0x422da3
mov eax, dword [eax - 0xc]
push eax
lea ecx, [ebp - 0x424]
call fcn.00401840
mov eax, dword [ebp - 0x424]
push eax
lea ecx, [ebp - 0x218]
push ecx
lea edx, [ebp - 0x420]
push 0x58b914
push edx
call dword [sym.imp.USER32.dll_wsprintfW]
add esp, 0x10
lea eax, [ebp - 0x420]
push eax
call dword [sym.imp.SHLWAPI.dll_PathFileExistsW]
test eax, eax
je 0x422e2a
push 1
push str.return___08x
lea ecx, [ebp - 0x434]
push 2
push ecx
call fcn.0040aed0
mov byte [ebp - 4], bl
mov eax, dword [ebp - 0x424]
add eax, 0xfffffff0
add esp, 0x10
lea edx, [eax + 0xc]
or ecx, 0xffffffff
lock xadd dword [edx], ecx
dec ecx
test ecx, ecx
jg 0x422e0e
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
lea ecx, [ebp - 0x434]
mov dword [ebp - 4], 0xffffffff
call fcn.0040ae50
mov eax, 1
jmp 0x422f37
call fcn.0044033f
xor ecx, ecx
cmp eax, ebx
setne cl
cmp ecx, ebx
jne 0x422e44
push 0x80004005
call fcn.004010a0
mov edx, dword [eax]
mov ecx, eax
mov eax, dword [edx + 0xc]
call eax
add eax, 0x10
mov dword [ebp - 0x42c], eax
mov byte [ebp - 4], 2
mov ecx, dword [esi + 0x628]
push ecx
push str.SOFTWARECANON_
lea edx, [ebp - 0x42c]
push 0x58b914
push edx
call fcn.00405ba0
mov esi, dword [ebp - 0x42c]
add esp, 0x10
lea eax, [ebp - 0x428]
push eax
push 0x2001f
push ebx
push esi
push edi
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExW]
cmp eax, ebx
jne 0x422eb4
mov ecx, dword [ebp - 0x428]
push ecx
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
push esi
push edi
call fcn.00422a10
add esp, 8
mov edi, eax
jmp 0x422ec7
cmp eax, 2
je 0x422ec2
cmp eax, 3
je 0x422ec2
xor edi, edi
jmp 0x422ec7
mov edi, 1
push edi
push str.return___08x
lea edx, [ebp - 0x434]
push 2
push edx
call fcn.0040aed0
lea eax, [esi - 0x10]
add esp, 0x10
mov byte [ebp - 4], 1
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x422efe
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov byte [ebp - 4], bl
mov eax, dword [ebp - 0x424]
add eax, 0xfffffff0
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x422f23
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
lea ecx, [ebp - 0x434]
mov dword [ebp - 4], 0xffffffff
call fcn.0040ae50
mov eax, edi
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 0x10]
xor ecx, ebp
call fcn.005337cb
mov esp, ebp
pop ebp
ret