joyce8/EMBER2024-capa huggingface dataset:
Function at 0x1800535f0
Capabilities:
Enumerate threads
Suspend thread

Disassembly:
mov qword [rsp + 0x18], rbx
mov qword [rsp + 0x20], rbp
push rsi
push rdi
push r14
sub rsp, 0x50
mov rax, qword [0x1800ad240]
xor rax, rsp
mov qword [rsp + 0x40], rax
xor esi, esi
mov r14d, edx
mov rbx, rcx
mov qword [rcx], rsi
mov qword [rcx + 8], rsi
xor edx, edx
mov ebp, r8d
lea ecx, [rsi + 4]
call sub.KERNEL32.dll_CreateToolhelp32Snapshot
mov rdi, rax
cmp rax, 0xffffffffffffffff
je 0x18005371a
lea rdx, [rsp + 0x20]
mov dword [rsp + 0x20], 0x1c
mov rcx, rax
call sub.KERNEL32.dll_Thread32First
test eax, eax
je 0x180053711
nop word [rax + rax]
cmp dword [rsp + 0x20], 0x10
jb 0x1800536f4
call qword [sym.imp.KERNEL32.dll_GetCurrentProcessId]
cmp dword [rsp + 0x2c], eax
jne 0x1800536f4
call qword [sym.imp.KERNEL32.dll_GetCurrentThreadId]
cmp dword [rsp + 0x28], eax
je 0x1800536f4
mov rdx, qword [rbx]
test rdx, rdx
jne 0x1800536b2
mov dword [rbx + 8], 0x80
mov r8d, 0x200
mov rcx, qword [0x1800c6798]
call qword [sym.imp.KERNEL32.dll_HeapAlloc]
mov qword [rbx], rax
mov rdx, rax
test rax, rax
je 0x180053711
jmp 0x1800536e7
mov eax, dword [rbx + 8]
cmp dword [rbx + 0xc], eax
jb 0x1800536e7
mov rcx, qword [0x1800c6798]
lea r9d, [rax + rax]
mov r8, rdx
shl r9, 2
xor edx, edx
call qword [sym.imp.KERNEL32.dll_HeapReAlloc]
mov rdx, rax
test rax, rax
je 0x180053711
mov eax, dword [rbx + 8]
add eax, eax
mov qword [rbx], rdx
mov dword [rbx + 8], eax
mov ecx, dword [rbx + 0xc]
mov eax, dword [rsp + 0x28]
mov dword [rdx + rcx*4], eax
inc dword [rbx + 0xc]
lea rdx, [rsp + 0x20]
mov dword [rsp + 0x20], 0x1c
mov rcx, rdi
call sub.KERNEL32.dll_Thread32Next
test eax, eax
jne 0x180053660
mov rcx, rdi
call qword [sym.imp.KERNEL32.dll_CloseHandle]
cmp qword [rbx], rsi
je 0x180053773
cmp dword [rbx + 0xc], esi
jbe 0x180053773
nop dword [rax]
nop dword [rax + rax]
mov r8, qword [rbx]
xor edx, edx
mov eax, esi
lea ecx, [rdx + 0x5a]
mov r8d, dword [r8 + rax*4]
call qword [sym.imp.KERNEL32.dll_OpenThread]
mov rdi, rax
test rax, rax
je 0x18005376c
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_SuspendThread]
mov r8d, ebp
mov edx, r14d
mov rcx, rdi
call fcn.180053dd0
mov rcx, rdi
call qword [sym.imp.KERNEL32.dll_CloseHandle]
inc esi
cmp esi, dword [rbx + 0xc]
jb 0x180053730
mov rcx, qword [rsp + 0x40]
xor rcx, rsp
call fcn.180054f40
lea r11, [rsp + 0x50]
mov rbx, qword [r11 + 0x30]
mov rbp, qword [r11 + 0x38]
mov rsp, r11
pop r14
pop rdi
pop rsi
ret
Function at 0x180053af0
Capabilities:
Resume thread

