Function at 0x413d05
Capabilities:
Query or enumerate registry key

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x44d2cc
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
sub esp, 0x130
mov dword [ebp - 0x13c], ecx
mov dword [ebp - 4], 0
mov dword [ebp - 0x14], 0
mov dword [ebp - 0x20], 0
call fcn.00404650
mov dword [ebp - 0x2c], eax
push 0
lea eax, [ebp - 0x28]
push eax
push 0x100
lea ecx, [ebp + 8]
call fcn.0043e2c3
push eax
call sub.WINSPOOL.DRV_OpenPrinterA
mov dword [ebp - 0x30], eax
cmp dword [ebp - 0x30], 0
jne 0x413d7c
mov dword [ebp - 4], 0xffffffff
lea ecx, [ebp + 8]
call fcn.0043de93
jmp 0x413f5f
lea ecx, [ebp - 0x20]
push ecx
mov edx, dword [ebp - 0x14]
push edx
push 0
push 2
mov eax, dword [ebp - 0x28]
push eax
call sub.WINSPOOL.DRV_GetPrinterA
mov dword [ebp - 0x30], eax
cmp dword [ebp - 0x30], 0
jne 0x413dc6
call dword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 0x7a
je 0x413dc6
push 0x4606f4
call fcn.00414290
add esp, 4
mov dword [ebp - 4], 0xffffffff
lea ecx, [ebp + 8]
call fcn.0043de93
jmp 0x413f5f
mov ecx, dword [ebp - 0x20]
push ecx
call fcn.0042c840
add esp, 4
mov dword [ebp - 0x24], eax
cmp dword [ebp - 0x24], 0
jne 0x413def
mov dword [ebp - 4], 0xffffffff
lea ecx, [ebp + 8]
call fcn.0043de93
jmp 0x413f5f
mov edx, dword [ebp - 0x20]
mov dword [ebp - 0x14], edx
lea eax, [ebp - 0x20]
push eax
mov ecx, dword [ebp - 0x14]
push ecx
mov edx, dword [ebp - 0x24]
push edx
push 2
mov eax, dword [ebp - 0x28]
push eax
call sub.WINSPOOL.DRV_GetPrinterA
test eax, eax
jne 0x413e46
push 0x46072c
call fcn.00414290
add esp, 4
mov ecx, dword [ebp - 0x28]
push ecx
call sub.WINSPOOL.DRV_ClosePrinter
mov edx, dword [ebp - 0x24]
push edx
call fcn.0042c57b
add esp, 4
mov dword [ebp - 4], 0xffffffff
lea ecx, [ebp + 8]
call fcn.0043de93
jmp 0x413f5f
mov eax, dword [ebp - 0x24]
mov dword [ebp - 0x1c], eax
mov ecx, dword [ebp - 0x1c]
mov edx, dword [ecx + 0x10]
push edx
lea ecx, [ebp - 0x18]
call fcn.0043df01
mov byte [ebp - 4], 1
lea eax, [ebp - 0x38]
push eax
push 0x20019
push 0
mov ecx, dword [ebp - 0x2c]
add ecx, 0xec
call fcn.00404600
push eax
push reloc.OLEAUT32.dll_SysReAllocString
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExA]
test eax, eax
je 0x413eba
cmp dword [ebp - 0x24], 0
je 0x413e9a
mov ecx, dword [ebp - 0x24]
push ecx
call fcn.0042c57b
add esp, 4
mov byte [ebp - 4], 0
lea ecx, [ebp - 0x18]
call fcn.0043de93
mov dword [ebp - 4], 0xffffffff
lea ecx, [ebp + 8]
call fcn.0043de93
jmp 0x413f5f
mov dword [ebp - 0x10], 0
push 0xff
lea edx, [ebp - 0x138]
push edx
mov eax, dword [ebp - 0x10]
push eax
mov ecx, dword [ebp - 0x38]
push ecx
call dword [sym.imp.ADVAPI32.dll_RegEnumKeyA]
mov dword [ebp - 0x34], eax
cmp dword [ebp - 0x34], 0x103
je 0x413eed
cmp dword [ebp - 0x34], 6
jne 0x413eef
jmp 0x413f25
lea edx, [ebp - 0x138]
push edx
lea ecx, [ebp - 0x18]
call fcn.0043cb31
test eax, eax
jl 0x413f13
lea eax, [ebp - 0x138]
push eax
mov ecx, dword [ebp + 0xc]
call fcn.0043e01c
jmp 0x413f25
mov ecx, dword [ebp - 0x10]
add ecx, 1
mov dword [ebp - 0x10], ecx
mov edx, 1
test edx, edx
jne 0x413ec1
mov eax, dword [ebp - 0x38]
push eax
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
mov ecx, dword [ebp - 0x28]
push ecx
call sub.WINSPOOL.DRV_ClosePrinter
mov edx, dword [ebp - 0x24]
push edx
call fcn.0042c57b
add esp, 4
mov byte [ebp - 4], 0
lea ecx, [ebp - 0x18]
call fcn.0043de93
mov dword [ebp - 4], 0xffffffff
lea ecx, [ebp + 8]
call fcn.0043de93
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
mov esp, ebp
pop ebp
ret 8