joyce8/EMBER2024-capa huggingface dataset:
Function at 0x401ae0
Capabilities:
Allocate or change rwx memory

Disassembly:
push r12
push rbp
push rdi
push rsi
push rbx
sub rsp, 0x50
movsxd rdi, dword [0x0040c614]
mov r12, rcx
mov rsi, rdx
mov rbx, r8
test edi, edi
jle 0x401c88
mov rax, qword [0x0040c618]
xor ecx, ecx
add rax, 0x18
nop
mov rdx, qword [rax]
cmp r12, rdx
jb 0x401b2c
mov r8, qword [rax + 8]
mov r8d, dword [r8 + 8]
add rdx, r8
cmp r12, rdx
jb 0x401bb7
add ecx, 1
add rax, 0x28
cmp ecx, edi
jne 0x401b10
mov rcx, r12
call dbg.__mingw_GetSectionForAddress
mov rbp, rax
test rax, rax
je 0x401cc2
mov rax, qword [0x0040c618]
lea rdi, [rdi + rdi*4]
shl rdi, 3
add rax, rdi
mov qword [rax + 0x20], rbp
mov dword [rax], 0
call dbg._GetPEImageBase
mov ecx, dword [rbp + 0xc]
lea rdx, [rsp + 0x20]
mov r8d, 0x30
add rcx, rax
mov rax, qword [0x0040c618]
mov qword [rax + rdi + 0x18], rcx
call qword [sym.imp.KERNEL32.dll_VirtualQuery]
test rax, rax
je 0x401cd1
mov eax, dword [rsp + 0x44]
lea edx, [rax - 0x40]
and edx, 0xffffffbf
je 0x401bb0
sub eax, 4
and eax, 0xfffffffb
jne 0x401c40
add dword [0x0040c614], 1
cmp ebx, 8
jae 0x401be8
test bl, 4
jne 0x401c90
test ebx, ebx
je 0x401bd9
movzx eax, byte [rsi]
mov byte [r12], al
test bl, 2
jne 0x401cb0
add rsp, 0x50
pop rbx
pop rsi
pop rdi
pop rbp
pop r12
ret
mov rax, qword [rsi]
lea rcx, [r12 + 8]
and rcx, 0xfffffffffffffff8
mov qword [r12], rax
mov eax, ebx
mov rdx, qword [rsi + rax - 8]
mov qword [r12 + rax - 8], rdx
sub r12, rcx
add ebx, r12d
sub rsi, r12
and ebx, 0xfffffff8
cmp ebx, 8
jb 0x401bd9
and ebx, 0xfffffff8
xor eax, eax
mov edx, eax
add eax, 8
mov r8, qword [rsi + rdx]
mov qword [rcx + rdx], r8
cmp eax, ebx
jb 0x401c1a
add rsp, 0x50
pop rbx
pop rsi
pop rdi
pop rbp
pop r12
ret
mov rcx, qword [rsp + 0x20]
mov rdx, qword [rsp + 0x38]
mov r8d, 0x40
add rdi, qword [0x0040c618]
mov qword [rdi + 8], rcx
mov r9, rdi
mov qword [rdi + 0x10], rdx
call qword [sym.imp.KERNEL32.dll_VirtualProtect]
test eax, eax
jne 0x401bb0
call qword [sym.imp.KERNEL32.dll_GetLastError]
lea rcx, str.__VirtualProtect_failed_with_code_0x_x
mov edx, eax
call dbg.__report_error
nop dword [rax]
xor edi, edi
jmp 0x401b37
mov eax, dword [rsi]
mov ebx, ebx
mov dword [r12], eax
mov eax, dword [rsi + rbx - 4]
mov dword [r12 + rbx - 4], eax
jmp 0x401bd9
mov ebx, ebx
movzx eax, word [rsi + rbx - 2]
mov word [r12 + rbx - 2], ax
jmp 0x401bd9
mov rdx, r12
lea rcx, str.Address__p_has_no_image_section
call dbg.__report_error
mov rax, qword [0x0040c618]
mov edx, dword [rbp + 8]
lea rcx, str.__VirtualQuery_failed_for__d_bytes_at_address__p
mov r8, qword [rax + rdi + 0x18]
call dbg.__report_error
nop
nop dword [rax]
Function at 0x4024b0
Capabilities:
Get thread local storage value

