Function at 0x40efb0
Capabilities:
Get socket status
Receive data
Receive data on socket
Send data
Send data on socket

Disassembly:
push ebp
mov ebp, esp
mov eax, 0x14a8
call fcn.00463a90
mov eax, dword [0x4b9430]
xor eax, ebp
mov dword [ebp - 4], eax
mov eax, dword [esi + 0x13c]
push ebx
mov ebx, dword [esi + 0x134]
push edi
cmp ebx, eax
jb 0x40f001
mov eax, dword [esi + 0xd8]
test eax, 0x1000
je 0x40f224
test eax, 0x40000
jne 0x40f224
mov eax, dword [esi + 0x90]
push eax
jmp 0x40f215
sub eax, ebx
mov edi, eax
mov eax, dword [esi + 0x84]
mov dword [ebp - 0x149c], eax
je 0x40f043
push ebx
push edi
push eax
push str.to_socket__d:__N
push 0x10
call fcn.004090c0
mov ecx, dword [ebp - 0x149c]
add esp, 0x14
push 0
push edi
push ebx
push ecx
call dword [sym.imp.WS2_32.dll_send]
xor edx, edx
cmp eax, edi
setne dl
mov eax, edx
test eax, eax
jne 0x40efd9
mov eax, dword [esi + 0x84]
mov ecx, dword [esi + 0x90]
cmp eax, ecx
ja 0x40f055
mov eax, ecx
inc eax
mov dword [ebp - 0x149c], eax
mov edx, dword [esi + 0x90]
mov ecx, dword [esi + 0x84]
mov eax, dword [esi]
mov dword [ebp - 0x1490], edx
lea edx, [ebp - 0x14a4]
push edx
push 0
mov dword [ebp - 0x1494], ecx
mov dword [ebp - 0x1498], 2
mov ecx, dword [eax + 0x74]
push 0
lea eax, [ebp - 0x1498]
mov dword [ebp - 0x14a4], ecx
mov ecx, dword [ebp - 0x149c]
push eax
push ecx
mov dword [ebp - 0x14a0], 0
call dword [sym.imp.WS2_32.dll_select]
test eax, eax
je 0x40f1fa
mov eax, dword [esi + 0x84]
lea edx, [ebp - 0x1498]
push edx
push eax
call dword [sym.imp.WS2_32.dll___WSAFDIsSet]
test eax, eax
je 0x40f15a
mov ebx, dword [esi + 0x84]
push 0
push 0x1387
lea ecx, [ebp - 0x1390]
push ecx
push ebx
call dword [sym.imp.WS2_32.dll_recv]
mov edi, eax
test edi, edi
jle 0x40f1fa
lea edx, [ebp - 0x1390]
push edx
push edi
push ebx
push str.from_socket__d:__N
push 0x8000
call fcn.004090c0
mov ebx, dword [esi + 0x90]
add esp, 0x14
test edi, edi
je 0x40f15a
lea eax, [ebp - 0x1390]
push eax
push edi
push ebx
push str.to_socket__d:__N
push 0x10
call fcn.004090c0
add esp, 0x14
push 0
push edi
lea ecx, [ebp - 0x1390]
push ecx
push ebx
call dword [sym.imp.WS2_32.dll_send]
xor edx, edx
cmp eax, edi
setne dl
mov eax, edx
test eax, eax
jne 0x40f1fa
mov ecx, dword [esi + 0x90]
lea eax, [ebp - 0x1498]
push eax
push ecx
call dword [sym.imp.WS2_32.dll___WSAFDIsSet]
test eax, eax
je 0x40f05c
mov ebx, dword [esi + 0x90]
push 0
push 0x1387
lea edx, [ebp - 0x1390]
push edx
push ebx
call dword [sym.imp.WS2_32.dll_recv]
mov edi, eax
test edi, edi
jle 0x40f1fa
lea eax, [ebp - 0x1390]
push eax
push edi
push ebx
push str.from_socket__d:__N
push 0x8000
call fcn.004090c0
mov ebx, dword [esi + 0x84]
add esp, 0x14
test edi, edi
je 0x40f05c
lea ecx, [ebp - 0x1390]
push ecx
push edi
push ebx
push str.to_socket__d:__N
push 0x10
call fcn.004090c0
add esp, 0x14
push 0
push edi
lea edx, [ebp - 0x1390]
push edx
push ebx
call dword [sym.imp.WS2_32.dll_send]
xor ecx, ecx
cmp eax, edi
setne cl
mov eax, ecx
test eax, eax
je 0x40f05c
mov eax, dword [esi + 0xd8]
test eax, 0x1000
je 0x40f224
test eax, 0x40000
jne 0x40f224
mov edx, dword [esi + 0x90]
push edx
push str.Marking_the_server_socket__d_tainted.
push 2
call fcn.004090c0
add esp, 0xc
mov ecx, dword [ebp - 4]
or dword [esi + 0xd8], 0x40000
pop edi
xor ecx, ebp
pop ebx
call fcn.0045d3b4
mov esp, ebp
pop ebp
ret