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

Disassembly:
push r13
push r14
push r15
mov eax, 0x2770
call fcn.1400f1270
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 [0x1401412b0]
xor rax, rsp
mov qword [rsp + 0x2760], rax
mov r12b, cl
xor edi, edi
test dl, dl
je 0x1400baa6a
cmp word [0x14015772e], di
je 0x1400baacf
cmp qword [0x14019f3f8], rdi
je 0x1400baacf
mov word [0x14015772e], di
jmp 0x1400baacf
mov cl, 1
call fcn.1400c0aa0
mov dword [0x14015a878], 3
mov qword [0x140149e60], rdi
mov cl, byte [0x140147ca4]
test cl, cl
jne 0x1400babc7
xor r8d, r8d
lea rdx, [0x140160b58]
lea rcx, [0x14016e120]
call fcn.1400402c8
cmp byte [0x14016f1a2], dil
je 0x1400baacf
mov eax, dword [0x14015a874]
mov r15d, 4
cmp qword [0x140160b88], 1
cmova eax, r15d
mov dword [0x14015a874], eax
jmp 0x1400baad5
mov r15d, 4
mov cl, byte [0x140147ca4]
test cl, cl
jne 0x1400babcd
cmp word [0x14015fb52], di
jne 0x1400babcd
mov r12b, dil
mov ebx, 0x800
mov r8d, ebx
lea rdx, [0x14015fb52]
mov ecx, dword [0x14015caf4]
call fcn.1400c065c
mov dword [rsp + 0x20], ebx
lea r13, [0x14010f1a8]
mov r9, r13
lea r8, [rsp + 0x1760]
lea rdx, str.DefFolder
lea rcx, [0x14010f9a8]
call fcn.14009f9e4
cmp word [rsp + 0x1760], di
jne 0x1400bab60
cmp byte [0x14016f1a2], dil
je 0x1400bab9e
lea rcx, [rsp + 0x1760]
call fcn.14003b324
cmp word [rsp + 0x1760], di
je 0x1400bab9e
mov rdx, rbx
lea rcx, [rsp + 0x1760]
call fcn.140077d10
mov r8, rbx
lea rdx, [0x14015fb52]
lea rcx, [rsp + 0x1760]
call fcn.14008e2ac
mov r8, rbx
lea rdx, [rsp + 0x1760]
lea rcx, [0x14015fb52]
call fcn.14008e2e4
cmp word [0x140155728], di
setne r8b
mov r9d, dword [0x14015caf4]
mov rdx, rbx
lea rcx, [0x14015fb52]
call fcn.1400c403c
mov cl, byte [0x140147ca4]
jmp 0x1400babd9
mov r15d, 4
lea r13, [0x14010f1a8]
mov ebx, 0x800
mov eax, dword [0x14015a874]
mov edx, 2
test eax, eax
cmove eax, edx
mov dword [0x14015a874], eax
test cl, cl
je 0x1400bad4c
mov r14d, dword [0x14016b344]
cmp r14d, 1
jbe 0x1400bac43
cmp dword [0x14015a844], 3
je 0x1400bb1ec
lea ecx, [rdx + 0x63]
call fcn.1400881f8
mov rbx, rax
mov ecx, 0x1fd
call fcn.1400881f8
mov rdx, rax
mov r9d, 0x30
mov r8, rbx
mov rcx, qword [0x140147cd8]
call fcn.1400c6a54
jmp 0x1400bb1ec
mov r8, rbx
lea rdx, [0x14015fb52]
lea rcx, [0x14016b340]
call fcn.140005104
mov r8, rbx
lea rdx, [0x140158740]
lea rcx, [0x14016b340]
call fcn.1400054d8
cmp word [0x140158740], di
je 0x1400bac87
mov rdx, rbx
lea rcx, [0x140158740]
call fcn.140077d10
mov byte [0x14015a8e8], dil
lea rdx, [rsp + 0x110]
lea rcx, [0x14016b340]
call fcn.1400054f8
mov eax, dword [rsp + 0x258]
mov dword [0x14015caf4], 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, [0x14015fb52]
call fcn.14006a8bc
test al, al
je 0x1400baced
cmp qword [rsp + 0x1310], 0x18
je 0x1400bad0e
cmp dword [rsp + 0x258], edi
jne 0x1400bad07
cmp byte [rsp + 0x190], dil
mov byte [0x14015a8d0], 1
jne 0x1400bad0e
mov byte [0x14015a8d0], dil
test r14d, r14d
jne 0x1400bad1c
cmp dword [rsp + 0x2e0], edi
je 0x1400bad2a
movzx eax, byte [rsp + 0x252]
mov dword [0x14015a864], eax
mov r14d, 0x2a
cmp qword [rsp + 0x248], rdi
je 0x1400bad43
mov dword [0x140155728], r14d
jmp 0x1400bad52
mov word [0x140155728], di
jmp 0x1400bad52
mov r14d, 0x2a
mov rcx, qword [0x140147cd8]
call qword [sym.imp.USER32.dll_IsWindowVisible]
neg eax
sbb rcx, rcx
and rcx, qword [0x140147cd8]
xor r8d, r8d
mov dl, r12b
call fcn.1400bdbc8
test al, al
je 0x1400bb1cd
mov al, byte [0x14019f417]
neg al
sbb ecx, ecx
and ecx, dword [0x14019f418]
mov dword [0x14015a858], ecx
mov eax, dword [0x14019f404]
dec eax
cmp eax, 1
ja 0x1400badf3
mov eax, dword [0x14019f410]
mov dword [rsp + 0x28], eax
mov eax, dword [0x14019f40c]
mov dword [rsp + 0x20], eax
mov r9d, dword [0x14019f408]
lea r8, str._dd_dh_dm
mov edx, 0x50
lea rcx, [rsp + 0x50]
call fcn.1400026d0
lea rdx, [rsp + 0x50]
cmp dword [0x14019f404], 1
lea rcx, [0x14015a9f0]
je 0x1400badee
lea rcx, [0x14015a9f8]
call fcn.14008f7bc
mov rcx, qword [0x14019f3f8]
test rcx, rcx
je 0x1400bae06
call fcn.1400c4984
jmp 0x1400bae2a
cmp byte [0x140147ca4], dil
je 0x1400bae2a
cmp qword [rsp + 0x248], rdi
je 0x1400bae2a
cmp word [0x140155728], r14w
jne 0x1400bae2a
mov word [0x140155728], di
cmp qword [0x140160b88], rdi
jne 0x1400bae67
mov ecx, 0x65
call fcn.1400881f8
mov rbx, rax
mov ecx, 0x14b
call fcn.1400881f8
mov rdx, rax
mov r9d, 0x30
mov r8, rbx
mov rcx, qword [0x140147cd8]
call fcn.1400c6a54
jmp 0x1400bb1cd
cmp word [0x14015772e], di
je 0x1400baf58
cmp dword [0x140158730], edi
jne 0x1400baf58
lea rdx, [0x140113c88]
lea rcx, [0x14015772e]
call fcn.14006a2ec
mov r12, rax
test rax, rax
je 0x1400baf58
mov r9, rax
mov edx, 1
mov r8d, 0x400
lea rcx, [rsp + 0x1360]
call fcn.1400fc644
mov r14, rax
mov rcx, r12
call fcn.1400f866c
mov eax, 0x3ff
cmp r14, rax
cmovb rax, r14
cmp rax, 0x400
jae 0x1400baf52
mov byte [rsp + rax + 0x1360], dil
mov dword [rsp + 0x40], 0x30c
test r14, r14
je 0x1400baf14
lea r8, [rsp + 0x40]
mov edx, r14d
lea rcx, [rsp + 0x1360]
call qword [sym.imp.ADVAPI32.dll_IsTextUnicode]
test eax, eax
je 0x1400baf14
mov dword [0x140158730], 3
jmp 0x1400baf58
cmp r14, 3
jbe 0x1400baf58
cmp byte [rsp + 0x1360], 0xef
jne 0x1400baf58
cmp byte [rsp + 0x1361], 0xbb
jne 0x1400baf58
cmp byte [rsp + 0x1362], 0xbf
jne 0x1400baf58
lea rcx, [rsp + 0x1360]
call fcn.140090dbc
test al, al
je 0x1400baf58
mov dword [0x140158730], r15d
jmp 0x1400baf58
call fcn.1400f104c
nop
lea rcx, [rsp + 0x50]
call fcn.14008e328
nop
lea rcx, [0x140160b58]
call fcn.14008e548
mov r15d, 0x25
lea rcx, [0x140160b58]
call fcn.14008e3d8
mov r14, rax
test rax, rax
je 0x1400bb08f
mov r9, rbx
lea r8, [rsp + 0x1760]
mov rdx, rax
lea rcx, [0x14016e120]
call fcn.14004091c
cmp word [r14], 0x40
jne 0x1400bb014
lea rcx, [rsp + 0x1760]
call fcn.140069390
test al, al
jne 0x1400bb014
lea rdx, [r14 + 2]
mov r9, rbx
lea r8, [rsp + 0x1760]
lea rcx, [0x14016e120]
call fcn.14004091c
mov byte [rsp + 0x38], 1
mov byte [rsp + 0x30], 1
mov byte [rsp + 0x28], 1
mov eax, dword [0x140158734]
mov dword [rsp + 0x20], eax
xor r9d, r9d
xor r8d, r8d
lea rdx, [rsp + 0x50]
lea rcx, [rsp + 0x1760]
call fcn.14006a3a0
test al, al
je 0x1400bb014
jmp 0x1400baf75
mov edx, r15d
mov rcx, r14
call fcn.1400f2430
test rax, rax
je 0x1400bb07b
mov edx, r15d
lea rcx, [rax + 2]
call fcn.1400f2430
test rax, rax
je 0x1400bb07b
lea rcx, [rsp + 0x1760]
call fcn.140069390
test al, al
jne 0x1400bb07b
mov r8d, ebx
lea rdx, [rsp + 0x310]
mov rcx, r14
call qword [sym.imp.KERNEL32.dll_ExpandEnvironmentStringsW]
dec eax
cmp eax, 0x7ff
ja 0x1400bb07b
mov r8, rbx
lea rdx, [rsp + 0x310]
lea rcx, [rsp + 0x1760]
call fcn.14008e2e4
lea rdx, [rsp + 0x1760]
lea rcx, [rsp + 0x50]
call fcn.14008e364
jmp 0x1400bb00f
lea rdx, [rsp + 0x50]
lea rcx, [0x140160b58]
call fcn.1400ba99c
nop
lea rcx, [rsp + 0x50]
call fcn.140004178
nop
jmp 0x1400bb0bc
cmp byte [0x14015eb05], dil
jne 0x1400bb0e2
mov r9, rbx
lea r8, [0x14015fb52]
lea rdx, [0x14015fb52]
lea rcx, [0x14016e120]
call fcn.14004091c
mov al, byte [0x140159840]
mov byte [0x14016dd10], al
lea rcx, [0x14016dce0]
call fcn.1400a8204
cmp byte [0x14015eb21], dil
je 0x1400bb10a
call fcn.1400bbaa8
jmp 0x1400bb11c
mov dl, byte [0x14015eb03]
lea rcx, [0x14016b340]
call fcn.1400042d4
cmp qword [0x14019f3f8], rdi
je 0x1400bb131
lea rcx, [0x14015772e]
call fcn.14006909c
cmp dword [0x140148d08], 1
je 0x1400bb1cd
cmp byte [0x140147ca4], dil
je 0x1400bb155
lea rcx, [0x14016e120]
call fcn.140043f1c
jmp 0x1400bb1cd
cmp byte [0x14015a8ce], dil
je 0x1400bb16a
lea rcx, [0x1401546e8]
call fcn.1400ae130
mov r8, rbx
lea rdx, [rsp + 0x1760]
lea rcx, [0x14016e120]
call fcn.140040240
lea rax, [rsp + 0x1760]
or r8, 0xffffffffffffffff
inc r8
cmp word [rax + r8*2], di
jne 0x1400bb18d
lea rdx, [0x14015fb52]
lea rcx, [rsp + 0x1760]
call fcn.140091370
test eax, eax
jne 0x1400bb1be
lea rcx, [0x14015fb52]
call fcn.1400796e4
mov r13, rax
mov rdx, r13
lea rcx, [0x14016e120]
call fcn.14004331c
mov rcx, qword [0x14019f3f8]
call fcn.1400f0f3c
mov byte [0x14016dd10], dil
lea rcx, [0x14016dce0]
call fcn.1400a8204
mov rcx, qword [rsp + 0x2760]
xor rcx, rsp
call fcn.1400f12e0
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