Function at 0x422170
Capabilities:
Set registry value

Disassembly:
push 0xffffffffffffffff
push 0x459a78
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
sub esp, 0x10
push ebx
push esi
push edi
mov ebx, ecx
push ebx
mov dword [esp + 0x28], 0
call fcn.00422570
mov eax, dword [esp + 0x2c]
add eax, 0xfffffff0
push eax
call fcn.004050d0
lea edi, [eax + 0x10]
add esp, 4
mov dword [esp + 0xc], edi
mov byte [esp + 0x24], 1
mov esi, dword [edi - 0xc]
mov eax, dword [edi - 8]
mov ecx, 1
sub ecx, dword [edi - 4]
sub eax, esi
or eax, ecx
jge 0x4221d9
push esi
lea ecx, [esp + 0x10]
call fcn.004052a0
mov edi, dword [esp + 0xc]
lea eax, [esi + 1]
push eax
push edi
call fcn.0043e8aa
add esp, 8
test esi, esi
jl 0x422564
cmp esi, dword [edi - 8]
jg 0x422564
xor ecx, ecx
mov dword [edi - 0xc], esi
push ebp
mov word [edi + esi*2], cx
mov ebp, dword [ebx + 4]
test ebp, ebp
je 0x42234e
lea esp, [esp]
mov dword [esp + 0x1c], ebp
mov eax, ebp
test ebp, ebp
je 0x4223f2
mov esi, dword [eax + 8]
mov ecx, dword [esi - 0x10]
mov edx, dword [ecx]
mov eax, dword [edx + 0x10]
mov ebp, dword [ebp]
sub esi, 0x10
call eax
cmp dword [esi + 0xc], 0
lea ecx, [esi + 0xc]
jl 0x42224b
cmp eax, dword [esi]
jne 0x42224b
mov edi, esi
mov edx, 1
lock xadd dword [ecx], edx
jmp 0x422286
mov ecx, dword [esi + 4]
mov edx, dword [eax]
mov edx, dword [edx]
push 2
push ecx
mov ecx, eax
call edx
mov edi, eax
test edi, edi
je 0x4223f7
mov eax, dword [esi + 4]
mov dword [edi + 4], eax
mov eax, dword [esi + 4]
lea ecx, [eax + eax + 2]
push ecx
add esi, 0x10
lea edx, [eax + eax + 2]
push esi
push edx
lea eax, [edi + 0x10]
push eax
call fcn.0043d2f0
add esp, 0x10
lea esi, [edi + 0x10]
mov dword [esp + 0x14], esi
mov byte [esp + 0x28], 2
mov edi, dword [esi - 0xc]
mov eax, dword [esi - 8]
mov ecx, 1
sub ecx, dword [esi - 4]
sub eax, edi
or eax, ecx
jge 0x4222b4
push edi
lea ecx, [esp + 0x18]
call fcn.004052a0
mov esi, dword [esp + 0x14]
lea ecx, [edi + 1]
push ecx
push esi
call fcn.0043e8aa
add esp, 8
test edi, edi
jl 0x4223fc
cmp edi, dword [esi - 8]
jg 0x4223fc
mov ecx, dword [esp + 0x10]
xor edx, edx
mov dword [esi - 0xc], edi
mov word [esi + edi*2], dx
mov eax, esi
mov dx, word [eax]
cmp dx, word [ecx]
jne 0x422307
test dx, dx
je 0x422303
mov dx, word [eax + 2]
cmp dx, word [ecx + 2]
jne 0x422307
add eax, 4
add ecx, 4
test dx, dx
jne 0x4222e1
xor eax, eax
jmp 0x42230c
sbb eax, eax
sbb eax, 0xffffffff
test eax, eax
sete al
test al, al
je 0x422321
mov eax, dword [esp + 0x1c]
push eax
mov ecx, ebx
call fcn.00437a1e
lea eax, [esi - 0x10]
mov byte [esp + 0x28], 1
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x422342
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
test ebp, ebp
jne 0x422210
mov edi, dword [esp + 0x10]
lea ecx, [esp + 0x30]
push ecx
mov ecx, ebx
call fcn.00437a8a
cmp dword [ebx + 0xc], 0xf
jle 0x42238c
lea edx, [esp + 0x1c]
push edx
mov ecx, ebx
call fcn.004379b7
mov eax, dword [esp + 0x1c]
add eax, 0xfffffff0
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x42238c
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
push 0
lea ecx, [esp + 0x1c]
push ecx
push 0
push 0xf003f
push 0
push 0
push 0
push 0x47b2f8
push 0x80000001
mov ebp, 1
call dword [sym.imp.ADVAPI32.dll_RegCreateKeyExW]
mov ebx, dword [ebx + 4]
test ebx, ebx
je 0x4224f1
mov eax, ebx
test ebx, ebx
je 0x4223f2
mov esi, dword [eax + 8]
mov ecx, dword [esi - 0x10]
mov edx, dword [ecx]
mov eax, dword [edx + 0x10]
mov ebx, dword [ebx]
sub esi, 0x10
call eax
cmp dword [esi + 0xc], 0
lea ecx, [esi + 0xc]
jl 0x422406
cmp eax, dword [esi]
jne 0x422406
mov edi, esi
mov edx, 1
lock xadd dword [ecx], edx
jmp 0x42243d
call fcn.0042adb3
call fcn.00405250
push 0x80070057
call fcn.00405760
mov ecx, dword [esi + 4]
mov edx, dword [eax]
mov edx, dword [edx]
push 2
push ecx
mov ecx, eax
call edx
mov edi, eax
test edi, edi
je 0x4223f7
mov eax, dword [esi + 4]
mov dword [edi + 4], eax
mov eax, dword [esi + 4]
lea ecx, [eax + eax + 2]
push ecx
add esi, 0x10
lea edx, [eax + eax + 2]
push esi
push edx
lea eax, [edi + 0x10]
push eax
call fcn.0043d2f0
add esp, 0x10
lea esi, [edi + 0x10]
mov dword [esp + 0x1c], esi
mov byte [esp + 0x28], 3
call fcn.0042ae70
xor ecx, ecx
test eax, eax
setne cl
test ecx, ecx
je 0x42255a
mov edx, dword [eax]
mov ecx, eax
mov eax, dword [edx + 0xc]
call eax
add eax, 0x10
mov dword [esp + 0x14], eax
push ebp
lea ecx, [esp + 0x18]
push 0x46445c
push ecx
mov byte [esp + 0x34], 4
call fcn.00404fe0
mov eax, dword [esi - 0xc]
mov edi, dword [esp + 0x20]
add esp, 0xc
lea edx, [eax + eax + 2]
mov eax, dword [esp + 0x18]
push edx
push esi
push 1
push 0
push edi
push eax
inc ebp
call dword [sym.imp.ADVAPI32.dll_RegSetValueExW]
lea eax, [edi - 0x10]
mov byte [esp + 0x28], 3
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x4224c4
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
lea eax, [esi - 0x10]
mov byte [esp + 0x28], 1
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x4224e5
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
test ebx, ebx
jne 0x4223c0
mov edi, dword [esp + 0x10]
mov ecx, dword [esp + 0x18]
push ecx
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
lea eax, [edi - 0x10]
mov byte [esp + 0x28], 0
lea edx, [eax + 0xc]
or ecx, 0xffffffff
lock xadd dword [edx], ecx
dec ecx
test ecx, ecx
jg 0x42251d
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov dword [esp + 0x28], 0xffffffff
mov eax, dword [esp + 0x30]
add eax, 0xfffffff0
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x422545
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov ecx, dword [esp + 0x20]
pop ebp
pop edi
pop esi
pop ebx
mov dword fs:[0], ecx
add esp, 0x1c
ret 4
push 0x80004005
call fcn.00405760
push 0x80070057
call fcn.00405760
int3