Function at 0x140012810
Capabilities:
Encode data using base64
Receive data
Receive data on socket
Send data
Send data on socket
Send http request

Disassembly:
push r15
mov eax, 0x42b8
push r14
push r13
push r12
push rbp
push rdi
push rsi
push rbx
call fcn.14025bb50
sub rsp, rax
vmovups xmmword [rsp + 0x4270], xmm6
vmovups xmmword [rsp + 0x4280], xmm7
vmovups xmmword [rsp + 0x4290], xmm8
vmovups xmmword [rsp + 0x42a0], xmm9
mov rax, qword [0x1402c6220]
mov rbp, qword [rax]
mov rax, qword [0x1402c6230]
mov r12d, dword [rax]
test r12d, r12d
jne 0x140012876
mov rax, qword [0x1402c6280]
cmp byte [rax], 0
jne 0x140013267
test rbp, rbp
je 0x140012a0f
mov rcx, rbp
call sub.msvcrt.dll_strlen
mov ecx, 1
lea rdx, [rax + 1]
call sub.msvcrt.dll_calloc
mov rdx, rbp
mov r13, rax
test rax, rax
je 0x140013b0c
mov rcx, r13
call sub.msvcrt.dll_strcpy
movsx ebx, byte [r13]
test bl, bl
je 0x140013a55
mov edx, ebx
mov ecx, 1
add rax, 1
cmp dl, 0x2c
sete dl
movzx edx, dl
add ecx, edx
movzx edx, byte [rax]
test dl, dl
jne 0x1400128c0
movsxd rcx, ecx
mov edx, 0xc
call sub.msvcrt.dll_calloc
mov qword [0x1402d9de8], rax
test rax, rax
je 0x140013af8
xor r15d, r15d
mov dword [rsp + 0x40], r12d
mov r14, r13
vmovdqu xmm6, xmmword [0x140274e00]
mov dword [0x14026c0d0], 0
mov r12d, r15d
mov r15, r13
mov r13, rbp
test bl, bl
je 0x1400129f0
nop dword [rax]
cmp bl, 9
je 0x140012938
cmp bl, 0x20
jne 0x14001294b
nop word [rax + rax]
movsx ebx, byte [r14 + 1]
add r14, 1
cmp bl, 0x20
je 0x140012938
cmp bl, 9
je 0x140012938
lea rsi, [r14 + 1]
cmp bl, 0x2c
je 0x1400129e2
mov edx, 0x2c
mov rcx, r14
xor esi, esi
call sub.msvcrt.dll_strchr
test rax, rax
je 0x140012977
mov byte [rax], 0
movsx ebx, byte [r14]
lea rsi, [rax + 1]
mov ecx, 0x52
mov rbp, qword [sym.imp.msvcrt.dll_toupper]
call rbp
mov ecx, ebx
mov edi, eax
call qword [sym.imp.msvcrt.dll_isalpha]
test eax, eax
je 0x14001299e
cmp byte [r14 + 1], 0x3a
je 0x140012ea0
movsxd rax, r12d
mov rcx, r14
lea rdx, [rax + rax*2]
mov rax, qword [0x1402d9de8]
lea rbx, [rax + rdx*4]
lea rdx, str.0.0.0.0
mov byte [rbx + 8], dil
call sub.msvcrt.dll_strcmp
test eax, eax
jne 0x140012da8
mov qword [rbx], 0
add r12d, 1
mov dword [0x14026c0d0], r12d
test rsi, rsi
je 0x1400129f0
movsx ebx, byte [rsi]
mov r14, rsi
test bl, bl
jne 0x140012928
mov rbp, r13
mov r13, r15
mov r15d, r12d
mov r12d, dword [rsp + 0x40]
mov rcx, r13
call sub.msvcrt.dll_free
test r15d, r15d
je 0x14001324a
mov edx, 8
mov ecx, 1
call sub.msvcrt.dll_calloc
mov ecx, 0x3e8
mov rdi, qword [sym.imp.KERNEL32.dll_Sleep]
mov rsi, rax
mov qword [rsp + 0x48], rax
call rdi
xor r8d, r8d
mov edx, 1
mov ecx, 2
call qword [sym.imp.WS2_32.dll_socket]
mov qword [rsi], rax
mov r15, rax
cmp rax, 0xffffffffffffffff
je 0x14001350f
mov r8d, 2
mov rcx, rbp
mov qword [rsp + 0x72], 0
mov word [rsp + 0x70], r8w
mov qword [rsp + 0x78], 0
call qword [sym.imp.WS2_32.dll_inet_addr]
mov dword [rsp + 0x74], eax
cmp eax, 0xffffffff
je 0x14001356e
movzx eax, r12w
lea r13, [rsp + 0x70]
mov ecx, eax
mov dword [rsp + 0x40], eax
call qword [sym.imp.WS2_32.dll_htons]
mov rbp, qword [sym.imp.msvcrt.dll__time64]
xor ecx, ecx
mov word [rsp + 0x72], ax
call rbp
mov r12, qword [sym.imp.WS2_32.dll_bind]
mov r14, qword [sym.imp.msvcrt.dll__errno]
mov rsi, rax
jmp 0x140012b1b
call r14
mov ecx, dword [rax]
call sub.msvcrt.dll_strerror
xor ecx, ecx
mov rbx, rax
call rbp
sub rax, rsi
cmp rax, 0x3d
jg 0x1400134a8
mov rax, qword [0x1402c6320]
cmp byte [rax], 0
je 0x140012afe
mov rax, qword [0x1402c6280]
cmp byte [rax], 0
je 0x140012b14
mov r8d, dword [rsp + 0x40]
lea rdx, str.API_bind_to_port__d_failed___trying_again_in_20sec
mov ecx, 2
call fcn.14000a6b0
mov ecx, 0x4e20
call rdi
mov r8d, 0x10
mov rdx, r13
mov rcx, r15
call r12
test eax, eax
js 0x140012ac8
mov edx, 0xa
mov rcx, r15
call qword [sym.imp.WS2_32.dll_listen]
cmp eax, 0xffffffff
je 0x1400135f3
mov edx, 0x4001
mov ecx, 1
call sub.msvcrt.dll_calloc
mov r14, qword [sym.imp.WS2_32.dll_accept]
mov qword [0x1402d9de0], rax
mov rdi, qword [0x1402c6280]
mov eax, dword [0x1402d9dd0]
test eax, eax
jne 0x140012e31
mov dword [rsp + 0x60], 0x10
lea rdx, [rsp + 0x80]
lea r8, [rsp + 0x60]
mov rcx, r15
call r14
mov rbx, rax
cmp eax, 0xffffffff
je 0x14001359b
mov ecx, dword [rsp + 0x84]
call qword [sym.imp.WS2_32.dll_inet_ntoa]
mov rsi, rax
mov rax, qword [0x1402c6220]
cmp qword [rax], 0
je 0x140012d50
mov ecx, dword [rsp + 0x84]
call qword [sym.imp.WS2_32.dll_htonl]
movsxd rcx, dword [0x14026c0d0]
test ecx, ecx
jle 0x140012de8
mov rdx, qword [0x1402d9de8]
lea rcx, [rcx + rcx*2]
lea r8, [rdx + rcx*4]
jmp 0x140012bfd
add rdx, 0xc
cmp rdx, r8
je 0x140012de8
mov ecx, dword [rdx + 4]
and ecx, eax
cmp ecx, dword [rdx]
jne 0x140012bf0
mov rbp, qword [0x1402c6280]
cmp byte [rbp], 0
je 0x140012c23
mov rax, qword [0x1402c62f0]
cmp byte [rax], 0
jne 0x140012d83
movsxd rbx, ebx
xor r9d, r9d
lea r12, [rsp + 0x270]
mov r8d, 0x400
mov rdx, r12
mov rcx, rbx
call qword [sym.imp.WS2_32.dll_recv]
mov esi, eax
cmp eax, 0xffffffff
je 0x1400130bc
test eax, eax
jle 0x140013209
lea eax, [rax - 1]
movsxd rdx, eax
cmp byte [rsp + rdx + 0x270], 0xa
je 0x1400135c8
movsxd rax, esi
mov byte [rsp + rax + 0x270], 0
lea rdx, str.GET__
mov rcx, r12
call sub.msvcrt.dll_strstr
mov rdi, rax
test rax, rax
je 0x140012ca0
mov rcx, rax
call sub.msvcrt.dll_strlen
cmp rax, 5
ja 0x1400132af
xor edi, edi
mov edx, 0x7c
mov rcx, r12
xor r13d, r13d
call sub.msvcrt.dll_strchr
test rax, rax
je 0x140012cbc
mov byte [rax], 0
lea r13, [rax + 1]
cmp byte [rbp], 0
jne 0x140013216
mov rdx, qword [str.AM_]
mov rcx, r12
call sub.msvcrt.dll_strcmp
movsxd rsi, eax
test esi, esi
je 0x14001362e
mov rdx, qword [str.IM_]
mov rcx, r12
call sub.msvcrt.dll_strcmp
test eax, eax
je 0x140013629
mov rdx, qword [str.QM_]
mov rcx, r12
call sub.msvcrt.dll_strcmp
test eax, eax
je 0x140013bc1
mov rdx, qword [str.XM_]
mov rcx, r12
call sub.msvcrt.dll_strcmp
test eax, eax
je 0x140013bcb
mov rdx, qword [str.help]
mov rcx, r12
mov esi, 4
call sub.msvcrt.dll_strcmp
test eax, eax
je 0x14001362e
mov rcx, rbx
call qword [sym.imp.WS2_32.dll_closesocket]
jmp 0x140012b62
lea rdx, str.127.0.0.1
mov rcx, rsi
mov rbp, rdi
call sub.msvcrt.dll_strcmp
cmp byte [rdi], 0
je 0x140012e90
mov rdx, qword [0x1402c62f0]
cmp byte [rdx], 0
je 0x140012e90
test eax, eax
jne 0x140012e08
lea r9, str.Accepted
mov r8, rsi
mov ecx, 5
lea rdx, str.API:_connection_from__s____s
call fcn.14000a6b0
jmp 0x140012c23
mov edx, 0x2f
mov rcx, r14
call sub.msvcrt.dll_strchr
test rax, rax
je 0x140013038
mov byte [rax], 0
lea rcx, [rax + 1]
call sub.msvcrt.dll_atoi
lea r11d, [rax - 1]
cmp r11d, 0x1f
jbe 0x140012ee0
mov r12d, dword [0x14026c0d0]
jmp 0x1400129dd
mov rax, qword [0x1402c6280]
cmp byte [rax], 0
je 0x140012b69
mov rax, qword [0x1402c62f0]
cmp byte [rax], 0
je 0x140012b69
lea r9, str.Ignored
mov r8, rsi
mov ecx, 5
lea rdx, str.API:_connection_from__s____s
call fcn.14000a6b0
mov eax, dword [0x1402d9dd0]
test eax, eax
je 0x140012b77
mov rcx, r15
call qword [sym.imp.WS2_32.dll_closesocket]
mov rcx, qword [rsp + 0x48]
call sub.msvcrt.dll_free
mov rcx, qword [0x1402d9de0]
call sub.msvcrt.dll_free
nop
vmovups xmm6, xmmword [rsp + 0x4270]
vmovups xmm7, xmmword [rsp + 0x4280]
vmovups xmm8, xmmword [rsp + 0x4290]
vmovups xmm9, xmmword [rsp + 0x42a0]
add rsp, 0x42b8
pop rbx
pop rsi
pop rdi
pop rbp
pop r12
pop r13
pop r14
pop r15
ret
test eax, eax
jne 0x140012b69
jmp 0x140012c23
mov ecx, ebx
call rbp
mov ecx, 0x57
mov ebx, eax
call rbp
cmp ebx, eax
je 0x140012ece
mov ecx, 0x41
call rbp
mov edx, eax
mov eax, ebx
sub eax, edx
lea rdx, [0x1402d9d00]
cdqe
cmp qword [rdx + rax*8], 0
je 0x140012ed0
mov edi, ebx
add r14, 2
jmp 0x14001299e
movsxd rdx, dword [0x14026c0d0]
mov r9d, r11d
lea rcx, [rdx + rdx*2]
mov rdx, qword [0x1402d9de8]
lea r10, [rdx + rcx*4]
lea edx, [rax + 1]
cmp eax, 6
jbe 0x140013a47
mov r8d, 7
vmovd xmm7, eax
mov ecx, edx
vmovd xmm3, r8d
mov r8d, 1
vpbroadcastd ymm7, xmm7
shr ecx, 3
vpaddd ymm1, ymm7, ymmword [0x140274d80]
vmovd xmm0, r8d
mov r8d, 3
vpbroadcastd ymm3, xmm3
vmovd xmm2, r8d
vpbroadcastd ymm0, xmm0
vpand ymm4, ymm1, ymm3
vpbroadcastd ymm2, xmm2
vpaddd ymm8, ymm7, ymmword [0x140274da0]
vpsrad ymm1, ymm1, 3
vpsllvd ymm4, ymm0, ymm4
vpsubd ymm1, ymm2, ymm1
vpslld ymm1, ymm1, 3
vpsllvd ymm4, ymm4, ymm1
vmovdqu ymm5, ymm4
cmp ecx, 1
je 0x1400130c9
vpand ymm5, ymm8, ymm3
vpsrad ymm1, ymm8, 3
vpaddd ymm9, ymm7, ymmword [0x140274dc0]
vpsllvd ymm5, ymm0, ymm5
vpsubd ymm1, ymm2, ymm1
vpslld ymm1, ymm1, 3
vpsllvd ymm5, ymm5, ymm1
vpor ymm5, ymm4, ymm5
cmp ecx, 2
je 0x1400130c9
vpand ymm4, ymm9, ymm3
vpaddd ymm1, ymm7, ymmword [0x140274de0]
vpsllvd ymm7, ymm0, ymm4
vpsrad ymm4, ymm9, 3
vpsubd ymm4, ymm2, ymm4
vpslld ymm4, ymm4, 3
vpsllvd ymm4, ymm7, ymm4
vpor ymm5, ymm5, ymm4
cmp ecx, 4
jne 0x1400130c9
vpand ymm3, ymm1, ymm3
vpsrad ymm1, ymm1, 3
vpsllvd ymm0, ymm0, ymm3
vpsubd ymm1, ymm2, ymm1
vpslld ymm1, ymm1, 3
vpsllvd ymm0, ymm0, ymm1
vpor ymm0, ymm0, ymm5
vextracti128 xmm1, ymm0, 1
vpor xmm0, xmm1, xmm0
vpsrldq xmm1, xmm0, 8
vpor xmm0, xmm0, xmm1
vpsrldq xmm1, xmm0, 4
vpor xmm0, xmm0, xmm1
vmovd r8d, xmm0
cmp edx, 0x20
jne 0x140013a5f
vzeroupper
jmp 0x1400131f9
mov rax, qword [0x140274e00]
mov qword [rbx], rax
mov ebx, 0x18
xor edi, edi
jmp 0x140013058
cmp edi, 3
jg 0x1400130b2
mov r14, rbp
mov edx, 0x2e
mov rcx, r14
xor ebp, ebp
call sub.msvcrt.dll_strchr
test rax, rax
je 0x140013073
mov byte [rax], 0
lea rbp, [rax + 1]
mov rcx, r14
call sub.msvcrt.dll_atoi
cmp eax, 0xff
ja 0x140012dd8
movsxd rdx, dword [0x14026c0d0]
add edi, 1
lea rcx, [rdx + rdx*2]
mov r12, rdx
mov rdx, qword [0x1402d9de8]
lea rdx, [rdx + rcx*4]
mov ecx, ebx
sub ebx, 8
shl eax, cl
or eax, dword [rdx]
mov dword [rdx], eax
test rbp, rbp
jne 0x140013050
and eax, dword [rdx + 4]
mov dword [rdx], eax
jmp 0x1400129d2
mov byte [rsp + 0x270], 0
jmp 0x140012b62
vextracti128 xmm3, ymm5, 1
mov ecx, edx
vpor xmm3, xmm3, xmm5
and ecx, 0xfffffff8
vpsrldq xmm0, xmm3, 8
sub r11d, ecx
and edx, 7
vpor xmm0, xmm3, xmm0
mov r9d, r11d
vpsrldq xmm1, xmm0, 4
vpor xmm0, xmm0, xmm1
vmovd r8d, xmm0
je 0x14001302a
vzeroupper
sub eax, ecx
lea edx, [rax + 1]
cmp eax, 2
jbe 0x140013185
mov eax, 7
vmovd xmm7, r9d
vmovd xmm2, eax
vpshufd xmm1, xmm7, 0
mov eax, 1
vpaddd xmm1, xmm1, xmm6
vmovd xmm0, eax
vpshufd xmm2, xmm2, 0
mov eax, 3
vpand xmm2, xmm1, xmm2
vpshufd xmm0, xmm0, 0
vpsllvd xmm0, xmm0, xmm2
vpsrad xmm2, xmm1, 3
vmovd xmm1, eax
vpshufd xmm1, xmm1, 0
vpsubd xmm1, xmm1, xmm2
vpslld xmm1, xmm1, 3
vpsllvd xmm0, xmm0, xmm1
vpor xmm0, xmm0, xmm3
vpsrldq xmm1, xmm0, 8
vpor xmm0, xmm0, xmm1
vpsrldq xmm1, xmm0, 4
vpor xmm0, xmm0, xmm1
vmovd r8d, xmm0
test dl, 3
je 0x1400131f9
and edx, 0xfffffffc
sub r9d, edx
mov ecx, r9d
mov eax, 1
mov ebx, r9d
mov edx, 3
and ecx, 7
mov r11d, eax
sar ebx, 3
shl r11d, cl
mov ecx, edx
sub ecx, ebx
shl ecx, 3
shl r11d, cl
or r8d, r11d
lea r11d, [r9 - 1]
cmp r9d, 0xffffffff
je 0x1400131f9
mov ecx, r11d
mov ebx, eax
mov edi, r11d
sub r9d, 2
and ecx, 7
sar edi, 3
shl ebx, cl
mov ecx, edx
sub ecx, edi
shl ecx, 3
shl ebx, cl
or r8d, ebx
cmp r11d, 0xffffffff
je 0x1400131f9
mov ecx, r9d
sar r9d, 3
and ecx, 7
sub edx, r9d
shl eax, cl
lea ecx, [rdx*8]
shl eax, cl
or r8d, eax
mov dword [r10 + 4], r8d
mov dword [r10], 0
jmp 0x140013042
jne 0x140012c75
xor esi, esi
jmp 0x140012c6a
mov rax, qword [0x1402c62f0]
cmp byte [rax], 0
je 0x140012cc6
test esi, esi
jle 0x140012cc6
mov r9, r13
mov r8, r12
mov ecx, 5
lea rdx, str.API:_exec_command__s__s_
call fcn.14000a6b0
jmp 0x140012cc6
lea r8, str.___API_will_not_be_available
lea rdx, str.API_not_running__no_valid_IPs_specified__s
mov ecx, 2
call fcn.14000a6b0
jmp 0x140012a0f
vmovups xmm6, xmmword [rsp + 0x4270]
lea rdx, str.API_disabled
vmovups xmm7, xmmword [rsp + 0x4280]
mov ecx, 5
vmovups xmm8, xmmword [rsp + 0x4290]
vmovups xmm9, xmmword [rsp + 0x42a0]
add rsp, 0x42b8
pop rbx
pop rsi
pop rdi
pop rbp
pop r12
pop r13
pop r14
pop r15
jmp fcn.14000a6b0
lea rsi, [rsp + 0x170]
lea rcx, [rdi + 5]
mov qword [rsp + 0x170], 0
lea rdx, [0x1402749a0]
mov r8, rsi
mov qword [rsp + 0x178], 0
mov qword [rsp + 0x180], 0
mov qword [rsp + 0x188], 0
mov qword [rsp + 0x190], 0
mov qword [rsp + 0x198], 0
mov qword [rsp + 0x1a0], 0
mov qword [rsp + 0x1a8], 0
mov qword [rsp + 0x1b0], 0
mov qword [rsp + 0x1b8], 0
mov qword [rsp + 0x1c0], 0
mov qword [rsp + 0x1c8], 0
mov qword [rsp + 0x1d0], 0
mov qword [rsp + 0x1d8], 0
mov qword [rsp + 0x1e0], 0
mov qword [rsp + 0x1e8], 0
mov qword [rsp + 0x1f0], 0
mov qword [rsp + 0x1f8], 0
mov qword [rsp + 0x200], 0
mov qword [rsp + 0x208], 0
mov qword [rsp + 0x210], 0
mov qword [rsp + 0x218], 0
mov qword [rsp + 0x220], 0
mov qword [rsp + 0x228], 0
mov qword [rsp + 0x230], 0
mov qword [rsp + 0x238], 0
mov qword [rsp + 0x240], 0
mov qword [rsp + 0x248], 0
mov qword [rsp + 0x250], 0
mov qword [rsp + 0x258], 0
mov qword [rsp + 0x260], 0
mov qword [rsp + 0x268], 0
call fcn.1400127e0
mov edx, 0x2f
mov rcx, rsi
call sub.msvcrt.dll_strchr
test rax, rax
je 0x140013474
mov byte [rax], 0x7c
mov edx, 0x2f
mov rcx, rsi
call sub.msvcrt.dll_strchr
test rax, rax
je 0x140013474
mov byte [rax], 0
mov rcx, rdi
lea rdx, str.Sec_WebSocket_Key
call sub.msvcrt.dll_strstr
mov rdi, rax
test rax, rax
jne 0x140013a6b
mov r8, rsi
lea rdx, [0x1402749ab]
mov rcx, r12
call fcn.140012340
mov esi, eax
jmp 0x140012ca0
lea rax, str.___API_will_not_be_available
mov r8d, dword [rsp + 0x40]
mov r9, rbx
lea rdx, str.API_bind_to_port__d_failed___s__s
mov qword [rsp + 0x20], rax
mov ecx, 2
call fcn.14000a6b0
nop
vmovups xmm6, xmmword [rsp + 0x4270]
mov rcx, qword [rsp + 0x48]
vmovups xmm7, xmmword [rsp + 0x4280]
vmovups xmm8, xmmword [rsp + 0x4290]
vmovups xmm9, xmmword [rsp + 0x42a0]
add rsp, 0x42b8
pop rbx
pop rsi
pop rdi
pop rbp
pop r12
pop r13
pop r14
pop r15
jmp sub.msvcrt.dll_free
call qword [sym.imp.msvcrt.dll__errno]
mov ecx, dword [rax]
call sub.msvcrt.dll_strerror
lea r9, str.___API_will_not_be_available
mov ecx, 1
vmovups xmm6, xmmword [rsp + 0x4270]
vmovups xmm7, xmmword [rsp + 0x4280]
mov r8, rax
lea rdx, str.API_initialisation_failed___s__s
vmovups xmm8, xmmword [rsp + 0x4290]
vmovups xmm9, xmmword [rsp + 0x42a0]
add rsp, 0x42b8
pop rbx
pop rsi
pop rdi
pop rbp
pop r12
pop r13
pop r14
pop r15
jmp fcn.14000a6b0
call qword [sym.imp.msvcrt.dll__errno]
mov ecx, dword [rax]
call sub.msvcrt.dll_strerror
lea r9, str.___API_will_not_be_available
mov ecx, 1
lea rdx, str.API_initialisation_2_failed___s__s
mov r8, rax
call fcn.14000a6b0
jmp 0x140012e51
call qword [sym.imp.msvcrt.dll__errno]
mov ecx, dword [rax]
call sub.msvcrt.dll_strerror
lea r9, str.___API_will_not_be_available
mov ecx, 1
lea rdx, str.API_failed___s__s
mov r8, rax
call fcn.14000a6b0
jmp 0x140012e31
mov byte [rsp + rdx + 0x270], 0
test eax, eax
je 0x14001320f
lea edx, [rsi - 2]
movsxd rdx, edx
cmp byte [rsp + rdx + 0x270], 0xd
je 0x140013ad7
mov esi, eax
jmp 0x140012c6a
call qword [sym.imp.msvcrt.dll__errno]
mov ecx, dword [rax]
call sub.msvcrt.dll_strerror
lea r9, str.___API_will_not_be_available
mov ecx, 1
lea rdx, str.API_initialisation_3_failed___s__s
mov r8, rax
call fcn.14000a6b0
mov rcx, r15
call qword [sym.imp.WS2_32.dll_closesocket]
jmp 0x1400134ce
mov esi, 1
test r13, r13
je 0x14001364f
cmp byte [r13], 0
je 0x14001364f
mov rcx, r13
call sub.msvcrt.dll_strlen
lea rax, [r13 + rax - 1]
cmp byte [rax], 0x7c
jne 0x14001364f
mov byte [rax], 0
shl rsi, 4
lea rax, str.AM_
mov rcx, r13
call qword [rax + rsi + 8]
mov qword [rsp + 0x40], rax
test rdi, rdi
je 0x140013b96
mov rax, qword [0x1402c62f0]
mov qword [rsp + 0xf0], 0
mov qword [rsp + 0xf8], 0
mov qword [rsp + 0x100], 0
cmp byte [rax], 0
mov qword [rsp + 0x108], 0
mov qword [rsp + 0x110], 0
mov qword [rsp + 0x118], 0
mov qword [rsp + 0x120], 0
mov qword [rsp + 0x128], 0
mov qword [rsp + 0x130], 0
mov qword [rsp + 0x138], 0
mov qword [rsp + 0x140], 0
mov qword [rsp + 0x148], 0
mov qword [rsp + 0x150], 0
mov qword [rsp + 0x158], 0
mov qword [rsp + 0x160], 0
mov qword [rsp + 0x168], 0
jne 0x140013abe
lea rbp, [rsp + 0xf0]
mov r8, rdi
lea rdx, str._s258EAFA5_E914_47DA_95CA_C5AB0DC85B11
mov rcx, rbp
lea rsi, [rsp + 0x90]
call fcn.140012340
mov rcx, rbp
call sub.msvcrt.dll_strlen
mov rcx, rbp
mov r8, rsi
mov rdx, rax
call sub.libcrypto_1_1_x64.dll_SHA1
vpxor xmm0, xmm0, xmm0
mov edx, 0x1e
lea rax, [rsp + 0xb0]
mov ecx, 1
mov qword [rsp + 0x50], rax
vmovdqu xmmword [rsp + 0xb0], xmm0
vmovdqu xmmword [rsp + 0xc0], xmm0
vmovdqu xmmword [rsp + 0xd0], xmm0
vmovdqu xmmword [rsp + 0xe0], xmm0
call sub.msvcrt.dll_calloc
mov rbp, rax
test rax, rax
je 0x1400138f3
mov r13d, 0x14
xor r12d, r12d
lea rdi, str.ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789_
movzx eax, byte [rsi + 1]
movzx r8d, byte [rsi]
lea rcx, [rbp + r12]
mov r10d, eax
shl eax, 2
and eax, 0x3c
shr r10b, 4
mov r11d, eax
cmp r13d, 2
je 0x140013870
movzx edx, byte [rsi + 2]
mov r9d, r8d
sub r13d, 3
add rsi, 3
shr r9b, 2
add r12, 4
mov rax, rdx
and r9d, 0x3f
and eax, 0x3f
movsx r9d, byte [rdi + r9]
movsx eax, byte [rdi + rax]
mov dword [rsp + 0x30], eax
mov eax, edx
mov edx, 5
shr al, 6
or eax, r11d
and eax, 0x3f
movsx eax, byte [rdi + rax]
mov dword [rsp + 0x28], eax
mov eax, r8d
lea r8, str._c_c_c_c
shl eax, 4
and eax, 0x30
or eax, r10d
and eax, 0x3f
movsx eax, byte [rdi + rax]
mov dword [rsp + 0x20], eax
call fcn.1400127b0
test r13d, r13d
jne 0x1400137d7
jmp 0x1400138bf
movzx eax, al
mov esi, r10d
mov r10, rcx
mov edx, r8d
movsx eax, byte [rdi + rax]
mov ecx, esi
shr dl, 2
add r12, 4
and edx, 0x3f
mov dword [rsp + 0x28], eax
mov eax, r8d
movsx r9d, byte [rdi + rdx]
lea r8, str._c_c_c
shl eax, 4
mov edx, 5
and eax, 0x30
or eax, ecx
mov rcx, r10
and eax, 0x3f
movsx eax, byte [rdi + rax]
mov dword [rsp + 0x20], eax
call fcn.1400127b0
mov rdi, qword [rsp + 0x50]
mov r9, rbp
lea r8, [0x1402749ab]
mov rdx, r12
mov rcx, rdi
call fcn.140012420
mov rcx, rdi
call sub.msvcrt.dll_strlen
cmp rax, 0x1b
je 0x140013ae6
mov rcx, rbp
call sub.msvcrt.dll_free
mov r8, qword [rsp + 0x50]
lea rsi, [rsp + 0x170]
lea rdx, str.HTTP_1.1_101_Switching_Protocol_r_nUpgrade:_WebSocket_r_nConnection:_Upgrade_r_nSec_WebSocket_Accept:__s_r_nSec_WebSocket_Protocol:_text_r_n_r_n
mov rcx, rsi
call fcn.140012340
mov rcx, qword [rsp + 0x40]
xor edx, edx
mov qword [rsp + 0x66], 0
mov word [rsp + 0x6e], dx
mov byte [rsp + 0x66], 0x81
call sub.msvcrt.dll_strlen
mov r13, rax
cmp rax, 0x7d
jbe 0x140013aa9
cmp rax, 0xffff
ja 0x140013bd5
rol ax, 8
mov byte [rsp + 0x67], 0x7e
mov r9d, 4
mov r8d, 4
mov word [rsp + 0x68], ax
mov rcx, rsi
mov dword [rsp + 0x5c], r9d
mov qword [rsp + 0x50], r8
call sub.msvcrt.dll_strlen
mov r8, qword [rsp + 0x50]
mov ecx, 1
mov r12, rax
lea rdx, [r8 + r13 + 1]
add rdx, rax
call sub.msvcrt.dll_calloc
mov rbp, rax
test rax, rax
je 0x140012d41
cmp r12d, 8
mov r8, qword [rsp + 0x50]
mov r9d, dword [rsp + 0x5c]
jae 0x140013b76
test r12b, 4
jne 0x140013c11
test r12d, r12d
je 0x1400139d1
movzx eax, byte [rsp + 0x170]
mov byte [rbp], al
test r12b, 2
jne 0x140013c40
lea rdx, [rbp + r12]
lea rcx, [rsp + 0x66]
mov eax, r8d
cmp r8d, 8
jae 0x140013b25
test r8b, 4
jne 0x140013c2b
test eax, eax
je 0x140013a07
movzx r10d, byte [rsp + 0x66]
mov byte [rdx], r10b
test al, 2
jne 0x140013c52
lea rcx, [rdx + r8]
mov rdx, qword [rsp + 0x40]
mov r8, r13
mov dword [rsp + 0x50], r9d
call sub.msvcrt.dll_memcpy
mov r9d, dword [rsp + 0x50]
mov rcx, rbx
mov rdx, rbp
lea eax, [r9 + r13 + 1]
xor r9d, r9d
lea r8d, [rax + r12]
call qword [sym.imp.WS2_32.dll_send]
mov rcx, rbp
call sub.msvcrt.dll_free
jmp 0x140012d41
vpxor xmm3, xmm3, xmm3
xor ecx, ecx
xor r8d, r8d
jmp 0x140013101
mov ecx, 1
jmp 0x1400128d9
lea r9d, [rax - 0x21]
vzeroupper
jmp 0x140013185
mov edx, 0xd
mov rcx, rax
call sub.msvcrt.dll_strchr
test rax, rax
je 0x140013a80
mov byte [rax], 0
mov rcx, rdi
mov edx, 0x3a
call sub.msvcrt.dll_strchr
cmp byte [rax + 1], 0x20
lea rdi, [rax + 1]
jne 0x14001348f
add rdi, 1
cmp byte [rdi], 0x20
je 0x140013a9b
jmp 0x14001348f
mov byte [rsp + 0x67], al
mov r9d, 2
mov r8d, 2
jmp 0x140013961
mov r8, rdi
lea rdx, str.clientkey:__s
mov ecx, 5
call fcn.14000a6b0
jmp 0x14001373f
mov byte [rsp + rdx + 0x270], 0
mov esi, eax
jmp 0x140012c6a
mov ecx, 0x3d
mov word [rsp + 0xcb], cx
jmp 0x1400138eb
mov ecx, 1
call fcn.140004290
movsx ebx, byte [r13]
jmp 0x1400128f3
mov ecx, 1
call fcn.140004290
mov rax, qword [0x1402c6220]
mov rdx, qword [rax]
jmp 0x1400128a4
mov rax, qword [rsp + 0x66]
lea r11, [rdx + 8]
and r11, 0xfffffffffffffff8
mov qword [rdx], rax
mov rax, qword [rcx + r8 - 8]
mov qword [rdx + r8 - 8], rax
mov rax, rdx
sub rax, r11
sub rcx, rax
add eax, r8d
and eax, 0xfffffff8
cmp eax, 8
jb 0x140013a07
and eax, 0xfffffff8
xor r10d, r10d
mov esi, r10d
add r10d, 8
mov rdi, qword [rcx + rsi]
mov qword [r11 + rsi], rdi
cmp r10d, eax
jb 0x140013b5d
jmp 0x140013a07
mov eax, r12d
lea ecx, [r12 - 1]
mov rdi, rbp
mov rdx, qword [rsi + rax - 8]
shr ecx, 3
mov qword [rbp + rax - 8], rdx
rep movsq qword [rdi], qword [rsi]
jmp 0x1400139d1
cmp qword [rsp + 0x40], 0
je 0x140013bf3
mov rcx, rax
mov rdi, rax
call sub.msvcrt.dll_strlen
xor r9d, r9d
mov rdx, rdi
mov rcx, rbx
lea r8d, [rax + 1]
call qword [sym.imp.WS2_32.dll_send]
jmp 0x140012d41
mov esi, 2
jmp 0x14001362e
mov esi, 3
jmp 0x14001362e
bswap rax
mov byte [rsp + 0x67], 0x7f
mov r9d, 0xa
mov r8d, 0xa
mov qword [rsp + 0x68], rax
jmp 0x140013961
xor r9d, r9d
mov r8d, 1
lea rdx, [0x140274cd5]
mov rcx, rbx
call qword [sym.imp.WS2_32.dll_send]
jmp 0x140012d41
mov eax, dword [rsp + 0x170]
mov dword [rbp], eax
mov eax, r12d
mov edx, dword [rsi + rax - 4]
mov dword [rbp + rax - 4], edx
jmp 0x1400139d1
mov r10d, dword [rsp + 0x66]
mov dword [rdx], r10d
mov ecx, dword [rcx + rax - 4]
mov dword [rdx + rax - 4], ecx
jmp 0x140013a07
mov eax, r12d
movzx edx, word [rsi + rax - 2]
mov word [rbp + rax - 2], dx
jmp 0x1400139d1
movzx ecx, word [rcx + rax - 2]
mov word [rdx + rax - 2], cx
jmp 0x140013a07