Function at 0x14001a2ac
Capabilities:
Get thread local storage value
Set thread local storage value

Disassembly:
mov qword [rsp + 0x10], rbx
mov qword [rsp + 0x18], rsi
push rdi
push r13
push r14
sub rsp, 0x30
mov rdi, rcx
mov ecx, dword [0x14003d17c]
call qword [sym.imp.api_ms_win_core_processthreads_l1_1_0.dll_TlsGetValue]
or ebx, 0xffffffff
mov rsi, rax
test rax, rax
jne 0x14001a2f5
mov ebx, dword [0x14003d17c]
lea rdx, [rsp + 0x50]
and dword [rsp + 0x50], eax
lea rsi, [rsp + 0x50]
mov ecx, ebx
call qword [sym.imp.api_ms_win_core_processthreads_l1_1_0.dll_TlsSetValue]
inc dword [rsi]
mov rax, qword [0x14003d048]
lea r13, [0x14003d048]
lea rdx, [0x140035650]
mov r14d, 0x1df
cmp rax, r13
je 0x14001a35b
test byte [rax + 0x1c], 1
je 0x14001a35b
mov eax, dword [rsi]
lea ecx, [rax + rax*4]
cmp ecx, 0x1e1
ja 0x14001a334
mov eax, ecx
mov ecx, r14d
sub rcx, rax
jmp 0x14001a336
xor ecx, ecx
lea r9, [rcx + rdx]
mov qword [rsp + 0x20], rdi
mov rcx, qword [0x14003d048]
lea r8, [0x1400367b8]
mov edx, 0x6c
mov rcx, qword [rcx + 0x10]
call fcn.140001370
mov rcx, qword [rdi + 0x80]
test rcx, rcx
je 0x14001a3d6
call qword [sym.imp.deviceassociation.dll_DafCloseAssociationContext]
mov r8d, eax
mov r10, qword [0x14003d048]
cmp r10, r13
je 0x14001a3ce
test byte [r10 + 0x1c], 4
je 0x14001a3ce
mov ecx, dword [rsi]
inc ecx
lea edx, [rcx + rcx*4]
cmp edx, 0x1e1
ja 0x14001a39c
mov eax, edx
mov rcx, r14
sub rcx, rax
jmp 0x14001a39e
xor ecx, ecx
mov rax, qword [rdi + 0x80]
lea r9, [0x140035650]
mov dword [rsp + 0x28], r8d
add r9, rcx
mov rcx, qword [r10 + 0x10]
lea r8, [0x1400367b8]
mov edx, 0x6d
mov qword [rsp + 0x20], rax
call fcn.140001730
and qword [rdi + 0x80], 0
mov rcx, qword [rdi + 0xd8]
test rcx, rcx
je 0x14001a3f0
call qword [sym.imp.api_ms_win_core_handle_l1_1_0.dll_CloseHandle]
and qword [rdi + 0xd8], 0
mov rcx, qword [rdi + 0xe0]
test rcx, rcx
je 0x14001a40a
call qword [sym.imp.api_ms_win_core_handle_l1_1_0.dll_CloseHandle]
and qword [rdi + 0xe0], 0
mov rcx, qword [rdi + 0xe8]
test rcx, rcx
je 0x14001a424
call qword [sym.imp.api_ms_win_core_handle_l1_1_0.dll_CloseHandle]
and qword [rdi + 0xe8], 0
mov rcx, qword [rdi + 0xf8]
test rcx, rcx
je 0x14001a43e
call qword [sym.imp.api_ms_win_core_handle_l1_1_0.dll_CloseHandle]
and qword [rdi + 0xf8], 0
mov rcx, qword [rdi + 0x88]
test rcx, rcx
je 0x14001a458
call qword [sym.imp.deviceassociation.dll_DafMemFree]
and qword [rdi + 0x88], 0
mov rcx, qword [rdi + 0xf0]
test rcx, rcx
je 0x14001a472
call qword [sym.imp.api_ms_win_core_handle_l1_1_0.dll_CloseHandle]
and qword [rdi + 0xf0], 0
mov rcx, qword [rdi]
test rcx, rcx
je 0x14001a48b
mov rax, qword [rcx]
mov rax, qword [rax + 0x10]
call qword [0x140034e68]
and qword [rdi], 0
mov rax, qword [0x14003d048]
cmp rax, r13
je 0x14001a4df
test byte [rax + 0x1c], 1
je 0x14001a4df
mov eax, dword [rsi]
lea ecx, [rax + rax*4]
cmp ecx, 0x1e1
ja 0x14001a4b1
mov eax, ecx
sub r14, rax
jmp 0x14001a4b4
xor r14d, r14d
mov rcx, qword [0x14003d048]
lea r9, [0x140035650]
add r9, r14
mov qword [rsp + 0x20], rdi
mov edx, 0x6e
lea r8, [0x1400367b8]
mov rcx, qword [rcx + 0x10]
call fcn.140001370
dec dword [rsi]
cmp ebx, 0xffffffff
je 0x14001a4fd
mov ecx, ebx
call qword [sym.imp.api_ms_win_core_processthreads_l1_1_0.dll_TlsGetValue]
test rax, rax
je 0x14001a4fd
xor edx, edx
mov ecx, ebx
call qword [sym.imp.api_ms_win_core_processthreads_l1_1_0.dll_TlsSetValue]
mov rbx, qword [rsp + 0x58]
mov rsi, qword [rsp + 0x60]
add rsp, 0x30
pop r14
pop r13
pop rdi
ret