joyce8/EMBER2024-capa huggingface dataset:
Function at 0x1dad9c0a0
Capabilities:
Write file on windows

Disassembly:
sub rsp, 0x28
xor r9d, r9d
xor r8d, r8d
mov edx, 1
xor ecx, ecx
call qword [sym.imp.KERNEL32.dll_CreateEventA]
mov qword [0x1db0bf288], rax
test rax, rax
je 0x1dad9c0d5
lea rcx, [0x1db0bf2a0]
add rsp, 0x28
jmp qword [sym.imp.KERNEL32.dll_InitializeCriticalSection]
mov ecx, 2
call qword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll___acrt_iob_func]
mov r8d, 0x3d
mov edx, 1
lea rcx, str.runtime:_failed_to_create_runtime_initialization_wait_event._n
mov r9, rax
call sub.api_ms_win_crt_stdio_l1_1_0.dll_fwrite
call sub.api_ms_win_crt_runtime_l1_1_0.dll_abort
nop

Function at 0x1dad9c700
Capabilities:
Write file on windows

Disassembly:
push rbp
push rbx
sub rsp, 0x38
lea rbp, [rsp + 0x30]
mov qword [rbp + 0x20], rcx
mov qword [rbp + 0x28], rdx
mov qword [rbp + 0x30], r8
mov qword [rbp + 0x38], r9
lea rax, [rbp + 0x28]
mov qword [rbp - 8], rax
mov ecx, 2
call sub.api_ms_win_crt_stdio_l1_1_0.dll___acrt_iob_func
mov r9, rax
mov r8d, 0x1b
mov edx, 1
lea rax, str.Mingw_w64_runtime_failure:_n
mov rcx, rax
call sub.api_ms_win_crt_stdio_l1_1_0.dll_fwrite
mov rbx, qword [rbp - 8]
mov ecx, 2
call sub.api_ms_win_crt_stdio_l1_1_0.dll___acrt_iob_func
mov rcx, rax
mov rax, qword [rbp + 0x20]
mov r8, rbx
mov rdx, rax
call fcn.1dad9d970
call sub.api_ms_win_crt_runtime_l1_1_0.dll_abort
nop

Function at 0x1dad9d102
Capabilities:
Get thread local storage value

Disassembly:
push rbp
mov rbp, rsp
sub rsp, 0x30
mov eax, dword [0x1db0bf368]
test eax, eax
je 0x1dad9d19a
lea rax, [0x1db0bf340]
mov rcx, rax
mov rax, qword [sym.imp.KERNEL32.dll_EnterCriticalSection]
call rax
mov rax, qword [0x1db0bf370]
mov qword [rbp - 8], rax
jmp 0x1dad9d17e
mov rax, qword [rbp - 8]
mov eax, dword [rax]
mov ecx, eax
mov rax, qword [sym.imp.KERNEL32.dll_TlsGetValue]
call rax
mov qword [rbp - 0x10], rax
mov rax, qword [sym.imp.KERNEL32.dll_GetLastError]
call rax
test eax, eax
jne 0x1dad9d172
cmp qword [rbp - 0x10], 0
je 0x1dad9d172
mov rax, qword [rbp - 8]
mov rdx, qword [rax + 8]
mov rax, qword [rbp - 0x10]
mov rcx, rax
call rdx
mov rax, qword [rbp - 8]
mov rax, qword [rax + 0x10]
mov qword [rbp - 8], rax
cmp qword [rbp - 8], 0
jne 0x1dad9d138
lea rax, [0x1db0bf340]
mov rcx, rax
mov rax, qword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
call rax
jmp 0x1dad9d19b
nop
add rsp, 0x30
pop rbp
ret

Function at 0x1dad9d2a0
Capabilities:
Parse pe header

Disassembly:
push rbp
mov rbp, rsp
sub rsp, 0x20
mov qword [rbp + 0x10], rcx
mov rax, qword [rbp + 0x10]
mov qword [rbp - 8], rax
mov rax, qword [rbp - 8]
movzx eax, word [rax]
cmp ax, 0x5a4d
je 0x1dad9d2c8
mov eax, 0
jmp 0x1dad9d316
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 0x1dad9d2f1
mov eax, 0
jmp 0x1dad9d316
mov rax, qword [rbp - 0x10]
add rax, 0x18
mov qword [rbp - 0x18], rax
mov rax, qword [rbp - 0x18]
movzx eax, word [rax]
cmp ax, 0x20b
je 0x1dad9d311
mov eax, 0
jmp 0x1dad9d316
mov eax, 1
add rsp, 0x20
pop rbp
ret
Function at 0x1dad9d31c
Capabilities:
Enumerate pe sections

