Function at 0x140002880
Capabilities:
Act as tcp client
Connect socket
Connect tcp socket
Create tcp socket
Initialize winsock library
Receive data
Receive data on socket
Resolve dns
Send data
Send data on socket
Send http request
Send http request with host header

Disassembly:
mov qword [rsp + 8], rbx
mov qword [rsp + 0x10], rsi
mov qword [rsp + 0x18], rdi
push rbp
push r12
push r13
push r14
push r15
lea rbp, [rsp - 0x11f0]
mov eax, 0x12f0
call fcn.1400077e0
sub rsp, rax
mov rdi, r8
mov rbx, rdx
mov r14, rcx
xor r15d, r15d
mov ecx, 0x202
lea rdx, [rbp + 0x50]
call qword [sym.imp.WS2_32.dll_WSAStartup]
test eax, eax
jne 0x1400030f4
lea edx, [rax + 1]
lea ecx, [rax + 2]
lea r8d, [r15 + 6]
call qword [sym.imp.WS2_32.dll_socket]
mov rsi, rax
cmp rax, 0xffffffffffffffff
je 0x14000311a
mov qword [rbp + 0x1238], r15
mov dword [rbp + 0x18], r15d
xorps xmm0, xmm0
movdqu xmmword [rbp + 0x28], xmm0
xorps xmm1, xmm1
movdqu xmmword [rbp + 0x38], xmm1
mov dword [rbp + 0x1c], 2
mov dword [rbp + 0x20], 1
mov dword [rbp + 0x24], 6
lea r9, [rbp + 0x1238]
lea r8, [rbp + 0x18]
lea rdx, str.http
mov rcx, rbx
call qword [sym.imp.WS2_32.dll_getaddrinfo]
test eax, eax
jne 0x140003146
mov rdx, qword [rbp + 0x1238]
mov r8d, dword [rdx + 0x10]
mov rdx, qword [rdx + 0x20]
mov rcx, rsi
call qword [sym.imp.WS2_32.dll_connect]
cmp eax, 0xffffffff
je 0x14000317b
xorps xmm0, xmm0
movups xmmword [rbp - 0x28], xmm0
xorps xmm1, xmm1
movdqu xmmword [rbp - 0x18], xmm1
mov r12, 0xffffffffffffffff
mov r8, r12
nop word [rax + rax]
inc r8
cmp byte [rbx + r8], r15b
jne 0x140002980
mov rdx, rbx
lea rcx, [rbp - 0x28]
call fcn.1400018f0
nop
xorps xmm0, xmm0
movups xmmword [rbp - 0x70], xmm0
xorps xmm1, xmm1
movdqu xmmword [rbp - 0x60], xmm1
mov r8, r12
nop dword [rax + rax]
inc r8
cmp byte [rdi + r8], 0
jne 0x1400029b0
mov rdx, rdi
lea rcx, [rbp - 0x70]
call fcn.1400018f0
nop
mov r8, qword [rbp - 0x60]
mov rcx, qword [rbp - 0x58]
mov rax, rcx
sub rax, r8
cmp rax, 4
jb 0x140002a63
lea rax, [r8 + 4]
mov qword [rbp - 0x60], rax
lea rbx, [rbp - 0x70]
cmp rcx, 0xf
cmova rbx, qword [rbp - 0x70]
lea rax, [0x14002e3e8]
lea r13, str.GET
cmp rax, rbx
jbe 0x140002a22
lea rax, [rbx + r8]
cmp r13, rax
ja 0x140002a22
cmp rbx, r13
ja 0x140002a1a
mov rdi, r15
jmp 0x140002a27
mov rdi, rbx
sub rdi, r13
jmp 0x140002a27
mov edi, 4
lea rcx, [rbx + 4]
inc r8
mov rdx, rbx
call fcn.140021ab0
mov r8, rdi
mov rdx, r13
mov rcx, rbx
call fcn.140021ab0
lea rcx, [rbx + rdi]
mov r8d, 4
sub r8, rdi
lea rdx, [r13 + 4]
add rdx, rdi
call fcn.140021ab0
lea rax, [rbp - 0x70]
jmp 0x140002a7a
mov qword [rsp + 0x28], 4
mov edx, 4
lea rcx, [rbp - 0x70]
call fcn.140004950
xorps xmm0, xmm0
movups xmmword [rsp + 0x70], xmm0
xorps xmm1, xmm1
movdqu xmmword [rbp - 0x80], xmm1
movups xmm0, xmmword [rax]
movups xmmword [rsp + 0x70], xmm0
movups xmm1, xmmword [rax + 0x10]
movups xmmword [rbp - 0x80], xmm1
mov qword [rax + 0x10], r15
mov qword [rax + 0x18], send
mov byte [rax], 0
mov rcx, qword [rbp - 0x80]
mov rdx, qword [rbp - 0x78]
mov rax, rdx
sub rax, rcx
cmp rax, 0x11
jb 0x140002af7
lea rax, [rcx + 0x11]
mov qword [rbp - 0x80], rax
lea rbx, [rsp + 0x70]
cmp rdx, 0xf
cmova rbx, qword [rsp + 0x70]
add rbx, rcx
mov r8d, send
lea rdx, str._HTTP_1.1_r_nHost:
mov rcx, rbx
call fcn.140021ab0
mov byte [rbx + 0x11], 0
lea rax, [rsp + 0x70]
jmp 0x140002b18
mov qword [rsp + 0x20], send
lea r9, str._HTTP_1.1_r_nHost:
xor r8d, r8d
lea edx, [r8 + 0x11]
lea rcx, [rsp + 0x70]
call fcn.140003d10
movups xmm0, xmmword [rax]
movups xmmword [rbp - 8], xmm0
movups xmm1, xmmword [rax + 0x10]
movups xmmword [rbp + 8], xmm1
mov qword [rax + 0x10], r15
mov qword [rax + 0x18], send
mov byte [rax], 0
lea r9, [rbp - 0x28]
lea r8, [rbp - 8]
lea rcx, [rbp - 0x50]
call fcn.1400043c0
nop
mov rcx, qword [rbp - 0x40]
mov rdx, qword [rbp - 0x38]
mov rax, rdx
sub rax, rcx
lea r8, str._r_n_r_n
cmp rax, 4
jb 0x140002b8a
lea rax, [rcx + 4]
mov qword [rbp - 0x40], rax
lea rax, [rbp - 0x50]
cmp rdx, 0xf
cmova rax, qword [rbp - 0x50]
mov dword [rax + rcx], 0xa0d0a0d
mov byte [rax + rcx + 4], 0
lea rax, [rbp - 0x50]
jmp 0x140002ba6
mov qword [rsp + 0x20], 4
mov r9, r8
xor r8d, r8d
lea edx, [r8 + 4]
lea rcx, [rbp - 0x50]
call fcn.140003d10
xorps xmm0, xmm0
movups xmmword [rsp + 0x50], xmm0
mov qword [rsp + 0x60], r15
mov qword [rsp + 0x68], r15
movups xmm0, xmmword [rax]
movups xmmword [rsp + 0x50], xmm0
movups xmm1, xmmword [rax + 0x10]
movups xmmword [rsp + 0x60], xmm1
mov qword [rax + 0x10], r15
mov qword [rax + 0x18], send
mov byte [rax], 0
mov rdx, qword [rbp - 0x38]
cmp rdx, 0xf
jbe 0x140002c13
inc rdx
mov rcx, qword [rbp - 0x50]
mov rax, rcx
cmp rdx, 0x1000
jb 0x140002c0e
add rdx, 0x27
mov rcx, qword [rcx - 8]
sub rax, rcx
add rax, 0xfffffffffffffff8
cmp rax, 0x1f
ja 0x1400031bd
call fcn.1400073f0
movdqa xmm0, xmmword [0x14002e460]
movdqu xmmword [rbp - 0x40], xmm0
mov byte [rbp - 0x50], 0
mov rdx, qword [rbp + 0x10]
cmp rdx, 0xf
jbe 0x140002c60
inc rdx
mov rcx, qword [rbp - 8]
mov rax, rcx
cmp rdx, 0x1000
jb 0x140002c5a
add rdx, 0x27
mov rcx, qword [rcx - 8]
sub rax, rcx
add rax, 0xfffffffffffffff8
cmp rax, 0x1f
ja 0x1400031c3
call fcn.1400073f0
nop
mov rdx, qword [rbp - 0x78]
cmp rdx, 0xf
jbe 0x140002c9c
inc rdx
mov rcx, qword [rsp + 0x70]
mov rax, rcx
cmp rdx, 0x1000
jb 0x140002c97
add rdx, 0x27
mov rcx, qword [rcx - 8]
sub rax, rcx
add rax, 0xfffffffffffffff8
cmp rax, 0x1f
ja 0x1400031c9
call fcn.1400073f0
movdqa xmm0, xmmword [0x14002e460]
movdqu xmmword [rbp - 0x80], xmm0
mov byte [rsp + 0x70], 0
mov rdx, qword [rbp - 0x58]
cmp rdx, 0xf
jbe 0x140002ce9
inc rdx
mov rcx, qword [rbp - 0x70]
mov rax, rcx
cmp rdx, 0x1000
jb 0x140002ce4
add rdx, 0x27
mov rcx, qword [rcx - 8]
sub rax, rcx
add rax, 0xfffffffffffffff8
cmp rax, 0x1f
ja 0x1400031cf
call fcn.1400073f0
movdqa xmm0, xmmword [0x14002e460]
movdqu xmmword [rbp - 0x60], xmm0
mov byte [rbp - 0x70], 0
mov rdx, qword [rbp - 0x10]
cmp rdx, 0xf
jbe 0x140002d35
inc rdx
mov rcx, qword [rbp - 0x28]
mov rax, rcx
cmp rdx, 0x1000
jb 0x140002d30
add rdx, 0x27
mov rcx, qword [rcx - 8]
sub rax, rcx
add rax, 0xfffffffffffffff8
cmp rax, 0x1f
ja 0x1400031d5
call fcn.1400073f0
lea rdx, str.Request:_n
lea rcx, [0x140034350]
call fcn.1400038e0
lea rdx, [rsp + 0x50]
cmp qword [rsp + 0x68], 0xf
cmova rdx, qword [rsp + 0x50]
mov r8, qword [rsp + 0x60]
mov rcx, rax
call fcn.1400046a0
mov rcx, rax
call fcn.140003b90
lea rdx, [rsp + 0x50]
cmp qword [rsp + 0x68], 0xf
cmova rdx, qword [rsp + 0x50]
xor r9d, r9d
mov r8d, dword [rsp + 0x60]
mov rcx, rsi
call qword [sym.imp.WS2_32.dll_send]
xorps xmm0, xmm0
movups xmmword [rsp + 0x30], xmm0
mov qword [rsp + 0x40], r15
mov qword [rsp + 0x48], send
mov byte [rsp + 0x30], 0
nop dword [rax + rax]
xor r9d, r9d
mov r8d, 0x1000
lea rdx, [rbp + 0x1f0]
mov rcx, rsi
call qword [sym.imp.WS2_32.dll_recv]
test eax, eax
jle 0x140002e39
movsxd rdi, eax
mov rcx, qword [rsp + 0x40]
mov rdx, qword [rsp + 0x48]
mov rax, rdx
sub rax, rcx
cmp rdi, rax
ja 0x140002e18
lea rax, [rcx + rdi]
mov qword [rsp + 0x40], rax
lea rbx, [rsp + 0x30]
cmp rdx, 0xf
cmova rbx, qword [rsp + 0x30]
add rbx, rcx
mov r8, rdi
lea rdx, [rbp + 0x1f0]
mov rcx, rbx
call fcn.140021ab0
mov byte [rbx + rdi], 0
jmp 0x140002db0
mov qword [rsp + 0x20], rdi
lea r9, [rbp + 0x1f0]
xor r8d, r8d
mov rdx, rdi
lea rcx, [rsp + 0x30]
call fcn.140003d10
jmp 0x140002db0
lea rdx, str.Response:_n
lea rcx, [0x140034350]
call fcn.1400038e0
lea rdx, [rsp + 0x30]
cmp qword [rsp + 0x48], 0xf
cmova rdx, qword [rsp + 0x30]
mov r8, qword [rsp + 0x40]
mov rcx, rax
call fcn.1400046a0
mov rcx, rax
call fcn.140003b90
mov rcx, rsi
call qword [sym.imp.WS2_32.dll_closesocket]
mov rcx, qword [rbp + 0x1238]
call qword [sym.imp.WS2_32.dll_freeaddrinfo]
call qword [sym.imp.WS2_32.dll_WSACleanup]
lea r15, [rsp + 0x30]
mov rbx, qword [rsp + 0x30]
mov r13, qword [rsp + 0x48]
cmp r13, 0xf
cmova r15, rbx
mov rsi, qword [rsp + 0x40]
cmp rsi, 4
jb 0x140002f21
lea rdi, [rsi + r15]
lea r8, [rdi - 3]
sub r8, r15
mov edx, recv
mov rcx, r15
call fcn.1400224f0
test rax, rax
je 0x140002f21
nop dword [rax]
xor edx, edx
lea r8, str._r_n_r_n
nop dword [rax]
movzx ecx, byte [rax + rdx]
inc rdx
cmp cl, byte [r8 + rdx - 1]
jne 0x140002ef8
cmp rdx, 4
jne 0x140002ee0
xor ecx, ecx
jmp 0x140002efd
sbb ecx, ecx
or ecx, 1
test ecx, ecx
je 0x140002fdf
inc rax
lea r8, [rdi - 3]
sub r8, rax
mov edx, recv
mov rcx, rax
call fcn.1400224f0
test rax, rax
jne 0x140002ed0
xorps xmm0, xmm0
movups xmmword [r14], xmm0
mov qword [r14 + 0x10], 0
mov qword [r14 + 0x18], 0
mov qword [r14 + 0x10], 0
mov qword [r14 + 0x18], send
mov byte [r14], 0
cmp r13, 0xf
jbe 0x140002f83
lea rdx, [r13 + 1]
mov rax, rbx
cmp rdx, 0x1000
jb 0x140002f7b
add rdx, 0x27
mov rbx, qword [rbx - 8]
sub rax, rbx
add rax, 0xfffffffffffffff8
cmp rax, 0x1f
ja 0x1400031db
mov rcx, rbx
call fcn.1400073f0
mov qword [rsp + 0x40], 0
mov qword [rsp + 0x48], send
mov byte [rsp + 0x30], 0
mov rdx, qword [rsp + 0x68]
cmp rdx, 0xf
jbe 0x1400030c4
inc rdx
mov rcx, qword [rsp + 0x50]
mov rax, rcx
cmp rdx, 0x1000
jb 0x1400030bf
add rdx, 0x27
mov rcx, qword [rcx - 8]
sub rax, rcx
add rax, 0xfffffffffffffff8
cmp rax, 0x1f
ja 0x1400030ee
jmp 0x1400030bf
sub rax, r15
cmp rax, 0xffffffffffffffff
je 0x140002f21
lea rcx, [rax + 4]
xorps xmm0, xmm0
movups xmmword [r14], xmm0
mov qword [r14 + 0x10], 0
mov qword [r14 + 0x18], 0
cmp rsi, rcx
jb 0x1400030e8
sub rsi, rcx
cmp rsi, 0xffffffffffffffff
cmovb r12, rsi
lea rdx, [rsp + 0x30]
cmp r13, 0xf
cmova rdx, rbx
add rdx, rcx
mov r8, r12
mov rcx, r14
call fcn.1400018f0
nop
mov rdx, qword [rsp + 0x48]
cmp rdx, 0xf
jbe 0x140003074
inc rdx
mov rcx, qword [rsp + 0x30]
mov rax, rcx
cmp rdx, 0x1000
jb 0x14000306f
add rdx, 0x27
mov rcx, qword [rcx - 8]
sub rax, rcx
add rax, 0xfffffffffffffff8
cmp rax, 0x1f
ja 0x1400031db
call fcn.1400073f0
mov qword [rsp + 0x40], 0
mov qword [rsp + 0x48], send
mov byte [rsp + 0x30], 0
mov rdx, qword [rsp + 0x68]
cmp rdx, 0xf
jbe 0x1400030c4
inc rdx
mov rcx, qword [rsp + 0x50]
mov rax, rcx
cmp rdx, 0x1000
jb 0x1400030bf
add rdx, 0x27
mov rcx, qword [rcx - 8]
sub rax, rcx
add rax, 0xfffffffffffffff8
cmp rax, 0x1f
ja 0x1400030ee
call fcn.1400073f0
mov rax, r14
lea r11, [rsp + 0x12f0]
mov rbx, qword [r11 + 0x30]
mov rsi, qword [r11 + 0x38]
mov rdi, qword [r11 + 0x40]
mov rsp, r11
pop r15
pop r14
pop r13
pop r12
pop rbp
ret
call fcn.1400038c0
nop
call fcn.14000e0b4
int3
lea rdx, str.WSAStartup_failed
lea rcx, [0x1400344f0]
call fcn.1400038e0
mov rcx, rax
call fcn.1400037f0
mov ecx, 1
call fcn.14000e434
int3
lea rdx, str.Socket_creation_failed
lea rcx, [0x1400344f0]
call fcn.1400038e0
mov rcx, rax
call fcn.1400037f0
call qword [sym.imp.WS2_32.dll_WSACleanup]
mov ecx, 1
call fcn.14000e434
int3
lea rdx, str.Failed_to_get_address_info
lea rcx, [0x1400344f0]
call fcn.1400038e0
mov rcx, rax
call fcn.1400037f0
mov rcx, rsi
call qword [sym.imp.WS2_32.dll_closesocket]
call qword [sym.imp.WS2_32.dll_WSACleanup]
mov ecx, 1
call fcn.14000e434
int3
lea rdx, str.Connection_failed
lea rcx, [0x1400344f0]
call fcn.1400038e0
mov rcx, rax
call fcn.1400037f0
mov rcx, rsi
call qword [sym.imp.WS2_32.dll_closesocket]
mov rcx, qword [rbp + 0x1238]
call qword [sym.imp.WS2_32.dll_freeaddrinfo]
call qword [sym.imp.WS2_32.dll_WSACleanup]
mov ecx, 1
call fcn.14000e434
nop
call fcn.14000e0b4
nop
call fcn.14000e0b4
nop
call fcn.14000e0b4
nop
call fcn.14000e0b4
nop
call fcn.14000e0b4
int3
call fcn.14000e0b4
int3