Disassembly:
push r12
push rdi
push rsi
push rbx
sub rsp, 0x28
lea rcx, [0x0040c900]
call qword [sym.imp.KERNEL32.dll_EnterCriticalSection]
mov rbx, qword [0x0040c8e0]
test rbx, rbx
je 0x402504
mov rdi, qword [sym.imp.KERNEL32.dll_TlsGetValue]
mov rsi, qword [sym.imp.KERNEL32.dll_GetLastError]
mov ecx, dword [rbx]
call rdi
mov r12, rax
call rsi
test eax, eax
jne 0x4024fb
test r12, r12
je 0x4024fb
mov rax, qword [rbx + 8]
mov rcx, r12
call rax
mov rbx, qword [rbx + 0x10]
test rbx, rbx
jne 0x4024e0
lea rcx, [0x0040c900]
add rsp, 0x28
pop rbx
pop rsi
pop rdi
pop r12
jmp qword [sym.imp.KERNEL32.dll_LeaveCriticalSection]

Function at 0x402730
Capabilities:
Parse pe header

Disassembly:
cmp word [rcx], 0x5a4d
jne 0x402740
jmp sym._ValidateImageBase.part.0
xor eax, eax
ret

Function at 0x402750
Capabilities:
Enumerate pe sections

Disassembly:
movsxd rax, dword [rcx + 0x3c]
add rcx, rax
movzx eax, word [rcx + 0x14]
lea rax, [rcx + rax + 0x18]
movzx ecx, word [rcx + 6]
test ecx, ecx
je 0x402795
sub ecx, 1
lea rcx, [rcx + rcx*4]
lea r9, [rax + rcx*8 + 0x28]
nop dword [rax]
mov r8d, dword [rax + 0xc]
mov rcx, r8
cmp r8, rdx
ja 0x40278c
add ecx, dword [rax + 8]
cmp rcx, rdx
ja 0x402797
add rax, 0x28
cmp rax, r9
jne 0x402778
xor eax, eax
ret

Function at 0x402840
Capabilities:
Enumerate pe sections

Disassembly:
sub rsp, 0x28
mov r10, qword [0x00409760]
xor r8d, r8d
cmp word [r10], 0x5a4d
mov r9, rcx
jne 0x4028b9
mov rcx, r10
call sym._ValidateImageBase.part.0
test eax, eax
je 0x4028b9
movsxd rax, dword [r10 + 0x3c]
mov rcx, r9
sub rcx, r10
add r10, rax
movzx eax, word [r10 + 0x14]
lea r8, [r10 + rax + 0x18]
movzx eax, word [r10 + 6]
test eax, eax
je 0x4028b6
sub eax, 1
lea rax, [rax + rax*4]
lea r9, [r8 + rax*8 + 0x28]
nop dword [rax]
mov edx, dword [r8 + 0xc]
mov rax, rdx
cmp rcx, rdx
jb 0x4028ad
add eax, dword [r8 + 8]
cmp rcx, rax
jb 0x4028b9
add r8, 0x28
cmp r8, r9
jne 0x402898
xor r8d, r8d
mov rax, r8
add rsp, 0x28
ret

Function at 0x4029a0
Capabilities:
Enumerate pe sections

Disassembly:
sub rsp, 0x28
mov r9, qword [0x00409760]
xor eax, eax
cmp word [r9], 0x5a4d
mov r8, rcx
jne 0x402a0f
mov rcx, r9
call sym._ValidateImageBase.part.0
test eax, eax
je 0x402a0f
movsxd rax, dword [r9 + 0x3c]
mov rcx, r8
sub rcx, r9
add r9, rax
movzx eax, word [r9 + 0x14]
movzx edx, word [r9 + 6]
lea rax, [r9 + rax + 0x18]
test edx, edx
je 0x402a0d
sub edx, 1
lea rdx, [rdx + rdx*4]
lea r9, [rax + rdx*8 + 0x28]
mov r8d, dword [rax + 0xc]
mov rdx, r8
cmp rcx, r8
jb 0x402a04
add edx, dword [rax + 8]
cmp rcx, rdx
jb 0x402a18
add rax, 0x28
cmp rax, r9
jne 0x4029f0
xor eax, eax
add rsp, 0x28
ret
mov eax, dword [rax + 0x24]
not eax
shr eax, 0x1f
add rsp, 0x28
ret
Function at 0x402a30
Capabilities:
Enumerate pe sections