Disassembly:
push rbp
mov rbp, rsp
sub rsp, 0x20
mov qword [rbp + 0x10], rcx
mov qword [rbp + 0x18], rdx
mov rax, qword [rbp + 0x10]
mov eax, dword [rax + 0x3c]
movsxd rdx, eax
mov rax, qword [rbp + 0x10]
add rax, rdx
mov qword [rbp - 0x18], rax
mov dword [rbp - 0xc], 0
mov rax, qword [rbp - 0x18]
movzx eax, word [rax + 0x14]
movzx edx, ax
mov rax, qword [rbp - 0x18]
add rax, rdx
add rax, 0x18
mov qword [rbp - 8], rax
jmp 0x1dad9d39a
mov rax, qword [rbp - 8]
mov eax, dword [rax + 0xc]
mov eax, eax
cmp qword [rbp + 0x18], rax
jb 0x1dad9d391
mov rax, qword [rbp - 8]
mov edx, dword [rax + 0xc]
mov rax, qword [rbp - 8]
mov eax, dword [rax + 8]
add eax, edx
mov eax, eax
cmp qword [rbp + 0x18], rax
jae 0x1dad9d391
mov rax, qword [rbp - 8]
jmp 0x1dad9d3af
add dword [rbp - 0xc], 1
add qword [rbp - 8], 0x28
mov rax, qword [rbp - 0x18]
movzx eax, word [rax + 6]
movzx eax, ax
cmp dword [rbp - 0xc], eax
jb 0x1dad9d364
mov eax, 0
add rsp, 0x20
pop rbp
ret
Function at 0x14001e298
Capabilities:
Get thread local storage value

Disassembly:
sub rsp, 0x48
mov qword [rsp + 0x28], rax
mov qword [rsp + 0x30], rcx
call sub.KERNEL32.dll_GetLastError
mov qword [rsp + 0x38], rax
mov rcx, qword [0x140075ba0]
call sub.KERNEL32.dll_TlsGetValue
mov rcx, qword [rsp + 0x30]
mov qword [rax + 0x10], rcx
mov rcx, qword [rsp + 0x38]
call sub.KERNEL32.dll_SetLastError
mov rax, qword [rsp + 0x28]
add rsp, 0x48
ret

Function at 0x14001f53c
Capabilities:
Create thread

Disassembly:
mov r11, rsp
mov qword [r11 + 8], rbx
mov qword [r11 + 0x10], rbp
mov qword [r11 + 0x20], rsi
push rdi
sub rsp, 0x30
lea rax, [r11 + 0x18]
mov r9, rdx
mov r8, rcx
mov qword [r11 - 0x10], rax
xor edi, edi
mov edx, 0x1000
xor ecx, ecx
mov dword [rsp + 0x20], edi
call qword [sym.imp.KERNEL32.dll_CreateThread]
mov rbp, rax
test rax, rax
je 0x14001f602
lea rcx, [0x140077260]
call qword [sym.imp.KERNEL32.dll_EnterCriticalSection]
mov rbx, qword [0x140077130]
jmp 0x14001f5c6
lea rsi, [rbx + 0x10]
xor edx, edx
mov rcx, qword [rsi]
call qword [sym.imp.KERNEL32.dll_WaitForSingleObject]
test eax, eax
jne 0x14001f5c3
mov rcx, qword [rsi]
call qword [sym.imp.KERNEL32.dll_CloseHandle]
mov rbx, qword [rbx]
lea rcx, [0x140077130]
mov rdx, rsi
call fcn.140026b38
jmp 0x14001f5c6
mov rbx, qword [rbx]
test rbx, rbx
jne 0x14001f593
mov rdx, qword [0x140075b78]
lea rcx, [0x140077130]
mov rdi, rdx
inc rdx
mov qword [0x140075b78], rdx
lea edx, [rbx + 0x20]
call fcn.140026b80
lea rcx, [0x140077260]
mov qword [rax], rbp
mov qword [rax + 8], rdi
call qword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
mov rbx, qword [rsp + 0x40]
mov rbp, qword [rsp + 0x48]
mov rsi, qword [rsp + 0x58]
mov rax, rdi
add rsp, 0x30
pop rdi
ret

Function at 0x14001f8b0
Capabilities:
Get thread local storage value

