Function at 0x474792
Capabilities:
Query or enumerate registry key
Query or enumerate registry value

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
and esp, 0xfffffff8
sub esp, 0x25c
mov eax, dword [0x5184d0]
xor eax, esp
mov dword [esp + 0x258], eax
push ebx
push esi
mov eax, ecx
mov dword [esp + 0x28], edx
mov ecx, dword [ebp + 0xc]
lea esi, [esp + 0x3c]
xor edx, edx
mov dword [esp + 0x20], eax
mov dword [esp + 0x34], ecx
mov ebx, edx
mov dword [esp + 0x2c], 8
mov dword [esp + 0x24], esi
mov dword [esp + 0x38], edx
push edi
mov edi, edx
test ecx, ecx
je 0x474827
mov edi, ecx
lea ecx, [edi + 2]
mov ax, word [edi]
add edi, 2
cmp ax, dx
jne 0x4747e5
sub edi, ecx
sar edi, 1
lea eax, [edi*2 + 2]
push eax
push edx
call dword [sym.imp.KERNEL32.dll_LocalAlloc]
mov ebx, eax
test ebx, ebx
jne 0x474821
mov eax, 0x8007000e
push eax
push 0xb900138
mov esi, eax
call dword [sym.imp.certcli.dll_Ordinal_357]
jmp 0x474b9b
mov eax, dword [esp + 0x24]
xor edx, edx
mov ecx, 0x105
mov dword [esp + 0x1c], edx
push ecx
mov dword [esp + 0x24], ecx
lea ecx, [esp + 0x54]
push ecx
push edx
push eax
mov dword [esp + 0x28], edx
call dword [sym.imp.ADVAPI32.dll_RegEnumKeyW]
push 5
pop ecx
test eax, eax
jne 0x47495c
test ebx, ebx
je 0x474885
push edi
lea eax, [esp + 0x54]
mov ecx, ebx
push eax
lea edx, [edi + 1]
call fcn.00452601
mov ecx, dword [esp + 0x38]
xor eax, eax
push 1
push 0xffffffffffffffff
mov edx, ebx
mov word [ebx + edi*2], ax
call fcn.004ca39c
test eax, eax
jne 0x474918
push 5
pop ecx
mov esi, dword [esp + 0x1c]
test esi, esi
jne 0x4748b1
push 0x406520
call fcn.004c5942
pop ecx
mov ecx, 0x2e3
call fcn.004cf8b9
push eax
call fcn.004c5942
mov dword [esp], 0x406520
jmp 0x4748c0
xor edx, edx
mov eax, esi
div ecx
test edx, edx
jne 0x4748c6
push 0x406520
call fcn.004c5942
pop ecx
lea eax, [esp + 0x50]
push eax
push 0x4056e4
call fcn.004c5942
mov eax, dword [0x519a3c]
inc esi
mov dword [esp + 0x24], esi
mov dword [esp + 0x1c], eax
pop ecx
pop ecx
test eax, eax
je 0x474918
cmp eax, 3
jae 0x4748f4
dec eax
mov dword [0x519a3c], eax
mov edx, dword [esp + 0x2c]
lea eax, [esp + 0x50]
mov ecx, dword [esp + 0x24]
push eax
push dword [ebp + 8]
call fcn.00474bbf
mov esi, eax
test esi, esi
jne 0x474947
mov eax, dword [esp + 0x14]
mov dword [0x519a3c], eax
mov eax, dword [esp + 0x18]
mov ecx, 0x105
push ecx
mov dword [esp + 0x24], ecx
inc eax
lea ecx, [esp + 0x54]
mov dword [esp + 0x1c], eax
push ecx
push eax
push dword [esp + 0x30]
call dword [sym.imp.ADVAPI32.dll_RegEnumKeyW]
test eax, eax
jne 0x474958
push 5
pop ecx
jmp 0x474851
push esi
push 0xbbd0138
call dword [sym.imp.certcli.dll_Ordinal_357]
jmp 0x474b90
lea esi, [esp + 0x40]
cmp eax, 0x103
je 0x47496f
push eax
push 0xb9b0138
call dword [sym.imp.certcli.dll_Ordinal_357]
xor edx, edx
mov dword [esp + 0x2c], edx
mov eax, edx
mov dword [esp + 0x18], edx
mov dword [esp + 0x1c], edx
mov ecx, dword [esp + 0x30]
mov dword [esp + 0x10], ecx
lea ecx, [esp + 0x10]
push ecx
push esi
lea ecx, [esp + 0x3c]
mov dword [esp + 0x28], 0x105
push ecx
push edx
lea ecx, [esp + 0x30]
mov dword [esp + 0x24], esi
push ecx
lea ecx, [esp + 0x64]
push ecx
push eax
push dword [esp + 0x40]
call dword [sym.imp.ADVAPI32.dll_RegEnumValueW]
test eax, eax
je 0x474a3f
cmp eax, 0xea
jne 0x474b62
mov eax, dword [esp + 0x10]
add eax, 6
push eax
xor eax, eax
push eax
call dword [sym.imp.KERNEL32.dll_LocalAlloc]
mov dword [esp + 0x14], eax
test eax, eax
je 0x474b4d
lea ecx, [esp + 0x40]
cmp ecx, esi
je 0x4749f7
push esi
call dword [sym.imp.KERNEL32.dll_LocalFree]
mov eax, dword [esp + 0x14]
mov ecx, dword [esp + 0x10]
mov dword [esp + 0x30], ecx
lea ecx, [esp + 0x10]
push ecx
push eax
mov dword [esp + 0x30], eax
lea eax, [esp + 0x3c]
push eax
xor eax, eax
mov dword [esp + 0x2c], 0x105
push eax
lea eax, [esp + 0x30]
push eax
lea eax, [esp + 0x64]
push eax
push dword [esp + 0x34]
push dword [esp + 0x40]
call dword [sym.imp.ADVAPI32.dll_RegEnumValueW]
mov esi, eax
test esi, esi
jne 0x474b3b
mov esi, dword [esp + 0x28]
mov eax, dword [esp + 0x30]
lea ecx, [esp + 0x50]
mov edx, dword [esp + 0x34]
add eax, 6
push eax
push dword [esp + 0x14]
push dword [esp + 0x1c]
call fcn.00473cef
mov dword [esp + 0x10], eax
test ebx, ebx
je 0x474a91
push edi
lea eax, [esp + 0x54]
mov ecx, ebx
push eax
lea edx, [edi + 1]
call fcn.00452601
mov ecx, dword [esp + 0x38]
xor eax, eax
push 1
push 0xffffffffffffffff
mov edx, ebx
mov word [ebx + edi*2], ax
call fcn.004ca39c
test eax, eax
jne 0x474b2b
mov eax, dword [esp + 0x18]
test eax, eax
jne 0x474abd
push 0x406520
call fcn.004c5942
pop ecx
mov ecx, 0x2e4
call fcn.004cf8b9
push eax
call fcn.004c5942
mov dword [esp], 0x406520
jmp 0x474ad4
cmp dword [esp + 0x2c], 0
jne 0x474acf
push 5
xor edx, edx
pop ecx
div ecx
test edx, edx
jne 0x474ada
push 0x406520
call fcn.004c5942
pop ecx
lea edx, [esp + 0x50]
lea ecx, [edx + 2]
mov ax, word [edx]
add edx, 2
cmp ax, word [esp + 0x3c]
jne 0x474ae1
lea eax, [esp + 0x2c]
sub edx, ecx
push eax
push dword [esp + 0x18]
sar edx, 1
push dword [esp + 0x18]
push 0x19
pop eax
mov ecx, eax
sub ecx, edx
cmp eax, edx
lea edx, [esp + 0x5c]
sbb eax, eax
not eax
and eax, ecx
mov ecx, edx
push eax
push 1
push 1
push 1
xor eax, eax
push eax
push dword [esp + 0x54]
call fcn.0047367e
inc dword [esp + 0x18]
mov eax, dword [esp + 0x1c]
inc eax
xor edx, edx
mov dword [esp + 0x1c], eax
jmp 0x47497f
push esi
push 0xbe50138
call dword [sym.imp.certcli.dll_Ordinal_357]
mov eax, dword [esp + 0x28]
jmp 0x474b81
mov eax, 0x8007000e
push eax
push 0xbdb0138
mov esi, eax
call dword [sym.imp.certcli.dll_Ordinal_357]
jmp 0x474b79
cmp eax, 0x103
je 0x474b75
push eax
push 0xbd20138
call dword [sym.imp.certcli.dll_Ordinal_357]
xor eax, eax
mov esi, eax
mov eax, dword [esp + 0x28]
test eax, eax
je 0x474b90
lea ecx, [esp + 0x40]
cmp ecx, eax
je 0x474b90
push eax
call dword [sym.imp.KERNEL32.dll_LocalFree]
test ebx, ebx
je 0x474b9b
push ebx
call dword [sym.imp.KERNEL32.dll_LocalFree]
mov ecx, esi
call fcn.004c738c
mov ecx, dword [esp + 0x264]
pop edi
pop esi
pop ebx
xor ecx, esp
call fcn.005036b0
mov esp, ebp
pop ebp
ret 8