Function at 0x1400010c0
Capabilities:
Query environment variable
Read file on windows

Disassembly:
push rbp
push rbx
push rsi
push r13
lea rbp, [rsp - 0x105c8]
mov eax, 0x106c8
call fcn.140006c50
sub rsp, rax
mov rax, qword [0x140040010]
xor rax, rsp
mov qword [rbp + 0x105a0], rax
mov rsi, rdx
mov r13, rcx
test rdx, rdx
je 0x140006edc
mov edx, 0x5c
mov rcx, rsi
call qword [sym.imp.VCRUNTIME140.dll_strrchr]
mov rbx, rax
test rax, rax
je 0x140006ee6
mov qword [rsp + 0x10700], rdi
sub rbx, rsi
mov qword [rsp + 0x106c0], r12
mov qword [rsp + 0x106b8], r14
mov qword [rsp + 0x106b0], r15
lea rcx, [rbx + 9]
call qword [sym.imp.mozglue.dll_malloc]
lea r8, [rbx + 1]
mov rdx, rsi
mov rcx, rax
mov rdi, rax
call sub.VCRUNTIME140.dll_memcpy
movabs rax, 0x6c6c642e6c7578
mov rcx, rdi
mov qword [rdi + rbx + 1], rax
xor ebx, ebx
movzx r9d, byte [rdi]
mov esi, ebx
test r9b, r9b
je 0x140006ef1
nop word [rax + rax]
lea rdx, [0x140035d80]
mov r8b, 0x2f
cmp r8b, r9b
lea rdx, [rdx + 1]
movzx r8d, byte [rdx]
mov rax, rcx
cmovne rax, rsi
mov rsi, rax
test r8b, r8b
jne 0x14000118a
movzx r9d, byte [rcx + 1]
inc rcx
test r9b, r9b
jne 0x140001180
test rax, rax
je 0x140006ef1
sub rsi, rdi
cmp rsi, 0xf0
ja 0x1400014c4
mov r8, rsi
lea rcx, [rsp + 0x60]
mov rdx, rdi
call sub.VCRUNTIME140.dll_memcpy
movups xmm0, xmmword [0x140036e90]
mov eax, dword [0x140036ea0]
lea r15, [rsp + 0x61]
add r15, rsi
movups xmmword [rsp + rsi + 0x60], xmm0
mov dword [rsp + rsi + 0x70], eax
lea rcx, str.MOZ_RUN_GTEST
call qword [sym.imp.api_ms_win_crt_environment_l1_1_0.dll_getenv]
test rax, rax
jne 0x140006f1e
lea rax, [rbp + 0x390]
mov dword [rsp + 0x28], 0x104
mov r9d, 0xffffffff
mov qword [rsp + 0x20], rax
lea r8, [rsp + 0x60]
xor edx, edx
mov ecx, 0xfde9
call qword [sym.imp.KERNEL32.dll_MultiByteToWideChar]
lea rdx, [0x140035d9c]
lea rcx, [rbp + 0x390]
call qword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll__wfopen]
mov r12, rax
test rax, rax
je 0x1400014c4
mov r8, rax
mov byte [r15], bl
mov edx, 0x104
lea rcx, [rbp + 0x70]
call qword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll_fgets]
test rax, rax
je 0x140001437
nop dword [rax + rax]
lea rcx, [rbp + 0x70]
mov rax, 0xffffffffffffffff
nop dword [rax + rax]
inc rax
cmp byte [rcx + rax], bl
jne 0x140001290
test eax, eax
je 0x14000141c
cmp byte [rbp + 0x70], 0x23
je 0x14000141c
movsxd rcx, eax
lea rax, [rcx - 1]
cmp byte [rbp + rax + 0x70], 0xa
jne 0x1400012c8
cmp rax, 0x104
jae 0x1400014be
mov byte [rbp + rax + 0x70], bl
lea rax, [rsp + 0x60]
sub rcx, rax
add rcx, r15
cmp rcx, 0x104
ja 0x140006f8a
lea rax, [rbp + 0x70]
mov rdx, r15
sub rdx, rax
lea rcx, [rbp + 0x70]
nop
movzx eax, byte [rcx]
mov byte [rdx + rcx], al
lea rcx, [rcx + 1]
test al, al
jne 0x1400012f0
lea rax, [rbp + 0x180]
mov dword [rsp + 0x28], 0x104
mov r9d, 0xffffffff
mov qword [rsp + 0x20], rax
lea r8, [rsp + 0x60]
xor edx, edx
mov ecx, 0xfde9
call qword [sym.imp.KERNEL32.dll_MultiByteToWideChar]
xor r9d, r9d
mov qword [rsp + 0x30], rbx
mov dword [rsp + 0x28], 0x8000000
lea rcx, [rbp + 0x180]
mov edx, 0x80000000
mov dword [rsp + 0x20], 3
lea r8d, [r9 + 1]
call qword [sym.imp.KERNEL32.dll_CreateFileW]
mov r14, rax
cmp rax, 0xffffffffffffffff
je 0x1400013d8
mov r9d, 1
lea r8, [rsp + 0x50]
mov rdx, rbx
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_SetFilePointerEx]
test eax, eax
je 0x1400013cf
mov rsi, rbx
nop
lea r9, [rsp + 0x40]
mov qword [rsp + 0x20], rbx
mov r8d, 0x10000
lea rdx, [rbp + 0x5a0]
mov rcx, r14
call qword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
je 0x1400013bb
cmp dword [rsp + 0x40], 0x10000
jne 0x1400013bb
add rsi, 0x10000
cmp rsi, 0xffffffffffffffff
jb 0x140001380
mov rdx, qword [rsp + 0x50]
xor r9d, r9d
xor r8d, r8d
mov rcx, r14
call qword [sym.imp.KERNEL32.dll_SetFilePointerEx]
mov rcx, r14
call qword [sym.imp.KERNEL32.dll_CloseHandle]
xor edx, edx
lea rcx, [rbp + 0x180]
lea r8d, [rdx + 8]
call qword [sym.imp.KERNEL32.dll_LoadLibraryExW]
mov rsi, rax
test rax, rax
je 0x140006f51
mov ecx, 0x10
call qword [sym.imp.mozglue.dll_moz_xmalloc]
test rax, rax
je 0x14000141c
mov rcx, qword [0x1400421b8]
mov qword [rax + 8], rcx
mov qword [rax], rsi
mov qword [0x1400421b8], rax
mov r8, r12
lea rcx, [rbp + 0x70]
mov edx, 0x104
call qword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll_fgets]
test rax, rax
jne 0x140001280
mov rcx, r12
call qword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll_fclose]
mov rax, qword [0x1400421b8]
lea rdx, str.XRE_GetBootstrap
mov rcx, qword [rax]
call qword [sym.imp.KERNEL32.dll_GetProcAddress]
test rax, rax
je 0x1400014c4
lea rcx, [rsp + 0x48]
mov qword [rsp + 0x48], rbx
call rax
mov rax, qword [rsp + 0x48]
mov qword [r13], rax
mov qword [rsp + 0x48], rbx
mov rcx, rdi
call qword [sym.imp.mozglue.dll_free]
mov r14, qword [rsp + 0x106b8]
mov r12, qword [rsp + 0x106c0]
mov rdi, qword [rsp + 0x10700]
mov r15, qword [rsp + 0x106b0]
mov rax, r13
mov rcx, qword [rbp + 0x105a0]
xor rcx, rsp
call fcn.140005a70
add rsp, 0x106c8
pop r13
pop rsi
pop rbx
pop rbp
ret
call fcn.140006194
int3
mov qword [r13], rbx
jmp 0x140001476
xor ebx, ebx
mov qword [rcx], rbx
jmp 0x14000149f
xor ebx, ebx
mov qword [r13], rbx
jmp 0x14000149f
movzx eax, word [0x140036fe8]
lea r15, [rsp + 0x60]
movups xmm0, xmmword [str.dependentlibs.list]
mov word [rsp + 0x70], ax
movzx eax, byte [0x140036fea]
mov byte [rsp + 0x72], al
movaps xmmword [rsp + 0x60], xmm0
jmp 0x1400011f8
lea rcx, [rsp + 0x60]
dec rcx
cmp byte [rcx + 1], bl
lea rcx, [rcx + 1]
jne 0x140006f26
mov eax, dword [str..gtest]
mov dword [rcx], eax
movzx eax, word [0x140036e20]
mov word [rcx + 4], ax
movzx eax, byte [0x140036e22]
mov byte [rcx + 6], al
jmp 0x14000120e
mov rax, qword [0x1400421b8]
test rax, rax
je 0x140006f8a
mov rcx, qword [rax]
call qword [sym.imp.KERNEL32.dll_FreeLibrary]
mov rcx, qword [0x1400421b8]
mov rax, qword [rcx + 8]
mov qword [0x1400421b8], rax
call qword [sym.imp.mozglue.dll_free]
mov rax, qword [0x1400421b8]
test rax, rax
jne 0x140006f5d
mov rcx, r12
call qword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll_fclose]
nop
jmp 0x1400014c4