Function at 0x140171d50
Capabilities:
Encode data using xor

Disassembly:
push r15
push r14
push r13
push r12
push rsi
push rdi
push rbp
push rbx
sub rsp, 0x78
mov r14, rcx
mov rcx, qword [rcx + 0x10]
mov qword [rsp + 0x30], rcx
inc rcx
je 0x1401726de
mov r12, rdx
mov rdi, qword [r14]
lea r15, [rdi + 1]
mov rax, r15
shr rax, 3
mov rdx, r15
and rdx, 0xfffffffffffffff8
sub rdx, rax
cmp rdi, 8
mov qword [rsp + 0x70], rdx
mov rax, rdx
cmovb rax, rdi
mov rdx, rax
shr rdx, 1
cmp rcx, rdx
mov qword [rsp + 0x20], rdi
jbe 0x140171dda
inc rax
cmp rcx, rax
cmova rax, rcx
cmp rax, 8
jae 0x140171e68
xor ecx, ecx
cmp rax, 4
setae cl
lea rbx, [rcx*4 + 4]
jmp 0x140171eb8
mov qword [rsp + 0x68], r14
mov r14, qword [r14 + 0x18]
xor eax, eax
movdqa xmm0, xmmword [0x140176680]
xor edx, edx
jmp 0x140171e28
cmp rax, r15
mov rcx, rax
adc rcx, 0
cmp rax, r15
jae 0x140171e3e
pxor xmm1, xmm1
pcmpgtb xmm1, xmmword [r14 + rax]
por xmm1, xmm0
movdqa xmmword [r14 + rax], xmm1
mov dl, 1
mov rax, rcx
test dl, 1
je 0x140171e00
add rax, 0xf
jb 0x140171e3e
cmp rax, r15
jae 0x140171e3e
lea rcx, [rax + 1]
jmp 0x140171e0f
cmp r15, 0x10
jae 0x140171f2c
lea rcx, [r14 + 0x10]
mov rdx, r14
mov r8, r15
call sub.VCRUNTIME140.dll_memmove
cmp rdi, 0xffffffffffffffff
jne 0x140171f37
xor ecx, ecx
jmp 0x1401724d3
mov ecx, 8
mul rcx
jo 0x1401726de
mov rcx, rax
mov ebx, 1
cmp rax, 0xe
jb 0x140171eb8
movabs rdx, 0x2492492492492493
mov rax, rcx
mul rdx
sub rcx, rdx
shr rcx, 1
add rcx, rdx
shr rcx, 2
dec rcx
bsr rcx, rcx
xor ecx, 0x3f
mov rbx, 0xffffffffffffffff
shr rbx, cl
inc rbx
mov ecx, 0x68
mov rax, rbx
mul rcx
jo 0x1401726de
mov rdi, rax
add rdi, 0xf
and rdi, 0xfffffffffffffff0
lea r13, [rbx + 0x10]
mov rbp, rdi
add rbp, r13
jb 0x1401726de
je 0x1401724e6
mov rcx, qword [0x140221370]
test rcx, rcx
jne 0x140171f0b
call qword [sym.imp.KERNEL32.dll_GetProcessHeap]
test rax, rax
je 0x140171f22
mov rcx, rax
mov qword [0x140221370], rax
xor edx, edx
mov r8, rbp
call qword [sym.imp.KERNEL32.dll_HeapAlloc]
mov rsi, rax
test rax, rax
jne 0x1401724eb
mov rcx, rbp
call fcn.1400809c0
ud2
movdqu xmm0, xmmword [r14]
movdqu xmmword [r14 + r15], xmm0
mov rax, qword [r12]
mov rcx, qword [r12 + 8]
movabs rdx, 0x736f6d6570736575
xor rdx, rax
mov qword [rsp + 0x58], rdx
movabs rdx, 0x646f72616e646f6d
xor rdx, rcx
mov qword [rsp + 0x50], rdx
movabs rdx, 0x6c7967656e657261
xor rdx, rax
mov qword [rsp + 0x48], rdx
movabs rax, 0x7465646279746573
xor rax, rcx
mov qword [rsp + 0x40], rax
xor r9d, r9d
jmp 0x140171fb4
shr r15, 0x39
lea rax, [r9 - 0x10]
and rax, rdi
mov byte [r14 + r9], r15b
mov byte [rax + r14 + 0x10], r15b
lea rax, [r9 + 1]
cmp r9, rdi
mov r9, rax
je 0x1401724c6
cmp byte [r14 + r9], 0x80
jne 0x140171fa4
mov rax, r9
not rax
imul rax, rax, 0x68
add rax, r14
mov qword [rsp + 0x60], rax
mov qword [rsp + 0x28], r9
mov rax, r9
neg rax
imul rax, rax, 0x68
add rax, r14
add rax, 0xffffffffffffff98
mov qword [rsp + 0x38], rax
nop dword [rax + rax]
mov rax, qword [rsp + 0x38]
mov r9, qword [rax + 8]
mov r12, qword [rax + 0x10]
mov r8d, r12d
and r8d, 7
mov rax, r12
and rax, 0xfffffffffffffff8
je 0x140172090
mov r13, qword [rsp + 0x48]
mov r15, qword [rsp + 0x50]
mov r11, qword [rsp + 0x58]
mov rsi, qword [rsp + 0x40]
xor r10d, r10d
nop dword [rax + rax]
add r11, r15
rol r15, 0xd
mov rcx, qword [r9 + r10]
xor r15, r11
rol r11, 0x20
xor rsi, rcx
add r13, rsi
rol rsi, 0x10
xor rsi, r13
add r11, rsi
rol rsi, 0x15
add r13, r15
rol r15, 0x11
xor r15, r13
rol r13, 0x20
xor rsi, r11
xor r11, rcx
add r10, 8
cmp r10, rax
jb 0x140172030
cmp r8d, 3
jbe 0x1401720ad
mov ebx, dword [r9 + r10]
mov eax, 4
mov rcx, rax
or rcx, 1
cmp rcx, r8
jb 0x1401720bd
jmp 0x1401720d7
mov rsi, qword [rsp + 0x40]
mov r15, qword [rsp + 0x50]
mov r13, qword [rsp + 0x48]
mov r11, qword [rsp + 0x58]
xor r10d, r10d
cmp r8d, 3
ja 0x140172079
xor eax, eax
xor ebx, ebx
mov rcx, rax
or rcx, 1
cmp rcx, r8
jae 0x1401720d7
lea rcx, [rax + r10]
movzx edx, word [r9 + rcx]
lea ecx, [rax*8]
shl rdx, cl
or rbx, rdx
or rax, 2
cmp rax, r8
jae 0x140172100
add r10, rax
movzx edx, byte [r9 + r10]
shl eax, 3
mov ecx, eax
shl rdx, cl
or rbx, rdx
mov r9, qword [rsp + 0x28]
jmp 0x14017210a
test r8, r8
mov r9, qword [rsp + 0x28]
je 0x140172167
lea ecx, [r8*8]
mov edx, 0xff
shl rdx, cl
or rdx, rbx
cmp r8, 7
jne 0x140172252
mov ecx, 8
add r11, r15
rol r15, 0xd
sub rcx, r8
xor r15, r11
rol r11, 0x20
xor rsi, rdx
add r13, rsi
rol rsi, 0x10
xor rsi, r13
add r11, rsi
rol rsi, 0x15
xor rsi, r11
add r13, r15
rol r15, 0x11
xor r15, r13
rol r13, 0x20
xor r11, rdx
jmp 0x140172169
xor ecx, ecx
mov edx, 1
sub rdx, rcx
mov r8d, edx
and r8d, 7
and rdx, 0xfffffffffffffff8
cmp rcx, rdx
jae 0x140172200
nop word cs:[rax + rax]
add r11, r15
rol r15, 0xd
mov rax, rsi
xor r15, r11
rol r11, 0x20
xor rax, 0xff
add r13, rax
shld rax, rsi, 0x10
xor rax, r13
add r11, rax
rol rax, 0x15
add r13, r15
rol r15, 0x11
mov rsi, rax
xor r15, r13
rol r13, 0x20
xor rsi, r11
xor r11, 0xff
add rcx, 8
cmp rcx, rdx
jb 0x140172190
xor edi, edi
cmp r8, 4
setae dil
shl rdi, 2
cmp r8d, 4
mov ebx, 0
mov eax, 0xff
cmovae rbx, rax
jmp 0x140172204
xor edi, edi
xor ebx, ebx
mov rdx, rdi
lea ecx, [rdi*8]
mov eax, 0xff
shl rax, cl
or rdx, 1
mov rbp, rdi
or rbp, 2
cmp rdx, r8
cmovae rbp, rdi
mov edi, 0
cmovae rax, rdi
or rax, rbx
lea ecx, [rbp*8]
mov edx, 0xff
shl rdx, cl
cmp rbp, r8
cmovae rdx, rdi
or rdx, rax
mov rdi, qword [rsp + 0x20]
shl r12, 0x38
movabs rax, 0x100000000000000
add r12, rax
add r11, r15
rol r15, 0xd
or r12, rdx
xor r15, r11
rol r11, 0x20
xor rsi, r12
add r13, rsi
rol rsi, 0x10
xor rsi, r13
add r11, rsi
rol rsi, 0x15
add r13, r15
rol r15, 0x11
xor rsi, r11
xor r15, r13
rol r13, 0x20
xor r11, r12
add r11, r15
rol r15, 0xd
xor r15, r11
rol r11, 0x20
xor r13, 0xff
add r13, rsi
rol rsi, 0x10
xor rsi, r13
add r11, rsi
rol rsi, 0x15
add r13, r15
rol r15, 0x11
xor r15, r13
rol r13, 0x20
xor rsi, r11
add r11, r15
rol r15, 0xd
xor r15, r11
rol r11, 0x20
add r13, rsi
rol rsi, 0x10
xor rsi, r13
add r11, rsi
rol rsi, 0x15
add r13, r15
rol r15, 0x11
xor r15, r13
rol r13, 0x20
xor rsi, r11
add r11, r15
rol r15, 0xd
add r13, rsi
rol rsi, 0x10
xor rsi, r13
rol rsi, 0x15
xor r15, r11
add r13, r15
rol r15, 0x11
mov rax, r13
rol rax, 0x20
xor r15, r13
xor r15, rax
xor r15, rsi
mov rax, rdi
and rax, r15
movdqu xmm0, xmmword [r14 + rax]
pmovmskb ecx, xmm0
mov rdx, rax
test ecx, ecx
jne 0x140172378
mov ebx, reloc.WS2_32.dll_recv
mov rdx, rax
nop word cs:[rax + rax]
add rdx, rbx
and rdx, rdi
movdqu xmm0, xmmword [r14 + rdx]
pmovmskb ecx, xmm0
add rbx, 0x10
test ecx, ecx
je 0x140172360
bsf cx, cx
movzx ebp, cx
add rbp, rdx
and rbp, rdi
cmp byte [r14 + rbp], 0
js 0x14017239c
movdqa xmm0, xmmword [r14]
pmovmskb ecx, xmm0
bsf cx, cx
movzx ebp, cx
mov rdx, r9
sub rdx, rax
mov rcx, rbp
sub rcx, rax
xor rcx, rdx
and rcx, rdi
cmp rcx, 0x10
jb 0x140171f90
mov rax, rbp
not rax
imul rax, rax, 0x68
add rax, r14
movzx ecx, byte [r14 + rbp]
shr r15, 0x39
lea rdx, [rbp - 0x10]
and rdx, rdi
mov byte [r14 + rbp], r15b
mov byte [rdx + r14 + 0x10], r15b
cmp cl, 0xff
je 0x140172470
mov rbp, qword [rsp + 0x60]
movups xmm0, xmmword [rbp]
movups xmm1, xmmword [rax]
movups xmmword [rbp], xmm1
movups xmmword [rax], xmm0
movups xmm0, xmmword [rbp + 0x10]
movups xmm1, xmmword [rax + 0x10]
movups xmmword [rbp + 0x10], xmm1
movups xmmword [rax + 0x10], xmm0
movups xmm0, xmmword [rbp + 0x20]
movups xmm1, xmmword [rax + 0x20]
movups xmmword [rbp + 0x20], xmm1
movups xmmword [rax + 0x20], xmm0
movups xmm0, xmmword [rbp + 0x30]
movups xmm1, xmmword [rax + 0x30]
movups xmmword [rbp + 0x30], xmm1
movups xmmword [rax + 0x30], xmm0
movups xmm0, xmmword [rbp + 0x40]
movups xmm1, xmmword [rax + 0x40]
movups xmmword [rbp + 0x40], xmm1
movups xmmword [rax + 0x40], xmm0
movdqu xmm0, xmmword [rbp + 0x50]
movdqu xmm1, xmmword [rax + 0x50]
movdqu xmmword [rbp + 0x50], xmm1
movdqu xmmword [rax + 0x50], xmm0
mov rcx, qword [rbp + 0x60]
mov rdx, qword [rax + 0x60]
mov qword [rbp + 0x60], rdx
mov qword [rax + 0x60], rcx
jmp 0x140171ff0
lea rcx, [r9 - 0x10]
and rcx, rdi
mov byte [r14 + r9], 0xff
mov byte [rcx + r14 + 0x10], 0xff
mov rdx, qword [rsp + 0x60]
mov rcx, qword [rdx + 0x60]
mov qword [rax + 0x60], rcx
movups xmm0, xmmword [rdx + 0x50]
movups xmmword [rax + 0x50], xmm0
movups xmm0, xmmword [rdx + 0x40]
movups xmmword [rax + 0x40], xmm0
movdqu xmm0, xmmword [rdx]
movdqu xmm1, xmmword [rdx + 0x10]
movups xmm2, xmmword [rdx + 0x20]
movups xmm3, xmmword [rdx + 0x30]
movups xmmword [rax + 0x30], xmm3
movups xmmword [rax + 0x20], xmm2
movdqu xmmword [rax + 0x10], xmm1
movdqu xmmword [rax], xmm0
jmp 0x140171fa4
cmp rdi, 8
mov rcx, qword [rsp + 0x70]
cmovb rcx, rdi
sub rcx, qword [rsp + 0x30]
mov rax, qword [rsp + 0x68]
mov qword [rax + 8], rcx
jmp 0x1401726c3
mov esi, reloc.WS2_32.dll_recv
lea rbp, [rbx - 1]
mov rax, rbx
shr rax, 3
and rbx, 0xfffffffffffffff8
sub rbx, rax
cmp rbp, 8
cmovb rbx, rbp
add rsi, rdi
mov rcx, rsi
mov dl, 0xff
mov r8, r13
call sub.VCRUNTIME140.dll_memset
mov rax, qword [rsp + 0x30]
sub rbx, rax
test r15, r15
je 0x14017267a
mov qword [rsp + 0x38], rbx
mov rdi, qword [r14 + 0x18]
mov rax, r12
lea r12, [rdi - 0x68]
mov rbx, qword [rax]
mov rax, qword [rax + 8]
mov qword [rsp + 0x28], rax
xor r13d, r13d
jmp 0x1401725c6
shr rax, 0x39
lea rcx, [rdx - 0x10]
and rcx, rbp
mov byte [rsi + rdx], al
mov byte [rcx + rsi + 0x10], al
imul rax, r13, 0xffffffffffffff98
imul rcx, rdx, 0xffffffffffffff98
mov rdx, qword [rax + rdi - 8]
mov qword [rcx + rsi - 8], rdx
movups xmm0, xmmword [rax + rdi - 0x18]
movups xmmword [rcx + rsi - 0x18], xmm0
movups xmm0, xmmword [rax + rdi - 0x28]
movups xmmword [rcx + rsi - 0x28], xmm0
movdqu xmm0, xmmword [rax + rdi - 0x68]
movdqu xmm1, xmmword [rax + rdi - 0x58]
movups xmm2, xmmword [rax + rdi - 0x48]
movups xmm3, xmmword [rax + rdi - 0x38]
movups xmmword [rcx + rsi - 0x38], xmm3
movups xmmword [rcx + rsi - 0x48], xmm2
movdqu xmmword [rcx + rsi - 0x58], xmm1
movdqu xmmword [rcx + rsi - 0x68], xmm0
lea rax, [r13 + 1]
cmp r13, qword [rsp + 0x20]
mov r13, rax
je 0x140172655
cmp byte [rdi + r13], 0
js 0x1401725b4
mov rax, r13
neg rax
imul rax, rax, 0x68
mov r8, qword [r12 + rax + 8]
mov r9, qword [r12 + rax + 0x10]
mov rcx, rbx
mov rdx, qword [rsp + 0x28]
call fcn.140021540
mov rcx, rax
and rcx, rbp
movdqu xmm0, xmmword [rsi + rcx]
pmovmskb edx, xmm0
test edx, edx
jne 0x14017262a
mov r8, rbx
mov ebx, reloc.WS2_32.dll_recv
nop dword [rax]
add rcx, rbx
and rcx, rbp
movdqu xmm0, xmmword [rsi + rcx]
pmovmskb edx, xmm0
add rbx, 0x10
test edx, edx
je 0x140172610
mov rbx, r8
bsf dx, dx
movzx edx, dx
add rdx, rcx
and rdx, rbp
cmp byte [rsi + rdx], 0
js 0x140172550
movdqa xmm0, xmmword [rsi]
pmovmskb ecx, xmm0
bsf cx, cx
movzx edx, cx
jmp 0x140172550
mov qword [r14], rbp
mov rax, qword [rsp + 0x38]
mov qword [r14 + 8], rax
mov rax, qword [rsp + 0x30]
mov qword [r14 + 0x10], rax
mov qword [r14 + 0x18], rsi
mov rbp, qword [rsp + 0x20]
test rbp, rbp
jne 0x140172692
jmp 0x1401726c3
mov rdi, qword [r14 + 0x18]
mov qword [r14], rbp
mov qword [r14 + 8], rbx
mov qword [r14 + 0x10], rax
mov qword [r14 + 0x18], rsi
mov rbp, qword [rsp + 0x20]
mov ecx, 0x68
mov rax, r15
mul rcx
add rax, 0xf
and rax, 0xfffffffffffffff0
add rbp, rax
cmp rbp, 0xffffffffffffffef
je 0x1401726c3
sub rdi, rax
mov rcx, qword [0x140221370]
xor edx, edx
mov r8, rdi
call qword [sym.imp.KERNEL32.dll_HeapFree]
movabs rax, 0x8000000000000001
add rsp, 0x78
pop rbx
pop rbp
pop rdi
pop rsi
pop r12
pop r13
pop r14
pop r15
ret
call fcn.140080970
ud2