Function at 0x406ff0
Capabilities:
Get hostname

Disassembly:
push 0xffffffffffffffff
push 0x42a6b2
mov eax, dword fs:[0]
push eax
sub esp, 0x4c
mov eax, dword [0x434568]
xor eax, esp
mov dword [esp + 0x48], eax
push ebx
push ebp
push esi
push edi
mov eax, dword [0x434568]
xor eax, esp
push eax
lea eax, [esp + 0x60]
mov dword fs:[0], eax
mov ebp, dword [esp + 0x70]
mov edi, dword [ebp + 4]
xor esi, esi
lea ebx, [ebp + 4]
mov dword [esp + 0x20], esi
mov dword [esp + 0x30], esi
mov dword [esp + 0x34], esi
mov dword [esp + 0x38], 8
cmp edi, esi
je 0x40705e
mov eax, dword [edi + 8]
cmp eax, esi
je 0x407052
cmp word [eax], si
jne 0x407083
mov eax, dword [edi + 4]
cmp eax, esi
je 0x40705e
cmp byte [eax], 0
jne 0x407065
mov eax, 0x42eae8
jmp 0x407088
cmp dword [edi + 8], esi
jne 0x40707b
mov eax, dword [edi + 0xc]
add eax, eax
push eax
call fcn.00416539
add esp, 4
mov dword [edi + 8], eax
mov ecx, dword [ebx]
push ecx
call fcn.00405180
mov edx, dword [ebx]
mov eax, dword [edx + 8]
lea ecx, [esp + 0x30]
push ecx
lea edx, [esp + 0x24]
push edx
push eax
call sub.WINSPOOL.DRV_OpenPrinterW
cmp eax, esi
je 0x4076c0
mov eax, dword [esp + 0x20]
cmp eax, esi
je 0x4076c0
lea ecx, [esp + 0x1c]
push ecx
push esi
push esi
push 2
push eax
mov dword [esp + 0x30], esi
call sub.WINSPOOL.DRV_GetPrinterW
test eax, eax
jne 0x4071ff
call dword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 0x7a
jne 0x4071ff
mov eax, dword [esp + 0x1c]
cmp eax, esi
je 0x4071ff
push eax
call fcn.00416539
mov edi, eax
add esp, 4
cmp edi, esi
je 0x4071ff
mov eax, dword [esp + 0x1c]
mov ecx, dword [esp + 0x20]
lea edx, [esp + 0x1c]
push edx
push eax
push edi
push 2
push ecx
call sub.WINSPOOL.DRV_GetPrinterW
test eax, eax
je 0x4071f6
call dword [sym.imp.KERNEL32.dll_GetTickCount]
mov dword [ebp + 0xa4], eax
mov edx, dword [edi + 4]
push edx
mov ecx, ebx
call fcn.004015a0
mov eax, dword [edi]
push eax
mov ecx, ebp
call fcn.004015a0
mov ecx, dword [edi + 8]
push ecx
lea ecx, [ebp + 8]
call fcn.004015a0
mov edx, dword [edi + 0xc]
push edx
lea ecx, [ebp + 0xc]
call fcn.004015a0
mov eax, dword [edi + 0x10]
push eax
lea ecx, [ebp + 0x10]
call fcn.004015a0
mov ecx, dword [edi + 0x14]
push ecx
lea ecx, [ebp + 0x14]
call fcn.004015a0
mov edx, dword [edi + 0x18]
push edx
lea ecx, [ebp + 0x18]
call fcn.004015a0
mov eax, dword [edi + 0x20]
push eax
lea ecx, [ebp + 0x20]
call fcn.004015a0
mov ecx, dword [edi + 0x24]
push ecx
lea ecx, [ebp + 0x24]
call fcn.004015a0
mov edx, dword [edi + 0x28]
push edx
lea ecx, [ebp + 0x28]
call fcn.004015a0
mov eax, dword [edi + 0x2c]
push eax
lea ecx, [ebp + 0x2c]
call fcn.004015a0
mov eax, dword [ebp + 0x1c]
mov ecx, dword [edi + 0x34]
mov dword [ebp + 0x30], ecx
cmp eax, esi
je 0x4071b7
push eax
call fcn.00416603
add esp, 4
mov dword [ebp + 0x1c], esi
mov byte [ebp + 0x98], 0
cmp dword [edi + 0x1c], esi
je 0x4071f6
mov eax, dword [edi + 0x1c]
movzx ebx, word [eax + 0x46]
movzx edx, word [eax + 0x44]
add ebx, edx
cmp ebx, esi
jle 0x4071f6
push ebx
push esi
call fcn.00416255
add esp, 8
mov dword [ebp + 0x1c], eax
cmp eax, esi
je 0x4071f6
mov ecx, dword [edi + 0x1c]
push ebx
push ecx
push eax
call fcn.00419320
add esp, 0xc
push edi
call fcn.00416603
add esp, 4
mov eax, dword [ebp]
cmp eax, esi
je 0x407226
mov ecx, dword [eax + 4]
cmp ecx, esi
je 0x407216
cmp byte [ecx], 0
jne 0x4072e8
mov eax, dword [eax + 8]
cmp eax, esi
je 0x407226
cmp word [eax], si
jne 0x4072e8
lea ebx, [ebp + 0xc]
push esi
mov ecx, 0x42efb8
mov edx, ebx
call fcn.00402330
test eax, eax
jne 0x4072b7
push 2
mov ecx, 0x42ef7c
mov edx, ebx
call fcn.00402330
sub eax, 2
push eax
push 2
lea edx, [esp + 0x1c]
push edx
push ebx
call fcn.00402620
mov dword [esp + 0x68], esi
push eax
mov ecx, ebp
call fcn.00401410
mov dword [esp + 0x68], 0xffffffff
lea ecx, [esp + 0x14]
call fcn.00401220
push 2
mov ecx, 0x42ef7c
mov edx, ebx
call fcn.00402330
mov edi, eax
lea eax, [esp + 0x14]
inc edi
push eax
mov ecx, ebx
call fcn.00402850
mov dword [esp + 0x68], 1
push eax
lea ecx, [ebp + 8]
call fcn.00401410
mov dword [esp + 0x68], 0xffffffff
lea ecx, [esp + 0x14]
call fcn.00401220
jmp 0x4072f1
lea ecx, [esp + 0x14]
push ecx
lea edx, [esp + 0x40]
push edx
mov dword [esp + 0x1c], 0x10
call dword [sym.imp.KERNEL32.dll_GetComputerNameW]
cmp eax, esi
je 0x4072df
lea eax, [esp + 0x3c]
push eax
mov ecx, ebp
call fcn.004015a0
mov byte [ebp + 0x8c], 0
jmp 0x4072f8
mov ebx, ebp
call fcn.004077d0
xor esi, esi
mov byte [ebp + 0x8c], 1
lea ebx, [ebp + 4]
push 2
mov ecx, 0x42ef7c
mov edx, ebx
call fcn.00402330
cmp eax, esi
jle 0x407345
lea ecx, [esp + 0x14]
push ecx
lea edi, [eax + 1]
mov ecx, ebx
call fcn.00402850
mov dword [esp + 0x68], 2
lea edi, [ebp + 0x9c]
push eax
mov ecx, edi
call fcn.00401410
mov dword [esp + 0x68], 0xffffffff
lea ecx, [esp + 0x14]
call fcn.00401220
jmp 0x407353
lea edi, [ebp + 0x9c]
push ebx
mov ecx, edi
call fcn.00401410
cmp byte [ebp + 0x8c], 0
jne 0x4073b1
mov edx, dword [esp + 0x20]
push edx
lea esi, [esp + 0x28]
call fcn.00408350
mov dword [esp + 0x68], 3
or esi, 0xffffffff
cmp dword [esp + 0x24], esi
je 0x4073a1
lea eax, [esp + 0x2c]
push eax
mov ecx, ebp
call fcn.00401410
lea ecx, [esp + 0x28]
push ecx
mov ecx, edi
call fcn.00401410
mov byte [ebp + 0x8c], 1
mov byte [ebp + 0x98], 1
mov dword [esp + 0x68], esi
lea edx, [esp + 0x24]
push edx
call fcn.004076f0
xor esi, esi
cmp byte [ebp + 0xa0], 0
jne 0x4076b6
mov ecx, dword [esp + 0x20]
lea eax, [esp + 0x1c]
push eax
push esi
push esi
push 6
push esi
push ecx
mov dword [esp + 0x34], esi
call sub.WINSPOOL.DRV_GetPrinterDriverW
test eax, eax
jne 0x4076b6
call dword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 0x7a
jne 0x4076b6
mov eax, dword [esp + 0x1c]
cmp eax, esi
je 0x4076b6
push eax
call fcn.00416539
mov esi, eax
add esp, 4
test esi, esi
je 0x4076b6
mov eax, dword [esp + 0x1c]
mov ecx, dword [esp + 0x20]
lea edx, [esp + 0x1c]
push edx
push eax
push esi
push 6
push 0
push ecx
call sub.WINSPOOL.DRV_GetPrinterDriverW
test eax, eax
je 0x4076ad
mov edx, dword [esi]
mov dword [ebp + 0x34], edx
mov eax, dword [esi + 8]
push eax
lea ecx, [ebp + 0x38]
call fcn.004015a0
mov ecx, dword [esi + 0xc]
push ecx
lea ecx, [esp + 0x18]
call fcn.004010b0
mov ebx, 4
mov dword [esp + 0x68], ebx
lea edx, [esp + 0x18]
push edx
lea edi, [esp + 0x18]
call fcn.00405730
add esp, 4
mov byte [esp + 0x68], 5
push eax
lea ecx, [ebp + 0x3c]
call fcn.00401410
mov byte [esp + 0x68], bl
lea ecx, [esp + 0x18]
call fcn.00401220
mov dword [esp + 0x68], 0xffffffff
mov ecx, edi
call fcn.00401220
mov eax, dword [esi + 0xc]
push eax
lea ecx, [esp + 0x18]
call fcn.004010b0
mov dword [esp + 0x68], 6
lea ecx, [esp + 0x18]
push ecx
lea ebx, [esp + 0x18]
call fcn.004057a0
add esp, 4
mov byte [esp + 0x68], 7
push eax
lea ecx, [ebp + 0x40]
call fcn.00401410
mov byte [esp + 0x68], 6
lea ecx, [esp + 0x18]
call fcn.00401220
or edi, 0xffffffff
mov dword [esp + 0x68], edi
mov ecx, ebx
call fcn.00401220
mov edx, dword [esi + 0x10]
push edx
lea ecx, [esp + 0x18]
call fcn.004010b0
mov dword [esp + 0x68], 8
lea eax, [esp + 0x18]
push eax
lea ebx, [esp + 0x18]
call fcn.004057a0
add esp, 4
mov byte [esp + 0x68], 9
push eax
lea ecx, [ebp + 0x44]
call fcn.00401410
mov byte [esp + 0x68], 8
lea ecx, [esp + 0x18]
call fcn.00401220
mov dword [esp + 0x68], edi
mov ecx, ebx
call fcn.00401220
mov ecx, dword [esi + 0x14]
push ecx
lea ecx, [esp + 0x18]
call fcn.004010b0
mov dword [esp + 0x68], 0xa
lea edx, [esp + 0x18]
push edx
lea ebx, [esp + 0x18]
call fcn.004057a0
add esp, 4
mov byte [esp + 0x68], 0xb
push eax
lea ecx, [ebp + 0x48]
call fcn.00401410
mov byte [esp + 0x68], 0xa
lea ecx, [esp + 0x18]
call fcn.00401220
mov dword [esp + 0x68], edi
mov ecx, ebx
call fcn.00401220
mov eax, dword [esi + 0x18]
push eax
lea ecx, [esp + 0x18]
call fcn.004010b0
mov dword [esp + 0x68], 0xc
lea ecx, [esp + 0x18]
push ecx
lea ebx, [esp + 0x18]
call fcn.004057a0
add esp, 4
mov byte [esp + 0x68], 0xd
push eax
lea ecx, [ebp + 0x4c]
call fcn.00401410
mov byte [esp + 0x68], 0xc
lea ecx, [esp + 0x18]
call fcn.00401220
mov dword [esp + 0x68], edi
mov ecx, ebx
call fcn.00401220
mov edx, dword [esi + 0x20]
push edx
lea ecx, [ebp + 0x64]
call fcn.004015a0
mov eax, dword [esi + 0x24]
push eax
lea ecx, [ebp + 0x68]
call fcn.004015a0
mov ecx, dword [esi + 0x2c]
mov dword [ebp + 0x6c], ecx
mov edx, dword [esi + 0x30]
mov dword [ebp + 0x70], edx
mov eax, dword [esi + 0x38]
mov dword [ebp + 0x78], eax
mov ecx, dword [esi + 0x3c]
mov dword [ebp + 0x7c], ecx
mov edx, dword [esi + 0x40]
push edx
lea ecx, [ebp + 0x80]
call fcn.004015a0
mov eax, dword [esi + 0x48]
push eax
lea ecx, [ebp + 0x84]
call fcn.004015a0
mov ecx, dword [esi + 0x4c]
push ecx
lea ecx, [ebp + 0x88]
call fcn.004015a0
lea ecx, [ebp + 0x50]
call fcn.00403e10
mov edi, dword [esi + 0x1c]
test edi, edi
je 0x4076ad
cmp word [edi], 0
je 0x4076ad
jmp 0x407640
push edi
lea ecx, [esp + 0x18]
call fcn.004010b0
mov dword [esp + 0x68], 0xe
lea edx, [esp + 0x18]
push edx
lea ebx, [esp + 0x18]
call fcn.004057a0
add esp, 4
mov byte [esp + 0x68], 0xf
push eax
lea ecx, [ebp + 0x50]
call fcn.00403ac0
mov byte [esp + 0x68], 0xe
lea ecx, [esp + 0x18]
call fcn.00401220
mov dword [esp + 0x68], 0xffffffff
mov ecx, ebx
call fcn.00401220
mov eax, edi
lea edx, [eax + 2]
mov cx, word [eax]
add eax, 2
test cx, cx
jne 0x407693
sub eax, edx
sar eax, 1
cmp word [edi + eax*2 + 2], cx
lea edi, [edi + eax*2 + 2]
jne 0x407640
push esi
call fcn.00416603
add esp, 4
mov eax, dword [esp + 0x20]
push eax
call sub.WINSPOOL.DRV_ClosePrinter
mov ebx, ebp
call fcn.00406a40
mov byte [ebp + 0xa0], 1
mov ecx, dword [esp + 0x60]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebp
pop ebx
mov ecx, dword [esp + 0x48]
xor ecx, esp
call fcn.004158f6
add esp, 0x58
ret 4