Function at 0x140022e28
Capabilities:
Query environment variable
Read file via mapping

Disassembly:
mov rax, rsp
push rbp
push rsi
push rdi
push r12
push r13
push r14
push r15
lea rbp, [rax - 0x208]
sub rsp, 0x2d0
mov qword [rsp + 0x58], 0xfffffffffffffffe
mov qword [rax + 0x18], rbx
mov rax, qword [0x14004ffa8]
xor rax, rsp
mov qword [rbp + 0x1c0], rax
mov edi, edx
mov rbx, rcx
xor edx, edx
mov r8d, 0x208
lea rcx, [rbp - 0x50]
call sub.msvcrt.dll_memset
lea r14, [rbx + 0x28]
mov r8d, 0x104
lea rdx, [rbp - 0x50]
mov rcx, qword [r14]
call qword [sym.imp.KERNEL32.dll_ExpandEnvironmentStringsW]
xor r12d, r12d
test eax, eax
jne 0x140022ea8
mov rcx, rbx
call fcn.140022820
mov eax, 0x80004005
jmp 0x140023182
mov r8d, edi
lea rcx, [rsp + 0x48]
call fcn.14002e6c4
nop
mov edi, dword [rsp + 0x50]
test edi, edi
jne 0x1400230f5
mov dword [rsp + 0x40], r12d
lea r8, [rsp + 0x40]
lea rdx, str.B0AA5481_05C1_4719_9A29_EE713099C5DF
mov rcx, rbx
call fcn.140022d08
mov edi, eax
cmp dword [rsp + 0x40], r12d
jne 0x1400230f3
mov edi, r12d
mov qword [rsp + 0x30], r12
mov dword [rsp + 0x28], 0x2000
mov dword [rsp + 0x20], 3
xor r9d, r9d
lea edx, [r9 + 1]
mov r8d, edx
lea rcx, [rbp - 0x50]
call qword [sym.imp.KERNEL32.dll_CreateFileW]
mov qword [rbx + 0x38], rax
cmp rax, 0xffffffffffffffff
je 0x1400230df
mov qword [rsp + 0x28], r12
mov dword [rsp + 0x20], r12d
xor r9d, r9d
xor edx, edx
lea r8d, [r9 + 2]
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_CreateFileMappingW]
mov qword [rbx + 0x40], rax
cmp rax, 0xffffffffffffffff
je 0x1400230c9
mov qword [rsp + 0x20], r12
xor r9d, r9d
xor r8d, r8d
lea edx, [r9 + 4]
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_MapViewOfFile]
mov qword [rbx + 0x48], rax
test rax, rax
je 0x1400230b8
xor edx, edx
lea r8d, [rdx + 0x34]
lea rcx, [rsp + 0x70]
call sub.msvcrt.dll_memset
lea rdx, [rsp + 0x70]
mov rcx, qword [rbx + 0x38]
call qword [sym.imp.KERNEL32.dll_GetFileInformationByHandle]
mov rax, qword [rbp - 0x7c]
test eax, eax
jne 0x140022fa3
cmp dword [rbp - 0x78], r12d
jne 0x140022fa3
mov rax, qword [rsp + 0x74]
mov qword [rbx + 0x30], rax
mov edi, 0x80070018
mov eax, dword [rbp - 0x6c]
cmp eax, 0x44
cmova edi, r12d
jbe 0x1400230aa
mov r12d, eax
mov rax, qword [rbx + 0x48]
movsxd r13, dword [r12 + rax - 4]
lea rsi, [r13 + 0x2c]
mov eax, r12d
sub rax, rsi
cmp rsi, r12
sbb r15, r15
and r15, rax
mov rcx, qword [rbx + 0x50]
call fcn.140035cb4
call fcn.140008898
mov rcx, qword [rax + 8]
test rcx, rcx
je 0x140022ffc
cmp dword [rcx], 0
jbe 0x140022ffc
call fcn.140008898
lea rax, [r15 + rsi]
cmp rax, r12
jbe 0x14002303a
mov esi, 0x80070018
mov edi, esi
call fcn.140008898
mov rcx, qword [rax + 8]
xor r12d, r12d
test rcx, rcx
je 0x1400230aa
cmp dword [rcx], r12d
jbe 0x1400230aa
call fcn.140008898
lea r8, str.More_bytes_to_copy_from_general_cache_wordlist_file_than_file_size
mov edx, esi
jmp 0x140023077
mov rcx, rsi
call fcn.140035cbc
mov rcx, rax
mov qword [rbx + 0x50], rax
xor r12d, r12d
test rax, rax
jne 0x14002307e
mov edi, 0x8007000e
call fcn.140008898
mov rcx, qword [rax + 8]
test rcx, rcx
je 0x1400230aa
cmp dword [rcx], r12d
jbe 0x1400230aa
call fcn.140008898
lea r8, str.Failed_allocating_memory_for_data_to_copy_from_TrainedDataStore_UDICT_
mov edx, edi
call fcn.140021e20
jmp 0x1400230aa
mov rax, qword [rbx + 0x48]
movups xmm0, xmmword [r15 + rax]
movdqu xmmword [rcx], xmm0
mov rdx, qword [rbx + 0x48]
add rdx, 0x10
add rdx, r15
mov rcx, qword [rbx + 0x50]
add rcx, 0x10
lea r8, [r13 + 0x1c]
call sub.msvcrt.dll_memcpy
mov dword [rbx + 0x58], esi
mov rcx, qword [rbx + 0x48]
call qword [sym.imp.KERNEL32.dll_UnmapViewOfFile]
mov qword [rbx + 0x48], r12
mov rcx, qword [rbx + 0x40]
call qword [sym.imp.KERNEL32.dll_CloseHandle]
or qword [rbx + 0x40], 0xffffffffffffffff
jmp 0x1400230ce
mov edi, 0x80070002
mov rcx, qword [rbx + 0x38]
call qword [sym.imp.KERNEL32.dll_CloseHandle]
or qword [rbx + 0x38], 0xffffffffffffffff
jmp 0x1400230f3
call qword [sym.imp.KERNEL32.dll_GetLastError]
movzx edi, ax
or edi, 0x80070000
test eax, eax
cmovle edi, eax
test edi, edi
js 0x140023176
xor eax, eax
mov qword [rsp + 0x60], rax
mov qword [rsp + 0x68], rax
mov rcx, qword [rbx + 0x50]
mov edx, dword [rbx + 0x58]
sub edx, 0x10
lea rax, [rcx + 0x10]
neg rcx
sbb rcx, rcx
and rcx, rax
lea r8, [rsp + 0x60]
call fcn.14002de2c
mov edi, eax
test eax, eax
js 0x140023143
mov rcx, qword [rbx + 0x50]
mov rax, qword [rsp + 0x60]
cmp rax, qword [rcx]
jne 0x140023143
mov rax, qword [rsp + 0x68]
cmp rax, qword [rcx + 8]
je 0x140023159
mov dword [rbx + 0x58], r12d
mov rcx, qword [rbx + 0x50]
call fcn.140035cb4
mov qword [rbx + 0x50], r12
mov edi, 0x80070017
test edi, edi
js 0x140023176
mov rcx, qword [r14]
call qword [sym.imp.OLEAUT32.dll_SysStringLen]
mov qword [r14], r12
mov rdx, r14
mov rcx, rbx
call fcn.140023548
mov edi, eax
lea rcx, [rsp + 0x48]
call fcn.14002e750
mov eax, edi
mov rcx, qword [rbp + 0x1c0]
xor rcx, rsp
call fcn.1400362c0
mov rbx, qword [rsp + 0x320]
add rsp, 0x2d0
pop r15
pop r14
pop r13
pop r12
pop rdi
pop rsi
pop rbp
ret