Disassembly:
mov qword [rsp + 0x18], rbx
mov qword [rsp + 0x20], rsi
push rdi
push r14
push r15
sub rsp, 0x30
xor r15d, r15d
mov rdi, rcx
mov r14d, r15d
mov ebx, r15d
xor eax, eax
mov esi, 1
lock cmpxchg dword [0x1800c6790], esi
je 0x180053b41
cmp rbx, 0x20
jae 0x180053b2a
xor ecx, ecx
jmp 0x180053b2c
mov ecx, esi
call qword [sym.imp.KERNEL32.dll_Sleep]
inc rbx
xor eax, eax
lock cmpxchg dword [0x1800c6790], esi
jne 0x180053b20
cmp qword [0x1800c6798], r14
mov qword [rsp + 0x58], r13
je 0x180053cdd
mov ecx, dword [0x1800cc37c]
mov ebx, r15d
test ecx, ecx
je 0x180053b7f
mov rdx, qword [0x1800cc370]
mov rax, rdx
nop word [rax + rax]
cmp rdi, qword [rax]
je 0x180053b8a
inc ebx
add rax, 0x38
cmp ebx, ecx
jb 0x180053b70
mov r14d, 4
jmp 0x180053ce3
cmp ebx, 0xffffffff
je 0x180053b7f
mov eax, ebx
imul r13, rax, 0x38
test byte [rdx + r13 + 0x20], 2
je 0x180053c3b
xor r8d, r8d
lea rcx, [rsp + 0x20]
mov edx, ebx
call fcn.1800535f0
xor edx, edx
mov ecx, ebx
call fcn.1800534e0
mov r14d, eax
cmp qword [rsp + 0x20], r15
je 0x180053c2b
mov ecx, dword [rsp + 0x2c]
test ecx, ecx
je 0x180053c17
mov rdi, qword [rsp + 0x20]
mov qword [rsp + 0x50], rbp
mov ebp, ecx
nop word [rax + rax]
mov r8d, dword [rdi]
xor edx, edx
lea ecx, [rdx + 0x5a]
call qword [sym.imp.KERNEL32.dll_OpenThread]
mov rsi, rax
test rax, rax
je 0x180053c08
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_ResumeThread]
mov rcx, rsi
call qword [sym.imp.KERNEL32.dll_CloseHandle]
add rdi, 4
sub rbp, 1
jne 0x180053be0
mov rbp, qword [rsp + 0x50]
mov r8, qword [rsp + 0x20]
xor edx, edx
mov rcx, qword [0x1800c6798]
call qword [sym.imp.KERNEL32.dll_HeapFree]
test r14d, r14d
jne 0x180053ce3
mov rdx, qword [0x1800cc370]
mov rcx, qword [rdx + r13 + 0x10]
call fcn.180054030
mov ecx, dword [0x1800cc37c]
lea eax, [rcx - 1]
cmp ebx, eax
jae 0x180053c8f
imul rcx, rax, 0x38
mov rax, qword [0x1800cc370]
movups xmm0, xmmword [rcx + rax]
movups xmmword [rax + r13], xmm0
movups xmm1, xmmword [rcx + rax + 0x10]
movups xmmword [rax + r13 + 0x10], xmm1
movups xmm0, xmmword [rcx + rax + 0x20]
movups xmmword [rax + r13 + 0x20], xmm0
movsd xmm1, qword [rcx + rax + 0x30]
movsd qword [rax + r13 + 0x30], xmm1
mov ecx, dword [0x1800cc37c]
mov edx, dword [0x1800cc378]
dec ecx
mov eax, edx
mov dword [0x1800cc37c], ecx
shr eax, 1
cmp eax, 0x20
jb 0x180053ce3
cmp eax, ecx
jb 0x180053ce3
mov r8, qword [0x1800cc370]
mov eax, edx
mov rcx, qword [0x1800c6798]
xor edx, edx
shr rax, 1
imul r9, rax, 0x38
call qword [sym.imp.KERNEL32.dll_HeapReAlloc]
test rax, rax
je 0x180053ce3
shr dword [0x1800cc378], 1
mov qword [0x1800cc370], rax
jmp 0x180053ce3
mov r14d, 2
xchg dword [0x1800c6790], r15d
mov r13, qword [rsp + 0x58]
mov eax, r14d
mov rbx, qword [rsp + 0x60]
mov rsi, qword [rsp + 0x68]
add rsp, 0x30
pop r15
pop r14
pop rdi
ret
Function at 0x180053f80
Capabilities:
Resume thread

Disassembly:
push rdi
sub rsp, 0x20
cmp qword [rcx], 0
mov rdi, rcx
je 0x180053fef
mov qword [rsp + 0x30], rbx
xor ebx, ebx
cmp dword [rcx + 0xc], ebx
jbe 0x180053fd8
mov qword [rsp + 0x38], rsi
mov r8, qword [rdi]
xor edx, edx
mov r8d, dword [r8 + rbx*4]
lea ecx, [rdx + 0x5a]
call qword [sym.imp.KERNEL32.dll_OpenThread]
mov rsi, rax
test rax, rax
je 0x180053fcc
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_ResumeThread]
mov rcx, rsi
call qword [sym.imp.KERNEL32.dll_CloseHandle]
inc ebx
cmp ebx, dword [rdi + 0xc]
jb 0x180053fa0
mov rsi, qword [rsp + 0x38]
mov r8, qword [rdi]
xor edx, edx
mov rcx, qword [0x1800c6798]
call qword [sym.imp.KERNEL32.dll_HeapFree]
mov rbx, qword [rsp + 0x30]
add rsp, 0x20
pop rdi
ret
Function at 0x1800540b0
Capabilities:
Get system information on windows