Disassembly:
mov qword [rsp + 8], rbx
mov qword [rsp + 0x10], rsi
push rdi
sub rsp, 0x20
mov rbx, rcx
mov esi, 0x40
mov ecx, esi
call fcn.1400274c0
mov rdx, rbx
mov rcx, rax
mov rdi, rax
call fcn.14001f820
or rcx, 0xffffffffffffffff
xor eax, eax
repne scasb al, byte [rdi]
not rcx
dec rcx
sub esi, ecx
mov ecx, esi
mov rbx, qword [rsp + 0x30]
mov rsi, qword [rsp + 0x38]
add rsp, 0x20
pop rdi
jmp fcn.140027590

Function at 0x14001faa0
Capabilities:
Get thread local storage value

Disassembly:
mov qword [rsp + 8], rbx
push rdi
sub rsp, 0x40
mov rdi, rcx
mov ebx, 0x40
mov ecx, ebx
call fcn.1400274c0
lea r8, [rsp + 0x20]
movabs r10, 0xcccccccccccccccd
mov r11, rax
mov r9, rax
nop
mov rax, r10
inc r8
mul rdi
shr rdx, 3
movzx ecx, dl
shl cl, 2
lea eax, [rcx + rdx]
add al, al
sub dil, al
add dil, 0x30
mov byte [r8 - 1], dil
mov rdi, rdx
test rdx, rdx
jne 0x14001fad0
nop dword [rax + rax]
movzx eax, byte [r8 - 1]
dec r8
inc r11
mov byte [r11 - 1], al
lea rax, [rsp + 0x20]
cmp r8, rax
jne 0x14001fb00
or rcx, 0xffffffffffffffff
xor eax, eax
mov rdi, r9
mov byte [r11], 0
repne scasb al, byte [rdi]
not rcx
dec rcx
sub ebx, ecx
mov ecx, ebx
mov rbx, qword [rsp + 0x50]
add rsp, 0x40
pop rdi
jmp fcn.140027590
Function at 0x1400200b0
Capabilities:
Get thread local storage value

Disassembly:
push r12
push r13
push r15
sub rsp, 0x30
xor r12d, r12d
mov r15d, r9d
mov r13d, edx
cmp edx, 1
jl 0x1400201f3
mov qword [rsp + 0x50], rbx
mov qword [rsp + 0x58], rbp
test rcx, rcx
mov qword [rsp + 0x60], rsi
mov qword [rsp + 0x28], rdi
mov qword [rsp + 0x20], r14
lea r14, [0x14002ac0a]
mov esi, r12d
mov rbx, r14
cmovne rbx, rcx
test r8, r8
cmovne r14, r8
mov rbp, rbx
movzx ecx, byte [r14]
test cl, cl
je 0x140020160
cmp byte [r14 + 1], sil
je 0x140020160
or rcx, 0xffffffffffffffff
xor eax, eax
mov rdi, r14
repne scasb al, byte [rdi]
not rcx
dec rcx
movsxd rdi, ecx
nop word [rax + rax]
mov r8, rdi
mov rdx, r14
mov rcx, rbx
call sub.msvcrt.dll_strncmp
test eax, eax
je 0x14002014c
cmp byte [rbx], r12b
je 0x14002014c
inc rbx
jmp 0x140020130
inc esi
cmp esi, r13d
je 0x14002017e
cmp byte [rbx], r12b
je 0x140020184
add rbx, rdi
mov rbp, rbx
jmp 0x140020130
movzx eax, byte [rbx]
cmp al, cl
je 0x14002016b
test al, al
jne 0x140020179
inc esi
cmp esi, edx
je 0x14002017e
test al, al
je 0x140020184
lea rbp, [rbx + 1]
inc rbx
jmp 0x140020160
mov r12d, ebx
sub r12d, ebp
mov rcx, rbx
call fcn.1400275d0
mov r14, qword [rsp + 0x20]
mov rsi, qword [rsp + 0x60]
mov ebx, eax
test eax, eax
je 0x1400201b2
mov ecx, r15d
call fcn.140027670
movsxd r8, r12d
mov rdx, rbp
mov rcx, rax
call sub.msvcrt.dll_memmove
mov edx, r15d
mov ecx, r12d
call fcn.1400274c0
test ebx, ebx
mov rbx, qword [rsp + 0x50]
mov rdi, rax
jne 0x1400201d7
movsxd r8, r12d
mov rdx, rbp
mov rcx, rax
call sub.msvcrt.dll_strncpy
mov rbp, qword [rsp + 0x58]
movsxd rcx, r12d
mov byte [rcx + rdi], 0
mov rdi, qword [rsp + 0x28]
add rsp, 0x30
pop r15
pop r13
pop r12
ret
mov ecx, r9d
add rsp, 0x30
pop r15
pop r13
pop r12
jmp fcn.1400276a0

