joyce8/EMBER2024-capa huggingface dataset:
Function at 0x14000fcc0
Capabilities:
Encode data using xor
Hash data using fnv

Disassembly:
mov qword [rsp + 0x18], rbx
mov qword [rsp + 0x20], rsi
push r14
mov r11, qword [r8 + 0x10]
mov r10, r8
mov qword [rsp + 0x10], rbp
mov rsi, rdx
mov rbp, qword [r8 + 0x18]
mov r14, rcx
mov r9, r8
cmp rbp, 7
jbe 0x14000fcee
mov r9, qword [r8]
xor ebx, ebx
mov qword [rsp + 0x18], rdi
lea rdx, [r11 + r11]
movabs r8, 0xcbf29ce484222325
mov ecx, ebx
test rdx, rdx
je 0x14000fd34
movabs rdi, 0x100000001b3
nop dword [rax]
nop dword [rax + rax]
movzx eax, byte [r9 + rcx]
inc rcx
xor r8, rax
imul r8, rdi
cmp rcx, rdx
jb 0x14000fd20
mov rcx, qword [r14 + 0x30]
mov rax, qword [r14 + 0x18]
and rcx, r8
add rcx, rcx
mov r9, qword [rax + rcx*8 + 8]
cmp r9, qword [r14 + 8]
je 0x14000fd97
mov rdi, qword [rax + rcx*8]
cmp qword [r9 + 0x28], 7
lea rax, [r9 + 0x10]
mov rcx, qword [rax + 0x10]
jbe 0x14000fd63
mov rax, qword [rax]
mov r8, r10
cmp rbp, 7
jbe 0x14000fd6f
mov r8, qword [r10]
cmp r11, rcx
jne 0x14000fdb9
mov rdx, r11
test r11, r11
je 0x14000fd94
sub r8, rax
nop
movzx ecx, word [r8 + rax]
cmp cx, word [rax]
jne 0x14000fdb9
add rax, 2
sub rdx, 1
jne 0x14000fd80
mov rbx, r9
mov rdi, qword [rsp + 0x18]
mov rbp, qword [rsp + 0x10]
test rbx, rbx
je 0x14000fdc4
mov qword [rsi], rbx
mov rax, rsi
mov rbx, qword [rsp + 0x20]
mov rsi, qword [rsp + 0x28]
pop r14
ret
cmp r9, rdi
je 0x14000fd97
mov r9, qword [r9 + 8]
jmp 0x14000fd51
mov rax, qword [r14 + 8]
mov rbx, qword [rsp + 0x20]
mov qword [rsi], rax
mov rax, rsi
mov rsi, qword [rsp + 0x28]
pop r14
ret
Function at 0x14001a1c0
Capabilities:
Check if file exists

Disassembly:
sub rsp, 0x28
call qword [sym.imp.SHLWAPI.dll_PathFileExistsW]
test eax, eax
setne al
add rsp, 0x28
ret

Function at 0x14001a1e0
Capabilities:
Move file

Disassembly:
sub rsp, 0x28
call qword [sym.imp.KERNEL32.dll_MoveFileW]
test eax, eax
setne al
add rsp, 0x28
ret

Function at 0x14001a200
Capabilities:
Write file on windows

Disassembly:
mov qword [rsp + 8], rbx
mov qword [rsp + 0x10], rsi
push rdi
sub rsp, 0x40
mov rbx, r8
mov qword [rsp + 0x30], 0
mov rsi, rdx
mov dword [rsp + 0x28], pe_nt_image_headers64
xor r8d, r8d
mov dword [rsp + 0x20], 2
mov edx, 0x40000000
xor r9d, r9d
call qword [sym.imp.KERNEL32.dll_CreateFileW]
mov rdi, rax
cmp rax, 0xffffffffffffffff
jne 0x14001a25a
xor al, al
mov rbx, qword [rsp + 0x50]
mov rsi, qword [rsp + 0x58]
add rsp, 0x40
pop rdi
ret
mov eax, 0xffffffff
mov dword [rsp + 0x68], 0
cmp rbx, rax
jbe 0x14001a270
xor bl, bl
jmp 0x14001a292
lea r9, [rsp + 0x68]
mov qword [rsp + 0x20], 0
mov r8d, ebx
mov rdx, rsi
mov rcx, rdi
call qword [sym.imp.KERNEL32.dll_WriteFile]
test eax, eax
setne bl
mov rcx, rdi
call qword [sym.imp.KERNEL32.dll_CloseHandle]
mov rsi, qword [rsp + 0x58]
movzx eax, bl
mov rbx, qword [rsp + 0x50]
add rsp, 0x40
pop rdi
ret
Function at 0x14001acb0
Capabilities:
Get cpu information
Query or enumerate registry value

