Function at 0x1800024f8
Capabilities:
Encode data using xor

Disassembly:
mov rax, rsp
push rbp
lea rbp, [rax - 0x28]
sub rsp, 0x120
mov qword [rsp + 0x48], 0xfffffffffffffffe
mov qword [rax + 0x10], rbx
mov qword [rax + 0x18], rsi
mov qword [rax + 0x20], rdi
mov rax, qword [0x18002b528]
xor rax, rsp
mov qword [rbp + 0x10], rax
mov rdi, rcx
xor ebx, ebx
cmp byte [rcx + 0x10], bl
jne 0x18000253b
xor al, al
jmp 0x180002783
xor edx, edx
mov rcx, qword [rcx + 0x38]
call qword [sym.imp.KERNEL32.dll_WaitForSingleObject]
test eax, eax
jne 0x180002534
mov byte [rdi + 0x10], bl
mov dword [rsp + 0x20], ebx
mov r8d, dword [0x18002dde8]
mov ecx, r8d
imul ecx, r8d
mov eax, 0x66666667
imul ecx
sar edx, 1
mov eax, edx
shr eax, 0x1f
add edx, eax
lea eax, [rdx + rdx*4]
sub ecx, eax
cmp ecx, 3
jne 0x1800025a4
mov ecx, ebx
lea rdx, [rsp + 0x50]
mov eax, dword [rdx]
imul eax, eax, 0xdc
add r8d, eax
inc ecx
lea rdx, [rdx + 4]
movsxd rax, ecx
cmp rax, 0xbc
jb 0x180002581
mov dword [0x18002dde8], r8d
lea rdx, [rdi + 0x18]
xor r9d, r9d
lea r8, [rsp + 0x20]
mov rcx, qword [rdi + 0x40]
call qword [sym.imp.KERNEL32.dll_GetOverlappedResult]
test eax, eax
jne 0x180002698
mov r8d, dword [0x18002dde8]
mov ecx, r8d
imul ecx, r8d
imul ecx, r8d
mov eax, 0x38e38e39
imul ecx
sar edx, 1
mov eax, edx
shr eax, 0x1f
add edx, eax
lea eax, [rdx + rdx*8]
sub ecx, eax
cmp ecx, 6
jne 0x180002623
mov edx, ebx
mov r9d, 8
mov ecx, edx
and ecx, 1
dec ecx
not ecx
and ecx, r8d
mov eax, edx
sar eax, 1
mov edx, ecx
xor edx, eax
dec r9
jne 0x1800025f6
add r8d, edx
inc ebx
cmp ebx, 0x100
jl 0x1800025ee
mov dword [0x18002dde8], r8d
call qword [sym.imp.KERNEL32.dll_GetLastError]
lea rcx, [rsp + 0x28]
cmp eax, 0x6d
jne 0x180002663
call fcn.18000a030
nop
lea rax, [0x180023da8]
mov qword [rsp + 0x28], rax
lea rax, [0x180023dc8]
mov qword [rsp + 0x28], rax
lea rdx, [0x180029878]
lea rcx, [rsp + 0x28]
call fcn.18000a7b8
int3
lea rax, str.Failure_to_grab_read_result
mov qword [rsp + 0x40], rax
lea rdx, [rsp + 0x40]
call fcn.180009fb8
nop
lea rax, [0x180023da8]
mov qword [rsp + 0x28], rax
lea rdx, [0x1800298c0]
lea rcx, [rsp + 0x28]
call fcn.18000a7b8
int3
lea rbx, [rdi + 0x48]
mov rsi, qword [rbx + 8]
sub rsi, qword [rbx]
mov edx, dword [rsp + 0x20]
add rdx, rsi
mov rcx, rbx
call fcn.180003540
mov eax, dword [0x18002dde8]
lea ecx, [rax + 1]
imul ecx, eax
mov eax, 0x30c30c31
imul ecx
sar edx, 2
mov eax, edx
shr eax, 0x1f
add edx, eax
imul edx, edx, 0x15
sub ecx, edx
cmp ecx, 8
jne 0x1800026eb
mov ecx, 4
call fcn.1800095e8
mov ecx, dword [0x18002dde8]
mov dword [rax], ecx
mov r8d, dword [rsp + 0x20]
mov rcx, qword [rbx]
add rcx, rsi
mov rdx, qword [rdi + 0x60]
call fcn.180008f60
mov rcx, qword [rdi + 0x38]
call qword [sym.imp.KERNEL32.dll_ResetEvent]
mov r8d, dword [0x18002dde8]
lea ecx, [r8 + 2]
lea eax, [r8 + 1]
imul ecx, eax
imul ecx, r8d
mov eax, 0xb21642c9
imul ecx
add edx, ecx
sar edx, 4
mov eax, edx
shr eax, 0x1f
add edx, eax
imul edx, edx, 0x17
sub ecx, edx
cmp ecx, 4
jne 0x180002781
mov eax, 0x51eb851f
imul r8d
sar edx, 5
mov ecx, edx
shr ecx, 0x1f
add edx, ecx
imul edx, edx, 0x64
sub r8d, edx
add r8d, 0x2f4
movsxd rcx, r8d
mov eax, 4
mul rcx
mov rcx, 0xffffffffffffffff
cmovo rax, rcx
mov rcx, rax
call fcn.180008ef4
mov rcx, rax
call fcn.18000a234
mov al, 1
mov rcx, qword [rbp + 0x10]
xor rcx, rsp
call fcn.180008f30
lea r11, [rsp + 0x120]
mov rbx, qword [r11 + 0x18]
mov rsi, qword [r11 + 0x20]
mov rdi, qword [r11 + 0x28]
mov rsp, r11
pop rbp
ret