Function at 0x1400024f0
Capabilities:
Act as tcp client
Connect socket
Connect tcp socket
Connect udp socket
Create tcp socket
Create udp socket
Resolve dns

Disassembly:
push rbp
sub rsp, 0x80
lea rbp, [rsp + 0x80]
mov dword [rbp - 0xc], edx
mov qword [rbp - 8], rcx
mov eax, dword [0x140012ba0]
mov ecx, dword [0x140012bac]
mov edx, eax
sub edx, 1
imul eax, edx
and eax, 1
cmp eax, 0
sete al
cmp ecx, 0xa
setl cl
or al, cl
test al, 1
jne 0x140002539
jmp 0x140002df9
mov eax, dword [0x140012ba0]
mov ecx, dword [0x140012bac]
mov edx, eax
sub edx, 1
imul eax, edx
and eax, 1
cmp eax, 0
sete al
cmp ecx, 0xa
setl cl
or al, cl
test al, 1
jne 0x14000256b
jmp 0x140002fd6
mov ecx, dword [rbp - 0xc]
mov r8, qword [rbp - 8]
mov eax, 0x10
mov qword [rbp - 0x30], rax
call fcn.1400084c0
sub rsp, rax
mov rax, qword [rbp - 0x30]
mov rdx, rsp
mov qword [rbp - 0x40], rdx
call fcn.1400084c0
sub rsp, rax
mov rax, qword [rbp - 0x30]
mov r9, rsp
mov qword [rbp - 0x20], r9
call fcn.1400084c0
sub rsp, rax
mov rax, qword [rbp - 0x30]
mov r9, rsp
mov qword [rbp - 0x38], r9
call fcn.1400084c0
sub rsp, rax
mov rax, qword [rbp - 0x30]
mov r9, rsp
mov qword [rbp - 0x28], r9
call fcn.1400084c0
sub rsp, rax
mov rax, qword [rbp - 0x20]
mov r9, rsp
mov qword [rbp - 0x18], r9
mov qword [rdx], r8
mov dword [rax], ecx
mov ecx, 2
mov edx, 1
xor r8d, r8d
sub rsp, 0x20
call qword [sym.imp.WS2_32.dll_socket]
add rsp, 0x20
mov rcx, rax
mov rax, qword [rbp - 0x18]
mov qword [rax], rcx
cmp qword [rax], 0xffffffffffffffff
sete al
mov byte [rbp - 0xd], al
mov eax, dword [0x140012ba0]
mov ecx, dword [0x140012bac]
mov edx, eax
sub edx, 1
imul eax, edx
and eax, 1
cmp eax, 0
sete al
cmp ecx, 0xa
setl cl
or al, cl
test al, 1
jne 0x140002640
jmp 0x140002fd6
mov eax, dword [0x140012ba0]
mov ecx, dword [0x140012bac]
mov edx, eax
sub edx, 1
imul eax, edx
and eax, 1
cmp eax, 0
sete al
cmp ecx, 0xa
setl cl
or al, cl
test al, 1
jne 0x140002672
jmp 0x140002df9
mov eax, dword [0x140012ba0]
mov ecx, dword [0x140012bac]
mov edx, eax
sub edx, 1
imul eax, edx
and eax, 1
cmp eax, 0
sete al
cmp ecx, 0xa
setl cl
or al, cl
test al, 1
jne 0x1400026a4
jmp 0x140003062
mov eax, dword [0x140012ba0]
mov ecx, dword [0x140012bac]
mov edx, eax
sub edx, 1
imul eax, edx
and eax, 1
cmp eax, 0
sete al
cmp ecx, 0xa
setl cl
or al, cl
test al, 1
jne 0x1400026d6
jmp 0x140003062
mov al, byte [rbp - 0xd]
test al, 1
jne 0x1400026e6
jmp 0x140002832
mov eax, dword [0x140012ba0]
mov ecx, dword [0x140012bac]
mov edx, eax
sub edx, 1
imul eax, edx
and eax, 1
cmp eax, 0
sete al
cmp ecx, 0xa
setl cl
or al, cl
test al, 1
jne 0x140002718
jmp 0x140002e85
mov eax, dword [0x140012ba0]
mov ecx, dword [0x140012bac]
mov edx, eax
sub edx, 1
imul eax, edx
and eax, 1
cmp eax, 0
sete al
cmp ecx, 0xa
setl cl
or al, cl
test al, 1
jne 0x14000274a
jmp 0x140003067
mov rax, qword [rbp - 0x18]
mov rcx, qword [rax]
lea rdx, str.Could_not_initialize_socket
sub rsp, 0x20
call sym.punt
add rsp, 0x20
mov eax, dword [0x140012ba0]
mov ecx, dword [0x140012bac]
mov edx, eax
sub edx, 1
imul eax, edx
and eax, 1
cmp eax, 0
sete al
cmp ecx, 0xa
setl cl
or al, cl
test al, 1
jne 0x140002797
jmp 0x140003067
mov eax, dword [0x140012ba0]
mov ecx, dword [0x140012bac]
mov edx, eax
sub edx, 1
imul eax, edx
and eax, 1
cmp eax, 0
sete al
cmp ecx, 0xa
setl cl
or al, cl
test al, 1
jne 0x1400027c9
jmp 0x140002e85
mov eax, dword [0x140012ba0]
mov ecx, dword [0x140012bac]
mov edx, eax
sub edx, 1
imul eax, edx
and eax, 1
cmp eax, 0
sete al
cmp ecx, 0xa
setl cl
or al, cl
test al, 1
jne 0x1400027fb
jmp 0x140003087
mov eax, dword [0x140012ba0]
mov ecx, dword [0x140012bac]
mov edx, eax
sub edx, 1
imul eax, edx
and eax, 1
cmp eax, 0
sete al
cmp ecx, 0xa
setl cl
or al, cl
test al, 1
jne 0x14000282d
jmp 0x140003087
jmp 0x140002832
mov eax, dword [0x140012ba0]
mov ecx, dword [0x140012bac]
mov edx, eax
sub edx, 1
imul eax, edx
and eax, 1
cmp eax, 0
sete al
cmp ecx, 0xa
setl cl
or al, cl
test al, 1
jne 0x140002864
jmp 0x140002f09
mov eax, dword [0x140012ba0]
mov ecx, dword [0x140012bac]
mov edx, eax
sub edx, 1
imul eax, edx
and eax, 1
cmp eax, 0
sete al
cmp ecx, 0xa
setl cl
or al, cl
test al, 1
jne 0x140002896
jmp 0x14000308c
mov rax, qword [rbp - 0x40]
mov rcx, qword [rax]
sub rsp, 0x20
call qword [sym.imp.WS2_32.dll_gethostbyname]
add rsp, 0x20
mov rcx, rax
mov rax, qword [rbp - 0x38]
mov qword [rax], rcx
cmp qword [rax], 0
sete al
mov byte [rbp - 0x41], al
mov eax, dword [0x140012ba0]
mov ecx, dword [0x140012bac]
mov edx, eax
sub edx, 1
imul eax, edx
and eax, 1
cmp eax, 0
sete al
cmp ecx, 0xa
setl cl
or al, cl
test al, 1
jne 0x1400028f1
jmp 0x14000308c
mov eax, dword [0x140012ba0]
mov ecx, dword [0x140012bac]
mov edx, eax
sub edx, 1
imul eax, edx
and eax, 1
cmp eax, 0
sete al
cmp ecx, 0xa
setl cl
or al, cl
test al, 1
jne 0x140002923
jmp 0x140002f09
mov eax, dword [0x140012ba0]
mov ecx, dword [0x140012bac]
mov edx, eax
sub edx, 1
imul eax, edx
and eax, 1
cmp eax, 0
sete al
cmp ecx, 0xa
setl cl
or al, cl
test al, 1
jne 0x140002955
jmp 0x1400030b0
mov eax, dword [0x140012ba0]
mov ecx, dword [0x140012bac]
mov edx, eax
sub edx, 1
imul eax, edx
and eax, 1
cmp eax, 0
sete al
cmp ecx, 0xa
setl cl
or al, cl
test al, 1
jne 0x140002987
jmp 0x1400030b0
mov al, byte [rbp - 0x41]
test al, 1
jne 0x140002997
jmp 0x140002a7f
mov eax, dword [0x140012ba0]
mov ecx, dword [0x140012bac]
mov edx, eax
sub edx, 1
imul eax, edx
and eax, 1
cmp eax, 0
sete al
cmp ecx, 0xa
setl cl
or al, cl
test al, 1
jne 0x1400029c9
jmp 0x140002f2d
mov rax, qword [rbp - 0x18]
mov rcx, qword [rax]
lea rdx, str.Could_not_resolve_target
sub rsp, 0x20
call sym.punt
add rsp, 0x20
mov eax, dword [0x140012ba0]
mov ecx, dword [0x140012bac]
mov edx, eax
sub edx, 1
imul eax, edx
and eax, 1
cmp eax, 0
sete al
cmp ecx, 0xa
setl cl
or al, cl
test al, 1
jne 0x140002a16
jmp 0x140002f2d
mov eax, dword [0x140012ba0]
mov ecx, dword [0x140012bac]
mov edx, eax
sub edx, 1
imul eax, edx
and eax, 1
cmp eax, 0
sete al
cmp ecx, 0xa
setl cl
or al, cl
test al, 1
jne 0x140002a48
jmp 0x1400030b5
mov eax, dword [0x140012ba0]
mov ecx, dword [0x140012bac]
mov edx, eax
sub edx, 1
imul eax, edx
and eax, 1
cmp eax, 0
sete al
cmp ecx, 0xa
setl cl
or al, cl
test al, 1
jne 0x140002a7a
jmp 0x1400030b5
jmp 0x140002a7f
mov eax, dword [0x140012ba0]
mov ecx, dword [0x140012bac]
mov edx, eax
sub edx, 1
imul eax, edx
and eax, 1
cmp eax, 0
sete al
cmp ecx, 0xa
setl cl
or al, cl
test al, 1
jne 0x140002ab1
jmp 0x1400030ba
mov rcx, qword [rbp - 0x28]
mov rax, qword [rbp - 0x38]
add rcx, 4
mov rdx, qword [rax]
mov rdx, qword [rdx + 0x18]
mov rdx, qword [rdx]
mov rax, qword [rax]
movsx r8, word [rax + 0x12]
sub rsp, 0x20
call sym.memcpy
mov rax, qword [rbp - 0x20]
mov rcx, qword [rbp - 0x28]
add rsp, 0x20
mov word [rcx], 2
mov eax, dword [rax]
mov cx, ax
sub rsp, 0x20
call qword [sym.imp.WS2_32.dll_htons]
mov rdx, qword [rbp - 0x28]
add rsp, 0x20
mov cx, ax
mov rax, qword [rbp - 0x18]
mov word [rdx + 2], cx
mov rcx, qword [rax]
mov r8d, 0x10
sub rsp, 0x20
call qword [sym.imp.WS2_32.dll_connect]
add rsp, 0x20
cmp eax, 0
setne al
mov byte [rbp - 0x42], al
mov eax, dword [0x140012ba0]
mov ecx, dword [0x140012bac]
mov edx, eax
sub edx, 1
imul eax, edx
and eax, 1
cmp eax, 0
sete al
cmp ecx, 0xa
setl cl
or al, cl
test al, 1
jne 0x140002b5d
jmp 0x1400030ba
mov al, byte [rbp - 0x42]
test al, 1
jne 0x140002b6d
jmp 0x140002cb9
mov eax, dword [0x140012ba0]
mov ecx, dword [0x140012bac]
mov edx, eax
sub edx, 1
imul eax, edx
and eax, 1
cmp eax, 0
sete al
cmp ecx, 0xa
setl cl
or al, cl
test al, 1
jne 0x140002b9f
jmp 0x140003130
mov eax, dword [0x140012ba0]
mov ecx, dword [0x140012bac]
mov edx, eax
sub edx, 1
imul eax, edx
and eax, 1
cmp eax, 0
sete al
cmp ecx, 0xa
setl cl
or al, cl
test al, 1
jne 0x140002bd1
jmp 0x140003130
mov eax, dword [0x140012ba0]
mov ecx, dword [0x140012bac]
mov edx, eax
sub edx, 1
imul eax, edx
and eax, 1
cmp eax, 0
sete al
cmp ecx, 0xa
setl cl
or al, cl
test al, 1
jne 0x140002c03
jmp 0x140002f4d
mov eax, dword [0x140012ba0]
mov ecx, dword [0x140012bac]
mov edx, eax
sub edx, 1
imul eax, edx
and eax, 1
cmp eax, 0
sete al
cmp ecx, 0xa
setl cl
or al, cl
test al, 1
jne 0x140002c35
jmp 0x140003135
mov rax, qword [rbp - 0x18]
mov rcx, qword [rax]
lea rdx, str.Could_not_connect_to_target
sub rsp, 0x20
call sym.punt
add rsp, 0x20
mov eax, dword [0x140012ba0]
mov ecx, dword [0x140012bac]
mov edx, eax
sub edx, 1
imul eax, edx
and eax, 1
cmp eax, 0
sete al
cmp ecx, 0xa
setl cl
or al, cl
test al, 1
jne 0x140002c82
jmp 0x140003135
mov eax, dword [0x140012ba0]
mov ecx, dword [0x140012bac]
mov edx, eax
sub edx, 1
imul eax, edx
and eax, 1
cmp eax, 0
sete al
cmp ecx, 0xa
setl cl
or al, cl
test al, 1
jne 0x140002cb4
jmp 0x140002f4d
jmp 0x140002cb9
mov eax, dword [0x140012ba0]
mov ecx, dword [0x140012bac]
mov edx, eax
sub edx, 1
imul eax, edx
and eax, 1
cmp eax, 0
sete al
cmp ecx, 0xa
setl cl
or al, cl
test al, 1
jne 0x140002ceb
jmp 0x140002fd1
mov eax, dword [0x140012ba0]
mov ecx, dword [0x140012bac]
mov edx, eax
sub edx, 1
imul eax, edx
and eax, 1
cmp eax, 0
sete al
cmp ecx, 0xa
setl cl
or al, cl
test al, 1
jne 0x140002d1d
jmp 0x140003155
mov rax, qword [rbp - 0x18]
mov rax, qword [rax]
mov qword [rbp - 0x50], rax
mov eax, dword [0x140012ba0]
mov ecx, dword [0x140012bac]
mov edx, eax
sub edx, 1
imul eax, edx
and eax, 1
cmp eax, 0
sete al
cmp ecx, 0xa
setl cl
or al, cl
test al, 1
jne 0x140002d5a
jmp 0x140003155
mov eax, dword [0x140012ba0]
mov ecx, dword [0x140012bac]
mov edx, eax
sub edx, 1
imul eax, edx
and eax, 1
cmp eax, 0
sete al
cmp ecx, 0xa
setl cl
or al, cl
test al, 1
jne 0x140002d8c
jmp 0x140002fd1
mov eax, dword [0x140012ba0]
mov ecx, dword [0x140012bac]
mov edx, eax
sub edx, 1
imul eax, edx
and eax, 1
cmp eax, 0
sete al
cmp ecx, 0xa
setl cl
or al, cl
test al, 1
jne 0x140002dbe
jmp 0x14000315a
mov eax, dword [0x140012ba0]
mov ecx, dword [0x140012bac]
mov edx, eax
sub edx, 1
imul eax, edx
and eax, 1
cmp eax, 0
sete al
cmp ecx, 0xa
setl cl
or al, cl
test al, 1
jne 0x140002df0
jmp 0x14000315a
mov rax, qword [rbp - 0x50]
mov rsp, rbp
pop rbp
ret
mov ecx, dword [rbp - 0xc]
mov r8, qword [rbp - 8]
mov eax, 0x10
mov qword [rbp - 0x68], rax
call fcn.1400084c0
sub rsp, rax
mov rax, qword [rbp - 0x68]
mov rdx, rsp
call fcn.1400084c0
sub rsp, rax
mov rax, qword [rbp - 0x68]
mov r9, rsp
mov qword [rbp - 0x60], r9
call fcn.1400084c0
sub rsp, rax
mov rax, qword [rbp - 0x68]
call fcn.1400084c0
sub rsp, rax
mov rax, qword [rbp - 0x68]
call fcn.1400084c0
sub rsp, rax
mov rax, qword [rbp - 0x60]
mov r9, rsp
mov qword [rbp - 0x58], r9
mov qword [rdx], r8
mov dword [rax], ecx
mov ecx, 2
mov edx, 1
xor r8d, r8d
sub rsp, 0x20
call qword [sym.imp.WS2_32.dll_socket]
add rsp, 0x20
mov rcx, rax
mov rax, qword [rbp - 0x58]
mov qword [rax], rcx
jmp 0x140002539
mov eax, dword [0x140012ba0]
mov ecx, dword [0x140012bac]
mov edx, eax
sub edx, 1
imul eax, edx
and eax, 1
cmp eax, 0
sete al
cmp ecx, 0xa
setl cl
or al, cl
test al, 1
jne 0x140002eb7
jmp 0x14000315f
mov rax, qword [rbp - 0x18]
mov rcx, qword [rax]
lea rdx, str.Could_not_initialize_socket
sub rsp, 0x20
call sym.punt
add rsp, 0x20
mov eax, dword [0x140012ba0]
mov ecx, dword [0x140012bac]
mov edx, eax
sub edx, 1
imul eax, edx
and eax, 1
cmp eax, 0
sete al
cmp ecx, 0xa
setl cl
or al, cl
test al, 1
jne 0x140002f04
jmp 0x14000315f
jmp 0x140002718
mov rax, qword [rbp - 0x40]
mov rcx, qword [rax]
sub rsp, 0x20
call qword [sym.imp.WS2_32.dll_gethostbyname]
add rsp, 0x20
mov rcx, rax
mov rax, qword [rbp - 0x38]
mov qword [rax], rcx
jmp 0x140002864
mov rax, qword [rbp - 0x18]
mov rcx, qword [rax]
lea rdx, str.Could_not_resolve_target
sub rsp, 0x20
call sym.punt
add rsp, 0x20
jmp 0x1400029c9
mov eax, dword [0x140012ba0]
mov ecx, dword [0x140012bac]
mov edx, eax
sub edx, 1
imul eax, edx
and eax, 1
cmp eax, 0
sete al
cmp ecx, 0xa
setl cl
or al, cl
test al, 1
jne 0x140002f7f
jmp 0x14000317f
mov rax, qword [rbp - 0x18]
mov rcx, qword [rax]
lea rdx, str.Could_not_connect_to_target
sub rsp, 0x20
call sym.punt
add rsp, 0x20
mov eax, dword [0x140012ba0]
mov ecx, dword [0x140012bac]
mov edx, eax
sub edx, 1
imul eax, edx
and eax, 1
cmp eax, 0
sete al
cmp ecx, 0xa
setl cl
or al, cl
test al, 1
jne 0x140002fcc
jmp 0x14000317f
jmp 0x140002c03
jmp 0x140002ceb
mov ecx, dword [rbp - 0xc]
mov r8, qword [rbp - 8]
mov eax, 0x10
mov qword [rbp - 0x80], rax
call fcn.1400084c0
sub rsp, rax
mov rax, qword [rbp - 0x80]
mov rdx, rsp
call fcn.1400084c0
sub rsp, rax
mov rax, qword [rbp - 0x80]
mov r9, rsp
mov qword [rbp - 0x78], r9
call fcn.1400084c0
sub rsp, rax
mov rax, qword [rbp - 0x80]
call fcn.1400084c0
sub rsp, rax
mov rax, qword [rbp - 0x80]
call fcn.1400084c0
sub rsp, rax
mov rax, qword [rbp - 0x78]
mov r9, rsp
mov qword [rbp - 0x70], r9
mov qword [rdx], r8
mov dword [rax], ecx
mov ecx, 2
mov edx, 1
xor r8d, r8d
sub rsp, 0x20
call qword [sym.imp.WS2_32.dll_socket]
add rsp, 0x20
mov rcx, rax
mov rax, qword [rbp - 0x70]
mov qword [rax], rcx
jmp 0x14000256b
jmp 0x1400026a4
mov rax, qword [rbp - 0x18]
mov rcx, qword [rax]
lea rdx, str.Could_not_initialize_socket
sub rsp, 0x20
call sym.punt
add rsp, 0x20
jmp 0x14000274a
jmp 0x1400027fb
mov rax, qword [rbp - 0x40]
mov rcx, qword [rax]
sub rsp, 0x20
call qword [sym.imp.WS2_32.dll_gethostbyname]
add rsp, 0x20
mov rcx, rax
mov rax, qword [rbp - 0x38]
mov qword [rax], rcx
jmp 0x140002896
jmp 0x140002955
jmp 0x140002a48
mov rcx, qword [rbp - 0x28]
mov rax, qword [rbp - 0x38]
add rcx, 4
mov rdx, qword [rax]
mov rdx, qword [rdx + 0x18]
mov rdx, qword [rdx]
mov rax, qword [rax]
movsx r8, word [rax + 0x12]
sub rsp, 0x20
call sym.memcpy
mov rax, qword [rbp - 0x20]
mov rcx, qword [rbp - 0x28]
add rsp, 0x20
mov word [rcx], 2
mov eax, dword [rax]
mov cx, ax
sub rsp, 0x20
call qword [sym.imp.WS2_32.dll_htons]
mov rdx, qword [rbp - 0x28]
add rsp, 0x20
mov cx, ax
mov rax, qword [rbp - 0x18]
mov word [rdx + 2], cx
mov rcx, qword [rax]
mov r8d, 0x10
sub rsp, 0x20
call qword [sym.imp.WS2_32.dll_connect]
add rsp, 0x20
jmp 0x140002ab1
jmp 0x140002b9f
mov rax, qword [rbp - 0x18]
mov rcx, qword [rax]
lea rdx, str.Could_not_connect_to_target
sub rsp, 0x20
call sym.punt
add rsp, 0x20
jmp 0x140002c35
jmp 0x140002d1d
jmp 0x140002dbe
mov rax, qword [rbp - 0x18]
mov rcx, qword [rax]
lea rdx, str.Could_not_initialize_socket
sub rsp, 0x20
call sym.punt
add rsp, 0x20
jmp 0x140002eb7
mov rax, qword [rbp - 0x18]
mov rcx, qword [rax]
lea rdx, str.Could_not_connect_to_target
sub rsp, 0x20
call sym.punt
add rsp, 0x20
jmp 0x140002f7f