Function at 0x41025220
Capabilities:
Set registry value

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x41149200
mov eax, dword fs:[0]
push eax
sub esp, 0x1c
push ebx
push esi
push edi
mov eax, dword [0x411bade8]
xor eax, ebp
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov esi, ecx
xor edi, edi
mov dword [ebp - 4], edi
call fcn.41040000
xor ecx, ecx
cmp eax, edi
setne cl
cmp ecx, edi
jne 0x41025269
push 0x80004005
call fcn.410011f0
mov edx, dword [eax]
mov ecx, eax
mov eax, dword [edx + 0xc]
call eax
lea ebx, [eax + 0x10]
mov dword [ebp - 0x14], ebx
mov byte [ebp - 4], 1
call fcn.41040000
xor ecx, ecx
cmp eax, edi
setne cl
cmp ecx, edi
jne 0x41025296
push 0x80004005
call fcn.410011f0
mov edx, dword [eax]
mov ecx, eax
mov eax, dword [edx + 0xc]
call eax
add eax, 0x10
mov dword [ebp - 0x24], eax
push edi
push 0x411584dc
lea ecx, [ebp - 0x24]
mov byte [ebp - 4], 2
mov dword [ebp - 0x28], edi
call fcn.410016e0
push str.PrinterDriverData
lea ecx, [ebp - 0x10]
mov byte [ebp - 4], 3
call fcn.41002090
mov ecx, dword [esi + 0xc]
add esi, 0xc
mov byte [ebp - 4], 4
cmp dword [ecx - 0xc], edi
jne 0x41025388
push str.CTPPrnTemplates::SetPrinterDataEx_called_with_empty_printer_name
push 0x2000001
push 0xaf
push str.TPPrnTemplates.cpp
call fcn.41002c10
mov eax, dword [ebp - 0x10]
add eax, 0xfffffff0
add esp, 0x10
mov byte [ebp - 4], 3
lea edx, [eax + 0xc]
or ecx, 0xffffffff
lock xadd dword [edx], ecx
dec ecx
test ecx, ecx
jg 0x4102531d
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
lea ecx, [ebp - 0x28]
mov byte [ebp - 4], 1
call fcn.41010de0
lea eax, [ebx - 0x10]
mov byte [ebp - 4], 0
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x41025349
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov eax, dword [ebp + 8]
add eax, 0xfffffff0
mov dword [ebp - 4], 0xffffffff
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x4102536f
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov eax, 2
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 0x14
mov ecx, dword [ebp - 0x10]
mov eax, dword [ecx - 0xc]
push eax
lea edx, [ebp - 0x18]
push edx
lea ecx, [ebp + 8]
call fcn.41007850
lea ecx, [ebp - 0x10]
push ecx
push eax
call fcn.4100a730
mov bl, al
mov eax, dword [ebp - 0x18]
add eax, 0xfffffff0
add esp, 8
lea edx, [eax + 0xc]
or ecx, 0xffffffff
lock xadd dword [edx], ecx
dec ecx
test ecx, ecx
jg 0x410253c9
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
test bl, bl
je 0x410253dd
mov ecx, dword [ebp - 0x10]
mov eax, dword [ecx - 0xc]
push eax
push edi
lea ecx, [ebp + 8]
call fcn.41016a00
push 0x5c
lea ecx, [ebp + 8]
call fcn.41024790
push esi
lea edx, [ebp - 0x20]
push str.SOFTWAREThinPrintTPPrnUI_
push edx
call fcn.41024990
push 0x41158aa4
push eax
lea eax, [ebp - 0x1c]
push eax
mov byte [ebp - 4], 5
call fcn.41006bf0
lea ecx, [ebp + 8]
push ecx
push eax
lea edx, [ebp - 0x18]
mov bl, 6
push edx
mov byte [ebp - 4], bl
call fcn.41005670
add esp, 0x24
push eax
lea ecx, [ebp - 0x14]
mov byte [ebp - 4], 7
call fcn.410043b0
mov eax, dword [ebp - 0x18]
add eax, 0xfffffff0
mov byte [ebp - 4], bl
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x4102544e
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov eax, dword [ebp - 0x1c]
add eax, 0xfffffff0
mov byte [ebp - 4], 5
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x41025471
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov eax, dword [ebp - 0x20]
add eax, 0xfffffff0
mov byte [ebp - 4], 4
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x41025494
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
push 0x5c
lea ecx, [ebp - 0x14]
call fcn.41024900
mov ebx, dword [ebp - 0x14]
lea ecx, [ebp - 0x20]
push ecx
lea edx, [ebp - 0x18]
push edx
push edi
push 0xf003f
push edi
push edi
push edi
push ebx
push reloc.OLEAUT32.dll_SysReAllocString
mov dword [ebp - 0x18], edi
call dword [sym.imp.ADVAPI32.dll_RegCreateKeyExW]
mov esi, eax
cmp esi, edi
jne 0x410254f4
mov eax, dword [ebp - 0x28]
xor esi, esi
cmp eax, edi
je 0x410254dc
push eax
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
mov esi, eax
mov dword [ebp - 0x28], edi
push edi
push 0x411584dc
lea ecx, [ebp - 0x24]
call fcn.410016e0
mov eax, dword [ebp - 0x18]
mov dword [ebp - 0x28], eax
cmp esi, edi
je 0x41025514
push esi
push ebx
push str.CTPPrnTemplates::SetPrinterDataEx_cannot_open_Registry_HKLM___s__errror__d
push 0x2000001
push 0xc3
push str.TPPrnTemplates.cpp
call fcn.41002c10
add esp, 0x18
jmp 0x4102553a
mov eax, dword [ebp + 0xc]
cmp eax, edi
je 0x4102553a
cmp word [eax], di
je 0x4102553a
mov ecx, dword [ebp + 0x18]
mov edx, dword [ebp + 0x14]
push ecx
mov ecx, dword [ebp + 0x10]
push edx
mov edx, dword [ebp - 0x28]
push ecx
push edi
push eax
push edx
call dword [sym.imp.ADVAPI32.dll_RegSetValueExW]
mov esi, eax
mov eax, dword [ebp - 0x10]
add eax, 0xfffffff0
or edx, 0xffffffff
lea ecx, [eax + 0xc]
mov byte [ebp - 4], 3
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x4102555d
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
lea ecx, [ebp - 0x28]
mov byte [ebp - 4], 1
call fcn.41010de0
lea eax, [ebx - 0x10]
or edx, 0xffffffff
lea ecx, [eax + 0xc]
mov byte [ebp - 4], 0
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x41025589
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov eax, dword [ebp + 8]
add eax, 0xfffffff0
or edx, 0xffffffff
lea ecx, [eax + 0xc]
mov dword [ebp - 4], edx
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x410255ab
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov eax, esi
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 0x14