Function at 0x180004bc0
Capabilities:
Encode data using xor

Disassembly:
mov rax, rsp
mov qword [rax + 0x18], rbx
mov qword [rax + 0x20], rsi
push rdi
sub rsp, 0x110
test edx, edx
je 0x180005080
cmp edx, 1
jne 0x180005076
mov qword [rax + 8], rbp
mov qword [rax + 0x10], r14
movaps xmmword [rax - 0x18], xmm6
movaps xmmword [rax - 0x28], xmm7
movaps xmmword [rax - 0x38], xmm8
call qword [sym.imp.KERNEL32.dll_AllocConsole]
mov esi, 1
mov ecx, esi
call qword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll___acrt_iob_func]
mov ecx, esi
mov rbx, rax
call qword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll___acrt_iob_func]
mov r9, rbx
lea r8, [0x18000a910]
mov rcx, rax
lea rdx, str.CONOUT_
call qword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll_freopen_s]
movups xmm0, xmmword [str.wYLP]
mov edi, dword [0x18000e018]
lea ebp, [rsi + 4]
xor ebx, ebx
lea r14d, [rsi + 0x1e]
movups xmmword [rsp + 0x20], xmm0
psrldq xmm0, 0xf
movd eax, xmm0
test al, al
je 0x180004dea
mov r8d, ebx
cmp edi, 2
jl 0x180004dbb
movdqa xmm0, xmmword [str.6666666666666666]
lea rcx, [rsp + 0x24]
movdqa xmm5, xmmword [0x18000ade0]
mov edx, ebx
movdqa xmm4, xmmword [0x18000ae30]
movdqa xmm7, xmmword [0x18000ae00]
movdqa xmmword [rsp + 0x30], xmm0
mov r8d, dword [rsp + 0x30]
movd xmm6, ebp
movd xmm8, r14d
nop dword [rax]
nop dword [rax + rax]
movd xmm2, edx
lea eax, [rdx + 4]
pshufd xmm2, xmm2, 0
lea rcx, [rcx + 8]
paddd xmm2, xmm5
movd xmm3, eax
movdqa xmm1, xmm2
pshufd xmm3, xmm3, 0
punpckldq xmm1, xmm2
movdqa xmm0, xmm2
punpckhdq xmm0, xmm2
paddd xmm3, xmm5
pmuldq xmm0, xmm4
add edx, 8
pmuldq xmm1, xmm4
shufps xmm1, xmm0, 0xdd
paddd xmm1, xmm2
psrad xmm1, xmm6
movdqa xmm0, xmm1
psrld xmm0, xmm8
paddd xmm0, xmm1
pmulld xmm0, xmm7
psubd xmm2, xmm0
pshuflw xmm0, xmm2, 0xd8
pshufhw xmm1, xmm0, 0xd8
pshufd xmm2, xmm1, 0xd8
movdqa xmm1, xmm3
pand xmm2, xmmword [0x18000ae10]
packuswb xmm2, xmm2
punpckldq xmm1, xmm3
pmuldq xmm1, xmm4
movd xmm0, r8d
paddb xmm2, xmm0
movd xmm0, dword [rcx - 0xc]
pxor xmm2, xmm0
movdqa xmm0, xmm3
punpckhdq xmm0, xmm3
pmuldq xmm0, xmm4
movd dword [rcx - 0xc], xmm2
shufps xmm1, xmm0, 0xdd
paddd xmm1, xmm3
psrad xmm1, xmm6
movdqa xmm0, xmm1
psrld xmm0, xmm8
paddd xmm0, xmm1
pmulld xmm0, xmm7
psubd xmm3, xmm0
pshuflw xmm0, xmm3, 0xd8
pshufhw xmm1, xmm0, 0xd8
movd xmm0, r8d
pshufd xmm2, xmm1, 0xd8
pand xmm2, xmmword [0x18000ae10]
packuswb xmm2, xmm2
paddb xmm2, xmm0
movd xmm0, dword [rcx - 8]
pxor xmm2, xmm0
movd dword [rcx - 8], xmm2
cmp edx, 0x10
jl 0x180004cb0
jmp 0x180004dea
lea r9, [rsp + 0x20]
mov eax, 0xa0a0a0a1
lea r9, [r9 + 1]
mul r8d
shr edx, 5
movsx eax, dl
imul ecx, eax, 0x33
movzx eax, r8b
inc r8d
sub al, cl
add al, 0x36
xor byte [r9 - 1], al
cmp r8d, 0x10
jl 0x180004dc0
lea rcx, [rsp + 0x20]
call fcn.180001040
movups xmm0, xmmword [0x18000ab60]
movups xmm1, xmmword [0x18000ab70]
mov eax, dword [0x18000abf8]
movups xmmword [rsp + 0x40], xmm0
movups xmm0, xmmword [0x18000ab80]
movups xmmword [rsp + 0x50], xmm1
movups xmm1, xmmword [0x18000ab90]
movups xmmword [rsp + 0x60], xmm0
movups xmm0, xmmword [0x18000aba0]
movups xmmword [rsp + 0x70], xmm1
movups xmm1, xmmword [0x18000abb0]
movups xmmword [rsp + 0x80], xmm0
movups xmm0, xmmword [0x18000abc0]
movups xmmword [rsp + 0x90], xmm1
movups xmm1, xmmword [0x18000abd0]
movups xmmword [rsp + 0xa0], xmm0
movups xmm0, xmmword [0x18000abe0]
movups xmmword [rsp + 0xb0], xmm1
movsd xmm1, qword [0x18000abf0]
mov dword [rsp + 0xd8], eax
movzx eax, byte [0x18000abfc]
movups xmmword [rsp + 0xc0], xmm0
movsd qword [rsp + 0xd0], xmm1
mov byte [rsp + 0xdc], al
cmp edi, 2
jl 0x180004ff2
movdqa xmm0, xmmword [str.6666666666666666]
lea rcx, [rsp + 0x44]
movdqa xmm5, xmmword [0x18000ade0]
movdqa xmm4, xmmword [0x18000ae30]
movdqa xmm7, xmmword [0x18000ae00]
movdqa xmmword [rsp + 0x30], xmm0
mov edx, dword [rsp + 0x30]
movd xmm6, ebp
movd xmm8, r14d
nop dword [rax]
movd xmm2, ebx
lea eax, [rbx + 4]
pshufd xmm2, xmm2, 0
lea rcx, [rcx + 8]
paddd xmm2, xmm5
movd xmm3, eax
movdqa xmm1, xmm2
pshufd xmm3, xmm3, 0
punpckldq xmm1, xmm2
movdqa xmm0, xmm2
punpckhdq xmm0, xmm2
paddd xmm3, xmm5
pmuldq xmm0, xmm4
add ebx, 8
pmuldq xmm1, xmm4
shufps xmm1, xmm0, 0xdd
paddd xmm1, xmm2
psrad xmm1, xmm6
movdqa xmm0, xmm1
psrld xmm0, xmm8
paddd xmm0, xmm1
pmulld xmm0, xmm7
psubd xmm2, xmm0
pshuflw xmm0, xmm2, 0xd8
pshufhw xmm1, xmm0, 0xd8
pshufd xmm2, xmm1, 0xd8
movdqa xmm1, xmm3
pand xmm2, xmmword [0x18000ae10]
packuswb xmm2, xmm2
punpckldq xmm1, xmm3
pmuldq xmm1, xmm4
movd xmm0, edx
paddb xmm2, xmm0
movd xmm0, dword [rcx - 0xc]
pxor xmm2, xmm0
movdqa xmm0, xmm3
punpckhdq xmm0, xmm3
pmuldq xmm0, xmm4
movd dword [rcx - 0xc], xmm2
shufps xmm1, xmm0, 0xdd
paddd xmm1, xmm3
psrad xmm1, xmm6
movdqa xmm0, xmm1
psrld xmm0, xmm8
paddd xmm0, xmm1
pmulld xmm0, xmm7
psubd xmm3, xmm0
pshuflw xmm0, xmm3, 0xd8
pshufhw xmm1, xmm0, 0xd8
movd xmm0, edx
pshufd xmm2, xmm1, 0xd8
pand xmm2, xmmword [0x18000ae10]
packuswb xmm2, xmm2
paddb xmm2, xmm0
movd xmm0, dword [rcx - 8]
pxor xmm2, xmm0
movd dword [rcx - 8], xmm2
cmp ebx, 0x98
jl 0x180004ee0
cmp ebx, 0x9d
jge 0x180005033
movsxd rax, ebx
lea r8, [rsp + 0x40]
add r8, rax
nop dword [rax]
mov eax, 0xa0a0a0a1
lea r8, [r8 + 1]
imul ebx
add edx, ebx
sar edx, 5
mov eax, edx
shr eax, 0x1f
add edx, eax
movsx eax, dl
movzx edx, bl
imul ecx, eax, 0x33
inc ebx
sub dl, cl
add dl, 0x36
xor byte [r8 - 1], dl
cmp ebx, 0x9d
jl 0x180005000
lea rcx, [rsp + 0x40]
call fcn.180001040
call qword [sym.imp.KERNEL32.dll_FreeConsole]
call fcn.180003ff0
movaps xmm8, xmmword [rsp + 0xe0]
movaps xmm7, xmmword [rsp + 0xf0]
movaps xmm6, xmmword [rsp + 0x100]
mov r14, qword [rsp + 0x128]
mov rbp, qword [rsp + 0x120]
jmp 0x18000514d
mov eax, 1
jmp 0x18000514f
call fcn.180002220
xor ebx, ebx
mov esi, 1
mov edi, ebx
xor eax, eax
lock cmpxchg dword [0x18000ec78], esi
je 0x1800050c1
nop word [rax + rax]
cmp rdi, 0x20
jae 0x1800050aa
xor ecx, ecx
jmp 0x1800050ac
mov ecx, esi
call qword [sym.imp.KERNEL32.dll_Sleep]
inc rdi
xor eax, eax
lock cmpxchg dword [0x18000ec78], esi
jne 0x1800050a0
cmp qword [0x18000ec80], rbx
je 0x180005141
xor ecx, ecx
call fcn.180007b10
test eax, eax
jne 0x180005141
mov rcx, qword [0x18000ed00]
mov qword [0x18000ed00], rbx
test rcx, rcx
je 0x180005109
nop dword [rax + rax]
mov rdi, qword [rcx]
xor edx, edx
mov r8d, 0x8000
call qword [sym.imp.KERNEL32.dll_VirtualFree]
mov rcx, rdi
test rdi, rdi
jne 0x1800050f0
mov r8, qword [0x18000ecf0]
xor edx, edx
mov rcx, qword [0x18000ec80]
call qword [sym.imp.KERNEL32.dll_HeapFree]
mov rcx, qword [0x18000ec80]
call qword [sym.imp.KERNEL32.dll_HeapDestroy]
mov qword [0x18000ec80], rbx
mov qword [0x18000ecf0], rbx
mov qword [0x18000ecf8], rbx
xchg dword [0x18000ec78], ebx
call qword [sym.imp.KERNEL32.dll_FreeConsole]
mov eax, esi
lea r11, [rsp + 0x110]
mov rbx, qword [r11 + 0x20]
mov rsi, qword [r11 + 0x28]
mov rsp, r11
pop rdi
ret