Disassembly:
sub rsp, 0x28
mov r11, qword [0x00409760]
xor r9d, r9d
cmp word [r11], 0x5a4d
mov r8d, ecx
jne 0x402aa8
mov rcx, r11
call sym._ValidateImageBase.part.0
test eax, eax
je 0x402aa8
movsxd rcx, dword [r11 + 0x3c]
add rcx, r11
mov eax, dword [rcx + 0x90]
test eax, eax
je 0x402aa8
movzx edx, word [rcx + 0x14]
lea rdx, [rcx + rdx + 0x18]
movzx ecx, word [rcx + 6]
test ecx, ecx
je 0x402aa8
sub ecx, 1
lea rcx, [rcx + rcx*4]
lea r10, [rdx + rcx*8 + 0x28]
nop dword [rax + rax]
mov r9d, dword [rdx + 0xc]
mov rcx, r9
cmp rax, r9
jb 0x402a9c
add ecx, dword [rdx + 8]
cmp rax, rcx
jb 0x402ab0
add rdx, 0x28
cmp rdx, r10
jne 0x402a88
xor r9d, r9d
mov rax, r9
add rsp, 0x28
ret
add rax, r11
jmp 0x402ac0
sub r8d, 1
add rax, 0x14
mov ecx, dword [rax + 4]
test ecx, ecx
jne 0x402ace
mov edx, dword [rax + 0xc]
test edx, edx
je 0x402aa5
test r8d, r8d
jg 0x402ab8
mov r9d, dword [rax + 0xc]
add r9, r11
mov rax, r9
add rsp, 0x28
ret
Function at 0x140001487
Capabilities:
Parse pe header

Disassembly:
push rbp
mov rbp, rsp
sub rsp, 0x20
mov rax, qword [0x140020970]
mov dword [rax], 1
mov rax, qword [0x140020980]
mov dword [rax], 1
mov rax, qword [0x140020990]
mov dword [rax], 1
mov rax, qword [0x1400208f0]
mov qword [rbp - 8], rax
mov rax, qword [rbp - 8]
movzx eax, word [rax]
cmp ax, 0x5a4d
je 0x1400014d8
mov eax, 0
jmp 0x140001585
mov rax, qword [rbp - 8]
mov eax, dword [rax + 0x3c]
movsxd rdx, eax
mov rax, qword [rbp - 8]
add rax, rdx
mov qword [rbp - 0x10], rax
mov rax, qword [rbp - 0x10]
mov eax, dword [rax]
cmp eax, 0x4550
je 0x140001504
mov eax, 0
jmp 0x140001585
mov rax, qword [rbp - 0x10]
add rax, 0x18
mov qword [rbp - 0x18], rax
mov rax, qword [rbp - 0x18]
movzx eax, word [rax]
movzx eax, ax
cmp eax, 0x10b
je 0x14000152a
cmp eax, 0x20b
je 0x140001551
jmp 0x140001580
mov rax, qword [rbp - 0x18]
mov eax, dword [rax + 0x5c]
cmp eax, 0xe
ja 0x14000153d
mov eax, 0
jmp 0x140001585
mov rax, qword [rbp - 0x18]
mov eax, dword [rax + 0xd0]
test eax, eax
setne al
movzx eax, al
jmp 0x140001585
mov rax, qword [rbp - 0x18]
mov qword [rbp - 0x20], rax
mov rax, qword [rbp - 0x20]
mov eax, dword [rax + 0x6c]
cmp eax, 0xe
ja 0x14000156c
mov eax, 0
jmp 0x140001585
mov rax, qword [rbp - 0x20]
mov eax, dword [rax + 0xe0]
test eax, eax
setne al
movzx eax, al
jmp 0x140001585
mov eax, 0
add rsp, 0x20
pop rbp
ret
Function at 0x140001c30
Capabilities:
Read file on windows

