Function at 0x404820
Capabilities:
Get common file path
Query or enumerate registry value

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x52cc5c
mov eax, dword fs:[0]
push eax
sub esp, 0x838
mov eax, dword [0x5976b8]
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
mov ebx, dword [ebp + 8]
mov edi, ecx
push 0x114
lea esi, [edi + 0xd4c8]
push 0
push esi
call fcn.005149a0
add esp, 0xc
push esi
mov dword [esi], 0x114
call dword [sym.imp.KERNEL32.dll_GetVersionExW]
mov ecx, edi
call fcn.004032d0
xor eax, eax
push 0x206
push eax
lea ecx, [ebp - 0x41e]
push ecx
mov word [ebp - 0x420], ax
call fcn.005149a0
push ebx
lea edx, [ebp - 0x420]
push 0x104
push edx
call fcn.00515853
add esp, 0x18
lea ecx, [edi + 8]
test ebx, ebx
jne 0x4048b8
xor eax, eax
jmp 0x4048cf
mov eax, ebx
lea esi, [eax + 2]
lea ecx, [ecx]
mov dx, word [eax]
add eax, 2
test dx, dx
jne 0x4048c0
sub eax, esi
sar eax, 1
push eax
push ebx
call fcn.00404130
mov eax, dword [edi + 0x24]
mov edx, dword [eax + 4]
lea ecx, [ebp - 0x420]
push ecx
lea ecx, [edi + 0x24]
call edx
test eax, eax
jne 0x4048f6
mov eax, 0x643
jmp 0x404d0a
mov eax, dword [edi + 0x24]
mov eax, dword [eax + 0x10]
lea ecx, [ebp - 0x844]
push ecx
lea edx, [ebp - 0x834]
push edx
push str.AppName
push 0x53d4ac
lea ecx, [edi + 0x24]
mov dword [ebp - 0x834], 0
call eax
test eax, eax
je 0x40496b
mov ecx, dword [ebp - 0x834]
mov ecx, dword [ecx + 0x310]
test ecx, ecx
jne 0x40493b
xor eax, eax
jmp 0x40494f
mov eax, ecx
lea ebx, [eax + 2]
mov dx, word [eax]
add eax, 2
test dx, dx
jne 0x404940
sub eax, ebx
sar eax, 1
push eax
push ecx
lea ecx, [edi + 0x20]
call fcn.00404130
mov edx, dword [edi + 0x24]
mov eax, dword [ebp - 0x834]
mov edx, dword [edx + 0x14]
push eax
lea ecx, [edi + 0x24]
call edx
mov eax, dword [edi + 0x24]
mov eax, dword [eax + 0x10]
lea ecx, [ebp - 0x844]
push ecx
lea edx, [ebp - 0x834]
push edx
push 0x53d808
push 0x53d4ac
lea ecx, [edi + 0x24]
call eax
test eax, eax
je 0x4049ea
mov ecx, dword [ebp - 0x834]
mov ecx, dword [ecx + 0x310]
test ecx, ecx
jne 0x4049a6
xor eax, eax
jmp 0x4049bf
mov eax, ecx
lea ebx, [eax + 2]
jmp 0x4049b0
mov dx, word [eax]
add eax, 2
test dx, dx
jne 0x4049b0
sub eax, ebx
sar eax, 1
push eax
push ecx
lea ecx, [edi + 0x1c]
call fcn.00404130
mov edx, dword [edi + 0x24]
mov eax, dword [ebp - 0x834]
mov edx, dword [edx + 0x14]
push eax
lea ecx, [edi + 0x24]
call edx
push 0x17
lea ecx, [edi + 0x18]
push str.Canon_IJApp_Uninstaller
call fcn.00404130
mov eax, dword [edi + 0x24]
mov eax, dword [eax + 0x10]
lea ecx, [ebp - 0x844]
push ecx
lea edx, [ebp - 0x834]
push edx
push str.UninstallName
push 0x53d4ac
lea ecx, [edi + 0x24]
call eax
test eax, eax
je 0x404a5b
mov ecx, dword [ebp - 0x834]
mov ecx, dword [ecx + 0x310]
test ecx, ecx
jne 0x404a25
xor eax, eax
jmp 0x404a3f
mov eax, ecx
lea ebx, [eax + 2]
lea ebx, [ebx]
mov dx, word [eax]
add eax, 2
test dx, dx
jne 0x404a30
sub eax, ebx
sar eax, 1
push eax
push ecx
lea ecx, [edi + 0x14]
call fcn.00404130
mov edx, dword [edi + 0x24]
mov eax, dword [ebp - 0x834]
mov edx, dword [edx + 0x14]
push eax
lea ecx, [edi + 0x24]
call edx
mov eax, dword [edi + 0x24]
mov eax, dword [eax + 0x10]
lea ecx, [ebp - 0x844]
push ecx
lea edx, [ebp - 0x834]
push edx
push str.CtrlExApp
push 0x53d4ac
lea ecx, [edi + 0x24]
call eax
xor ebx, ebx
cmp eax, ebx
je 0x404a9f
mov eax, dword [ebp - 0x834]
mov ecx, dword [eax + 0x210]
mov edx, dword [edi + 0x24]
mov dword [edi + 4], ecx
push eax
mov eax, dword [edx + 0x14]
lea ecx, [edi + 0x24]
call eax
push 0x206
lea edx, [ebp - 0x82e]
xor ecx, ecx
push ebx
push edx
mov dword [ebp - 0x840], ebx
mov word [ebp - 0x830], cx
call fcn.005149a0
add esp, 0xc
lea eax, [ebp - 0x838]
push eax
mov ecx, edi
call fcn.00403c00
mov esi, dword [ebp - 0x838]
mov dword [ebp - 4], ebx
mov ebx, 1
cmp dword [esi - 4], ebx
jle 0x404af9
mov ecx, dword [esi - 0xc]
push ecx
lea ecx, [ebp - 0x838]
call fcn.004036b0
mov esi, dword [ebp - 0x838]
push esi
push str.SoftwareMicrosoftWindowsCurrentVersionUninstall
push 0x53d734
lea edx, [ebp - 0x830]
push 0x104
push edx
call fcn.00515c51
add esp, 0x14
lea eax, [ebp - 0x840]
push eax
push ebx
push 0
lea ecx, [ebp - 0x830]
push ecx
push reloc.OLEAUT32.dll_SysReAllocString
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExW]
test eax, eax
jne 0x404ba4
xor edx, edx
push 0x206
push edx
lea eax, [ebp - 0x626]
push eax
mov word [ebp - 0x628], dx
call fcn.005149a0
mov eax, dword [ebp - 0x840]
add esp, 0xc
lea ecx, [ebp - 0x83c]
push ecx
lea edx, [ebp - 0x628]
push edx
push 0
push 0
push str.InstallLocation
push eax
mov dword [ebp - 0x83c], 0x208
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExW]
test eax, eax
jne 0x404b97
lea ecx, [ebp - 0x628]
push ecx
lea ecx, [edi + 0x10]
call fcn.004047d0
mov edx, dword [ebp - 0x840]
push edx
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
lea eax, [esi - 0x10]
mov dword [ebp - 4], 0xffffffff
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x404bc7
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
call fcn.004170fe
xor ecx, ecx
test eax, eax
setne cl
test ecx, ecx
jne 0x404be1
push 0x80004005
call fcn.00401550
mov edx, dword [eax]
mov ecx, eax
mov eax, dword [edx + 0xc]
call eax
add eax, 0x10
mov dword [ebp - 0x838], eax
xor ecx, ecx
push 0x206
push ecx
lea edx, [ebp - 0x216]
push edx
mov dword [ebp - 4], ebx
mov word [ebp - 0x218], cx
call fcn.005149a0
add esp, 0xc
lea eax, [ebp - 0x218]
push eax
push 0x104
call dword [sym.imp.KERNEL32.dll_GetTempPathW]
lea ecx, [ebp - 0x83c]
push ecx
mov ecx, edi
call fcn.00403b70
push eax
lea ecx, [ebp - 0x838]
mov byte [ebp - 4], 2
call fcn.00404700
mov eax, dword [ebp - 0x83c]
add eax, 0xfffffff0
mov byte [ebp - 4], bl
lea edx, [eax + 0xc]
or ecx, 0xffffffff
lock xadd dword [edx], ecx
dec ecx
test ecx, ecx
jg 0x404c69
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
push str..bat
push 0x53d6fc
lea ecx, [ebp - 0x838]
call fcn.00404290
lea ecx, [ebp - 0x838]
push ecx
lea edx, [ebp - 0x218]
push edx
lea eax, [ebp - 0x83c]
push eax
call fcn.004045e0
add esp, 0xc
push eax
lea ecx, [ebp - 0x838]
mov byte [ebp - 4], 3
call fcn.00404700
mov eax, dword [ebp - 0x83c]
add eax, 0xfffffff0
mov byte [ebp - 4], bl
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x404cd0
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
lea edx, [ebp - 0x838]
lea ecx, [edi + 0xc]
push edx
call fcn.00404700
mov eax, dword [ebp - 0x838]
add eax, 0xfffffff0
mov dword [ebp - 4], 0xffffffff
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x404d08
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
xor eax, eax
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.00514990
mov esp, ebp
pop ebp
ret 4