Function at 0x140004d38
Capabilities:
Delete file
Get common file path

Disassembly:
mov qword [rsp + 0x18], rbx
push rbp
push rsi
push rdi
push r12
push r13
push r14
push r15
lea rbp, [rsp - 0x105f0]
mov eax, 0x106f0
call fcn.140011300
sub rsp, rax
mov rax, qword [0x140016010]
xor rax, rsp
mov qword [rbp + 0x105e0], rax
mov r12, rdx
lea r8, str.set
mov r15d, ecx
xor r14d, r14d
mov edx, 0x8000
mov qword [rsp + 0x20], r14
lea rcx, [rbp + 0x5e0]
call qword [sym.imp.api_ms_win_crt_string_l1_1_0.dll_wcscpy_s]
lea eax, [r14 + 0x20]
lea rbx, [0x140016808]
lea rdi, [rbp + 0x5e8]
cmp word [rbx], ax
je 0x140004db2
cmp word [rbx], 9
jne 0x140004db8
add rbx, 2
jmp 0x140004da7
cmp word [rbx], 0x2f
mov sil, r14b
jne 0x140004ddc
cmp word [rbx + 2], 0x41
jne 0x140004ddc
cmp word [rbx + 4], ax
je 0x140004dd5
cmp word [rbx + 4], 9
jne 0x140004ddc
mov sil, 1
add rbx, 6
mov edx, 0x3d
mov rcx, rbx
call qword [sym.imp.VCRUNTIME140.dll_wcschr]
test rax, rax
jne 0x140004dfb
lea rax, [0x140012dc4]
jmp 0x14000514e
lea r13, [rbp + 0x5e8]
mov r8d, 0x3d
jmp 0x140004e25
mov word [rdi], ax
add rdi, 2
lea rax, [rbp + 0x105e0]
cmp rdi, rax
jae 0x1400052f1
add rbx, 2
movzx eax, word [rbx]
cmp ax, r8w
jne 0x140004e0a
test sil, sil
je 0x1400050c8
lea rcx, [rdi - 2]
movzx eax, word [rcx]
sub ax, 0x25
cmp ax, 0x39
ja 0x140004e58
movabs rdx, 0x200000000000563
bt rdx, rax
jb 0x140004e7f
cmp word [rcx], 0x7c
je 0x140004e7f
cmp word [rcx], 0x3e
lea rax, [rdi - 4]
jne 0x140004e6e
cmp word [rax], 0x3e
je 0x140004e7a
cmp word [rcx], 0x3c
jne 0x140004e82
cmp word [rax], 0x3c
jne 0x140004e82
mov rdi, rax
jmp 0x140004e82
mov rdi, rcx
lea rax, [rbp + 0x5ea]
mov r14d, 0x22
cmp word [rbp + 0x5e8], r14w
lea r13, [rbp + 0x5e8]
mov word [rdi], r8w
cmove r13, rax
add rdi, 2
lea rax, [rbp + 0x105e0]
cmp rdi, rax
jae 0x1400052f1
mov esi, 0x106
lea r9, [0x140012dc8]
xor ebx, ebx
lea rdx, [rsp + 0x30]
mov r8d, esi
mov qword [rsp + 0x28], rbx
lea rcx, [rsp + 0x28]
call qword [sym.imp.api_ms_win_crt_environment_l1_1_0.dll__wgetenv_s]
test eax, eax
jne 0x140004eeb
cmp qword [rsp + 0x28], rbx
jne 0x140004f00
lea r8, [0x140012dd0]
mov rdx, rsi
lea rcx, [rsp + 0x30]
call qword [sym.imp.api_ms_win_crt_string_l1_1_0.dll_wcscpy_s]
lea r9, [rbp + 0x3d0]
xor r8d, r8d
lea rdx, [0x140012dd4]
lea rcx, [rsp + 0x30]
call qword [sym.imp.KERNEL32.dll_GetTempFileNameW]
test eax, eax
jne 0x140004f35
mov ecx, dword [0x140026c20]
lea r8, [rsp + 0x30]
mov edx, 0x43c
call fcn.140003e48
lea r8, [rbp + 0x3d0]
mov rdx, rsi
lea rcx, [rsp + 0x30]
call qword [sym.imp.api_ms_win_crt_string_l1_1_0.dll_wcscpy_s]
mov edx, 0x20
lea rcx, [rsp + 0x30]
call qword [sym.imp.VCRUNTIME140.dll_wcschr]
or rsi, 0xffffffffffffffff
test rax, rax
je 0x140004fca
mov edx, r14d
lea rcx, [rsp + 0x30]
call qword [sym.imp.VCRUNTIME140.dll_wcschr]
test rax, rax
jne 0x140004fca
lea rax, [rsp + 0x30]
mov r14, rsi
inc r14
cmp word [rax + r14*2], bx
jne 0x140004f7e
lea rbx, [r14 + r14]
mov r8, rbx
lea rdx, [rsp + 0x30]
lea rcx, [rsp + 0x32]
call sub.VCRUNTIME140.dll_memmove
mov eax, 0x22
lea r14, [r14*2 + 4]
mov word [rsp + 0x30], ax
mov word [rsp + rbx + 0x32], ax
cmp r14, 0x20c
jae 0x1400052f8
xor eax, eax
mov word [rsp + r14 + 0x30], ax
mov r8, r12
lea rcx, [rsp + 0x30]
mov edx, r15d
call fcn.140004bc4
xor r12d, r12d
test eax, eax
jne 0x1400052f1
lea r8d, [r12 + 0x20]
lea rdx, [0x140012ddc]
lea rcx, [rsp + 0x30]
call qword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll__wfsopen]
mov rbx, rax
test rax, rax
jne 0x140005015
lea r8, [rsp + 0x30]
mov edx, 0x41c
xor ecx, ecx
call fcn.140003e48
mov r8, rbx
lea rcx, [rbp + 0x140]
mov edx, 0x40
call qword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll_fgetws]
test rax, rax
jne 0x140005040
lea r8, [rsp + 0x30]
mov edx, 0x41d
xor ecx, ecx
call fcn.140003e48
mov rcx, rbx
call qword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll_fclose]
cmp eax, esi
jne 0x14000505e
lea r8, [rsp + 0x30]
mov edx, 0x424
xor ecx, ecx
call fcn.140003e48
lea rcx, [rsp + 0x30]
call qword [sym.imp.api_ms_win_crt_filesystem_l1_1_0.dll__wremove]
cmp eax, esi
jne 0x14000507e
lea r8, [rsp + 0x30]
mov edx, 0x421
xor ecx, ecx
call fcn.140003e48
lea rcx, [rbp + 0x140]
mov rax, rsi
inc rax
cmp word [rcx + rax*2], r12w
jne 0x140005088
inc rax
lea rcx, [rbp + 0x105e0]
lea rax, [rdi + rax*2]
cmp rax, rcx
ja 0x1400052f1
lea rdx, [rbp + 0x105e0]
mov rcx, rdi
sub rdx, rdi
lea r8, [rbp + 0x140]
sar rdx, 1
call qword [sym.imp.api_ms_win_crt_string_l1_1_0.dll_wcscpy_s]
jmp 0x140005118
movzx eax, word [rbx]
or rsi, 0xffffffffffffffff
xor r12d, r12d
test ax, ax
je 0x140005114
lea r14d, [rsi + 0x26]
add rbx, 2
cmp ax, 0x5e
jne 0x140005178
movzx eax, word [rbx]
test ax, ax
je 0x14000510c
add rbx, 2
mov word [rdi], ax
lea rax, [rbp + 0x105e0]
add rdi, 2
cmp rdi, rax
jae 0x1400052f1
movzx eax, word [rbx]
test ax, ax
jne 0x1400050db
mov word [rdi], r12w
lea rbx, [0x140016800]
mov edx, 0x8000
mov rcx, rbx
lea r8, [rbp + 0x5e0]
call qword [sym.imp.api_ms_win_crt_string_l1_1_0.dll_wcscpy_s]
lea rax, [rbp + 0x5e0]
mov word [r13], r12w
inc rsi
cmp word [rax + rsi*2], r12w
jne 0x140005140
lea rax, [rbx + rsi*2]
mov rcx, qword [rbp + 0x105e0]
xor rcx, rsp
call fcn.1400106c0
mov rbx, qword [rsp + 0x10740]
add rsp, 0x106f0
pop r15
pop r14
pop r13
pop r12
pop rdi
pop rsi
pop rbp
ret
cmp ax, r14w
jne 0x1400050f5
movzx eax, word [rbx]
lea rcx, [rbp + 0x1c0]
cmp ax, r14w
je 0x1400051c4
movzx edx, ax
movzx eax, dx
test dx, dx
je 0x1400051c4
mov word [rcx], dx
lea rax, [rbp + 0x3c2]
add rcx, 2
cmp rcx, rax
je 0x1400052f1
add rbx, 2
movzx eax, word [rbx]
movzx edx, ax
cmp ax, r14w
jne 0x140005195
add rbx, 2
mov word [rcx], r12w
test ax, ax
je 0x14000529d
lea r8, [rbp + 0x1c0]
xor edx, edx
lea rcx, [rsp + 0x20]
call qword [sym.imp.api_ms_win_crt_environment_l1_1_0.dll__wdupenv_s]
mov r8, qword [rsp + 0x20]
mov rax, rsi
test r8, r8
je 0x140005242
inc rax
cmp word [r8 + rax*2], r12w
jne 0x1400051f6
lea r15, [rdi + rax*2]
lea rax, [rbp + 0x105e0]
cmp r15, rax
jae 0x1400052f1
lea rdx, [rbp + 0x105e0]
mov rcx, rdi
sub rdx, rdi
sar rdx, 1
call qword [sym.imp.api_ms_win_crt_string_l1_1_0.dll_wcscpy_s]
mov rcx, qword [rsp + 0x20]
mov rdi, r15
call qword [sym.imp.api_ms_win_crt_heap_l1_1_0.dll_free]
mov qword [rsp + 0x20], r12
jmp 0x14000510c
lea rcx, [rbp + 0x1c0]
inc rax
cmp word [rcx + rax*2], r12w
jne 0x140005249
add rax, 2
lea r15, [rdi + rax*2]
lea rax, [rbp + 0x105e0]
cmp r15, rax
jae 0x1400052f1
mov word [rdi], r14w
lea rdx, [rbp + 0x105e0]
add rdi, 2
lea r8, [rbp + 0x1c0]
sub rdx, rdi
mov rcx, rdi
sar rdx, 1
call qword [sym.imp.api_ms_win_crt_string_l1_1_0.dll_wcscpy_s]
mov word [r15 - 2], r14w
mov rdi, r15
jmp 0x14000510c
lea rcx, [rbp + 0x1c0]
mov rax, rsi
inc rax
cmp word [rcx + rax*2], r12w
jne 0x1400052a7
inc rax
lea rbx, [rdi + rax*2]
lea rax, [rbp + 0x105e0]
cmp rbx, rax
jae 0x1400052f1
mov word [rdi], r14w
lea rdx, [rbp + 0x105e0]
add rdi, 2
lea r8, [rbp + 0x1c0]
sub rdx, rdi
mov rcx, rdi
sar rdx, 1
call qword [sym.imp.api_ms_win_crt_string_l1_1_0.dll_wcscpy_s]
mov rdi, rbx
jmp 0x140005114
xor eax, eax
jmp 0x14000514e
call fcn.1400107e8
int3