Function at 0x14003f790
Capabilities:
Receive data
Receive data on socket
Send data
Send data on socket

Disassembly:
push rbp
push rbx
push rdi
lea rbp, [rsp - 0x4080]
mov eax, 0x4180
call fcn.140111910
sub rsp, rax
mov rax, qword [0x14017f8e0]
xor rax, rsp
mov qword [rbp + 0x4060], rax
movzx ebx, word [0x14017f98c]
mov rdi, qword [0x140190360]
test bx, bx
jne 0x14003f7eb
cmp byte [0x140190372], bl
je 0x14003f7eb
lea rdx, str.API_disabled
mov ecx, 4
call fcn.140033450
jmp 0x14003febc
mov qword [rsp + 0x41a8], r12
lea r12, str.___API_will_not_be_available
mov qword [rsp + 0x4170], r15
test rdi, rdi
je 0x14003f829
call fcn.14003f420
cmp dword [reloc.WS2_32.dll_accept], 0
jne 0x14003f829
mov r8, r12
lea rdx, str.API_not_running__no_valid_IPs_specified__s
mov ecx, 1
call fcn.140033450
mov edx, 8
lea ecx, [rdx - 7]
call qword [sym.imp.api_ms_win_crt_heap_l1_1_0.dll_calloc]
mov r15, rax
test rax, rax
je 0x14003fed6
mov ecx, 0x3e8
mov qword [rsp + 0x41a0], rsi
mov qword [rax], 0xffffffffffffffff
call qword [sym.imp.KERNEL32.dll_Sleep]
xor r8d, r8d
mov esi, 2
mov ecx, esi
lea edx, [r8 + 1]
call qword [sym.imp.WS2_32.dll_socket]
mov qword [r15], rax
cmp rax, 0xffffffffffffffff
jne 0x14003f8a1
call qword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll__errno]
mov ecx, dword [rax]
call qword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll_strerror]
mov r9, r12
lea rdx, str.API_initialisation_failed___s__s
mov r8, rax
xor ecx, ecx
call fcn.140033450
jmp 0x14003fea4
xor eax, eax
mov rcx, rdi
mov qword [rsp + 0x38], rax
mov word [rsp + 0x38], si
mov qword [rsp + 0x40], rax
call qword [sym.imp.WS2_32.dll_inet_addr]
mov dword [rsp + 0x3c], eax
cmp eax, 0xffffffff
jne 0x14003f8eb
call qword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll__errno]
mov ecx, dword [rax]
call qword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll_strerror]
mov r9, r12
lea rdx, str.API_initialisation_2_failed___s__s
mov r8, rax
xor ecx, ecx
call fcn.140033450
jmp 0x14003fea4
movzx ecx, bx
mov qword [rsp + 0x4178], r14
call qword [sym.imp.WS2_32.dll_htons]
xor ecx, ecx
mov word [rsp + 0x3a], ax
call qword [sym.imp.api_ms_win_crt_time_l1_1_0.dll__time64]
mov rsi, rax
mov r14d, 0xfe4
mov rcx, qword [r15]
lea rdx, [rsp + 0x38]
mov r8d, reloc.WS2_32.dll_recv
call qword [sym.imp.WS2_32.dll_bind]
test eax, eax
jns 0x14003fa03
call qword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll__errno]
mov ecx, dword [rax]
call qword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll_strerror]
xor ecx, ecx
mov rdi, rax
call qword [sym.imp.api_ms_win_crt_time_l1_1_0.dll__time64]
sub rax, rsi
cmp rax, 0x3d
jg 0x14003f9d8
cmp word [0x14017f98c], r14w
jne 0x14003f9a1
cmp byte [0x140190372], 0
je 0x14003f980
movzx r8d, bx
lea rdx, str.API_bind_to_port__d_failed__trying_port__u
mov ecx, 4
lea r9d, [r8 + 1]
call fcn.140033450
inc bx
movzx ecx, bx
call qword [sym.imp.WS2_32.dll_htons]
mov ecx, 0x3e8
mov word [rsp + 0x3a], ax
call qword [sym.imp.KERNEL32.dll_Sleep]
jmp 0x14003f912
cmp byte [0x1401905c8], 0
je 0x14003f9b3
cmp byte [0x140190372], 0
je 0x14003f9c8
movzx r8d, bx
lea rdx, str.API_bind_to_port__u_failed___trying_again_in_20sec
mov ecx, 1
call fcn.140033450
mov ecx, 0x4e20
call qword [sym.imp.KERNEL32.dll_Sleep]
jmp 0x14003f912
movzx r8d, bx
lea rdx, str.API_bind_to_port__d_failed___s__s
mov r9, rdi
mov qword [rsp + 0x20], r12
mov ecx, 1
call fcn.140033450
mov rcx, r15
call qword [sym.imp.api_ms_win_crt_heap_l1_1_0.dll_free]
jmp 0x14003fe9c
movzx eax, word [0x14017f98c]
cmp ax, bx
je 0x14003fa2f
movzx r9d, bx
lea rdx, str.API_bind_to_port__d_failed___using_port__u
movzx r8d, ax
mov ecx, 1
call fcn.140033450
mov word [0x14017f98c], bx
mov rcx, qword [r15]
mov edx, 0xa
call qword [sym.imp.WS2_32.dll_listen]
cmp eax, 0xffffffff
jne 0x14003fa7b
call qword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll__errno]
mov ecx, dword [rax]
call qword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll_strerror]
mov r9, r12
lea rdx, str.API_initialisation_3_failed___s__s
mov r8, rax
xor ecx, ecx
call fcn.140033450
mov rcx, qword [r15]
call qword [sym.imp.WS2_32.dll_closesocket]
mov rcx, r15
call qword [sym.imp.api_ms_win_crt_heap_l1_1_0.dll_free]
jmp 0x14003fe9c
mov edx, 0x4001
mov ecx, 1
call qword [sym.imp.api_ms_win_crt_heap_l1_1_0.dll_calloc]
mov qword [0x140190ab0], rax
test rax, rax
je 0x14003feef
cmp dword [0x140190ab8], 0
mov qword [rsp + 0x41b0], r13
jne 0x14003fe75
lea r14, str.Accepted
lea r13, str.summary
nop
mov dword [rsp + 0x30], reloc.WS2_32.dll_recv
lea r8, [rsp + 0x30]
mov rcx, qword [r15]
lea rdx, [rsp + 0x48]
call qword [sym.imp.WS2_32.dll_accept]
mov rsi, rax
cmp eax, 0xffffffff
je 0x14003fe4a
mov ecx, dword [rsp + 0x4c]
xor bl, bl
call qword [sym.imp.WS2_32.dll_inet_ntoa]
mov ecx, 0x52
mov rdi, rax
call qword [sym.imp.api_ms_win_crt_string_l1_1_0.dll_toupper]
cmp qword [0x140190360], 0
je 0x14003fb4b
mov ecx, dword [rsp + 0x4c]
call qword [sym.imp.WS2_32.dll_htonl]
mov r9d, dword [reloc.WS2_32.dll_accept]
xor r8d, r8d
test r9d, r9d
jle 0x14003fb5f
mov rdx, qword [0x1401909d0]
nop dword [rax + rax]
mov ecx, dword [rdx + 4]
and ecx, eax
cmp ecx, dword [rdx]
je 0x14003fb47
inc r8d
add rdx, 0xc
cmp r8d, r9d
jl 0x14003fb30
jmp 0x14003fb5f
mov bl, 1
jmp 0x14003fb5f
lea rdx, str.127.0.0.1
mov rcx, rdi
call sub.api_ms_win_crt_string_l1_1_0.dll_strcmp
test eax, eax
sete bl
cmp byte [0x140190372], 0
je 0x14003fb92
cmp byte [0x140190371], 0
je 0x14003fb92
test bl, bl
lea r9, str.Ignored
mov r8, rdi
lea rdx, str.API:_connection_from__s____s
cmovne r9, r14
mov ecx, 4
call fcn.140033450
test bl, bl
je 0x14003fe3b
movsxd rsi, esi
lea rdx, [rbp + 0x60]
mov rcx, rsi
xor r9d, r9d
mov r8d, 0x400
xor r14d, r14d
call qword [sym.imp.WS2_32.dll_recv]
cmp eax, 0xffffffff
mov edi, eax
sete dl
test dl, dl
je 0x14003fbc8
mov byte [rbp + 0x60], r14b
jmp 0x14003fc0f
test eax, eax
jle 0x14003fc0f
lea ecx, [rax - 1]
movsxd rax, ecx
cmp byte [rbp + rax + 0x60], 0xa
jne 0x14003fc0f
cmp rax, 0x4000
jae 0x14003ff0e
mov byte [rbp + rax + 0x60], r14b
mov edi, ecx
test ecx, ecx
jle 0x14003fc0f
lea eax, [rcx - 1]
movsxd rcx, eax
cmp byte [rbp + rcx + 0x60], 0xd
jne 0x14003fc0f
cmp rcx, 0x4000
jae 0x14003ff08
mov byte [rbp + rcx + 0x60], r14b
movsxd rax, edi
cmp rax, 0x4000
jae 0x14003ff14
mov byte [rbp + rax + 0x60], r14b
test dl, dl
jne 0x14003fe34
lea rdx, str.GET__
lea rcx, [rbp + 0x60]
call qword [sym.imp.VCRUNTIME140.dll_strstr]
mov rbx, rax
test rax, rax
je 0x14003fd20
or rcx, 0xffffffffffffffff
nop dword [rax]
inc rcx
cmp byte [rax + rcx], r14b
jne 0x14003fc50
cmp rcx, 5
jbe 0x14003fd20
xor edx, edx
lea rcx, [rsp + 0x60]
mov r8d, 0x100
call sub.VCRUNTIME140.dll_memset
lea rcx, [rbx + 5]
lea r8, [rsp + 0x60]
lea rdx, [0x14016fd18]
call fcn.14003e320
mov edx, Ordinal_50
lea rcx, [rsp + 0x60]
call qword [sym.imp.VCRUNTIME140.dll_strchr]
test rax, rax
je 0x14003fca2
mov byte [rax], 0x7c
mov edx, Ordinal_50
lea rcx, [rsp + 0x60]
call qword [sym.imp.VCRUNTIME140.dll_strchr]
test rax, rax
je 0x14003fcba
mov byte [rax], r14b
lea rdx, str.Sec_WebSocket_Key
mov rcx, rbx
call qword [sym.imp.VCRUNTIME140.dll_strstr]
mov r14, rax
test rax, rax
je 0x14003fd09
mov edx, reloc.WS2_32.dll_listen
mov rcx, rax
call qword [sym.imp.VCRUNTIME140.dll_strchr]
test rax, rax
je 0x14003fce8
mov byte [rax], 0
mov edx, Ordinal_60
mov rcx, r14
call qword [sym.imp.VCRUNTIME140.dll_strchr]
cmp byte [rax + 1], 0x20
lea r14, [rax + 1]
jne 0x14003fd09
inc r14
cmp byte [r14], 0x20
je 0x14003fd00
lea r8, [rsp + 0x60]
lea rdx, [0x14016d034]
lea rcx, [rbp + 0x60]
call fcn.140029280
mov edi, eax
mov edx, 0x7c
lea rcx, [rbp + 0x60]
call qword [sym.imp.VCRUNTIME140.dll_strchr]
mov rbx, rax
test rax, rax
je 0x14003fd3d
mov byte [rax], 0
inc rbx
cmp byte [0x140190372], 0
je 0x14003fd76
cmp byte [0x140190371], 0
je 0x14003fd76
test edi, edi
jle 0x14003fd76
test rbx, rbx
lea r9, [0x14012d6f2]
lea r8, [rbp + 0x60]
mov ecx, 4
cmovne r9, rbx
lea rdx, str.API:_exec_command__s__s_
call fcn.140033450
xor r10d, r10d
mov r9, r13
xor r11d, r11d
nop
mov r8, qword [r9]
lea rax, [rbp + 0x60]
sub r8, rax
nop word [rax + rax]
movzx edx, byte [rax]
movzx ecx, byte [rax + r8]
sub edx, ecx
jne 0x14003fda3
inc rax
test ecx, ecx
jne 0x14003fd90
test edx, edx
jne 0x14003fdbe
lea rcx, [rbp + 0x60]
or rax, 0xffffffffffffffff
nop
inc rax
cmp byte [rcx + rax], 0
jne 0x14003fdb0
test rax, rax
jne 0x14003fdd0
inc r10d
inc r11
add r9, 0x10
cmp r10d, 8
jb 0x14003fd80
jmp 0x14003fe2b
add r11, r11
mov rcx, rbx
call qword [r13 + r11*reloc.WS2_32.dll_htonl + 8]
mov rdx, rax
test r14, r14
je 0x14003fdf0
mov r8, r14
mov rcx, rsi
call fcn.14003f1a0
jmp 0x14003fe2b
test rdx, rdx
jne 0x14003fe02
lea r8d, [rdx + 1]
lea rdx, [0x14012d6f2]
jmp 0x14003fe1f
or rax, 0xffffffffffffffff
nop word [rax + rax]
cmp byte [rdx + rax + 1], 0
lea rax, [rax + 1]
jne 0x14003fe10
lea r8d, [rax + 1]
xor r9d, r9d
mov rcx, rsi
call qword [sym.imp.WS2_32.dll_send]
mov rcx, rsi
call qword [sym.imp.WS2_32.dll_closesocket]
lea r14, str.Accepted
cmp dword [0x140190ab8], 0
je 0x14003fac0
jmp 0x14003fe75
cmp byte [0x140190370], 0
jne 0x14003fe75
call qword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll__errno]
mov ecx, dword [rax]
call qword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll_strerror]
mov r9, r12
lea rdx, str.API_failed___s__s
mov r8, rax
xor ecx, ecx
call fcn.140033450
mov rcx, qword [r15]
call qword [sym.imp.WS2_32.dll_closesocket]
mov rcx, r15
call qword [sym.imp.api_ms_win_crt_heap_l1_1_0.dll_free]
mov rcx, qword [0x140190ab0]
call qword [sym.imp.api_ms_win_crt_heap_l1_1_0.dll_free]
mov r13, qword [rsp + 0x41b0]
mov r14, qword [rsp + 0x4178]
mov rsi, qword [rsp + 0x41a0]
mov r12, qword [rsp + 0x41a8]
mov r15, qword [rsp + 0x4170]
mov rcx, qword [rbp + 0x4060]
xor rcx, rsp
call fcn.140111120
add rsp, 0x4180
pop rdi
pop rbx
pop rbp
ret
lea rdx, str.Out_of_memory_
xor ecx, ecx
call fcn.140033450
mov ecx, 1
call fcn.1400293c0
int3
lea rdx, str.Out_of_memory_
xor ecx, ecx
call fcn.140033450
mov ecx, 1
call fcn.1400293c0
int3
call fcn.140110efc
int3
call fcn.140110efc
int3
call fcn.140110efc
int3