Function at 0x14001d150
Capabilities:
Query environment variable

Disassembly:
push r15
push r14
push r13
push r12
push rbp
push rdi
push rsi
push rbx
sub rsp, 0x48
mov qword [rsp + 0xa8], r9
mov esi, ecx
mov r14, rdx
mov r13, r8
test r8, r8
je 0x14001d47e
mov r9d, dword [0x14002407c]
test r9d, r9d
je 0x14001d318
cmp dword [0x140024060], 0xffffffff
je 0x14001d32c
mov eax, dword [0x140029198]
test eax, eax
jne 0x14001d32c
movzx edx, byte [r13]
cmp dl, 0x2d
je 0x14001d360
mov r8d, dword [0x140024060]
test r8d, r8d
jne 0x14001d1c3
cmp dl, 0x2b
jne 0x14001d1d4
and dword [rsp + 0xb8], 0xfffffffe
cmp dl, 0x2b
je 0x14001d368
mov qword [0x140029190], 0
test eax, eax
je 0x14001d1f7
mov dword [0x140024064], 0xffffffff
mov dword [0x140024068], 0xffffffff
mov edi, dword [rsp + 0xb8]
mov r12d, dword [rsp + 0xb8]
lea rbp, [0x140025da8]
and edi, 2
and r12d, 1
test eax, eax
je 0x14001d289
mov dword [0x140029198], 0
mov ebx, dword [0x14002407c]
cmp ebx, esi
jge 0x14001d440
movsxd rax, ebx
mov r15, qword [r14 + rax*8]
cmp byte [r15], 0x2d
mov qword [0x140024070], r15
je 0x14001d378
mov qword [0x140024070], rbp
test edi, edi
jne 0x14001d4a0
test r12d, r12d
je 0x14001d47e
mov r15d, dword [0x140024068]
cmp r15d, 0xffffffff
je 0x14001d3e0
mov edx, dword [0x140024064]
cmp edx, 0xffffffff
jne 0x14001d3f8
add ebx, 1
mov dword [0x14002407c], ebx
mov r9, qword [0x140024070]
movzx eax, byte [r9]
test al, al
je 0x14001d218
cmp qword [rsp + 0xa8], 0
je 0x14001d2c6
movsxd rdx, dword [0x14002407c]
cmp qword [r14 + rdx*8], r9
je 0x14001d2c6
cmp al, 0x2d
je 0x14001d70d
test byte [rsp + 0xb8], 4
jne 0x14001d4d1
lea rbx, [r9 + 1]
movsx r12d, al
mov qword [0x140024070], rbx
cmp al, 0x3a
jne 0x14001d528
cmp byte [r9 + 1], 0
jne 0x14001d2eb
add dword [0x14002407c], 1
mov ecx, dword [0x140024080]
test ecx, ecx
je 0x14001d300
cmp byte [r13], 0x3a
jne 0x14001d6a8
mov dword [0x140024078], r12d
mov r12d, 0x3f
jmp 0x14001d484
mov dword [0x140029198], 1
mov dword [0x14002407c], 1
xor edx, edx
xor r8d, r8d
lea rcx, str.POSIXLY_CORRECT
call qword [sym.imp.KERNEL32.dll_GetEnvironmentVariableW]
movzx edx, byte [r13]
test eax, eax
setne al
movzx eax, al
mov dword [0x140024060], eax
mov eax, dword [0x140029198]
cmp dl, 0x2d
jne 0x14001d1b2
or dword [rsp + 0xb8], 2
add r13, 1
jmp 0x14001d1d4
movzx eax, byte [r15 + 1]
test al, al
jne 0x14001d62b
mov edx, 0x2d
mov rcx, r13
call sub.msvcrt.dll_strchr
test rax, rax
je 0x14001d248
cmp dword [0x140024068], 0xffffffff
je 0x14001d71f
cmp dword [0x140024064], 0xffffffff
je 0x14001d702
lea rbx, [r15 + 1]
mov qword [0x140024070], rbx
cmp byte [r15 + 1], 0
je 0x14001d5e8
mov r12d, 0x2d
jmp 0x14001d2eb
mov dword [0x140024068], ebx
add ebx, 1
mov dword [0x14002407c], ebx
jmp 0x14001d289
mov ecx, r15d
mov r9, r14
mov r8d, ebx
mov dword [rsp + 0x38], edx
call fcn.14001cc60
mov ecx, dword [0x14002407c]
mov edx, dword [rsp + 0x38]
mov dword [0x140024064], 0xffffffff
mov eax, ecx
sub edx, r15d
add ecx, 1
sub eax, edx
mov dword [0x14002407c], ecx
mov dword [0x140024068], eax
mov eax, dword [0x140029198]
jmp 0x14001d214
mov esi, dword [0x140024064]
lea rax, [0x140025da8]
mov edi, dword [0x140024068]
mov qword [0x140024070], rax
cmp esi, 0xffffffff
jne 0x14001d4b8
cmp edi, 0xffffffff
je 0x14001d46a
mov dword [0x14002407c], edi
mov dword [0x140024064], 0xffffffff
mov dword [0x140024068], 0xffffffff
mov r12d, 0xffffffff
mov eax, r12d
add rsp, 0x48
pop rbx
pop rsi
pop rdi
pop rbp
pop r12
pop r13
pop r14
pop r15
ret
add ebx, 1
mov qword [0x140029190], r15
mov r12d, 1
mov dword [0x14002407c], ebx
jmp 0x14001d484
mov r9, r14
mov r8d, ebx
mov edx, esi
mov ecx, edi
sub esi, edi
call fcn.14001cc60
sub dword [0x14002407c], esi
jmp 0x14001d46a
xor edx, edx
cmp al, 0x3a
je 0x14001d4ea
movsx edx, al
mov rcx, r13
call sub.msvcrt.dll_strchr
xor edx, edx
test rax, rax
setne dl
mov dword [rsp + 0x20], edx
mov r9, qword [rsp + 0xb0]
mov rdx, r13
mov rcx, r14
mov r8, qword [rsp + 0xa8]
call fcn.14001cdb0
mov r12d, eax
cmp eax, 0xffffffff
je 0x14001d698
lea rax, [0x140025da8]
mov qword [0x140024070], rax
jmp 0x14001d484
cmp r12d, 0x2d
je 0x14001d72d
mov edx, r12d
mov rcx, r13
mov qword [rsp + 0x38], r9
call sub.msvcrt.dll_strchr
mov r9, qword [rsp + 0x38]
test rax, rax
je 0x14001d2dd
cmp qword [rsp + 0xa8], 0
movzx edx, byte [rax + 1]
je 0x14001d60b
cmp r12d, 0x57
jne 0x14001d60b
cmp dl, 0x3b
jne 0x14001d60b
cmp byte [r9 + 1], 0
jne 0x14001d768
mov eax, dword [0x14002407c]
add eax, 1
mov dword [0x14002407c], eax
cmp eax, esi
jl 0x14001d75b
mov edx, dword [0x140024080]
lea rax, [0x140025da8]
mov qword [0x140024070], rax
test edx, edx
je 0x14001d5c8
cmp byte [r13], 0x3a
je 0x14001d5c8
mov edx, 0x57
lea rcx, str.option_requires_an_argument_____c
call fcn.14001cd20
mov dword [0x140024078], 0x57
cmp byte [r13], 0x3a
je 0x14001d7d3
mov r12d, 0x3f
jmp 0x14001d484
mov edx, 0x2d
mov rcx, r13
call sub.msvcrt.dll_strchr
test rax, rax
je 0x14001d47e
movzx edx, byte [rax + 1]
mov r9, r15
mov r12d, 0x2d
cmp dl, 0x3a
je 0x14001d6bc
cmp byte [r9 + 1], 0
jne 0x14001d484
add dword [0x14002407c], 1
jmp 0x14001d484
mov edi, dword [0x140024068]
cmp edi, 0xffffffff
je 0x14001d643
cmp dword [0x140024064], 0xffffffff
je 0x14001d6f7
lea r9, [r15 + 1]
mov qword [0x140024070], r9
cmp al, 0x2d
jne 0x14001d298
cmp byte [r15 + 2], 0
jne 0x14001d298
mov esi, dword [0x140024064]
lea r8d, [rbx + 1]
lea rax, [0x140025da8]
mov dword [0x14002407c], r8d
mov qword [0x140024070], rax
cmp esi, 0xffffffff
je 0x14001d46a
mov r9, r14
jmp 0x14001d4be
mov r9, qword [0x140024070]
movzx eax, byte [r9]
jmp 0x14001d2c6
mov edx, r12d
lea rcx, str.unknown_option_____c
call fcn.14001cd20
jmp 0x14001d300
mov ecx, dword [0x14002407c]
mov qword [0x140029190], 0
cmp byte [r9 + 1], 0
lea edx, [rcx + 1]
je 0x14001d738
mov qword [0x140029190], rbx
lea rax, [0x140025da8]
mov dword [0x14002407c], edx
mov qword [0x140024070], rax
jmp 0x14001d484
mov dword [0x140024064], ebx
jmp 0x14001d643
mov dword [0x140024064], ebx
jmp 0x14001d3b5
add r9, 1
xor edx, edx
mov qword [0x140024070], r9
jmp 0x14001d4ea
lea rbx, [r15 + 1]
mov r9, r15
mov qword [0x140024070], rbx
mov r15, r9
jmp 0x14001d3c0
cmp byte [rax + 2], 0x3a
je 0x14001d6de
mov dword [0x14002407c], edx
cmp esi, edx
jle 0x14001d793
movsxd rdx, edx
mov rax, qword [r14 + rdx*8]
lea edx, [rcx + 2]
mov qword [0x140029190], rax
jmp 0x14001d6de
cdqe
mov rax, qword [r14 + rax*8]
mov qword [0x140024070], rax
mov dword [rsp + 0x20], 0
mov r9, qword [rsp + 0xb0]
mov rdx, r13
mov rcx, r14
mov r8, qword [rsp + 0xa8]
call fcn.14001cdb0
mov r12d, eax
jmp 0x14001d515
lea rax, [0x140025da8]
mov qword [0x140024070], rax
mov eax, dword [0x140024080]
test eax, eax
je 0x14001d7c1
cmp byte [r13], 0x3a
je 0x14001d7c1
mov edx, r12d
lea rcx, str.option_requires_an_argument_____c
call fcn.14001cd20
mov dword [0x140024078], r12d
cmp byte [r13], 0x3a
jne 0x14001d5dd
mov r12d, 0x3a
jmp 0x14001d484