Function at 0x556cb0
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:
push ebp
push edi
push esi
push ebx
sub esp, 0x4c
mov eax, dword [esp + 0x60]
mov ebx, dword [esp + 0x64]
mov edx, dword [eax + 8]
test edx, edx
je 0x556e10
mov eax, dword [esp + 0x60]
mov ebp, dword [eax]
cmp ebp, 0xffffffff
je 0x556e40
mov edi, dword [esp + 0x68]
mov eax, dword [esp + 0x60]
mov dword [0x5bffe0], ebp
test edi, edi
mov esi, dword [eax + 0xc]
je 0x556e02
mov edi, dword [esp + 0x68]
jmp 0x556d2a
mov dword [esp + 0xc], 0
mov dword [esp + 8], edi
mov dword [esp + 4], ebx
mov dword [esp], ebp
call dword [sym.imp.WS2_32.dll_send]
sub esp, 0x10
test eax, eax
js 0x556d42
add ebx, eax
sub edi, eax
je 0x556e02
test esi, esi
jne 0x556d00
mov dword [esp + 8], edi
mov dword [esp + 4], ebx
mov dword [esp], ebp
call sym._write
test eax, eax
jns 0x556d20
call dword [sym.imp.msvcrt.dll__errno]
cmp dword [eax], 4
je 0x556d2a
mov ecx, dword [0x74374c]
test ecx, ecx
jne 0x556dd0
mov eax, dword [esp + 0x60]
cmp dword [eax], 0xffffffff
je 0x556e02
mov dword [esp], 2
call dbg._gpgrt__get_std_stream
mov dword [esp], eax
call dbg._gpgrt_fileno
mov dword [esp], eax
call sym._isatty
test eax, eax
je 0x556dd0
mov eax, dword [esp + 0x60]
cmp byte [eax + 0x10], 0
je 0x557073
call dword [sym.imp.msvcrt.dll__errno]
mov eax, dword [eax]
mov dword [esp], eax
call sym._strerror
mov dword [esp], 2
mov ebx, eax
call dbg._gpgrt__get_std_stream
mov ecx, dword [esp + 0x60]
mov dword [esp + 0xc], ebx
mov dword [esp + 4], str.error_writing_to__s:__s_n
mov dword [esp], eax
lea edx, [ecx + 0x10]
mov dword [esp + 8], edx
call dbg._gpgrt_fprintf
nop
mov eax, dword [esp + 0x60]
mov edx, dword [eax + 0xc]
test edx, edx
je 0x556e02
mov eax, dword [eax]
cmp eax, 0xffffffff
je 0x556e02
mov dword [esp], eax
call dword [sym.imp.WS2_32.dll_closesocket]
sub esp, 4
mov dword [0x5bffe0], 0xffffffff
mov eax, dword [esp + 0x60]
mov dword [eax], 0xffffffff
mov eax, dword [esp + 0x68]
add esp, 0x4c
pop ebx
pop esi
pop edi
pop ebp
ret
mov ebp, dword [eax]
cmp ebp, 0xffffffff
mov dword [0x5bffe0], ebp
je 0x556d4d
mov edi, dword [esp + 0x68]
mov eax, dword [esp + 0x60]
test edi, edi
mov esi, dword [eax + 0xc]
jne 0x556cf2
jmp 0x556e02
lea esi, [eax + 0x10]
mov dword [eax + 0xc], 0
mov edi, str.tcp:__
mov ecx, 6
mov dword [esp + 0x28], esi
repe cmpsb byte [esi], byte es:[edi]
jne 0x556e66
mov eax, dword [esp + 0x60]
cmp byte [eax + 0x16], 0
jne 0x556eb2
mov eax, dword [esp + 0x60]
mov dword [eax], 0xffffffff
mov eax, dword [esp + 0x60]
mov eax, dword [eax + 4]
test eax, eax
jne 0x557144
mov eax, dword [0x74374c]
test eax, eax
je 0x5570b4
mov eax, dword [esp + 0x60]
mov ebp, dword [eax]
cmp ebp, 0xffffffff
je 0x556e12
mov eax, dword [esp + 0x60]
mov dword [eax + 4], 0
mov dword [eax + 0xc], 1
jmp 0x556e12
lea edi, [eax + 0x16]
mov dword [esp], edi
call sym._strlen
add eax, 1
mov dword [esp], eax
call sym.__gpgrt_malloc
test eax, eax
mov esi, eax
je 0x557066
mov eax, dword [esp + 0x60]
cmp byte [eax + 0x16], 0x5b
je 0x557025
mov dword [esp + 4], edi
mov dword [esp], esi
call sym._strcpy
mov dword [esp + 4], 0x3a
mov dword [esp], esi
call sym._strchr
test eax, eax
mov dword [esp + 0x2c], eax
je 0x55705a
lea ecx, [eax + 1]
movsx eax, byte [eax + 1]
lea edx, [eax - 0x30]
cmp dl, 9
ja 0x55705a
lea edx, [eax - 0x30]
mov edi, ebx
jmp 0x556f35
lea edx, [edx + edx*4]
lea edx, [eax + edx*2 - 0x30]
cmp edx, 0xffff
ja 0x557173
add ecx, 1
movsx eax, byte [ecx]
lea ebx, [eax - 0x30]
cmp bl, 9
jbe 0x556f22
test edx, edx
mov ebx, edi
je 0x55705a
test al, al
jne 0x55705a
mov eax, dword [esp + 0x2c]
movzx edx, dx
lea edi, [esp + 0x30]
mov byte [eax], 0
mov eax, 2
mov dword [esp + 0x30], 0
mov dword [esp], edx
mov dword [esp + 0x34], 0
mov dword [esp + 0x38], 0
mov dword [esp + 0x3c], 0
mov word [esp + 0x30], ax
call dword [sym.imp.WS2_32.dll_htons]
sub esp, 4
mov word [esp + 0x32], ax
mov dword [esp], esi
call dword [sym.imp.WS2_32.dll_inet_addr]
sub esp, 4
cmp eax, 0xffffffff
mov dword [esp + 0x34], eax
je 0x557066
mov dword [esp], esi
call sym.__gpgrt_free
mov dword [esp + 8], 0
mov dword [esp + 4], 1
mov dword [esp], 2
call dword [sym.imp.WS2_32.dll_socket]
sub esp, 0xc
cmp eax, 0xffffffff
mov ecx, dword [esp + 0x60]
mov dword [ecx], eax
je 0x556e70
mov dword [esp + 8], 0x10
mov dword [esp + 4], edi
mov dword [esp], eax
call dword [sym.imp.WS2_32.dll_connect]
sub esp, 0xc
cmp eax, 0xffffffff
je 0x55710f
mov eax, dword [esp + 0x60]
mov eax, dword [eax]
cmp eax, 0xffffffff
je 0x557144
mov ebp, eax
jmp 0x556e9b
add eax, 0x17
mov dword [esp], esi
mov dword [esp + 4], eax
call sym._strcpy
mov dword [esp + 4], 0x5d
mov dword [esp], esi
call sym._strchr
test eax, eax
mov dword [esp + 0x28], eax
je 0x55705a
mov eax, dword [esp + 0x28]
cmp byte [eax + 1], 0x3a
je 0x55717a
mov dword [esp], 0x16
call sym.__gpg_err_set_errno
mov dword [esp], esi
call sym.__gpgrt_free
jmp 0x556e66
call dword [sym.imp.msvcrt.dll__errno]
mov eax, dword [eax]
mov dword [esp], eax
call sym._strerror
mov esi, eax
mov eax, dword [esp + 0x60]
mov ebx, dword [eax]
mov dword [esp], 2
call dbg._gpgrt__get_std_stream
mov dword [esp + 0xc], esi
mov dword [esp + 4], str.error_writing_to_file_descriptor__d:__s_n
mov dword [esp + 8], ebx
mov dword [esp], eax
call dbg._gpgrt_fprintf
jmp 0x556dd0
mov dword [esp], 2
call dbg._gpgrt__get_std_stream
mov dword [esp], eax
call dbg._gpgrt_fileno
mov dword [esp], eax
call sym._isatty
test eax, eax
je 0x55700f
call dword [sym.imp.msvcrt.dll__errno]
mov eax, dword [eax]
mov dword [esp], eax
call sym._strerror
mov dword [esp], 2
mov esi, eax
call dbg._gpgrt__get_std_stream
mov dword [esp + 8], esi
mov dword [esp + 4], str.failed_to_create_socket_for_logging:__s_n
mov dword [esp], eax
call dbg._gpgrt_fprintf
jmp 0x55700f
mov eax, dword [esp + 0x60]
mov edi, dword [eax + 4]
test edi, edi
jne 0x557128
mov esi, dword [0x74374c]
test esi, esi
je 0x5571db
mov eax, dword [esp + 0x60]
mov eax, dword [eax]
mov dword [esp], eax
call dword [sym.imp.WS2_32.dll_closesocket]
sub esp, 4
mov eax, dword [esp + 0x60]
mov dword [eax], 0xffffffff
mov ecx, dword [0x74374c]
mov eax, dword [esp + 0x60]
test ecx, ecx
jne 0x556e10
mov edx, dword [eax + 4]
test edx, edx
jne 0x557164
mov dword [eax + 4], 1
mov eax, dword [esp + 0x60]
mov dword [eax], 0xffffffff
jmp 0x556e12
mov ebx, edi
jmp 0x55705a
lea ecx, [eax + 2]
movsx eax, byte [eax + 2]
lea edx, [eax - 0x30]
cmp dl, 9
ja 0x55705a
lea edx, [eax - 0x30]
mov edi, ebx
jmp 0x5571a3
lea edx, [edx + edx*4]
lea edx, [eax + edx*2 - 0x30]
cmp edx, 0xffff
ja 0x557173
add ecx, 1
movsx eax, byte [ecx]
lea ebx, [eax - 0x30]
cmp bl, 9
jbe 0x557194
test edx, edx
mov ebx, edi
je 0x55705a
test al, al
jne 0x55705a
mov eax, dword [esp + 0x28]
mov byte [eax], 0
mov dword [esp], 0x66
call sym.__gpg_err_set_errno
jmp 0x557066
mov dword [esp], 2
call dbg._gpgrt__get_std_stream
mov dword [esp], eax
call dbg._gpgrt_fileno
mov dword [esp], eax
call sym._isatty
test eax, eax
je 0x557128
call dword [sym.imp.msvcrt.dll__errno]
mov eax, dword [eax]
mov dword [esp], eax
call sym._strerror
mov dword [esp], 2
mov esi, eax
call dbg._gpgrt__get_std_stream
mov ecx, dword [esp + 0x28]
mov dword [esp + 0x10], esi
mov dword [esp + 0xc], 0x651ead
mov dword [esp + 4], str.cant_connect_to__s_s:__s_n
mov dword [esp], eax
mov dword [esp + 8], ecx
call dbg._gpgrt_fprintf
jmp 0x557128