Function at 0x100022a0
Capabilities:
Receive data
Receive data on socket
Set socket configuration

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x2c
push ebx
push esi
mov esi, ecx
push edi
mov dword [ebp - 0x10], esi
cmp dword [esi], 0xffffffff
je 0x100025c4
mov ebx, dword [ebp + 0xc]
test ebx, ebx
je 0x100025c4
call fcn.10002070
cmp byte [ebp + 8], 0
je 0x100023a7
lea eax, [esi + 8]
push eax
call dword [sym.imp.KERNEL32.DLL_EnterCriticalSection]
mov eax, dword [esi + 0x2c]
mov ecx, 1
dec dword [esi + 4]
mov dword [ebp + 8], ecx
mov dword [ebp - 8], eax
mov edi, dword [eax]
mov edx, dword [edi]
inc edx
cmp edx, ecx
jle 0x10002382
mov eax, dword [edi + 4]
mov edi, dword [ebx + 0x1c]
nop
cmp dword [eax], edi
je 0x10002311
inc ecx
add eax, 4
mov dword [ebp + 8], ecx
cmp ecx, edx
jl 0x10002300
jmp 0x10002382
mov eax, dword [ebp - 8]
mov eax, dword [eax]
mov ebx, dword [eax]
mov esi, dword [eax + 4]
mov dword [ebp - 0xc], esi
lea eax, [ebx*4 - 4]
push eax
push 0x40
call dword [sym.imp.KERNEL32.DLL_LocalAlloc]
mov ecx, dword [ebp + 8]
mov edi, eax
lea ecx, [ecx*4 - 4]
push ecx
push esi
mov esi, dword [sym.imp.MSVCRT.dll_memmove]
push edi
call esi
mov ecx, dword [ebp + 8]
add esp, 0xc
mov eax, ebx
sub eax, ecx
shl eax, 2
push eax
mov eax, dword [ebp - 0xc]
lea eax, [eax + ecx*4]
dec ecx
push eax
lea eax, [edi + ecx*4]
push eax
call esi
mov edx, dword [ebp - 8]
lea ecx, [ebx - 1]
add esp, 0xc
mov eax, dword [edx]
push dword [ebp - 0xc]
mov dword [eax], ecx
mov eax, dword [edx]
mov dword [eax + 4], edi
call dword [sym.imp.KERNEL32.DLL_LocalFree]
mov ebx, dword [ebp + 0xc]
mov esi, dword [ebp - 0x10]
lea eax, [esi + 8]
push eax
call dword [sym.imp.KERNEL32.DLL_LeaveCriticalSection]
push dword [esi + 0x28]
push dword [esi + 4]
push 0
push 0
push 3
push dword [ebx + 0x1c]
push esi
call dword [0x10005028]
jmp 0x100025a7
push 4
push esi
push 0x700b
push 0xffff
push dword [ebx + 0x1c]
call dword [sym.imp.WS2_32.dll_setsockopt]
push 0
push 0
lea eax, [ebp - 4]
mov dword [ebp - 4], 0
push eax
push 0
push 0
push 0xc
lea eax, [ebp - 0x2c]
mov dword [ebp - 0x2c], 1
push eax
push 0x98000004
push dword [ebx + 0x1c]
mov dword [ebp - 0x28], 0x7530
mov dword [ebp - 0x24], 0x1388
call dword [sym.imp.WS2_32.dll_WSAIoctl]
lea edi, [esi + 8]
push edi
mov dword [ebp - 0x18], edi
call dword [sym.imp.KERNEL32.DLL_EnterCriticalSection]
inc dword [esi + 4]
push edi
call dword [sym.imp.KERNEL32.DLL_LeaveCriticalSection]
push dword [esi + 0x28]
push dword [esi + 4]
push 0
push 0
push 1
push dword [ebx + 0x1c]
push esi
call dword [0x10005028]
mov dword [ebx + 0x18], 2
cmp dword [esi + 0x20], 0
je 0x10002469
push dword [ebx + 0x20]
call fcn.10003abc
add esp, 4
mov dword [ebx + 0x30], 0
push 4
call fcn.10003acf
mov dword [ebx + 0x20], eax
add esp, 4
add eax, dword [ebx + 0x30]
mov dword [ebp - 0x1c], eax
mov eax, 4
sub eax, dword [ebx + 0x30]
mov dword [ebx + 0x2c], 4
jmp 0x10002474
mov eax, dword [ebx + 0x20]
mov dword [ebp - 0x1c], eax
mov eax, dword [0x10005010]
push 0
push ebx
mov dword [ebp - 0x20], eax
lea eax, [ebp - 0x14]
push eax
lea eax, [ebp - 4]
mov dword [ebp - 0x14], 0
push eax
push 1
lea eax, [ebp - 0x20]
mov dword [ebp - 4], 0
push eax
push dword [ebx + 0x1c]
call dword [sym.imp.WS2_32.dll_WSARecv]
test eax, eax
je 0x100025c4
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
cmp eax, 0x271e
je 0x100025c4
cmp eax, 0x3e5
je 0x100025c4
push edi
call dword [sym.imp.KERNEL32.DLL_EnterCriticalSection]
mov eax, dword [esi + 0x2c]
mov ecx, 1
dec dword [esi + 4]
mov dword [ebp - 8], eax
mov dword [ebp + 8], ecx
mov eax, dword [eax]
mov edx, dword [eax]
inc edx
cmp edx, ecx
jle 0x1000257b
mov edi, dword [ebp - 8]
mov eax, dword [edi]
mov edi, dword [ebx + 0x1c]
mov eax, dword [eax + 4]
cmp dword [eax], edi
je 0x10002507
inc ecx
add eax, 4
mov dword [ebp + 8], ecx
cmp ecx, edx
jl 0x100024f3
lea edi, [esi + 8]
jmp 0x1000257b
mov eax, dword [ebp - 8]
mov eax, dword [eax]
mov ebx, dword [eax]
mov esi, dword [eax + 4]
mov dword [ebp - 0xc], esi
lea eax, [ebx*4 - 4]
push eax
push 0x40
call dword [sym.imp.KERNEL32.DLL_LocalAlloc]
mov ecx, dword [ebp + 8]
mov edi, eax
lea ecx, [ecx*4 - 4]
push ecx
push esi
mov esi, dword [sym.imp.MSVCRT.dll_memmove]
push edi
call esi
mov ecx, dword [ebp + 8]
add esp, 0xc
mov eax, ebx
sub eax, ecx
shl eax, 2
push eax
mov eax, dword [ebp - 0xc]
lea eax, [eax + ecx*4]
dec ecx
push eax
lea eax, [edi + ecx*4]
push eax
call esi
mov edx, dword [ebp - 8]
lea ecx, [ebx - 1]
add esp, 0xc
mov eax, dword [edx]
push dword [ebp - 0xc]
mov dword [eax], ecx
mov eax, dword [edx]
mov dword [eax + 4], edi
call dword [sym.imp.KERNEL32.DLL_LocalFree]
mov ebx, dword [ebp + 0xc]
mov esi, dword [ebp - 0x10]
mov edi, dword [ebp - 0x18]
push edi
call dword [sym.imp.KERNEL32.DLL_LeaveCriticalSection]
push dword [esi + 0x28]
push dword [esi + 4]
push 0
push 0
push 3
push dword [ebx + 0x1c]
push esi
call dword [0x10005028]
mov ecx, dword [ebx + 0x1c]
call fcn.10001a60
mov dword [ebx + 0x1c], 0xffffffff
push dword [ebx + 0x20]
call fcn.10003abc
add esp, 4
mov dword [ebx + 0x20], 0
push 0x34
push ebx
call fcn.10003ac1
add esp, 8
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 8