Disassembly:
push rbx
sub rsp, 0x230
mov rax, qword [0x1400a9100]
xor rax, rsp
mov qword [rsp + 0x220], rax
mov rbx, rcx
mov qword [rsp + 0x40], rcx
mov dword [rsp + 0x34], 1
xorps xmm0, xmm0
movups xmmword [rcx], xmm0
mov qword [rcx + 0x10], 7
mov qword [rcx + 0x18], 0xf
mov rax, qword [str.unknown]
mov dword [rcx], eax
movzx eax, word [0x14009a22c]
mov word [rcx + 4], ax
movzx eax, byte [0x14009a22e]
mov byte [rcx + 6], al
mov byte [rcx + 7], 0
mov dword [rsp + 0x34], 1
lea rax, [rsp + 0x38]
mov qword [rsp + 0x20], rax
mov r9d, 0x20019
xor r8d, r8d
lea rdx, str.HARDWAREDESCRIPTIONSystemCentralProcessor0
mov rcx, 0xffffffff80000002
call qword [sym.imp.ADVAPI32.dll_RegOpenKeyExA]
test eax, eax
jne 0x14001adc3
mov dword [rsp + 0x30], 0x1c8
lea rax, [rsp + 0x30]
mov qword [rsp + 0x28], rax
lea rax, [rsp + 0x50]
mov qword [rsp + 0x20], rax
xor r9d, r9d
xor r8d, r8d
lea rdx, str.ProcessorNameString
mov rcx, qword [rsp + 0x38]
call qword [sym.imp.ADVAPI32.dll_RegQueryValueExA]
test eax, eax
jne 0x14001adb7
mov eax, dword [rsp + 0x30]
test eax, eax
je 0x14001adb7
cmp rax, 0x1c9
jae 0x14001addf
mov byte [rsp + rax + 0x50], 0
lea rax, [rsp + 0x50]
mov r8, 0xffffffffffffffff
nop
inc r8
cmp byte [rax + r8], 0
jne 0x14001ada0
lea rdx, [rsp + 0x50]
mov rcx, rbx
call fcn.140016050
mov rcx, qword [rsp + 0x38]
call qword [sym.imp.ADVAPI32.dll_RegCloseKey]
nop
mov rax, rbx
mov rcx, qword [rsp + 0x220]
xor rcx, rsp
call fcn.140053250
add rsp, 0x230
pop rbx
ret
call fcn.140053c6c
nop
int3

Function at 0x14001af00
Capabilities:
Get hostname

Disassembly:
push rbx
sub rsp, 0x210
mov rax, qword [0x1400a9100]
xor rax, rsp
mov qword [rsp + 0x200], rax
mov rbx, rcx
mov qword [rsp + 0x28], rcx
xor eax, eax
mov dword [rsp + 0x24], eax
xorps xmm0, xmm0
movups xmmword [rcx], xmm0
mov qword [rcx + 0x10], 7
mov qword [rcx + 0x18], 0xf
mov rax, qword [str.unknown]
mov dword [rcx], eax
movzx eax, word [0x14009a22c]
mov word [rcx + 4], ax
movzx eax, byte [0x14009a22e]
mov byte [rcx + 6], al
mov byte [rcx + 7], 0
mov dword [rsp + 0x24], 1
mov dword [rsp + 0x20], 0x1c8
lea rdx, [rsp + 0x20]
lea rcx, [rsp + 0x30]
call qword [sym.imp.KERNEL32.dll_GetComputerNameA]
test eax, eax
je 0x14001afb9
mov eax, dword [rsp + 0x20]
cmp rax, 0x1c9
jae 0x14001afd5
mov byte [rsp + rax + 0x30], 0
lea rax, [rsp + 0x30]
mov r8, 0xffffffffffffffff
inc r8
cmp byte [rax + r8], 0
jne 0x14001afa2
lea rdx, [rsp + 0x30]
mov rcx, rbx
call fcn.140016050
mov rax, rbx
mov rcx, qword [rsp + 0x200]
xor rcx, rsp
call fcn.140053250
add rsp, 0x210
pop rbx
ret
call fcn.140053c6c
int3
Function at 0x14001b370
Capabilities:
Get geographical location

