Function at 0x180173a20
Capabilities:
Query environment variable

Disassembly:
push rbp
push r12
push r13
push r14
push r15
sub rsp, 0x80
lea rbp, [rsp + 0x30]
mov qword [rbp + 0x80], rbx
mov qword [rbp + 0x88], rsi
mov qword [rbp + 0x90], rdi
mov rax, qword [0x1803bc678]
xor rax, rbp
mov qword [rbp + 0x48], rax
mov dword [rbp], r9d
mov rbx, rcx
mov qword [rbp + 0x20], r8
mov qword [rbp + 8], rdx
test rdx, rdx
jne 0x180173a74
xor eax, eax
jmp 0x1801741e9
call qword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll__errno]
lea rcx, [0x1803bc130]
mov eax, dword [rax]
mov dword [rbp + 0x10], eax
call fcn.180172e90
test eax, eax
je 0x180173a96
call qword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll_abort]
int3
mov eax, dword [0x1803e7e50]
lea r15, [0x180341688]
mov r12, qword [0x1803ee540]
test rbx, rbx
movabs r8, 0xffffffffffffff0
cmove rbx, qword [str.messages]
or r14, 0xffffffffffffffff
test eax, eax
mov qword [rbp + 0x28], rbx
cmove eax, r14d
xor r13d, r13d
mov dword [0x1803e7e50], eax
test r12, r12
je 0x180173b18
nop dword [rax + rax]
lea rdx, [r12 + 0x18]
mov rax, rbx
sub rdx, rbx
nop dword [rax + rax]
movzx ecx, byte [rax]
cmp cl, byte [rax + rdx]
jne 0x180173b04
inc rax
test cl, cl
jne 0x180173af0
mov eax, r13d
jmp 0x180173b09
sbb eax, eax
or eax, 1
test eax, eax
je 0x180173b60
js 0x180173b5b
mov r12, qword [r12]
test r12, r12
jne 0x180173ae0
lea rax, [0x180229000]
mov qword [rbp + 0x18], rax
movsxd r8, dword [rbp + 0xa8]
cmp r8d, 0x6c1
jg case.default.0x180173b59
je 0x180173cd4
cmp r8d, 5
ja case.default.0x180173b59
lea rdx, sym.MZ_7Wyf4v__La_5Ec_xEUjtaT_Cc_.__jRIY___V
mov ecx, dword [rdx + r8*4 + 0x174218]
add rcx, rdx
jmp rcx
mov r12, r13
jmp 0x180173b18
test r12, r12
je 0x180173b18
mov rdx, qword [r12 + 8]
mov qword [rbp + 0x18], rdx
movzx ecx, byte [rdx]
cmp cl, 0x2f
je 0x180173b23
cmp cl, 0x5c
je 0x180173b23
lea eax, [rcx - 0x41]
cmp al, 0x19
jbe 0x180173b8a
sub cl, 0x61
cmp cl, 0x19
ja 0x180173b90
cmp byte [rdx + 1], 0x3a
je 0x180173b23
mov rdi, r14
inc rdi
cmp byte [rdx + rdi], r13b
jne 0x180173b93
inc rdi
mov ebx, 0x101
lea rax, [rdi + 0x101]
lea rcx, [rax + 0xf]
cmp rcx, rax
ja 0x180173bb7
mov rcx, r8
and rcx, 0xfffffffffffffff0
mov rax, rcx
call fcn.1801e70d0
sub rsp, rcx
lea r14, [rsp + 0x30]
call qword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll__errno]
mov rdx, rbx
mov rcx, r14
mov dword [rax], r13d
call sub.api_ms_win_crt_stdio_l1_1_0.dll__getcwd
mov rsi, rax
test rax, rax
jne 0x180173c51
call qword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll__errno]
cmp dword [rax], 0x22
jne 0x180173c48
mov rax, rbx
shr rax, 1
add rax, 0x20
add rbx, rax
lea rax, [rbx + rdi]
lea rcx, [rax + 0xf]
cmp rcx, rax
ja 0x180173c16
movabs rcx, 0xffffffffffffff0
and rcx, 0xfffffffffffffff0
mov rax, rcx
call fcn.1801e70d0
sub rsp, rcx
lea r14, [rsp + 0x30]
call qword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll__errno]
mov rdx, rbx
mov rcx, r14
mov dword [rax], r13d
call sub.api_ms_win_crt_stdio_l1_1_0.dll__getcwd
mov rsi, rax
test rax, rax
je 0x180173be7
jmp 0x180173c51
test rsi, rsi
je 0x180173f34
xor edx, edx
mov rcx, r14
call sub.VCRUNTIME140.dll_strchr
mov r8, r15
sub r8, rax
movzx ecx, byte [rax + r8]
mov rdx, rax
mov byte [rax], cl
inc rax
test cl, cl
jne 0x180173c61
mov rcx, qword [rbp + 0x18]
nop word [rax + rax]
movzx eax, byte [rcx]
lea rcx, [rcx + 1]
mov byte [rdx], al
lea rdx, [rdx + 1]
test al, al
jne 0x180173c80
mov qword [rbp + 0x18], r14
or r14, 0xffffffffffffffff
jmp 0x180173b23
lea rdi, str.LC_COLLATE
jmp 0x180173ce4
lea rdi, str.LC_CTYPE
jmp 0x180173ce4
lea rdi, str.LC_MONETARY
jmp 0x180173ce4
lea rdi, str.LC_NUMERIC
jmp 0x180173ce4
lea rdi, str.LC_TIME
jmp 0x180173ce4
lea rdi, str.LC_ALL
jmp 0x180173ce4
lea rdi, str.LC_MESSAGES
jmp 0x180173ce4
lea rdi, str.LC_XXX
mov rdx, rdi
mov ecx, r8d
mov esi, r13d
call fcn.180171710
mov rbx, rax
test rax, rax
jne 0x180173d07
call fcn.18016f880
mov rbx, rax
mov esi, 1
movzx eax, byte [rbx]
cmp al, byte [0x18033ed90]
jne 0x180173d1e
movzx eax, byte [rbx + 1]
cmp al, byte [0x18033ed91]
je 0x180173d46
lea rcx, str.LANGUAGE
call qword [sym.imp.api_ms_win_crt_environment_l1_1_0.dll_getenv]
test rax, rax
je 0x180173d35
cmp byte [rax], r13b
jne 0x180173d43
test esi, esi
je 0x180173d46
call fcn.1801750a0
test rax, rax
je 0x180173d46
mov rbx, rax
mov r9, qword [rbp + 0x28]
nop word [rax + rax]
inc r14
cmp byte [r9 + r14], r13b
jne 0x180173d50
mov qword [rbp + 0x40], r14
or rax, 0xffffffffffffffff
inc rax
cmp byte [rdi + rax], r13b
jne 0x180173d61
add rax, 5
add rax, r14
lea rcx, [rax + 0xf]
cmp rcx, rax
ja 0x180173d84
movabs rcx, 0xffffffffffffff0
and rcx, 0xfffffffffffffff0
mov rax, rcx
call fcn.1801e70d0
sub rsp, rcx
lea rax, [rsp + 0x30]
mov qword [rbp + 0x30], rax
mov rcx, rax
sub rdi, rax
movzx eax, byte [rdi + rcx]
mov rdx, rcx
mov byte [rcx], al
inc rcx
test al, al
jne 0x180173da2
nop dword [rax]
nop word [rax + rax]
movzx eax, byte [r15]
lea r15, [r15 + 1]
mov byte [rdx], al
mov rsi, rdx
inc rdx
test al, al
jne 0x180173dc0
mov r8, r14
lea rdi, [0x180229014]
mov rdx, r9
mov rcx, rsi
call sub.VCRUNTIME140.dll_memcpy
mov rdx, r14
sub rdx, rdi
add rdx, rsi
movzx eax, byte [rdi]
mov byte [rdx + rdi], al
lea rdi, [rdi + 1]
test al, al
jne 0x180173df2
or rax, 0xffffffffffffffff
inc rax
cmp byte [rbx + rax], r13b
jne 0x180173e04
inc rax
lea rcx, [rax + 0xf]
cmp rcx, rax
ja 0x180173e23
movabs rcx, 0xffffffffffffff0
and rcx, 0xfffffffffffffff0
mov rax, rcx
call fcn.1801e70d0
sub rsp, rcx
lea rdx, str.POSIX
lea r15, [rsp + 0x30]
jmp 0x180173e4a
lea rdx, str.POSIX
xor r13d, r13d
movzx eax, byte [rbx]
test al, al
je 0x180173e6e
movzx ecx, al
movzx eax, cl
cmp cl, 0x3a
jne 0x180173e6a
movzx eax, byte [rbx + 1]
inc rbx
movzx ecx, al
test al, al
jne 0x180173e54
test al, al
jne 0x180173e79
mov word [r15], 0x43
jmp 0x180173f03
mov rcx, r15
nop dword [rax]
cmp al, 0x3a
je 0x180173e93
inc rbx
mov byte [rcx], al
inc rcx
movzx eax, byte [rbx]
test al, al
jne 0x180173e80
cmp dword [0x1803e7e50], 1
mov byte [rcx], 0
jne 0x180173f03
mov edx, Ordinal_50
mov rcx, r15
call sub.VCRUNTIME140.dll_strchr
lea rdx, str.POSIX
test rax, rax
jne 0x180173e4a
mov edx, 0x5c
mov rcx, r15
call sub.VCRUNTIME140.dll_strchr
lea rdx, str.POSIX
test rax, rax
jne 0x180173e4a
movzx ecx, byte [r15]
lea eax, [rcx - 0x41]
cmp al, 0x19
jbe 0x180173ee8
sub cl, 0x61
cmp cl, 0x19
ja 0x180173efc
cmp byte [r15 + 1], 0x3a
lea rdx, str.POSIX
je 0x180173e4a
jmp 0x180173f03
lea rdx, str.POSIX
movzx eax, byte [r15]
cmp al, byte [0x18033ed90]
jne 0x180173f1c
movzx eax, byte [r15 + 1]
cmp al, byte [0x18033ed91]
je 0x180173f34
mov rcx, r13
nop
movzx eax, byte [r15 + rcx]
inc rcx
cmp al, byte [rdx + rcx - 1]
jne 0x180173f4f
cmp rcx, 6
jne 0x180173f20
lea rcx, [0x1803bc130]
call fcn.180172fa0
test eax, eax
je 0x180174177
call qword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll_abort]
int3
mov r8, qword [rbp + 0x30]
mov r9, r12
mov rcx, qword [rbp + 0x18]
mov rdx, r15
call fcn.180175440
lea rdx, str.POSIX
mov r13, rax
test rax, rax
je 0x180173e47
mov r14, qword [rbp + 8]
lea rax, [rbp + 0x38]
mov r8, r14
mov qword [rsp + 0x20], rax
mov r9d, 1
mov rdx, r12
mov rcx, r13
call fcn.1801731d0
mov rsi, rax
test rax, rax
jne 0x18017400e
mov rax, qword [r13 + 0x20]
lea rdi, [r13 + 0x20]
xor r14d, r14d
lea rdx, str.POSIX
test rax, rax
je 0x180173e47
nop dword [rax]
mov r8, qword [rbp + 8]
lea rcx, [rbp + 0x38]
mov qword [rsp + 0x20], rcx
mov r9d, 1
mov rcx, rax
mov rdx, r12
call fcn.1801731d0
mov rsi, rax
cmp rax, 0xffffffffffffffff
je 0x180173f34
test rax, rax
jne 0x180174005
mov rax, qword [rdi + 8]
add rdi, 8
inc r14
test rax, rax
jne 0x180173fc0
jmp 0x180173e40
mov r13, qword [r13 + r14*8 + 0x20]
mov r14, qword [rbp + 8]
cmp rsi, 0xffffffffffffffff
je 0x180173f34
test rsi, rsi
je 0x180173e40
or rdi, 0xffffffffffffffff
inc rdi
cmp byte [r14 + rdi], 0
jne 0x180174025
mov r12, qword [rbp + 0x40]
inc rdi
mov qword [rbp + 0x30], rdi
lea rcx, [r12 + 0x29]
add rcx, rdi
call qword [0x180225ae8]
mov r15, qword [rbp + 0x38]
mov r14, rax
test rax, rax
je 0x1801740fe
mov rdx, qword [rbp + 8]
lea rcx, [rax + 0x28]
mov r8, rdi
call sub.VCRUNTIME140.dll_memcpy
mov rdx, qword [rbp + 0x28]
lea rdi, [r14 + 0x28]
add rdi, qword [rbp + 0x30]
lea r8, [r12 + 1]
mov rcx, rdi
call sub.VCRUNTIME140.dll_memcpy
mov eax, dword [rbp + 0xa8]
lea rcx, [0x1803bc0c0]
mov dword [r14 + 8], eax
mov qword [r14], rdi
mov eax, dword [0x1803ee548]
mov dword [r14 + 0xc], eax
mov qword [r14 + 0x10], r13
mov qword [r14 + 0x18], rsi
mov qword [r14 + 0x20], r15
call fcn.1801730b0
test eax, eax
je 0x1801740bb
call qword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll_abort]
int3
lea r8, [0x180174c40]
mov rcx, r14
lea rdx, [0x1803e7e48]
call fcn.180174610
lea rcx, [0x1803bc0c0]
mov rbx, rax
call fcn.180172fa0
test eax, eax
je 0x1801740eb
call qword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll_abort]
int3
test rbx, rbx
je 0x1801740f5
cmp qword [rbx], r14
je 0x1801740fe
mov rcx, r14
call qword [0x180225ad8]
call qword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll__errno]
cmp dword [rbp], 0
mov ecx, dword [rbp + 0x10]
mov dword [rax], ecx
je 0x18017415b
mov r9, qword [r13 + 0x10]
mov edx, dword [rbp + 0xa0]
mov rcx, qword [r9 + 0xe8]
call fcn.180174970
cmp eax, dword [r9 + 0xf0]
mov edi, 0
cmovb edi, eax
mov rax, rsi
test edi, edi
je 0x180174158
lea rbx, [r15 + rsi]
nop
xor edx, edx
mov rcx, rax
dec edi
call sub.VCRUNTIME140.dll_strchr
inc rax
cmp rax, rbx
jae 0x18017415b
test edi, edi
jne 0x180174140
mov rsi, rax
lea rcx, [0x1803bc130]
call fcn.180172fa0
test eax, eax
je 0x180174172
call qword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll_abort]
int3
mov rax, rsi
jmp 0x1801741e9
cmp dword [0x1803e7e50], 1
je 0x1801741bc
lea rcx, str.GETTEXT_LOG_UNTRANSLATED
call qword [sym.imp.api_ms_win_crt_environment_l1_1_0.dll_getenv]
mov r14d, dword [rbp]
mov rdi, qword [rbp + 0x20]
mov rbx, qword [rbp + 8]
test rax, rax
je 0x1801741c8
cmp byte [rax], 0
je 0x1801741c8
mov rdx, qword [rbp + 0x28]
mov r9, rdi
mov r8, rbx
mov dword [rsp + 0x20], r14d
mov rcx, rax
call fcn.180175710
jmp 0x1801741c8
mov rbx, qword [rbp + 8]
mov rdi, qword [rbp + 0x20]
mov r14d, dword [rbp]
call qword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll__errno]
mov ecx, dword [rbp + 0x10]
mov dword [rax], ecx
test r14d, r14d
je 0x1801741e6
cmp dword [rbp + 0xa0], 1
cmove rdi, rbx
mov rbx, rdi
mov rax, rbx
mov rcx, qword [rbp + 0x48]
xor rcx, rbp
call fcn.1801e5c70
mov rbx, qword [rbp + 0x80]
mov rsi, qword [rbp + 0x88]
mov rdi, qword [rbp + 0x90]
lea rsp, [rbp + 0x50]
pop r15
pop r14
pop r13
pop r12
pop rbp
ret