Function at 0x471d30
Capabilities:
Create thread

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x44
push esi
push 0x4cc408
push 0
call fcn.004718a0
add esp, 8
call fcn.00473800
and eax, 0x500
jne 0x471d59
xor eax, eax
jmp 0x472185
cmp dword [ebp + 0x14], 0
je 0x471d73
mov eax, dword [ebp + 0x14]
push eax
call fcn.00489c70
add esp, 4
add eax, 0x14
mov dword [ebp - 0x40], eax
jmp 0x471d7a
mov dword [ebp - 0x40], 0x400
mov ecx, dword [ebp - 0x40]
mov dword [ebp - 0x14], ecx
mov edx, dword [ebp - 0x14]
push edx
call fcn.0048a9a4
add esp, 4
mov dword [ebp - 0x20], eax
mov eax, dword [ebp - 0x14]
push eax
call fcn.0048a9a4
add esp, 4
mov dword [ebp - 0x18], eax
cmp dword [ebp + 0x14], 0
je 0x471dac
mov ecx, dword [ebp + 0x14]
mov dword [ebp - 0x44], ecx
jmp 0x471db3
mov dword [ebp - 0x44], str.print
mov edx, dword [ebp - 0x44]
push edx
mov eax, dword [ebp - 0x20]
push eax
call fcn.00489ae0
add esp, 8
mov ecx, dword [ebp - 0x20]
push ecx
mov edx, dword [ebp + 0xc]
push edx
push str._s:_s
mov eax, dword [ebp - 0x18]
push eax
call fcn.00489bd8
add esp, 0x10
lea ecx, [ebp - 0x2c]
push ecx
call fcn.004609e0
add esp, 4
mov dword [ebp - 0xc], eax
cmp dword [ebp - 0xc], 0
je 0x471e8a
mov dword [ebp - 8], 0
jmp 0x471e07
mov edx, dword [ebp - 8]
add edx, 1
mov dword [ebp - 8], edx
mov eax, dword [ebp - 8]
cmp eax, dword [ebp - 0xc]
jge 0x471e30
mov ecx, dword [ebp - 8]
shl ecx, 4
mov edx, dword [ebp - 0x2c]
mov eax, dword [edx + ecx]
push eax
mov ecx, dword [ebp - 0x18]
push ecx
call fcn.00468510
add esp, 8
test eax, eax
jne 0x471e2e
jmp 0x471e30
jmp 0x471dfe
mov edx, dword [ebp - 0x2c]
push edx
call fcn.00460db0
add esp, 4
mov eax, dword [ebp - 8]
cmp eax, dword [ebp - 0xc]
jge 0x471e8a
mov ecx, dword [ebp - 0x18]
push ecx
push str.LTaddPort_P2PNT4___existing_port:_return_it___s__n
push 0
call fcn.004718a0
add esp, 0xc
mov edx, dword [ebp - 0x18]
push edx
push 0x53f450
call fcn.00489ae0
add esp, 8
mov eax, dword [ebp - 0x20]
push eax
call fcn.00488f35
add esp, 4
mov ecx, dword [ebp - 0x18]
push ecx
call fcn.00488f35
add esp, 4
mov eax, 0x53f450
jmp 0x472185
mov dword [ebp - 0x34], 0
mov dword [ebp - 0x1c], 0
lea edx, [ebp - 0x34]
push edx
call fcn.004609e0
add esp, 4
mov dword [ebp - 0x28], eax
mov eax, dword [ebp - 0x28]
push eax
push 0x4cc468
push 0
call fcn.004718a0
add esp, 0xc
mov ecx, dword [ebp + 0xc]
push ecx
mov edx, dword [ebp + 8]
push edx
push 0x4cc490
push 0
call fcn.004718a0
add esp, 0x10
mov eax, dword [ebp + 0xc]
push eax
call fcn.00489c70
add esp, 4
mov esi, eax
mov ecx, dword [ebp - 0x20]
push ecx
call fcn.00489c70
add esp, 4
lea edx, [esi + eax + 0xa]
push edx
call fcn.0048a9a4
add esp, 4
mov dword [ebp - 4], eax
push 4
lea eax, [ebp + 8]
push eax
mov ecx, dword [ebp - 4]
push ecx
call fcn.00489120
add esp, 0xc
mov edx, dword [ebp + 0xc]
push edx
mov eax, dword [ebp - 4]
add eax, 4
push eax
call fcn.00489ae0
add esp, 8
mov ecx, dword [ebp - 0x20]
push ecx
mov edx, dword [ebp + 0xc]
push edx
call fcn.00489c70
add esp, 4
mov ecx, dword [ebp - 4]
lea edx, [ecx + eax + 5]
push edx
call fcn.00489ae0
add esp, 8
push 4
lea eax, [ebp + 0x10]
push eax
mov ecx, dword [ebp + 0xc]
push ecx
call fcn.00489c70
add esp, 4
mov edx, dword [ebp - 4]
lea esi, [edx + eax + 4]
mov eax, dword [ebp - 0x20]
push eax
call fcn.00489c70
add esp, 4
lea ecx, [esi + eax + 2]
push ecx
call fcn.00489120
add esp, 0xc
push str.LTaddPort_P2PNT4___start_threadCheckAddLPRPortUI_n
push 0
call fcn.004718a0
add esp, 8
lea edx, [ebp - 0x10]
push edx
push 0
mov eax, dword [ebp - 4]
push eax
push 0x472190
push 0
push 0
call dword [sym.imp.KERNEL32.dll_CreateThread]
mov dword [ebp - 0x24], eax
push str.LPR_Port
mov ecx, dword [ebp + 8]
push ecx
push 0
call sub.WINSPOOL.DRV_AddPortA
test eax, eax
jne 0x471fee
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov dword [ebp - 0x3c], eax
cmp dword [ebp - 0x3c], 0x70a
jne 0x471fd8
mov edx, dword [ebp - 0x3c]
push edx
push 0x4cc4fc
push 0
call fcn.004718a0
add esp, 0xc
jmp 0x471fee
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push 0x4cc538
push 0
call fcn.004718a0
add esp, 0xc
mov eax, dword [ebp - 0x24]
push eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
lea ecx, [ebp - 0x1c]
push ecx
call fcn.004609e0
add esp, 4
mov dword [ebp - 0x38], eax
mov edx, dword [ebp - 0x38]
push edx
push 0x4cc564
push 0
call fcn.004718a0
add esp, 0xc
mov dword [ebp - 8], 0
jmp 0x47202c
mov eax, dword [ebp - 8]
add eax, 1
mov dword [ebp - 8], eax
mov ecx, dword [ebp - 8]
cmp ecx, dword [ebp - 0x38]
jge 0x47212b
mov dword [ebp - 0x30], 0
jmp 0x47204a
mov edx, dword [ebp - 0x30]
add edx, 1
mov dword [ebp - 0x30], edx
mov eax, dword [ebp - 0x30]
cmp eax, dword [ebp - 0x28]
jge 0x4720a5
mov ecx, dword [ebp - 0x30]
shl ecx, 4
mov edx, dword [ebp - 0x34]
mov eax, dword [edx + ecx]
push eax
mov ecx, dword [ebp - 8]
shl ecx, 4
mov edx, dword [ebp - 0x1c]
mov eax, dword [edx + ecx]
push eax
push 0x4cc58c
push 0
call fcn.004718a0
add esp, 0x10
mov ecx, dword [ebp - 8]
shl ecx, 4
mov edx, dword [ebp - 0x1c]
mov eax, dword [edx + ecx]
push eax
mov ecx, dword [ebp - 0x30]
shl ecx, 4
mov edx, dword [ebp - 0x34]
mov eax, dword [edx + ecx]
push eax
call fcn.0048a3e0
add esp, 8
test eax, eax
jne 0x4720a3
jmp 0x4720a5
jmp 0x472041
mov ecx, dword [ebp - 0x30]
cmp ecx, dword [ebp - 0x28]
jne 0x472126
mov edx, dword [ebp - 8]
shl edx, 4
mov eax, dword [ebp - 0x1c]
mov ecx, dword [eax + edx]
push ecx
push 0x4cc5b8
push 0
call fcn.004718a0
add esp, 0xc
mov edx, dword [ebp - 8]
shl edx, 4
mov eax, dword [ebp - 0x1c]
mov ecx, dword [eax + edx]
push ecx
push 0x53f388
call fcn.00489ae0
add esp, 8
mov edx, dword [ebp - 0x34]
push edx
call fcn.00460db0
add esp, 4
mov eax, dword [ebp - 0x1c]
push eax
call fcn.00460db0
add esp, 4
mov ecx, dword [ebp - 0x20]
push ecx
call fcn.00488f35
add esp, 4
mov edx, dword [ebp - 0x18]
push edx
call fcn.00488f35
add esp, 4
mov eax, dword [ebp - 4]
push eax
call fcn.00488f35
add esp, 4
mov eax, 0x53f388
jmp 0x472185
jmp 0x472023
mov ecx, dword [ebp - 0x34]
push ecx
call fcn.00460db0
add esp, 4
mov edx, dword [ebp - 0x1c]
push edx
call fcn.00460db0
add esp, 4
mov eax, dword [ebp - 0x20]
push eax
call fcn.00488f35
add esp, 4
mov ecx, dword [ebp - 0x18]
push ecx
call fcn.00488f35
add esp, 4
mov edx, dword [ebp - 4]
push edx
call fcn.00488f35
add esp, 4
mov eax, dword [ebp - 8]
shl eax, 4
mov ecx, dword [ebp - 0x1c]
mov edx, dword [ecx + eax]
push edx
push 0x4cc5e0
push 0
call fcn.004718a0
add esp, 0xc
xor eax, eax
pop esi
mov esp, ebp
pop ebp
ret