Disassembly:
push rbx
sub rsp, 0x50
mov rax, qword [0x1400a9100]
xor rax, rsp
mov qword [rsp + 0x48], rax
mov rbx, rcx
mov qword [rsp + 0x28], rcx
mov dword [rsp + 0x20], 1
xorps xmm0, xmm0
movups xmmword [rcx], xmm0
mov qword [rcx + 0x10], 7
mov qword [rcx + 0x18], 0xf
mov rax, qword [str.unknown]
mov dword [rcx], eax
movzx eax, word [0x14009a22c]
mov word [rcx + 4], ax
movzx eax, byte [0x14009a22e]
mov byte [rcx + 6], al
mov byte [rcx + 7], 0
mov dword [rsp + 0x20], 1
xor eax, eax
movups xmmword [rsp + 0x30], xmm0
mov dword [rsp + 0x40], eax
mov r9d, 0x14
lea r8, [rsp + 0x30]
mov edx, 0x5c
mov ecx, 0x800
call qword [sym.imp.KERNEL32.dll_GetLocaleInfoA]
test eax, eax
je 0x14001b428
mov byte [rsp + 0x44], 0
lea rax, [rsp + 0x30]
mov r8, 0xffffffffffffffff
inc r8
cmp byte [rax + r8], 0
jne 0x14001b410
lea rdx, [rsp + 0x30]
mov rcx, rbx
call fcn.140016050
nop
mov rax, rbx
mov rcx, qword [rsp + 0x48]
xor rcx, rsp
call fcn.140053250
add rsp, 0x50
pop rbx
ret
Function at 0x14001b440
Capabilities:
Get common file path

Disassembly:
mov qword [rsp + 0x10], rbx
mov qword [rsp + 0x18], rbp
push rsi
push rdi
push r15
sub rsp, 0x570
mov rax, qword [0x1400a9100]
xor rax, rsp
mov qword [rsp + 0x560], rax
mov rbx, rcx
mov qword [rsp + 0x28], rcx
mov dword [rsp + 0x20], 1
xorps xmm0, xmm0
movups xmmword [rcx], xmm0
xor r15d, r15d
mov qword [rcx + 0x10], r15
mov esi, 0xf
mov qword [rcx + 0x18], rsi
mov byte [rcx], r15b
mov dword [rsp + 0x20], 1
mov edx, 0x400
lea rcx, [rsp + 0x150]
call qword [sym.imp.KERNEL32.dll_GetWindowsDirectoryA]
test eax, eax
je 0x14001b64c
mov eax, eax
cmp rax, 0x401
jae 0x14001b67d
mov byte [rsp + rax + 0x150], r15b
lea rax, [rsp + 0x150]
mov r8, 0xffffffffffffffff
nop dword [rax + rax]
inc r8
cmp byte [rax + r8], 0
jne 0x14001b4e0
lea rdx, [rsp + 0x150]
mov rcx, rbx
call fcn.140016050
mov rbp, qword [rbx + 0x10]
mov rdi, rbx
cmp qword [rbx + 0x18], 0xf
jbe 0x14001b50b
mov rdi, qword [rbx]
test rbp, rbp
je 0x14001b566
xor edx, edx
mov r8d, 0x100
lea rcx, [rsp + 0x50]
call fcn.14007ec80
lea rcx, [0x140083930]
lea rdx, [0x140083932]
movzx eax, byte [rcx]
mov byte [rsp + rax + 0x50], 1
inc rcx
cmp rcx, rdx
jne 0x14001b530
lea rdx, [rdi + rbp]
mov rcx, rdi
cmp rdi, rdx
jae 0x14001b566
nop dword [rax]
movzx eax, byte [rcx]
cmp byte [rsp + rax + 0x50], 0
jne 0x14001b609
inc rcx
cmp rcx, rdx
jb 0x14001b550
mov rcx, 0xffffffffffffffff
cmp rcx, 0xffffffffffffffff
je 0x14001b64c
xorps xmm0, xmm0
movups xmmword [rsp + 0x30], xmm0
xorps xmm1, xmm1
movdqu xmmword [rsp + 0x40], xmm1
lea r8, [rcx + 1]
cmp rbp, r8
cmovb r8, rbp
mov rdx, rbx
cmp qword [rbx + 0x18], 0xf
jbe 0x14001b5a0
mov rdx, qword [rbx]
lea rcx, [rsp + 0x30]
call fcn.140004f70
lea rax, [rsp + 0x30]
cmp rbx, rax
je 0x14001b611
mov rdx, qword [rbx + 0x18]
cmp rdx, 0xf
jbe 0x14001b5ee
mov rcx, qword [rbx]
inc rdx
cmp rdx, 0x1000
jb 0x14001b5e9
add rdx, 0x27
mov r8, qword [rcx - 8]
sub rcx, r8
lea rax, [rcx - 8]
cmp rax, 0x1f
ja 0x14001b677
mov rcx, r8
call fcn.1400532ac
mov byte [rbx], 0
movups xmm0, xmmword [rsp + 0x30]
movups xmmword [rbx], xmm0
movups xmm1, xmmword [rsp + 0x40]
movups xmmword [rbx + 0x10], xmm1
mov byte [rsp + 0x30], 0
jmp 0x14001b616
sub rcx, rdi
jmp 0x14001b56d
mov rsi, qword [rsp + 0x48]
cmp rsi, 0xf
jbe 0x14001b64c
lea rdx, [rsi + 1]
mov rcx, qword [rsp + 0x30]
mov rax, rcx
cmp rdx, 0x1000
jb 0x14001b646
add rdx, 0x27
mov rcx, qword [rcx - 8]
sub rax, rcx
add rax, 0xfffffffffffffff8
cmp rax, 0x1f
ja 0x14001b677
call fcn.1400532ac
nop
mov rax, rbx
mov rcx, qword [rsp + 0x560]
xor rcx, rsp
call fcn.140053250
lea r11, [rsp + 0x570]
mov rbx, qword [r11 + 0x28]
mov rbp, qword [r11 + 0x30]
mov rsp, r11
pop r15
pop rdi
pop rsi
ret
call fcn.1400593b4
nop
call fcn.140053c6c
int3
Function at 0x14001b690
Capabilities:
Query or enumerate registry value

