Function at 0x40ef70
Capabilities:
Access peb ldr_data

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff8
push 0xffffffffffffffff
push 0x4482d2
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
push ecx
mov eax, 0x8038
call fcn.0042dd50
push ebx
push ebp
push esi
xor esi, esi
push edi
mov dword [esp + 0x20], esi
mov dword [esp + 0x24], esi
mov dword [esp + 0x2c], esi
call fcn.0043cb83
mov edx, dword [eax]
mov ecx, eax
call dword [edx + 0xc]
add eax, 0x10
mov dword [esp + 0x14], eax
mov dword [esp + 0x8054], esi
call fcn.0043cb83
mov edx, dword [eax]
mov ecx, eax
call dword [edx + 0xc]
add eax, 0x10
mov dword [esp + 0x1c], eax
lea ecx, [esp + 0x34]
mov byte [esp + 0x8054], 1
call fcn.0043be4f
mov ebx, 2
mov byte [esp + 0x8054], bl
call fcn.0044608e
mov esi, dword [eax + 4]
lea eax, [esi + 0xa4]
push eax
lea ecx, [esp + 0x18]
call fcn.00401e30
add esi, 0xa8
push esi
lea ecx, [esp + 0x20]
call fcn.00401e30
push 0x44b628
lea ecx, [esp + 0x18]
push ecx
lea edx, [esp + 0x30]
push edx
call fcn.00401d70
lea ecx, [esp + 0x28]
push ecx
push eax
lea edx, [esp + 0x2c]
push edx
mov byte [esp + 0x806c], 3
call fcn.0040c1f0
add esp, 0x18
push eax
lea ecx, [esp + 0x18]
mov byte [esp + 0x8058], 4
call fcn.00401e30
mov eax, dword [esp + 0x18]
add eax, 0xfffffff0
mov byte [esp + 0x8054], 3
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x40f081
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
call dword [edx + 4]
mov eax, dword [esp + 0x28]
add eax, 0xfffffff0
mov byte [esp + 0x8054], bl
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x40f0a6
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
call dword [edx + 4]
mov ebp, dword [esp + 0x14]
xor eax, eax
mov ecx, 0x2000
lea edi, [esp + 0x48]
rep stosd dword es:[edi], eax
mov ecx, dword [ebp - 0xc]
mov eax, ecx
shr ecx, 2
mov esi, ebp
lea edi, [esp + 0x48]
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
and ecx, 3
rep movsb byte es:[edi], byte [esi]
lea ecx, [esp + 0x48]
push 0x44b628
push ecx
call fcn.0042e8d8
add esp, 8
test eax, eax
je 0x40f13d
push eax
lea ecx, [esp + 0x2c]
call fcn.00402470
mov edx, dword [esp + 0x3c]
push eax
push edx
lea ecx, [esp + 0x3c]
mov byte [esp + 0x805c], 5
call fcn.0043c0dd
mov eax, dword [esp + 0x28]
add eax, 0xfffffff0
mov byte [esp + 0x8054], bl
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x40f12a
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
call dword [edx + 4]
push 0x44b628
push 0
call fcn.0042e8d8
add esp, 8
test eax, eax
jne 0x40f0e4
lea eax, [esp + 0x24]
push eax
lea ecx, [esp + 0x24]
push ecx
push 0
push 0
push ebx
push 0
push 6
call sub.WINSPOOL.DRV_EnumPrintersA
test eax, eax
jne 0x40f1d8
call dword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 0x7a
je 0x40f1d8
lea ecx, [esp + 0x34]
mov byte [esp + 0x8054], 1
call fcn.0043bea1
mov eax, dword [esp + 0x1c]
add eax, 0xfffffff0
mov byte [esp + 0x8054], 0
lea edx, [eax + 0xc]
or ecx, 0xffffffff
lock xadd dword [edx], ecx
dec ecx
test ecx, ecx
jg 0x40f19b
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
call dword [edx + 4]
lea eax, [ebp - 0x10]
mov dword [esp + 0x8054], 0xffffffff
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x40f1c0
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
call dword [edx + 4]
xor eax, eax
mov ecx, dword [esp + 0x804c]
mov dword fs:[0], ecx
pop edi
pop esi
pop ebp
pop ebx
mov esp, ebp
pop ebp
ret
mov eax, dword [esp + 0x20]
push eax
push 0x40
call dword [sym.imp.KERNEL32.dll_GlobalAlloc]
mov esi, eax
test esi, esi
mov dword [esp + 0x30], esi
je 0x40f312
mov eax, dword [esp + 0x20]
lea ecx, [esp + 0x24]
push ecx
lea edx, [esp + 0x24]
push edx
push eax
push esi
push ebx
push 0
push 6
call sub.WINSPOOL.DRV_EnumPrintersA
cmp eax, 1
jne 0x40f307
mov eax, dword [esp + 0x24]
test eax, eax
mov dword [esp + 0x18], 0
jbe 0x40f307
mov eax, dword [esp + 0x3c]
lea ebx, [esi + 0x10]
xor ebp, ebp
test eax, eax
jle 0x40f2eb
jmp 0x40f240
test ebp, ebp
jl 0x40f3af
cmp ebp, eax
jge 0x40f3af
mov ecx, dword [esp + 0x38]
mov esi, dword [ecx + ebp*4]
mov ecx, dword [esi - 0x10]
mov edx, dword [ecx]
sub esi, 0x10
call dword [edx + 0x10]
mov edx, dword [esi + 0xc]
test edx, edx
lea ecx, [esi + 0xc]
jl 0x40f27d
cmp eax, dword [esi]
jne 0x40f27d
mov eax, esi
mov edx, 1
lock xadd dword [ecx], edx
jmp 0x40f2af
mov ecx, dword [esi + 4]
mov edx, dword [eax]
push 1
push ecx
mov ecx, eax
call dword [edx]
test eax, eax
je 0x40f3aa
mov edx, dword [esi + 4]
mov dword [eax + 4], edx
mov ecx, dword [esi + 4]
inc ecx
mov edx, ecx
shr ecx, 2
add esi, 0x10
lea edi, [eax + 0x10]
rep movsd dword es:[edi], dword [esi]
mov ecx, edx
and ecx, 3
rep movsb byte es:[edi], byte [esi]
lea esi, [eax + 0x10]
mov eax, dword [ebx]
push esi
push eax
call dword [sym.imp.KERNEL32.dll_lstrcmpiA]
or edx, 0xffffffff
test eax, eax
lea eax, [esi - 0x10]
lea ecx, [eax + 0xc]
je 0x40f388
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x40f2de
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
call dword [edx + 4]
mov eax, dword [esp + 0x3c]
inc ebp
cmp ebp, eax
jl 0x40f240
mov ecx, dword [esp + 0x18]
mov edx, dword [esp + 0x24]
inc ecx
add ebx, 0x54
cmp ecx, edx
mov dword [esp + 0x18], ecx
jb 0x40f231
mov ebp, dword [esp + 0x14]
mov eax, dword [esp + 0x30]
push eax
call dword [sym.imp.KERNEL32.dll_GlobalFree]
lea ecx, [esp + 0x34]
mov byte [esp + 0x8054], 1
call fcn.0043bea1
mov eax, dword [esp + 0x1c]
add eax, 0xfffffff0
mov byte [esp + 0x8054], 0
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x40f349
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
call dword [edx + 4]
lea eax, [ebp - 0x10]
mov dword [esp + 0x8054], 0xffffffff
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x40f36e
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
call dword [edx + 4]
mov ecx, dword [esp + 0x804c]
mov eax, dword [esp + 0x2c]
pop edi
mov dword fs:[0], ecx
pop esi
pop ebp
pop ebx
mov esp, ebp
pop ebp
ret
mov dword [esp + 0x2c], 1
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x40f303
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
call dword [edx + 4]
jmp 0x40f303
jmp fcn.00401260
jmp fcn.0043b946