Function at 0x4900e0
Capabilities:
Delete registry key
Query or enumerate registry key

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x4f2ae6
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
sub esp, 0x124
push esi
push edi
xor edi, edi
mov dword [ebp - 0x24], ecx
mov dword [ebp - 0x14], edi
mov eax, dword [ebp + 0xc]
mov ecx, dword [eax]
sub ecx, 0x10
call fcn.00401750
lea esi, [eax + 0x10]
mov dword [ebp + 0xc], esi
mov dword [ebp - 4], edi
call fcn.00401bb0
mov ecx, eax
test ecx, ecx
je 0x4903b2
mov eax, dword [ecx]
push ebx
call dword [eax + 0xc]
add eax, 0x10
mov dword [ebp - 0x20], eax
push esi
push SysReAllocStringLen
mov byte [ebp - 4], 1
call dword [sym.imp.ADVAPI32.dll_RegDeleteKeyA]
or ebx, 0xffffffff
test eax, eax
je 0x49017c
lea eax, [ebp - 0x1c]
push eax
push 0x20019
push edi
push esi
push SysReAllocStringLen
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExA]
test eax, eax
je 0x4901e1
cmp eax, 2
jne 0x4901d0
push str.Key_not_found._n
call fcn.00490660
add esp, 4
mov edi, 1
mov byte [ebp - 4], 0
mov eax, ebx
mov edx, dword [ebp - 0x20]
add edx, 0xfffffff0
lock xadd dword [edx + 0xc], eax
dec eax
test eax, eax
jg 0x49019f
mov ecx, dword [edx]
push edx
mov eax, dword [ecx]
call dword [eax + 4]
mov dword [ebp - 4], 0xffffffff
add esi, 0xfffffff0
lock xadd dword [esi + 0xc], ebx
dec ebx
test ebx, ebx
pop ebx
jg 0x4901bc
mov ecx, dword [esi]
push esi
mov edx, dword [ecx]
call dword [edx + 4]
mov ecx, dword [ebp - 0xc]
mov eax, edi
pop edi
pop esi
mov dword fs:[0], ecx
mov esp, ebp
pop ebp
ret 8
push str.Error_opening_key._n
call fcn.00490660
add esp, 4
xor edi, edi
jmp 0x490181
mov ebx, dword [esi - 0xc]
lea eax, [ebx - 1]
test eax, eax
js 0x4903a8
cmp eax, ebx
jg 0x4903a8
cmp byte [esi + eax], 0x5c
je 0x490234
mov eax, dword [esi - 8]
lea edi, [ebx + 1]
mov ecx, 1
sub eax, edi
sub ecx, dword [esi - 4]
or eax, ecx
jge 0x49021d
push edi
lea ecx, [ebp + 0xc]
call fcn.00401da0
mov esi, dword [ebp + 0xc]
mov byte [ebx + esi], 0x5c
cmp edi, dword [esi - 8]
jg 0x4903a8
mov dword [esi - 0xc], edi
mov byte [edi + esi], 0
mov edi, dword [ebp - 0x14]
lea eax, [ebp - 0x2c]
mov dword [ebp - 0x18], 0x104
push eax
push 0
push 0
push 0
lea eax, [ebp - 0x18]
push eax
lea eax, [ebp - 0x130]
push eax
push 0
push dword [ebp - 0x1c]
call dword [sym.imp.ADVAPI32.dll_RegEnumKeyExA]
or ebx, 0xffffffff
test eax, eax
jne 0x490345
mov byte [ebp - 4], 2
mov ecx, dword [esi - 0x10]
test ecx, ecx
je 0x49027c
mov eax, dword [ecx]
call dword [eax + 0x10]
mov ecx, eax
test ecx, ecx
jne 0x490292
call fcn.00401bb0
mov ecx, eax
mov edx, dword [eax]
call dword [edx + 0x10]
mov ecx, eax
test ecx, ecx
je 0x4903b2
mov eax, dword [ecx]
call dword [eax + 0xc]
add eax, 0x10
or edi, 1
mov dword [ebp - 0x10], eax
lea eax, [ebp - 0x130]
mov dword [ebp - 0x14], edi
lea edx, [eax + 1]
nop dword [eax]
mov cl, byte [eax]
inc eax
test cl, cl
jne 0x4902b0
sub eax, edx
lea ecx, [ebp - 0x10]
push eax
lea eax, [ebp - 0x130]
mov edx, esi
push eax
push dword [esi - 0xc]
call fcn.004061b0
add esp, 0xc
lea eax, [ebp - 0x10]
lea ecx, [ebp - 0x20]
push eax
call fcn.00401680
mov byte [ebp - 4], 1
and edi, 0xfffffffe
mov edx, dword [ebp - 0x10]
mov eax, ebx
mov dword [ebp - 0x14], edi
add edx, 0xfffffff0
lock xadd dword [edx + 0xc], eax
dec eax
test eax, eax
jg 0x490301
mov ecx, dword [edx]
push edx
mov eax, dword [ecx]
call dword [eax + 4]
mov ecx, dword [ebp - 0x24]
lea eax, [ebp - 0x20]
push eax
push SysReAllocStringLen
call fcn.004900e0
test eax, eax
je 0x490345
lea eax, [ebp - 0x2c]
mov dword [ebp - 0x18], 0x104
push eax
push 0
push 0
push 0
lea eax, [ebp - 0x18]
push eax
lea eax, [ebp - 0x130]
push eax
push 0
push dword [ebp - 0x1c]
call dword [sym.imp.ADVAPI32.dll_RegEnumKeyExA]
test eax, eax
je 0x490266
mov eax, dword [esi - 0xc]
lea ecx, [ebp + 0xc]
dec eax
push eax
lea eax, [ebp - 0x10]
push eax
call fcn.00405f40
push eax
lea ecx, [ebp + 0xc]
mov byte [ebp - 4], 3
call fcn.00401680
mov byte [ebp - 4], 1
mov eax, ebx
mov edx, dword [ebp - 0x10]
add edx, 0xfffffff0
lock xadd dword [edx + 0xc], eax
dec eax
test eax, eax
jg 0x490381
mov ecx, dword [edx]
push edx
mov eax, dword [ecx]
call dword [eax + 4]
push dword [ebp - 0x1c]
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
mov esi, dword [ebp + 0xc]
push esi
push SysReAllocStringLen
call dword [sym.imp.ADVAPI32.dll_RegDeleteKeyA]
test eax, eax
je 0x49017c
xor edi, edi
jmp 0x490181
push 0x80070057
call fcn.00401f30
push 0x80004005
call fcn.00401f30
int3