Disassembly:
mov qword [rsp + 0x20], rsi
push rdi
push r14
push r15
sub rsp, 0x80
mov rdi, rcx
lea rcx, [rsp + 0x20]
call qword [sym.imp.KERNEL32.dll_GetSystemInfo]
mov r14, qword [rsp + 0x28]
mov rcx, qword [rsp + 0x30]
cmp rdi, 0x40000000
jbe 0x1800540f0
lea rax, [rdi - 0x40000000]
cmp r14, rax
cmovb r14, rax
mov rsi, qword [0x1800cc360]
lea r15, [rdi + 0x40000000]
cmp rcx, r15
cmovbe r15, rcx
sub r15, 0xfff
test rsi, rsi
je 0x18005412e
cmp rsi, r14
jb 0x180054126
cmp rsi, r15
jae 0x180054126
cmp qword [rsi + 8], 0
jne 0x1800542f7
mov rsi, qword [rsi]
test rsi, rsi
jne 0x180054111
mov qword [rsp + 0xa0], rbx
mov rbx, rdi
mov qword [rsp + 0xa8], rbp
mov qword [rsp + 0xb0], r12
mov r12d, 0x40
cmp rdi, r14
jb 0x1800541c2
nop dword [rax]
nop dword [rax + rax]
mov ebp, dword [rsp + 0x48]
mov rax, rbx
xor edx, edx
div rbp
sub rbx, rdx
sub rbx, rbp
cmp rbx, r14
jb 0x1800541b9
nop word [rax + rax]
mov r8d, 0x30
lea rdx, [rsp + 0x50]
mov rcx, rbx
call qword [sym.imp.KERNEL32.dll_VirtualQuery]
test rax, rax
je 0x1800541b9
cmp dword [rsp + 0x70], 0x10000
je 0x18005423b
mov rbx, qword [rsp + 0x58]
cmp rbx, rbp
jb 0x1800541b9
sub rbx, rbp
cmp rbx, r14
jae 0x180054180
test rsi, rsi
jne 0x1800542a0
cmp rdi, r15
ja 0x1800542df
nop dword [rax + rax]
mov ebp, dword [rsp + 0x48]
xor edx, edx
mov rax, rdi
mov ebx, ebp
div rbp
mov eax, ebp
sub rax, rdx
add rax, rdi
mov rdi, rax
cmp rax, r15
ja 0x1800542df
mov r8d, 0x30
lea rdx, [rsp + 0x50]
mov rcx, rdi
call qword [sym.imp.KERNEL32.dll_VirtualQuery]
test rax, rax
je 0x1800542df
cmp dword [rsp + 0x70], 0x10000
je 0x180054271
xor edx, edx
lea edi, [rbp - 1]
add rdi, qword [rsp + 0x68]
add rdi, qword [rsp + 0x50]
mov rax, rdi
div rbx
sub rdi, rdx
cmp rdi, r15
jbe 0x1800541f2
jmp 0x1800542df
test rbx, rbx
je 0x1800541b9
mov r9d, r12d
mov edx, 0x1000
mov r8d, 0x3000
mov rcx, rbx
call qword [sym.imp.KERNEL32.dll_VirtualAlloc]
mov rsi, rax
test rax, rax
jne 0x1800542a0
cmp rbx, r14
jae 0x180054160
jmp 0x1800541c2
test rdi, rdi
je 0x1800542df
mov r9d, r12d
mov edx, 0x1000
mov r8d, 0x3000
mov rcx, rdi
call qword [sym.imp.KERNEL32.dll_VirtualAlloc]
mov rsi, rax
test rax, rax
jne 0x1800542a0
cmp rdi, r15
jbe 0x1800541d0
jmp 0x1800542df
xor edx, edx
lea rcx, [rsi + 0x40]
mov dword [rsi + 0x10], edx
nop dword [rax]
mov qword [rcx], rdx
mov rax, rcx
mov qword [rsi + 8], rcx
add r12, 0x40
add rcx, 0x40
mov rdx, rax
cmp r12, 0xfc0
jbe 0x1800542b0
mov rax, qword [0x1800cc360]
mov qword [rsi], rax
mov qword [0x1800cc360], rsi
mov r12, qword [rsp + 0xb0]
mov rbp, qword [rsp + 0xa8]
mov rbx, qword [rsp + 0xa0]
mov rax, rsi
mov rsi, qword [rsp + 0xb8]
add rsp, 0x80
pop r15
pop r14
pop rdi
ret
Function at 0x406cf4
Capabilities:
Set file attributes

Disassembly:
test edx, 0xf0000000
je 0x406d02
and edx, 0x3fff
jmp fcn.00406c4c

Function at 0x406d08
Capabilities:
Delete directory