Function at 0x140021208
Capabilities:
Set environment variable

Disassembly:
sub rsp, 0x28
mov rax, rdx
test rcx, rcx
je 0x140021228
test rax, rax
lea rdx, [0x14002ac0a]
cmovne rdx, rax
call qword [sym.imp.KERNEL32.dll_SetEnvironmentVariableA]
add rsp, 0x28
ret
Function at 0x140021248
Capabilities:
Accept command line arguments

Disassembly:
mov qword [rsp + 0x10], rbx
mov qword [rsp + 0x18], rbp
mov qword [rsp + 0x20], rsi
push rdi
sub rsp, 0x20
mov rdi, rcx
mov rcx, qword [0x1400772b0]
call fcn.14002619c
xor ebx, ebx
or esi, 0xffffffff
mov rbp, rax
call qword [sym.imp.KERNEL32.dll_GetCommandLineA]
mov dl, byte [rax]
test dl, dl
je 0x14002130e
mov rcx, qword [rsp + 0x30]
mov r10b, 0x20
lea r9d, [rbx + 1]
cmp dl, r10b
jne 0x14002129c
add rax, r9
cmp byte [rax], r10b
je 0x140021294
mov dl, byte [rax]
mov r8d, r9d
cmp dl, 0x22
jne 0x1400212d2
add rax, r9
mov rbx, rax
mov cl, byte [rax]
test cl, cl
je 0x1400212cd
cmp cl, 0x22
je 0x1400212c0
add rax, r9
mov cl, byte [rax]
test cl, cl
jne 0x1400212b2
cmp byte [rax], 0
je 0x1400212cd
mov rcx, rax
add rax, r9
jmp 0x1400212f4
mov rcx, rax
jmp 0x1400212f4
test dl, dl
je 0x1400212f1
mov rbx, rax
cmp dl, r10b
je 0x1400212e7
add rax, r9
mov dl, byte [rax]
test dl, dl
jne 0x1400212d9
cmp byte [rax], 0
mov rcx, rax
je 0x1400212f4
jmp 0x1400212c8
xor r8d, r8d
cmp dword [rbp], esi
jne 0x1400212fe
test rdi, rdi
jne 0x140021318
test r8d, r8d
je 0x140021306
add esi, r9d
mov dl, byte [rax]
xor ebx, ebx
test dl, dl
jne 0x14002128f
test rdi, rdi
jne 0x14002132a
movsxd rax, esi
jmp 0x14002132d
test rbx, rbx
je 0x14002132a
sub ecx, ebx
mov rax, rbx
mov dword [rdi], ecx
add dword [rbp], r9d
jmp 0x14002132d
and dword [rdi], 0
mov rbx, qword [rsp + 0x38]
mov rbp, qword [rsp + 0x40]
mov rsi, qword [rsp + 0x48]
add rsp, 0x20
pop rdi
ret

Function at 0x140021408
Capabilities:
Accept command line arguments

Disassembly:
sub rsp, 0x28
mov rcx, qword [0x1400772b0]
call fcn.14002619c
xor ecx, ecx
add rsp, 0x28
jmp fcn.140021248

Function at 0x140021bc0
Capabilities:
Allocate thread local storage
Get thread local storage value
Set thread local storage value

Disassembly:
push rbx
sub rsp, 0x20
cmp dword [0x14007714c], 0
jne 0x140021be5
call qword [sym.imp.KERNEL32.dll_TlsAlloc]
mov dword [0x14007714c], 1
mov dword [0x140077148], eax
mov rcx, qword [0x140076bc8]
xor edx, edx
mov r8d, 0x90
call qword [sym.imp.KERNEL32.dll_HeapAlloc]
mov ecx, dword [0x140077148]
mov rdx, rax
call qword [sym.imp.KERNEL32.dll_TlsSetValue]
call qword [sym.imp.KERNEL32.dll_GetCurrentThreadId]
mov ebx, eax
call qword [sym.imp.KERNEL32.dll_GetTickCount]
xor ebx, eax
mov ecx, ebx
add rsp, 0x20
pop rbx
jmp fcn.140021e70
Function at 0x140021c30
Capabilities:
Get thread local storage value

