Function at 0x140005430
Capabilities:
Connect socket
Get socket status
Receive data
Receive data on socket
Send data
Send data on socket
Send http request

Disassembly:
push rbp
push rbx
push rdi
push r14
push r15
lea rbp, [rsp - 0x5a0]
sub rsp, 0x6a0
mov rax, qword [0x1400086c8]
xor rax, rsp
mov qword [rbp + 0x580], rax
movzx r15d, r8w
mov r14d, edx
mov rbx, rcx
call fcn.140003fb0
mov edi, eax
cmp eax, 0xffffffff
jne 0x14000547a
mov rax, 0xffffffffffffffff
jmp 0x1400057bd
xor r8d, r8d
mov qword [rsp + 0x6e8], rsi
mov qword [rsp + 0x690], r13
mov r13d, 2
mov ecx, r13d
lea edx, [r8 + 1]
call qword [sym.imp.WS2_32.dll_socket]
mov rsi, rax
cmp rax, 0xffffffffffffffff
jne 0x1400054b4
call qword [sym.imp.WS2_32.dll_WSAGetLastError]
jmp 0x1400057a6
movzx ecx, word [rbx + 0x30]
mov dword [rsp + 0x54], edi
call qword [sym.imp.WS2_32.dll_htons]
mov r8d, reloc.WS2_32.dll_recv
mov word [rsp + 0x50], r13w
lea rdx, [rsp + 0x50]
mov word [rsp + 0x52], ax
mov rcx, rsi
call qword [sym.imp.WS2_32.dll_connect]
test eax, eax
jne 0x140005797
mov ecx, r14d
call qword [sym.imp.WS2_32.dll_inet_ntoa]
mov r9d, r15d
lea rdx, [0x1400013a8]
mov r8, rax
lea rcx, [rbp + 0x380]
call qword [sym.imp.USER32.dll_wsprintfA]
lea rcx, [rbp + 0x380]
call qword [sym.imp.KERNEL32.dll_lstrlenA]
xor r9d, r9d
lea rdx, [rbp + 0x380]
mov r8d, eax
mov rcx, rsi
call qword [sym.imp.WS2_32.dll_send]
cmp eax, 0xffffffff
je 0x140005797
xor r14d, r14d
mov qword [rsp + 0x698], r12
mov r12d, r14d
mov dword [rsp + 0x40], r14d
mov edi, r14d
nop
lea rax, [rsp + 0x48]
mov dword [rsp + 0x48], r14d
lea r9, [rsp + 0x60]
mov qword [rsp + 0x20], rax
xor r8d, r8d
mov dword [rsp + 0x4c], 0x2710
lea rdx, [rbp + 0x170]
mov qword [rbp + 0x178], rsi
xor ecx, ecx
mov dword [rbp + 0x170], 1
mov qword [rsp + 0x68], rsi
mov dword [rsp + 0x60], 1
call qword [sym.imp.WS2_32.dll_select]
cmp eax, 0xffffffff
je 0x14000576c
test eax, eax
jle 0x140005699
lea rdx, [rsp + 0x60]
mov rcx, rsi
call sub.WS2_32.dll___WSAFDIsSet
test eax, eax
jne 0x140005772
lea rdx, [rbp + 0x170]
mov rcx, rsi
call sub.WS2_32.dll___WSAFDIsSet
test eax, eax
je 0x140005699
xor edx, edx
lea rcx, [rbp + 0x380]
mov r8d, 0x200
call fcn.140005f00
xor r9d, r9d
lea rdx, [rbp + 0x380]
mov r8d, 0x1ff
mov rcx, rsi
call qword [sym.imp.WS2_32.dll_recv]
movsxd r14, eax
cmp r14d, 0xffffffff
je 0x14000576c
test eax, eax
je 0x140005772
lea r15d, [rdi + r14]
cmp r15d, 0x200
jge 0x140005772
lea r13d, [r15 + 1]
mov ecx, 0x40
mov edx, r13d
call qword [sym.imp.KERNEL32.dll_LocalAlloc]
mov rbx, rax
test rax, rax
je 0x140005764
movsxd r8, r13d
xor edx, edx
mov rcx, rax
call fcn.140005f00
test edi, edi
jle 0x140005677
test r12, r12
je 0x140005677
movsxd r8, edi
mov rdx, r12
mov rcx, rbx
call fcn.140005ed0
mov rcx, r12
call qword [sym.imp.KERNEL32.dll_LocalFree]
movsxd rcx, edi
lea rdx, [rbp + 0x380]
add rcx, rbx
mov r8, r14
call fcn.140005ed0
xor r14d, r14d
mov r12, rbx
mov edi, r15d
lea r13d, [r14 + 2]
cmp edi, 4
jle 0x140005550
movsxd rbx, edi
lea rcx, [r12 - 4]
add rcx, rbx
lea rdx, [0x1400013c4]
mov r8d, 4
call qword [sym.imp.SHLWAPI.dll_StrCmpNA]
test eax, eax
je 0x1400056e4
lea rcx, [r12 - 2]
mov r8d, r13d
add rcx, rbx
lea rdx, [0x1400013cc]
call qword [sym.imp.SHLWAPI.dll_StrCmpNA]
test eax, eax
jne 0x140005550
lea r9, [rsp + 0x30]
mov qword [rsp + 0x30], r14
xor r8d, r8d
mov dl, 0xa
mov rcx, r12
call fcn.140005de0
test eax, eax
je 0x140005772
mov rcx, qword [rsp + 0x30]
mov dl, 0x20
call fcn.140005d50
cmp eax, 2
jle 0x140005757
mov rcx, qword [rsp + 0x30]
lea r9, [rsp + 0x38]
mov r8d, 1
mov qword [rsp + 0x38], r14
mov dl, 0x20
call fcn.140005de0
test eax, eax
je 0x140005757
mov rcx, qword [rsp + 0x38]
lea r8, [rsp + 0x40]
xor edx, edx
call qword [sym.imp.SHLWAPI.dll_StrToIntExA]
test eax, eax
jne 0x14000574c
call qword [sym.imp.KERNEL32.dll_GetLastError]
mov rcx, qword [rsp + 0x38]
call qword [sym.imp.KERNEL32.dll_LocalFree]
mov rcx, qword [rsp + 0x30]
call qword [sym.imp.KERNEL32.dll_LocalFree]
jmp 0x140005772
call qword [sym.imp.KERNEL32.dll_GetLastError]
jmp 0x140005772
call qword [sym.imp.WS2_32.dll_WSAGetLastError]
test r12, r12
je 0x140005780
mov rcx, r12
call qword [sym.imp.KERNEL32.dll_LocalFree]
cmp dword [rsp + 0x40], 0xc8
mov r12, qword [rsp + 0x698]
jne 0x14000579d
mov rax, rsi
jmp 0x1400057ad
call qword [sym.imp.WS2_32.dll_WSAGetLastError]
mov rcx, rsi
call qword [sym.imp.WS2_32.dll_closesocket]
mov rax, 0xffffffffffffffff
mov rsi, qword [rsp + 0x6e8]
mov r13, qword [rsp + 0x690]
mov rcx, qword [rbp + 0x580]
xor rcx, rsp
call fcn.140005fc0
add rsp, 0x6a0
pop r15
pop r14
pop rdi
pop rbx
pop rbp
ret