Function at 0x40bf30
Capabilities:
Delete registry value
Query or enumerate registry value
Set registry value

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff8
push 0xffffffffffffffff
push 0x42a786
mov eax, dword fs:[0]
push eax
sub esp, 0x154
mov eax, dword [0x43b010]
xor eax, esp
mov dword [esp + 0x14c], eax
push ebx
push esi
mov eax, dword [0x43b010]
xor eax, esp
push eax
lea eax, [esp + 0x160]
mov dword fs:[0], eax
mov esi, ecx
mov dword [esp + 0xc], 0
lea ecx, [esp + 0x3c]
push 0x2a
xor eax, eax
mov dword [esp + 0x54], 7
push str.SoftwareHewlett_PackardHP_Print_Settings
mov bl, 1
mov dword [esp + 0x54], 0
mov word [esp + 0x44], ax
call fcn.0040adb0
cmp dword [esp + 0x50], 8
lea ecx, [esp + 0xc]
push ecx
lea ecx, [esp + 0x14]
mov dword [esp + 0x14], 0
push ecx
push 0
push 0xf003f
push 0
push 0
lea eax, [esp + 0x54]
mov dword [esp + 0x2c], 2
cmovae eax, dword [esp + 0x54]
push 0
push eax
push 0x80000002
mov byte [esp + 0x40], 0
call dword [sym.imp.ADVAPI32.dll_RegCreateKeyExW]
mov dword [esp + 0x18], eax
test eax, eax
jne 0x40bffd
cmp dword [esp + 0xc], 1
jne 0x40c005
mov byte [esp + 0x1c], bl
jmp 0x40c005
mov dword [esp + 0x10], 0
mov dword [esp + 0x168], 0
cmp dword [esp + 0x50], 8
jb 0x40c023
push dword [esp + 0x3c]
call fcn.004144c0
add esp, 4
xor eax, eax
mov dword [esp + 0x38], 7
mov dword [esp + 0x34], 0
mov word [esp + 0x24], ax
lea eax, [esp + 0x24]
mov byte [esp + 0x168], 1
push eax
push 0x43c990
mov ecx, esi
call fcn.0040df90
test al, al
je 0x40c083
mov eax, dword [esp + 0x10]
test eax, eax
je 0x40c081
push 0x12
push str.19728374
push 1
push 0
push str.UPDMPA
push eax
call dword [sym.imp.ADVAPI32.dll_RegSetValueExW]
test eax, eax
mov dword [esp + 0x18], eax
sete bl
jmp 0x40c083
xor bl, bl
lea eax, [esp + 0x24]
mov ecx, esi
push eax
push 0x43c930
call fcn.0040df90
test al, al
je 0x40c0e1
cmp dword [esp + 0x34], 0
je 0x40c0e1
push str.Policy
lea ecx, [esp + 0x40]
call fcn.0040a170
lea eax, [esp + 0x24]
push eax
lea eax, [esp + 0x40]
push eax
lea ecx, [esp + 0x18]
call fcn.004139d0
test al, al
je 0x40c0cc
test bl, bl
je 0x40c0cc
mov bl, 1
jmp 0x40c0ce
xor bl, bl
cmp dword [esp + 0x50], 8
jb 0x40c0e1
push dword [esp + 0x3c]
call fcn.004144c0
add esp, 4
lea eax, [esp + 0x24]
mov ecx, esi
push eax
push 0x43c950
call fcn.0040df90
mov esi, dword [esp + 0x10]
test al, al
je 0x40c142
test esi, esi
je 0x40c142
lea eax, [esp + 0xc]
mov dword [esp + 0xc], pe_nt_image_headers32
push eax
lea eax, [esp + 0x58]
push eax
lea eax, [esp + 0x28]
push eax
push 0
push str.UPDMPA
push esi
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExW]
test eax, eax
je 0x40c12e
cmp eax, 0xea
jne 0x40c13a
push str.UPDMPA
push esi
call dword [sym.imp.ADVAPI32.dll_RegDeleteValueW]
mov esi, dword [esp + 0x10]
mov dword [esp + 0x18], eax
cmp dword [esp + 0x38], 8
jb 0x40c159
push dword [esp + 0x24]
call fcn.004144c0
mov esi, dword [esp + 0x14]
add esp, 4
xor eax, eax
mov dword [esp + 0x38], 7
mov dword [esp + 0x34], 0
mov word [esp + 0x24], ax
test esi, esi
je 0x40c17b
push esi
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
mov al, bl
mov ecx, dword [esp + 0x160]
mov dword fs:[0], ecx
pop ecx
pop esi
pop ebx
mov ecx, dword [esp + 0x14c]
xor ecx, esp
call fcn.0041729b
mov esp, ebp
pop ebp
ret