Disassembly:
push rbx
push rdi
sub rsp, 0x48
mov qword [rsp + 0x20], 0xfffffffffffffffe
mov rdi, rcx
call fcn.0040ace8
mov ebx, eax
cmp eax, 1
je 0x406d38
mov rcx, rdi
call qword [sym.imp.KERNEL32.dll_RemoveDirectoryW]
test eax, eax
je 0x406d38
mov al, 1
jmp 0x406d89
test ebx, ebx
je 0x406d87
lea rcx, [rsp + 0x28]
call fcn.00403558
nop
cmp ebx, 1
setne r8b
lea rdx, [rsp + 0x28]
mov rcx, rdi
call fcn.0040b364
test al, al
je 0x406d7d
mov rcx, qword [rsp + 0x28]
call qword [sym.imp.KERNEL32.dll_RemoveDirectoryW]
test eax, eax
setne bl
mov rcx, qword [rsp + 0x28]
call fcn.0040237c
mov al, bl
jmp 0x406d89
mov rcx, qword [rsp + 0x28]
call fcn.0040237c
xor al, al
add rsp, 0x48
pop rdi
pop rbx
ret

Function at 0x406db0
Capabilities:
Move file

Disassembly:
push rbx
push rbp
push rsi
push rdi
push r12
sub rsp, 0x60
mov qword [rsp + 0x30], 0xfffffffffffffffe
mov rbp, rdx
mov r12, rcx
call fcn.0040ace8
mov esi, eax
mov rcx, rbp
call fcn.0040ace8
mov edi, eax
mov ebx, 1
cmp esi, ebx
je 0x406dff
cmp eax, ebx
je 0x406dff
mov rdx, rbp
mov rcx, r12
call qword [sym.imp.KERNEL32.dll_MoveFileW]
test eax, eax
je 0x406dff
mov al, bl
jmp 0x406e8d
test esi, esi
jne 0x406e0b
test edi, edi
je 0x406e8b
lea rcx, [rsp + 0x48]
call fcn.00403558
nop
lea rcx, [rsp + 0x38]
call fcn.00403558
nop
cmp esi, ebx
je 0x406e29
cmp edi, ebx
jne 0x406e2b
xor bl, bl
mov byte [rsp + 0x20], bl
lea r9, [rsp + 0x38]
lea r8, [rsp + 0x48]
mov rdx, rbp
mov rcx, r12
call fcn.0040b3ac
test al, al
je 0x406e76
mov rdx, qword [rsp + 0x38]
mov rcx, qword [rsp + 0x48]
call qword [sym.imp.KERNEL32.dll_MoveFileW]
test eax, eax
setne bl
mov rcx, qword [rsp + 0x38]
call fcn.0040237c
nop
mov rcx, qword [rsp + 0x48]
call fcn.0040237c
mov al, bl
jmp 0x406e8d
mov rcx, qword [rsp + 0x38]
call fcn.0040237c
nop
mov rcx, qword [rsp + 0x48]
call fcn.0040237c
xor al, al
add rsp, 0x60
pop r12
pop rdi
pop rsi
pop rbp
pop rbx
ret

Function at 0x407030
Capabilities:
Create directory

Disassembly:
push rbx
push rdi
sub rsp, 0x48
mov qword [rsp + 0x20], 0xfffffffffffffffe
mov rdi, rcx
call fcn.0040ace8
mov ebx, eax
cmp eax, 1
je 0x40706f
xor edx, edx
mov rcx, rdi
call qword [sym.imp.KERNEL32.dll_CreateDirectoryW]
test eax, eax
je 0x407062
mov al, 1
jmp 0x4070c2
call qword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 0xb7
je 0x4070c0
test ebx, ebx
je 0x4070c0
lea rcx, [rsp + 0x28]
call fcn.00403558
nop
cmp ebx, 1
setne r8b
lea rdx, [rsp + 0x28]
mov rcx, rdi
call fcn.0040b364
test al, al
je 0x4070b6
xor edx, edx
mov rcx, qword [rsp + 0x28]
call qword [sym.imp.KERNEL32.dll_CreateDirectoryW]
test eax, eax
setne bl
mov rcx, qword [rsp + 0x28]
call fcn.0040237c
mov al, bl
jmp 0x4070c2
mov rcx, qword [rsp + 0x28]
call fcn.0040237c
xor al, al
add rsp, 0x48
pop rdi
pop rbx
ret
Function at 0x4070f4
Capabilities:
Delete file

