Function at 0x41e7ec
Capabilities:
Act as tcp client
Connect socket
Connect tcp socket
Connect udp socket
Create tcp socket
Create udp socket
Send data
Send data on socket

Disassembly:
sub esp, 0x20
push ebx
push ebp
push esi
push edi
xor eax, eax
lea edi, [esp + 0x15]
stosd dword es:[edi], eax
mov esi, dword [sym.imp.WS2_32.dll_WSAGetLastError]
stosd dword es:[edi], eax
mov eax, dword [esp + 0x34]
mov edi, dword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 0x14
mov dword [esp + 0x14], eax
mov dword [esp + 0x18], 8
je 0x41e8b0
cmp dword [0x441ff4], 0
je 0x41e8b0
mov eax, dword [0x441fd4]
mov eax, dword [eax]
cmp eax, 3
je 0x41e849
mov ecx, dword [0x441fdc]
cmp dword [ecx], 0
jne 0x41e8b0
cmp eax, 3
jle 0x41e8b0
call esi
mov ebp, eax
call edi
cmp dword [0x43cd48], 0
mov ebx, eax
jge 0x41e864
mov eax, dword [0x441fa0]
mov dword [0x43cd48], eax
call fcn.0041c4b1
test eax, eax
je 0x41e8a2
push 3
push dword [0x43cd48]
push 0x62b
push str.C:_build_rel_sp_8_4_6_2_srcwindowsSHAREDutilitycabutil.cpp
call fcn.0041c4e1
push dword [esp + 0x4c]
push dword [esp + 0x2c]
push dword [esp + 0x2c]
push str.SendCmdEx:Sending_command:_d___d_bytes_.bWaitReturnValue_d_n
call fcn.0041c506
add esp, 0x20
call fcn.0041c4cc
push ebp
call dword [sym.imp.WS2_32.dll_WSASetLastError]
push ebx
call dword [sym.imp.KERNEL32.dll_SetLastError]
mov eax, dword [esp + 0x38]
sub eax, 0
je 0x41e8ea
dec eax
je 0x41e8de
dec eax
je 0x41e8d2
dec eax
jne 0x41e9b6
mov ecx, 0x442408
call fcn.00420585
jmp 0x41e8f4
mov ecx, 0x442408
call fcn.0042078d
jmp 0x41e8f4
mov ecx, 0x442408
call fcn.00420770
jmp 0x41e8f4
mov ecx, 0x442408
call fcn.00420753
push 2
pop ebx
push str.127.0.0.1
mov word [esp + 0x24], bx
movzx ebp, ax
call dword [sym.imp.WS2_32.dll_inet_addr]
push ebp
mov dword [esp + 0x28], eax
call dword [sym.imp.WS2_32.dll_htons]
push 0
push 1
push ebx
mov word [esp + 0x2e], ax
call dword [sym.imp.WS2_32.dll_socket]
cmp eax, 0xffffffff
mov dword [esp + 0x10], eax
jne 0x41e9bd
xor ebx, ebx
cmp dword [0x441ff4], ebx
je 0x41e9b6
mov eax, dword [0x441fd4]
mov eax, dword [eax]
cmp eax, 1
je 0x41e957
mov ecx, dword [0x441fdc]
cmp dword [ecx], ebx
jne 0x41e9b6
cmp eax, 1
jle 0x41e9b6
call esi
mov ebp, eax
call edi
cmp dword [0x43cd48], ebx
mov edi, eax
jge 0x41e971
mov eax, dword [0x441fa0]
mov dword [0x43cd48], eax
call fcn.0041c4b1
test eax, eax
je 0x41e9a8
push 1
push dword [0x43cd48]
push 0x64c
push str.C:_build_rel_sp_8_4_6_2_srcwindowsSHAREDutilitycabutil.cpp
call fcn.0041c4e1
add esp, 0x10
call esi
push eax
push str.SendCmdEx:Failed_to_create_socket__err_d_n
call fcn.0041c506
pop ecx
pop ecx
call fcn.0041c4cc
push ebp
call dword [sym.imp.WS2_32.dll_WSASetLastError]
push edi
call dword [sym.imp.KERNEL32.dll_SetLastError]
xor eax, eax
jmp 0x41edc5
lea eax, [esp + 0x20]
push 0x10
push eax
push dword [esp + 0x18]
call dword [sym.imp.WS2_32.dll_connect]
cmp eax, 0xffffffff
jne 0x41ea6b
cmp dword [0x441ff4], 0
je 0x41ea64
mov eax, dword [0x441fd4]
mov eax, dword [eax]
cmp eax, ebx
je 0x41e9fe
mov ecx, dword [0x441fdc]
cmp dword [ecx], 0
jne 0x41ea64
cmp eax, ebx
jle 0x41ea64
call esi
mov ebx, eax
call edi
cmp dword [0x43cd48], 0
mov edi, eax
jge 0x41ea19
mov eax, dword [0x441fa0]
mov dword [0x43cd48], eax
call fcn.0041c4b1
test eax, eax
je 0x41ea56
push 2
push dword [0x43cd48]
push 0x653
push str.C:_build_rel_sp_8_4_6_2_srcwindowsSHAREDutilitycabutil.cpp
call fcn.0041c4e1
add esp, 0x10
push ebp
call esi
push eax
push dword [esp + 0x3c]
push str.SendCmdEx:Failed_to_connect__command:0X_X_err_d_server_port_is:0X_X._n
call fcn.0041c506
add esp, 0x10
call fcn.0041c4cc
push ebx
call dword [sym.imp.WS2_32.dll_WSASetLastError]
push edi
call dword [sym.imp.KERNEL32.dll_SetLastError]
xor esi, esi
jmp 0x41edb9
xor ebx, ebx
lea eax, [esp + 0x14]
push ebx
push dword [esp + 0x1c]
push eax
push dword [esp + 0x1c]
call dword [sym.imp.WS2_32.dll_send]
mov ebp, eax
cmp ebp, dword [esp + 0x18]
je 0x41eb1d
cmp dword [0x441ff4], ebx
je 0x41ea64
mov eax, dword [0x441fd4]
mov eax, dword [eax]
cmp eax, 1
je 0x41eab0
mov ecx, dword [0x441fdc]
cmp dword [ecx], ebx
jne 0x41ea64
cmp eax, 1
jle 0x41ea64
call esi
mov ebx, eax
call edi
cmp dword [0x43cd48], 0
mov edi, eax
jge 0x41eacb
mov eax, dword [0x441fa0]
mov dword [0x43cd48], eax
call fcn.0041c4b1
test eax, eax
je 0x41eb08
push 1
push dword [0x43cd48]
push 0x65b
push str.C:_build_rel_sp_8_4_6_2_srcwindowsSHAREDutilitycabutil.cpp
call fcn.0041c4e1
add esp, 0x10
call esi
push eax
push dword [esp + 0x1c]
push ebp
push str.:_SendCmdEx__failed_to_send__sent_d_of__d__err_d_n
call fcn.0041c506
add esp, 0x10
call fcn.0041c4cc
push ebx
call dword [sym.imp.WS2_32.dll_WSASetLastError]
push edi
call dword [sym.imp.KERNEL32.dll_SetLastError]
xor ebx, ebx
jmp 0x41ea64
cmp dword [esp + 0x3c], ebx
mov dword [esp + 0x38], 1
je 0x41edb5
cmp dword [esp + 0x40], ebx
je 0x41ec90
cmp dword [esp + 0x44], ebx
je 0x41ec90
push dword [esp + 0x48]
push ebx
push dword [esp + 0x4c]
push dword [esp + 0x4c]
push dword [esp + 0x20]
call fcn.0041fa92
mov ebp, eax
add esp, 0x14
cmp ebp, 0xffffffff
jne 0x41ec01
cmp dword [0x441ff4], ebx
je 0x41ebf8
mov eax, dword [0x441fd4]
mov eax, dword [eax]
cmp eax, 1
je 0x41eb8e
mov ecx, dword [0x441fdc]
cmp dword [ecx], ebx
jne 0x41ebf8
cmp eax, 1
jle 0x41ebf8
call esi
mov ebp, eax
call edi
cmp dword [0x43cd48], ebx
mov edi, eax
jge 0x41eba8
mov eax, dword [0x441fa0]
mov dword [0x43cd48], eax
call fcn.0041c4b1
test eax, eax
je 0x41ebea
push 1
push dword [0x43cd48]
push 0x680
push str.C:_build_rel_sp_8_4_6_2_srcwindowsSHAREDutilitycabutil.cpp
call fcn.0041c4e1
add esp, 0x10
call esi
push eax
push dword [esp + 0x1c]
push 0xffffffffffffffff
push dword [esp + 0x40]
push str.SendCmdEx:failed_to_recieve._command:_d__sent_d_of__d__err_d_n
call fcn.0041c506
add esp, 0x14
call fcn.0041c4cc
push ebp
call dword [sym.imp.WS2_32.dll_WSASetLastError]
push edi
call dword [sym.imp.KERNEL32.dll_SetLastError]
mov dword [esp + 0x38], ebx
jmp 0x41edb5
cmp dword [0x441ff4], ebx
je 0x41ec83
mov eax, dword [0x441fd4]
mov eax, dword [eax]
cmp eax, 4
je 0x41ec24
mov ecx, dword [0x441fdc]
cmp dword [ecx], ebx
jne 0x41ec83
cmp eax, 4
jle 0x41ec83
call esi
mov esi, eax
call edi
cmp dword [0x43cd48], ebx
mov edi, eax
jge 0x41ec3e
mov eax, dword [0x441fa0]
mov dword [0x43cd48], eax
call fcn.0041c4b1
test eax, eax
je 0x41ec75
push 4
push dword [0x43cd48]
push 0x685
push str.C:_build_rel_sp_8_4_6_2_srcwindowsSHAREDutilitycabutil.cpp
call fcn.0041c4e1
push ebp
push dword [esp + 0x48]
push str.SendCmdEx:command:_d___d_bytes_recv_n
call fcn.0041c506
add esp, 0x1c
call fcn.0041c4cc
push esi
call dword [sym.imp.WS2_32.dll_WSASetLastError]
push edi
call dword [sym.imp.KERNEL32.dll_SetLastError]
mov dword [esp + 0x38], 1
jmp 0x41edb5
push dword [esp + 0x48]
and byte [esp + 0x40], 0
lea eax, [esp + 0x40]
push ebx
push 1
push eax
push dword [esp + 0x20]
call fcn.0041fa92
mov ebp, eax
add esp, 0x14
cmp ebp, 0xffffffff
jne 0x41ed1c
cmp dword [0x441ff4], ebx
je 0x41ebf8
mov eax, dword [0x441fd4]
mov eax, dword [eax]
cmp eax, 1
je 0x41ece3
mov ecx, dword [0x441fdc]
cmp dword [ecx], ebx
jne 0x41ebf8
cmp eax, 1
jle 0x41ebf8
call esi
mov ebp, eax
call edi
cmp dword [0x43cd48], ebx
mov edi, eax
jge 0x41ecfd
mov eax, dword [0x441fa0]
mov dword [0x43cd48], eax
call fcn.0041c4b1
test eax, eax
je 0x41ebea
push 1
push dword [0x43cd48]
push 0x66b
jmp 0x41ebbe
xor eax, eax
cmp byte [esp + 0x3c], al
setne al
cmp dword [0x441ff4], ebx
mov dword [esp + 0x38], eax
je 0x41edb5
mov eax, dword [0x441fd4]
mov eax, dword [eax]
cmp eax, 4
je 0x41ed50
mov ecx, dword [0x441fdc]
cmp dword [ecx], ebx
jne 0x41edb5
cmp eax, 4
jle 0x41edb5
call esi
mov esi, eax
call edi
cmp dword [0x43cd48], ebx
mov edi, eax
jge 0x41ed6a
mov eax, dword [0x441fa0]
mov dword [0x43cd48], eax
call fcn.0041c4b1
test eax, eax
je 0x41eda7
push 4
push dword [0x43cd48]
push 0x678
push str.C:_build_rel_sp_8_4_6_2_srcwindowsSHAREDutilitycabutil.cpp
call fcn.0041c4e1
movsx eax, byte [esp + 0x4c]
push eax
push ebp
push dword [esp + 0x4c]
push str.SendCmdEx:command:_d___d_bytes_recv_return_code_is__d_n
call fcn.0041c506
add esp, 0x20
call fcn.0041c4cc
push esi
call dword [sym.imp.WS2_32.dll_WSASetLastError]
push edi
call dword [sym.imp.KERNEL32.dll_SetLastError]
mov esi, dword [esp + 0x38]
push dword [esp + 0x10]
call dword [sym.imp.WS2_32.dll_closesocket]
mov eax, esi
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x20
ret