Function at 0x412230
Capabilities:
Delete registry value
Set registry value

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x14
push ebx
xor ebx, ebx
cmp dword [ebp + 0xc], ebx
jne 0x412246
or eax, 0xffffffff
pop ebx
mov esp, ebp
pop ebp
ret
mov eax, dword [ebp + 0x18]
push esi
xor esi, esi
push edi
mov dword [ebp - 4], esi
mov dword [ebp - 0xc], ebx
mov dword [ebp - 8], ebx
cmp eax, ebx
je 0x412435
mov edi, dword [eax]
cmp edi, ebx
je 0x412435
cmp word [edi], bx
je 0x412435
movzx eax, word [edi]
sub eax, 0x2b
je 0x412298
sub eax, 2
je 0x41228f
sub eax, 0xd
jne 0x412335
add edi, 2
jmp 0x412335
mov dword [ebp - 8], 0xffffffff
jmp 0x41229f
mov dword [ebp - 8], 1
mov ecx, dword [ebp + 8]
lea eax, [ebp - 0x14]
push eax
mov eax, dword [ebp + 0xc]
mov dword [ebp - 0x10], ebx
mov ebx, dword [ebp + 0x10]
push ecx
lea esi, [ebp - 0x10]
add edi, 2
call fcn.0040a750
add esp, 8
test eax, eax
jne 0x41246f
mov esi, dword [ebp - 0x10]
test esi, esi
je 0x412321
mov ebx, dword [ebp - 0x14]
cmp dword [ebp - 8], eax
jle 0x4122eb
lea edx, [ebp - 0xc]
push edx
lea eax, [ebp - 4]
push eax
push ebx
push esi
mov edx, edi
call fcn.00401f30
add esp, 0x10
jmp 0x4122fe
lea ecx, [ebp - 0xc]
push ecx
lea edx, [ebp - 4]
push edx
push edi
push ebx
push esi
call fcn.00401f70
add esp, 0x14
mov edi, eax
test ebx, ebx
je 0x412314
push esi
push 0
call dword [sym.imp.KERNEL32.dll_GetProcessHeap]
push eax
call dword [sym.imp.KERNEL32.dll_HeapFree]
test edi, edi
jne 0x41246f
mov edi, dword [ebp - 4]
jmp 0x412332
cmp dword [ebp - 8], 0
jl 0x412479
mov dword [ebp - 8], 0
mov esi, dword [ebp - 4]
xor ebx, ebx
cmp edi, ebx
je 0x412435
cmp word [edi], bx
je 0x412435
cmp dword [ebp - 8], ebx
jne 0x41237d
mov eax, edi
lea edx, [eax + 2]
mov cx, word [eax]
add eax, 2
cmp cx, bx
jne 0x412352
sub eax, edx
lea ecx, [ebp - 0xc]
push ecx
lea edx, [ebp - 4]
push edx
sar eax, 1
push edi
call fcn.0040ac30
add esp, 0xc
test eax, eax
jne 0x41246f
mov esi, dword [ebp - 4]
push esi
call fcn.00401e50
add esp, 4
test eax, eax
je 0x4123b9
push esi
push ebx
call dword [sym.imp.KERNEL32.dll_GetProcessHeap]
push eax
call dword [sym.imp.KERNEL32.dll_HeapFree]
push 0x40000238
call fcn.004147fb
add eax, 0x40
push eax
call fcn.00402220
add esp, 8
pop edi
pop esi
or eax, 0xffffffff
pop ebx
mov esp, ebp
pop ebp
ret
mov edi, dword [ebp - 0xc]
mov ecx, dword [ebp + 0x10]
mov edx, dword [ebp + 0xc]
lea eax, [edi + edi]
push eax
push esi
push 7
push ebx
push ecx
push edx
call dword [sym.imp.ADVAPI32.dll_RegSetValueExW]
test eax, eax
je 0x412416
cmp edi, ebx
je 0x4123e9
push esi
push ebx
call dword [sym.imp.KERNEL32.dll_GetProcessHeap]
push eax
call dword [sym.imp.KERNEL32.dll_HeapFree]
push ebx
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov edi, eax
call fcn.00402080
push eax
push str.AppEnvironment
push 0xc00003fb
push 1
call fcn.004021b0
add esp, 0x14
pop edi
pop esi
or eax, 0xffffffff
pop ebx
mov esp, ebp
pop ebp
ret
cmp edi, ebx
je 0x412429
push esi
push ebx
call dword [sym.imp.KERNEL32.dll_GetProcessHeap]
push eax
call dword [sym.imp.KERNEL32.dll_HeapFree]
pop edi
pop esi
mov eax, 1
pop ebx
mov esp, ebp
pop ebp
ret
mov esi, dword [ebp + 0x10]
mov eax, dword [ebp + 0xc]
push esi
push eax
call dword [sym.imp.ADVAPI32.dll_RegDeleteValueW]
cmp eax, ebx
je 0x412479
cmp eax, 2
je 0x412479
mov edi, eax
call fcn.00402080
mov ecx, dword [ebp + 8]
push eax
push ecx
push esi
push 0x4000020d
call fcn.004147fb
add eax, 0x40
push eax
call fcn.00402220
add esp, 0x14
pop edi
pop esi
or eax, 0xffffffff
pop ebx
mov esp, ebp
pop ebp
ret
pop edi
pop esi
xor eax, eax
pop ebx
mov esp, ebp
pop ebp
ret