Disassembly:
push rbx
push rdi
sub rsp, 0x48
mov qword [rsp + 0x20], 0xfffffffffffffffe
mov rbx, rcx
call fcn.00408184
cmp eax, 0xffffffff
je 0x40712a
test al, 0x10
jne 0x40712a
test al, 1
je 0x40712a
and eax, 0xfffffffe
mov edx, eax
mov rcx, rbx
call fcn.00406c4c
test al, al
je 0x40719b
mov rcx, rbx
call fcn.0040ace8
mov edi, eax
cmp eax, 1
je 0x40714a
mov rcx, rbx
call qword [sym.imp.KERNEL32.dll_DeleteFileW]
test eax, eax
je 0x40714a
mov al, 1
jmp 0x40719b
test edi, edi
je 0x407199
lea rcx, [rsp + 0x28]
call fcn.00403558
nop
cmp edi, 1
setne r8b
lea rdx, [rsp + 0x28]
mov rcx, rbx
call fcn.0040b364
test al, al
je 0x40718f
mov rcx, qword [rsp + 0x28]
call qword [sym.imp.KERNEL32.dll_DeleteFileW]
test eax, eax
setne bl
mov rcx, qword [rsp + 0x28]
call fcn.0040237c
mov al, bl
jmp 0x40719b
mov rcx, qword [rsp + 0x28]
call fcn.0040237c
xor al, al
add rsp, 0x48
pop rdi
pop rbx
ret

Function at 0x4071c4
Capabilities:
Set current directory

Disassembly:
sub rsp, 0x28
call qword [sym.imp.KERNEL32.dll_SetCurrentDirectoryW]
xor ecx, ecx
cmp eax, ecx
setne al
add rsp, 0x28
ret

Function at 0x4072a8
Capabilities:
Get common file path

Disassembly:
push rbx
push rsi
push rdi
sub rsp, 0x230
mov rax, qword [rcx]
xor esi, esi
mov rdi, rcx
mov dword [rcx + 8], esi
lea rdx, [rsp + 0x20]
mov ecx, 0x105
mov word [rax], si
mov word [rsp + 0x20], si
call qword [sym.imp.KERNEL32.dll_GetTempPathW]
lea rdx, [rsp + 0x20]
mov rcx, rdi
mov ebx, eax
call fcn.0040373c
lea r11d, [rbx - 1]
cmp r11d, 0x103
setbe al
add rsp, 0x230
pop rdi
pop rsi
pop rbx
ret
Function at 0x407300
Capabilities:
Check for time delay via gettickcount

Disassembly:
push rbx
push rbp
push rsi
push rdi
push r12
push r13
push r14
push r15
sub rsp, 0x38
mov rbp, r9
mov rsi, r8
mov r12b, dl
mov r14, rcx
call qword [sym.imp.KERNEL32.dll_GetCurrentThreadId]
mov ebx, eax
shl ebx, 2
call qword [sym.imp.KERNEL32.dll_GetTickCount]
mov edi, eax
xor edi, ebx
shl edi, 0xc
call qword [sym.imp.KERNEL32.dll_GetCurrentProcessId]
mov r13d, eax
xor r13d, edi
xor edi, edi
lea r15d, [rdi + 1]
mov ebx, edi
mov rdx, r14
mov rcx, rsi
call fcn.0040373c
cmp r12b, dil
je 0x4073e3
mov r10d, r13d
mov r9, rdi
mov r11d, 8
mov r8d, r10d
shr r10d, 4
and r8d, 0xf
cmp r8d, 0xa
lea eax, [r8 + 0x37]
lea edx, [r8 + 0x30]
movzx ecx, al
movzx eax, dl
cmovb ecx, eax
mov byte [rsp + r9 + 0x20], cl
add r9, r15
sub r11, r15
jne 0x407369
cmp rbp, rdi
mov byte [rsp + r9 + 0x20], dil
je 0x4073c6
mov eax, dword [rsi + 8]
cmp dword [rsi + 0xc], eax
jne 0x4073b0
mov rcx, rsi
call fcn.004032bc
mov edx, dword [rsi + 8]
mov rcx, qword [rsi]
mov word [rcx + rdx*2], 0x2e
add edx, r15d
mov word [rcx + rdx*2], di
mov dword [rsi + 8], edx
lea rdx, [rsp + 0x20]
mov rcx, rsi
call fcn.004039fc
call qword [sym.imp.KERNEL32.dll_GetTickCount]
add eax, 2
cmove eax, r15d
add r13d, eax
cmp rbp, rdi
mov r12b, r15b
je 0x4073fa
lea rdx, str..tmp
mov rcx, rsi
call fcn.004039fc
mov rcx, qword [rsi]
call fcn.00408d98
cmp al, dil
je 0x407414
mov ecx, 0xb7
call qword [sym.imp.KERNEL32.dll_SetLastError]
jmp 0x407448
cmp rbp, rdi
je 0x407429
mov rdx, qword [rsi]
xor r8d, r8d
mov rcx, rbp
call fcn.00409af4
jmp 0x407431
mov rcx, qword [rsi]
call fcn.00407030
cmp al, dil
jne 0x407470
call qword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 0x50
je 0x407448
cmp eax, 0xb7
jne 0x407454
add ebx, r15d
cmp ebx, 0x64
jb 0x407349
mov rax, qword [rsi]
mov dword [rsi + 8], edi
mov word [rax], di
xor al, al
add rsp, 0x38
pop r15
pop r14
pop r13
pop r12
pop rdi
pop rsi
pop rbp
pop rbx
ret
mov al, r15b
jmp 0x40745f
Function at 0x408184
Capabilities:
Check if file exists
Get file attributes

