Function at 0x422c6b
Capabilities:
Delete registry key
Set registry value

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x24
push ebx
push esi
xor ebx, ebx
mov esi, ecx
push edi
mov dword [ebp - 0x1c], ebx
lea ecx, [ebp - 0x10]
push ebx
mov dword [ebp - 0x20], esi
mov dword [ebp - 0x10], ebx
call fcn.004235ec
push eax
push ebx
mov edi, 0xf003f
push edi
push ebx
push ebx
push ebx
push 0x4028b8
push 0x80000001
call dword [sym.imp.api_ms_win_core_registry_l1_1_0.dll_RegCreateKeyExW]
test eax, eax
jne 0x422ef4
lea ecx, [ebp - 0x18]
mov dword [ebp - 0x18], ebx
call fcn.004235ec
push ebx
push eax
push ebx
push edi
push ebx
push ebx
push ebx
push dword [esi + 8]
push dword [ebp - 0x10]
call dword [sym.imp.api_ms_win_core_registry_l1_1_0.dll_RegCreateKeyExW]
test eax, eax
jne 0x422ee5
call fcn.0040e41a
mov byte [ebp - 1], al
test al, al
je 0x422d20
push dword [esi + 8]
lea eax, [ebp - 0x14]
mov dword [ebp - 0x14], ebx
push dword [esi + 4]
push 0x402914
push eax
call fcn.0042361e
add esp, 0x10
test eax, eax
jns 0x422d12
mov dword [ebp - 8], ebx
cmp dword [ebp - 0x14], ebx
je 0x422d18
push dword [ebp - 0x14]
call dword [sym.imp.api_ms_win_core_com_l1_1_0.dll_CoTaskMemFree]
jmp 0x422d18
mov eax, dword [ebp - 0x14]
mov dword [ebp - 8], eax
xor ecx, ecx
lea edx, [ebp - 8]
inc ecx
jmp 0x422d34
push 0xffffffffffffffff
mov edx, 0x402214
lea ecx, [ebp - 0x1c]
call fcn.0040c916
push 2
mov edx, eax
pop ecx
mov eax, dword [edx]
mov dword [ebp - 0xc], eax
mov dword [edx], ebx
test cl, 2
je 0x422d57
and ecx, 0xfffffffd
mov dword [ebp - 0x14], ecx
cmp dword [ebp - 0x1c], ebx
je 0x422d57
push dword [ebp - 0x1c]
call dword [sym.imp.api_ms_win_core_com_l1_1_0.dll_CoTaskMemFree]
mov ecx, dword [ebp - 0x14]
test cl, 1
je 0x422d6a
cmp dword [ebp - 8], ebx
je 0x422d6a
push dword [ebp - 8]
call dword [sym.imp.api_ms_win_core_com_l1_1_0.dll_CoTaskMemFree]
mov esi, dword [ebp - 0xc]
test esi, esi
je 0x422ee5
lea ecx, [esi + 2]
mov ax, word [esi]
add esi, 2
cmp ax, bx
jne 0x422d78
sub esi, ecx
mov dword [ebp - 8], ebx
sub esp, 0x48
sar esi, 1
mov ecx, esp
lea eax, [ecx + 8]
mov dword [ecx + 0x40], eax
lea ecx, [ebp - 8]
mov dword [eax], 0x4011d8
call fcn.00411934
test eax, eax
js 0x422ec7
mov ecx, dword [ebp - 8]
lea edx, [ecx + 2]
mov ax, word [ecx]
add ecx, 2
cmp ax, bx
jne 0x422db1
sub ecx, edx
xor edx, edx
sar ecx, 1
add ecx, 4
add esi, ecx
lea ecx, [ebp - 0x1c]
push esi
call fcn.0040c916
push dword [ebp - 8]
mov edi, dword [ebp - 0x1c]
push dword [ebp - 0xc]
push dword [0x429e18]
push 0x402900
push esi
push edi
call fcn.00406803
add esp, 0x18
test eax, eax
js 0x422ebc
mov ecx, dword [0x42a8cc]
mov esi, ebx
mov dword [ebp - 0x14], esi
mov edx, 0x4028a0
test ecx, ecx
je 0x422e20
push ecx
lea edx, [ebp - 0x14]
call fcn.00411900
mov esi, dword [ebp - 0x14]
test eax, eax
js 0x422eb1
mov edx, esi
mov ecx, edi
lea eax, [ecx + 2]
mov dword [ebp - 0x1c], eax
mov ax, word [ecx]
add ecx, 2
cmp ax, bx
jne 0x422e28
sub ecx, dword [ebp - 0x1c]
sar ecx, 1
lea eax, [ecx*2 + 1]
push eax
push edi
push 1
push ebx
push edx
push dword [ebp - 0x18]
call dword [sym.imp.api_ms_win_core_registry_l1_1_0.dll_RegSetValueExW]
test eax, eax
jne 0x422eb1
cmp byte [ebp - 1], bl
je 0x422eaf
mov ecx, dword [ebp - 0x20]
call fcn.004233ec
test al, al
je 0x422eb1
mov eax, dword [0x429d8c]
lea edx, [ebp - 0xc]
push ebx
mov dword [ebp - 0x1c], eax
mov eax, dword [0x429e14]
push 1
mov dword [ebp - 0x14], eax
mov dword [0x429e14], 2
call fcn.0041080c
test al, al
jne 0x422e9f
mov eax, dword [ebp - 0x20]
push ebx
push ebx
push dword [eax + 8]
push dword [ebp - 0x10]
call dword [sym.imp.api_ms_win_core_registry_l1_1_0.dll_RegDeleteKeyExW]
jmp 0x422eb1
mov eax, dword [ebp - 0x1c]
mov dword [0x429d8c], eax
mov eax, dword [ebp - 0x14]
mov dword [0x429e14], eax
mov bl, 1
test esi, esi
je 0x422ebc
push esi
call dword [sym.imp.api_ms_win_core_com_l1_1_0.dll_CoTaskMemFree]
test edi, edi
je 0x422ec7
push edi
call dword [sym.imp.api_ms_win_core_com_l1_1_0.dll_CoTaskMemFree]
cmp dword [ebp - 8], 0
je 0x422ed6
push dword [ebp - 8]
call dword [sym.imp.api_ms_win_core_com_l1_1_0.dll_CoTaskMemFree]
cmp dword [ebp - 0xc], 0
je 0x422ee5
push dword [ebp - 0xc]
call dword [sym.imp.api_ms_win_core_com_l1_1_0.dll_CoTaskMemFree]
cmp dword [ebp - 0x18], 0
je 0x422ef4
push dword [ebp - 0x18]
call dword [sym.imp.api_ms_win_core_registry_l1_1_0.dll_RegCloseKey]
cmp dword [ebp - 0x10], 0
je 0x422f03
push dword [ebp - 0x10]
call dword [sym.imp.api_ms_win_core_registry_l1_1_0.dll_RegCloseKey]
pop edi
pop esi
mov al, bl
pop ebx
leave
ret