Function at 0x491e60
Capabilities:
Create tcp socket
Create udp socket
Set socket configuration

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x4b81b8
mov eax, dword fs:[0]
push eax
sub esp, 0x48
mov eax, dword [0x4d625c]
xor eax, ebp
mov dword [ebp - 0x10], eax
push ebx
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov dword [ebp - 0x44], ecx
call fcn.004b30c0
mov ebx, dword [sym.imp.WS2_32.dll_WSASetLastError]
push 0
call ebx
push 1
push 0
push 0
push 6
push 1
push 2
call dword [sym.imp.WS2_32.dll_WSASocketA]
mov esi, eax
call fcn.004b30c0
mov edi, eax
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
mov dword [ebp - 0x28], eax
mov dword [ebp - 0x24], edi
cmp esi, 0xffffffff
jne 0x491ecd
or esi, esi
jmp 0x491ede
xor edi, edi
call fcn.004b30c0
mov ecx, eax
mov eax, edi
mov dword [ebp - 0x28], eax
mov dword [ebp - 0x24], ecx
mov dword [ebp - 0x3c], esi
mov dword [ebp - 0x4c], esi
mov dword [ebp - 4], 0
cmp esi, 0xffffffff
jne 0x491f02
test eax, eax
je 0x491f02
push str.socket_select_interrupter
lea eax, [ebp - 0x28]
push eax
call fcn.0047edc0
mov dword [ebp - 0x38], 1
cmp esi, 0xffffffff
jne 0x491f1d
call fcn.004b30c0
mov ecx, 0x2719
mov dword [ebp - 0x28], ecx
jmp 0x491f5a
push 0
call ebx
push 4
lea ecx, [ebp - 0x38]
push ecx
push 4
push 0xffff
push esi
call dword [sym.imp.WS2_32.dll_setsockopt]
mov edi, eax
call fcn.004b30c0
mov dword [ebp - 0x2c], eax
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
mov edx, dword [ebp - 0x2c]
mov dword [ebp - 0x28], eax
mov dword [ebp - 0x24], edx
test edi, edi
jne 0x491f5d
call fcn.004b30c0
mov dword [ebp - 0x28], edi
mov dword [ebp - 0x24], eax
mov edi, dword [sym.imp.WS2_32.dll_inet_addr]
xor eax, eax
mov dword [ebp - 0x20], eax
mov dword [ebp - 0x1c], eax
mov dword [ebp - 0x18], eax
mov dword [ebp - 0x14], eax
mov eax, 2
push str.127.0.0.1
mov dword [ebp - 0x2c], 0x10
mov word [ebp - 0x20], ax
call edi
lea edx, [ebp - 0x28]
push edx
mov dword [ebp - 0x1c], eax
push 0x10
lea eax, [ebp - 0x20]
push eax
xor ecx, ecx
push esi
mov word [ebp - 0x1e], cx
call fcn.004905d0
add esp, 0x10
cmp eax, 0xffffffff
jne 0x491fbd
cmp dword [ebp - 0x28], 0
je 0x491fbd
push str.socket_select_interrupter
lea ecx, [ebp - 0x28]
push ecx
call fcn.0047edc0
lea edx, [ebp - 0x28]
push edx
lea eax, [ebp - 0x2c]
push eax
lea ecx, [ebp - 0x20]
push ecx
push esi
call fcn.004908b0
add esp, 0x10
cmp eax, 0xffffffff
jne 0x491feb
cmp dword [ebp - 0x28], 0
je 0x491feb
push str.socket_select_interrupter
lea edx, [ebp - 0x28]
push edx
call fcn.0047edc0
push str.127.0.0.1
call edi
mov dword [ebp - 0x1c], eax
lea eax, [ebp - 0x28]
push eax
push bind
push esi
call fcn.00490720
add esp, 0xc
cmp eax, 0xffffffff
jne 0x492020
cmp dword [ebp - 0x28], 0
je 0x492020
push str.socket_select_interrupter
lea ecx, [ebp - 0x28]
push ecx
call fcn.0047edc0
push 0
call ebx
push 1
push 0
push 0
push 6
push 1
push 2
call dword [sym.imp.WS2_32.dll_WSASocketA]
mov edi, eax
call fcn.004b30c0
mov esi, eax
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
mov ecx, eax
mov dword [ebp - 0x28], ecx
mov dword [ebp - 0x24], esi
cmp edi, 0xffffffff
jne 0x492057
mov dword [ebp - 0x34], edi
jmp 0x492069
xor esi, esi
call fcn.004b30c0
mov ecx, esi
mov dword [ebp - 0x28], ecx
mov dword [ebp - 0x24], eax
mov dword [ebp - 0x34], edi
mov eax, dword [ebp - 0x34]
mov dword [ebp - 0x54], eax
mov byte [ebp - 4], 1
cmp eax, 0xffffffff
jne 0x49208a
test ecx, ecx
je 0x49208a
push str.socket_select_interrupter
lea edx, [ebp - 0x28]
push edx
call fcn.0047edc0
mov edx, dword [ebp - 0x2c]
lea ecx, [ebp - 0x28]
push ecx
push edx
lea ecx, [ebp - 0x20]
push ecx
push eax
call fcn.004906b0
add esp, 0x10
cmp eax, 0xffffffff
jne 0x4920b8
cmp dword [ebp - 0x28], 0
je 0x4920b8
push str.socket_select_interrupter
lea edx, [ebp - 0x28]
push edx
call fcn.0047edc0
mov esi, dword [ebp - 0x3c]
cmp esi, 0xffffffff
jne 0x4920ce
call fcn.004b30c0
mov ecx, 0x2719
or esi, esi
jmp 0x49210d
push 0
call ebx
push 0
push 0
push esi
mov dword [ebp - 0x50], 0
call dword [sym.imp.WS2_32.dll_accept]
mov esi, eax
call fcn.004b30c0
mov edi, eax
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
mov ecx, eax
mov dword [ebp - 0x28], ecx
mov dword [ebp - 0x24], edi
cmp esi, 0xffffffff
jne 0x492104
or esi, esi
jmp 0x492113
xor edi, edi
call fcn.004b30c0
mov ecx, edi
mov dword [ebp - 0x24], eax
mov dword [ebp - 0x28], ecx
mov dword [ebp - 0x48], esi
mov byte [ebp - 4], 2
cmp esi, 0xffffffff
jne 0x492131
test ecx, ecx
je 0x492131
push str.socket_select_interrupter
lea eax, [ebp - 0x28]
push eax
call fcn.0047edc0
mov edi, dword [ebp - 0x34]
mov dword [ebp - 0x40], 1
cmp edi, 0xffffffff
jne 0x492152
call fcn.004b30c0
mov ecx, 0x2719
mov dword [ebp - 0x28], ecx
mov dword [ebp - 0x24], eax
jmp 0x492196
push 0
call ebx
lea ecx, [ebp - 0x40]
push ecx
push 0x8004667e
push edi
call dword [sym.imp.WS2_32.dll_ioctlsocket]
mov edi, eax
call fcn.004b30c0
mov dword [ebp - 0x2c], eax
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
mov edx, dword [ebp - 0x2c]
mov ecx, eax
mov dword [ebp - 0x28], ecx
mov dword [ebp - 0x24], edx
test edi, edi
js 0x492194
call fcn.004b30c0
xor ecx, ecx
mov dword [ebp - 0x28], ecx
mov dword [ebp - 0x24], eax
test edi, edi
je 0x4921a8
test ecx, ecx
je 0x4921a8
push str.socket_select_interrupter
lea eax, [ebp - 0x28]
push eax
call fcn.0047edc0
mov edi, dword [ebp - 0x34]
mov dword [ebp - 0x38], 1
cmp edi, 0xffffffff
je 0x4921dd
push 0
call ebx
push 4
lea ecx, [ebp - 0x38]
push ecx
push 1
push 6
push edi
call dword [sym.imp.WS2_32.dll_setsockopt]
mov edi, eax
call fcn.004b30c0
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
test edi, edi
jne 0x4921e2
call fcn.004b30c0
mov dword [ebp - 0x40], 1
cmp esi, 0xffffffff
jne 0x492200
call fcn.004b30c0
mov ecx, 0x2719
mov dword [ebp - 0x28], ecx
mov dword [ebp - 0x24], eax
jmp 0x492244
push 0
call ebx
lea edx, [ebp - 0x40]
push edx
push 0x8004667e
push esi
call dword [sym.imp.WS2_32.dll_ioctlsocket]
mov edi, eax
call fcn.004b30c0
mov dword [ebp - 0x2c], eax
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
mov ecx, eax
mov eax, dword [ebp - 0x2c]
mov dword [ebp - 0x28], ecx
mov dword [ebp - 0x24], eax
test edi, edi
js 0x492242
call fcn.004b30c0
xor ecx, ecx
mov dword [ebp - 0x28], ecx
mov dword [ebp - 0x24], eax
test edi, edi
je 0x492256
test ecx, ecx
je 0x492256
push str.socket_select_interrupter
lea ecx, [ebp - 0x28]
push ecx
call fcn.0047edc0
mov dword [ebp - 0x38], 1
cmp esi, 0xffffffff
je 0x492288
push 0
call ebx
push 4
lea edx, [ebp - 0x38]
push edx
push 1
push 6
push esi
call dword [sym.imp.WS2_32.dll_setsockopt]
mov ebx, eax
call fcn.004b30c0
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
test ebx, ebx
jne 0x49228d
call fcn.004b30c0
mov eax, dword [ebp - 0x44]
mov ecx, dword [ebp - 0x34]
mov dword [eax], esi
mov esi, dword [ebp - 0x3c]
mov dword [eax + 4], ecx
mov dword [ebp - 4], 0xffffffff
cmp esi, 0xffffffff
je 0x4922cd
mov dword [ebp - 0x28], 0
call fcn.004b30c0
lea edx, [ebp - 0x28]
push edx
mov dword [ebp - 0x24], eax
push 1
lea eax, [ebp - 0x2d]
push eax
push esi
mov byte [ebp - 0x2d], 0
call fcn.00481920
add esp, 0x10
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 0x10]
xor ecx, ebp
call fcn.0049d48e
mov esp, ebp
pop ebp
ret