Function at 0x1004a360
Capabilities:
Check if file exists

Disassembly:
push ebp
lea ebp, [esp - 0x20c]
sub esp, 0x20c
push 0xffffffffffffffff
push 0x1006cf7d
mov eax, dword fs:[0]
push eax
sub esp, 0x50
mov eax, dword [0x100ad040]
xor eax, ebp
mov dword [ebp + 0x208], eax
push ebx
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov eax, dword [ebp + 0x214]
mov dword [ebp - 0x44], eax
mov dword [ebp - 0x30], 0
mov dword [ebp - 0x2c], 0
mov dword [ebp - 4], 0
lea ecx, [ebp - 0x30]
push ecx
mov edx, str.OriginalDatabase
mov ecx, eax
call fcn.1002ea60
add esp, 4
test al, al
jne 0x1004a3df
mov dword [ebp - 4], 0xffffffff
mov eax, dword [ebp - 0x2c]
test eax, eax
je 0x1004a40f
push eax
jmp 0x1004a409
mov ebx, dword [ebp - 0x2c]
mov eax, dword [ebp - 0x30]
lea eax, [ebx + eax*2]
cmp eax, ebx
jb 0x1004a3fd
nop dword [eax]
cmp word [eax], 0x5c
je 0x1004a447
sub eax, 2
cmp eax, ebx
jae 0x1004a3f0
mov dword [ebp - 4], 0xffffffff
test ebx, ebx
je 0x1004a40f
push ebx
call dword [sym.imp.KERNEL32.dll_LocalFree]
mov eax, 0x65b
mov dword [ebp - 0x30], 0
mov dword [ebp - 0x2c], 0
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [ebp + 0x208]
xor ecx, ebp
call fcn.1004d46a
lea esp, [ebp + 0x20c]
pop ebp
ret 4
xor ecx, ecx
mov word [eax + 2], cx
call fcn.1001cdb0
cmp byte [eax + 0x1c], 0
je 0x1004a551
call fcn.1001cdb0
mov ebx, eax
call fcn.1000a250
mov edi, eax
test edi, edi
je 0x1004aba0
mov ecx, dword [edi]
mov esi, dword [ecx + 0xc]
mov ecx, esi
call dword [0x1006e578]
mov ecx, edi
call esi
add eax, 0x10
mov dword [ebp - 0x10], eax
mov byte [ebp - 4], 3
lea ecx, [ebp - 0x10]
push 0x12
push str.Directory_of_CABs:
call fcn.10011800
call fcn.1000a250
mov edi, eax
test edi, edi
je 0x1004aba0
mov ecx, dword [edi]
mov esi, dword [ecx + 0xc]
mov ecx, esi
call dword [0x1006e578]
mov ecx, edi
call esi
add eax, 0x10
mov dword [ebp - 0x28], eax
mov byte [ebp - 4], 6
lea ecx, [ebp - 0x28]
push 0
push 0x10093cf4
call fcn.10011800
mov eax, dword [ebx + 0x38]
test eax, eax
je 0x1004a4f8
push str.AiEmbeddedDirectCall
push eax
call dword [sym.imp.msi.dll_MsiGetComponentStateW]
cmp eax, 1
je 0x1004a4f8
lea eax, [ebp - 0x10]
mov ecx, ebx
push eax
call fcn.1001cfd0
mov byte [ebp - 4], 3
or eax, 0xffffffff
mov ecx, dword [ebp - 0x28]
add ecx, 0xfffffff0
lock xadd dword [ecx + 0xc], eax
dec eax
test eax, eax
jg 0x1004a523
mov edi, dword [ecx]
push ecx
mov eax, dword [edi]
mov esi, dword [eax + 4]
mov ecx, esi
call dword [0x1006e578]
mov ecx, edi
call esi
mov byte [ebp - 4], 0
or eax, 0xffffffff
mov ecx, dword [ebp - 0x10]
add ecx, 0xfffffff0
lock xadd dword [ecx + 0xc], eax
dec eax
test eax, eax
jg 0x1004a54e
mov edi, dword [ecx]
push ecx
mov eax, dword [edi]
mov esi, dword [eax + 4]
mov ecx, esi
call dword [0x1006e578]
mov ecx, edi
call esi
mov ebx, dword [ebp - 0x2c]
mov dword [ebp - 0x24], 0
mov byte [ebp - 4], 0xb
mov dword [ebp - 0x1c], 0
mov byte [ebp - 4], 0xc
push dword [ebp - 0x44]
call dword [sym.imp.msi.dll_MsiGetFeatureCostA]
mov esi, eax
mov dword [ebp - 0x5c], esi
mov byte [ebp - 4], 0xd
mov ecx, dword [ebp - 0x1c]
test ecx, ecx
je 0x1004a587
push ecx
call dword [sym.imp.msi.dll_MsiConfigureFeatureFromDescriptorA]
lea eax, [ebp - 0x1c]
mov dword [ebp - 0x1c], 0
push eax
push str.SELECT__Feature__FROM__Feature_
push esi
call dword [sym.imp.msi.dll_MsiEnumClientsA]
test eax, eax
je 0x1004a5de
mov byte [ebp - 4], 0xc
test esi, esi
je 0x1004a5b1
push esi
call dword [sym.imp.msi.dll_MsiConfigureFeatureFromDescriptorA]
mov byte [ebp - 4], 0xb
mov eax, dword [ebp - 0x1c]
test eax, eax
je 0x1004a5c3
push eax
call dword [sym.imp.msi.dll_MsiConfigureFeatureFromDescriptorA]
mov byte [ebp - 4], 0
mov eax, dword [ebp - 0x24]
test eax, eax
je 0x1004a3fd
push eax
call dword [sym.imp.msi.dll_MsiConfigureFeatureFromDescriptorA]
jmp 0x1004a3fd
push 0
push dword [ebp - 0x1c]
call dword [sym.imp.msi.dll_MsiViewModify]
test eax, eax
jne 0x1004a5a2
mov dword [ebp - 0x38], eax
mov dword [ebp - 0x34], eax
mov byte [ebp - 4], 0xe
push 0x320
push 0x40
call dword [sym.imp.KERNEL32.dll_LocalAlloc]
xor esi, esi
mov dword [ebp - 0x34], eax
xor edi, edi
mov dword [ebp - 0x38], 0xc8
mov dword [ebp - 0x20], esi
mov dword [ebp - 0x10], edi
mov ebx, 1
nop dword [eax]
mov eax, dword [ebp - 0x24]
test eax, eax
je 0x1004a62e
push eax
call dword [sym.imp.msi.dll_MsiConfigureFeatureFromDescriptorA]
lea eax, [ebp - 0x24]
mov dword [ebp - 0x24], 0
push eax
push dword [ebp - 0x1c]
call dword [sym.imp.msi.dll_MsiDatabaseIsTablePersistentA]
mov dword [ebp - 0x18], 0
mov dword [ebp - 0x14], 0
test eax, eax
jne 0x1004aa7f
mov byte [ebp - 4], 0xf
lea eax, [ebp - 0x18]
mov ecx, dword [ebp - 0x24]
mov edx, ebx
push eax
call fcn.1002f6e0
add esp, 4
call fcn.1001cdb0
cmp byte [eax + 0x1c], 0
je 0x1004a779
call fcn.1001cdb0
mov ebx, eax
call fcn.1000a250
mov edi, eax
test edi, edi
je 0x1004aba0
mov ecx, dword [edi]
mov esi, dword [ecx + 0xc]
mov ecx, esi
call dword [0x1006e578]
mov ecx, edi
call esi
add eax, 0x10
mov dword [ebp - 0x3c], eax
mov byte [ebp - 4], 0x12
lea ecx, [ebp - 0x3c]
push 0x13
push str._Analyzing_feature:
call fcn.10011800
call fcn.1000a250
mov edi, eax
test edi, edi
je 0x1004aba0
mov ecx, dword [edi]
mov esi, dword [ecx + 0xc]
mov ecx, esi
call dword [0x1006e578]
mov ecx, edi
call esi
add eax, 0x10
mov dword [ebp - 0x4c], eax
mov byte [ebp - 4], 0x15
lea ecx, [ebp - 0x4c]
push 0
push 0x10093cf4
call fcn.10011800
mov eax, dword [ebx + 0x38]
test eax, eax
je 0x1004a718
push str.AiEmbeddedDirectCall
push eax
call dword [sym.imp.msi.dll_MsiGetComponentStateW]
cmp eax, 1
je 0x1004a718
lea eax, [ebp - 0x3c]
mov ecx, ebx
push eax
call fcn.1001cfd0
mov byte [ebp - 4], 0x12
or eax, 0xffffffff
mov ecx, dword [ebp - 0x4c]
add ecx, 0xfffffff0
lock xadd dword [ecx + 0xc], eax
dec eax
test eax, eax
jg 0x1004a743
mov edi, dword [ecx]
push ecx
mov eax, dword [edi]
mov esi, dword [eax + 4]
mov ecx, esi
call dword [0x1006e578]
mov ecx, edi
call esi
mov byte [ebp - 4], 0xf
or eax, 0xffffffff
mov ecx, dword [ebp - 0x3c]
add ecx, 0xfffffff0
lock xadd dword [ecx + 0xc], eax
dec eax
test eax, eax
jg 0x1004a76e
mov edi, dword [ecx]
push ecx
mov eax, dword [edi]
mov esi, dword [eax + 4]
mov ecx, esi
call dword [0x1006e578]
mov ecx, edi
call esi
mov edi, dword [ebp - 0x10]
mov ebx, 1
mov esi, dword [ebp - 0x20]
mov ecx, dword [ebp - 0x44]
lea edx, [ebp - 0x18]
call fcn.10049e40
test al, al
jne 0x1004a7ad
mov byte [ebp - 4], 0xe
mov eax, dword [ebp - 0x14]
test eax, eax
je 0x1004a79a
push eax
call dword [sym.imp.KERNEL32.dll_LocalFree]
mov dword [ebp - 0x14], 0
mov dword [ebp - 0x18], 0
jmp 0x1004a620
mov edx, dword [ebp - 0x2c]
lea ecx, [ebp]
xor eax, eax
push 0xffffffffffffffff
mov word [ebp], ax
call fcn.10013e10
add esp, 4
cmp word [eax], 0
je 0x1004a7d9
nop dword [eax]
add eax, 2
cmp word [eax], 0
jne 0x1004a7d0
mov ebx, dword [ebp - 0x14]
mov ecx, eax
push 0xffffffffffffffff
mov edx, ebx
call fcn.10013e10
add esp, 4
cmp word [eax], 0
je 0x1004a7f9
add eax, 2
cmp word [eax], 0
jne 0x1004a7f0
push 0xffffffffffffffff
mov edx, str..cab
mov ecx, eax
call fcn.10013e10
add esp, 4
lea eax, [ebp]
push eax
call dword [sym.imp.SHLWAPI.dll_PathFileExistsW]
mov dword [ebp - 0x58], eax
call fcn.1001cdb0
cmp byte [eax + 0x1c], 0
je 0x1004a91c
call fcn.1001cdb0
mov dword [ebp - 0x48], eax
call fcn.1000a250
mov edi, eax
test edi, edi
je 0x1004aba0
mov ecx, dword [edi]
mov esi, dword [ecx + 0xc]
mov ecx, esi
call dword [0x1006e578]
mov ecx, edi
call esi
add eax, 0x10
mov dword [ebp - 0x40], eax
mov byte [ebp - 4], 0x1c
lea ecx, [ebp - 0x40]
push 9
push str.Cab_file:
call fcn.10011800
call fcn.1000a250
mov edi, eax
test edi, edi
je 0x1004aba0
mov ecx, dword [edi]
mov esi, dword [ecx + 0xc]
mov ecx, esi
call dword [0x1006e578]
mov ecx, edi
call esi
add eax, 0x10
mov dword [ebp - 0x50], eax
mov byte [ebp - 4], 0x1f
lea ecx, [ebp - 0x50]
push 0
push 0x10093cf4
call fcn.10011800
mov esi, dword [ebp - 0x48]
mov eax, dword [esi + 0x38]
test eax, eax
je 0x1004a8c6
push str.AiEmbeddedDirectCall
push eax
call dword [sym.imp.msi.dll_MsiGetComponentStateW]
cmp eax, 1
je 0x1004a8c6
lea eax, [ebp - 0x40]
mov ecx, esi
push eax
call fcn.1001cfd0
mov byte [ebp - 4], 0x1c
or eax, 0xffffffff
mov ecx, dword [ebp - 0x50]
add ecx, 0xfffffff0
lock xadd dword [ecx + 0xc], eax
dec eax
test eax, eax
jg 0x1004a8f1
mov edi, dword [ecx]
push ecx
mov eax, dword [edi]
mov esi, dword [eax + 4]
mov ecx, esi
call dword [0x1006e578]
mov ecx, edi
call esi
mov byte [ebp - 4], 0xf
or eax, 0xffffffff
mov ecx, dword [ebp - 0x40]
add ecx, 0xfffffff0
lock xadd dword [ecx + 0xc], eax
dec eax
test eax, eax
jg 0x1004a91c
mov edi, dword [ecx]
push ecx
mov eax, dword [edi]
mov esi, dword [eax + 4]
mov ecx, esi
call dword [0x1006e578]
mov ecx, edi
call esi
call fcn.1001cdb0
cmp byte [eax + 0x1c], 0
je 0x1004aa34
call fcn.1001cdb0
mov dword [ebp - 0x48], eax
call fcn.1000a250
mov edi, eax
test edi, edi
je 0x1004aba0
mov ecx, dword [edi]
mov esi, dword [ecx + 0xc]
mov ecx, esi
call dword [0x1006e578]
mov ecx, edi
call esi
add eax, 0x10
mov dword [ebp - 0x28], eax
mov byte [ebp - 4], 0x26
lea ecx, [ebp]
lea edx, [ecx + 2]
mov ax, word [ecx]
add ecx, 2
test ax, ax
jne 0x1004a963
sub ecx, edx
lea eax, [ebp]
sar ecx, 1
push ecx
push eax
lea ecx, [ebp - 0x28]
call fcn.10011800
call fcn.1000a250
mov edi, eax
test edi, edi
je 0x1004aba0
mov ecx, dword [edi]
mov esi, dword [ecx + 0xc]
mov ecx, esi
call dword [0x1006e578]
mov ecx, edi
call esi
add eax, 0x10
mov dword [ebp - 0x54], eax
mov byte [ebp - 4], 0x29
lea ecx, [ebp - 0x54]
push 0
push 0x10093cf4
call fcn.10011800
mov esi, dword [ebp - 0x48]
mov eax, dword [esi + 0x38]
test eax, eax
je 0x1004a9de
push str.AiEmbeddedDirectCall
push eax
call dword [sym.imp.msi.dll_MsiGetComponentStateW]
cmp eax, 1
je 0x1004a9de
lea eax, [ebp - 0x28]
mov ecx, esi
push eax
call fcn.1001cfd0
mov byte [ebp - 4], 0x26
or eax, 0xffffffff
mov ecx, dword [ebp - 0x54]
add ecx, 0xfffffff0
lock xadd dword [ecx + 0xc], eax
dec eax
test eax, eax
jg 0x1004aa09
mov edi, dword [ecx]
push ecx
mov eax, dword [edi]
mov esi, dword [eax + 4]
mov ecx, esi
call dword [0x1006e578]
mov ecx, edi
call esi
mov byte [ebp - 4], 0xf
or eax, 0xffffffff
mov ecx, dword [ebp - 0x28]
add ecx, 0xfffffff0
lock xadd dword [ecx + 0xc], eax
dec eax
test eax, eax
jg 0x1004aa34
mov edi, dword [ecx]
push ecx
mov eax, dword [edi]
mov esi, dword [eax + 4]
mov ecx, esi
call dword [0x1006e578]
mov ecx, edi
call esi
cmp dword [ebp - 0x58], 1
mov edi, dword [ebp - 0x10]
mov esi, dword [ebp - 0x20]
je 0x1004aa5d
mov eax, dword [ebp - 0x18]
inc eax
add edi, eax
mov eax, ebx
xor ebx, ebx
mov dword [ebp - 0x10], edi
mov dword [ebp - 0x14], ebx
mov ecx, dword [ebp - 0x34]
mov dword [ebp - 0x18], ebx
mov dword [ecx + esi*4], eax
inc esi
mov dword [ebp - 0x20], esi
mov byte [ebp - 4], 0xe
test ebx, ebx
je 0x1004aa6c
push ebx
call dword [sym.imp.KERNEL32.dll_LocalFree]
mov dword [ebp - 0x14], 0
mov dword [ebp - 0x18], 0
jmp 0x1004a618
test edi, edi
cmove edi, ebx
mov byte [ebp - 4], 0x2e
xor ecx, ecx
mov eax, edi
mov edx, 2
mul edx
seto cl
neg ecx
or ecx, eax
push ecx
push 0x40
call dword [sym.imp.KERNEL32.dll_LocalAlloc]
mov ebx, eax
mov dword [ebp - 0x18], edi
xor eax, eax
mov dword [ebp - 0x14], ebx
sub esi, 1
mov dword [ebp - 0x20], esi
mov word [ebx], ax
js 0x1004ab06
mov esi, ebx
mov ebx, dword [ebp - 0x20]
nop dword [eax]
mov eax, dword [ebp - 0x34]
mov edx, dword [eax + ebx*4]
movzx eax, word [edx]
test ax, ax
je 0x1004aae1
mov ecx, edx
sub ecx, esi
mov word [esi], ax
add esi, 2
movzx eax, word [esi + ecx]
test ax, ax
jne 0x1004aad2
mov eax, 0x3b
mov edi, esi
mov word [esi], ax
add esi, 2
push edx
call dword [sym.imp.KERNEL32.dll_LocalFree]
sub ebx, 1
jns 0x1004aac0
mov ebx, dword [ebp - 0x14]
cmp esi, ebx
je 0x1004ab06
xor eax, eax
mov word [edi], ax
push ebx
push str.AI_DISABLED_FEATURES
push dword [ebp - 0x44]
call dword [sym.imp.msi.dll_MsiSummaryInfoGetPropertyCount]
mov byte [ebp - 4], 0xe
push ebx
call dword [sym.imp.KERNEL32.dll_LocalFree]
mov dword [ebp - 0x14], 0
mov dword [ebp - 0x18], 0
mov byte [ebp - 4], 0xd
mov eax, dword [ebp - 0x34]
test eax, eax
je 0x1004ab40
push eax
call dword [sym.imp.KERNEL32.dll_LocalFree]
mov dword [ebp - 0x34], 0
mov dword [ebp - 0x38], 0
mov byte [ebp - 4], 0xc
mov eax, dword [ebp - 0x5c]
test eax, eax
je 0x1004ab60
push eax
call dword [sym.imp.msi.dll_MsiConfigureFeatureFromDescriptorA]
mov byte [ebp - 4], 0xb
mov eax, dword [ebp - 0x1c]
test eax, eax
je 0x1004ab72
push eax
call dword [sym.imp.msi.dll_MsiConfigureFeatureFromDescriptorA]
mov byte [ebp - 4], 0
mov eax, dword [ebp - 0x24]
test eax, eax
je 0x1004ab84
push eax
call dword [sym.imp.msi.dll_MsiConfigureFeatureFromDescriptorA]
mov dword [ebp - 4], 0xffffffff
mov eax, dword [ebp - 0x2c]
test eax, eax
je 0x1004ab99
push eax
call dword [sym.imp.KERNEL32.dll_LocalFree]
xor eax, eax
jmp 0x1004a414
push 0x80004005
call fcn.10005390
int3