Function at 0x4033c0
Capabilities:
Delete registry value
Query or enumerate registry value

Disassembly:
push ebp
mov ebp, esp
push edi
push esi
mov esi, eax
push ebx
mov ebx, ecx
sub esp, 0x58
cmp ecx, 1
lea ecx, [ebp - 0x28]
mov dword [ebp - 0x20], 0
sbb eax, eax
mov dword [esp + 0x20], ecx
lea ecx, [ebp - 0x2c]
and eax, 0xfff2ffda
mov dword [ebp - 0x1c], 0
add eax, 0xf003f
mov dword [esp + 0x1c], ecx
mov dword [esp + 0x18], 0
mov dword [esp + 0x14], eax
mov dword [esp + 0x10], 0
mov dword [esp + 0xc], 0
mov dword [esp + 8], 0
mov dword [esp + 4], edx
mov dword [esp], esi
call dword [sym.imp.advapi32.dll_RegCreateKeyExW]
sub esp, 0x24
test eax, eax
jne 0x4034e0
cmp dword [ebp - 0x28], 1
je 0x4034b6
lea eax, [ebp - 0x20]
mov dword [esp + 0x2c], 0
mov dword [esp + 0x24], eax
lea eax, [ebp - 0x1c]
mov dword [esp + 0x20], eax
lea eax, [ebp - 0x24]
mov dword [esp + 0x1c], eax
mov eax, dword [ebp - 0x2c]
mov dword [esp + 0x28], 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], 0
mov dword [esp], eax
call dword [sym.imp.advapi32.dll_RegQueryInfoKeyW]
sub esp, 0x30
test eax, eax
jne 0x4034b6
mov edx, dword [ebp - 0x24]
test edx, edx
jne 0x40350e
test byte [0x40a160], 8
jne 0x40370e
xor edi, edi
xor esi, esi
mov dword [esp], edi
mov ebx, dword [sym.imp.ucrtbase.dll_free]
call ebx
mov dword [esp], esi
call ebx
mov eax, dword [ebp - 0x2c]
mov dword [esp], eax
call dword [sym.imp.advapi32.dll_RegCloseKey]
push eax
test byte [0x40a160], 8
jne 0x4034e8
lea esp, [ebp - 0xc]
pop ebx
pop esi
pop edi
pop ebp
ret
mov dword [esp + 0xc], str.Done._n
mov dword [esp + 8], str.process_run_key
mov dword [esp + 4], 0x40a160
mov dword [esp], 3
call sym._wine_dbg_log.constprop.0_1
jmp 0x4034e0
mov eax, dword [ebp - 0x20]
mov edi, dword [sym.imp.ucrtbase.dll_malloc]
mov dword [ebp - 0x30], edx
mov dword [esp], eax
call edi
mov edx, dword [ebp - 0x30]
test eax, eax
mov esi, eax
je 0x4037a1
mov eax, dword [ebp - 0x1c]
mov dword [ebp - 0x30], edx
inc eax
mov dword [ebp - 0x1c], eax
add eax, eax
mov dword [esp], eax
call edi
mov edi, eax
test eax, eax
je 0x40376b
mov eax, dword fs:[0x18]
mov edx, dword [ebp - 0x30]
mov dword [ebp - 0x34], eax
jmp 0x4035b3
test ebx, ebx
jne 0x403640
mov eax, dword [ebp - 0x10]
cmp eax, 1
je 0x403671
test byte [0x40a160], 2
je 0x4035a8
mov dword [esp + 0x14], eax
mov eax, dword [ebp - 0x24]
mov dword [esp + 0xc], str.Incorrect_type_of_value__lu___lu_._n
mov dword [esp + 0x10], eax
mov dword [esp + 8], str.process_run_key
mov dword [esp + 4], 0x40a160
mov dword [esp], 1
call sym._wine_dbg_log.constprop.0_1
lea esi, [esi]
mov edx, dword [ebp - 0x24]
test edx, edx
je 0x4034ba
mov eax, dword [ebp - 0x1c]
dec edx
mov dword [esp + 0x18], esi
mov dword [ebp - 0x24], edx
mov dword [ebp - 0x18], eax
mov eax, dword [ebp - 0x20]
mov dword [esp + 0x10], 0
mov dword [ebp - 0x14], eax
lea eax, [ebp - 0x14]
mov dword [esp + 0x1c], eax
lea eax, [ebp - 0x10]
mov dword [esp + 0x14], eax
lea eax, [ebp - 0x18]
mov dword [esp + 0xc], eax
mov eax, dword [ebp - 0x2c]
mov dword [esp + 8], edi
mov dword [esp + 4], edx
mov dword [esp], eax
call dword [sym.imp.advapi32.dll_RegEnumValueW]
sub esp, 0x20
test eax, eax
je 0x403558
test byte [0x40a160], 2
je 0x4035a8
mov dword [esp + 0x14], eax
mov eax, dword [ebp - 0x24]
mov dword [esp + 0xc], str.Couldnt_read_value__lu___ld_._n
mov dword [esp + 0x10], eax
mov dword [esp + 8], str.process_run_key
mov dword [esp + 4], 0x40a160
mov dword [esp], 1
call sym._wine_dbg_log.constprop.0_1
jmp 0x4035a8
mov eax, dword [ebp - 0x2c]
mov dword [esp + 4], edi
mov dword [esp], eax
call dword [sym.imp.advapi32.dll_RegDeleteValueW]
push edx
push edx
test eax, eax
je 0x403560
test byte [0x40a160], 2
jne 0x403737
cmp dword [ebp - 0x10], 1
jne 0x4035a8
mov edx, dword [ebp + 8]
mov eax, esi
call sym._runCmd.constprop.0
mov edx, eax
movzx eax, byte [0x40a160]
inc edx
je 0x4036bf
test al, 8
je 0x4035a8
mov eax, dword [ebp - 0x24]
mov dword [esp + 0xc], str.Done_processing_cmd__lu._n
mov dword [esp + 8], str.process_run_key
mov dword [esp + 0x10], eax
mov dword [esp + 4], 0x40a160
mov dword [esp], 3
call sym._wine_dbg_log.constprop.0_1
jmp 0x4035a8
test al, 2
je 0x403687
mov eax, dword [ebp - 0x34]
mov edx, dword [eax + 0x34]
mov eax, esi
mov dword [ebp - 0x30], edx
call sym._wine_dbgstr_wn.constprop.0_1
mov edx, dword [ebp - 0x30]
mov dword [esp + 0xc], str.Error_running_cmd__s___lu_._n
mov dword [esp + 0x10], eax
mov dword [esp + 0x14], edx
mov dword [esp + 8], str.process_run_key
mov dword [esp + 4], 0x40a160
mov dword [esp], 1
call sym._wine_dbg_log.constprop.0_1
movzx eax, byte [0x40a160]
jmp 0x403687
mov dword [esp + 0xc], str.No_commands_to_execute._n
mov dword [esp + 8], str.process_run_key
mov dword [esp + 4], 0x40a160
mov dword [esp], 3
call sym._wine_dbg_log.constprop.0_1
jmp 0x4034b6
mov dword [esp + 0x14], eax
mov eax, dword [ebp - 0x24]
mov dword [esp + 0xc], str.Couldnt_delete_value__lu___ld_._Running_command_anyways._n
mov dword [esp + 0x10], eax
mov dword [esp + 8], str.process_run_key
mov dword [esp + 4], 0x40a160
mov dword [esp], 1
call sym._wine_dbg_log.constprop.0_1
jmp 0x403560
test byte [0x40a160], 2
je 0x4034ba
mov dword [esp + 0xc], str.Couldnt_allocate_memory_for_the_value_names._n
mov dword [esp + 8], str.process_run_key
mov dword [esp + 4], 0x40a160
mov dword [esp], 1
call sym._wine_dbg_log.constprop.0_1
jmp 0x4034ba
test byte [0x40a160], 2
je 0x4034b6
mov dword [esp + 0xc], str.Couldnt_allocate_memory_for_the_commands_to_be_executed._n
xor edi, edi
mov dword [esp + 8], str.process_run_key
mov dword [esp + 4], 0x40a160
mov dword [esp], 1
call sym._wine_dbg_log.constprop.0_1
jmp 0x4034ba