Disassembly:
push rbx
sub rsp, 0x20
cmp dword [0x14007714c], 0
mov rbx, rcx
jne 0x140021c47
call fcn.140021bc0
mov ecx, dword [0x140077148]
call qword [sym.imp.KERNEL32.dll_TlsGetValue]
mov r11, rax
test rax, rax
jne 0x140021c6f
call fcn.140021bc0
mov ecx, dword [0x140077148]
call qword [sym.imp.KERNEL32.dll_TlsGetValue]
mov r11, rax
movsxd r8, dword [r11]
movsxd rdx, dword [r11 + 4]
mov eax, 0x10
mov r9d, dword [r11 + r8*4 + 0x4c]
mov r10d, dword [r11 + r8*4 + 8]
ror r9d, 0xd
add r9d, dword [r11 + rdx*4 + 0x4c]
ror r10d, 5
add r10d, dword [r11 + rdx*4 + 8]
mov dword [r11 + r8*4 + 8], r9d
mov dword [r11 + r8*4 + 0x4c], r10d
dec r8d
mov ecx, r10d
cmovs r8d, eax
dec edx
cmovs edx, eax
inc rbx
mov dword [r11], r8d
mov dword [r11 + 4], edx
je 0x140021ce8
mov edx, r9d
mov r8, rbx
mov eax, ebx
shr r8, 0x20
imul rax, rdx
shr rax, 0x20
imul rcx, r8
imul rdx, r8
shr rcx, 0x20
add rax, rcx
add rax, rdx
add rsp, 0x20
pop rbx
ret
mov eax, r9d
shl rax, 0x20
and rax, rcx
add rsp, 0x20
pop rbx
ret

Function at 0x140021d30
Capabilities:
Get thread local storage value

Disassembly:
mov qword [rsp + 0x18], rbx
mov qword [rsp + 0x20], rbp
push rsi
sub rsp, 0x20
cmp dword [0x14007714c], 0
mov rbx, rdx
mov rsi, rcx
jne 0x140021d53
call fcn.140021bc0
mov ecx, dword [0x140077148]
call qword [sym.imp.KERNEL32.dll_TlsGetValue]
mov r11, rax
test rax, rax
jne 0x140021d7b
call fcn.140021bc0
mov ecx, dword [0x140077148]
call qword [sym.imp.KERNEL32.dll_TlsGetValue]
mov r11, rax
mov ebp, 0x10
cmp rbx, 8
jl 0x140021df6
mov qword [rsp + 0x30], rdi
mov rdi, rbx
shr rdi, 3
mov rax, rdi
neg rax
lea rbx, [rbx + rax*8]
nop dword [rax]
movsxd r9, dword [r11]
movsxd r10, dword [r11 + 4]
mov r8d, dword [r11 + r9*4 + 0x4c]
mov edx, dword [r11 + r9*4 + 8]
ror r8d, 0xd
add r8d, dword [r11 + r10*4 + 0x4c]
ror edx, 5
add edx, dword [r11 + r10*4 + 8]
mov dword [r11 + r9*4 + 8], r8d
mov dword [r11 + r9*4 + 0x4c], edx
dec r9d
cmovs r9d, ebp
dec r10d
cmovs r10d, ebp
mov dword [r11], r9d
add rsi, 8
dec rdi
mov dword [r11 + 4], r10d
mov dword [rsi - 8], edx
mov dword [rsi - 4], r8d
jne 0x140021da0
mov rdi, qword [rsp + 0x30]
test rbx, rbx
jle 0x140021e55
movsxd r10, dword [r11]
movsxd r9, dword [r11 + 4]
mov rcx, rsi
mov r8d, dword [r11 + r10*4 + 0x4c]
mov edx, dword [r11 + r10*4 + 8]
ror r8d, 0xd
add r8d, dword [r11 + r9*4 + 0x4c]
ror edx, 5
add edx, dword [r11 + r9*4 + 8]
mov dword [r11 + r10*4 + 8], r8d
mov dword [rsp + 0x3c], r8d
mov dword [r11 + r10*4 + 0x4c], edx
dec r10d
mov dword [rsp + 0x38], edx
cmovs r10d, ebp
dec r9d
lea rdx, [rsp + 0x38]
cmovs r9d, ebp
mov r8, rbx
mov dword [r11], r10d
mov dword [r11 + 4], r9d
call sub.msvcrt.dll_memcpy
mov rbx, qword [rsp + 0x40]
mov rbp, qword [rsp + 0x48]
add rsp, 0x20
pop rsi
ret
Function at 0x140021e70
Capabilities:
Get thread local storage value

