Function at 0x14000cc70
Capabilities:
Query environment variable

Disassembly:
push r15
push r14
push r13
push r12
push rsi
push rdi
push rbp
push rbx
sub rsp, 0x48
mov qword [rsp + 0x38], rcx
mov ebx, dword [0x14001b2a4]
cmp ebx, 0xffffffff
je 0x14000cc9d
test ebx, ebx
jg 0x14000cfe0
jmp 0x14000d03a
lea rcx, str.WINEDEBUG
call qword [sym.imp.ucrtbase.dll_getenv]
mov dword [0x14001b2a4], 0
test rax, rax
je 0x14000d03a
mov rcx, rax
call qword [sym.imp.ucrtbase.dll__strdup]
test rax, rax
je 0x14000cfd6
mov rsi, qword [sym.imp.ucrtbase.dll_strchr]
lea rbx, [0x140018a82]
mov qword [rsp + 0x40], rax
mov rdi, rax
jmp 0x14000cd09
not r13b
and r13b, byte [0x14001b2a8]
or r13b, bpl
mov byte [0x14001b2a8], r13b
nop dword [rax + rax]
test rdi, rdi
je 0x14000cfcb
mov r12, rdi
mov rcx, rdi
mov edx, 0x2c
call rsi
test rax, rax
je 0x14000cd30
mov rdi, rax
inc rdi
mov byte [rax], 0
jmp 0x14000cd32
xor edi, edi
mov rcx, r12
mov rdx, rbx
call qword [sym.imp.ucrtbase.dll_strcspn]
lea r15, [r12 + rax]
cmp byte [r12 + rax], 0
cmove r15, r12
mov rax, r15
sub rax, r12
jbe 0x14000cda0
cmp rax, 3
je 0x14000cdba
cmp rax, 4
je 0x14000cdda
cmp rax, 5
jne 0x14000cd00
mov eax, dword [r12]
mov ecx, 0x6d786966
xor eax, ecx
movzx ecx, byte [r12 + 4]
xor ecx, 0x65
or ecx, eax
je 0x14000cdec
mov eax, dword [r12]
mov ecx, 0x63617274
xor eax, ecx
movzx ecx, byte [r12 + 4]
xor ecx, 0x65
or ecx, eax
jne 0x14000cd00
mov cl, 3
jmp 0x14000cdee
movzx eax, byte [r15]
cmp al, 0x2d
sete r13b
setne bpl
neg bpl
neg r13b
cmp al, 0x2d
jne 0x14000ce0e
jmp 0x14000ce16
movzx eax, word [r12]
xor eax, 0x7265
movzx ecx, byte [r12 + 2]
xor ecx, 0x72
or cx, ax
jne 0x14000cd00
mov cl, 1
jmp 0x14000cdee
cmp dword [r12], 0x6e726177
jne 0x14000cd00
mov cl, 2
jmp 0x14000cdee
xor ecx, ecx
mov dl, 1
shl dl, cl
movzx eax, byte [r15]
cmp al, 0x2b
movzx ebp, dl
mov r13d, ebp
mov ecx, 0
cmove r13d, ecx
cmovne ebp, ecx
cmp al, 0x2d
je 0x14000ce16
movzx ecx, al
cmp ecx, 0x2b
jne 0x14000ce1e
movzx eax, byte [r15 + 1]
inc r15
test al, al
je 0x14000cd00
mov rcx, r15
lea rdx, [0x140018a85]
call qword [sym.imp.ucrtbase.dll_strcmp]
test eax, eax
je 0x14000cce7
mov r14d, dword [0x14001b2a4]
mov rcx, r15
call qword [sym.imp.ucrtbase.dll_strlen]
cmp rax, 0xe
ja 0x14000cd00
mov dword [rsp + 0x2c], ebp
mov r12, qword [0x14001daf8]
test r14d, r14d
mov qword [rsp + 0x30], r14
jle 0x14000cebf
dec r14d
xor esi, esi
jmp 0x14000ce89
inc ebx
mov esi, ebx
cmp esi, r14d
jg 0x14000cec1
lea eax, [r14 + rsi]
mov ebx, eax
shr ebx, 0x1f
add ebx, eax
sar ebx, 1
movsxd rbp, ebx
shl rbp, 4
lea rdx, [r12 + rbp]
inc rdx
mov rcx, r15
call qword [sym.imp.ucrtbase.dll_strcmp]
test eax, eax
je 0x14000cf25
jns 0x14000ce80
dec ebx
mov r14d, ebx
cmp esi, r14d
jle 0x14000ce89
jmp 0x14000cec1
xor esi, esi
mov r9d, dword [0x14001db00]
cmp dword [rsp + 0x30], r9d
jge 0x14000cee0
lea rbx, [0x140018a82]
mov rax, qword [rsp + 0x30]
jmp 0x14000cf63
add r9d, r9d
cmp r9d, 0x11
mov eax, 0x10
cmovl r9d, eax
mov dword [0x14001db00], r9d
shl r9, 4
mov rax, qword gs:[0x30]
mov rax, qword [rax + 0x60]
mov rcx, qword [rax + 0x30]
test r12, r12
lea rbx, [0x140018a82]
je 0x14000cf48
xor edx, edx
mov r8, r12
call qword [sym.imp.kernel32.dll_HeapReAlloc]
jmp 0x14000cf53
not r13b
and r13b, byte [r12 + rbp]
or r13b, byte [rsp + 0x2c]
mov byte [r12 + rbp], r13b
mov rsi, qword [sym.imp.ucrtbase.dll_strchr]
lea rbx, [0x140018a82]
jmp 0x14000cd00
xor edx, edx
mov r8, r9
call qword [sym.imp.kernel32.dll_HeapAlloc]
mov r12, rax
mov qword [0x14001daf8], rax
mov eax, dword [0x14001b2a4]
mov rbp, rax
sub eax, esi
jle 0x14000cf8d
movsxd rsi, esi
mov rdx, rsi
shl rdx, 4
lea rcx, [r12 + rdx]
add rcx, 0x10
add rdx, r12
movsxd r8, eax
shl r8, 4
call sym.memmove
jmp 0x14000cf90
movsxd rsi, esi
shl rsi, 4
lea rcx, [r12 + rsi]
inc rcx
mov rdx, r15
call qword [sym.imp.ucrtbase.dll_strcpy]
not r13b
and r13b, byte [0x14001b2a8]
or r13b, byte [rsp + 0x2c]
mov byte [r12 + rsi], r13b
inc ebp
mov dword [0x14001b2a4], ebp
mov rsi, qword [sym.imp.ucrtbase.dll_strchr]
jmp 0x14000cd00
mov rcx, qword [rsp + 0x40]
call qword [sym.imp.ucrtbase.dll_free]
mov ebx, dword [0x14001b2a4]
test ebx, ebx
jle 0x14000d03a
dec ebx
mov rsi, qword [0x14001daf8]
mov rax, qword [rsp + 0x38]
lea rdi, [rax + 1]
xor r15d, r15d
mov r14, qword [sym.imp.ucrtbase.dll_strcmp]
jmp 0x14000d00a
inc ebp
mov r15d, ebp
cmp r15d, ebx
jg 0x14000d03a
lea eax, [r15 + rbx]
mov ebp, eax
shr ebp, 0x1f
add ebp, eax
sar ebp, 1
movsxd r12, ebp
shl r12, 4
lea rdx, [rsi + r12]
inc rdx
mov rcx, rdi
call r14
test eax, eax
je 0x14000d056
jns 0x14000d000
dec ebp
mov ebx, ebp
cmp r15d, ebx
jle 0x14000d00a
lea rsi, [0x14001b2a8]
mov rcx, qword [rsp + 0x38]
cmp byte [rcx], 0
jns 0x14000d059
movzx eax, byte [0x14001b2a8]
mov byte [rcx], al
jmp 0x14000d059
add rsi, r12
movzx eax, byte [rsi]
add rsp, 0x48
pop rbx
pop rbp
pop rdi
pop rsi
pop r12
pop r13
pop r14
pop r15
ret