Disassembly:
push rbx
sub rsp, 0x400
mov rax, qword [0x1400a9100]
xor rax, rsp
mov qword [rsp + 0x3f0], rax
mov rbx, rcx
mov qword [rsp + 0x40], rcx
xor eax, eax
mov dword [rsp + 0x34], eax
xorps xmm0, xmm0
movups xmmword [rcx], xmm0
mov qword [rcx + 0x10], 7
mov qword [rcx + 0x18], 0xf
mov rax, qword [str.unknown]
mov dword [rcx], eax
movzx eax, word [0x14009a22c]
mov word [rcx + 4], ax
movzx eax, byte [0x14009a22e]
mov byte [rcx + 6], al
mov byte [rcx + 7], 0
mov dword [rsp + 0x34], 2
lea rax, [rsp + 0x38]
mov qword [rsp + 0x20], rax
mov r9d, 0x20019
xor r8d, r8d
lea rdx, str.SOFTWAREMicrosoftWindows_NTCurrentVersion
mov rcx, 0xffffffff80000002
call qword [sym.imp.ADVAPI32.dll_RegOpenKeyExA]
test eax, eax
jne 0x14001b7a3
mov dword [rsp + 0x30], 0x390
lea rax, [rsp + 0x30]
mov qword [rsp + 0x28], rax
lea rax, [rsp + 0x50]
mov qword [rsp + 0x20], rax
xor r9d, r9d
xor r8d, r8d
lea rdx, str.ProductName
mov rcx, qword [rsp + 0x38]
call qword [sym.imp.ADVAPI32.dll_RegQueryValueExA]
test eax, eax
jne 0x14001b797
mov eax, dword [rsp + 0x30]
cmp rax, 0x391
jae 0x14001b7bf
mov byte [rsp + rax + 0x50], 0
lea rax, [rsp + 0x50]
mov r8, 0xffffffffffffffff
nop dword [rax]
inc r8
cmp byte [rax + r8], 0
jne 0x14001b780
lea rdx, [rsp + 0x50]
mov rcx, rbx
call fcn.140016050
mov rcx, qword [rsp + 0x38]
call qword [sym.imp.ADVAPI32.dll_RegCloseKey]
nop
mov rax, rbx
mov rcx, qword [rsp + 0x3f0]
xor rcx, rsp
call fcn.140053250
add rsp, 0x400
pop rbx
ret
call fcn.140053c6c
nop
int3

Function at 0x14001b990
Capabilities:
Get session user name

Disassembly:
push rbx
sub rsp, 0x210
mov rax, qword [0x1400a9100]
xor rax, rsp
mov qword [rsp + 0x200], rax
mov rbx, rcx
mov qword [rsp + 0x28], rcx
xor eax, eax
mov dword [rsp + 0x24], eax
xorps xmm0, xmm0
movups xmmword [rcx], xmm0
mov qword [rcx + 0x10], 7
mov qword [rcx + 0x18], 0xf
mov rax, qword [str.unknown]
mov dword [rcx], eax
movzx eax, word [0x14009a22c]
mov word [rcx + 4], ax
movzx eax, byte [0x14009a22e]
mov byte [rcx + 6], al
mov byte [rcx + 7], 0
mov dword [rsp + 0x24], 1
mov dword [rsp + 0x20], 0x1c8
lea rdx, [rsp + 0x20]
lea rcx, [rsp + 0x30]
call qword [sym.imp.ADVAPI32.dll_GetUserNameA]
test eax, eax
je 0x14001ba49
mov eax, dword [rsp + 0x20]
cmp rax, 0x1c9
jae 0x14001ba65
mov byte [rsp + rax + 0x30], 0
lea rax, [rsp + 0x30]
mov r8, 0xffffffffffffffff
inc r8
cmp byte [rax + r8], 0
jne 0x14001ba32
lea rdx, [rsp + 0x30]
mov rcx, rbx
call fcn.140016050
mov rax, rbx
mov rcx, qword [rsp + 0x200]
xor rcx, rsp
call fcn.140053250
add rsp, 0x210
pop rbx
ret
call fcn.140053c6c
int3