Disassembly:
push r13
push r12
push rbp
push rdi
push rsi
push rbx
sub rsp, 0x28
mov rbp, rcx
mov rcx, qword [rcx]
mov r12, rdx
test rcx, rcx
je 0x140001d30
mov edx, dword [r12 + 4]
xor r8d, r8d
add edx, dword [rbp + 8]
call fcn.14000f330
test eax, eax
js 0x140001d78
mov esi, dword [r12 + 0xc]
mov rcx, rsi
call sub.msvcrt.dll_malloc
mov r13, rax
test rax, rax
je 0x140001d92
cmp byte [r12 + 0x10], 1
je 0x140001d10
mov rdi, rax
test rsi, rsi
jne 0x140001ca0
jmp 0x140001ce9
add rdi, rbx
sub rsi, rbx
je 0x140001ce9
mov ebx, 0x2000
mov r9, qword [rbp]
mov r8d, 1
mov rcx, rdi
cmp rsi, rbx
cmovbe rbx, rsi
mov rdx, rbx
call sub.msvcrt.dll_fread
test rax, rax
jne 0x140001c98
lea r8, [r12 + 0x12]
lea rdx, str.Failed_to_extract__s:_failed_to_read_data_chunk__n
lea rcx, str.fread
call fcn.140002f90
mov rcx, r13
call sub.msvcrt.dll_free
xor r13d, r13d
mov rcx, qword [rbp]
test rcx, rcx
je 0x140001cff
call sub.msvcrt.dll_fclose
mov qword [rbp], 0
mov rax, r13
add rsp, 0x28
pop rbx
pop rsi
pop rdi
pop rbp
pop r12
pop r13
ret
xor r8d, r8d
mov r9, rax
mov rdx, r12
mov rcx, rbp
call fcn.140001850
test eax, eax
je 0x140001ce9
jmp 0x140001cde
lea rcx, [rbp + 0x78]
lea rdx, [0x14001a1a0]
call fcn.1400044f0
mov qword [rbp], rax
mov rcx, rax
test rax, rax
jne 0x140001c4e
lea rdx, [r12 + 0x12]
lea rcx, str.Failed_to_extract__s:_failed_to_open_archive_file__n
call fcn.140002e10
xor r13d, r13d
mov rax, r13
add rsp, 0x28
pop rbx
pop rsi
pop rdi
pop rbp
pop r12
pop r13
ret
lea r8, [r12 + 0x12]
lea rdx, str.Failed_to_extract__s:_failed_to_seek_to_the_entrys_data__n
lea rcx, str.fseek
call fcn.140002f90
jmp 0x140001d61
mov r9d, esi
lea r8, [r12 + 0x12]
lea rdx, str.Failed_to_extract__s:_failed_to_allocate_data_buffer___u_bytes___n
lea rcx, [0x14001a0e2]
call fcn.140002f90
jmp 0x140001ce6
Function at 0x140001dc0
Capabilities:
Read file on windows
Write file on windows

Disassembly:
push r13
push r12
push rbp
push rdi
push rsi
push rbx
sub rsp, 0x28
mov rdi, rcx
mov rbx, rdx
call fcn.140007570
cmp eax, 0xffffffff
je 0x140001f8e
lea r13, [rbx + 0x12]
lea rcx, [rdi + 0x3078]
mov rdx, r13
call fcn.1400077f0
mov r12, rax
test rax, rax
je 0x140001f78
mov rcx, qword [rdi]
test rcx, rcx
je 0x140001f00
mov edx, dword [rbx + 4]
xor r8d, r8d
add edx, dword [rdi + 8]
call fcn.14000f330
test eax, eax
js 0x140001f60
cmp byte [rbx + 0x10], 1
je 0x140001ec0
mov ecx, 0x2000
call sub.msvcrt.dll_malloc
mov rbp, rax
test rax, rax
je 0x140001f98
mov esi, dword [rbx + 0xc]
test rsi, rsi
jne 0x140001e76
jmp 0x140001f38
mov r9, r12
mov r8d, 1
mov rdx, rbx
mov rcx, rbp
call sub.msvcrt.dll_fwrite
test rax, rax
je 0x140001f40
sub rsi, rbx
je 0x140001f38
mov ebx, 0x2000
mov r9, qword [rdi]
mov r8d, 1
mov rcx, rbp
cmp rsi, rbx
cmovbe rbx, rsi
mov rdx, rbx
call sub.msvcrt.dll_fread
test rax, rax
jne 0x140001e50
mov r8, r13
lea rdx, str.Failed_to_extract__s:_failed_to_read_data_chunk__n
lea rcx, str.fread
call fcn.140002f90
mov ebx, 0xffffffff
mov rcx, rbp
call sub.msvcrt.dll_free
jmp 0x140001ed3
mov rdx, rbx
xor r9d, r9d
mov r8, r12
mov rcx, rdi
call fcn.140001850
mov ebx, eax
mov rcx, qword [rdi]
test rcx, rcx
je 0x140001ee7
call sub.msvcrt.dll_fclose
mov qword [rdi], 0
mov rcx, r12
call sub.msvcrt.dll_fclose
mov eax, ebx
add rsp, 0x28
pop rbx
pop rsi
pop rdi
pop rbp
pop r12
pop r13
ret
lea rcx, [rdi + 0x78]
lea rdx, [0x14001a1a0]
call fcn.1400044f0
mov qword [rdi], rax
mov rcx, rax
test rax, rax
jne 0x140001e0b
mov rdx, r13
lea rcx, str.Failed_to_extract__s:_failed_to_open_archive_file__n
call fcn.140002e10
mov ebx, 0xffffffff
jmp 0x140001ed3
xor ebx, ebx
jmp 0x140001eb6
mov r8, r13
lea rdx, str.Failed_to_extract__s:_failed_to_write_data_chunk__n
lea rcx, str.fwrite
call fcn.140002f90
jmp 0x140001eb1
mov r8, r13
lea rdx, str.Failed_to_extract__s:_failed_to_seek_to_the_entrys_data__n
lea rcx, str.fseek
call fcn.140002f90
jmp 0x140001f2e
mov r8, r13
lea rdx, str.Failed_to_extract__s:_failed_to_open_target_file__n
lea rcx, str.fopen
call fcn.140002f90
mov ebx, 0xffffffff
jmp 0x140001eef
mov r8, r13
lea rdx, str.Failed_to_extract__s:_failed_to_allocate_temporary_buffer__n
lea rcx, [0x14001a0e2]
call fcn.140002f90
jmp 0x140001f2e
Function at 0x140001fc0
Capabilities:
Read file on windows