Disassembly:
mov qword [rsp + 8], rbx
mov qword [rsp + 0x10], rsi
push rdi
sub rsp, 0x20
cmp dword [0x14007714c], 0
mov ebx, ecx
jne 0x140021e8f
call fcn.140021bc0
mov ecx, dword [0x140077148]
call qword [sym.imp.KERNEL32.dll_TlsGetValue]
mov rdi, rax
test rax, rax
jne 0x140021eb7
call fcn.140021bc0
mov ecx, dword [0x140077148]
call qword [sym.imp.KERNEL32.dll_TlsGetValue]
mov rdi, rax
lea rcx, [rdi + 8]
mov edx, 0x11
imul ebx, ebx, 0x53a9b4fb
mov eax, 1
add rcx, 4
sub eax, ebx
mov ebx, 1
mov dword [rcx + 0x40], eax
imul eax, eax, 0x53a9b4fb
sub ebx, eax
dec rdx
mov dword [rcx - 4], ebx
jne 0x140021ec0
mov dword [rdi], edx
mov dword [rdi + 4], 0xa
lea ebx, [rdx + 0x1f]
lea esi, [rdx + 0x10]
nop dword [rax + rax]
movsxd r10, dword [rdi]
movsxd r11, dword [rdi + 4]
mov r8d, dword [rdi + r11*4 + 8]
mov ecx, dword [rdi + r10*4 + 0x4c]
mov edx, dword [rdi + r10*4 + 8]
ror ecx, 0xd
add ecx, dword [rdi + r11*4 + 0x4c]
ror edx, 5
add edx, r8d
mov dword [rdi + r10*4 + 8], ecx
mov dword [rdi + r10*4 + 0x4c], edx
dec r10d
cmovs r10d, esi
dec r11d
cmovs r11d, esi
dec rbx
mov dword [rdi], r10d
mov dword [rdi + 4], r11d
jne 0x140021f00
mov rbx, qword [rsp + 0x30]
mov rsi, qword [rsp + 0x38]
add rsp, 0x20
pop rdi
ret

Function at 0x140022b64
Capabilities:
Check if file exists
Get disk information
Get file attributes

Disassembly:
mov qword [rsp + 8], rbx
push rbp
lea rbp, [rsp - 0x170]
sub rsp, 0x270
or rbx, 0xffffffffffffffff
test rcx, rcx
je 0x140022c9d
cmp byte [rcx], 0
je 0x140022c9d
mov rdx, rcx
lea rcx, [rsp + 0x20]
mov r8d, 0x104
call sub.msvcrt.dll_strncpy
lea rcx, [rsp + 0x20]
mov byte [rbp + 0x24], 0
call sub.msvcrt.dll_strlen
mov r11, rax
cdqe
lea rcx, [rsp + rax + 0x1f]
cmp r11d, 2
je 0x140022bc6
cmp r11d, 3
jne 0x140022bfa
cmp byte [rsp + 0x21], 0x3a
jne 0x140022bfa
cmp r11d, 2
jne 0x140022be4
lea rdx, [0x14002ac2c]
lea rcx, [rsp + 0x20]
call sub.msvcrt.dll_strcat
lea rcx, [rsp + 0x20]
call qword [sym.imp.KERNEL32.dll_GetDriveTypeA]
cmp eax, 1
jbe 0x140022c9d
jmp 0x140022c75
cmp byte [rcx], 0x5c
je 0x140022c04
cmp byte [rcx], 0x2f
jne 0x140022c0c
mov byte [rcx], 0
dec rcx
jmp 0x140022bfa
lea rdx, [rbp + 0x30]
lea rcx, [rsp + 0x20]
call qword [sym.imp.KERNEL32.dll_FindFirstFileA]
mov rcx, rax
cmp rax, rbx
je 0x140022c47
test byte [rbp + 0x30], 0x10
je 0x140022c32
mov rbx, 0xfffffffffffffffe
jmp 0x140022c3f
mov ebx, dword [rbp + 0x4c]
mov eax, dword [rbp + 0x50]
shl rbx, 0x20
or rbx, rax
call qword [sym.imp.KERNEL32.dll_FindClose]
jmp 0x140022c9d
cmp byte [rsp + 0x20], 0x5c
mov al, byte [rsp + 0x21]
jne 0x140022c56
cmp al, 0x5c
je 0x140022c61
cmp byte [rsp + 0x20], 0x2e
jne 0x140022c9d
cmp al, 0x2e
jne 0x140022c9d
lea rcx, [rsp + 0x20]
call qword [sym.imp.KERNEL32.dll_GetFileAttributesA]
cmp eax, 0xffffffff
je 0x140022c7e
test al, 0x10
je 0x140022c9d
mov rbx, 0xfffffffffffffffe
jmp 0x140022c9d
lea rcx, [rsp + 0x20]
call qword [sym.imp.KERNEL32.dll_GetDriveTypeA]
mov rcx, rbx
mov rbx, 0xfffffffffffffffe
cmp eax, 1
cmova rcx, rbx
mov rbx, rcx
mov rax, rbx
mov rbx, qword [rsp + 0x280]
add rsp, 0x270
pop rbp
ret
Function at 0x140022cb4
Capabilities:
Delete file
Set file attributes

