Function at 0x4022e0
Capabilities:
Accept command line arguments
Create process on windows
Create process suspended
Delete registry key
Get common file path
Get installed programs
Terminate process

Disassembly:
lea ecx, [esp + 4]
and esp, 0xfffffff0
push dword [ecx - 4]
push ebp
mov ebp, esp
push edi
push esi
push ebx
push ecx
sub esp, 0xcb8
mov eax, dword [ecx + 4]
mov ebx, dword [ecx]
mov dword [esp], 0xffffffff
mov dword [ebp - 0xc80], eax
lea eax, [ebp - 0xc78]
mov dword [esp + 4], eax
call dword [sym.imp.kernel32.dll_IsWow64Process]
sub esp, 8
test eax, eax
je 0x40232e
mov eax, dword [ebp - 0xc78]
test eax, eax
jne 0x402648
call dword [0x4081a0]
cmp ebx, 1
jle 0x402730
mov eax, dword [ebp - 0xc80]
mov edi, dword [sym.imp.kernel32.dll_lstrcmpW]
mov esi, dword [eax + 4]
mov dword [esp + 4], str.__help
mov dword [esp], esi
call edi
mov dword [ebp - 0xc7c], eax
sub esp, 8
test eax, eax
je 0x402768
mov dword [esp + 4], 0x405194
mov dword [esp], esi
call edi
mov dword [ebp - 0xc7c], eax
sub esp, 8
test eax, eax
je 0x4028b0
mov dword [esp + 4], 0x4051a2
mov dword [esp], esi
call edi
mov dword [ebp - 0xc7c], eax
sub esp, 8
test eax, eax
jne 0x402b00
cmp ebx, 2
je 0x402890
mov eax, dword [ebp - 0xc80]
mov eax, dword [eax + 8]
mov dword [ebp - 0xc80], eax
call dbg.FetchUninstallInformation
mov edi, dword [section..bss]
test edi, edi
je 0x402a98
xor edi, edi
jmp 0x4023e7
add edi, 1
cmp edi, dword [section..bss]
jae 0x402a98
mov eax, dword [0x407004]
lea ebx, [edi + edi*4]
shl ebx, 2
mov esi, dword [eax + ebx + 4]
call dword [sym.imp.kernel32.dll_GetThreadLocale]
mov edx, dword [ebp - 0xc80]
mov dword [esp + 0x14], 0xffffffff
mov dword [esp + 0xc], 0xffffffff
mov dword [esp + 0x10], edx
mov dword [esp + 8], esi
mov dword [esp + 4], 1
mov dword [esp], eax
call dword [sym.imp.kernel32.dll_CompareStringW]
sub esp, 0x18
cmp eax, 2
jne 0x4023d8
mov edx, dword [0x407004]
add dword [edx + ebx + 0x10], 1
mov ebx, dword [section..bss]
cmp ebx, edi
jbe 0x402a98
movzx eax, byte [global___dbch]
test ebx, ebx
je 0x402a55
xor ebx, ebx
jmp 0x4024bf
mov eax, dword [ebp - 0xc6c]
mov dword [esp + 4], 0xffffffff
mov dword [esp], eax
call dword [sym.imp.kernel32.dll_WaitForSingleObject]
lea eax, [ebp - 0xc74]
sub esp, 8
mov dword [esp + 4], eax
mov eax, dword [ebp - 0xc6c]
mov dword [esp], eax
call dword [sym.imp.kernel32.dll_GetExitCodeProcess]
mov edx, eax
movzx eax, byte [global___dbch]
sub esp, 8
mov ecx, eax
and ecx, 8
jne 0x402ab8
add ebx, 1
cmp ebx, dword [section..bss]
jae 0x402a60
mov edx, dword [0x407004]
lea esi, [ebx + ebx*4]
mov ecx, eax
lea edi, [esi*4]
mov dword [ebp - 0xc84], esi
and ecx, 8
add edx, edi
mov dword [ebp - 0xc80], edi
mov esi, dword [edx + 0x10]
test esi, esi
je 0x4024aa
test cl, cl
jne 0x402900
xor eax, eax
mov ecx, 0x10
lea edi, [ebp - 0xc58]
rep stosd dword es:[edi], eax
mov eax, 1
mov dword [esp + 0x1c], 0
mov word [ebp - 0xc2c], ax
lea eax, [ebp - 0xc6c]
mov dword [esp + 0x24], eax
lea eax, [ebp - 0xc5c]
mov dword [esp + 0x20], eax
mov dword [esp + 0x18], 0
mov dword [esp + 0x14], 0
mov dword [esp + 0x10], 0
mov dword [esp + 0xc], 0
mov dword [esp + 8], 0
mov eax, dword [edx + 0xc]
mov dword [ebp - 0xc5c], 0x44
mov dword [esp + 4], eax
mov dword [esp], 0
call dword [sym.imp.kernel32.dll_CreateProcessW]
sub esp, 0x28
test eax, eax
jne 0x402460
mov dword [esp], 0
lea edi, [ebp - 0xc18]
call dword [sym.imp.kernel32.dll_GetModuleHandleW]
mov ecx, dword [0x408294]
sub esp, 4
mov esi, eax
mov dword [ebp - 0xc88], ecx
mov dword [esp + 0xc], 0xff
mov dword [esp + 8], edi
mov dword [esp + 4], 0x3e8
mov dword [esp], eax
call ecx
lea edx, [ebp - 0xa18]
mov ecx, dword [ebp - 0xc88]
sub esp, 0x10
mov dword [esp + 8], edx
mov dword [esp], esi
mov dword [esp + 0xc], 0xff
mov dword [esp + 4], 0x3e9
call ecx
mov esi, dword [ebp - 0xc80]
mov eax, dword [0x407004]
lea edx, [ebp - 0xa18]
sub esp, 0x10
mov eax, dword [eax + esi + 0xc]
lea esi, [ebp - 0x818]
mov dword [esp + 4], edx
mov dword [esp], esi
mov dword [esp + 8], eax
call dword [0x40829c]
mov dword [esp + 0xc], 0x24
mov dword [esp + 8], edi
mov dword [esp + 4], esi
mov dword [esp], 0
call dword [0x408298]
sub esp, 0x10
cmp eax, 6
je 0x402cb8
movzx eax, byte [global___dbch]
mov ecx, eax
and ecx, 8
jmp 0x4024aa
lea edx, [ebp - 0xc14]
xor eax, eax
mov ecx, 0x10
mov edi, edx
lea esi, [ebp - 0xc18]
rep stosd dword es:[edi], eax
lea edi, [ebp - 0x818]
mov dword [esp + 4], 0x104
mov dword [ebp - 0xc18], 0x44
mov dword [esp], edi
call dword [sym.imp.kernel32.dll_GetSystemDirectoryW]
sub esp, 8
mov dword [esp + 4], str.uninstaller.exe
mov dword [esp], edi
call dword [sym.imp.ucrtbase.dll_wcscat]
lea eax, [ebp - 0xc6c]
mov dword [esp], eax
call dword [sym.imp.kernel32.dll_Wow64DisableWow64FsRedirection]
sub esp, 4
call dword [sym.imp.kernel32.dll_GetCommandLineW]
lea ecx, [ebp - 0xc5c]
mov dword [esp], edi
mov dword [esp + 0x24], ecx
mov dword [esp + 0x20], esi
mov dword [esp + 0x1c], 0
mov dword [esp + 0x18], 0
mov dword [esp + 0x14], 0
mov dword [esp + 0x10], 0
mov dword [esp + 0xc], 0
mov dword [esp + 8], 0
mov dword [esp + 4], eax
call dword [sym.imp.kernel32.dll_CreateProcessW]
sub esp, 0x28
test eax, eax
jne 0x402df1
test byte [0x404000], 2
jne 0x402798
mov eax, dword [ebp - 0xc6c]
mov dword [esp], eax
call dword [sym.imp.kernel32.dll_Wow64RevertWow64FsRedirection]
sub esp, 4
call dword [0x4081a0]
cmp ebx, 1
jg 0x40233d
call dword [0x408290]
mov dword [esp + 0xc], 5
mov dword [esp + 8], str.appwiz.cpl
mov dword [esp + 4], 0
mov dword [esp], eax
call sym._Control_RunDLL_16
mov dword [ebp - 0xc7c], 1
sub esp, 0x10
jmp 0x402780
mov dword [esp], 0x7d3
call dbg.output_message
mov dword [esp], 0x7d4
call dbg.output_message
mov eax, dword [ebp - 0xc7c]
lea esp, [ebp - 0x10]
pop ecx
pop ebx
pop esi
pop edi
pop ebp
lea esp, [ecx - 4]
ret
mov eax, dword fs:[0x18]
mov eax, dword [eax + 0x34]
mov dword [ebp - 0xc84], eax
mov eax, edi
shr eax, 0x10
je 0x402b20
mov dword [esp + 4], 0xffffffff
mov dword [esp], edi
call dword [sym.imp.kernel32.dll_IsBadStringPtrW]
mov edx, str._invalid_
sub esp, 8
test eax, eax
jne 0x402b35
movzx edx, word [ebp - 0x818]
test dx, dx
je 0x402dd3
lea esi, [esi]
nop
mov ecx, eax
lea eax, [eax + 1]
cmp word [edi + ecx*2 + 2], 0
jne 0x4027e8
mov esi, 0x224c
mov dword [ebp - 0xc88], ebx
lea eax, [ebp - 0xa16]
mov word [ebp - 0xa18], si
lea esi, [ebp - 0x8f6]
mov dword [ebp - 0xc7c], esi
jmp 0x40285c
cmp dx, 9
je 0x402ca0
cmp dx, 0xa
jne 0x402c1e
mov esi, 0x6e5c
add eax, 2
mov word [eax - 2], si
lea esi, [ecx - 1]
cmp eax, dword [ebp - 0xc7c]
ja 0x402d60
test ecx, ecx
jle 0x402d60
movzx edx, word [edi]
mov ecx, esi
add edi, 2
cmp dx, 0xd
je 0x402c88
jbe 0x402820
cmp dx, 0x22
je 0x402c70
cmp dx, 0x5c
jne 0x402c11
mov ebx, 0x5c5c
add eax, 2
mov word [eax - 2], bx
jmp 0x402840
mov dword [esp], 0x7d1
call dbg.output_message
mov dword [ebp - 0xc7c], 1
jmp 0x402780
call dbg.FetchUninstallInformation
mov eax, dword [section..bss]
xor ebx, ebx
test eax, eax
je 0x402780
lea esi, [esi]
mov eax, dword [0x407004]
lea edx, [ebx + ebx*4]
add ebx, 1
lea eax, [eax + edx*4]
mov edx, dword [eax + 8]
mov dword [esp + 8], edx
mov eax, dword [eax + 4]
mov dword [esp], str._1_2_n
mov dword [esp + 4], eax
call sym._output_array.constprop.0
cmp ebx, dword [section..bss]
jb 0x4028c8
jmp 0x402780
mov esi, dword [edx + 8]
test esi, esi
je 0x402da8
mov eax, esi
shr eax, 0x10
je 0x402d30
mov dword [esp + 4], 0xffffffff
mov dword [esp], esi
call dword [sym.imp.kernel32.dll_IsBadStringPtrW]
mov edx, str._invalid_
sub esp, 8
test eax, eax
jne 0x402a1c
cmp word [esi], 0
je 0x402db2
lea esi, [esi]
mov edx, eax
lea eax, [eax + 1]
cmp word [esi + edx*2 + 2], 0
jne 0x402948
mov edi, 0x224c
lea eax, [ebp - 0x8f6]
mov dword [ebp - 0xc8c], ebx
lea ecx, [ebp - 0xa16]
mov word [ebp - 0xa18], di
mov dword [ebp - 0xc88], eax
jmp 0x4029b1
cmp ax, 9
je 0x402b88
cmp ax, 0xa
jne 0x402ba6
mov eax, 0x6e5c
add ecx, 2
mov word [ecx - 2], ax
lea eax, [edx - 1]
cmp ecx, dword [ebp - 0xc88]
ja 0x4029e8
test edx, edx
jle 0x4029e8
mov edx, eax
movzx eax, word [esi]
add esi, 2
cmp ax, 0xd
je 0x402b70
jbe 0x402980
cmp ax, 0x22
je 0x402c00
cmp ax, 0x5c
jne 0x402b99
mov ebx, 0x5c5c
add ecx, 2
mov word [ecx - 2], bx
jmp 0x4029a0
mov byte [ecx], 0x22
mov ebx, dword [ebp - 0xc8c]
test eax, eax
jle 0x402dcb
mov edx, 0x2e2e
mov byte [ecx + 3], 0x2e
lea eax, [ecx + 4]
mov word [ecx + 1], dx
mov byte [eax], 0
lea eax, [ebp - 0xa18]
mov dword [esp], eax
call dbg.__wine_dbg_strdup
mov edx, eax
mov dword [esp + 0x10], edx
mov dword [esp + 0xc], str.uninstalling__s_n
mov dword [esp + 8], str.UninstallProgram
mov dword [esp + 4], global___dbch
mov dword [esp], 3
call sym._wine_dbg_log.constprop.0
mov edx, dword [ebp - 0xc80]
add edx, dword [0x407004]
jmp 0x4024eb
and eax, 8
mov ecx, eax
lea esi, [esi]
test cl, cl
je 0x402780
mov dword [esp + 0xc], str.finished_uninstall_phase._n
mov dword [esp + 8], str.UninstallProgram
mov dword [esp + 4], global___dbch
mov dword [esp], 3
call sym._wine_dbg_log.constprop.0
jmp 0x402780
mov eax, dword [ebp - 0xc80]
mov dword [esp], 0x7d0
mov dword [esp + 4], eax
call dbg.output_message
jmp 0x402780
mov eax, dword [ebp - 0xc74]
mov dword [esp + 0x10], edx
mov dword [esp + 0xc], str._d:__08lx_n
mov dword [esp + 0x14], eax
mov dword [esp + 8], str.UninstallProgram
mov dword [esp + 4], global___dbch
mov dword [esp], 3
call sym._wine_dbg_log.constprop.0
movzx eax, byte [global___dbch]
mov ecx, eax
and ecx, 8
jmp 0x4024aa
mov dword [esp + 4], esi
mov dword [esp], 0x7d2
call dbg.output_message
mov dword [ebp - 0xc7c], 1
jmp 0x402780
movzx esi, di
mov dword [esp], str._04x
mov dword [esp + 4], esi
call sym._wine_dbg_sprintf.constprop.0
mov edx, eax
mov eax, dword [ebp - 0xc84]
mov dword [esp + 0x10], edx
mov dword [esp + 0xc], str.failed_to_restart_64_bit__s__err__ld_n
mov dword [esp + 0x14], eax
mov dword [esp + 8], 0x405254
mov dword [esp + 4], global___dbch
mov dword [esp], 1
call sym._wine_dbg_log.constprop.0
jmp 0x40270f
mov eax, 0x725c
add ecx, 2
mov word [ecx - 2], ax
jmp 0x4029a0
mov eax, 0x745c
add ecx, 2
mov word [ecx - 2], ax
jmp 0x4029a0
lea edi, [eax - 0x20]
cmp di, 0x5e
jbe 0x402d50
mov edi, eax
mov byte [ecx], 0x5c
add ecx, 5
shr di, 0xc
movzx edi, di
movzx ebx, byte [edi + str.0123456789abcdefwmain]
mov edi, eax
shr di, 8
and edi, 0xf
mov byte [ecx - 4], bl
movzx ebx, byte [edi + str.0123456789abcdefwmain]
mov edi, eax
and eax, 0xf
shr di, 4
movzx eax, byte [eax + str.0123456789abcdefwmain]
and edi, 0xf
mov byte [ecx - 3], bl
movzx ebx, byte [edi + str.0123456789abcdefwmain]
mov byte [ecx - 1], al
mov byte [ecx - 2], bl
jmp 0x4029a0
mov edi, 0x225c
add ecx, 2
mov word [ecx - 2], di
jmp 0x4029a0
lea esi, [edx - 0x20]
cmp si, 0x5e
jbe 0x402d98
mov esi, edx
mov byte [eax], 0x5c
add eax, 5
shr si, 0xc
movzx esi, si
movzx ebx, byte [esi + str.0123456789abcdefwmain]
mov esi, edx
shr si, 8
and esi, 0xf
mov byte [eax - 4], bl
movzx ebx, byte [esi + str.0123456789abcdefwmain]
mov esi, edx
and edx, 0xf
shr si, 4
movzx edx, byte [edx + str.0123456789abcdefwmain]
and esi, 0xf
mov byte [eax - 3], bl
movzx ebx, byte [esi + str.0123456789abcdefwmain]
mov byte [eax - 1], dl
mov byte [eax - 2], bl
jmp 0x402840
mov esi, 0x225c
add eax, 2
mov word [eax - 2], si
jmp 0x402840
mov ebx, 0x725c
add eax, 2
mov word [eax - 2], bx
jmp 0x402840
mov edx, 0x745c
add eax, 2
mov word [eax - 2], dx
jmp 0x402840
lea eax, [ebp - 0xc70]
mov esi, dword [ebp - 0xc84]
mov dword [esp + 0xc], 0x20019
mov dword [esp + 0x10], eax
mov eax, dword [0x407004]
mov dword [esp + 8], 0
mov dword [esp + 4], str.SoftwareMicrosoftWindowsCurrentVersionUninstall
mov eax, dword [eax + esi*4]
mov dword [esp], eax
call dword [sym.imp.advapi32.dll_RegOpenKeyExW]
mov eax, dword [0x407004]
mov esi, dword [ebp - 0xc80]
sub esp, 0x14
mov eax, dword [eax + esi + 4]
mov dword [esp + 4], eax
mov eax, dword [ebp - 0xc70]
mov dword [esp], eax
call dword [sym.imp.advapi32.dll_RegDeleteKeyW]
mov eax, dword [ebp - 0xc70]
sub esp, 8
mov dword [esp], eax
call dword [sym.imp.advapi32.dll_RegCloseKey]
sub esp, 4
jmp 0x402630
movzx esi, si
mov dword [esp], str._04x
mov dword [esp + 4], esi
call sym._wine_dbg_sprintf.constprop.0
mov edx, eax
jmp 0x402a1c
mov byte [ecx], al
add ecx, 1
jmp 0x4029a0
mov byte [eax], 0x22
mov ebx, dword [ebp - 0xc88]
test esi, esi
jle 0x402dec
mov ecx, 0x2e2e
mov byte [eax + 3], 0x2e
lea edx, [eax + 4]
mov word [eax + 1], cx
lea eax, [ebp - 0xa18]
mov byte [edx], 0
mov dword [esp], eax
call dbg.__wine_dbg_strdup
mov edx, eax
jmp 0x402b35
mov byte [eax], dl
add eax, 1
jmp 0x402840
mov edx, str._null_
jmp 0x402a1c
mov eax, 0x224c
mov byte [ebp - 0xa16], 0x22
lea ecx, [ebp - 0xa16]
mov word [ebp - 0xa18], ax
lea eax, [ecx + 1]
jmp 0x402a09
mov byte [ebp - 0xa16], 0x22
mov eax, 0x224c
mov word [ebp - 0xa18], ax
lea eax, [ebp - 0xa16]
lea edx, [eax + 1]
jmp 0x402d7d
test byte [0x404000], 8
jne 0x402e3d
mov eax, dword [ebp - 0xc5c]
mov dword [esp + 4], 0xffffffff
mov dword [esp], eax
call dword [sym.imp.kernel32.dll_WaitForSingleObject]
lea eax, [ebp - 0xa18]
push edi
push edi
mov dword [esp + 4], eax
mov eax, dword [ebp - 0xc5c]
mov dword [esp], eax
call dword [sym.imp.kernel32.dll_GetExitCodeProcess]
push eax
push eax
mov eax, dword [ebp - 0xa18]
mov dword [esp], eax
call dword [sym.imp.kernel32.dll_ExitProcess]
mov eax, edi
call sym._wine_dbgstr_wn.constprop.0
mov dword [esp + 0xc], str.restarting__s_n
mov dword [esp + 0x10], eax
mov dword [esp + 8], 0x405254
mov dword [esp + 4], global___dbch
mov dword [esp], 3
call sym._wine_dbg_log.constprop.0
jmp 0x402dfa