Function at 0x42bf40
Capabilities:
Check if file exists
Get common file path
Query or enumerate registry value

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 0x4ad18a
mov eax, dword fs:[0]
push eax
push ebx
sub esp, 0x4f8
mov eax, dword [0x4e006c]
xor eax, ebp
mov dword [ebp - 0x14], eax
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
push 0x52
xorps xmm0, xmm0
mov dword [ebp - 0x4a4], 0
xor eax, eax
movq qword [ebp - 0x250], xmm0
push str.SOFTWAREMicrosoftWindowsCurrentVersionWindowsUpdateAuto_UpdateRebootRequired
lea ecx, [ebp - 0x508]
mov dword [ebp - 0x248], 0
mov dword [ebp - 0x4f8], 0
mov dword [ebp - 0x4f4], 7
mov word [ebp - 0x508], ax
call fcn.00407d50
mov dword [ebp - 4], 0
lea ecx, [ebp - 0x4f0]
push 0x51
xor eax, eax
mov dword [ebp - 0x4e0], 0
push str.SOFTWAREMicrosoftWindowsCurrentVersionComponent_Based_ServicingRebootPending
mov dword [ebp - 0x4dc], 7
mov word [ebp - 0x4f0], ax
call fcn.00407d50
mov byte [ebp - 4], 1
lea ecx, [ebp - 0x4d8]
push 0x54
xor eax, eax
mov dword [ebp - 0x4c8], 0
push str.SOFTWAREMicrosoftWindowsCurrentVersionComponent_Based_ServicingRebootInProgress
mov dword [ebp - 0x4c4], 7
mov word [ebp - 0x4d8], ax
call fcn.00407d50
mov dword [ebp - 4], 2
lea eax, [ebp - 0x4c0]
push dword [ebp - 0x228]
lea ecx, [ebp - 0x250]
mov dword [ebp - 0x250], 0
push eax
lea eax, [ebp - 0x508]
mov dword [ebp - 0x24c], 0
push eax
mov dword [ebp - 0x248], 0
call fcn.0043eb00
push fcn.00405100
push 3
push 0x18
lea eax, [ebp - 0x508]
mov byte [ebp - 4], 4
push eax
call fcn.0046a859
mov eax, dword [ebp - 0x24c]
mov esi, dword [ebp - 0x250]
mov edi, dword [sym.imp.ADVAPI32.dll_RegCloseKey]
mov dword [ebp - 0x22c], eax
cmp esi, eax
je 0x42c1ef
nop word [eax + eax]
cmp dword [esi + 0x14], 8
mov eax, esi
mov byte [ebp - 0x4a5], 0
mov dword [ebp - 0x224], 0
jb 0x42c0db
mov eax, dword [esi]
lea ecx, [ebp - 0x224]
push ecx
push 0x20119
push 0
push eax
push 0x80000002
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExW]
mov edi, eax
test edi, edi
jne 0x42c115
push dword [ebp - 0x224]
mov edi, dword [sym.imp.ADVAPI32.dll_RegCloseKey]
mov byte [ebp - 0x4a5], 1
call edi
jmp 0x42c1d3
cmp edi, 2
je 0x42c1cd
lea ecx, [ebp - 0x4c0]
call fcn.0045b1b0
mov byte [ebp - 4], 5
cmp dword [eax + 0x14], 8
mov ecx, dword [eax + 0x10]
jb 0x42c138
mov eax, dword [eax]
push ecx
mov edx, eax
mov ecx, 0x4e45b8
call fcn.0040d910
add esp, 4
mov edx, str.d:jenkinsworkspace_a_mb4_mbsetup_srcmbsetupmbsetup.cpp
mov ecx, eax
call fcn.0040be10
mov edx, str.:.
mov ecx, eax
call fcn.0040be10
push 0x36e
mov ecx, eax
call fcn.00408660
mov edx, str.:_Error_RegOpenKeyEx:
mov ecx, eax
call fcn.0040be10
push edi
mov ecx, eax
call fcn.004084b0
push eax
call fcn.0040c180
mov byte [ebp - 4], 4
add esp, 4
mov edx, dword [ebp - 0x4ac]
cmp edx, 8
jb 0x42c1cd
mov ecx, dword [ebp - 0x4c0]
lea edx, [edx*2 + 2]
mov eax, ecx
cmp edx, 0x1000
jb 0x42c1c3
mov ecx, dword [ecx - 4]
add edx, 0x23
sub eax, ecx
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x42c933
push edx
push ecx
call fcn.0046a609
add esp, 8
mov edi, dword [sym.imp.ADVAPI32.dll_RegCloseKey]
cmp byte [ebp - 0x4a5], 0
jne 0x42c27a
add esi, 0x18
cmp esi, dword [ebp - 0x22c]
jne 0x42c0c0
push 0x48
xor eax, eax
mov dword [ebp - 0x4b0], 0
push str.SOFTWAREMicrosoftWindowsCurrentVersionWindowsUpdateServicesPending
lea ecx, [ebp - 0x4c0]
mov dword [ebp - 0x4ac], 7
mov word [ebp - 0x4c0], ax
call fcn.00407d50
lea ecx, [ebp - 0x4c0]
mov byte [ebp - 4], 7
call fcn.0042b560
mov byte [ebp - 4], 4
mov edx, dword [ebp - 0x4ac]
mov byte [ebp - 0x4a5], al
cmp edx, 8
jb 0x42c354
mov ecx, dword [ebp - 0x4c0]
lea edx, [edx*2 + 2]
mov eax, ecx
cmp edx, 0x1000
jb 0x42c344
mov ecx, dword [ecx - 4]
add edx, 0x23
sub eax, ecx
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x42c92e
jmp 0x42c344
lea ecx, [ebp - 0x4c0]
call fcn.0045b1b0
mov byte [ebp - 4], 6
cmp dword [eax + 0x14], 8
mov edi, dword [eax + 0x10]
jb 0x42c294
mov eax, dword [eax]
push edi
mov edx, eax
mov ecx, 0x4e45b8
call fcn.0040d910
add esp, 4
mov edx, str.d:jenkinsworkspace_a_mb4_mbsetup_srcmbsetupmbsetup.cpp
mov ecx, eax
call fcn.0040be10
mov edx, str.:.
mov ecx, eax
call fcn.0040be10
push 0x3fb
mov ecx, eax
call fcn.00408660
mov edx, str.:_HKLM_subkey_
mov ecx, eax
call fcn.0040be10
cmp dword [esi + 0x14], 8
mov ecx, dword [esi + 0x10]
jb 0x42c2df
mov esi, dword [esi]
push ecx
mov edx, esi
mov ecx, eax
call fcn.0040d910
add esp, 4
mov edx, str._exists
mov ecx, eax
call fcn.0040be10
push eax
call fcn.0040c180
mov edx, dword [ebp - 0x4ac]
add esp, 4
cmp edx, 8
jb 0x42c4de
mov ecx, dword [ebp - 0x4c0]
lea edx, [edx*2 + 2]
mov eax, ecx
cmp edx, 0x1000
jb 0x42c4d4
mov ecx, dword [ecx - 4]
add edx, 0x23
sub eax, ecx
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x42c933
jmp 0x42c4d4
push edx
push ecx
call fcn.0046a609
mov al, byte [ebp - 0x4a5]
add esp, 8
test al, al
je 0x42c3c8
lea ecx, [ebp - 0x4c0]
call fcn.0045b1b0
mov byte [ebp - 4], 8
cmp dword [eax + 0x14], 8
mov ecx, dword [eax + 0x10]
jb 0x42c372
mov eax, dword [eax]
push ecx
mov edx, eax
mov ecx, 0x4e45b8
call fcn.0040d910
add esp, 4
mov edx, str.d:jenkinsworkspace_a_mb4_mbsetup_srcmbsetupmbsetup.cpp
mov ecx, eax
call fcn.0040be10
mov edx, str.:.
mov ecx, eax
call fcn.0040be10
push 0x403
mov ecx, eax
call fcn.00408660
mov edx, str.:_HKLM_key_
mov ecx, eax
call fcn.0040be10
mov edx, str.SOFTWAREMicrosoftWindowsCurrentVersionWindowsUpdateServicesPending
mov ecx, eax
call fcn.0041e6c0
mov edx, str._has_subkeys
jmp 0x42c2f1
lea eax, [ebp - 0x4a4]
push eax
push 0x20119
push 0
push str.SOFTWAREMicrosoftUpdates
push 0x80000002
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExW]
test eax, eax
jne 0x42c4f2
mov dword [ebp - 0x224], eax
lea eax, [ebp - 0x22c]
push eax
lea eax, [ebp - 0x224]
mov dword [ebp - 0x228], 4
push eax
lea eax, [ebp - 0x228]
mov dword [ebp - 0x22c], 4
push eax
push 0
push str.UpdateExeVolatile
push dword [ebp - 0x4a4]
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExW]
test eax, eax
jne 0x42c4ea
cmp dword [ebp - 0x224], eax
jbe 0x42c4ea
push dword [ebp - 0x4a4]
call edi
lea ecx, [ebp - 0x4c0]
call fcn.0045b1b0
mov byte [ebp - 4], 9
cmp dword [eax + 0x14], 8
mov ecx, dword [eax + 0x10]
jb 0x42c466
mov eax, dword [eax]
push ecx
mov edx, eax
mov ecx, 0x4e45b8
call fcn.0040d910
add esp, 4
mov edx, str.d:jenkinsworkspace_a_mb4_mbsetup_srcmbsetupmbsetup.cpp
mov ecx, eax
call fcn.0040be10
mov edx, str.:.
mov ecx, eax
call fcn.0040be10
push 0x415
mov ecx, eax
call fcn.00408660
mov edx, str.:_HKLM_key_
mov ecx, eax
call fcn.0040be10
mov edx, str.SOFTWAREMicrosoftUpdates
mov ecx, eax
call fcn.0041e6c0
mov edx, str._has_
mov ecx, eax
call fcn.0040be10
mov edx, str.UpdateExeVolatile
mov ecx, eax
call fcn.0041e6c0
mov edx, str._value
jmp 0x42c2f1
push edx
push ecx
call fcn.0046a609
add esp, 8
mov byte [ebp - 0x4a5], 1
jmp 0x42c8ff
push dword [ebp - 0x4a4]
call edi
push 0x208
lea eax, [ebp - 0x220]
push 0
push eax
call fcn.00482710
add esp, 0xc
lea eax, [ebp - 0x220]
push 0x104
push eax
call dword [sym.imp.KERNEL32.dll_GetWindowsDirectoryW]
test eax, eax
jne 0x42c5ed
call dword [sym.imp.KERNEL32.dll_GetLastError]
lea ecx, [ebp - 0x4c0]
mov esi, eax
call fcn.0045b1b0
mov byte [ebp - 4], 0xa
cmp dword [eax + 0x14], 8
mov ecx, dword [eax + 0x10]
jb 0x42c544
mov eax, dword [eax]
push ecx
mov edx, eax
mov ecx, 0x4e45b8
call fcn.0040d910
add esp, 4
mov edx, str.d:jenkinsworkspace_a_mb4_mbsetup_srcmbsetupmbsetup.cpp
mov ecx, eax
call fcn.0040be10
mov edx, str.:.
mov ecx, eax
call fcn.0040be10
push 0x421
mov ecx, eax
call fcn.00408660
mov edx, str.:_Error
mov ecx, eax
call fcn.0040be10
push esi
mov ecx, eax
call fcn.0041e4e0
mov edx, str._calling_GetWindowsDirectory
mov ecx, eax
call fcn.0040be10
push eax
call fcn.0040c180
mov edx, dword [ebp - 0x4ac]
add esp, 4
cmp edx, 8
jb 0x42c5e1
mov ecx, dword [ebp - 0x4c0]
lea edx, [edx*2 + 2]
mov eax, ecx
cmp edx, 0x1000
jb 0x42c5d7
mov ecx, dword [ecx - 4]
add edx, 0x23
sub eax, ecx
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x42c933
push edx
push ecx
call fcn.0046a609
add esp, 8
mov byte [ebp - 0x4a5], 0
jmp 0x42c8ff
xor eax, eax
mov dword [ebp - 0x234], 0
lea ecx, [ebp - 0x220]
mov dword [ebp - 0x230], 7
mov word [ebp - 0x244], ax
lea edx, [ecx + 2]
mov ax, word [ecx]
add ecx, 2
test ax, ax
jne 0x42c613
sub ecx, edx
lea eax, [ebp - 0x220]
sar ecx, 1
push ecx
push eax
lea ecx, [ebp - 0x244]
call fcn.00407d50
mov byte [ebp - 4], 0xb
lea eax, [ebp - 0x244]
mov edx, dword [ebp - 0x230]
cmp edx, 8
mov esi, dword [ebp - 0x244]
mov ecx, dword [ebp - 0x234]
cmovae eax, esi
cmp word [eax + ecx*2 - 2], 0x5c
je 0x42c69c
cmp ecx, edx
jae 0x42c681
lea eax, [ecx + 1]
cmp edx, 8
mov dword [ebp - 0x234], eax
lea eax, [ebp - 0x244]
cmovae eax, esi
mov dword [eax + ecx*2], 0x5c
jmp 0x42c69c
push 0x5c
mov byte [ebp - 0x228], 0
push dword [ebp - 0x228]
push ecx
lea ecx, [ebp - 0x244]
call fcn.00414de0
push 0x14
push str.WinSxSpending.xml
lea ecx, [ebp - 0x244]
call fcn.00415840
push 0x250
lea eax, [ebp - 0x4a0]
push 0
push eax
call fcn.00482710
add esp, 0xc
lea ecx, [ebp - 0x4a0]
cmp dword [ebp - 0x230], 8
lea eax, [ebp - 0x244]
cmovae eax, dword [ebp - 0x244]
push ecx
push eax
call dword [sym.imp.KERNEL32.dll_FindFirstFileW]
mov esi, eax
cmp esi, 0xffffffff
je 0x42c7d7
lea ecx, [ebp - 0x4c0]
call fcn.0045b1b0
mov byte [ebp - 4], 0xc
cmp dword [eax + 0x14], 8
mov ecx, dword [eax + 0x10]
jb 0x42c70b
mov eax, dword [eax]
push ecx
mov edx, eax
mov ecx, 0x4e45b8
call fcn.0040d910
add esp, 4
mov edx, str.d:jenkinsworkspace_a_mb4_mbsetup_srcmbsetupmbsetup.cpp
mov ecx, eax
call fcn.0040be10
mov edx, str.:.
mov ecx, eax
call fcn.0040be10
push 0x433
mov ecx, eax
call fcn.00408660
mov edx, str.:_Found_at_least_one_match_for_
mov ecx, eax
call fcn.0040be10
cmp dword [ebp - 0x230], 8
lea edx, [ebp - 0x244]
push dword [ebp - 0x234]
cmovae edx, dword [ebp - 0x244]
mov ecx, eax
call fcn.0040d910
add esp, 4
mov edx, 0x4c3d0c
mov ecx, eax
call fcn.0040be10
push eax
call fcn.0040c180
mov edx, dword [ebp - 0x4ac]
add esp, 4
cmp edx, 8
jb 0x42c7c4
mov ecx, dword [ebp - 0x4c0]
lea edx, [edx*2 + 2]
mov eax, ecx
cmp edx, 0x1000
jb 0x42c7ba
mov ecx, dword [ecx - 4]
add edx, 0x23
sub eax, ecx
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x42c933
push edx
push ecx
call fcn.0046a609
add esp, 8
push esi
call dword [sym.imp.KERNEL32.dll_FindClose]
mov byte [ebp - 0x4a5], 1
jmp 0x42c8a6
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov esi, eax
cmp esi, 2
je 0x42c89f
lea ecx, [ebp - 0x4c0]
call fcn.0045b1b0
mov byte [ebp - 4], 0xd
cmp dword [eax + 0x14], 8
mov ecx, dword [eax + 0x10]
jb 0x42c802
mov eax, dword [eax]
push ecx
mov edx, eax
mov ecx, 0x4e45b8
call fcn.0040d910
add esp, 4
mov edx, str.d:jenkinsworkspace_a_mb4_mbsetup_srcmbsetupmbsetup.cpp
mov ecx, eax
call fcn.0040be10
mov edx, str.:.
mov ecx, eax
call fcn.0040be10
push 0x43c
mov ecx, eax
call fcn.00408660
mov edx, str.:_Error
mov ecx, eax
call fcn.0040be10
push esi
mov ecx, eax
call fcn.0041e4e0
mov edx, str._calling_FindFirstFile
mov ecx, eax
call fcn.0040be10
push eax
call fcn.0040c180
mov edx, dword [ebp - 0x4ac]
add esp, 4
cmp edx, 8
jb 0x42c89f
mov ecx, dword [ebp - 0x4c0]
lea edx, [edx*2 + 2]
mov eax, ecx
cmp edx, 0x1000
jb 0x42c895
mov ecx, dword [ecx - 4]
add edx, 0x23
sub eax, ecx
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x42c933
push edx
push ecx
call fcn.0046a609
add esp, 8
mov byte [ebp - 0x4a5], 0
mov edx, dword [ebp - 0x230]
cmp edx, 8
jb 0x42c8e2
mov ecx, dword [ebp - 0x244]
lea edx, [edx*2 + 2]
mov eax, ecx
cmp edx, 0x1000
jb 0x42c8d8
mov ecx, dword [ecx - 4]
add edx, 0x23
sub eax, ecx
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x42c933
push edx
push ecx
call fcn.0046a609
add esp, 8
xor eax, eax
mov dword [ebp - 0x234], 0
mov dword [ebp - 0x230], 7
mov word [ebp - 0x244], ax
lea ecx, [ebp - 0x250]
call fcn.0043c8a0
mov al, byte [ebp - 0x4a5]
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
mov ecx, dword [ebp - 0x14]
xor ecx, ebp
call fcn.0046a0e8
mov esp, ebp
pop ebp
mov esp, ebx
pop ebx
ret
call fcn.0048552c
call fcn.0048552c
int3