Function at 0x1001cc6
Capabilities:
Create thread
Set socket configuration

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x118
mov eax, dword [0x1003074]
mov dword [ebp - 4], eax
mov eax, dword [ebp + 0xc]
push ebx
mov ebx, dword [ebp + 8]
mov dword [ebp - 0x110], eax
mov eax, dword [ebp + 0x10]
push esi
mov esi, dword [sym.imp.KERNEL32.dll_CreateEventA]
mov dword [ebp - 0x10c], eax
mov eax, dword [ebp + 0x14]
push edi
mov edi, dword [ebp + 0x20]
mov dword [ebp - 0x118], eax
xor eax, eax
push eax
push eax
push eax
push eax
mov dword [ebp - 0x108], 1
call esi
xor ecx, ecx
cmp eax, ecx
mov dword [0x1003098], eax
jne 0x1001d36
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push 0x3f3
call fcn.01001726
jmp 0x1001fb7
push ecx
push ecx
push 1
push ecx
call esi
test eax, eax
mov dword [0x1003090], eax
je 0x1001d20
push 0x100
lea eax, [ebp - 0x104]
push eax
mov dword [0x1003260], ebx
call fcn.0100217b
cmp eax, 0xffffffff
jne 0x1001d77
push 0x3e8
push 2
call fcn.01001fcc
pop ecx
pop ecx
push 2
jmp 0x1001fb9
mov eax, dword [edi]
xor ecx, ecx
mov esi, edi
jmp 0x1001d94
lea edx, [eax + 1]
mov bl, byte [eax]
inc eax
test bl, bl
jne 0x1001d82
sub eax, edx
add esi, 4
lea ecx, [ecx + eax + 1]
mov eax, dword [esi]
test eax, eax
jne 0x1001d7f
push ecx
call dword [sym.imp.msvcrt.dll_malloc]
mov ebx, eax
test ebx, ebx
pop ecx
mov dword [ebp - 0x114], ebx
jne 0x1001db6
push 0x3e9
jmp 0x1001fae
cmp dword [edi], 0
mov eax, edi
je 0x1001de4
mov edx, dword [eax]
mov esi, ebx
mov cl, byte [edx]
inc edx
mov byte [esi], cl
inc esi
test cl, cl
jne 0x1001dc1
jmp 0x1001dce
inc ebx
cmp byte [ebx], 0
jne 0x1001dcd
add eax, 4
cmp dword [eax], 0
je 0x1001de4
mov byte [ebx], 0x20
inc ebx
cmp dword [eax], 0
jne 0x1001dbd
push 0x1001204
push dword [ebp - 0x118]
call dword [sym.imp.WS2_32.dll_getservbyname]
test eax, eax
jne 0x1001e19
push dword [ebp - 0x118]
push dword [0x1003260]
push 0x3ea
push 2
call fcn.01001fcc
add esp, 0x10
jmp 0x1001d70
mov ecx, dword [ebp + 0x18]
sub ecx, 0
je 0x1001e6e
dec ecx
je 0x1001e48
push dword [0x1003260]
push 0x3eb
push 2
call fcn.01001fcc
mov ecx, dword [ebp - 4]
add esp, 0xc
pop edi
pop esi
pop ebx
call fcn.01002216
leave
ret 0x1c
movzx eax, word [eax + 8]
push 0x1003064
push dword [ebp - 0x114]
push 0
push dword [ebp - 0x10c]
push eax
lea eax, [ebp - 0x110]
push eax
call sub.MSWSOCK.dll_rexec
jmp 0x1001ea2
mov ecx, dword [ebp - 0x10c]
test ecx, ecx
jne 0x1001e7e
lea ecx, [ebp - 0x104]
movzx eax, word [eax + 8]
push 0x1003064
push dword [ebp - 0x114]
push ecx
lea ecx, [ebp - 0x104]
push ecx
push eax
lea eax, [ebp - 0x110]
push eax
call sub.MSWSOCK.dll_rcmd
cmp eax, 0xffffffff
mov dword [0x1003060], eax
jne 0x1001ec6
push dword [0x1003260]
push 0x3ec
push 2
call fcn.01001fcc
add esp, 0xc
jmp 0x1001fb7
cmp dword [0x1003064], 0xffffffff
jne 0x1001edc
push dword [0x1003260]
push 0x3ed
jmp 0x1001eb7
test byte [ebp + 0x1c], 1
mov ebx, dword [sym.imp.KERNEL32.dll_GetLastError]
mov esi, dword [sym.imp.WS2_32.dll_setsockopt]
mov edi, 0xffff
je 0x1001f3c
push 4
lea ecx, [ebp - 0x108]
push ecx
push 1
push edi
push eax
call esi
test eax, eax
jge 0x1001f15
call ebx
call ebx
push eax
push 0x10011e8
call sub.MSWSOCK.dll_s_perror
push 4
lea eax, [ebp - 0x108]
push eax
push 1
push edi
push dword [0x1003064]
call esi
test eax, eax
jge 0x1001f3c
call ebx
call ebx
push eax
push 0x10011c8
call sub.MSWSOCK.dll_s_perror
push 4
lea eax, [ebp - 0x108]
push eax
push 8
push edi
push dword [0x1003060]
call esi
test eax, eax
jge 0x1001f63
call ebx
call ebx
push eax
push 0x10011a4
call sub.MSWSOCK.dll_s_perror
push 4
lea eax, [ebp - 0x108]
push eax
push 8
push edi
push dword [0x1003064]
call esi
test eax, eax
jge 0x1001f8a
call ebx
call ebx
push eax
push 0x1001180
call sub.MSWSOCK.dll_s_perror
push 0x100325c
xor esi, esi
push esi
push esi
push 0x1001a03
push esi
push esi
call dword [sym.imp.KERNEL32.dll_CreateThread]
cmp eax, esi
mov dword [0x1003094], eax
jne 0x1001fbe
push 0x3ee
push 2
call fcn.01001fcc
pop ecx
pop ecx
push 1
call fcn.010015fd
push dword [ebp + 0x18]
call fcn.010017c6
int3