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

Disassembly:
push r13
push r14
push r15
mov eax, 0x2770
call fcn.1400fc460
sub rsp, rax
mov qword [rsp + 0x48], 0xfffffffffffffffe
mov qword [rsp + 0x2798], rbx
mov qword [rsp + 0x27a0], rdi
mov qword [rsp + 0x27a8], r12
mov rax, qword [0x140160370]
xor rax, rsp
mov qword [rsp + 0x2760], rax
mov r12b, cl
xor edi, edi
test dl, dl
je 0x1400c3846
cmp word [0x14017689e], di
je 0x1400c38ab
cmp qword [0x1401bdf08], rdi
je 0x1400c38ab
mov word [0x14017689e], di
jmp 0x1400c38ab
mov cl, 1
call fcn.1400c9d90
mov dword [0x1401799e8], 3
mov qword [0x140168ea0], rdi
mov cl, byte [0x140166ce4]
test cl, cl
jne 0x1400c39a5
xor r8d, r8d
lea rdx, [0x14017fe00]
lea rcx, [0x14018d510]
call fcn.140044518
cmp byte [0x14018e58e], dil
je 0x1400c38ab
mov eax, dword [0x1401799e4]
mov r14d, 4
cmp qword [0x14017fe30], 1
cmova eax, r14d
mov dword [0x1401799e4], eax
jmp 0x1400c38b1
mov r14d, 4
mov cl, byte [0x140166ce4]
test cl, cl
jne 0x1400c39ab
cmp word [0x14017edfa], di
jne 0x1400c39ab
mov r12b, dil
mov ebx, 0x800
mov r8d, ebx
lea rdx, [0x14017edfa]
mov ecx, dword [0x14017bd98]
call fcn.1400c98dc
mov dword [rsp + 0x20], ebx
lea r13, [0x14011bd58]
mov r9, r13
lea r8, [rsp + 0x1360]
lea rdx, str.DefFolder
lea rcx, [0x14011c9d0]
call fcn.1400a7a28
cmp word [rsp + 0x1360], di
jne 0x1400c393e
cmp byte [0x14018e58e], dil
je 0x1400c397c
mov edx, ebx
lea rcx, [rsp + 0x1360]
call fcn.14003e638
cmp word [rsp + 0x1360], di
je 0x1400c397c
mov rdx, rbx
lea rcx, [rsp + 0x1360]
call fcn.14007e920
mov r8, rbx
lea rdx, [0x14017edfa]
lea rcx, [rsp + 0x1360]
call fcn.140096160
mov r8, rbx
lea rdx, [rsp + 0x1360]
lea rcx, [0x14017edfa]
call fcn.140096188
cmp word [0x140174898], di
setne r8b
mov r9d, dword [0x14017bd98]
mov rdx, rbx
lea rcx, [0x14017edfa]
call fcn.1400cd554
mov cl, byte [0x140166ce4]
jmp 0x1400c39b7
mov r14d, 4
lea r13, [0x14011bd58]
mov ebx, 0x800
mov eax, dword [0x1401799e4]
mov edx, 2
test eax, eax
cmove eax, edx
mov dword [0x1401799e4], eax
test cl, cl
je 0x1400c3b31
mov r15d, dword [0x14018a714]
cmp r15d, 1
jbe 0x1400c3a21
cmp dword [0x1401799b4], 3
je 0x1400c3f51
lea ecx, [rdx + 0x63]
call fcn.1400900b8
mov rbx, rax
mov ecx, 0x1fd
call fcn.1400900b8
mov rdx, rax
mov r9d, 0x30
mov r8, rbx
mov rcx, qword [0x140166d18]
call fcn.1400d00d0
jmp 0x1400c3f51
mov r8, rbx
lea rdx, [0x14017edfa]
lea rcx, [0x14018a710]
call fcn.14000606c
mov r8, rbx
lea rdx, [0x1401778b0]
lea rcx, [0x14018a710]
call fcn.140006608
cmp word [0x1401778b0], di
je 0x1400c3a65
mov rdx, rbx
lea rcx, [0x1401778b0]
call fcn.14007e920
mov byte [0x140179a59], dil
lea rdx, [rsp + 0x110]
lea rcx, [0x14018a710]
call fcn.140006628
mov eax, dword [rsp + 0x258]
mov dword [0x14017bd98], eax
mov qword [rsp + 0x1320], rdi
mov qword [rsp + 0x1328], rdi
mov qword [rsp + 0x1330], rdi
xor r8d, r8d
lea rdx, [rsp + 0x310]
lea rcx, [0x14017edfa]
call fcn.140070b8c
test al, al
je 0x1400c3acb
cmp qword [rsp + 0x1310], 0x18
je 0x1400c3aec
cmp dword [rsp + 0x258], edi
jne 0x1400c3ae5
cmp byte [rsp + 0x190], dil
mov byte [0x140179a40], 1
jne 0x1400c3aec
mov byte [0x140179a40], dil
test r15d, r15d
jne 0x1400c3afa
cmp dword [rsp + 0x2e0], edi
je 0x1400c3b08
movzx eax, byte [rsp + 0x252]
mov dword [0x1401799d4], eax
cmp qword [rsp + 0x248], rdi
je 0x1400c3b2a
mov r8, rbx
lea rdx, [0x14011c528]
lea rcx, [0x140174898]
call fcn.140096188
jmp 0x1400c3b31
mov word [0x140174898], di
mov rcx, qword [0x140166d18]
call qword [sym.imp.USER32.dll_IsWindowVisible]
neg eax
sbb rcx, rcx
and rcx, qword [0x140166d18]
xor r8d, r8d
mov dl, r12b
call fcn.1400c6c10
test al, al
je 0x1400c3f32
mov al, byte [0x1401bdf27]
neg al
sbb ecx, ecx
and ecx, dword [0x1401bdf28]
mov dword [0x1401799c8], ecx
mov rcx, qword [0x1401bdf08]
test rcx, rcx
je 0x1400c3b86
call fcn.1400cde7c
jmp 0x1400c3baa
cmp byte [0x140166ce4], dil
je 0x1400c3baa
cmp qword [rsp + 0x248], rdi
je 0x1400c3baa
cmp word [0x140174898], 0x2a
jne 0x1400c3baa
mov word [0x140174898], di
cmp qword [0x14017fe30], rdi
jne 0x1400c3be7
mov ecx, 0x65
call fcn.1400900b8
mov rbx, rax
mov ecx, 0x14b
call fcn.1400900b8
mov rdx, rax
mov r9d, 0x30
mov r8, rbx
mov rcx, qword [0x140166d18]
call fcn.1400d00d0
jmp 0x1400c3f32
cmp word [0x14017689e], di
je 0x1400c3cc6
cmp dword [0x1401778a0], edi
jne 0x1400c3cc6
lea rdx, [0x140120cd8]
lea rcx, [0x14017689e]
call fcn.1400705bc
mov r12, rax
test rax, rax
je 0x1400c3cc6
mov r9, rax
mov edx, 1
mov r8d, 0x400
lea rcx, [rsp + 0x2360]
call fcn.140107984
mov r15, rax
mov rcx, r12
call fcn.1401039a8
mov eax, 0x3ff
cmp r15, rax
cmovb rax, r15
cmp rax, 0x400
jae 0x1400c3cc0
mov byte [rsp + rax + 0x2360], dil
mov dword [rsp + 0x40], 0x30c
test r15, r15
je 0x1400c3c94
lea r8, [rsp + 0x40]
mov edx, r15d
lea rcx, [rsp + 0x2360]
call qword [sym.imp.ADVAPI32.dll_IsTextUnicode]
test eax, eax
je 0x1400c3c94
mov dword [0x1401778a0], 3
jmp 0x1400c3cc6
lea rcx, [rsp + 0x2360]
call fcn.1400959a8
cmp eax, 2
jne 0x1400c3caf
mov dword [0x1401778a0], r14d
jmp 0x1400c3cc6
cmp eax, 1
jne 0x1400c3cc6
mov dword [0x1401778a0], 2
jmp 0x1400c3cc6
call fcn.1400fc234
nop
lea rcx, [rsp + 0x50]
call fcn.1400961bc
nop
lea rcx, [0x14017fe00]
call fcn.1400963fc
mov r15d, 0x25
lea rcx, [0x14017fe00]
call fcn.14009626c
mov r14, rax
test rax, rax
je 0x1400c3dfd
mov r9, rbx
lea r8, [rsp + 0x1360]
mov rdx, rax
lea rcx, [0x14018d510]
call fcn.140044c54
cmp word [r14], 0x40
jne 0x1400c3d82
lea rcx, [rsp + 0x1360]
call fcn.14006f688
test al, al
jne 0x1400c3d82
lea rdx, [r14 + 2]
mov r9, rbx
lea r8, [rsp + 0x1360]
lea rcx, [0x14018d510]
call fcn.140044c54
mov byte [rsp + 0x38], 1
mov byte [rsp + 0x30], 1
mov byte [rsp + 0x28], 1
mov eax, dword [0x1401778a4]
mov dword [rsp + 0x20], eax
xor r9d, r9d
xor r8d, r8d
lea rdx, [rsp + 0x50]
lea rcx, [rsp + 0x1360]
call fcn.140070670
test al, al
je 0x1400c3d82
jmp 0x1400c3ce3
mov edx, r15d
mov rcx, r14
call fcn.1400fd63c
test rax, rax
je 0x1400c3de9
mov edx, r15d
lea rcx, [rax + 2]
call fcn.1400fd63c
test rax, rax
je 0x1400c3de9
lea rcx, [rsp + 0x1360]
call fcn.14006f688
test al, al
jne 0x1400c3de9
mov r8d, ebx
lea rdx, [rsp + 0x310]
mov rcx, r14
call qword [sym.imp.KERNEL32.dll_ExpandEnvironmentStringsW]
dec eax
cmp eax, 0x7ff
ja 0x1400c3de9
mov r8, rbx
lea rdx, [rsp + 0x310]
lea rcx, [rsp + 0x1360]
call fcn.140096188
lea rdx, [rsp + 0x1360]
lea rcx, [rsp + 0x50]
call fcn.1400961f8
jmp 0x1400c3d7d
lea rdx, [rsp + 0x50]
lea rcx, [0x14017fe00]
call fcn.1400c3778
nop
lea rcx, [rsp + 0x50]
call fcn.140004af8
nop
jmp 0x1400c3e2a
mov r9, rbx
lea r8, [0x14017edfa]
lea rdx, [0x14017edfa]
lea rcx, [0x14018d510]
call fcn.140044c54
mov al, byte [0x1401789b0]
mov byte [0x14018d100], al
lea rcx, [0x14018d0d0]
call fcn.1400b02c4
cmp byte [0x14017ddc9], dil
je 0x1400c3e6f
call fcn.1400c4800
jmp 0x1400c3e81
mov dl, byte [0x14017ddab]
lea rcx, [0x14018a710]
call fcn.140004e24
cmp qword [0x1401bdf08], rdi
je 0x1400c3e96
lea rcx, [0x14017689e]
call fcn.14006f3a0
cmp dword [0x140167d48], 1
je 0x1400c3f32
cmp byte [0x140166ce4], dil
je 0x1400c3eba
lea rcx, [0x14018d510]
call fcn.140048600
jmp 0x1400c3f32
cmp byte [0x140179a3e], dil
je 0x1400c3ecf
lea rcx, [0x140168ea8]
call fcn.1400b636c
mov r8, rbx
lea rdx, [rsp + 0x1360]
lea rcx, [0x14018d510]
call fcn.140044490
lea rax, [rsp + 0x1360]
or r8, 0xffffffffffffffff
inc r8
cmp word [rax + r8*2], di
jne 0x1400c3ef2
lea rdx, [0x14017edfa]
lea rcx, [rsp + 0x1360]
call fcn.140099370
test eax, eax
jne 0x1400c3f23
lea rcx, [0x14017edfa]
call fcn.1400802e0
mov r13, rax
mov rdx, r13
lea rcx, [0x14018d510]
call fcn.140047a24
mov rcx, qword [0x1401bdf08]
call fcn.1400fc57c
mov byte [0x14018d100], dil
lea rcx, [0x14018d0d0]
call fcn.1400b02c4
mov rcx, qword [rsp + 0x2760]
xor rcx, rsp
call fcn.1400fc4d0
lea r11, [rsp + 0x2770]
mov rbx, qword [r11 + 0x28]
mov rdi, qword [r11 + 0x30]
mov r12, qword [r11 + 0x38]
mov rsp, r11
pop r15
pop r14
pop r13
ret