Disassembly:
push rdi
push rsi
push rbx
sub rsp, 0x30
mov rdi, rcx
mov rcx, qword [rcx]
test rcx, rcx
je 0x140002160
mov rax, qword [0x1400203c0]
mov r8d, 8
mov rdx, qword [rax]
mov qword [rsp + 0x28], rdx
shr rdx, 0x18
add edx, 0xc
mov byte [rsp + 0x2b], dl
lea rdx, [rsp + 0x28]
call fcn.140007e70
mov rbx, rax
test rax, rax
je 0x14000219b
mov rcx, qword [rdi]
xor r8d, r8d
mov edx, eax
call fcn.14000f330
test eax, eax
js 0x1400021c5
mov r9, qword [rdi]
lea rcx, [rdi + 0x20]
mov r8d, 1
mov edx, 0x58
call sub.msvcrt.dll_fread
test rax, rax
je 0x140002188
mov eax, dword [rdi + 0x28]
mov ecx, dword [rdi + 0x30]
add rbx, 0x58
xor r8d, r8d
mov dword [rdi + 0x507c], 0
mov edx, dword [rdi + 0x2c]
bswap eax
bswap ecx
mov dword [rdi + 0x28], eax
mov eax, eax
mov dword [rdi + 0x30], ecx
mov ecx, dword [rdi + 0x34]
sub rbx, rax
bswap edx
mov qword [rdi + 8], rbx
bswap ecx
mov dword [rdi + 0x2c], edx
add edx, ebx
mov dword [rdi + 0x34], ecx
mov dword [0x1400260b0], ecx
mov rcx, qword [rdi]
call fcn.14000f330
movsxd rbx, dword [rdi + 0x30]
mov rcx, rbx
call sub.msvcrt.dll_malloc
mov qword [rdi + 0x10], rax
mov rcx, rax
test rax, rax
je 0x1400021da
mov r9, qword [rdi]
mov r8d, 1
mov rdx, rbx
call sub.msvcrt.dll_fread
test rax, rax
je 0x1400021a2
movsxd rax, dword [rdi + 0x30]
add rax, qword [rdi + 0x10]
mov qword [rdi + 0x18], rax
mov rcx, qword [rdi]
call sub.msvcrt.dll_ferror
mov ebx, eax
test eax, eax
jne 0x1400021b7
mov rax, qword [rdi + 0x10]
mov r8, qword [rdi + 0x18]
lea rsi, str.Cannot_read_Table_of_Contents._n
nop
cmp rax, r8
jae 0x140002138
mov ecx, dword [rax + 4]
mov edx, dword [rax]
bswap ecx
mov dword [rax + 4], ecx
mov ecx, dword [rax + 8]
bswap edx
mov dword [rax], edx
movsxd rdx, edx
bswap ecx
mov dword [rax + 8], ecx
mov ecx, dword [rax + 0xc]
bswap ecx
mov dword [rax + 0xc], ecx
add rax, rdx
cmp rax, qword [rdi + 0x10]
jae 0x1400020f0
mov rcx, rsi
call fcn.140002e10
mov rax, qword [rdi + 0x18]
mov r8, rax
cmp rax, r8
jb 0x1400020f5
nop dword [rax + rax]
mov rcx, qword [rdi]
test rcx, rcx
je 0x14000214c
call sub.msvcrt.dll_fclose
mov qword [rdi], 0
mov eax, ebx
add rsp, 0x30
pop rbx
pop rsi
pop rdi
ret
lea rcx, [rdi + 0x78]
lea rdx, [0x14001a1a0]
call fcn.1400044f0
mov qword [rdi], rax
mov rcx, rax
test rax, rax
jne 0x140001fd6
jmp 0x14000219b
lea rdx, str.Failed_to_read_cookie__n
lea rcx, str.fread
call fcn.140002f90
mov ebx, 0xffffffff
jmp 0x14000214c
lea rdx, str.Could_not_read_full_TOC__n
lea rcx, str.fread
call fcn.140002f90
jmp 0x14000219b
lea rcx, str.Error_on_file._n
call fcn.140002e10
jmp 0x14000219b
lea rdx, str.Failed_to_seek_to_cookie_position__n
lea rcx, str.fseek
call fcn.140002f90
jmp 0x14000219b
lea rdx, str.Could_not_allocate_buffer_for_TOC__n
lea rcx, [0x14001a0e2]
call fcn.140002f90
jmp 0x14000219b
Function at 0x140007120
Capabilities:
Query environment variable

