Function at 0x40ad40
Capabilities:
Query or enumerate registry value

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x6e8
mov eax, dword [0x57c06c]
xor eax, ebp
mov dword [ebp - 8], eax
mov eax, dword [ebp + 8]
push ebx
push esi
push edi
xor esi, esi
mov dword [ebp - 0x6e8], eax
push esi
push esi
push esi
push 0xa
push esi
push esi
lea eax, [ebp - 0x6ac]
mov dword [ebp - 0x6e4], edx
push eax
mov dword [ebp - 0x6d4], ecx
mov dword [ebp - 0x6ac], 0x4d36e96e
mov dword [ebp - 0x6a8], 0x11cee325
mov dword [ebp - 0x6a4], 0x8c1bf
mov dword [ebp - 0x6a0], 0x1803e12b
call dword [sym.imp.SETUPAPI.dll_SetupDiGetClassDevsExW]
mov ebx, eax
mov dword [ebp - 0x6cc], ebx
test ebx, ebx
jne 0x40adc6
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 8]
xor ecx, ebp
call fcn.004e24d7
mov esp, ebp
pop ebp
ret
xor edi, edi
mov dword [ebp - 0x6d0], edi
call dword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 0x103
je 0x40af93
nop
lea eax, [ebp - 0x6c8]
mov dword [ebp - 0x6b0], 0
push eax
xorps xmm0, xmm0
push edi
movups xmmword [ebp - 0x6c8], xmm0
push ebx
movq qword [ebp - 0x6b8], xmm0
mov dword [ebp - 0x6c8], 0x1c
call dword [sym.imp.SETUPAPI.dll_SetupDiEnumDeviceInfo]
test eax, eax
je 0x40af75
push 0
push 0x104
lea eax, [ebp - 0x29c]
push eax
lea eax, [ebp - 0x6c8]
push eax
push ebx
call dword [sym.imp.SETUPAPI.dll_SetupDiGetDeviceInstanceIdW]
test eax, eax
je 0x40af75
push dword [ebp - 0x6d4]
lea eax, [ebp - 0x29c]
push eax
call fcn.004e4202
add esp, 8
test eax, eax
je 0x40af75
push 0x20019
push 1
push 0
push 1
lea eax, [ebp - 0x6c8]
push eax
push ebx
call dword [sym.imp.SETUPAPI.dll_SetupDiOpenDevRegKey]
mov ebx, eax
test ebx, ebx
je 0x40af6f
cmp ebx, 0xffffffff
je 0x40af6f
push 0x100
lea eax, [ebp - 0x10c]
mov dword [ebp - 0x6dc], 0
push 0
push eax
mov dword [ebp - 0x6e0], 0x80
call fcn.004e5200
push 0x400
lea eax, [ebp - 0x69c]
push 0
push eax
call fcn.004e5200
add esp, 0x18
mov dword [ebp - 0x6d8], 0x400
xor esi, esi
lea eax, [ebp - 0x6d8]
push eax
lea eax, [ebp - 0x69c]
push eax
lea eax, [ebp - 0x6dc]
push eax
push 0
lea eax, [ebp - 0x6e0]
push eax
lea eax, [ebp - 0x10c]
push eax
push esi
push ebx
call dword [sym.imp.ADVAPI32.dll_RegEnumValueW]
mov edi, eax
test edi, edi
jne 0x40af4f
lea eax, [ebp - 0x10c]
push eax
call fcn.004fe0f4
add esp, 4
lea ecx, [ebp - 0x10c]
mov eax, str.EDID
mov dx, word [ecx]
cmp dx, word [eax]
jne 0x40af46
test dx, dx
je 0x40af42
mov dx, word [ecx + 2]
cmp dx, word [eax + 2]
jne 0x40af46
add ecx, 4
add eax, 4
test dx, dx
jne 0x40af20
xor eax, eax
jmp 0x40af4b
sbb eax, eax
or eax, 1
test eax, eax
je 0x40afad
inc esi
cmp edi, 0x103
jne 0x40aed3
xor esi, esi
push ebx
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
test esi, esi
jne 0x40af8d
mov edi, dword [ebp - 0x6d0]
mov ebx, dword [ebp - 0x6cc]
inc edi
mov dword [ebp - 0x6d0], edi
call dword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 0x103
jne 0x40ade0
mov ebx, dword [ebp - 0x6cc]
push ebx
call dword [sym.imp.SETUPAPI.dll_SetupDiDestroyDeviceInfoList]
mov ecx, dword [ebp - 8]
mov eax, esi
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.004e24d7
mov esp, ebp
pop ebp
ret
mov dl, byte [ebp - 0x658]
mov esi, 1
mov al, dl
and dl, 0xf
and al, 0xf0
movzx ecx, al
movzx eax, byte [ebp - 0x65a]
shl cx, 4
add cx, ax
mov eax, dword [ebp - 0x6e4]
mov word [eax], cx
mov eax, 0x100
movzx ecx, dl
cwde
movsx ecx, cx
imul ecx, eax
movzx eax, byte [ebp - 0x659]
add cx, ax
mov eax, dword [ebp - 0x6e8]
mov word [eax], cx
jmp 0x40af5e