Function at 0x14006d700
Capabilities:
Connect socket
Initialize winsock library
Receive data
Receive data on socket
Send data
Send data on socket
Send http request
Send http request with host header
Set socket configuration

Disassembly:
mov qword [rsp + 0x10], rbx
mov qword [rsp + 0x18], rsi
push rbp
push rdi
push r12
push r14
push r15
lea rbp, [rsp - 0x1300]
mov eax, 0x1400
call fcn.14008b800
sub rsp, rax
mov rax, qword [0x1400b0010]
xor rax, rsp
mov qword [rbp + 0x12f0], rax
mov rbx, rcx
mov qword [rbp - 0x20], rcx
mov rcx, qword [rcx + 0x10]
movabs rdi, 0x7fffffffffffffff
mov rax, rdi
sub rax, rcx
cmp rax, 1
jb 0x14006deb8
mov rax, rbx
cmp qword [rbx + 0x18], 0x10
jb 0x14006d76a
mov rax, qword [rbx]
mov qword [rsp + 0x30], rcx
mov qword [rsp + 0x28], rax
mov qword [rsp + 0x20], 1
lea r9, [0x140099c10]
lea rcx, [rbp + 8]
call fcn.1400611d0
nop
mov ecx, 0x202
lea rdx, [rbp + 0x150]
call qword [sym.imp.WSOCK32.dll_WSAStartup]
xor r15d, r15d
test eax, eax
je 0x14006d7cf
lea rdx, str.Failed_to_initialize_Winsock
mov rcx, qword [sym.imp.MSVCP140.dll_class_std::basic_ostream_char__struct_std::char_traits_char___std::cerr]
call fcn.14006a690
mov rcx, rax
lea rdx, [0x14006dec0]
call qword [sym.imp.MSVCP140.dll_public:_class_std::basic_ostream_char__struct_std::char_traits_char______ptr64___cdecl_std::basic_ostream_char__struct_std::char_traits_char__::operator___class_std::basic_ostream_char__struct_std::char_traits_char______ptr64____cdecl___class_std::basic_ostream_char__struct_std::char_traits_char______ptr64_____ptr64]
jmp 0x14006dc02
xor r8d, r8d
lea edx, [r8 + 1]
mov r12d, 2
mov ecx, r12d
call qword [sym.imp.WSOCK32.dll_socket]
mov rsi, rax
cmp rax, 0xffffffffffffffff
jne 0x14006d81c
lea rdx, str.Failed_to_create_socket
mov rcx, qword [sym.imp.MSVCP140.dll_class_std::basic_ostream_char__struct_std::char_traits_char___std::cerr]
call fcn.14006a690
mov rcx, rax
lea rdx, [0x14006dec0]
call qword [sym.imp.MSVCP140.dll_public:_class_std::basic_ostream_char__struct_std::char_traits_char______ptr64___cdecl_std::basic_ostream_char__struct_std::char_traits_char__::operator___class_std::basic_ostream_char__struct_std::char_traits_char______ptr64____cdecl___class_std::basic_ostream_char__struct_std::char_traits_char______ptr64_____ptr64]
call qword [sym.imp.WSOCK32.dll_WSACleanup]
jmp 0x14006dc02
mov rcx, rsi
call fcn.14006c640
test al, al
jne 0x14006d83c
mov rcx, rsi
call qword [sym.imp.WSOCK32.dll_closesocket]
call qword [sym.imp.WSOCK32.dll_WSACleanup]
jmp 0x14006dc02
mov word [rbp + 0x28], r12w
mov ecx, 0x50
call qword [sym.imp.WSOCK32.dll_htons]
mov word [rbp + 0x2a], ax
lea rcx, str.1.117.225.11
call qword [sym.imp.WSOCK32.dll_inet_addr]
mov dword [rbp + 0x2c], eax
mov r8d, reloc.WSOCK32.dll_recv
lea rdx, [rbp + 0x28]
mov rcx, rsi
call qword [sym.imp.WSOCK32.dll_connect]
cmp eax, 0xffffffff
jne 0x14006d8af
lea rdx, str.Failed_to_connect_to_server
mov rcx, qword [sym.imp.MSVCP140.dll_class_std::basic_ostream_char__struct_std::char_traits_char___std::cerr]
call fcn.14006a690
mov rcx, rax
lea rdx, [0x14006dec0]
call qword [sym.imp.MSVCP140.dll_public:_class_std::basic_ostream_char__struct_std::char_traits_char______ptr64___cdecl_std::basic_ostream_char__struct_std::char_traits_char__::operator___class_std::basic_ostream_char__struct_std::char_traits_char______ptr64____cdecl___class_std::basic_ostream_char__struct_std::char_traits_char______ptr64_____ptr64]
mov rcx, rsi
call qword [sym.imp.WSOCK32.dll_closesocket]
call qword [sym.imp.WSOCK32.dll_WSACleanup]
jmp 0x14006dc02
mov qword [rsp + 0x60], r15
mov qword [rsp + 0x70], r15
mov qword [rsp + 0x78], setsockopt
mov byte [rsp + 0x60], r15b
mov r8d, recv
lea rdx, str.1.117.225.11
lea rcx, [rsp + 0x60]
call fcn.140055850
nop
mov rcx, qword [rbp + 0x18]
sub rdi, rcx
cmp rdi, 4
jb 0x14006deb2
lea rax, [rbp + 8]
cmp qword [rbp + 0x20], 0x10
cmovae rax, qword [rbp + 8]
mov qword [rsp + 0x30], rcx
mov qword [rsp + 0x28], rax
mov qword [rsp + 0x20], 4
lea r9, str.GET
lea rcx, [rbp - 0x60]
call fcn.1400611d0
nop
mov r8d, recv
lea rdx, str._HTTP_1.1_r_n
lea rcx, [rbp - 0x60]
call fcn.140060e70
mov qword [rsp + 0x40], r15
mov qword [rsp + 0x50], r15
mov qword [rsp + 0x58], r15
movups xmm0, xmmword [rax]
movups xmmword [rsp + 0x40], xmm0
movups xmm1, xmmword [rax + 0x10]
movups xmmword [rsp + 0x50], xmm1
mov qword [rax + 0x10], r15
mov qword [rax + 0x18], setsockopt
mov byte [rax], 0
mov r8d, 6
lea rdx, str.Host:
lea rcx, [rsp + 0x40]
call fcn.140060e70
movups xmm0, xmmword [rax]
movups xmmword [rbp - 0x40], xmm0
movups xmm1, xmmword [rax + 0x10]
movups xmmword [rbp - 0x30], xmm1
mov qword [rax + 0x10], r15
mov qword [rax + 0x18], setsockopt
mov byte [rax], 0
lea r9, [rsp + 0x60]
lea r8, [rbp - 0x40]
lea rcx, [rbp - 0x80]
call fcn.140066270
nop
mov r8d, 4
lea rdx, str._r_n_r_n
lea rcx, [rbp - 0x80]
call fcn.140060e70
mov qword [rbp - 0x18], r15
mov qword [rbp - 8], r15
mov qword [rbp], r15
movups xmm0, xmmword [rax]
movups xmmword [rbp - 0x18], xmm0
movups xmm1, xmmword [rax + 0x10]
movups xmmword [rbp - 8], xmm1
mov qword [rax + 0x10], r15
mov qword [rax + 0x18], setsockopt
mov byte [rax], 0
mov rdx, qword [rbp - 0x68]
cmp rdx, 0x10
jb 0x14006da2d
inc rdx
mov rcx, qword [rbp - 0x80]
mov rax, rcx
cmp rdx, 0x1000
jb 0x14006da28
add rdx, 0x27
mov rcx, qword [rcx - 8]
sub rax, rcx
add rax, 0xfffffffffffffff8
cmp rax, 0x1f
jbe 0x14006da28
call qword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll__invalid_parameter_noinfo_noreturn]
int3
call fcn.14008a88c
mov qword [rbp - 0x70], r15
mov qword [rbp - 0x68], setsockopt
mov byte [rbp - 0x80], 0
mov rdx, qword [rbp - 0x28]
cmp rdx, 0x10
jb 0x14006da7c
inc rdx
mov rcx, qword [rbp - 0x40]
mov rax, rcx
cmp rdx, 0x1000
jb 0x14006da76
add rdx, 0x27
mov rcx, qword [rcx - 8]
sub rax, rcx
add rax, 0xfffffffffffffff8
cmp rax, 0x1f
jbe 0x14006da76
call qword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll__invalid_parameter_noinfo_noreturn]
int3
call fcn.14008a88c
nop
mov rdx, qword [rsp + 0x58]
cmp rdx, 0x10
jb 0x14006dabc
inc rdx
mov rcx, qword [rsp + 0x40]
mov rax, rcx
cmp rdx, 0x1000
jb 0x14006dab7
add rdx, 0x27
mov rcx, qword [rcx - 8]
sub rax, rcx
add rax, 0xfffffffffffffff8
cmp rax, 0x1f
jbe 0x14006dab7
call qword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll__invalid_parameter_noinfo_noreturn]
int3
call fcn.14008a88c
mov qword [rsp + 0x50], r15
mov qword [rsp + 0x58], setsockopt
mov byte [rsp + 0x40], 0
mov rdx, qword [rbp - 0x48]
cmp rdx, 0x10
jb 0x14006db0d
inc rdx
mov rcx, qword [rbp - 0x60]
mov rax, rcx
cmp rdx, 0x1000
jb 0x14006db08
add rdx, 0x27
mov rcx, qword [rcx - 8]
sub rax, rcx
add rax, 0xfffffffffffffff8
cmp rax, 0x1f
jbe 0x14006db08
call qword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll__invalid_parameter_noinfo_noreturn]
int3
call fcn.14008a88c
mov qword [rbp - 0x50], r15
mov qword [rbp - 0x48], setsockopt
mov byte [rbp - 0x60], 0
mov rdx, qword [rsp + 0x78]
cmp rdx, 0x10
jb 0x14006db5d
inc rdx
mov rcx, qword [rsp + 0x60]
mov rax, rcx
cmp rdx, 0x1000
jb 0x14006db58
add rdx, 0x27
mov rcx, qword [rcx - 8]
sub rax, rcx
add rax, 0xfffffffffffffff8
cmp rax, 0x1f
jbe 0x14006db58
call qword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll__invalid_parameter_noinfo_noreturn]
int3
call fcn.14008a88c
lea rdx, [rbp - 0x18]
cmp qword [rbp], 0x10
cmovae rdx, qword [rbp - 0x18]
xor r9d, r9d
mov r8d, dword [rbp - 8]
mov rcx, rsi
call qword [sym.imp.WSOCK32.dll_send]
cmp eax, 0xffffffff
jne 0x14006dc7f
lea rdx, str.Failed_to_send_request
mov rcx, qword [sym.imp.MSVCP140.dll_class_std::basic_ostream_char__struct_std::char_traits_char___std::cerr]
call fcn.14006a690
mov rcx, rax
lea rdx, [0x14006dec0]
call qword [sym.imp.MSVCP140.dll_public:_class_std::basic_ostream_char__struct_std::char_traits_char______ptr64___cdecl_std::basic_ostream_char__struct_std::char_traits_char__::operator___class_std::basic_ostream_char__struct_std::char_traits_char______ptr64____cdecl___class_std::basic_ostream_char__struct_std::char_traits_char______ptr64_____ptr64]
mov rcx, rsi
call qword [sym.imp.WSOCK32.dll_closesocket]
call qword [sym.imp.WSOCK32.dll_WSACleanup]
nop
mov rdx, qword [rbp]
cmp rdx, 0x10
jb 0x14006dbf2
inc rdx
mov rcx, qword [rbp - 0x18]
mov rax, rcx
cmp rdx, 0x1000
jb 0x14006dbed
add rdx, 0x27
mov rcx, qword [rcx - 8]
sub rax, rcx
add rax, 0xfffffffffffffff8
cmp rax, 0x1f
ja 0x14006ddde
call fcn.14008a88c
mov qword [rbp - 8], r15
mov qword [rbp], setsockopt
mov byte [rbp - 0x18], 0
mov rdx, qword [rbp + 0x20]
cmp rdx, 0x10
jb 0x14006dc3e
mov rcx, qword [rbp + 8]
inc rdx
mov rax, rcx
cmp rdx, 0x1000
jb 0x14006dc38
mov rcx, qword [rcx - 8]
sub rax, rcx
add rdx, 0x27
add rax, 0xfffffffffffffff8
cmp rax, 0x1f
ja 0x14006de2c
call fcn.14008a88c
nop
mov rdx, qword [rbx + 0x18]
cmp rdx, 0x10
jb 0x14006dc78
inc rdx
mov rcx, qword [rbx]
cmp rdx, 0x1000
jb 0x14006dc73
mov r8, qword [rcx - 8]
sub rcx, r8
add rdx, 0x27
lea rax, [rcx - 8]
cmp rax, 0x1f
ja 0x14006deab
mov rcx, r8
call fcn.14008a88c
xor al, al
jmp 0x14006de71
xor edx, edx
mov r8d, 0x108
lea rcx, [rbp + 0x40]
call sub.VCRUNTIME140.dll_memset
mov r8d, 0x22
mov rdx, rbx
lea rcx, [rbp + 0x40]
call fcn.14006a290
nop
xor r14b, r14b
xor r9d, r9d
mov r8d, 0x1000
lea rdx, [rbp + 0x2f0]
mov rcx, rsi
call qword [sym.imp.WSOCK32.dll_recv]
mov edi, eax
test eax, eax
jle 0x14006dd2c
test r14b, r14b
jne 0x14006dcf9
lea rdx, str._r_n_r_n
lea rcx, [rbp + 0x2f0]
call qword [sym.imp.VCRUNTIME140.dll_strstr]
test rax, rax
je 0x14006dd0d
mov r14b, 1
mov ecx, edi
sub rcx, rax
lea r8, [rbp + rcx + 0x2ec]
lea rdx, [rax + 4]
jmp 0x14006dd03
mov r8d, edi
lea rdx, [rbp + 0x2f0]
lea rcx, [rbp + 0x40]
call qword [sym.imp.MSVCP140.dll_public:_class_std::basic_ostream_char__struct_std::char_traits_char______ptr64___cdecl_std::basic_ostream_char__struct_std::char_traits_char__::write_char_const____ptr64__long_long___int64_____ptr64]
xor r9d, r9d
mov r8d, 0x1000
lea rdx, [rbp + 0x2f0]
mov rcx, rsi
call qword [sym.imp.WSOCK32.dll_recv]
mov edi, eax
test eax, eax
jg 0x14006dcc5
lea rcx, [rbp + 0x48]
call fcn.1400555a0
test rax, rax
jne 0x14006dd55
mov rax, qword [rbp + 0x40]
movsxd rcx, dword [rax + 4]
lea rax, [rbp + 0x40]
add rcx, rax
xor r8d, r8d
mov edx, r12d
call qword [sym.imp.MSVCP140.dll_public:_void___cdecl_std::basic_ios_char__struct_std::char_traits_char__::setstate_int__bool____ptr64]
mov rcx, rsi
call qword [sym.imp.WSOCK32.dll_closesocket]
call qword [sym.imp.WSOCK32.dll_WSACleanup]
nop
mov rax, qword [rbp + 0x40]
movsxd rcx, dword [rax + 4]
lea rax, vtable.std::basic_ofstream_char__struct_std::char_traits_char__.0
mov qword [rbp + rcx + 0x40], rax
mov rax, qword [rbp + 0x40]
movsxd rcx, dword [rax + 4]
lea edx, [rcx - 0xa8]
mov dword [rbp + rcx + 0x3c], edx
lea rcx, [rbp + 0x48]
call fcn.140054e80
lea rcx, [rbp + 0x50]
call qword [sym.imp.MSVCP140.dll_public_virtual:_void___cdecl_std::basic_ostream_char__struct_std::char_traits_char__::destructor_void____ptr64]
lea rcx, [rbp + 0xe8]
call qword [sym.imp.MSVCP140.dll_public_virtual:_void___cdecl_std::basic_ios_char__struct_std::char_traits_char__::destructor_void____ptr64]
nop
mov rdx, qword [rbp]
cmp rdx, 0x10
jb 0x14006ddea
inc rdx
mov rcx, qword [rbp - 0x18]
mov rax, rcx
cmp rdx, 0x1000
jb 0x14006dde5
add rdx, 0x27
mov rcx, qword [rcx - 8]
sub rax, rcx
add rax, 0xfffffffffffffff8
cmp rax, 0x1f
jbe 0x14006dde5
call qword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll__invalid_parameter_noinfo_noreturn]
int3
call fcn.14008a88c
mov qword [rbp - 8], r15
mov qword [rbp], setsockopt
mov byte [rbp - 0x18], 0
mov rdx, qword [rbp + 0x20]
cmp rdx, 0x10
jb 0x14006de39
inc rdx
mov rcx, qword [rbp + 8]
mov rax, rcx
cmp rdx, 0x1000
jb 0x14006de33
add rdx, 0x27
mov rcx, qword [rcx - 8]
sub rax, rcx
add rax, 0xfffffffffffffff8
cmp rax, 0x1f
jbe 0x14006de33
call qword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll__invalid_parameter_noinfo_noreturn]
int3
call fcn.14008a88c
nop
mov rdx, qword [rbx + 0x18]
cmp rdx, 0x10
jb 0x14006de6f
inc rdx
mov rcx, qword [rbx]
cmp rdx, 0x1000
jb 0x14006de6a
add rdx, 0x27
mov r8, qword [rcx - 8]
sub rcx, r8
lea rax, [rcx - 8]
cmp rax, 0x1f
ja 0x14006deab
mov rcx, r8
call fcn.14008a88c
mov al, 1
mov qword [rbx + 0x10], r15
mov qword [rbx + 0x18], setsockopt
mov byte [rbx], 0
mov rcx, qword [rbp + 0x12f0]
xor rcx, rsp
call fcn.14008a4a0
lea r11, [rsp + 0x1400]
mov rbx, qword [r11 + 0x38]
mov rsi, qword [r11 + 0x40]
mov rsp, r11
pop r15
pop r14
pop r12
pop rdi
pop rbp
ret
call qword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll__invalid_parameter_noinfo_noreturn]
nop
call fcn.140005e10
nop
call fcn.140005e10
int3