Function at 0x180066c50
Capabilities:
Query environment variable

Disassembly:
push rsi
push r12
push r13
push r15
sub rsp, 0x38
lea rax, [rdx + 0x1000]
mov r13, r9
mov r12, r8
mov r15, rdx
mov rsi, rcx
cmp rax, 0x2000
jb 0x180066c9f
movabs rcx, 0xffff800000000000
test rcx, rdx
jne 0x180066c9f
lea rax, [r8 + 0x1000]
cmp rax, 0x2000
jb 0x180066c9a
test rcx, r8
je 0x180066cb0
test r8, r8
je 0x180066cb0
mov eax, 0xfffffffa
add rsp, 0x38
pop r15
pop r13
pop r12
pop rsi
ret
mov qword [rsp + 0x70], rbp
mov rbp, qword [rsp + 0x80]
lea rax, [rbp + 0x1000]
cmp rax, 0x2000
jb 0x180066db5
test rcx, rbp
jne 0x180066db5
test rbp, rbp
jne 0x180066cf5
test r8, r8
je 0x180066ede
test r9, r9
je 0x180066ede
test rbp, rbp
je 0x180066cfd
mov qword [rbp], 0
mov qword [rsp + 0x60], rbx
mov qword [rsp + 0x78], rdi
cmp rsi, 0xffffffffffffffff
jne 0x180066df0
lea r8, str.D:_tinderboxwin_4.2_srcVBoxRuntimegenericenv_generic.cpp
lea rcx, [rsp + 0x68]
call sym.VBoxRT.dll_RTStrUtf8ToCurrentCPTag
mov ebx, eax
test eax, eax
js 0x180066eba
mov rcx, qword [rsp + 0x68]
call sym.VBoxRT.dll_RTEnvGet
mov rcx, qword [rsp + 0x68]
mov rdi, rax
call sym.VBoxRT.dll_RTStrFree
test rdi, rdi
je 0x180066de6
lea r8, str.D:_tinderboxwin_4.2_srcVBoxRuntimegenericenv_generic.cpp
lea rcx, [rsp + 0x20]
mov rdx, rdi
call sym.VBoxRT.dll_RTStrCurrentCPToUtf8Tag
mov ebx, eax
test eax, eax
js 0x180066eba
or rcx, rsi
mov rsi, qword [rsp + 0x20]
xor eax, eax
mov rdi, rsi
xor ebx, ebx
repne scasb al, byte [rdi]
not rcx
dec rcx
test rbp, rbp
je 0x180066d8a
mov qword [rbp], rcx
test r12, r12
je 0x180066dd9
test r13, r13
je 0x180066dd9
cmp rcx, r13
jae 0x180066dd4
lea r8, [rcx + 1]
mov rdx, rsi
mov rcx, r12
call sub.MSVCR100.dll_memcpy
mov rcx, rsi
call sym.VBoxRT.dll_RTStrFree
jmp 0x180066eba
test rbp, rbp
je 0x180066cde
mov eax, 0xfffffffa
mov rbp, qword [rsp + 0x70]
add rsp, 0x38
pop r15
pop r13
pop r12
pop rsi
ret
mov ebx, 0xffffffd7
mov rcx, rsi
call sym.VBoxRT.dll_RTStrFree
jmp 0x180066eba
mov ebx, 0xfffffd12
jmp 0x180066eba
lea rax, [rsi + 0x1000]
cmp rax, 0x2000
jb 0x180066ed7
test rcx, rsi
jne 0x180066ed7
cmp dword [rsi], 0x19571010
jne 0x180066ed7
or rcx, 0xffffffffffffffff
xor eax, eax
mov rdi, rdx
repne scasb al, byte [rdi]
xor edi, edi
mov qword [rsp + 0x30], r14
not rcx
mov ebx, 0xfffffd12
lea r14, [rcx - 1]
cmp qword [rsi + 8], rax
jbe 0x180066eb5
mov rcx, qword [rsi + 0x18]
mov r8, r14
mov rdx, r15
mov rcx, qword [rcx + rdi*8]
call qword [sym.imp.MSVCR100.dll_strncmp]
test eax, eax
jne 0x180066e67
mov rax, qword [rsi + 0x18]
mov rcx, qword [rax + rdi*8]
cmp byte [r14 + rcx], 0x3d
je 0x180066e72
inc rdi
cmp rdi, qword [rsi + 8]
jb 0x180066e40
jmp 0x180066eb5
lea rdx, [rcx + r14 + 1]
or rcx, 0xffffffffffffffff
xor eax, eax
mov rdi, rdx
xor ebx, ebx
repne scasb al, byte [rdi]
not rcx
dec rcx
test rbp, rbp
je 0x180066e93
mov qword [rbp], rcx
test r12, r12
je 0x180066eb5
test r13, r13
je 0x180066eb5
cmp rcx, r13
jae 0x180066eb0
lea r8, [rcx + 1]
mov rcx, r12
call sub.MSVCR100.dll_memcpy
jmp 0x180066eb5
mov ebx, 0xffffffd7
mov r14, qword [rsp + 0x30]
mov eax, ebx
mov rbx, qword [rsp + 0x60]
mov rdi, qword [rsp + 0x78]
mov rbp, qword [rsp + 0x70]
add rsp, 0x38
pop r15
pop r13
pop r12
pop rsi
ret
mov eax, 0xfffffffc
jmp 0x180066ebc
mov eax, 0xfffffffe
mov rbp, qword [rsp + 0x70]
add rsp, 0x38
pop r15
pop r13
pop r12
pop rsi
ret