Function at 0x14001d5c0
Capabilities:
Generate random numbers via winapi

Disassembly:
push rbx
sub rsp, 0x20
mov rbx, rcx
cmp r8d, 1
jl 0x14001d5e9
xor ecx, ecx
mov r9d, 2
call sub.bcrypt.dll_BCryptGenRandom
test eax, eax
mov dword [rbx], eax
setns al
add rsp, 0x20
pop rbx
ret
xor al, al
add rsp, 0x20
pop rbx
ret
Function at 0x140021060
Capabilities:
Get disk information

Disassembly:
mov qword [rsp + 0x10], rbx
mov qword [rsp + 0x18], rsi
push rbp
push rdi
push r14
mov rbp, rsp
sub rsp, 0x70
mov rax, qword [0x1400a9100]
xor rax, rsp
mov qword [rbp - 8], rax
mov rbx, rcx
mov qword [rbp - 0x30], rcx
xor r14d, r14d
mov dword [rbp - 0x40], r14d
xorps xmm0, xmm0
movups xmmword [rbp - 0x28], xmm0
mov qword [rbp - 0x18], r14
mov qword [rbp - 0x10], 7
mov word [rbp - 0x28], r14w
mov qword [rcx], r14
mov qword [rcx + 8], r14
mov qword [rcx + 0x10], r14
mov dword [rbp - 0x40], 1
call qword [sym.imp.KERNEL32.dll_GetLogicalDrives]
mov esi, eax
mov edi, 0x41
nop dword [rax + rax]
test sil, 1
je 0x1400211ab
mov qword [rbp - 0x18], 1
lea rax, [rbp - 0x28]
cmp qword [rbp - 0x10], 7
cmova rax, qword [rbp - 0x28]
mov word [rax], di
mov word [rax + 2], r14w
mov rcx, qword [rbp - 0x18]
mov rdx, qword [rbp - 0x10]
mov rax, rdx
sub rax, rcx
cmp rax, 2
jb 0x140021130
lea rax, [rcx + 2]
mov qword [rbp - 0x18], rax
lea rax, [rbp - 0x28]
cmp rdx, 7
cmova rax, qword [rbp - 0x28]
mov dword [rax + rcx*2], 0x5c003a
mov word [rax + rcx*2 + 4], r14w
jmp 0x140021151
mov qword [rsp + 0x20], 2
lea r9, [0x1400840b0]
xor r8d, r8d
mov edx, 2
lea rcx, [rbp - 0x28]
call fcn.140002230
lea rdx, [rbp - 0x28]
cmp qword [rbp - 0x10], 7
cmova rdx, qword [rbp - 0x28]
mov qword [rbp - 0x38], rdx
mov rax, qword [rbx + 8]
cmp rax, qword [rbx + 0x10]
je 0x14002119c
xorps xmm0, xmm0
movups xmmword [rax], xmm0
mov qword [rax + 0x10], r14
mov qword [rax + 0x18], r14
mov r8, 0xffffffffffffffff
inc r8
cmp word [rdx + r8*2], 0
jne 0x140021182
mov rcx, rax
call fcn.140004d30
add qword [rbx + 8], 0x20
jmp 0x1400211ab
lea r8, [rbp - 0x38]
mov rdx, rax
mov rcx, rbx
call fcn.140020e60
inc di
shr esi, 1
cmp di, 0x5a
jbe 0x1400210d0
mov rdx, qword [rbp - 0x10]
cmp rdx, 7
jbe 0x1400211f6
lea rdx, [rdx*2 + 2]
mov rcx, qword [rbp - 0x28]
mov rax, rcx
cmp rdx, 0x1000
jb 0x1400211f1
add rdx, 0x27
mov rcx, qword [rcx - 8]
sub rax, rcx
add rax, 0xfffffffffffffff8
cmp rax, 0x1f
ja 0x14002121a
call fcn.1400532ac
mov rax, rbx
mov rcx, qword [rbp - 8]
xor rcx, rsp
call fcn.140053250
lea r11, [rsp + 0x70]
mov rbx, qword [r11 + 0x28]
mov rsi, qword [r11 + 0x30]
mov rsp, r11
pop r14
pop rdi
pop rbp
ret
call fcn.1400593b4
int3
Function at 0x140021220
Capabilities:
Enumerate disk volumes
Get disk information

