Function at 0x40efe0
Capabilities:
Act as tcp client
Connect socket
Connect tcp socket
Create tcp socket
Create thread
Initialize winsock library
Set socket configuration

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x54
mov eax, dword [0x4294ec]
xor eax, ebp
mov dword [ebp - 4], eax
push ebx
push esi
mov esi, dword [ebp + 8]
push edi
push str.CConnectionWifi::Open__
call fcn.00416aa0
add esp, 4
mov ecx, esi
call fcn.004067a0
cmp eax, 4
je 0x40f3e8
cmp eax, 8
je 0x40f3e8
push 4
mov ecx, esi
call fcn.00408800
lea eax, [esi + 0x218]
push eax
push 0x202
call dword [sym.imp.WS2_32.dll_WSAStartup]
mov dword [esi + 0x3b8], eax
test eax, eax
je 0x40f05f
push eax
push str.WSAStartup_failed_with_error__d_n
call fcn.00416aa0
add esp, 8
call dword [sym.imp.WS2_32.dll_WSACleanup]
mov eax, 1
jmp 0x40f3ea
mov eax, dword [esi + 0x130]
sub eax, 0x10
mov ecx, 2
push eax
mov word [esi + 0x3a8], cx
call fcn.004027b0
add esp, 4
push 0x41caf8
add eax, 0x10
push str._WIFIVID_SAMSUNGPID_SAMSUNGMI_01
lea ecx, [ebp - 0x20]
mov dword [ebp - 0x20], eax
call fcn.00408180
mov edx, dword [0x429700]
mov eax, dword [edx + 0xc]
mov ecx, 0x429700
mov dword [ebp - 0x34], 0
call eax
lea ecx, [ebp - 0x34]
push ecx
push 0x41d950
lea edx, [ebp - 0x28]
add eax, 0x10
push edx
lea ecx, [ebp - 0x20]
mov dword [ebp - 0x1c], eax
call fcn.0040eeb0
push eax
lea ecx, [ebp - 0x1c]
call fcn.00405670
mov eax, dword [ebp - 0x28]
add eax, 0xfffffff0
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x40f0ef
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov ebx, dword [ebp - 0x1c]
cmp dword [ebx - 4], 1
jle 0x40f107
mov ecx, dword [ebx - 0xc]
push ecx
lea ecx, [ebp - 0x1c]
call fcn.00402890
mov ebx, dword [ebp - 0x1c]
test ebx, ebx
jne 0x40f10f
xor eax, eax
jmp 0x40f138
push ebx
call dword [sym.imp.KERNEL32.dll_lstrlenW]
inc eax
cmp eax, 0x3fffffff
jle 0x40f122
xor eax, eax
jmp 0x40f138
lea edi, [eax + eax]
mov eax, edi
call fcn.00417730
mov eax, esp
push 3
push edi
push ebx
push eax
call fcn.0040e0f0
lea edx, [ebp - 0x18]
jmp 0x40f140
mov cl, byte [eax]
mov byte [edx], cl
inc eax
inc edx
test cl, cl
jne 0x40f140
lea edx, [ebp - 0x34]
push edx
push 0x41d950
lea eax, [ebp - 0x28]
push eax
lea ecx, [ebp - 0x20]
call fcn.0040eeb0
push eax
lea ecx, [ebp - 0x1c]
call fcn.00405670
mov eax, dword [ebp - 0x28]
add eax, 0xfffffff0
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x40f187
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov eax, dword [ebp - 0x1c]
cmp dword [eax - 4], 1
jle 0x40f19f
mov ecx, dword [eax - 0xc]
push ecx
lea ecx, [ebp - 0x1c]
call fcn.00402890
mov eax, dword [ebp - 0x1c]
push eax
call dword [sym.imp.MSVCR90.dll__wtoi]
add esp, 4
lea edx, [ebp - 0x18]
push edx
mov edi, eax
call dword [sym.imp.WS2_32.dll_inet_addr]
push edi
mov dword [esi + 0x3ac], eax
call dword [sym.imp.WS2_32.dll_htons]
push 6
mov ebx, 1
push ebx
push 2
mov word [esi + 0x3aa], ax
call dword [sym.imp.WS2_32.dll_socket]
mov dword [esi + 0x214], eax
cmp eax, 0xffffffff
jne 0x40f21b
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
push eax
push str.socket_create_failed:_error__d
call fcn.00416aa0
add esp, 8
push 0x100
mov ecx, esi
call fcn.00408800
lea ecx, [ebp - 0x1c]
call fcn.00403030
lea ecx, [ebp - 0x20]
call fcn.00403030
mov eax, ebx
jmp 0x40f3ea
push 0x10
lea ecx, [esi + 0x3a8]
push ecx
push eax
call dword [sym.imp.WS2_32.dll_connect]
mov dword [esi + 0x3b8], eax
cmp eax, 0xffffffff
jne 0x40f287
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
push eax
push str.connect_failed:_error__d
call fcn.00416aa0
mov eax, dword [esi + 0x214]
add esp, 8
push eax
call dword [sym.imp.WS2_32.dll_closesocket]
push 0x100
mov ecx, esi
mov dword [esi + 0x214], 0xffffffff
call fcn.00408800
lea ecx, [ebp - 0x1c]
call fcn.00403030
lea ecx, [ebp - 0x20]
call fcn.00403030
mov eax, 0x4c9
jmp 0x40f3ea
mov eax, dword [esi + 0x214]
mov edi, dword [sym.imp.WS2_32.dll_getsockopt]
lea ecx, [ebp - 0x24]
push ecx
lea edx, [ebp - 0x30]
push edx
push 0x1001
push 0xffff
push eax
mov dword [ebp - 0x24], 4
call edi
mov eax, dword [esi + 0x214]
lea ecx, [ebp - 0x24]
push ecx
lea edx, [ebp - 0x2c]
push edx
push 0x1002
push 0xffff
push eax
call edi
mov ecx, dword [ebp - 0x24]
mov edi, dword [sym.imp.WS2_32.dll_setsockopt]
push ecx
lea edx, [ebp - 0x30]
push edx
mov eax, 0x10000
push 0x1001
mov dword [ebp - 0x30], eax
mov dword [ebp - 0x2c], eax
mov eax, dword [esi + 0x214]
push 0xffff
push eax
call edi
mov ecx, dword [ebp - 0x24]
mov eax, dword [esi + 0x214]
push ecx
lea edx, [ebp - 0x2c]
push edx
push 0x1002
push 0xffff
push eax
call edi
push 0
push 0
lea ecx, [ebp - 0x48]
push ecx
mov ecx, dword [esi + 0x214]
push 0xc
lea edx, [ebp - 0x54]
push edx
push 0xc
lea eax, [ebp - 0x40]
push eax
push 0x98000004
push ecx
mov dword [ebp - 0x40], ebx
mov dword [ebp - 0x3c], 0x2710
mov dword [ebp - 0x38], 0x7d0
call dword [sym.imp.WS2_32.dll_WSAIoctl]
test eax, eax
je 0x40f360
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
push eax
push str.setsockopt_:_KeepAlive_is_failed_:__d
call fcn.00416aa0
add esp, 8
call dword [sym.imp.WS2_32.dll_WSACreateEvent]
mov edx, dword [esi + 0x214]
push 0x20
push eax
push edx
mov dword [esi + 0x3dc], eax
call dword [sym.imp.WS2_32.dll_WSAEventSelect]
lea eax, [ebp - 0x44]
push eax
push 0
push esi
push 0x40e1a0
push 0
push 0
call dword [sym.imp.KERNEL32.dll_CreateThread]
mov edi, dword [sym.imp.KERNEL32.dll_CreateEventW]
push 0
push 0
push ebx
push 0
mov dword [esi + 0x3d0], eax
call edi
push 0
push 0
push ebx
push 0
mov dword [esi + 0x3e8], eax
call edi
push 8
mov ecx, esi
mov dword [esi + 0x3ec], eax
call fcn.00408800
add dword [esi + 0x1f0], ebx
push str.CConnectionWifi::Open___
call fcn.00416aa0
add esp, 4
lea ecx, [ebp - 0x1c]
call fcn.00403030
lea ecx, [ebp - 0x20]
call fcn.00403030
xor eax, eax
lea esp, [ebp - 0x60]
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.0041759c
mov esp, ebp
pop ebp
ret 4