Function at 0x14001dcc0
Capabilities:
Query environment variable

Disassembly:
mov qword [rsp + 0x18], rdi
push r14
sub rsp, 0x20
lea rcx, str.PTC_USE_SYS_DEFAULT_LANG_CHARSET
xor dil, dil
call qword [sym.imp.api_ms_win_crt_environment_l1_1_0.dll_getenv]
test rax, rax
je 0x14001dd1f
movsxd rax, dword [0x1401ba2c0]
mov dil, 1
imul rcx, rax, 0x38
mov rax, qword [0x140175020]
test byte [rcx + rax + 0x18], 0x40
je 0x14001dd1f
mov r8, qword [rcx + rax]
lea rcx, str._s_MONITOR:_s:
mov rdx, qword [section..data]
call fcn.140002310
lea rcx, str.User_has_set_env_variable_named_PTC_USE_SYS_DEFAULT_LANG_CHARSET
call fcn.140001fb0
cmp dword [0x1401b9ee0], 0
lea r14, [0x140000000]
jne 0x14001dede
test dil, dil
jne 0x14001dede
lea rcx, str.LANG
mov qword [rsp + 0x30], rbx
call fcn.14001c820
mov rbx, rax
test rax, rax
je 0x14001ddc3
cmp byte [rax], dil
je 0x14001ddc3
mov rcx, rax
call fcn.14001db10
mov dword [0x1401b9ee0], eax
test eax, eax
je 0x14001ddc3
movsxd rcx, dword [0x1401ba2c0]
mov rax, qword [0x140175020]
imul rdx, rcx, 0x38
test byte [rdx + rax + 0x18], 0x40
je 0x14001ded9
mov r8, qword [rdx + rax]
lea rcx, str._s_MONITOR:_s:
mov rdx, qword [section..data]
call fcn.140002310
movsxd rdx, dword [0x1401b9ee0]
lea rcx, str.Setting_System_Language_to__d___s__from_LANG___s__n
mov r9, rbx
mov r8, qword [r14 + rdx*8 + 0x17e290]
call fcn.140001fb0
jmp 0x14001ded9
xor edx, edx
mov qword [rsp + 0x38], rsi
lea ecx, [rdx + 2]
call qword [sym.imp.api_ms_win_crt_locale_l1_1_0.dll_setlocale]
mov rcx, rax
call fcn.140002810
lea rdx, [0x1401ba268]
mov ecx, 2
mov rsi, rax
call qword [sym.imp.api_ms_win_crt_locale_l1_1_0.dll_setlocale]
mov rbx, rax
test rax, rax
je 0x14001de63
cmp byte [rax], 0
je 0x14001de63
mov rcx, rax
call fcn.14001db10
mov dword [0x1401b9ee0], eax
test eax, eax
je 0x14001de63
movsxd rcx, dword [0x1401ba2c0]
mov rax, qword [0x140175020]
imul rdx, rcx, 0x38
test byte [rdx + rax + 0x18], 0x40
je 0x14001deb8
mov r8, qword [rdx + rax]
lea rcx, str._s_MONITOR:_s:
mov rdx, qword [section..data]
call fcn.140002310
movsxd rdx, dword [0x1401b9ee0]
lea rcx, str.Setting_System_Language_to__d___s__from_CTYPE_locale___s__n
mov r9, rbx
mov r8, qword [r14 + rdx*8 + 0x17e290]
call fcn.140001fb0
jmp 0x14001deb8
movsxd rax, dword [0x1401ba2c0]
imul rcx, rax, 0x38
mov rax, qword [0x140175020]
mov dword [0x1401b9ee0], 0xe
test byte [rcx + rax + 0x18], 0x40
je 0x14001deb8
mov r8, qword [rcx + rax]
lea rcx, str._s_MONITOR:_s:
mov rdx, qword [section..data]
call fcn.140002310
movsxd rdx, dword [0x1401b9ee0]
lea rcx, str.Setting_System_Language_to_default__d___s__n
mov r8, qword [r14 + rdx*8 + 0x17e290]
call fcn.140001fb0
test rsi, rsi
je 0x14001ded4
mov rdx, rsi
mov ecx, 2
call qword [sym.imp.api_ms_win_crt_locale_l1_1_0.dll_setlocale]
mov rcx, rsi
call qword [sym.imp.api_ms_win_crt_heap_l1_1_0.dll_free]
mov rsi, qword [rsp + 0x38]
mov rbx, qword [rsp + 0x30]
cmp dword [reloc.WS2_32.dll_accept], 1
jne 0x14001df3a
test dil, dil
jne 0x14001df3a
movsxd rax, dword [0x1401b9ee0]
mov eax, dword [r14 + rax*4 + 0x17e430]
mov dword [reloc.WS2_32.dll_accept], eax
movsxd rax, dword [0x1401ba2c0]
imul rdx, rax, 0x38
mov rax, qword [0x140175020]
test byte [rdx + rax + 0x18], 0x40
je 0x14001df85
mov r8, qword [rdx + rax]
lea rcx, str._s_MONITOR:_s:
mov rdx, qword [section..data]
call fcn.140002310
lea rcx, [0x14017e878]
jmp 0x14001df71
movsxd rax, dword [0x1401ba2c0]
imul rcx, rax, 0x38
mov rax, qword [0x140175020]
test byte [rcx + rax + 0x18], 0x40
je 0x14001df85
mov r8, qword [rcx + rax]
lea rcx, str._s_MONITOR:_s:
mov rdx, qword [section..data]
call fcn.140002310
lea rcx, str.Setting_System_CharSet_to__d___s__n
movsxd rdx, dword [reloc.WS2_32.dll_accept]
mov r8, qword [r14 + rdx*8 + 0x17e120]
call fcn.140001fb0
mov rdi, qword [rsp + 0x40]
add rsp, 0x20
pop r14
ret