Disassembly:
push rbp
push rsi
push r14
lea rbp, [rsp - 0x370]
sub rsp, 0x470
mov rax, qword [0x1400a9100]
xor rax, rsp
mov qword [rbp + 0x350], rax
xor r14d, r14d
lea rcx, [rsp + 0x32]
xor edx, edx
mov word [rsp + 0x30], r14w
mov r8d, 0x206
call fcn.14007ec80
mov edx, 0x104
lea rcx, [rsp + 0x30]
call qword [sym.imp.KERNEL32.dll_FindFirstVolumeW]
mov rsi, rax
cmp rax, 0xffffffffffffffff
je 0x1400213d0
mov qword [rsp + 0x490], rbx
lea rcx, [rbp + 0x140]
mov qword [rsp + 0x498], rdi
xor edx, edx
mov qword [rsp + 0x4a0], r12
mov r8d, 0x208
mov qword [rsp + 0x468], r13
mov qword [rsp + 0x460], r15
call fcn.14007ec80
lea r9, [rsp + 0x20]
mov dword [rsp + 0x20], r14d
mov r8d, 0x104
lea rdx, [rbp + 0x140]
lea rcx, [rsp + 0x30]
call qword [sym.imp.KERNEL32.dll_GetVolumePathNamesForVolumeNameW]
cmp dword [rsp + 0x20], 1
mov r13d, 0x43
jne 0x140021320
movzx ebx, r13w
nop dword [rax]
lea rdx, [rsp + 0x30]
mov word [rsp + 0x28], bx
lea rcx, [rsp + 0x28]
mov dword [rsp + 0x2a], 0x5c003a
mov word [rsp + 0x2e], r14w
call qword [sym.imp.KERNEL32.dll_SetVolumeMountPointW]
test eax, eax
jne 0x140021320
inc bx
cmp bx, 0x5a
jbe 0x1400212f0
mov r8d, 0x104
lea rdx, [rsp + 0x30]
mov rcx, rsi
call qword [sym.imp.KERNEL32.dll_FindNextVolumeW]
lea r9, [rsp + 0x20]
mov r8d, 0x104
lea rdx, [rbp + 0x140]
mov edi, eax
lea rcx, [rsp + 0x30]
call qword [sym.imp.KERNEL32.dll_GetVolumePathNamesForVolumeNameW]
test eax, eax
je 0x1400213a0
cmp dword [rsp + 0x20], 1
jne 0x1400213a0
movzx ebx, r13w
nop dword [rax]
nop word [rax + rax]
lea rdx, [rsp + 0x30]
mov word [rsp + 0x28], bx
lea rcx, [rsp + 0x28]
mov dword [rsp + 0x2a], 0x5c003a
mov word [rsp + 0x2e], r14w
call qword [sym.imp.KERNEL32.dll_SetVolumeMountPointW]
test eax, eax
jne 0x1400213a0
inc bx
cmp bx, 0x5a
jbe 0x140021370
test edi, edi
jne 0x140021320
mov r15, qword [rsp + 0x460]
mov r13, qword [rsp + 0x468]
mov r12, qword [rsp + 0x4a0]
mov rdi, qword [rsp + 0x498]
mov rbx, qword [rsp + 0x490]
mov rcx, qword [rbp + 0x350]
xor rcx, rsp
call fcn.140053250
add rsp, 0x470
pop r14
pop rsi
pop rbp
ret
Function at 0x1400218b0
Capabilities:
Get file size
Set file attributes

Disassembly:
mov qword [rsp + 0x10], rbx
mov qword [rsp + 0x18], rbp
mov qword [rsp + 0x20], rsi
mov qword [rsp + 8], rcx
push rdi
sub rsp, 0x60
mov rdi, rcx
call fcn.140022d20
nop
lea rax, vtable.FileWrapperWin.0
mov qword [rdi], rax
mov qword [rdi + 0x38], 0xffffffffffffffff
xor eax, eax
mov qword [rdi + 0x40], rax
xor ebp, ebp
mov esi, ebp
nop
lea rcx, [rdi + 8]
cmp qword [rdi + 0x20], 7
jbe 0x1400218ff
mov rcx, qword [rdi + 8]
mov qword [rsp + 0x30], rbp
mov dword [rsp + 0x28], 0x8000080
mov dword [rsp + 0x20], 3
xor r9d, r9d
xor r8d, r8d
mov edx, 0xc0000000
call qword [sym.imp.KERNEL32.dll_CreateFileW]
mov qword [rdi + 0x38], rax
cmp rax, 0xffffffffffffffff
jne 0x1400219ce
call qword [sym.imp.KERNEL32.dll_GetLastError]
sub eax, 5
je 0x140021983
sub eax, 0x1b
je 0x140021948
cmp eax, 1
jne 0x1400219c5
mov dword [rdi + 0x28], 3
lea rcx, [rdi + 8]
cmp qword [rdi + 0x20], 7
jbe 0x14002195e
mov rcx, qword [rdi + 8]
mov rax, qword [rdi + 0x18]
mov qword [rsp + 0x40], rcx
mov qword [rsp + 0x48], rax
movaps xmm0, xmmword [rsp + 0x40]
movdqa xmmword [rsp + 0x50], xmm0
lea rcx, [rsp + 0x50]
call fcn.14001eae0
jmp 0x1400219b8
lea rcx, [rdi + 8]
cmp qword [rdi + 0x20], 7
jbe 0x140021992
mov rcx, qword [rdi + 8]
mov edx, pe_nt_image_headers64
call qword [sym.imp.KERNEL32.dll_SetFileAttributesW]
lea rcx, [rdi + 8]
cmp qword [rdi + 0x20], 7
jbe 0x1400219ac
mov rcx, qword [rdi + 8]
call fcn.140022fb0
mov dword [rdi + 0x28], 2
inc esi
cmp esi, 2
jl 0x1400218f0
jmp 0x1400219d1
mov dword [rdi + 0x28], 1
jmp 0x1400219d1
mov dword [rdi + 0x28], ebp
cmp dword [rdi + 0x28], ebp
jne 0x1400219ec
lea rdx, [rdi + 0x40]
mov rcx, qword [rdi + 0x38]
call qword [sym.imp.KERNEL32.dll_GetFileSizeEx]
mov rax, qword [rdi + 0x40]
mov qword [rdi + 0x30], rax
mov rax, rdi
lea r11, [rsp + 0x60]
mov rbx, qword [r11 + 0x18]
mov rbp, qword [r11 + 0x20]
mov rsi, qword [r11 + 0x28]
mov rsp, r11
pop rdi
ret

