Function at 0x40b300
Capabilities:
Query or enumerate registry value

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x40d3d1
mov eax, dword fs:[0]
push eax
sub esp, 0x2b0
mov eax, dword [0x412194]
xor eax, ebp
mov dword [ebp - 0x2c], eax
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov dword [ebp - 0x20], 0x80004005
call fcn.00401460
mov dword [ebp - 0x1c], eax
push 0x41001c
push str.Attempting_to_open_the_following_registry_path:
call fcn.0040ae00
add esp, 8
lea eax, [ebp - 0x18]
push eax
push 0x20019
push 0
push str.SoftwareHewlett_PackardDigitalImagingTrayAppPlugIns
push reloc.OLEAUT32.dll_SysReAllocString
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExA]
test eax, eax
jne 0x40b69d
mov dword [ebp - 0x248], 0
mov dword [ebp - 0x24c], 0
lea ecx, [ebp - 0x138]
call fcn.004010f0
mov dword [ebp - 4], 0
push str.Open_succeeded__enumerating_values_found_there
call fcn.0040ade0
add esp, 4
lea ecx, [ebp - 0x138]
call fcn.004010d0
test eax, eax
ja 0x40b64c
cmp dword [ebp - 0x248], 0x103
je 0x40b64c
mov dword [ebp - 0x250], 0x104
mov dword [ebp - 0x13c], 0x104
lea ecx, [ebp - 0x13c]
push ecx
lea edx, [ebp - 0x244]
push edx
lea eax, [ebp - 0x28]
push eax
push 0
lea ecx, [ebp - 0x250]
push ecx
lea edx, [ebp - 0x134]
push edx
mov eax, dword [ebp - 0x24c]
push eax
mov ecx, dword [ebp - 0x18]
push ecx
call dword [sym.imp.ADVAPI32.dll_RegEnumValueA]
mov dword [ebp - 0x248], eax
cmp dword [ebp - 0x248], 0
jne 0x40b600
lea edx, [ebp - 0x134]
push edx
call fcn.00401d20
add esp, 4
test eax, eax
jbe 0x40b5f1
lea eax, [ebp - 0x244]
push eax
call fcn.00401d20
add esp, 4
test eax, eax
jbe 0x40b5f1
lea ecx, [ebp - 0x134]
push ecx
push str.Key_found:
call fcn.0040ae00
add esp, 8
lea edx, [ebp - 0x244]
push edx
push str.Contents:
call fcn.0040ae00
add esp, 8
lea ecx, [ebp - 0x138]
call fcn.004010c0
push eax
lea eax, [ebp - 0x244]
push eax
call fcn.0040ae30
test eax, eax
jl 0x40b5e4
lea ecx, [ebp - 0x138]
call fcn.00401190
mov dword [ebp - 0x14], eax
cmp dword [ebp - 0x14], 0
jne 0x40b4b5
mov dword [ebp - 0x2a8], 0
jmp 0x40b516
mov ecx, dword [ebp - 0x14]
push ecx
call dword [sym.imp.KERNEL32.dll_lstrlenW]
add eax, 1
mov dword [ebp - 0x10], eax
cmp dword [ebp - 0x10], 0x3fffffff
jle 0x40b4da
mov dword [ebp - 0x2ac], 0
jmp 0x40b50a
mov eax, dword [ebp - 0x10]
shl eax, 1
call fcn.00406fd0
mov dword [ebp - 0x2b0], esp
mov edx, dword [ebp - 0x1c]
push edx
mov eax, dword [ebp - 0x10]
shl eax, 1
push eax
mov ecx, dword [ebp - 0x14]
push ecx
mov edx, dword [ebp - 0x2b0]
push edx
call fcn.00401140
mov dword [ebp - 0x2ac], eax
mov eax, dword [ebp - 0x2ac]
mov dword [ebp - 0x2a8], eax
mov ecx, dword [ebp - 0x2a8]
push ecx
push str.Filename_for_this_COM_Server:
call fcn.0040ae00
add esp, 8
lea ecx, [ebp - 0x138]
call fcn.00401190
mov dword [ebp - 0x14], eax
cmp dword [ebp - 0x14], 0
jne 0x40b54a
mov dword [ebp - 0x2b4], 0
jmp 0x40b5ab
mov edx, dword [ebp - 0x14]
push edx
call dword [sym.imp.KERNEL32.dll_lstrlenW]
add eax, 1
mov dword [ebp - 0x10], eax
cmp dword [ebp - 0x10], 0x3fffffff
jle 0x40b56f
mov dword [ebp - 0x2b8], 0
jmp 0x40b59f
mov eax, dword [ebp - 0x10]
shl eax, 1
call fcn.00406fd0
mov dword [ebp - 0x2bc], esp
mov eax, dword [ebp - 0x1c]
push eax
mov ecx, dword [ebp - 0x10]
shl ecx, 1
push ecx
mov edx, dword [ebp - 0x14]
push edx
mov eax, dword [ebp - 0x2bc]
push eax
call fcn.00401140
mov dword [ebp - 0x2b8], eax
mov ecx, dword [ebp - 0x2b8]
mov dword [ebp - 0x2b4], ecx
mov edx, dword [ebp - 0x2b4]
push edx
call fcn.0040aa40
test eax, eax
jne 0x40b5d5
lea ecx, [ebp - 0x138]
call fcn.004010a0
push str.File_does_not_exist
call fcn.0040ade0
add esp, 4
jmp 0x40b5e2
push str.File_exists
call fcn.0040ade0
add esp, 4
jmp 0x40b5ef
lea ecx, [ebp - 0x138]
call fcn.004010a0
jmp 0x40b5fe
push str.Skipping_default_key
call fcn.0040ade0
add esp, 4
jmp 0x40b638
mov eax, dword [ebp - 0x248]
push eax
mov ecx, dword [ebp - 0x24c]
push ecx
push str.Index:__d__Error:__d
push 0x50
lea edx, [ebp - 0x2a4]
push edx
call fcn.00401b8b
add esp, 0x14
lea eax, [ebp - 0x2a4]
push eax
push str.Failed_to_enumerate_key:
call fcn.0040ae00
add esp, 8
mov ecx, dword [ebp - 0x24c]
add ecx, 1
mov dword [ebp - 0x24c], ecx
jmp 0x40b3a2
lea ecx, [ebp - 0x138]
call fcn.004010d0
test eax, eax
jbe 0x40b67a
cmp dword [ebp + 8], 0
je 0x40b67a
lea ecx, [ebp - 0x138]
call fcn.00401110
mov edx, dword [ebp + 8]
mov dword [edx], eax
mov dword [ebp - 0x20], 0
jmp 0x40b681
mov dword [ebp - 0x20], 0x80004005
mov eax, dword [ebp - 0x18]
push eax
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
mov dword [ebp - 4], 0xffffffff
lea ecx, [ebp - 0x138]
call fcn.00401240
mov eax, dword [ebp - 0x20]
lea esp, [ebp - 0x2c0]
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
mov ecx, dword [ebp - 0x2c]
xor ecx, ebp
call fcn.0040147b
mov esp, ebp
pop ebp
ret 4