Disassembly:
push rbx
sub rsp, 0x20
mov rbx, rcx
test rcx, rcx
je 0x140022cdf
test dl, 2
je 0x140022cd2
mov edx, pe_nt_image_headers64
call qword [sym.imp.KERNEL32.dll_SetFileAttributesA]
mov rcx, rbx
call qword [sym.imp.KERNEL32.dll_DeleteFileA]
cdqe
jmp 0x140022ce1
xor eax, eax
add rsp, 0x20
pop rbx
ret

Function at 0x140022ce8
Capabilities:
Move file

Disassembly:
sub rsp, 0x28
test rcx, rcx
je 0x140022d00
test rdx, rdx
je 0x140022d00
call qword [sym.imp.KERNEL32.dll_MoveFileA]
cdqe
jmp 0x140022d02
xor eax, eax
add rsp, 0x28
ret

Function at 0x140022d10
Capabilities:
Write file on windows

Disassembly:
push rbx
sub rsp, 0x30
xor eax, eax
mov rbx, rcx
mov dword [rsp + 0x40], eax
cmp dword [rcx + 0x1c], eax
jne 0x140022d56
mov r8d, dword [rcx + 0x10]
mov rdx, qword [rcx + 8]
lea r9, [rsp + 0x40]
sub r8d, dword [rcx + 0x14]
mov rcx, qword [rcx]
mov qword [rsp + 0x20], rax
call qword [sym.imp.KERNEL32.dll_WriteFile]
mov r11d, dword [rbx + 0x10]
movsxd rax, dword [rsp + 0x40]
mov dword [rbx + 0x14], r11d
add rsp, 0x30
pop rbx
ret
cdqe
add rsp, 0x30
pop rbx
ret

Function at 0x140023470
Capabilities:
Write file on windows

Disassembly:
mov qword [rsp + 8], rbx
mov qword [rsp + 0x18], rsi
push rdi
sub rsp, 0x30
xor ebx, ebx
mov edi, r8d
mov rsi, rdx
mov dword [rsp + 0x48], ebx
test rdx, rdx
je 0x1400234e8
test r8d, r8d
je 0x1400234e8
mov rdx, rcx
mov rcx, qword [0x140077300]
call fcn.140025f70
test rax, rax
je 0x1400234e4
mov r8d, edi
mov rdx, rsi
cmp qword [rax + 8], rbx
je 0x1400234d1
mov rcx, rax
call fcn.140023830
mov ebx, eax
cdqe
mov rbx, qword [rsp + 0x40]
mov rsi, qword [rsp + 0x50]
add rsp, 0x30
pop rdi
ret
mov rcx, qword [rax]
lea r9, [rsp + 0x48]
mov qword [rsp + 0x20], rbx
call qword [sym.imp.KERNEL32.dll_WriteFile]
mov ebx, dword [rsp + 0x48]
mov rsi, qword [rsp + 0x50]
movsxd rax, ebx
mov rbx, qword [rsp + 0x40]
add rsp, 0x30
pop rdi
ret

Function at 0x140023500
Capabilities:
Read file on windows