Disassembly:
push rbx
mov eax, 0x4020
call fcn.14000e2a0
sub rsp, rax
xor r8d, r8d
mov rdx, rcx
xor ecx, ecx
lea rbx, [rsp + 0x20]
call fcn.140008350
mov r8d, 0x2000
mov rdx, rbx
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_GetEnvironmentVariableW]
test eax, eax
jne 0x140007168
xor eax, eax
add rsp, 0x4020
pop rbx
ret
lea rdx, [rsp + 0x2020]
mov r8d, 0x2000
mov rcx, rbx
call qword [sym.imp.KERNEL32.dll_ExpandEnvironmentStringsW]
xor ecx, ecx
xor r8d, r8d
mov rdx, rbx
call fcn.140008180
mov rcx, rax
test rax, rax
je 0x140007156
cmp byte [rax], 0
je 0x140007156
call sub.msvcrt.dll__strdup
add rsp, 0x4020
pop rbx
ret

Function at 0x140007210
Capabilities:
Set environment variable

Disassembly:
push rsi
push rbx
sub rsp, 0x28
xor r8d, r8d
mov rdx, rcx
xor ecx, ecx
call fcn.140008350
xor edx, edx
mov rbx, rax
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_SetEnvironmentVariableW]
mov rcx, rbx
mov esi, eax
call sub.msvcrt.dll_free
mov eax, esi
add rsp, 0x28
pop rbx
pop rsi
ret

Function at 0x140007250
Capabilities:
Create directory
Query environment variable

Disassembly:
push rbp
mov eax, 0x4028
push rdi
push rsi
push rbx
call fcn.14000e2a0
sub rsp, rax
xor r8d, r8d
mov rdx, rcx
xor ecx, ecx
call fcn.140008350
mov rbx, rax
test rax, rax
je 0x140007390
lea rdi, [rsp + 0x20]
mov rcx, rax
mov r8d, 0x1000
mov rdx, rdi
call qword [sym.imp.KERNEL32.dll_ExpandEnvironmentStringsW]
mov rcx, rbx
mov esi, eax
call sub.msvcrt.dll_free
test esi, esi
je 0x140007370
mov rcx, rdi
call fcn.140008790
test eax, eax
jne 0x140007358
mov r8d, 0x1000
mov rdx, rdi
xor ecx, ecx
call qword [sym.imp.msvcrt.dll__wfullpath]
mov rbp, rax
test rbp, rbp
je 0x1400073a0
lea rsi, [rsp + 0x2020]
xor eax, eax
mov ecx, 0x400
mov edx, 0x5c
mov rdi, rsi
rep stosq qword [rdi], rax
mov rcx, rbp
call sub.msvcrt.dll_wcschr
mov rdi, qword [sym.imp.KERNEL32.dll_CreateDirectoryW]
mov rbx, rax
test rax, rax
je 0x14000733d
nop dword [rax]
mov r8, rbx
mov rdx, rbp
mov rcx, rsi
sub r8, rbp
sar r8, 1
add r8, 1
call sub.msvcrt.dll_wcsncpy
xor edx, edx
mov rcx, rsi
call rdi
lea rcx, [rbx + 2]
mov edx, 0x5c
call sub.msvcrt.dll_wcschr
mov rbx, rax
test rax, rax
jne 0x140007308
xor edx, edx
mov rcx, rbp
call rdi
mov rax, rbp
add rsp, 0x4028
pop rbx
pop rsi
pop rdi
pop rbp
ret
mov rcx, rdi
call qword [sym.imp.msvcrt.dll__wcsdup_1]
mov rbp, rax
jmp 0x1400072c7
lea rcx, str.LOADER:_Failed_to_expand_environment_variables_in_the_runtime_tmpdir._n
xor ebp, ebp
call fcn.140002e10
mov rax, rbp
add rsp, 0x4028
pop rbx
pop rsi
pop rdi
pop rbp
ret
lea rcx, str.LOADER:_Failed_to_convert_runtime_tmpdir_to_a_wide_string._n
xor ebp, ebp
call fcn.140002e10
jmp 0x14000737e
lea rcx, str.LOADER:_Failed_to_obtain_the_absolute_path_of_the_runtime_tmpdir._n
xor ebp, ebp
call fcn.140002e10
jmp 0x14000737e
Function at 0x1400073b0
Capabilities:
Get common file path
Set environment variable