Disassembly:
push rbx
push rdi
sub rsp, 0x48
mov qword [rsp + 0x20], 0xfffffffffffffffe
mov rdi, rcx
call fcn.0040ace8
mov ebx, eax
cmp eax, 1
je 0x4081b1
mov rcx, rdi
call qword [sym.imp.KERNEL32.dll_GetFileAttributesW]
cmp eax, 0xffffffff
jne 0x408202
test ebx, ebx
je 0x4081fd
lea rcx, [rsp + 0x28]
call fcn.00403558
nop
cmp ebx, 1
setne r8b
lea rdx, [rsp + 0x28]
mov rcx, rdi
call fcn.0040b364
test al, al
je 0x4081f3
mov rcx, qword [rsp + 0x28]
call qword [sym.imp.KERNEL32.dll_GetFileAttributesW]
mov ebx, eax
mov rcx, qword [rsp + 0x28]
call fcn.0040237c
mov eax, ebx
jmp 0x408202
mov rcx, qword [rsp + 0x28]
call fcn.0040237c
mov eax, 0xffffffff
add rsp, 0x48
pop rdi
pop rbx
ret

Function at 0x408ed8
Capabilities:
Get disk information

Disassembly:
push rbx
push rbp
push rsi
push rdi
push r12
push r13
sub rsp, 0x48
mov qword [rsp + 0x20], 0xfffffffffffffffe
mov rbp, rcx
movsxd rbx, dword [rcx + 8]
mov rdi, rbx
test ebx, ebx
je 0x408f28
shl rdi, 3
add ebx, 0xffffffff
sub rdi, 8
mov rax, qword [rbp]
mov rsi, qword [rdi + rax]
test rsi, rsi
je 0x408f24
mov rcx, qword [rsi]
call fcn.0040237c
mov rcx, rsi
call fcn.0040237c
test ebx, ebx
jne 0x408f00
mov dword [rbp + 8], 0
xor edx, edx
xor ecx, ecx
call qword [sym.imp.KERNEL32.dll_GetLogicalDriveStringsW]
mov edi, eax
test eax, eax
je 0x40902d
mov rcx, rdi
xor ebx, ebx
mov qword [rsp + 0x80], rbx
test eax, eax
je 0x408f67
add rcx, rcx
call fcn.00402350
mov rbx, rax
mov qword [rsp + 0x80], rax
mov rdx, rbx
mov ecx, edi
call qword [sym.imp.KERNEL32.dll_GetLogicalDriveStringsW]
mov esi, eax
test eax, eax
je 0x409023
cmp eax, edi
ja 0x409023
lea rcx, [rsp + 0x28]
call fcn.00403558
nop
xor r13d, r13d
xor edi, edi
test esi, esi
je 0x409004
mov r12, rbx
cmp word [r12], 0
jne 0x408ffa
lea rdx, [rbx + r13*2]
lea rcx, [rsp + 0x28]
call fcn.0040373c
lea r13d, [rdi + 1]
mov rcx, rbp
call fcn.004421a4
mov ecx, 0x10
call fcn.00402350
mov qword [rsp + 0x88], rax
test rax, rax
je 0x408fe6
lea rdx, [rsp + 0x28]
mov rcx, rax
call fcn.004036b4
mov r11, rax
jmp 0x408fe9
xor r11d, r11d
mov ecx, dword [rbp + 8]
lea eax, [rcx + 1]
mov dword [rbp + 8], eax
mov rax, qword [rbp]
mov qword [rax + rcx*8], r11
inc edi
add r12, 2
cmp edi, esi
jb 0x408f9b
cmp r13d, esi
sete dil
mov rcx, qword [rsp + 0x28]
call fcn.0040237c
nop
mov rcx, rbx
call fcn.0040237c
mov al, dil
jmp 0x40902d
mov rcx, rbx
call fcn.0040237c
xor al, al
add rsp, 0x48
pop r13
pop r12
pop rdi
pop rsi
pop rbp
pop rbx
ret

Function at 0x4090fc
Capabilities:
Get file size

Disassembly:
push rbx
push rdi
sub rsp, 0x28
cmp byte [rcx + 9], 0
mov rbx, rdx
je 0x40911b
cmp byte [rcx + 0xa], 0
je 0x40911b
mov rax, qword [rcx + 0x10]
mov qword [rdx], rax
jmp 0x409157
mov rcx, qword [rcx]
lea rdx, [rsp + 0x40]
mov dword [rsp + 0x40], 0
call qword [sym.imp.KERNEL32.dll_GetFileSize]
cmp eax, 0xffffffff
mov edi, eax
jne 0x409146
call qword [sym.imp.KERNEL32.dll_GetLastError]
test eax, eax
je 0x409146
xor al, al
jmp 0x409159
mov ecx, dword [rsp + 0x40]
mov rax, rdi
shl rcx, 0x20
add rcx, rdi
mov qword [rbx], rcx
mov al, 1
add rsp, 0x28
pop rdi
pop rbx
ret
Function at 0x40927c
Capabilities:
Read file on windows