Function at 0x140021a90
Capabilities:
Get file size

Disassembly:
push rbx
sub rsp, 0x20
mov rcx, qword [rcx + 0x38]
lea rdx, [rsp + 0x30]
xor ebx, ebx
mov qword [rsp + 0x30], rbx
call qword [sym.imp.KERNEL32.dll_GetFileSizeEx]
mov rcx, qword [rsp + 0x30]
test eax, eax
cmove rcx, rbx
mov rax, rcx
add rsp, 0x20
pop rbx
ret
Function at 0x140021b10
Capabilities:
Read file on windows

Disassembly:
mov qword [rsp + 0x10], rbx
mov qword [rsp + 0x18], rbp
push rsi
push rdi
push r14
sub rsp, 0x50
mov rbp, r8
mov rbx, rdx
mov r14, rcx
xor esi, esi
cmp qword [rcx + 0x38], 0xffffffffffffffff
je 0x140021bf6
lea rax, [r8 - 1]
mov ecx, 0xfffffffd
cmp rax, rcx
ja 0x140021bf6
xorps xmm0, xmm0
movdqu xmmword [rsp + 0x38], xmm0
mov edi, esi
mov qword [rsp + 0x48], rsi
test r8, r8
je 0x140021b76
lea r8, [rsp + 0x70]
mov rdx, rbp
lea rcx, [rsp + 0x38]
call fcn.140016ba0
mov rdi, qword [rsp + 0x48]
mov dword [rsp + 0x70], esi
mov qword [rsp + 0x20], rsi
lea r9, [rsp + 0x70]
mov r8d, ebp
mov rsi, qword [rsp + 0x38]
mov rdx, rsi
mov rcx, qword [r14 + 0x38]
call qword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
je 0x140021bbc
mov eax, dword [rsp + 0x70]
cmp rax, rbp
jl 0x140021bbc
mov qword [rbx], rsi
mov rax, qword [rsp + 0x40]
mov qword [rbx + 8], rax
mov qword [rbx + 0x10], rdi
mov byte [rbx + 0x18], 1
jmp 0x140021bfa
mov byte [rbx + 0x18], 0
test rsi, rsi
je 0x140021bfa
sub rdi, rsi
mov rax, rsi
cmp rdi, 0x1000
jb 0x140021be9
add rdi, 0x27
mov rsi, qword [rsi - 8]
sub rax, rsi
add rax, 0xfffffffffffffff8
cmp rax, 0x1f
ja 0x140021c13
mov rdx, rdi
mov rcx, rsi
call fcn.1400532ac
jmp 0x140021bfa
mov byte [rdx + 0x18], sil
mov rax, rbx
mov rbx, qword [rsp + 0x78]
mov rbp, qword [rsp + 0x80]
add rsp, 0x50
pop r14
pop rdi
pop rsi
ret
call fcn.1400593b4
int3

Function at 0x140021c20
Capabilities:
Read file on windows

Disassembly:
push rbx
sub rsp, 0x30
mov rcx, qword [rcx + 0x38]
mov rbx, r9
cmp rcx, 0xffffffffffffffff
je 0x140021c60
test r8, r8
jle 0x140021c60
xor eax, eax
lea r9, [rsp + 0x40]
mov dword [rsp + 0x40], eax
mov qword [rsp + 0x20], rax
call qword [sym.imp.KERNEL32.dll_ReadFile]
mov ecx, dword [rsp + 0x40]
test eax, eax
mov qword [rbx], rcx
setne al
add rsp, 0x30
pop rbx
ret
xor al, al
add rsp, 0x30
pop rbx
ret

