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

Disassembly:
push r13
push r14
push r15
mov eax, 0x2770
call fcn.140101610
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 [0x140192630]
xor rax, rsp
mov qword [rsp + 0x2760], rax
mov r12b, cl
xor edi, edi
test dl, dl
je 0x1400c4cc6
cmp word [0x1401ac1ce], di
je 0x1400c4d2b
cmp qword [0x1401f7948], rdi
je 0x1400c4d2b
mov word [0x1401ac1ce], di
jmp 0x1400c4d2b
mov cl, 1
call fcn.1400cb4f8
mov dword [0x1401af31c], 3
mov qword [0x14019c788], rdi
mov cl, byte [0x14019b720]
test cl, cl
jne 0x1400c4e25
xor r8d, r8d
lea rdx, [0x1401b7738]
lea rcx, [0x1401c6f50]
call fcn.140044938
cmp byte [0x1401c7fce], dil
je 0x1400c4d2b
mov eax, dword [0x1401af318]
mov r14d, 4
cmp qword [0x1401b7768], 1
cmova eax, r14d
mov dword [0x1401af318], eax
jmp 0x1400c4d31
mov r14d, 4
mov cl, byte [0x14019b720]
test cl, cl
jne 0x1400c4e2b
cmp word [0x1401b6732], di
jne 0x1400c4e2b
mov r12b, dil
mov ebx, 0x800
mov r8d, ebx
lea rdx, [0x1401b6732]
mov ecx, dword [0x1401b16c8]
call fcn.1400caf68
mov dword [rsp + 0x20], ebx
lea r13, [0x1401423c8]
mov r9, r13
lea r8, [rsp + 0x1360]
lea rdx, str.DefFolder
lea rcx, [0x140143090]
call fcn.1400a8858
cmp word [rsp + 0x1360], di
jne 0x1400c4dbe
cmp byte [0x1401c7fce], dil
je 0x1400c4dfc
mov edx, ebx
lea rcx, [rsp + 0x1360]
call fcn.14003e998
cmp word [rsp + 0x1360], di
je 0x1400c4dfc
mov rdx, rbx
lea rcx, [rsp + 0x1360]
call fcn.14007f710
mov r8, rbx
lea rdx, [0x1401b6732]
lea rcx, [rsp + 0x1360]
call fcn.140096ec8
mov r8, rbx
lea rdx, [rsp + 0x1360]
lea rcx, [0x1401b6732]
call fcn.140096ef0
cmp word [0x1401aa1c8], di
setne r8b
mov r9d, dword [0x1401b16c8]
mov rdx, rbx
lea rcx, [0x1401b6732]
call fcn.1400ced68
mov cl, byte [0x14019b720]
jmp 0x1400c4e37
mov r14d, 4
lea r13, [0x1401423c8]
mov ebx, 0x800
mov eax, dword [0x1401af318]
mov edx, 2
test eax, eax
cmove eax, edx
mov dword [0x1401af318], eax
test cl, cl
je 0x1400c4fb1
mov r15d, dword [0x1401c40e4]
cmp r15d, 1
jbe 0x1400c4ea1
cmp dword [0x1401af2e4], 3
je 0x1400c53d1
lea ecx, [rdx + 0x63]
call fcn.140090e20
mov rbx, rax
mov ecx, 0x1fd
call fcn.140090e20
mov rdx, rax
mov r9d, 0x30
mov r8, rbx
mov rcx, qword [0x14019b6f0]
call fcn.1400d19e0
jmp 0x1400c53d1
mov r8, rbx
lea rdx, [0x1401b6732]
lea rcx, [0x1401c40e0]
call fcn.1400065fc
mov r8, rbx
lea rdx, [0x1401ad1e0]
lea rcx, [0x1401c40e0]
call fcn.140006b98
cmp word [0x1401ad1e0], di
je 0x1400c4ee5
mov rdx, rbx
lea rcx, [0x1401ad1e0]
call fcn.14007f710
mov byte [0x1401af389], dil
lea rdx, [rsp + 0x110]
lea rcx, [0x1401c40e0]
call fcn.140006bb8
mov eax, dword [rsp + 0x258]
mov dword [0x1401b16c8], 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, [0x1401b6732]
call fcn.14007194c
test al, al
je 0x1400c4f4b
cmp qword [rsp + 0x1310], 0x18
je 0x1400c4f6c
cmp dword [rsp + 0x258], edi
jne 0x1400c4f65
cmp byte [rsp + 0x190], dil
mov byte [0x1401af370], 1
jne 0x1400c4f6c
mov byte [0x1401af370], dil
test r15d, r15d
jne 0x1400c4f7a
cmp dword [rsp + 0x2e0], edi
je 0x1400c4f88
movzx eax, byte [rsp + 0x252]
mov dword [0x1401af308], eax
cmp qword [rsp + 0x248], rdi
je 0x1400c4faa
mov r8, rbx
lea rdx, [0x140142bd8]
lea rcx, [0x1401aa1c8]
call fcn.140096ef0
jmp 0x1400c4fb1
mov word [0x1401aa1c8], di
mov rcx, qword [0x14019b6f0]
call qword [sym.imp.USER32.dll_IsWindowVisible]
neg eax
sbb rcx, rcx
and rcx, qword [0x14019b6f0]
xor r8d, r8d
mov dl, r12b
call fcn.1400c81f0
test al, al
je 0x1400c53b2
mov al, byte [0x1401f7967]
neg al
sbb ecx, ecx
and ecx, dword [0x1401f7968]
mov dword [0x1401af2f8], ecx
mov rcx, qword [0x1401f7948]
test rcx, rcx
je 0x1400c5006
call fcn.1400cf69c
jmp 0x1400c502a
cmp byte [0x14019b720], dil
je 0x1400c502a
cmp qword [rsp + 0x248], rdi
je 0x1400c502a
cmp word [0x1401aa1c8], 0x2a
jne 0x1400c502a
mov word [0x1401aa1c8], di
cmp qword [0x1401b7768], rdi
jne 0x1400c5067
mov ecx, 0x65
call fcn.140090e20
mov rbx, rax
mov ecx, 0x14b
call fcn.140090e20
mov rdx, rax
mov r9d, 0x30
mov r8, rbx
mov rcx, qword [0x14019b6f0]
call fcn.1400d19e0
jmp 0x1400c53b2
cmp word [0x1401ac1ce], di
je 0x1400c5146
cmp dword [0x1401ad1d0], edi
jne 0x1400c5146
lea rdx, [0x140147320]
lea rcx, [0x1401ac1ce]
call fcn.14007137c
mov r12, rax
test rax, rax
je 0x1400c5146
mov r9, rax
mov edx, 1
mov r8d, 0x400
lea rcx, [rsp + 0x2360]
call fcn.14012b598
mov r15, rax
mov rcx, r12
call fcn.1401280c8
mov eax, 0x3ff
cmp r15, rax
cmovb rax, r15
cmp rax, 0x400
jae 0x1400c5140
mov byte [rsp + rax + 0x2360], dil
mov dword [rsp + 0x40], 0x30c
test r15, r15
je 0x1400c5114
lea r8, [rsp + 0x40]
mov edx, r15d
lea rcx, [rsp + 0x2360]
call qword [sym.imp.ADVAPI32.dll_IsTextUnicode]
test eax, eax
je 0x1400c5114
mov dword [0x1401ad1d0], 3
jmp 0x1400c5146
lea rcx, [rsp + 0x2360]
call fcn.140096710
cmp eax, 2
jne 0x1400c512f
mov dword [0x1401ad1d0], r14d
jmp 0x1400c5146
cmp eax, 1
jne 0x1400c5146
mov dword [0x1401ad1d0], 2
jmp 0x1400c5146
call fcn.1401013e4
nop
lea rcx, [rsp + 0x50]
call fcn.140096f24
nop
lea rcx, [0x1401b7738]
call fcn.140097164
mov r15d, 0x25
lea rcx, [0x1401b7738]
call fcn.140096fd4
mov r14, rax
test rax, rax
je 0x1400c527d
mov r9, rbx
lea r8, [rsp + 0x1360]
mov rdx, rax
lea rcx, [0x1401c6f50]
call fcn.140045074
cmp word [r14], 0x40
jne 0x1400c5202
lea rcx, [rsp + 0x1360]
call fcn.140070448
test al, al
jne 0x1400c5202
lea rdx, [r14 + 2]
mov r9, rbx
lea r8, [rsp + 0x1360]
lea rcx, [0x1401c6f50]
call fcn.140045074
mov byte [rsp + 0x38], 1
mov byte [rsp + 0x30], 1
mov byte [rsp + 0x28], 1
mov eax, dword [0x1401ad1d4]
mov dword [rsp + 0x20], eax
xor r9d, r9d
xor r8d, r8d
lea rdx, [rsp + 0x50]
lea rcx, [rsp + 0x1360]
call fcn.140071430
test al, al
je 0x1400c5202
jmp 0x1400c5163
mov edx, r15d
mov rcx, r14
call fcn.140120ac0
test rax, rax
je 0x1400c5269
mov edx, r15d
lea rcx, [rax + 2]
call fcn.140120ac0
test rax, rax
je 0x1400c5269
lea rcx, [rsp + 0x1360]
call fcn.140070448
test al, al
jne 0x1400c5269
mov r8d, ebx
lea rdx, [rsp + 0x310]
mov rcx, r14
call qword [sym.imp.KERNEL32.dll_ExpandEnvironmentStringsW]
dec eax
cmp eax, 0x7ff
ja 0x1400c5269
mov r8, rbx
lea rdx, [rsp + 0x310]
lea rcx, [rsp + 0x1360]
call fcn.140096ef0
lea rdx, [rsp + 0x1360]
lea rcx, [rsp + 0x50]
call fcn.140096f60
jmp 0x1400c51fd
lea rdx, [rsp + 0x50]
lea rcx, [0x1401b7738]
call fcn.1400c4bf8
nop
lea rcx, [rsp + 0x50]
call fcn.140004f48
nop
jmp 0x1400c52aa
mov r9, rbx
lea r8, [0x1401b6732]
lea rdx, [0x1401b6732]
lea rcx, [0x1401c6f50]
call fcn.140045074
mov al, byte [0x1401ae2e0]
mov byte [0x1401c6b40], al
lea rcx, [0x1401c6b10]
call fcn.1400b13e4
cmp byte [0x1401b5700], dil
je 0x1400c52ef
call fcn.1400c5ca4
jmp 0x1400c5301
mov dl, byte [0x1401b46db]
lea rcx, [0x1401c40e0]
call fcn.140005274
cmp qword [0x1401f7948], rdi
je 0x1400c5316
lea rcx, [0x1401ac1ce]
call fcn.140070160
cmp dword [0x14019b724], 1
je 0x1400c53b2
cmp byte [0x14019b720], dil
je 0x1400c533a
lea rcx, [0x1401c6f50]
call fcn.140048a14
jmp 0x1400c53b2
cmp byte [0x1401af36e], dil
je 0x1400c534f
lea rcx, [0x14019c7c8]
call fcn.1400b748c
mov r8, rbx
lea rdx, [rsp + 0x1360]
lea rcx, [0x1401c6f50]
call fcn.1400448b0
lea rax, [rsp + 0x1360]
or r8, 0xffffffffffffffff
inc r8
cmp word [rax + r8*2], di
jne 0x1400c5372
lea rdx, [0x1401b6732]
lea rcx, [rsp + 0x1360]
call fcn.14009a02c
test eax, eax
jne 0x1400c53a3
lea rcx, [0x1401b6732]
call fcn.1400810ec
mov r13, rax
mov rdx, r13
lea rcx, [0x1401c6f50]
call fcn.140047e30
mov rcx, qword [0x1401f7948]
call fcn.1401012cc
mov byte [0x1401c6b40], dil
lea rcx, [0x1401c6b10]
call fcn.1400b13e4
mov rcx, qword [rsp + 0x2760]
xor rcx, rsp
call fcn.140101680
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