Function at 0x403c40
Capabilities:
Delete registry value
Get process heap flags
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, 0x6c
cmp ecx, 1
lea ecx, [ebp - 0x34]
mov dword [ebp - 0x2c], 0
sbb eax, eax
mov dword [esp + 0x20], ecx
lea ecx, [ebp - 0x38]
and eax, 0xfff2ffda
mov dword [ebp - 0x28], 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 0x403d9a
cmp dword [ebp - 0x34], 1
je 0x403d39
lea eax, [ebp - 0x2c]
mov dword [esp + 0x2c], 0
mov dword [esp + 0x24], eax
lea eax, [ebp - 0x28]
mov dword [esp + 0x20], eax
lea eax, [ebp - 0x30]
mov dword [esp + 0x1c], eax
mov eax, dword [ebp - 0x38]
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 0x403d39
cmp dword [ebp - 0x30], 0
jne 0x403dc8
test byte [0x40a160], 8
jne 0x403fe7
xor edi, edi
xor esi, esi
mov edx, dword fs:[0x18]
mov dword [esp + 8], edi
mov ebx, dword [sym.imp.kernelbase.dll_HeapFree]
mov dword [esp + 4], 0
mov eax, dword [edx + 0x30]
mov dword [ebp - 0x3c], edx
mov eax, dword [eax + 0x18]
mov dword [esp], eax
call ebx
mov edx, dword [ebp - 0x3c]
sub esp, 0xc
mov dword [esp + 8], esi
mov dword [esp + 4], 0
mov eax, dword [edx + 0x30]
mov eax, dword [eax + 0x18]
mov dword [esp], eax
call ebx
mov eax, dword [ebp - 0x38]
sub esp, 0xc
mov dword [esp], eax
call dword [sym.imp.advapi32.dll_RegCloseKey]
push eax
test byte [0x40a160], 8
jne 0x403da2
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 0x403d9a
mov eax, dword fs:[0x18]
mov edi, eax
mov dword [ebp - 0x3c], eax
mov eax, dword [ebp - 0x2c]
mov dword [esp + 4], 0
mov dword [esp + 8], eax
mov eax, dword [edi + 0x30]
mov edi, dword [sym.imp.kernelbase.dll_HeapAlloc]
mov eax, dword [eax + 0x18]
mov dword [esp], eax
call edi
sub esp, 0xc
mov esi, eax
test eax, eax
je 0x40407a
mov eax, dword [ebp - 0x28]
mov dword [esp + 4], 0
inc eax
mov dword [ebp - 0x28], eax
add eax, eax
mov dword [esp + 8], eax
mov eax, dword [ebp - 0x3c]
mov eax, dword [eax + 0x30]
mov eax, dword [eax + 0x18]
mov dword [esp], eax
call edi
sub esp, 0xc
mov edi, eax
test eax, eax
je 0x404044
mov eax, dword [ebp - 0x30]
test eax, eax
je 0x403d3d
mov edx, dword [ebp - 0x28]
dec eax
lea ecx, [ebp - 0x20]
mov dword [esp + 0x18], esi
mov dword [ebp - 0x30], eax
mov dword [ebp - 0x24], edx
mov edx, dword [ebp - 0x2c]
mov dword [esp + 0x1c], ecx
lea ecx, [ebp - 0x1c]
mov dword [esp + 4], eax
mov eax, dword [ebp - 0x38]
mov dword [esp + 0x14], ecx
lea ecx, [ebp - 0x24]
mov dword [ebp - 0x20], edx
mov dword [esp + 0x10], 0
mov dword [esp + 0xc], ecx
mov dword [esp + 8], edi
mov dword [esp], eax
call dword [sym.imp.advapi32.dll_RegEnumValueW]
sub esp, 0x20
test eax, eax
jne 0x403ed8
test ebx, ebx
jne 0x403f19
mov eax, dword [ebp - 0x1c]
cmp eax, 1
je 0x403f4a
test byte [0x40a160], 2
je 0x403e30
mov dword [esp + 0x14], eax
mov eax, dword [ebp - 0x30]
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
jmp 0x403e30
test byte [0x40a160], 2
je 0x403e30
mov dword [esp + 0x14], eax
mov eax, dword [ebp - 0x30]
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 0x403e30
mov eax, dword [ebp - 0x38]
mov dword [esp + 4], edi
mov dword [esp], eax
call dword [sym.imp.advapi32.dll_RegDeleteValueW]
push edx
push edx
test eax, eax
je 0x403e8f
test byte [0x40a160], 2
jne 0x404010
cmp dword [ebp - 0x1c], 1
jne 0x403e30
mov edx, dword [ebp + 8]
mov eax, esi
call sym._runCmd.constprop.0
mov edx, eax
movzx eax, byte [0x40a160]
inc edx
je 0x403f98
test al, 8
je 0x403e30
mov eax, dword [ebp - 0x30]
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 0x403e30
test al, 2
je 0x403f60
mov eax, dword [ebp - 0x3c]
mov edx, dword [eax + 0x34]
mov eax, esi
mov dword [ebp - 0x40], edx
call sym._wine_dbgstr_wn.constprop.0_1
mov edx, dword [ebp - 0x40]
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 0x403f60
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 0x403d39
mov dword [esp + 0x14], eax
mov eax, dword [ebp - 0x30]
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 0x403e8f
test byte [0x40a160], 2
je 0x403d3d
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 0x403d3d
test byte [0x40a160], 2
je 0x403d39
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 0x403d3d