Disassembly:
push rbx
sub rsp, 0x30
mov rcx, qword [rcx]
mov rbx, r9
lea r9, [rsp + 0x58]
mov dword [rsp + 0x58], 0
mov qword [rsp + 0x20], 0
call qword [sym.imp.KERNEL32.dll_ReadFile]
mov ecx, dword [rsp + 0x58]
test eax, eax
setne al
mov dword [rbx], ecx
add rsp, 0x30
pop rbx
ret

Function at 0x4092b8
Capabilities:
Read file on windows

Disassembly:
mov eax, 0x400000
cmp r8d, eax
cmova r8d, eax
jmp fcn.0040927c

Function at 0x40937c
Capabilities:
Write file on windows

Disassembly:
push rbx
sub rsp, 0x30
mov rcx, qword [rcx]
mov eax, 0x400000
mov rbx, r9
cmp r8d, eax
lea r9, [rsp + 0x50]
mov dword [rsp + 0x50], 0
cmova r8d, eax
mov qword [rsp + 0x20], 0
call qword [sym.imp.KERNEL32.dll_WriteFile]
mov ecx, dword [rsp + 0x50]
test eax, eax
mov dword [rbx], ecx
setne al
add rsp, 0x30
pop rbx
ret

Function at 0x409490
Capabilities:
Clear file content

Disassembly:
push rbx
push rsi
push rdi
sub rsp, 0x20
lea r9, [rsp + 0x50]
xor r8d, r8d
mov rdi, rdx
mov rsi, rcx
call fcn.004091bc
xor ebx, ebx
cmp al, bl
je 0x4094b8
cmp qword [rsp + 0x50], rdi
je 0x4094bc
xor al, al
jmp 0x4094ca
mov rcx, qword [rsi]
call qword [sym.imp.KERNEL32.dll_SetEndOfFile]
cmp eax, ebx
setne al
add rsp, 0x20
pop rdi
pop rsi
pop rbx
ret

Function at 0x40aaf8
Capabilities:
Get common file path

Disassembly:
push rbx
push rsi
push rdi
sub rsp, 0x230
mov rax, qword [rcx]
xor esi, esi
mov rdi, rcx
mov dword [rcx + 8], esi
lea rdx, [rsp + 0x20]
mov ecx, 0x105
mov word [rax], si
mov word [rsp + 0x20], si
call qword [sym.imp.KERNEL32.dll_GetCurrentDirectoryW]
lea rdx, [rsp + 0x20]
mov rcx, rdi
mov ebx, eax
call fcn.0040373c
lea r11d, [rbx - 1]
cmp r11d, 0x103
setbe al
add rsp, 0x230
pop rdi
pop rsi
pop rbx
ret

Function at 0x40b740
Capabilities:
Get disk size

Disassembly:
push rbx
push rbp
push rsi
push rdi
push r12
sub rsp, 0x60
mov r12, rcx
lea rcx, [0x0045d9a0]
mov rdi, r9
mov rsi, r8
mov rbx, rdx
xor bpl, bpl
call qword [sym.imp.KERNEL32.dll_GetModuleHandleW]
lea rdx, str.GetDiskFreeSpaceExW
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_GetProcAddress]
test rax, rax
je 0x40b7a6
lea r9, [rsp + 0x48]
lea r8, [rsp + 0x40]
lea rdx, [rsp + 0x50]
mov rcx, r12
call rax
test eax, eax
mov rax, qword [rsp + 0x40]
mov qword [rsi], rax
mov rax, qword [rsp + 0x48]
setne bpl
mov qword [rdi], rax
lea rax, [rsp + 0x38]
lea r9, [rsp + 0x3c]
lea r8, [rsp + 0x34]
lea rdx, [rsp + 0x30]
mov rcx, r12
mov qword [rsp + 0x20], rax
call qword [sym.imp.KERNEL32.dll_GetDiskFreeSpaceW]
test eax, eax
je 0x40b7f8
mov ecx, dword [rsp + 0x30]
mov eax, dword [rsp + 0x34]
imul rcx, rax
test bpl, bpl
mov qword [rbx], rcx
jne 0x40b7f6
mov eax, dword [rsp + 0x38]
imul rax, rcx
mov qword [rsi], rax
mov eax, dword [rsp + 0x3c]
imul rax, qword [rbx]
mov qword [rdi], rax
mov al, 1
add rsp, 0x60
pop r12
pop rdi
pop rsi
pop rbp
pop rbx
ret
Function at 0x40c094
Capabilities:
Query or enumerate registry value

