Function at 0x4dff70
Capabilities:
Query environment variable

Disassembly:
push r15
push r14
push r13
push r12
push rbp
push rdi
push rsi
push rbx
sub rsp, 0x58
mov eax, dword [0x004fa228]
mov qword [0x0057caf8], 0
test eax, eax
mov esi, ecx
mov r10, r8
mov r13, r9
jne 0x4e00d8
mov dword [0x004fa228], 1
mov eax, 1
lea rcx, str.POSIXLY_CORRECT
mov qword [rsp + 0xb0], r10
mov qword [rsp + 0xa8], rdx
mov dword [0x0057cb00], eax
mov dword [0x0057cb04], eax
mov qword [0x0057cb18], 0
call sub.msvcrt.dll_getenv
mov r10, qword [rsp + 0xb0]
mov rdx, qword [rsp + 0xa8]
mov qword [0x0057cb08], rax
movzx ecx, byte [r10]
cmp cl, 0x2d
je 0x4e0190
test rax, rax
sete al
cmp cl, 0x2b
movzx eax, al
jne 0x4e0199
mov dword [0x0057caf0], 1
xor eax, eax
add r10, 1
mov dword [0x0057cb10], eax
nop
mov r15, qword [0x0057cb18]
test r15, r15
je 0x4e00f0
movsx edi, byte [r15]
test dil, dil
je 0x4e00f0
test r13, r13
je 0x4e0230
movsxd rax, dword [0x004fa228]
mov r9, qword [rdx + rax*8]
mov rbp, rax
movzx ecx, byte [r9 + 1]
cmp cl, 0x2d
je 0x4e0330
mov eax, dword [rsp + 0xc8]
test eax, eax
je 0x4e0230
cmp byte [r9 + 2], 0
jne 0x4e0330
movzx r8d, byte [r10]
test r8b, r8b
je 0x4e0330
mov eax, r8d
mov rbx, r10
jmp 0x4e00b8
movzx eax, byte [rbx + 1]
add rbx, 1
test al, al
je 0x4e0330
cmp al, cl
jne 0x4e00a8
lea r14, [r15 + 1]
movzx ecx, byte [r15 + 1]
mov qword [0x0057cb18], r14
jmp 0x4e024d
mov ecx, dword [0x0057caf0]
test ecx, ecx
je 0x4dffb0
jmp 0x4e0030
mov ebp, dword [0x004fa228]
cmp dword [0x0057cb00], ebp
jle 0x4e0104
mov dword [0x0057cb00], ebp
cmp ebp, dword [0x0057cb04]
jge 0x4e0112
mov dword [0x0057cb04], ebp
mov ebx, dword [0x0057cb10]
cmp ebx, 1
je 0x4e01b0
cmp esi, ebp
je 0x4e01d8
movsxd rax, ebp
mov r9, qword [rdx + rax*8]
cmp byte [r9], 0x2d
jne 0x4e01f8
cmp byte [r9 + 1], 0x2d
jne 0x4e01f8
cmp byte [r9 + 2], 0
jne 0x4e01f8
mov eax, dword [0x0057cb04]
add ebp, 1
mov ecx, dword [0x0057cb00]
mov dword [0x004fa228], ebp
cmp eax, ecx
je 0x4e0760
cmp ebp, ecx
je 0x4e017f
mov rcx, rdx
call fcn.004dfe50
mov eax, dword [0x0057cb04]
mov dword [0x0057cb00], esi
mov dword [0x004fa228], esi
jmp 0x4e01e4
add r10, 1
mov eax, 2
mov dword [0x0057cb10], eax
mov dword [0x0057caf0], 1
jmp 0x4e0030
mov eax, dword [0x0057cb00]
cmp dword [0x0057cb04], eax
je 0x4e0410
cmp ebp, eax
jne 0x4e0428
mov ecx, ebp
jmp 0x4e0456
mov eax, dword [0x0057cb04]
mov esi, dword [0x0057cb00]
cmp eax, esi
je 0x4e01ee
mov dword [0x004fa228], eax
mov edi, 0xffffffff
jmp 0x4e021b
cmp byte [r9], 0x2d
je 0x4e02f0
test ebx, ebx
je 0x4e01ee
add ebp, 1
mov qword [0x0057caf8], r9
mov edi, 1
mov dword [0x004fa228], ebp
mov eax, edi
add rsp, 0x58
pop rbx
pop rsi
pop rdi
pop rbp
pop r12
pop r13
pop r14
pop r15
ret
movzx r8d, byte [r10]
lea r14, [r15 + 1]
test r8b, r8b
movzx ecx, byte [r15 + 1]
mov qword [0x0057cb18], r14
je 0x4e04a8
mov rax, r10
jmp 0x4e026a
movzx r8d, byte [rax + 1]
add rax, 1
test r8b, r8b
je 0x4e04a8
cmp r8b, dil
jne 0x4e0258
test rax, rax
sete r8b
cmp dil, 0x3a
sete r9b
or r8d, r9d
test cl, cl
jne 0x4e028c
add dword [0x004fa228], 1
test r8b, r8b
jne 0x4e04b3
cmp byte [rax], 0x57
movzx ecx, byte [rax + 1]
je 0x4e0560
cmp cl, 0x3a
jne 0x4e021b
cmp byte [rax + 2], 0x3a
movzx ecx, byte [r15 + 1]
je 0x4e073a
test cl, cl
movsxd rax, dword [0x004fa228]
je 0x4e0838
add eax, 1
mov qword [0x0057caf8], r14
mov dword [0x004fa228], eax
mov qword [0x0057cb18], 0
jmp 0x4e021b
movzx ecx, byte [r9 + 1]
test cl, cl
je 0x4e0202
test r13, r13
je 0x4e07b0
cmp cl, 0x2d
je 0x4e031e
lea r15, [r9 + 1]
movsx edi, cl
mov qword [0x0057cb18], r15
jmp 0x4e0072
movsx edi, byte [r9 + 2]
lea r15, [r9 + 2]
mov qword [0x0057cb18], r15
nop
test dil, dil
mov rax, r15
je 0x4e0354
cmp dil, 0x3d
je 0x4e0354
nop
movzx r8d, byte [rax + 1]
add rax, 1
test r8b, r8b
je 0x4e0354
cmp r8b, 0x3d
jne 0x4e0340
mov rbx, qword [r13]
test rbx, rbx
je 0x4e06f0
mov r11, rax
xor r8d, r8d
mov r12, r13
mov byte [rsp + 0x38], dil
sub r11, r15
mov dword [rsp + 0x48], ebp
xor r14d, r14d
xor ebp, ebp
mov dword [rsp + 0xa0], esi
mov rdi, r11
mov rsi, r8
mov qword [rsp + 0xb8], r13
mov r13, rax
mov dword [rsp + 0x30], 0xffffffff
mov qword [rsp + 0x40], r9
mov byte [rsp + 0x4f], cl
mov qword [rsp + 0xa8], rdx
mov qword [rsp + 0xb0], r10
jmp 0x4e03db
mov ebp, 1
mov rbx, qword [r12 + 0x20]
add r12, 0x20
add r14d, 1
test rbx, rbx
je 0x4e0500
mov r8, rdi
mov rdx, r15
mov rcx, rbx
call sub.msvcrt.dll_strncmp
test eax, eax
jne 0x4e03c5
mov rcx, rbx
call sub.msvcrt.dll_strlen
cmp edi, eax
je 0x4e0650
test rsi, rsi
jne 0x4e03c0
mov dword [rsp + 0x30], r14d
mov rsi, r12
jmp 0x4e03c5
cmp ebp, eax
je 0x4e01ca
mov dword [0x0057cb04], ebp
mov ecx, ebp
jmp 0x4e0456
mov rcx, rdx
mov qword [rsp + 0xb0], r10
mov qword [rsp + 0xa8], rdx
call fcn.004dfe50
mov ecx, dword [0x004fa228]
mov rdx, qword [rsp + 0xa8]
mov r10, qword [rsp + 0xb0]
cmp esi, ecx
jle 0x4e04a0
movsxd rax, ecx
jmp 0x4e0471
add rax, 1
add ecx, 1
cmp esi, eax
mov dword [0x004fa228], ecx
jle 0x4e04a0
mov r8, qword [rdx + rax*8]
mov ecx, eax
cmp byte [r8], 0x2d
jne 0x4e0460
cmp byte [r8 + 1], 0
je 0x4e0460
mov ebp, dword [0x004fa228]
cmp esi, ebp
mov dword [0x0057cb00], ecx
jne 0x4e0129
jmp 0x4e01d8
mov ebp, ecx
jmp 0x4e048a
test cl, cl
jne 0x4e04b3
add dword [0x004fa228], 1
mov ebx, dword [0x004fa224]
test ebx, ebx
je 0x4e04ee
cmp qword [0x0057cb08], 0
mov ecx, 2
mov rbx, qword [rdx]
je 0x4e0963
call qword [fcn.004f2040]
mov r9d, edi
mov r8, rbx
lea rdx, str._s:_illegal_option_____c_n
mov rcx, rax
call fcn.004dff40
mov dword [0x004fa220], edi
mov edi, 0x3f
jmp 0x4e021b
mov ebx, ebp
mov r11, rsi
mov rax, r13
movsx edi, byte [rsp + 0x38]
test ebx, ebx
mov r9, qword [rsp + 0x40]
movzx ecx, byte [rsp + 0x4f]
mov ebp, dword [rsp + 0x48]
mov esi, dword [rsp + 0xa0]
mov rdx, qword [rsp + 0xa8]
mov r10, qword [rsp + 0xb0]
mov r13, qword [rsp + 0xb8]
jne 0x4e0770
test r11, r11
mov r12, r11
je 0x4e06f0
mov r14d, dword [rsp + 0x30]
jmp 0x4e066e
cmp cl, 0x3b
jne 0x4e02a2
cmp byte [r15 + 1], 0
movsxd rax, dword [0x004fa228]
je 0x4e0904
add eax, 1
mov qword [0x0057caf8], r14
mov dword [0x004fa228], eax
movzx eax, byte [r14]
mov qword [0x0057cb18], r14
mov rcx, r14
test al, al
jne 0x4e05ac
jmp 0x4e05b0
movzx eax, byte [rcx + 1]
add rcx, 1
test al, al
je 0x4e05b0
cmp al, 0x3d
jne 0x4e05a0
mov r15, qword [r13]
test r15, r15
je 0x4e0b95
mov rdi, rcx
mov dword [rsp + 0xa0], esi
xor ebx, ebx
xor ebp, ebp
sub rdi, r14
mov dword [rsp + 0x30], 0
xor r12d, r12d
mov r11d, edi
mov byte [rsp + 0x48], al
mov qword [rsp + 0x38], rcx
mov rsi, r11
mov qword [rsp + 0xa8], rdx
mov qword [rsp + 0xb0], r10
jmp 0x4e0619
mov ebp, 1
mov r15, qword [r13 + 0x20]
add r13, 0x20
add ebx, 1
test r15, r15
je 0x4e087d
mov r8, rdi
mov rdx, r14
mov rcx, r15
call sub.msvcrt.dll_strncmp
test eax, eax
jne 0x4e0605
mov rcx, r15
call sub.msvcrt.dll_strlen
cmp rsi, rax
je 0x4e0a3f
test r12, r12
jne 0x4e0600
mov dword [rsp + 0x30], ebx
mov r12, r13
jmp 0x4e0605
mov ebp, dword [rsp + 0x48]
mov rax, r13
mov esi, dword [rsp + 0xa0]
mov rdx, qword [rsp + 0xa8]
mov r10, qword [rsp + 0xb0]
lea ecx, [rbp + 1]
mov r8d, dword [r12 + 8]
mov dword [0x004fa228], ecx
cmp byte [rax], 0
jne 0x4e06d0
cmp r8d, 1
je 0x4e0859
mov rcx, r15
call sub.msvcrt.dll_strlen
add rax, r15
cmp qword [rsp + 0xc0], 0
mov qword [0x0057cb18], rax
je 0x4e06b3
mov rax, qword [rsp + 0xc0]
mov dword [rax], r14d
mov rax, qword [r12 + 0x10]
mov edi, dword [r12 + 0x18]
test rax, rax
je 0x4e021b
mov dword [rax], edi
xor edi, edi
jmp 0x4e021b
test r8d, r8d
je 0x4e07c0
add rax, 1
mov qword [0x0057caf8], rax
jmp 0x4e068b
mov r12d, dword [rsp + 0xc8]
test r12d, r12d
je 0x4e0983
cmp cl, 0x2d
je 0x4e0aeb
movzx r8d, byte [r10]
test r8b, r8b
je 0x4e0b4a
mov rcx, r10
mov eax, r8d
jmp 0x4e0730
movzx eax, byte [rcx + 1]
add rcx, 1
test al, al
je 0x4e0b4a
cmp al, dil
jne 0x4e0720
jmp 0x4e00bc
test cl, cl
je 0x4e095b
add dword [0x004fa228], 1
mov qword [0x0057caf8], r14
mov qword [0x0057cb18], 0
jmp 0x4e021b
mov dword [0x0057cb04], ebp
mov eax, ebp
jmp 0x4e017f
mov eax, dword [0x004fa224]
test eax, eax
jne 0x4e0925
mov rcx, r15
call sub.msvcrt.dll_strlen
mov dword [0x004fa220], 0
add dword [0x004fa228], 1
add rax, r15
mov qword [0x0057cb18], rax
jmp 0x4e04f4
movzx r8d, byte [r10]
lea r15, [r9 + 1]
movsx edi, cl
jmp 0x4e0234
mov eax, dword [0x004fa224]
test eax, eax
je 0x4e068b
movsxd rcx, ecx
mov rsi, qword [r12]
mov rax, qword [rdx + rcx*8 - 8]
mov rbx, qword [rdx]
cmp byte [rax + 1], 0x2d
je 0x4e0bd1
movsx edi, byte [rax]
mov ecx, 2
call qword [fcn.004f2040]
mov qword [rsp + 0x20], rsi
mov r8, rbx
lea rdx, str._s:_option___c_s_doesnt_allow_an_argument_n
mov rcx, rax
mov r9d, edi
call fcn.004dff40
mov rbx, qword [0x0057cb18]
mov rcx, rbx
call sub.msvcrt.dll_strlen
add rbx, rax
mov eax, dword [r12 + 0x18]
mov qword [0x0057cb18], rbx
mov dword [0x004fa220], eax
jmp 0x4e04f4
cmp esi, eax
je 0x4e0a18
lea ecx, [rax + 1]
mov rax, qword [rdx + rax*8]
mov dword [0x004fa228], ecx
mov qword [0x0057caf8], rax
jmp 0x4e02d9
cmp ecx, esi
jge 0x4e0a6c
movsxd rcx, ecx
add ebp, 2
mov rax, qword [rdx + rcx*8]
mov dword [0x004fa228], ebp
mov qword [0x0057caf8], rax
jmp 0x4e068b
test ebp, ebp
movzx eax, byte [rsp + 0x48]
mov rcx, qword [rsp + 0x38]
mov esi, dword [rsp + 0xa0]
mov rdx, qword [rsp + 0xa8]
mov r10, qword [rsp + 0xb0]
jne 0x4e0abd
test r12, r12
je 0x4e0b95
test al, al
mov r8d, dword [r12 + 8]
je 0x4e09e6
test r8d, r8d
je 0x4e0baa
add rcx, 1
mov qword [0x0057caf8], rcx
mov rcx, r14
call sub.msvcrt.dll_strlen
add rax, r14
cmp qword [rsp + 0xc0], 0
mov qword [0x0057cb18], rax
je 0x4e06b3
mov rax, qword [rsp + 0xc0]
mov esi, dword [rsp + 0x30]
mov dword [rax], esi
jmp 0x4e06b3
cmp esi, eax
je 0x4e0b21
mov r14, qword [rdx + rax*8]
lea ecx, [rax + 1]
mov dword [0x004fa228], ecx
mov qword [0x0057caf8], r14
jmp 0x4e058b
mov rbx, qword [rdx]
mov qword [rsp + 0x30], r9
mov ecx, 2
call qword [fcn.004f2040]
mov r9, qword [rsp + 0x30]
lea rdx, str._s:_option___s_is_ambiguous_n
mov rcx, rax
mov r8, rbx
call fcn.004dff40
mov r15, qword [0x0057cb18]
jmp 0x4e077e
xor r14d, r14d
jmp 0x4e0749
call qword [fcn.004f2040]
mov r9d, edi
mov r8, rbx
lea rdx, str._s:_invalid_option_____c_n
mov rcx, rax
call fcn.004dff40
jmp 0x4e04ee
mov esi, dword [0x004fa224]
test esi, esi
je 0x4e09c2
cmp cl, 0x2d
je 0x4e0af9
mov rbx, qword [rdx]
mov ecx, 2
movsx esi, byte [r9]
call qword [fcn.004f2040]
mov qword [rsp + 0x20], r15
lea rdx, str._s:_unrecognized_option___c_s_n
mov rcx, rax
mov r8, rbx
mov r9d, esi
call fcn.004dff40
add dword [0x004fa228], 1
lea rax, [0x00566da8]
mov dword [0x004fa220], 0
mov qword [0x0057cb18], rax
jmp 0x4e04f4
cmp r8d, 1
jne 0x4e08d0
movsxd rax, dword [0x004fa228]
cmp eax, esi
jge 0x4e0c77
lea ecx, [rax + 1]
mov rax, qword [rdx + rax*8]
mov dword [0x004fa228], ecx
mov qword [0x0057caf8], rax
jmp 0x4e08d0
mov eax, dword [0x004fa224]
test eax, eax
jne 0x4e0b5d
mov dword [0x004fa220], edi
xor edi, edi
cmp byte [r10], 0x3a
setne dil
lea edi, [rdi + rdi*4 + 0x3a]
jmp 0x4e02d9
movzx eax, byte [rsp + 0x48]
mov dword [rsp + 0x30], ebx
mov r12, r13
mov rcx, qword [rsp + 0x38]
mov esi, dword [rsp + 0xa0]
mov rdx, qword [rsp + 0xa8]
mov r10, qword [rsp + 0xb0]
jmp 0x4e08af
mov r13d, dword [0x004fa224]
test r13d, r13d
jne 0x4e0bf6
mov rcx, r15
mov qword [rsp + 0xb0], r10
call sub.msvcrt.dll_strlen
mov r10, qword [rsp + 0xb0]
add rax, r15
mov qword [0x0057cb18], rax
mov eax, dword [r12 + 0x18]
mov dword [0x004fa220], eax
cmp byte [r10], 0x3a
jne 0x4e04f4
mov edi, 0x3a
jmp 0x4e021b
mov r9d, dword [0x004fa224]
test r9d, r9d
jne 0x4e0c3d
mov rcx, r14
call sub.msvcrt.dll_strlen
add dword [0x004fa228], 1
add rax, r14
mov qword [0x0057cb18], rax
jmp 0x4e04f4
mov edi, dword [0x004fa224]
test edi, edi
je 0x4e09c2
mov rbx, qword [rdx]
mov ecx, 2
call qword [fcn.004f2040]
lea rdx, str._s:_unrecognized_option_____s_n
mov r9, r15
mov rcx, rax
mov r8, rbx
call fcn.004dff40
jmp 0x4e09c2
mov r11d, dword [0x004fa224]
test r11d, r11d
jne 0x4e0cbd
mov dword [0x004fa220], edi
xor edi, edi
cmp byte [r10], 0x3a
setne dil
lea edi, [rdi + rdi*4 + 0x3a]
jmp 0x4e021b
mov ebp, dword [0x004fa224]
test ebp, ebp
jne 0x4e0996
jmp 0x4e09c2
mov rbx, qword [rdx]
mov qword [rsp + 0xb0], r10
mov ecx, 2
call qword [fcn.004f2040]
lea rdx, str._s:_option_requires_an_argument_____c_n
mov r9d, edi
mov rcx, rax
mov r8, rbx
call fcn.004dff40
mov r10, qword [rsp + 0xb0]
jmp 0x4e0a26
mov qword [0x0057cb18], 0
mov edi, 0x57
jmp 0x4e021b
mov r8d, dword [0x004fa224]
test r8d, r8d
jne 0x4e0cf5
mov rcx, r14
call sub.msvcrt.dll_strlen
add rax, r14
mov qword [0x0057cb18], rax
jmp 0x4e04f4
mov ecx, 2
call qword [fcn.004f2040]
mov r9, rsi
mov r8, rbx
lea rdx, str._s:_option_____s_doesnt_allow_an_argument_n
mov rcx, rax
call fcn.004dff40
jmp 0x4e080f
movsxd rcx, ecx
mov rbx, qword [rdx]
mov qword [rsp + 0xb0], r10
mov rsi, qword [rdx + rcx*8 - 8]
mov ecx, 2
call qword [fcn.004f2040]
lea rdx, str._s:_option___s_requires_an_argument_n
mov rcx, rax
mov r8, rbx
mov r9, rsi
call fcn.004dff40
mov r15, qword [0x0057cb18]
mov r10, qword [rsp + 0xb0]
jmp 0x4e0a7c
movsxd rax, dword [0x004fa228]
mov ecx, 2
mov rbx, qword [rdx]
mov rsi, qword [rdx + rax*8]
call qword [fcn.004f2040]
lea rdx, str._s:_option___W__s_is_ambiguous_n
mov r8, rbx
mov rcx, rax
mov r9, rsi
call fcn.004dff40
mov r14, qword [0x0057cb18]
jmp 0x4e0acd
mov ecx, dword [0x004fa224]
test ecx, ecx
jne 0x4e0d28
mov rbx, qword [0x0057cb18]
mov qword [rsp + 0xb0], r10
mov rcx, rbx
call sub.msvcrt.dll_strlen
mov r10, qword [rsp + 0xb0]
add rbx, rax
mov qword [0x0057cb18], rbx
cmp byte [r10], 0x3a
jne 0x4e04f4
jmp 0x4e0ab3
mov rbx, qword [rdx]
mov qword [rsp + 0xb0], r10
mov ecx, 2
call qword [fcn.004f2040]
lea rdx, str._s:_option_requires_an_argument_____c_n
mov r9d, edi
mov rcx, rax
mov r8, rbx
call fcn.004dff40
mov r10, qword [rsp + 0xb0]
jmp 0x4e0b31
mov rbx, qword [rdx]
mov ecx, 2
mov rsi, qword [r12]
call qword [fcn.004f2040]
lea rdx, str._s:_option___W__s_doesnt_allow_an_argument_n
mov rcx, rax
mov r8, rbx
mov r9, rsi
call fcn.004dff40
mov r14, qword [0x0057cb18]
jmp 0x4e0bba
mov rbx, qword [rdx]
mov qword [rsp + 0xb0], r10
mov ecx, 2
mov rsi, qword [rdx + rax*8 - 8]
call qword [fcn.004f2040]
lea rdx, str._s:_option___s_requires_an_argument_n
mov rcx, rax
mov r8, rbx
mov r9, rsi
call fcn.004dff40
mov r10, qword [rsp + 0xb0]
jmp 0x4e0c85