Function at 0x402f70
Capabilities:
Create process on windows
Create process suspended
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, 0xcc
cmp ecx, 1
mov dword [ebp - 0x80], 0
lea ecx, [ebp - 0x8c]
sbb eax, eax
mov dword [ebp - 0x84], 0
and eax, 0xfff2ffda
mov dword [esp + 0x20], ecx
lea ecx, [ebp - 0x90]
add eax, 0xf003f
mov dword [esp + 0x18], 0
mov dword [esp + 0x1c], ecx
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 0x4030c2
cmp dword [ebp - 0x8c], 1
mov eax, dword [ebp - 0x90]
je 0x403065
lea edx, [ebp - 0x84]
xor edi, edi
xor esi, esi
mov dword [esp], eax
mov dword [esp + 0x24], edx
lea edx, [ebp - 0x80]
mov dword [esp + 0x20], edx
lea edx, [ebp - 0x88]
mov dword [esp + 0x2c], esi
mov dword [esp + 0x28], esi
mov dword [esp + 0x1c], edx
mov dword [esp + 0x18], edi
mov dword [esp + 0x14], edi
mov dword [esp + 0x10], edi
mov dword [esp + 0xc], edi
mov dword [esp + 8], edi
mov dword [esp + 4], edi
call dword [sym.imp.advapi32.dll_RegQueryInfoKeyW]
sub esp, 0x30
test eax, eax
jne 0x403065
mov edi, dword [ebp - 0x88]
test edi, edi
jne 0x4030ca
test byte [0x408010], 8
jne 0x40348b
xor ebx, ebx
xor esi, esi
mov dword [ebp - 0xa0], ebx
mov eax, dword [ebp - 0xa0]
mov ebx, dword [sym.imp.ucrtbase.dll_free]
mov dword [esp], eax
call ebx
mov dword [esp], esi
call ebx
mov eax, dword [ebp - 0x90]
mov dword [esp], eax
call dword [sym.imp.advapi32.dll_RegCloseKey]
push eax
test byte [0x408010], 8
je 0x4030c2
mov dword [esp + 0xc], str.Done._n
mov dword [esp + 8], str.process_run_key
mov dword [esp + 4], 0x408010
mov dword [esp], 3
call fcn.00402b80
lea esp, [ebp - 0xc]
pop ebx
pop esi
pop edi
pop ebp
ret
mov edx, dword [sym.imp.ucrtbase.dll_malloc]
mov eax, dword [ebp - 0x84]
mov dword [esp], eax
mov dword [ebp - 0x9c], edx
call edx
mov edx, dword [ebp - 0x9c]
test eax, eax
mov esi, eax
je 0x40354a
mov eax, dword [ebp - 0x80]
add eax, 1
mov dword [ebp - 0x80], eax
add eax, eax
mov dword [esp], eax
call edx
mov dword [ebp - 0xa0], eax
test eax, eax
je 0x403514
mov dword [ebp - 0x9c], ebx
mov ebx, eax
jmp 0x403155
mov ecx, dword [ebp - 0x9c]
test ecx, ecx
jne 0x4031f6
mov eax, dword [ebp - 0x74]
cmp eax, 1
je 0x40322a
mov edi, dword [ebp - 0x88]
test byte [0x408010], 2
jne 0x40330a
test edi, edi
je 0x40306f
mov eax, dword [ebp - 0x80]
sub edi, 1
mov dword [ebp - 0x88], edi
mov dword [ebp - 0x7c], eax
mov eax, dword [ebp - 0x84]
mov dword [ebp - 0x78], eax
lea eax, [ebp - 0x78]
mov dword [esp + 0x1c], eax
lea eax, [ebp - 0x74]
mov dword [esp + 0x14], eax
lea eax, [ebp - 0x7c]
mov dword [esp + 0x18], esi
mov dword [esp + 0x10], 0
mov dword [esp + 0xc], eax
mov dword [esp + 8], ebx
mov dword [esp + 4], edi
mov eax, dword [ebp - 0x90]
mov dword [esp], eax
call dword [sym.imp.advapi32.dll_RegEnumValueW]
sub esp, 0x20
test eax, eax
je 0x403120
mov edi, dword [ebp - 0x88]
test byte [0x408010], 2
je 0x40314d
mov dword [esp + 0x14], eax
mov dword [esp + 0x10], edi
mov dword [esp + 0xc], str.Couldnt_read_value__lu___ld_._n
mov dword [esp + 8], str.process_run_key
mov dword [esp + 4], 0x408010
mov dword [esp], 1
call fcn.00402b80
mov edi, dword [ebp - 0x88]
jmp 0x40314d
mov dword [esp + 4], ebx
mov eax, dword [ebp - 0x90]
mov dword [esp], eax
call dword [sym.imp.advapi32.dll_RegDeleteValueW]
push edx
push edx
test eax, eax
je 0x40312e
test byte [0x408010], 2
jne 0x4034b4
cmp dword [ebp - 0x74], 1
jne 0x4032ff
xor edi, edi
xor eax, eax
mov ecx, 0x10
mov dword [ebp - 0x5c], 0x44
mov dword [ebp - 0x70], edi
lea edx, [ebp - 0x6c]
lea edi, [ebp - 0x58]
rep stosd dword es:[edi], eax
mov edi, edx
mov ecx, 4
rep stosd dword es:[edi], eax
lea eax, [ebp - 0x5c]
mov dword [esp + 0x24], edx
mov dword [esp + 0x20], eax
xor eax, eax
mov dword [esp + 0x1c], eax
mov dword [esp + 0x18], eax
mov dword [esp + 0x14], eax
mov dword [esp + 0x10], eax
mov dword [esp + 0xc], eax
mov dword [esp + 8], eax
xor eax, eax
mov dword [esp + 4], esi
mov dword [esp], eax
call dword [sym.imp.kernelbase.dll_CreateProcessW]
sub esp, 0x28
test eax, eax
je 0x40331f
test byte [0x408010], 8
jne 0x4033aa
cmp dword [ebp + 8], 0
jne 0x40337a
mov eax, dword [ebp - 0x68]
mov edi, dword [sym.imp.kernelbase.dll_CloseHandle]
mov dword [esp], eax
call edi
push edx
mov eax, dword [ebp - 0x6c]
mov dword [esp], eax
call edi
push ecx
cmp dword [ebp - 0x70], 0xffffffff
movzx eax, byte [0x408010]
je 0x40332e
mov edi, dword [ebp - 0x88]
test al, 8
je 0x40314d
mov dword [esp + 0x10], edi
mov dword [esp + 0xc], str.Done_processing_cmd__lu._n
mov dword [esp + 8], str.process_run_key
mov dword [esp + 4], 0x408010
mov dword [esp], 3
call fcn.00402b80
mov edi, dword [ebp - 0x88]
jmp 0x40314d
mov dword [esp + 0x14], eax
mov dword [esp + 0x10], edi
mov dword [esp + 0xc], str.Incorrect_type_of_value__lu___lu_._n
jmp 0x4031cf
movzx eax, byte [0x408010]
test al, 4
jne 0x40341b
test al, 2
je 0x4032c9
mov eax, dword fs:[0x18]
mov edi, dword [eax + 0x34]
mov eax, esi
call fcn.004027f0
mov dword [esp + 0xc], str.Error_running_cmd__s___lu_._n
mov dword [esp + 0x10], eax
mov dword [esp + 8], str.process_run_key
mov dword [esp + 0x14], edi
mov dword [esp + 4], 0x408010
mov dword [esp], 1
call fcn.00402b80
movzx eax, byte [0x408010]
jmp 0x4032c9
mov dword [esp + 4], 0xffffffff
mov eax, dword [ebp - 0x6c]
mov dword [esp], eax
call dword [sym.imp.kernelbase.dll_WaitForSingleObject]
lea eax, [ebp - 0x70]
push edi
push edi
mov dword [esp + 4], eax
mov eax, dword [ebp - 0x6c]
mov dword [esp], eax
call dword [sym.imp.kernelbase.dll_GetExitCodeProcess]
push eax
push eax
jmp 0x4032a4
mov eax, esi
mov edi, dword [ebp - 0x6c]
shr eax, 0x10
test eax, eax
je 0x403409
mov dword [esp + 4], 0xffffffff
mov dword [esp], esi
call dword [sym.imp.kernel32.dll_IsBadStringPtrW]
push edx
push edx
test eax, eax
jne 0x4034eb
mov eax, esi
call fcn.004023d0
mov dword [esp + 0x14], edi
mov dword [esp + 0x10], eax
mov dword [esp + 0xc], str.Successfully_ran_command__s___Created_process_handle__p_n
mov dword [esp + 8], str.runCmd
mov dword [esp + 4], 0x408010
mov dword [esp], 3
call fcn.00402b80
jmp 0x40329a
mov dword [esp + 4], esi
mov dword [esp], 0x40926c
call fcn.00402590
jmp 0x4033d8
mov eax, dword fs:[0x18]
mov edi, dword [eax + 0x34]
mov eax, esi
shr eax, 0x10
test eax, eax
je 0x4034f5
mov dword [esp + 4], 0xffffffff
mov dword [esp], esi
call dword [sym.imp.kernel32.dll_IsBadStringPtrW]
push ecx
push ecx
test eax, eax
jne 0x40350a
mov eax, esi
call fcn.004023d0
mov dword [esp + 0x14], edi
mov dword [esp + 0x10], eax
mov dword [esp + 0xc], str.Failed_to_run_command__s___ld__n
mov dword [esp + 8], str.runCmd
mov dword [esp + 4], 0x408010
mov dword [esp], 2
call fcn.00402b80
movzx eax, byte [0x408010]
jmp 0x40332e
mov dword [esp + 0xc], str.No_commands_to_execute._n
mov dword [esp + 8], str.process_run_key
mov dword [esp + 4], 0x408010
mov dword [esp], 3
call fcn.00402b80
jmp 0x403065
mov dword [esp + 0x14], eax
mov eax, dword [ebp - 0x88]
mov dword [esp + 0xc], str.Couldnt_delete_value__lu___ld_._Running_command_anyways._n
mov dword [esp + 8], str.process_run_key
mov dword [esp + 4], 0x408010
mov dword [esp + 0x10], eax
mov dword [esp], 1
call fcn.00402b80
jmp 0x40312e
mov eax, str._invalid_
jmp 0x4033d8
mov dword [esp + 4], esi
mov dword [esp], 0x40926c
call fcn.00402590
jmp 0x403453
mov eax, str._invalid_
jmp 0x403453
test byte [0x408010], 2
je 0x40306f
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], 0x408010
mov dword [esp], 1
call fcn.00402b80
jmp 0x40306f
test byte [0x408010], 2
je 0x403065
mov dword [esp + 0xc], str.Couldnt_allocate_memory_for_the_commands_to_be_executed._n
mov dword [esp + 8], str.process_run_key
mov dword [esp + 4], 0x408010
mov dword [esp], 1
call fcn.00402b80
jmp 0x403065