Disassembly:
push rbx
push rsi
push rdi
mov r11, rsp
sub rsp, 0x40
mov rax, qword [r8]
mov dword [r8 + 8], 0
mov rsi, rcx
mov word [rax], 0
mov rcx, qword [rcx]
lea rax, [r11 + 0x30]
mov rbx, r8
mov qword [r11 - 0x18], rax
lea r9, [r11 - 0x10]
xor r8d, r8d
mov qword [r11 - 0x20], 0
mov rdi, rdx
mov dword [rsp + 0x30], 0
mov dword [rsp + 0x70], 0
call qword [sym.imp.ADVAPI32.dll_RegQueryValueExW]
test eax, eax
je 0x40c0f3
cmp eax, 0xea
jne 0x40c169
mov edx, dword [rsp + 0x70]
cmp edx, dword [rbx + 0xc]
mov dword [rsp + 0x78], edx
jbe 0x40c108
mov rcx, rbx
call fcn.00403234
mov rax, qword [rbx]
lea rcx, [rsp + 0x78]
lea r9, [rsp + 0x34]
mov qword [rsp + 0x28], rcx
mov rcx, qword [rsi]
xor r8d, r8d
mov rdx, rdi
mov dword [rsp + 0x34], 0
mov qword [rsp + 0x20], rax
call qword [sym.imp.ADVAPI32.dll_RegQueryValueExW]
mov ecx, dword [rsp + 0x70]
mov rdx, qword [rbx]
cmp ecx, dword [rsp + 0x78]
cmova ecx, dword [rsp + 0x78]
mov dword [rsp + 0x70], ecx
shr rcx, 1
mov word [rdx + rcx*2], 0
xor ecx, ecx
cmp word [rdx], cx
je 0x40c166
add rdx, 2
inc ecx
cmp word [rdx], 0
jne 0x40c15a
mov dword [rbx + 8], ecx
add rsp, 0x40
pop rdi
pop rsi
pop rbx
ret

Function at 0x40c1d0
Capabilities:
Query or enumerate registry value

Disassembly:
push rbx
push rbp
push rsi
push rdi
push r12
mov rax, rsp
sub rsp, 0x40
mov dword [r9], 0
mov qword [rax - 0x18], r9
mov r12, rcx
mov rcx, qword [rcx]
mov rsi, r9
mov rbx, r8
lea r9, [rax + 0x48]
xor r8d, r8d
mov rbp, rdx
mov dword [rax + 0x48], 0
mov qword [rax - 0x20], 0
call qword [sym.imp.ADVAPI32.dll_RegQueryValueExW]
test eax, eax
je 0x40c21f
cmp eax, 0xea
jne 0x40c281
mov edi, dword [rsi]
cmp rdi, qword [rbx + 8]
je 0x40c257
mov rcx, qword [rbx]
test rcx, rcx
je 0x40c23b
call fcn.0040237c
mov qword [rbx], 0
test rdi, rdi
mov qword [rbx + 8], 0
je 0x40c257
mov rcx, rdi
call fcn.00402350
mov qword [rbx + 8], rdi
mov qword [rbx], rax
mov rax, qword [rbx]
mov rcx, qword [r12]
lea r9, [rsp + 0x30]
xor r8d, r8d
mov rdx, rbp
mov qword [rsp + 0x28], rsi
mov qword [rsp + 0x20], rax
mov dword [rsp + 0x30], 0
call qword [sym.imp.ADVAPI32.dll_RegQueryValueExW]
add rsp, 0x40
pop r12
pop rdi
pop rsi
pop rbp
pop rbx
ret

Function at 0x40c2d4
Capabilities:
Get system information on windows

Disassembly:
sub rsp, 0x68
lea rcx, [rsp + 0x20]
call fcn.0040c2ac
xor r8d, r8d
cmp eax, r8d
je 0x40c313
cmp qword [rsp + 0x20], r8
je 0x40c313
mov rcx, r8
lea eax, [r8 + 0x40]
mov rdx, qword [rsp + 0x20]
shr rdx, cl
inc rcx
and edx, 1
add r8d, edx
dec rax
jne 0x40c2f8
mov eax, r8d
jmp 0x40c322
lea rcx, [rsp + 0x30]
call qword [sym.imp.KERNEL32.dll_GetSystemInfo]
mov eax, dword [rsp + 0x50]
add rsp, 0x68
ret

Function at 0x40c328
Capabilities:
Get memory capacity

Disassembly:
push rbx
sub rsp, 0x60
movabs rax, 0x100000000
mov rbx, rcx
mov dword [rsp + 0x20], 0x40
mov qword [rcx], rax
lea rcx, [rsp + 0x20]
call qword [sym.imp.KERNEL32.dll_GlobalMemoryStatusEx]
test eax, eax
je 0x40c36a
mov rax, qword [rsp + 0x28]
cmp qword [rsp + 0x48], rax
cmovb rax, qword [rsp + 0x48]
mov qword [rbx], rax
mov al, 1
add rsp, 0x60
pop rbx
ret