Disassembly:
push r15
mov eax, 0x2048
push r14
push r13
push r12
push rbp
push rdi
push rsi
push rbx
call fcn.14000e2a0
sub rsp, rax
mov r15, rcx
mov rdi, rdx
test rdx, rdx
je 0x140007419
lea rcx, [0x14001c573]
call fcn.140007120
mov rcx, rdi
mov r14, rax
call fcn.140007250
mov rbx, rax
test rax, rax
je 0x1400074a3
lea rcx, [0x14001c578]
mov rdx, rax
call qword [sym.imp.msvcrt.dll__wputenv_s]
mov rcx, rbx
mov esi, eax
call sub.msvcrt.dll_free
test esi, esi
jne 0x1400074c0
lea r12, [rsp + 0x40]
mov ecx, 0x1000
lea rbp, [rsp + 0x20]
mov esi, 5
mov rdx, r12
call qword [sym.imp.KERNEL32.dll_GetTempPathW]
call sub.msvcrt.dll__getpid
lea r8, str._MEI_d
mov edx, 0x10
mov rcx, rbp
mov r9d, eax
call fcn.140006fb0
mov r13, qword [sym.imp.msvcrt.dll__wtempnam]
mov rcx, r12
mov rdx, rbp
call r13
mov rcx, rax
mov rbx, rax
call fcn.140008580
test eax, eax
je 0x1400074d0
mov rcx, rbx
call sub.msvcrt.dll_free
sub esi, 1
jne 0x140007459
test rdi, rdi
je 0x1400074a3
test r14, r14
je 0x140007518
lea rcx, [0x14001c573]
mov rdx, r14
call fcn.1400071b0
mov rcx, r14
call sub.msvcrt.dll_free
xor eax, eax
add rsp, 0x2048
pop rbx
pop rsi
pop rdi
pop rbp
pop r12
pop r13
pop r14
pop r15
ret
lea rcx, str.LOADER:_Failed_to_set_the_TMP_environment_variable._n
call fcn.140002e10
jmp 0x1400074a3
mov rcx, r15
mov r8d, 0x1000
mov rdx, rbx
call fcn.140008180
mov rcx, rbx
call sub.msvcrt.dll_free
test rdi, rdi
je 0x14000750a
test r14, r14
je 0x140007544
lea rcx, [0x14001c573]
mov rdx, r14
call fcn.1400071b0
mov rcx, r14
call sub.msvcrt.dll_free
mov eax, 1
jmp 0x1400074a5
xor r8d, r8d
xor ecx, ecx
lea rdx, [0x14001c573]
call fcn.140008350
xor edx, edx
mov rbx, rax
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_SetEnvironmentVariableW]
mov rcx, rbx
call sub.msvcrt.dll_free
jmp 0x1400074a3
xor r8d, r8d
xor ecx, ecx
lea rdx, [0x14001c573]
call fcn.140008350
xor edx, edx
mov rbx, rax
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_SetEnvironmentVariableW]
mov rcx, rbx
call sub.msvcrt.dll_free
jmp 0x14000750a
Function at 0x1400075d0
Capabilities:
Delete directory

Disassembly:
push r15
mov eax, 0x44b8
push r14
push r13
push r12
push rbp
push rdi
push rsi
push rbx
call fcn.14000e2a0
sub rsp, rax
mov r8d, 0x1000
lea rax, [rsp + 0x24a0]
mov rdx, rcx
lea r12, [rsp + 0x490]
mov rsi, rax
mov rcx, rax
mov qword [rsp + 0x28], rax
call fcn.140008350
mov rdx, rsi
mov rcx, r12
call sub.msvcrt.dll_wcscpy
mov rcx, r12
call sub.msvcrt.dll_wcslen
mov r13, rax
movzx eax, word [rsp + rax*2 + 0x48e]
cmp ax, 0x2f
je 0x14000763c
cmp ax, 0x5c
jne 0x140007690
lea rdx, [0x14001c600]
mov rcx, r12
lea rbx, [rsp + 0x260]
call sub.msvcrt.dll_wcscat
mov rdx, rbx
mov rcx, r12
call fcn.14000ee80
mov r14, rax
cmp rax, 0xffffffffffffffff
jne 0x1400076a8
mov rcx, qword [rsp + 0x28]
call qword [sym.imp.msvcrt.dll__wrmdir]
nop
add rsp, 0x44b8
pop rbx
pop rsi
pop rdi
pop rbp
pop r12
pop r13
pop r14
pop r15
ret
lea rdx, [0x14001c5fc]
mov rcx, r12
add r13, 1
call sub.msvcrt.dll_wcscat
jmp 0x14000763c
lea rdi, [rsp + 0x30]
mov ecx, 0x46
mov rsi, rbx
mov rdx, r13
rep movsq qword [rdi], qword [rsi]
lea rbp, [rsp + 0x30]
mov rcx, r12
mov r8, rbp
mov r15, rbp
call fcn.140007710
jmp 0x1400076ef
mov rdi, rbp
mov ecx, 0x46
mov rsi, rbx
mov r8, r15
rep movsq qword [rdi], qword [rsi]
mov rdx, r13
mov rcx, r12
mov rbp, r15
call fcn.140007710
mov rdx, rbx
mov rcx, r14
call fcn.14000ef60
test eax, eax
je 0x1400076d0
mov rcx, r14
call qword [sym.imp.msvcrt.dll__findclose]
jmp 0x140007667