Disassembly:
mov qword [rsp + 8], rbx
push rdi
sub rsp, 0x30
mov rdi, rdx
mov rdx, rcx
mov rcx, qword [0x140077300]
mov rbx, r8
mov dword [rsp + 0x58], 0
call fcn.140025f70
test rax, rax
je 0x140023568
cmp qword [rax + 8], 0
mov rdx, rdi
je 0x14002354e
mov r8, rbx
mov rcx, rax
call fcn.140023930
cdqe
mov rbx, qword [rsp + 0x40]
add rsp, 0x30
pop rdi
ret
mov rcx, qword [rax]
lea r9, [rsp + 0x58]
mov r8d, ebx
mov qword [rsp + 0x20], 0
call qword [sym.imp.KERNEL32.dll_ReadFile]
movsxd rax, dword [rsp + 0x58]
mov rbx, qword [rsp + 0x40]
add rsp, 0x30
pop rdi
ret

Function at 0x140023580
Capabilities:
Get file size

Disassembly:
push rbx
sub rsp, 0x20
mov rdx, rcx
mov rcx, qword [0x140077300]
call fcn.140025f70
mov rbx, rax
test rax, rax
je 0x1400235d4
cmp qword [rax + 8], 0
je 0x1400235b2
cmp dword [rax + 0x1c], 0
jne 0x1400235b2
mov rcx, rax
call fcn.140022d10
mov rcx, qword [rbx]
lea rdx, [rsp + 0x38]
call qword [sym.imp.KERNEL32.dll_GetFileSize]
mov r11d, eax
mov eax, dword [rsp + 0x38]
shl rax, 0x20
or rax, r11
add rsp, 0x20
pop rbx
ret
or rax, 0xffffffffffffffff
add rsp, 0x20
pop rbx
ret
Function at 0x1400235e0
Capabilities:
Write file on windows

Disassembly:
push rbx
push rbp
push rsi
sub rsp, 0x30
mov rsi, rdx
mov rdx, rcx
mov rcx, qword [0x140077300]
xor ebp, ebp
mov dword [rsp + 0x60], ebp
mov dword [rsp + 0x68], ebp
call fcn.140025f70
mov rbx, rax
test rax, rax
je 0x1400236c0
test rsi, rsi
je 0x14002366b
cmp byte [rsi], bpl
je 0x14002366b
or rcx, 0xffffffffffffffff
mov qword [rsp + 0x50], rdi
mov rdx, rsi
mov rdi, rsi
cmp qword [rax + 8], rbp
je 0x140023648
xor eax, eax
repne scasb al, byte [rdi]
not rcx
lea r8, [rcx - 1]
mov rcx, rbx
call fcn.140023830
mov dword [rsp + 0x60], eax
jmp 0x140023666
xor eax, eax
lea r9, [rsp + 0x60]
mov qword [rsp + 0x20], rbp
repne scasb al, byte [rdi]
not rcx
lea r8, [rcx - 1]
mov rcx, qword [rbx]
call qword [sym.imp.KERNEL32.dll_WriteFile]
mov rdi, qword [rsp + 0x50]
mov r8d, 2
lea rdx, [0x14002ac30]
cmp qword [rbx + 8], rbp
je 0x140023699
mov rcx, rbx
call fcn.140023830
mov rdx, rax
mov eax, dword [rsp + 0x60]
add eax, edx
cdqe
add rsp, 0x30
pop rsi
pop rbp
pop rbx
ret
mov rcx, qword [rbx]
lea r9, [rsp + 0x68]
mov qword [rsp + 0x20], rbp
call qword [sym.imp.KERNEL32.dll_WriteFile]
mov eax, dword [rsp + 0x60]
mov edx, dword [rsp + 0x68]
add eax, edx
cdqe
add rsp, 0x30
pop rsi
pop rbp
pop rbx
ret
movsxd rax, dword [rsp + 0x60]
add rsp, 0x30
pop rsi
pop rbp
pop rbx
ret

Function at 0x1400237c0
Capabilities:
Write file on windows

Disassembly:
mov qword [rsp + 0x10], rdx
sub rsp, 0x38
mov rdx, rcx
mov rcx, qword [0x140077300]
mov dword [rsp + 0x50], 0
call fcn.140025f70
test rax, rax
je 0x14002381d
cmp qword [rax + 8], 0
mov r8d, 8
lea rdx, [rsp + 0x48]
je 0x140023806
mov rcx, rax
call fcn.140023830
cdqe
add rsp, 0x38
ret
mov rcx, qword [rax]
lea r9, [rsp + 0x50]
mov qword [rsp + 0x20], 0
call qword [sym.imp.KERNEL32.dll_WriteFile]
movsxd rax, dword [rsp + 0x50]
add rsp, 0x38
ret