Function at 0x402919
Capabilities:
Query or enumerate registry value
Set registry value

Disassembly:
push ebp
mov ebp, esp
mov eax, 0x1018
call fcn.0040c710
push ebx
push esi
mov esi, ecx
xor ebx, ebx
push edi
mov eax, dword [esi + 8]
cmp eax, ebx
jne 0x402939
mov eax, 0x4132cc
lea ecx, [ebp - 8]
mov edi, 0x80000002
push ecx
lea ecx, [ebp - 4]
push ecx
push ebx
push 0xf003f
push ebx
push ebx
push ebx
push eax
push edi
mov dword [ebp - 4], ebx
call dword [sym.imp.ADVAPI32.dll_RegCreateKeyExA]
cmp eax, ebx
jne 0x402b82
mov eax, dword [esi + 0x24]
sub eax, ebx
je 0x402b47
dec eax
je 0x402b1d
mov eax, dword [esi + 8]
mov dword [ebp - 0xc], 0x1000
cmp eax, ebx
mov dword [ebp - 0x18], ebx
jne 0x40298a
mov eax, 0x4132cc
lea ecx, [ebp - 8]
push ecx
push 3
push ebx
push eax
push edi
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExA]
cmp eax, ebx
mov dword [ebp - 0x14], eax
jne 0x402b74
mov eax, dword [esi + 0x18]
cmp eax, ebx
jne 0x4029b0
mov eax, 0x4132cc
lea ecx, [ebp - 0xc]
push ecx
lea ecx, [ebp - 0x1018]
push ecx
lea ecx, [ebp - 0x10]
push ecx
push ebx
push eax
push dword [ebp - 8]
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExA]
push 1
test eax, eax
pop ebx
jne 0x4029dc
cmp dword [ebp - 0x10], 7
je 0x4029fd
cmp dword [ebp - 0x10], ebx
je 0x4029f7
and byte [ebp - 0x1018], 0
xor eax, eax
cmp dword [esi + 0x24], 2
mov dword [ebp - 0xc], ebx
setne al
dec eax
and eax, 6
inc eax
mov dword [ebp - 0x10], eax
cmp dword [ebp - 0x10], 7
jne 0x402a74
cmp byte [ebp - 0x1018], 0
lea edi, [ebp - 0x1018]
je 0x402a44
mov eax, dword [esi + 0x2c]
test eax, eax
jne 0x402a18
mov eax, 0x4132cc
push eax
push edi
call fcn.0040c620
pop ecx
test eax, eax
pop ecx
jne 0x402a28
mov dword [ebp - 0x18], ebx
push edi
call fcn.0040bba0
cmp byte [edi + eax + 1], 0
lea edi, [edi + eax + 1]
pop ecx
jne 0x402a0c
cmp dword [ebp - 0x18], 0
jne 0x402b10
mov eax, dword [esi + 0x2c]
test eax, eax
jne 0x402a50
mov eax, 0x4132cc
push eax
push edi
call fcn.0040bc20
push edi
call fcn.0040bba0
mov ecx, dword [ebp - 0xc]
add esp, 0xc
lea eax, [ecx + eax + 1]
mov dword [ebp - 0xc], eax
and byte [ebp + eax - 0x1019], 0
jmp 0x402aea
mov eax, dword [esi + 0x2c]
test eax, eax
jne 0x402a80
mov eax, 0x4132cc
push eax
lea eax, [ebp - 0x1018]
push eax
call fcn.0040c370
neg eax
sbb eax, eax
pop ecx
neg eax
pop ecx
mov dword [ebp - 0x18], eax
jne 0x402b10
lea eax, [ebp - 0x1018]
push eax
call fcn.0040bba0
test eax, eax
pop ecx
je 0x402abe
lea eax, [ebp - 0x1018]
push 0x417480
push eax
call fcn.0040bc30
pop ecx
pop ecx
mov eax, dword [esi + 0x2c]
test eax, eax
jne 0x402aca
mov eax, 0x4132cc
push eax
lea eax, [ebp - 0x1018]
push eax
call fcn.0040bc30
lea eax, [ebp - 0x1018]
push eax
call fcn.0040bba0
add esp, 0xc
inc eax
mov dword [ebp - 0xc], eax
mov esi, dword [esi + 0x18]
test esi, esi
jne 0x402af6
mov esi, 0x4132cc
push eax
lea eax, [ebp - 0x1018]
push eax
push dword [ebp - 0x10]
push 0
push esi
push dword [ebp - 8]
call dword [sym.imp.ADVAPI32.dll_RegSetValueExA]
mov dword [ebp - 0x14], eax
push dword [ebp - 8]
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
xor ebx, ebx
jmp 0x402b6f
mov eax, dword [esi + 0x18]
mov edi, 0x4132cc
cmp eax, ebx
je 0x402b2b
mov edi, eax
mov esi, dword [esi + 0x2c]
cmp esi, ebx
jne 0x402b37
mov esi, 0x4132cc
push esi
call dword [sym.imp.KERNEL32.dll_lstrlenA]
inc eax
push eax
push esi
push 1
push ebx
push edi
jmp 0x402b63
mov eax, dword [esi + 0x18]
cmp eax, ebx
jne 0x402b53
mov eax, 0x4132cc
mov ecx, dword [esi + 0x38]
push 4
mov dword [ebp - 8], ecx
lea ecx, [ebp - 8]
push ecx
push 4
push ebx
push eax
push dword [ebp - 4]
call dword [sym.imp.ADVAPI32.dll_RegSetValueExA]
mov dword [ebp - 0x14], eax
cmp dword [ebp - 0x14], ebx
je 0x402b87
cmp dword [ebp - 4], ebx
je 0x402b82
push dword [ebp - 4]
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
push 3
pop eax
jmp 0x402b97
cmp dword [ebp - 4], ebx
je 0x402b95
push dword [ebp - 4]
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
xor eax, eax
pop edi
pop esi
pop ebx
leave
ret