Function at 0x140002aa0
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 r15d, dword [rsp + 0xb8]
mov r12d, ecx
mov rbp, rdx
mov r13, r8
mov r14, r9
test r8, r8
je 0x140002e46
mov r9d, dword [0x14000f04c]
mov eax, dword [0x14000f030]
test r9d, r9d
je 0x140002cd0
cmp eax, 0xffffffff
je 0x140002ce4
mov edx, dword [0x140016d88]
test edx, edx
jne 0x140002ce4
movzx eax, byte [r13]
cmp al, 0x2d
je 0x140002d17
mov r8d, dword [0x14000f030]
test r8d, r8d
jne 0x140002df0
cmp al, 0x2b
je 0x140002ee0
mov qword [0x140016d80], 0
test edx, edx
je 0x140002be4
mov dword [0x14000f034], 0xffffffff
mov dword [0x14000f038], 0xffffffff
nop word cs:[rax + rax]
mov dword [0x140016d88], 0
mov ebx, dword [0x14000f04c]
cmp ebx, r12d
jge 0x140002e08
movsxd rax, ebx
mov rsi, qword [rbp + rax*8]
cmp byte [rsi], 0x2d
je 0x140002d28
lea rax, [0x140012768]
mov qword [0x14000f040], rax
test r15b, 2
jne 0x140002e60
test r15b, 1
je 0x140002e46
mov esi, dword [0x14000f038]
cmp esi, 0xffffffff
je 0x140002de0
mov edi, dword [0x14000f034]
cmp edi, 0xffffffff
je 0x140002bdb
mov edx, edi
mov r9, rbp
mov r8d, ebx
mov ecx, esi
call fcn.1400025b0
sub edi, esi
mov eax, ebx
mov dword [0x14000f034], 0xffffffff
sub eax, edi
mov dword [0x14000f038], eax
add ebx, 1
mov dword [0x14000f04c], ebx
mov rdi, qword [0x14000f040]
movzx eax, byte [rdi]
test al, al
je 0x140002b50
test r14, r14
je 0x140002c66
movsxd rdx, dword [0x14000f04c]
cmp qword [rbp + rdx*8], rdi
je 0x140002c66
cmp al, 0x2d
je 0x140002f83
and r15d, 4
je 0x140002e92
cmp al, 0x3a
je 0x140002f8e
movsx edx, al
mov rcx, r13
call sub.msvcrt.dll_strchr
test rax, rax
setne al
movzx eax, al
mov dword [rsp + 0x20], eax
mov r8, r14
mov rdx, r13
mov rcx, rbp
mov r9, qword [rsp + 0xb0]
call fcn.140002710
mov ebx, eax
cmp eax, 0xffffffff
jne 0x140003046
mov rdi, qword [0x14000f040]
movzx eax, byte [rdi]
lea r15, [rdi + 1]
movsx ebx, al
mov qword [0x14000f040], r15
cmp al, 0x3a
je 0x140002ea8
cmp ebx, 0x2d
je 0x140002d73
mov edx, ebx
mov rcx, r13
call sub.msvcrt.dll_strchr
test rax, rax
je 0x140002ea8
movzx edx, byte [rax + 1]
test r14, r14
je 0x140002caf
cmp ebx, 0x57
jne 0x140002caf
cmp dl, 0x3b
je 0x140002f95
cmp dl, 0x3a
je 0x140002d9d
cmp byte [rdi + 1], 0
jne 0x140002e4b
add dword [0x14000f04c], 1
jmp 0x140002e4b
mov dword [0x140016d88], 1
mov dword [0x14000f04c], 1
xor edx, edx
xor r8d, r8d
lea rcx, str.POSIXLY_CORRECT
call qword [sym.imp.KERNEL32.dll_GetEnvironmentVariableW]
mov edx, dword [0x140016d88]
test eax, eax
setne al
movzx eax, al
mov dword [0x14000f030], eax
movzx eax, byte [r13]
cmp al, 0x2d
jne 0x140002b07
or r15d, 2
add r13, 1
jmp 0x140002b1f
movzx eax, byte [rsi + 1]
test al, al
jne 0x140002ee9
mov edx, 0x2d
mov rcx, r13
call sub.msvcrt.dll_strchr
test rax, rax
je 0x140002b7a
cmp dword [0x14000f038], 0xffffffff
je 0x140002d60
cmp dword [0x14000f034], 0xffffffff
je 0x140003002
lea r15, [rsi + 1]
mov rdi, rsi
mov ebx, 0x2d
mov qword [0x14000f040], r15
cmp byte [rdi + 1], 0
jne 0x140002eb5
mov edx, 0x2d
mov rcx, r13
call sub.msvcrt.dll_strchr
test rax, rax
je 0x140002e46
cmp byte [rax + 1], 0x3a
jne 0x140002cc2
mov qword [0x140016d80], 0
cmp byte [rdi + 1], 0
mov edx, dword [0x14000f04c]
je 0x140003059
mov qword [0x140016d80], r15
lea rax, [0x140012768]
add edx, 1
mov qword [0x14000f040], rax
mov dword [0x14000f04c], edx
jmp 0x140002e4b
mov dword [0x14000f038], ebx
jmp 0x140002bdb
and r15d, 0xfffffffe
cmp al, 0x2b
jne 0x140002b1f
jmp 0x140002d1b
mov esi, dword [0x14000f034]
lea rax, [0x140012768]
mov edi, dword [0x14000f038]
mov qword [0x14000f040], rax
cmp esi, 0xffffffff
jne 0x140002e77
cmp edi, 0xffffffff
je 0x140002e32
mov dword [0x14000f04c], edi
mov dword [0x14000f034], 0xffffffff
mov dword [0x14000f038], 0xffffffff
mov ebx, 0xffffffff
mov eax, ebx
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 [0x140016d80], rsi
mov dword [0x14000f04c], ebx
mov ebx, 1
jmp 0x140002e4b
mov edx, esi
sub esi, edi
mov r8d, ebx
mov r9, rbp
mov ecx, edi
sub ebx, esi
call fcn.1400025b0
mov dword [0x14000f04c], ebx
jmp 0x140002e32
lea r15, [rdi + 1]
movsx ebx, al
mov qword [0x14000f040], r15
cmp al, 0x3a
jne 0x140002c85
cmp byte [rdi + 1], 0
jne 0x140002eb5
add dword [0x14000f04c], 1
mov ecx, dword [0x14000f050]
test ecx, ecx
je 0x140002eca
cmp byte [r13], 0x3a
jne 0x140002f70
mov dword [0x14000f048], ebx
mov ebx, 0x3f
jmp 0x140002e4b
and r15d, 0xfffffffe
jmp 0x140002d1b
mov ecx, dword [0x14000f038]
cmp ecx, 0xffffffff
je 0x140002f01
cmp dword [0x14000f034], 0xffffffff
je 0x14000300d
lea rdi, [rsi + 1]
mov qword [0x14000f040], rdi
cmp al, 0x2d
jne 0x140002bf6
cmp byte [rsi + 2], 0
jne 0x140002bf6
mov esi, dword [0x14000f034]
add ebx, 1
lea rax, [0x140012768]
mov dword [0x14000f04c], ebx
mov qword [0x14000f040], rax
cmp esi, 0xffffffff
je 0x140002e32
mov r8d, ebx
mov edx, esi
mov r9, rbp
mov dword [rsp + 0x3c], ecx
call fcn.1400025b0
mov ecx, dword [rsp + 0x3c]
sub esi, ecx
sub ebx, esi
mov dword [0x14000f04c], ebx
jmp 0x140002e32
mov edx, ebx
lea rcx, str.unknown_option_____c
call fcn.140002680
jmp 0x140002eca
add rdi, 1
mov qword [0x14000f040], rdi
xor eax, eax
jmp 0x140002c37
cmp byte [rdi + 1], 0
jne 0x140003026
mov eax, dword [0x14000f04c]
add eax, 1
mov dword [0x14000f04c], eax
cmp eax, r12d
jl 0x140003018
mov edx, dword [0x14000f050]
lea rax, [0x140012768]
mov qword [0x14000f040], rax
test edx, edx
je 0x140002fe3
cmp byte [r13], 0x3a
je 0x140002fe3
mov edx, 0x57
lea rcx, str.option_requires_an_argument_____c
call fcn.140002680
mov dword [0x14000f048], 0x57
cmp byte [r13], 0x3a
jne 0x140002ed0
mov ebx, 0x3a
jmp 0x140002e4b
mov dword [0x14000f034], ebx
jmp 0x140002d60
mov dword [0x14000f034], ebx
jmp 0x140002f01
cdqe
mov rax, qword [rbp + rax*8]
mov qword [0x14000f040], rax
mov dword [rsp + 0x20], 0
mov r8, r14
mov rdx, r13
mov rcx, rbp
mov r9, qword [rsp + 0xb0]
call fcn.140002710
mov ebx, eax
lea rax, [0x140012768]
mov qword [0x14000f040], rax
jmp 0x140002e4b
cmp byte [rax + 2], 0x3a
je 0x140002dbf
add edx, 1
mov dword [0x14000f04c], edx
cmp r12d, edx
jle 0x140003085
movsxd rax, edx
mov rax, qword [rbp + rax*8]
mov qword [0x140016d80], rax
jmp 0x140002dbf
lea rax, [0x140012768]
mov qword [0x14000f040], rax
mov eax, dword [0x14000f050]
test eax, eax
je 0x1400030b2
cmp byte [r13], 0x3a
je 0x1400030b2
mov edx, ebx
lea rcx, str.option_requires_an_argument_____c
call fcn.140002680
mov dword [0x14000f048], ebx
cmp byte [r13], 0x3a
jne 0x140002ed0
jmp 0x140002ff8