Function at 0x140021c70
Capabilities:
Clear file content

Disassembly:
mov qword [rsp + 8], rbx
push rdi
sub rsp, 0x20
mov rdi, rdx
mov rbx, rcx
test rdx, rdx
js 0x140021ce0
mov rcx, qword [rcx + 0x38]
lea r8, [rsp + 0x38]
mov r9d, 1
mov qword [rsp + 0x38], 0
xor edx, edx
call qword [sym.imp.KERNEL32.dll_SetFilePointerEx]
test eax, eax
je 0x140021ce0
mov rcx, qword [rbx + 0x38]
cmp rcx, 0xffffffffffffffff
je 0x140021ce0
xor r9d, r9d
xor r8d, r8d
mov rdx, rdi
call qword [sym.imp.KERNEL32.dll_SetFilePointerEx]
test eax, eax
jne 0x140021ced
call qword [sym.imp.KERNEL32.dll_GetLastError]
lea rdx, str.Cant_set_file_position...__d_n
mov ecx, 1
mov r8d, eax
call fcn.14001cdd0
xor al, al
mov rbx, qword [rsp + 0x30]
add rsp, 0x20
pop rdi
ret
mov rcx, qword [rbx + 0x38]
call qword [sym.imp.KERNEL32.dll_SetEndOfFile]
test eax, eax
je 0x140021ce0
mov rcx, qword [rbx + 0x38]
cmp rcx, 0xffffffffffffffff
je 0x140021d34
mov rdx, qword [rsp + 0x38]
xor r9d, r9d
xor r8d, r8d
call qword [sym.imp.KERNEL32.dll_SetFilePointerEx]
test eax, eax
jne 0x140021d34
call qword [sym.imp.KERNEL32.dll_GetLastError]
lea rdx, str.Cant_set_file_position...__d_n
mov ecx, 1
mov r8d, eax
call fcn.14001cdd0
mov rbx, qword [rsp + 0x30]
mov al, 1
add rsp, 0x20
pop rdi
ret
Function at 0x140021db0
Capabilities:
Write file on windows

Disassembly:
push rbx
sub rsp, 0x30
mov rax, qword [rdx]
mov rbx, r8
mov r8, qword [rdx + 8]
movabs rdx, 0x7fffffffffffffff
sub r8, rax
cmp r8, rdx
ja 0x140021e0c
mov rcx, qword [rcx + 0x38]
cmp rcx, 0xffffffffffffffff
je 0x140021e0c
test r8, r8
je 0x140021e0c
xor edx, edx
lea r9, [rsp + 0x48]
mov dword [rsp + 0x48], edx
mov qword [rsp + 0x20], rdx
mov rdx, rax
call qword [sym.imp.KERNEL32.dll_WriteFile]
mov ecx, dword [rsp + 0x48]
test eax, eax
mov qword [rbx], rcx
setne al
add rsp, 0x30
pop rbx
ret
xor al, al
add rsp, 0x30
pop rbx
ret

Function at 0x140021e20
Capabilities:
Write file on windows

Disassembly:
push rbx
sub rsp, 0x30
mov rcx, qword [rcx + 0x38]
mov rbx, r9
cmp rcx, 0xffffffffffffffff
je 0x140021e60
test r8, r8
je 0x140021e60
xor eax, eax
lea r9, [rsp + 0x40]
mov dword [rsp + 0x40], eax
mov qword [rsp + 0x20], rax
call qword [sym.imp.KERNEL32.dll_WriteFile]
mov ecx, dword [rsp + 0x40]
test eax, eax
mov qword [rbx], rcx
setne al
add rsp, 0x30
pop rbx
ret
xor al, al
add rsp, 0x30
pop rbx
ret

Function at 0x140021eb0
Capabilities:
Terminate process

Disassembly:
mov qword [rsp + 8], rbx
push rdi
sub rsp, 0x20
mov r8d, ecx
xor edx, edx
mov ecx, 1
call qword [sym.imp.KERNEL32.dll_OpenProcess]
mov rbx, rax
xor eax, eax
cmp rbx, 0xffffffffffffffff
cmove rbx, rax
lea rax, [rbx - 1]
cmp rax, 0xfffffffffffffffd
ja 0x140021ef4
xor edx, edx
mov rcx, rbx
call qword [sym.imp.KERNEL32.dll_TerminateProcess]
test eax, eax
setne dil
jmp 0x140021efc
xor dil, dil
test rbx, rbx
je 0x140021f05
mov rcx, rbx
call qword [sym.imp.KERNEL32.dll_CloseHandle]
mov rbx, qword [rsp + 0x30]
movzx eax, dil
add rsp, 0x20
pop rdi
ret