Function at 0x140007710
Capabilities:
Delete directory
Delete file

Disassembly:
push rbp
mov eax, 0x1038
push rdi
push rsi
push rbx
call fcn.14000e2a0
sub rsp, rax
lea rsi, [r8 + 0x24]
mov rbp, rcx
mov rdi, rdx
mov rbx, r8
lea rdx, [0x14001c604]
mov rcx, rsi
call sub.msvcrt.dll_wcscmp
test eax, eax
jne 0x140007750
add rsp, 0x1038
pop rbx
pop rsi
pop rdi
pop rbp
ret
lea rdx, [0x14001c608]
mov rcx, rsi
call sub.msvcrt.dll_wcscmp
test eax, eax
je 0x140007741
xor eax, eax
mov rcx, rbp
mov rdx, rsi
mov word [rbp + rdi*2], ax
call sub.msvcrt.dll_wcscat
mov rcx, rbp
test byte [rbx], 0x10
je 0x1400077b0
call fcn.140008720
test eax, eax
jne 0x1400077d8
lea rbx, [rsp + 0x20]
mov r8d, 0x1000
mov rdx, rbp
mov rcx, rbx
call fcn.140008180
mov rcx, rbx
call fcn.1400075d0
jmp 0x140007741
mov rbx, qword [sym.imp.msvcrt.dll__wremove]
call rbx
test eax, eax
je 0x140007741
mov ecx, 0x64
call qword [sym.imp.KERNEL32.dll_Sleep]
mov rcx, rbp
call rbx
jmp 0x140007741
mov rcx, rbp
call qword [sym.imp.msvcrt.dll__wrmdir]
jmp 0x140007741
Function at 0x140007980
Capabilities:
Read file on windows
Write file on windows

Disassembly:
push rdi
mov eax, 0x1020
push rsi
push rbx
call fcn.14000e2a0
sub rsp, rax
mov rdi, r8
mov rsi, rdx
lea rdx, [0x14001c644]
call fcn.1400044f0
mov rdx, rdi
mov rcx, rsi
mov rbx, rax
call fcn.1400077f0
mov rdi, rax
test rbx, rbx
je 0x140007a79
test rax, rax
je 0x140007a6c
lea rsi, [rsp + 0x20]
nop word [rax + rax]
mov rcx, rbx
call sub.msvcrt.dll_feof
test eax, eax
jne 0x140007a68
mov r8d, 0x1000
mov r9, rbx
mov edx, 1
mov rcx, rsi
call sub.msvcrt.dll_fread
mov r8, rax
test rax, rax
jne 0x140007a18
mov rcx, rbx
call sub.msvcrt.dll_ferror
test eax, eax
je 0x1400079d0
mov rcx, rbx
call sub.msvcrt.dll_clearerr
jmp 0x140007a41
mov r9, rdi
mov edx, 1
mov rcx, rsi
call sub.msvcrt.dll_fwrite
test rax, rax
je 0x140007a39
mov rcx, rdi
call sub.msvcrt.dll_ferror
test eax, eax
je 0x1400079d0
mov rcx, rdi
call sub.msvcrt.dll_clearerr
mov esi, 0xffffffff
mov rcx, rbx
call sub.msvcrt.dll_fclose
mov rcx, rdi
call sub.msvcrt.dll_fclose
mov eax, esi
add rsp, 0x1020
pop rbx
pop rsi
pop rdi
ret
xor esi, esi
jmp 0x140007a46
test rbx, rbx
je 0x140007a79
mov rcx, rbx
call sub.msvcrt.dll_fclose
test rdi, rdi
je 0x140007a86
mov rcx, rdi
call sub.msvcrt.dll_fclose
mov esi, 0xffffffff
jmp 0x140007a56