Function at 0x10002641
Capabilities:
Act as tcp client
Check for time delay via gettickcount
Connect socket
Connect tcp socket
Connect udp socket
Create tcp socket
Create udp socket
Receive data
Receive data on socket
Set socket configuration

Disassembly:
push ebx
mov ebx, esp
push ecx
push ecx
and esp, 0xfffffff8
add esp, 4
push ebp
mov ebp, dword [ebx + 4]
mov dword [esp + 4], ebp
mov ebp, esp
sub esp, 0x960
mov eax, dword [0x10025014]
xor eax, ebp
mov dword [ebp - 4], eax
push esi
push edi
push 0
push 1
push 2
pop eax
push eax
call dword [sym.imp.WS2_32.dll_socket]
mov esi, eax
or edi, 0xffffffff
mov dword [ebp - 0x954], esi
cmp esi, edi
je 0x10002bcb
push 2
pop eax
mov word [ebp - 0x950], ax
xorps xmm0, xmm0
mov eax, dword [0x10021aa4]
movlpd qword [ebp - 0x948], xmm0
mov dword [ebp - 0x94c], 0x971aefca
movzx eax, word [eax]
push eax
call dword [sym.imp.WS2_32.dll_htons]
mov word [ebp - 0x94e], ax
mov eax, dword [0x10029654]
inc eax
mov dword [0x10029654], eax
cmp eax, 2
jne 0x10002742
push 0x104
lea eax, [ebp - 0x110]
push 0
push eax
call fcn.1000a7f0
add esp, 0xc
lea ecx, [ebp - 0x110]
mov edx, 0x104
push dword [0x10021b58]
call fcn.100010e3
lea edx, [ebp - 0x110]
lea ecx, [edx + 1]
mov al, byte [edx]
inc edx
test al, al
jne 0x10002703
sub edx, ecx
lea ecx, [ebp - 0x110]
call fcn.1000773e
lea ecx, [ebp - 0x110]
call fcn.10007a28
test eax, eax
je 0x10002742
mov dword [ebp - 0x94c], eax
mov eax, dword [0x10021aa4]
movzx eax, word [eax]
push eax
call dword [sym.imp.WS2_32.dll_htons]
mov word [ebp - 0x94e], ax
cmp dword [0x10029654], 0xf
jne 0x100027bf
push 0x104
lea eax, [ebp - 0x110]
push 0
push eax
call fcn.1000a7f0
add esp, 0xc
lea ecx, [ebp - 0x110]
mov edx, 0x104
push dword [0x10021a80]
call fcn.100010e3
lea edx, [ebp - 0x110]
lea ecx, [edx + 1]
mov al, byte [edx]
inc edx
test al, al
jne 0x10002780
sub edx, ecx
lea ecx, [ebp - 0x110]
call fcn.1000773e
lea ecx, [ebp - 0x110]
call fcn.10007a28
test eax, eax
je 0x100027bf
mov dword [ebp - 0x94c], eax
mov eax, dword [0x10021aa4]
movzx eax, word [eax]
push eax
call dword [sym.imp.WS2_32.dll_htons]
mov word [ebp - 0x94e], ax
cmp dword [0x10029654], 0x1e
jne 0x1000283c
push 0x104
lea eax, [ebp - 0x110]
push 0
push eax
call fcn.1000a7f0
add esp, 0xc
lea ecx, [ebp - 0x110]
mov edx, 0x104
push dword [0x10021b58]
call fcn.100010e3
lea edx, [ebp - 0x110]
lea ecx, [edx + 1]
mov al, byte [edx]
inc edx
test al, al
jne 0x100027fd
sub edx, ecx
lea ecx, [ebp - 0x110]
call fcn.1000773e
lea ecx, [ebp - 0x110]
call fcn.10007a28
test eax, eax
je 0x1000283c
mov dword [ebp - 0x94c], eax
mov eax, dword [0x10021aa4]
movzx eax, word [eax]
push eax
call dword [sym.imp.WS2_32.dll_htons]
mov word [ebp - 0x94e], ax
cmp dword [0x10029654], 0x96
jbe 0x10002a0c
and dword [0x10029654], 0
lea eax, [ebp - 0x218]
push 0x104
push 0
push eax
call fcn.1000a7f0
add esp, 0xc
lea eax, [ebp - 0x638]
push 0x104
push 0
push eax
call fcn.1000a7f0
add esp, 0xc
lea eax, [ebp - 0x740]
push 0x104
push 0
push eax
call fcn.1000a7f0
add esp, 0xc
lea eax, [ebp - 0x320]
push 0x104
push 0
push eax
call fcn.1000a7f0
add esp, 0xc
lea eax, [ebp - 0x428]
push 0x104
push 0
push eax
call fcn.1000a7f0
add esp, 0xc
lea eax, [ebp - 0x428]
push 0xa
push 0x104
push eax
mov eax, dword [0x10021aa4]
movzx eax, word [eax]
push eax
call fcn.1000e219
push 0xa
push 0x104
lea eax, [ebp - 0x320]
push eax
push 0x971aefca
call fcn.1000e219
push 0x104
lea eax, [ebp - 0x110]
push 0
push eax
call fcn.1000a7f0
add esp, 0x2c
lea ecx, [ebp - 0x110]
mov edx, 0x104
push dword [0x10021ac0]
call fcn.100010e3
lea edx, [ebp - 0x110]
lea ecx, [edx + 1]
mov al, byte [edx]
inc edx
test al, al
jne 0x1000292a
sub edx, ecx
lea ecx, [ebp - 0x110]
call fcn.1000773e
push 0x104
lea eax, [ebp - 0x530]
push 0
push eax
call fcn.1000a7f0
add esp, 0xc
lea eax, [ebp - 0x110]
push eax
lea eax, [ebp - 0x320]
push eax
lea eax, [ebp - 0x428]
push eax
push str._s_s_s
lea eax, [ebp - 0x530]
push 0x104
push eax
call fcn.10001176
add esp, 0x18
lea edx, [ebp - 0x218]
lea ecx, [ebp - 0x530]
call fcn.10005817
test eax, eax
je 0x10002a0c
push 5
lea eax, [ebp - 0x218]
mov esi, 0x104
push eax
push ecx
mov edx, esi
lea ecx, [ebp - 0x740]
call fcn.100011d3
lea eax, [ebp - 0x213]
mov edx, esi
push eax
lea ecx, [ebp - 0x638]
call fcn.100010e3
push 0xa
lea eax, [ebp - 0x638]
push 0
push eax
call fcn.1000cd0b
add esp, 0xc
mov esi, eax
lea eax, [ebp - 0x740]
push 0xa
push 0
push eax
call fcn.1000cce1
add esp, 0xc
movzx ecx, ax
mov dword [ebp - 0x94c], esi
push ecx
call dword [sym.imp.WS2_32.dll_htons]
mov esi, dword [ebp - 0x954]
mov word [ebp - 0x94e], ax
push 0x10
lea eax, [ebp - 0x950]
push eax
push esi
call dword [sym.imp.WS2_32.dll_connect]
cmp eax, edi
jne 0x10002a2c
and dword [0x10028528], 0
jmp 0x10002bc4
lea eax, [ebp - 0x95c]
xor edi, edi
push eax
push 0x8004667e
inc edi
push esi
mov dword [ebp - 0x95c], edi
call dword [sym.imp.WS2_32.dll_ioctlsocket]
mov edx, edi
mov ecx, esi
call fcn.10003941
call dword [sym.imp.KERNEL32.dll_GetTickCount]
push 0x200
push 0
lea edi, [eax + 0x55f0]
lea eax, [ebp - 0x940]
push eax
call fcn.1000a7f0
add esp, 0xc
jmp 0x10002bb5
push 0x200
lea eax, [ebp - 0x940]
push 0
push eax
call fcn.1000a7f0
add esp, 0xc
push 1
push dword [0x10028518]
call dword [sym.imp.KERNEL32.dll_WaitForSingleObject]
test eax, eax
je 0x10002bc2
push 0
push 0x200
lea eax, [ebp - 0x940]
push eax
push esi
call dword [sym.imp.WS2_32.dll_recv]
mov dword [ebp - 0x958], eax
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
cmp eax, 0x274c
je 0x10002bc2
mov edx, dword [ebp - 0x958]
test edx, edx
jle 0x10002b81
lea eax, [ebp - 0x940]
mov dword [ebp - 0x960], eax
mov eax, dword [0x100259c0]
add eax, edx
cmp dword [0x100259bc], eax
jge 0x10002b35
mov eax, 0x2000
push eax
push 0
push 0x100259c4
mov dword [0x100259bc], eax
call fcn.1000a7f0
add esp, 0xc
xor eax, eax
mov dword [0x100259b4], eax
mov dword [0x100259b8], eax
mov dword [0x100259c0], eax
push dword [0x100259bc]
push eax
push 0x100259c4
jmp 0x10002a6b
mov esi, dword [ebp - 0x960]
mov ecx, edx
mov edx, dword [0x100259b8]
mov al, byte [esi]
inc esi
mov byte [edx + 0x100259c4], al
mov eax, dword [0x100259b8]
inc eax
cdq
idiv dword [0x100259bc]
mov dword [0x100259b8], edx
sub ecx, 1
jne 0x10002b43
mov esi, dword [ebp - 0x954]
mov ecx, esi
mov eax, dword [ebp - 0x958]
add dword [0x100259c0], eax
call fcn.10002be0
test eax, eax
js 0x10002bc2
call dword [sym.imp.KERNEL32.dll_GetTickCount]
cmp edi, eax
jae 0x10002ba5
call dword [sym.imp.KERNEL32.dll_GetTickCount]
push 3
pop edx
mov ecx, esi
lea edi, [eax + 0x55f0]
call fcn.10003941
test eax, eax
js 0x10002bc2
call dword [sym.imp.KERNEL32.dll_SwitchToThread]
push 0
push 1
call dword [sym.imp.KERNEL32.dll_SleepEx]
cmp dword [0x1002851c], 0
jne 0x10002a78
xor edi, edi
mov ecx, esi
call fcn.1000130a
mov ecx, dword [ebp - 4]
mov eax, edi
pop edi
xor ecx, ebp
pop esi
call fcn.10008f85
mov esp, ebp
pop ebp
mov esp, ebx
pop ebx
ret