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

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x238
mov eax, dword [0x408028]
xor eax, ebp
mov dword [ebp - 4], eax
push ebx
push esi
mov esi, dword [ebp + 8]
lea eax, [ebp - 0x220]
push edi
push eax
xor ebx, ebx
mov dword [ebp - 0x214], esi
mov edi, edx
mov dword [0x408394], ebx
mov edx, dword [esi + 0xc]
mov ecx, edi
push 0x408394
push 7
mov dword [ebp - 0x218], 0
mov dword [ebp - 0x238], 0
mov dword [ebp - 0x234], 0
mov dword [ebp - 0x224], 0
mov dword [ebp - 0x230], ebx
mov dword [ebp - 0x220], ebx
call fcn.00403fb0
mov dword [ebp - 0x228], eax
lea eax, [ebp - 0x218]
push eax
push 0x20019
push ebx
push dword [esi + 0xc]
push edi
call dword [sym.imp.api_ms_win_core_registry_l1_1_0.dll_RegOpenKeyExW]
test eax, eax
jne 0x403d10
mov esi, dword [ebp - 0x220]
xor edi, edi
push 0
push 0
push 0
push 0
lea eax, [ebp - 0x22c]
mov dword [ebp - 0x22c], 0x101
push eax
lea eax, [ebp - 0x208]
push eax
push edi
push dword [ebp - 0x218]
call dword [sym.imp.api_ms_win_core_registry_l1_1_0.dll_RegEnumKeyExW]
mov ecx, eax
test ecx, ecx
je 0x4064b5
inc edi
test ecx, ecx
je 0x403864
mov dword [ebp - 0x21c], esi
test esi, esi
mov esi, dword [ebp - 0x214]
je 0x4038b9
cmp edi, 1
ja 0x4064c6
xor ecx, ecx
mov eax, dword [0x408394]
mov edi, dword [ebp - 0x220]
test eax, eax
je 0x4067d8
cmp edi, 2
jb 0x406641
cmp word [eax], 0
je 0x4067d8
lea eax, [ebp - 0x210]
mov dword [ebp - 0x210], 4
push eax
lea eax, [ebp - 0x20c]
push eax
lea eax, [ebp - 0x214]
push eax
push 0
push 0x4017b0
push dword [ebp - 0x218]
call dword [sym.imp.api_ms_win_core_registry_l1_1_0.dll_RegQueryValueExW]
test eax, eax
jne 0x40392d
cmp dword [ebp - 0x214], 4
jne 0x40664e
mov eax, dword [ebp - 0x20c]
mov dword [esi + 0x14], eax
lea eax, [ebp - 0x210]
mov dword [ebp - 0x210], 4
push eax
lea eax, [ebp - 0x20c]
push eax
lea eax, [ebp - 0x214]
push eax
push 0
push 0x401770
push dword [ebp - 0x218]
call dword [sym.imp.api_ms_win_core_registry_l1_1_0.dll_RegQueryValueExW]
test eax, eax
jne 0x40397c
cmp dword [ebp - 0x214], 4
jne 0x40665d
cmp dword [ebp - 0x20c], eax
je 0x40397c
or dword [esi + 0x58], 2
lea eax, [ebp - 0x210]
mov dword [ebp - 0x210], 4
push eax
lea eax, [ebp - 0x20c]
push eax
lea eax, [ebp - 0x214]
push eax
push 0
push 0x401718
push dword [ebp - 0x218]
call dword [sym.imp.api_ms_win_core_registry_l1_1_0.dll_RegQueryValueExW]
test eax, eax
je 0x403f30
lea eax, [ebp - 0x210]
mov dword [ebp - 0x210], 4
push eax
lea eax, [ebp - 0x20c]
push eax
lea eax, [ebp - 0x214]
push eax
push 0
push 0x4016c8
push dword [ebp - 0x218]
call dword [sym.imp.api_ms_win_core_registry_l1_1_0.dll_RegQueryValueExW]
test eax, eax
je 0x403e7f
lea eax, [ebp - 0x210]
mov dword [ebp - 0x210], 4
push eax
lea eax, [ebp - 0x20c]
push eax
lea eax, [ebp - 0x214]
push eax
push 0
push 0x401678
push dword [ebp - 0x218]
call dword [sym.imp.api_ms_win_core_registry_l1_1_0.dll_RegQueryValueExW]
test eax, eax
je 0x403f53
cmp dword [esi + 0x14], 0
je 0x403bf1
lea eax, [ebp - 0x210]
mov dword [ebp - 0x210], 4
push eax
lea eax, [ebp - 0x20c]
push eax
lea eax, [ebp - 0x214]
push eax
push 0
push 0x4018c8
push dword [ebp - 0x218]
call dword [sym.imp.api_ms_win_core_registry_l1_1_0.dll_RegQueryValueExW]
test eax, eax
je 0x403ed5
mov ecx, dword [ebp - 0x20c]
test eax, eax
je 0x403ee7
mov dword [esi + 0x18], 4
lea eax, [ebp - 0x210]
mov dword [ebp - 0x210], 4
push eax
lea eax, [ebp - 0x20c]
push eax
lea eax, [ebp - 0x214]
push eax
push 0
push 0x4018a0
push dword [ebp - 0x218]
call dword [sym.imp.api_ms_win_core_registry_l1_1_0.dll_RegQueryValueExW]
test eax, eax
je 0x4066ab
mov ecx, dword [ebp - 0x20c]
test eax, eax
je 0x4066ca
mov dword [esi + 0x1c], 2
lea eax, [ebp - 0x210]
mov dword [ebp - 0x210], 4
push eax
lea eax, [ebp - 0x20c]
push eax
lea eax, [ebp - 0x214]
push eax
push 0
push 0x401868
push dword [ebp - 0x218]
call dword [sym.imp.api_ms_win_core_registry_l1_1_0.dll_RegQueryValueExW]
test eax, eax
jne 0x403b15
cmp dword [ebp - 0x214], 4
jne 0x4066d2
mov ecx, dword [ebp - 0x20c]
test eax, eax
jne 0x403ea2
mov dword [esi + 0x20], ecx
mov ecx, dword [ebp - 0x218]
lea eax, [ebp - 0x210]
push eax
lea eax, [ebp - 0x234]
mov edx, 0x401834
push eax
push 1
call fcn.00403fb0
test eax, eax
je 0x4066e4
lea eax, [ebp - 0x210]
mov dword [ebp - 0x210], 4
push eax
lea eax, [ebp - 0x20c]
push eax
lea eax, [ebp - 0x214]
push eax
push 0
push 0x401804
push dword [ebp - 0x218]
call dword [sym.imp.api_ms_win_core_registry_l1_1_0.dll_RegQueryValueExW]
test eax, eax
jne 0x403b91
cmp dword [ebp - 0x214], 4
jne 0x406720
mov ecx, dword [ebp - 0x20c]
test eax, eax
jne 0x403eae
mov dword [esi + 0x34], ecx
lea eax, [ebp - 0x210]
mov dword [ebp - 0x210], 4
push eax
lea eax, [ebp - 0x20c]
push eax
lea eax, [ebp - 0x214]
push eax
push 0
push 0x4017e4
push dword [ebp - 0x218]
call dword [sym.imp.api_ms_win_core_registry_l1_1_0.dll_RegQueryValueExW]
test eax, eax
je 0x403f8f
mov ecx, dword [ebp - 0x20c]
test eax, eax
je 0x403fa1
mov dword [esi + 0x38], 0xffff
lea eax, [ebp - 0x210]
mov dword [ebp - 0x210], 4
push eax
lea eax, [ebp - 0x20c]
push eax
lea eax, [ebp - 0x214]
push eax
push 0
push 0x40164c
push dword [ebp - 0x218]
call dword [sym.imp.api_ms_win_core_registry_l1_1_0.dll_RegQueryValueExW]
test eax, eax
je 0x403eba
lea eax, [ebp - 0x210]
mov dword [ebp - 0x210], 4
push eax
lea eax, [ebp - 0x20c]
push eax
lea eax, [ebp - 0x214]
push eax
push 0
push 0x40161c
push dword [ebp - 0x218]
call dword [sym.imp.api_ms_win_core_registry_l1_1_0.dll_RegQueryValueExW]
test eax, eax
je 0x403eef
lea eax, [ebp - 0x210]
mov dword [ebp - 0x210], 4
push eax
lea eax, [ebp - 0x20c]
push eax
lea eax, [ebp - 0x214]
push eax
push 0
push 0x4015fc
push dword [ebp - 0x218]
call dword [sym.imp.api_ms_win_core_registry_l1_1_0.dll_RegQueryValueExW]
test eax, eax
je 0x406762
lea eax, [ebp - 0x210]
mov dword [ebp - 0x210], 4
push eax
lea eax, [ebp - 0x20c]
push eax
lea eax, [ebp - 0x214]
push eax
push 0
push 0x4015e4
push dword [ebp - 0x218]
call dword [sym.imp.api_ms_win_core_registry_l1_1_0.dll_RegQueryValueExW]
test eax, eax
je 0x40678d
mov ecx, dword [ebp - 0x218]
lea eax, [ebp - 0x210]
push eax
lea eax, [ebp - 0x230]
mov edx, 0x4015b4
push eax
push 3
call fcn.00403fb0
mov ebx, dword [ebp - 0x230]
test eax, eax
je 0x403f76
cmp eax, 2
jne 0x4067cb
xor edi, edi
call fcn.00404070
xor ecx, ecx
call fcn.004040a0
test eax, eax
jne 0x4067e2
mov eax, dword [ebp - 0x218]
test eax, eax
je 0x403d65
lea ecx, [ebp - 0x210]
mov dword [ebp - 0x210], 4
push ecx
lea ecx, [ebp - 0x20c]
push ecx
lea ecx, [ebp - 0x214]
push ecx
push 0
push 0x401590
push eax
call dword [sym.imp.api_ms_win_core_registry_l1_1_0.dll_RegQueryValueExW]
test eax, eax
je 0x403f15
test edi, edi
jne 0x4067f9
mov eax, dword [ebp - 0x218]
test eax, eax
je 0x403dac
lea ecx, [ebp - 0x210]
mov dword [ebp - 0x210], 4
push ecx
lea ecx, [ebp - 0x20c]
push ecx
lea ecx, [ebp - 0x214]
push ecx
push 0
push 0x401564
push eax
call dword [sym.imp.api_ms_win_core_registry_l1_1_0.dll_RegQueryValueExW]
test eax, eax
je 0x406805
test edi, edi
jne 0x40682b
mov eax, dword [ebp - 0x218]
test eax, eax
je 0x403df3
lea ecx, [ebp - 0x210]
mov dword [ebp - 0x210], 4
push ecx
lea ecx, [ebp - 0x20c]
push ecx
lea ecx, [ebp - 0x214]
push ecx
push 0
push 0x401538
push eax
call dword [sym.imp.api_ms_win_core_registry_l1_1_0.dll_RegQueryValueExW]
test eax, eax
je 0x406837
test edi, edi
jne 0x40685d
lea eax, [ebp - 0x238]
push eax
push 0x20019
push 0
push 0x401400
push 0x80000002
call dword [sym.imp.api_ms_win_core_registry_l1_1_0.dll_RegOpenKeyExW]
test eax, eax
je 0x406869
mov edi, dword [ebp - 0x224]
mov esi, dword [ebp - 0x228]
test ebx, ebx
jne 0x4068b9
test edi, edi
jne 0x4068cd
mov eax, dword [ebp - 0x234]
test eax, eax
jne 0x4068e1
mov eax, dword [ebp - 0x218]
test eax, eax
je 0x403e5c
push eax
call dword [sym.imp.api_ms_win_core_registry_l1_1_0.dll_RegCloseKey]
mov eax, dword [ebp - 0x238]
test eax, eax
jne 0x4068f5
mov ecx, dword [ebp - 4]
mov eax, esi
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.00405790
mov esp, ebp
pop ebp
ret 4
cmp dword [ebp - 0x214], 4
jne 0x40667b
cmp dword [ebp - 0x20c], 0
je 0x4039f0
or dword [esi + 0x58], 0x20
jmp 0x4039f0
mov dword [esi + 0x20], 0x3000
jmp 0x403b26
mov dword [esi + 0x34], 0xffff
jmp 0x403ba2
cmp dword [ebp - 0x214], 4
jne 0x406744
mov eax, dword [ebp - 0x20c]
mov dword [esi + 0x3c], eax
jmp 0x403c2b
cmp dword [ebp - 0x214], 4
je 0x403a6e
jmp 0x406699
mov dword [esi + 0x18], ecx
jmp 0x403a83
cmp dword [ebp - 0x214], 4
jne 0x406753
cmp dword [ebp - 0x20c], 0
jne 0x403c65
mov dword [esi + 0x40], 1
jmp 0x403c65
cmp dword [ebp - 0x214], 4
jne 0x4067ea
mov eax, dword [ebp - 0x20c]
mov dword [esi + 0x4c], eax
jmp 0x403d6d
cmp dword [ebp - 0x214], 4
jne 0x40666c
cmp dword [ebp - 0x20c], 0
je 0x4039b6
or dword [esi + 0x58], 0x10
jmp 0x4039b6
cmp dword [ebp - 0x214], 4
jne 0x40668a
cmp dword [ebp - 0x20c], 0
je 0x403a2a
or dword [esi + 0x58], 0x40
jmp 0x403a2a
push ebx
call dword [sym.imp.ntdll.dll_RtlValidSecurityDescriptor]
test al, al
je 0x4067bb
mov dword [esi + 0x5c], ebx
xor ebx, ebx
jmp 0x403d10
cmp dword [ebp - 0x214], 4
je 0x403bdc
jmp 0x406732
mov dword [esi + 0x38], ecx
jmp 0x403bf1
mov eax, dword [ebp - 0x22c]
lea esi, [esi + eax*2]
add esi, 2
jmp 0x40389b
mov eax, dword [ebp - 0x21c]
add eax, 2
push eax
push 0
push dword [0x40837c]
call dword [sym.imp.api_ms_win_core_heap_l1_1_0.dll_HeapAlloc]
mov ecx, eax
mov dword [ebp - 0x210], ecx
test ecx, ecx
je 0x4038bb
mov edi, dword [ebp - 0x220]
mov dword [ebp - 0x21c], ecx
cmp dword [ebp - 0x228], ebx
jne 0x40657e
cmp edi, 2
jb 0x40657e
mov ebx, dword [0x408394]
test ebx, ebx
je 0x40657e
cmp word [ebx], 0
je 0x40657e
mov esi, eax
mov ecx, ebx
lea edx, [ecx + 2]
mov ax, word [ecx]
add ecx, 2
test ax, ax
jne 0x40651e
sub ecx, edx
sar ecx, 1
lea eax, [ecx*2 + 2]
push eax
push ebx
push esi
call sub.api_ms_win_core_crt_l1_1_0.dll_memcpy
mov ecx, ebx
add esp, 0xc
lea edx, [ecx + 2]
mov ax, word [ecx]
add ecx, 2
test ax, ax
jne 0x406544
sub ecx, edx
sar ecx, 1
lea esi, [esi + ecx*2]
mov ecx, ebx
add esi, 2
lea edx, [ecx + 2]
mov ax, word [ecx]
add ecx, 2
test ax, ax
jne 0x40655e
sub ecx, edx
sar ecx, 1
lea ebx, [ebx + ecx*2]
add ebx, 2
cmp word [ebx], ax
jne 0x406519
mov dword [ebp - 0x21c], esi
mov esi, dword [ebp - 0x21c]
xor ebx, ebx
push 0
push 0
push 0
push 0
lea eax, [ebp - 0x22c]
mov dword [ebp - 0x22c], 0x101
push eax
lea eax, [ebp - 0x208]
push eax
push ebx
push dword [ebp - 0x218]
call dword [sym.imp.api_ms_win_core_registry_l1_1_0.dll_RegEnumKeyExW]
mov dword [ebp - 0x21c], eax
test eax, eax
jne 0x4065ff
lea ecx, [ebp - 0x208]
lea edx, [ecx + 2]
mov ax, word [ecx]
add ecx, 2
test ax, ax
jne 0x4065c6
sub ecx, edx
sar ecx, 1
lea eax, [ecx*2 + 2]
push eax
lea eax, [ebp - 0x208]
push eax
push esi
call sub.api_ms_win_core_crt_l1_1_0.dll_memcpy
mov eax, dword [ebp - 0x22c]
add esp, 0xc
lea esi, [esi + eax*2]
mov eax, dword [ebp - 0x21c]
add esi, 2
inc ebx
test eax, eax
je 0x406586
xor eax, eax
mov word [esi], ax
mov eax, dword [0x408394]
mov esi, dword [ebp - 0x214]
test eax, eax
je 0x406627
push eax
push 0
push dword [0x40837c]
call dword [sym.imp.api_ms_win_core_heap_l1_1_0.dll_HeapFree]
mov ecx, dword [ebp - 0x210]
xor edx, edx
mov eax, ecx
mov dword [ebp - 0x228], edx
mov dword [0x408394], eax
jmp 0x4038c6
test ecx, ecx
je 0x4038e1
jmp 0x4038d7
mov dword [ebp - 0x20c], 0
jmp 0x40392d
mov dword [ebp - 0x20c], 0
jmp 0x40397c
mov dword [ebp - 0x20c], 0
jmp 0x4039b6
mov dword [ebp - 0x20c], 0
jmp 0x4039f0
mov dword [ebp - 0x20c], 0
jmp 0x403a2a
xor ecx, ecx
mov eax, 0x70c
mov dword [ebp - 0x20c], ecx
jmp 0x403a74
cmp dword [ebp - 0x214], 4
je 0x403abd
xor ecx, ecx
mov eax, 0x70c
mov dword [ebp - 0x20c], ecx
jmp 0x403ac3
mov dword [esi + 0x1c], ecx
jmp 0x403ad2
xor ecx, ecx
mov eax, 0x70c
mov dword [ebp - 0x20c], ecx
jmp 0x403b1b
lea edi, [esi + 0x24]
push edi
push dword [ebp - 0x234]
call dword [sym.imp.api_ms_win_core_com_l1_1_0.dll_CLSIDFromString]
test eax, eax
jns 0x403b4e
mov eax, dword [0x401950]
mov dword [edi], eax
mov eax, dword [0x401954]
mov dword [edi + 4], eax
mov eax, dword [0x401958]
mov dword [edi + 8], eax
mov eax, dword [0x40195c]
mov dword [edi + 0xc], eax
jmp 0x403b4e
xor ecx, ecx
mov eax, 0x70c
mov dword [ebp - 0x20c], ecx
jmp 0x403b97
xor ecx, ecx
mov eax, 0x70c
mov dword [ebp - 0x20c], ecx
jmp 0x403be2
mov dword [ebp - 0x20c], 0
jmp 0x403c2b
mov dword [ebp - 0x20c], 0
jmp 0x403c65
cmp dword [ebp - 0x214], 4
je 0x40677a
mov dword [ebp - 0x20c], 0
jmp 0x403c9f
xor eax, eax
cmp dword [ebp - 0x20c], eax
setne al
mov dword [esi + 0x44], eax
jmp 0x403c9f
cmp dword [ebp - 0x214], 4
je 0x4067a5
mov dword [ebp - 0x20c], 0
jmp 0x403cd9
cmp dword [ebp - 0x20c], 0
je 0x403cd9
or dword [esi + 0x58], 8
jmp 0x403cd9
mov edi, dword [ebp - 0x224]
mov esi, 0xd
jmp 0x403e2d
mov edi, dword [ebp - 0x224]
mov esi, eax
jmp 0x403e2d
mov esi, 0xd
jmp 0x403e4b
mov edi, dword [esi + 0x48]
jmp 0x403d26
mov dword [ebp - 0x20c], 0
jmp 0x403d65
mov dword [esi + 0x4c], 1
jmp 0x403d6d
cmp dword [ebp - 0x214], 4
je 0x40681d
mov dword [ebp - 0x20c], 0
jmp 0x403dac
mov eax, dword [ebp - 0x20c]
mov dword [esi + 0x50], eax
jmp 0x403db4
mov dword [esi + 0x50], 1
jmp 0x403db4
cmp dword [ebp - 0x214], 4
je 0x40684f
mov dword [ebp - 0x20c], 0
jmp 0x403df3
mov eax, dword [ebp - 0x20c]
mov dword [esi + 0x54], eax
jmp 0x403dfb
mov dword [esi + 0x54], 1
jmp 0x403dfb
mov ecx, dword [ebp - 0x238]
lea eax, [ebp - 0x210]
push eax
lea eax, [ebp - 0x224]
mov edx, 0x401cf0
push eax
push 1
call fcn.00403fb0
mov edi, dword [ebp - 0x224]
test eax, eax
jne 0x403e27
push 1
push 0xffffffffffffffff
push edi
push 0xffffffffffffffff
push dword [esi + 0xc]
call dword [sym.imp.api_ms_win_core_string_l1_1_0.dll_CompareStringOrdinal]
cmp eax, 2
jne 0x403e27
or dword [esi + 0x58], 4
jmp 0x403e27
push ebx
push 0
push dword [0x40837c]
call dword [sym.imp.api_ms_win_core_heap_l1_1_0.dll_HeapFree]
jmp 0x403e35
push edi
push 0
push dword [0x40837c]
call dword [sym.imp.api_ms_win_core_heap_l1_1_0.dll_HeapFree]
jmp 0x403e3d
push eax
push 0
push dword [0x40837c]
call dword [sym.imp.api_ms_win_core_heap_l1_1_0.dll_HeapFree]
jmp 0x403e4b
push eax
call dword [sym.imp.api_ms_win_core_registry_l1_1_0.dll_RegCloseKey]
jmp 0x403e6a