Function at 0x46da50
Capabilities:
Send data
Send data on socket
Send http request
Set socket configuration

Disassembly:
push r15
push r14
push r13
push r12
push rbp
push rdi
push rsi
push rbx
sub rsp, 0x28
test rcx, rcx
mov rsi, rcx
je 0x46dd74
mov eax, dword [rcx + 0x18c]
test ah, 0x20
jne 0x46dd31
test al, 8
mov byte [rsi + 0x170], 1
mov rbp, qword [rsi + 0x150]
je 0x46dd24
mov rcx, qword [rsi + 0xc8]
test rcx, rcx
je 0x46dd85
mov eax, dword [rsi + 0xf0]
test eax, eax
je 0x46db60
xor r13d, r13d
lea rdi, [0x004b52e7]
mov rbx, qword [sym.imp.WS2_32.dll_send]
mov r12, qword [sym.imp.WS2_32.dll_WSAGetLastError]
jmp 0x46daea
mov rcx, qword [rsi + 0xc8]
mov eax, dword [rsi + 0xf0]
add r13d, 1
cmp eax, r13d
jbe 0x46dc10
mov edx, r13d
mov rax, rdx
shl rax, 4
sub rax, rdx
shl rax, 5
add rcx, rax
mov byte [rcx + 0x170], 1
mov rcx, qword [rsi + 0xc8]
add rax, rcx
cmp qword [rax + 0x160], 0xffffffffffffffff
je 0x46dad7
xor r9d, r9d
mov rcx, qword [rax + 0x168]
mov r8d, 1
mov rdx, rdi
call rbx
test eax, eax
jg 0x46dad0
call r12
cmp eax, 0x2733
je 0x46dad0
lea r9, str.Failed_to_signal_shutdown_via_inter_thread_communication_channel.
mov r8d, 0x18c6
lea rdx, str.T:_Bin_prep_mhd_src_libmicrohttpd_0.9.55_src_microhttpd_daemon.c
mov rcx, qword [0x004cd150]
call qword [0x004cd158]
nop dword [rax]
call sub.msvcrt.dll_free
cmp rbp, 0xffffffffffffffff
je 0x46db7a
movzx eax, byte [rsi + 0x171]
test al, al
je 0x46dd41
mov rcx, qword [rsi + 0x160]
cmp rcx, 0xffffffffffffffff
je 0x46dbc6
mov rbx, qword [sym.imp.WS2_32.dll_closesocket]
call rbx
test eax, eax
mov rcx, qword [rsi + 0x168]
je 0x46dbc0
call rbx
lea r9, str.Failed_to_destroy_ITC._n
mov r8d, 0x1908
lea rdx, str.T:_Bin_prep_mhd_src_libmicrohttpd_0.9.55_src_microhttpd_daemon.c
mov rcx, qword [0x004cd150]
call qword [0x004cd158]
nop
call rbx
test eax, eax
jne 0x46db9d
mov rcx, qword [rsi + 0x1a0]
call sub.msvcrt.dll_free
mov rbx, qword [sym.imp.KERNEL32.dll_DeleteCriticalSection]
lea rcx, [rsi + 0x1a8]
call rbx
lea rcx, [rsi + 0x100]
call rbx
lea rcx, [rsi + 0x128]
call rbx
mov rcx, rsi
add rsp, 0x28
pop rbx
pop rsi
pop rdi
pop rbp
pop r12
pop r13
pop r14
pop r15
jmp sub.msvcrt.dll_free
test eax, eax
je 0x46db60
xor edi, edi
mov r13, qword [sym.imp.KERNEL32.dll_WaitForSingleObject]
mov r15, qword [sym.imp.KERNEL32.dll_CloseHandle]
mov r12, qword [sym.imp.WS2_32.dll_closesocket]
mov r14, qword [sym.imp.KERNEL32.dll_DeleteCriticalSection]
jmp 0x46dcb4
mov rax, qword [rsi + 0xc8]
mov rcx, qword [rax + rbx + 0xf8]
call r15
mov rax, rbx
add rax, qword [rsi + 0xc8]
mov rcx, qword [rax + 0x160]
cmp rcx, 0xffffffffffffffff
je 0x46dc94
call r12
test eax, eax
mov rax, qword [rsi + 0xc8]
mov rcx, qword [rax + rbx + 0x168]
jne 0x46dd00
call r12
test eax, eax
jne 0x46dd03
mov rax, rbx
add rax, qword [rsi + 0xc8]
lea rcx, [rax + 0x128]
add edi, 1
call r14
cmp dword [rsi + 0xf0], edi
mov rcx, qword [rsi + 0xc8]
jbe 0x46db60
mov eax, edi
mov edx, 0xffffffff
mov rbx, rax
shl rbx, 4
sub rbx, rax
shl rbx, 5
mov rcx, qword [rcx + rbx + 0xf8]
call r13
test eax, eax
je 0x46dc40
lea r9, str.Failed_to_join_a_thread_n
mov r8d, 0x18d6
lea rdx, str.T:_Bin_prep_mhd_src_libmicrohttpd_0.9.55_src_microhttpd_daemon.c
mov rcx, qword [0x004cd150]
call qword [0x004cd158]
nop dword [rax]
call r12
lea r9, str.Failed_to_destroy_ITC._n
mov r8d, 0x18e0
lea rdx, str.T:_Bin_prep_mhd_src_libmicrohttpd_0.9.55_src_microhttpd_daemon.c
mov rcx, qword [0x004cd150]
call qword [0x004cd158]
mov rcx, rsi
call fcn.0046a7f0
jmp 0x46db65
call fcn.00469980
mov eax, dword [rsi + 0x18c]
jmp 0x46da7b
mov rcx, rbp
call qword [sym.imp.WS2_32.dll_closesocket]
test eax, eax
je 0x46db7a
lea r9, str.Close_socket_failed._n
mov r8d, 0x1905
lea rdx, str.T:_Bin_prep_mhd_src_libmicrohttpd_0.9.55_src_microhttpd_daemon.c
mov rcx, qword [0x004cd150]
call qword [0x004cd158]
nop
add rsp, 0x28
pop rbx
pop rsi
pop rdi
pop rbp
pop r12
pop r13
pop r14
pop r15
ret
cmp qword [rsi + 0x160], 0xffffffffffffffff
je 0x46ddb0
xor r9d, r9d
mov rcx, qword [rsi + 0x168]
mov r8d, 1
lea rdx, [0x004b52e7]
call qword [sym.imp.WS2_32.dll_send]
test eax, eax
jle 0x46ddf9
mov rcx, qword [rsi + 0xf8]
mov edx, 0xffffffff
call qword [sym.imp.KERNEL32.dll_WaitForSingleObject]
test eax, eax
je 0x46dde7
lea r9, str.Failed_to_join_a_thread_n
mov r8d, 0x18f9
lea rdx, str.T:_Bin_prep_mhd_src_libmicrohttpd_0.9.55_src_microhttpd_daemon.c
mov rcx, qword [0x004cd150]
call qword [0x004cd158]
mov rcx, qword [rsi + 0xf8]
call qword [sym.imp.KERNEL32.dll_CloseHandle]
jmp 0x46db65
call qword [sym.imp.WS2_32.dll_WSAGetLastError]
cmp eax, 0x2733
je 0x46ddb0
lea r9, str.Failed_to_signal_shutdown_via_inter_thread_communication_channel
mov r8d, 0x18eb
lea rdx, str.T:_Bin_prep_mhd_src_libmicrohttpd_0.9.55_src_microhttpd_daemon.c
mov rcx, qword [0x004cd150]
call qword [0x004cd158]
nop
nop dword [rax + rax]