joyce8/EMBER2024-capa huggingface dataset:
Function at 0x404e9c
Capabilities:
Get disk information

Disassembly:
push rbx
push rsi
push rdi
sub rsp, 0x460
mov rdi, rdx
mov edx, 0x104
lea rax, [rsp + 0x250]
mov dword [rsp + 0x38], edx
mov qword [rsp + 0x30], rax
mov rax, qword [rsp + 0x4a0]
mov qword [rsp + 0x28], rax
mov qword [rsp + 0x20], r9
mov r9, r8
mov r8d, edx
xor esi, esi
lea rdx, [rsp + 0x40]
mov word [rsp + 0x40], si
mov word [rsp + 0x250], si
call qword [sym.imp.KERNEL32.dll_GetVolumeInformationW]
lea rdx, [rsp + 0x40]
mov rcx, rdi
mov ebx, eax
call fcn.00402b10
mov rcx, qword [rsp + 0x4a8]
lea rdx, [rsp + 0x250]
call fcn.00402b10
cmp ebx, esi
setne al
add rsp, 0x460
pop rdi
pop rsi
pop rbx
ret

Function at 0x404f30
Capabilities:
Get disk size

Disassembly:
push rbx
push rbp
push rsi
push rdi
push r12
sub rsp, 0x50
mov rsi, r9
mov rbp, r8
mov rdi, rdx
lea r9, [rsp + 0x40]
lea r8, [rsp + 0x38]
lea rdx, [rsp + 0x48]
mov rbx, rcx
call qword [sym.imp.KERNEL32.dll_GetDiskFreeSpaceExW]
mov r10, qword [rsp + 0x38]
mov qword [rbp], r10
mov r10, qword [rsp + 0x40]
mov r12d, eax
lea rax, [rsp + 0x30]
lea r9, [rsp + 0x34]
lea r8, [rsp + 0x98]
lea rdx, [rsp + 0x90]
mov rcx, rbx
mov qword [rsi], r10
mov qword [rsp + 0x20], rax
call qword [sym.imp.KERNEL32.dll_GetDiskFreeSpaceW]
test eax, eax
je 0x404fcf
mov ecx, dword [rsp + 0x90]
mov eax, dword [rsp + 0x98]
imul rcx, rax
test r12d, r12d
mov qword [rdi], rcx
jne 0x404fcd
mov eax, dword [rsp + 0x30]
imul rax, rcx
mov qword [rbp], rax
mov eax, dword [rsp + 0x34]
imul rax, qword [rdi]
mov qword [rsi], rax
mov al, 1
add rsp, 0x50
pop r12
pop rdi
pop rsi
pop rbp
pop rbx
ret

Function at 0x40514c
Capabilities:
Connect network resource

Disassembly:
sub rsp, 0x58
mov r11, rdx
lea rdx, [rsp + 0x20]
mov r10, r8
call fcn.004050b4
lea rcx, [rsp + 0x20]
mov r8, r10
mov rdx, r11
call sub.MPR.dll_WNetAddConnection2W
add rsp, 0x58
ret
Function at 0x405440
Capabilities:
Get user security identifier

Disassembly:
push rbx
push rbp
push rsi
push rdi
mov r11, rsp
sub rsp, 0x48
lea rax, [r11 + 0x40]
mov rsi, rcx
mov rdx, rcx
mov qword [r11 - 0x18], rax
lea rax, [r11 + 0x30]
lea r9, [r11 + 0x38]
mov qword [r11 - 0x20], rax
xor r8d, r8d
xor ecx, ecx
mov dword [r11 + 0x38], 0
mov dword [rsp + 0x78], 0
mov qword [r11 - 0x28], 0
call qword [sym.imp.ADVAPI32.dll_LookupAccountNameW]
test eax, eax
jne 0x405534
call qword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 0x7a
jne 0x405534
mov ebx, dword [rsp + 0x80]
call qword [sym.imp.KERNEL32.dll_GetProcessHeap]
mov edi, 8
mov r8, rbx
mov edx, edi
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_HeapAlloc]
mov ebx, dword [rsp + 0x78]
inc ebx
mov rbp, rax
add rbx, rbx
call qword [sym.imp.KERNEL32.dll_GetProcessHeap]
mov r8, rbx
mov rcx, rax
mov edx, edi
call qword [sym.imp.KERNEL32.dll_HeapAlloc]
lea r9, [rsp + 0x80]
mov r8, rbp
mov rdi, rax
lea rax, [rsp + 0x88]
mov rdx, rsi
mov qword [rsp + 0x30], rax
lea rax, [rsp + 0x78]
xor ecx, ecx
mov qword [rsp + 0x28], rax
mov qword [rsp + 0x20], rdi
call qword [sym.imp.ADVAPI32.dll_LookupAccountNameW]
mov ebx, eax
call qword [sym.imp.KERNEL32.dll_GetProcessHeap]
mov r8, rdi
mov rcx, rax
xor edx, edx
call qword [sym.imp.KERNEL32.dll_HeapFree]
test ebx, ebx
je 0x405534
mov rax, rbp
jmp 0x405536
xor eax, eax
add rsp, 0x48
pop rdi
pop rsi
pop rbp
pop rbx
ret

Function at 0x405540
Capabilities:
Get session user name
Manipulate user privileges

Disassembly:
push rbx
push rbp
push rsi
push rdi
mov rax, rsp
sub rsp, 0x378
xor ebp, ebp
lea r9, [rax + 0x30]
lea rdx, [rsp + 0x30]
mov r8d, 0xf0fff
xor ecx, ecx
mov dword [rsp + 0x30], 0x30
mov qword [rax + 0x30], rbp
mov qword [rsp + 0x38], rbp
mov qword [rsp + 0x40], rbp
mov dword [rsp + 0x48], ebp
mov qword [rsp + 0x50], rbp
mov qword [rsp + 0x58], rbp
call sub.ADVAPI32.dll_LsaOpenPolicy
cmp eax, ebp
je 0x40559c
mov rcx, qword [rsp + 0x3a8]
jmp 0x405634
lea rcx, [rsp + 0x60]
lea rdx, [0x0049cc60]
mov r8d, 0x2c
call sub.msvcrt.dll_memcpy
lea rcx, [rsp + 0x8c]
xor edx, edx
mov r8d, 0xd4
call sub.msvcrt.dll_memset
lea rcx, [rsp + 0x60]
call qword [sym.imp.msvcrt.dll_wcslen]
lea rdx, [rsp + 0x3a0]
lea rcx, [rsp + 0x160]
add ax, ax
mov dword [rsp + 0x3a0], 0x100
mov word [rsp + 0x20], ax
add ax, 2
mov word [rsp + 0x22], ax
lea rax, [rsp + 0x60]
mov qword [rsp + 0x28], rax
call qword [sym.imp.ADVAPI32.dll_GetUserNameW]
cmp eax, ebp
je 0x40558f
lea rcx, [rsp + 0x160]
call fcn.00405440
mov rcx, qword [rsp + 0x3a8]
cmp rax, rbp
mov rbx, rax
jne 0x405642
cmp rcx, rbp
je 0x40563e
call sub.ADVAPI32.dll_LsaClose
xor al, al
jmp 0x405689
mov esi, 1
lea r8, [rsp + 0x20]
mov rdx, rax
mov r9d, esi
call sub.ADVAPI32.dll_LsaAddAccountRights
movzx edi, bpl
cmp eax, ebp
cmove edi, esi
call qword [sym.imp.KERNEL32.dll_GetProcessHeap]
mov r8, rbx
mov rcx, rax
xor edx, edx
call qword [sym.imp.KERNEL32.dll_HeapFree]
mov rcx, qword [rsp + 0x3a8]
cmp rcx, rbp
je 0x405686
call sub.ADVAPI32.dll_LsaClose
mov al, dil
add rsp, 0x378
pop rdi
pop rsi
pop rbp
pop rbx
ret
Function at 0x4056ec
Capabilities:
Open clipboard
Write clipboard data

Disassembly:
push rbx
push rbp
push rsi
push rdi
sub rsp, 0x28
mov rdi, rdx
call qword [sym.imp.USER32.dll_OpenClipboard]
xor ebx, ebx
cmp eax, ebx
setne al
cmp al, bl
mov byte [rsp + 0x60], al
je 0x4057a3
call qword [sym.imp.USER32.dll_EmptyClipboard]
cmp eax, ebx
je 0x4057a3
mov esi, dword [rdi + 8]
mov rbp, qword [rdi]
lea rcx, [rsp + 0x68]
inc esi
mov edx, 0x2002
mov qword [rsp + 0x68], rbx
add rsi, rsi
mov r8, rsi
call fcn.0040af74
cmp al, bl
jne 0x40574c
lea rcx, [rsp + 0x68]
jmp 0x405790
mov rdi, qword [rsp + 0x68]
mov rcx, rdi
call qword [sym.imp.KERNEL32.dll_GlobalLock]
cmp rax, rbx
je 0x405745
mov r8, rsi
mov rdx, rbp
mov rcx, rax
call sub.msvcrt.dll_memcpy
mov rcx, rdi
call qword [sym.imp.KERNEL32.dll_GlobalUnlock]
mov rdx, qword [rsp + 0x68]
mov ecx, InitCommonControls
call qword [sym.imp.USER32.dll_SetClipboardData]
lea rcx, [rsp + 0x68]
cmp rax, rbx
jne 0x405797
call fcn.0040af9c
jmp 0x4057a3
mov qword [rsp + 0x68], rbx
call fcn.0040af9c
mov bl, 1
lea rcx, [rsp + 0x60]
call fcn.004056bc
mov al, bl
add rsp, 0x28
pop rdi
pop rsi
pop rbp
pop rbx
ret

Function at 0x405d28
Capabilities:
Get common file path

Disassembly:
push rbx
push rsi
push rdi
sub rsp, 0x250
mov rbx, rcx
lea rcx, [rsp + 0x20]
xor edi, edi
mov edx, 0x114
mov word [rsp + 0x20], di
call qword [sym.imp.KERNEL32.dll_GetWindowsDirectoryW]
lea rdx, [rsp + 0x20]
mov rcx, rbx
mov esi, eax
call fcn.00402b10
cmp esi, edi
je 0x405d6d
cmp esi, 0x114
jae 0x405d6d
mov edi, 1
mov al, dil
add rsp, 0x250
pop rdi
pop rsi
pop rbx
ret

Function at 0x405f4c
Capabilities:
Set file attributes

Disassembly:
test edx, 0xf0000000
je 0x405f5a
and edx, 0x3fff
jmp fcn.00405ea4

Function at 0x405f60
Capabilities:
Delete directory

Disassembly:
push rbx
push rdi
sub rsp, 0x48
mov qword [rsp + 0x20], 0xfffffffffffffffe
mov rdi, rcx
call fcn.0040a510
mov ebx, eax
cmp eax, 1
je 0x405f90
mov rcx, rdi
call qword [sym.imp.KERNEL32.dll_RemoveDirectoryW]
test eax, eax
je 0x405f90
mov al, 1
jmp 0x405fe1
test ebx, ebx
je 0x405fdf
lea rcx, [rsp + 0x28]
call fcn.004028fc
nop
cmp ebx, 1
setne r8b
lea rdx, [rsp + 0x28]
mov rcx, rdi
call fcn.0040abdc
test al, al
je 0x405fd5
mov rcx, qword [rsp + 0x28]
call qword [sym.imp.KERNEL32.dll_RemoveDirectoryW]
test eax, eax
setne bl
mov rcx, qword [rsp + 0x28]
call sub.msvcrt.dll_free
mov al, bl
jmp 0x405fe1
mov rcx, qword [rsp + 0x28]
call sub.msvcrt.dll_free
xor al, al
add rsp, 0x48
pop rdi
pop rbx
ret
Function at 0x406008
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.0040a510
mov esi, eax
mov rcx, rbp
call fcn.0040a510
mov edi, eax
mov ebx, 1
cmp esi, ebx
je 0x406057
cmp eax, ebx
je 0x406057
mov rdx, rbp
mov rcx, r12
call qword [sym.imp.KERNEL32.dll_MoveFileW]
test eax, eax
je 0x406057
mov al, bl
jmp 0x4060e5
test esi, esi
jne 0x406063
test edi, edi
je 0x4060e3
lea rcx, [rsp + 0x48]
call fcn.004028fc
nop
lea rcx, [rsp + 0x38]
call fcn.004028fc
nop
cmp esi, ebx
je 0x406081
cmp edi, ebx
jne 0x406083
xor bl, bl
mov byte [rsp + 0x20], bl
lea r9, [rsp + 0x38]
lea r8, [rsp + 0x48]
mov rdx, rbp
mov rcx, r12
call fcn.0040ac24
test al, al
je 0x4060ce
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 sub.msvcrt.dll_free
nop
mov rcx, qword [rsp + 0x48]
call sub.msvcrt.dll_free
mov al, bl
jmp 0x4060e5
mov rcx, qword [rsp + 0x38]
call sub.msvcrt.dll_free
nop
mov rcx, qword [rsp + 0x48]
call sub.msvcrt.dll_free
xor al, al
add rsp, 0x60
pop r12
pop rdi
pop rsi
pop rbp
pop rbx
ret

Function at 0x406258
Capabilities:
Create directory

Disassembly:
push rbx
push rdi
sub rsp, 0x48
mov qword [rsp + 0x20], 0xfffffffffffffffe
mov rdi, rcx
call fcn.0040a510
mov ebx, eax
cmp eax, 1
je 0x406297
xor edx, edx
mov rcx, rdi
call qword [sym.imp.KERNEL32.dll_CreateDirectoryW]
test eax, eax
je 0x40628a
mov al, 1
jmp 0x4062ea
call qword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 0xb7
je 0x4062e8
test ebx, ebx
je 0x4062e8
lea rcx, [rsp + 0x28]
call fcn.004028fc
nop
cmp ebx, 1
setne r8b
lea rdx, [rsp + 0x28]
mov rcx, rdi
call fcn.0040abdc
test al, al
je 0x4062de
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 sub.msvcrt.dll_free
mov al, bl
jmp 0x4062ea
mov rcx, qword [rsp + 0x28]
call sub.msvcrt.dll_free
xor al, al
add rsp, 0x48
pop rdi
pop rbx
ret

Function at 0x406310
Capabilities:
Delete file

Disassembly:
push rbx
push rdi
sub rsp, 0x48
mov qword [rsp + 0x20], 0xfffffffffffffffe
mov rbx, rcx
call fcn.00407634
cmp eax, 0xffffffff
je 0x406346
test al, 0x10
jne 0x406346
test al, 1
je 0x406346
and eax, 0xfffffffe
mov edx, eax
mov rcx, rbx
call fcn.00405ea4
test al, al
je 0x4063b7
mov rcx, rbx
call fcn.0040a510
mov edi, eax
cmp eax, 1
je 0x406366
mov rcx, rbx
call qword [sym.imp.KERNEL32.dll_DeleteFileW]
test eax, eax
je 0x406366
mov al, 1
jmp 0x4063b7
test edi, edi
je 0x4063b5
lea rcx, [rsp + 0x28]
call fcn.004028fc
nop
cmp edi, 1
setne r8b
lea rdx, [rsp + 0x28]
mov rcx, rbx
call fcn.0040abdc
test al, al
je 0x4063ab
mov rcx, qword [rsp + 0x28]
call qword [sym.imp.KERNEL32.dll_DeleteFileW]
test eax, eax
setne bl
mov rcx, qword [rsp + 0x28]
call sub.msvcrt.dll_free
mov al, bl
jmp 0x4063b7
mov rcx, qword [rsp + 0x28]
call sub.msvcrt.dll_free
xor al, al
add rsp, 0x48
pop rdi
pop rbx
ret
Function at 0x4063e0
Capabilities:
Get common file path

Disassembly:
push rbx
push rdi
sub rsp, 0x278
mov qword [rsp + 0x30], 0xfffffffffffffffe
mov rdi, rcx
mov dword [rcx + 8], 0
mov rax, qword [rcx]
mov word [rax], 0
mov word [rsp + 0x40], 0
lea rdx, [rsp + 0x40]
mov ecx, 0x114
call qword [sym.imp.KERNEL32.dll_GetCurrentDirectoryW]
mov ebx, eax
test eax, eax
je 0x4064e2
cmp ebx, 0x114
jae 0x40644c
mov word [rsp + 0x268], 0
lea rdx, [rsp + 0x40]
mov rcx, rdi
call fcn.00402b10
mov al, 1
jmp 0x4064e2
lea rcx, [rsp + 0x20]
call fcn.004028fc
nop
cmp ebx, dword [rsp + 0x2c]
jbe 0x406469
mov edx, ebx
lea rcx, [rsp + 0x20]
call fcn.00402588
mov rdx, qword [rsp + 0x20]
mov ecx, ebx
call qword [sym.imp.KERNEL32.dll_GetCurrentDirectoryW]
mov r11d, eax
test eax, eax
jne 0x40648b
mov rcx, qword [rsp + 0x20]
call sub.msvcrt.dll_free
xor al, al
jmp 0x4064e2
mov rcx, qword [rsp + 0x20]
mov word [rcx + rbx*2], 0
xor eax, eax
cmp word [rcx], ax
je 0x4064a9
inc eax
add rcx, 2
cmp word [rcx], 0
jne 0x40649d
mov dword [rsp + 0x28], eax
cmp eax, r11d
jne 0x4064d6
lea eax, [rbx - 1]
cmp eax, r11d
jne 0x4064d6
lea rdx, [rsp + 0x20]
mov rcx, rdi
call fcn.00402b78
nop
mov rcx, qword [rsp + 0x20]
call sub.msvcrt.dll_free
mov al, 1
jmp 0x4064e2
mov rcx, qword [rsp + 0x20]
call sub.msvcrt.dll_free
xor al, al
add rsp, 0x278
pop rdi
pop rbx
ret

Function at 0x4065d4
Capabilities:
Get common file path

Disassembly:
push rbx
push rsi
push rdi
sub rsp, 0x250
mov rbx, rcx
lea rdx, [rsp + 0x20]
xor edi, edi
mov ecx, 0x114
mov word [rsp + 0x20], di
call qword [sym.imp.KERNEL32.dll_GetTempPathW]
lea rdx, [rsp + 0x20]
mov rcx, rbx
mov esi, eax
call fcn.00402b10
mov rcx, rbx
call fcn.00409d70
cmp esi, edi
je 0x406621
cmp esi, 0x114
jae 0x406621
mov edi, 1
mov al, dil
add rsp, 0x250
pop rdi
pop rsi
pop rbx
ret
Function at 0x406630
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, 0x58
mov qword [rsp + 0x20], 0xfffffffffffffffe
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
mov ebx, edi
lea r15d, [rdi + 1]
mov dword [rsi + 8], edi
mov rcx, qword [rsi]
mov byte [rcx], dil
cmp r12b, dil
je 0x4066f8
mov r10d, r13d
mov r9, rdi
mov r11d, 8
mov r8d, r10d
and r8d, 0xf
shr r10d, 4
lea edx, [r8 + 0x30]
lea eax, [r8 + 0x37]
movzx ecx, al
movzx eax, dl
cmp r8d, 0xa
cmovb ecx, eax
mov byte [rsp + r9 + 0x38], cl
add r9, r15
sub r11, r15
jne 0x40669c
mov byte [rsp + r9 + 0x38], dil
cmp rbp, rdi
je 0x4066db
mov rcx, rsi
call fcn.004031a8
lea rdx, [rsp + 0x38]
mov rcx, rsi
call fcn.004023b4
call qword [sym.imp.KERNEL32.dll_GetTickCount]
add eax, 2
cmove eax, r15d
add r13d, eax
mov r12b, r15b
cmp rbp, rdi
je 0x40670f
lea rdx, str..tmp
mov rcx, rsi
call fcn.004023b4
mov rdx, r14
lea rcx, [rsp + 0x28]
call fcn.00402998
nop
mov rdx, qword [rsi]
lea rcx, [rsp + 0x28]
call fcn.00402db8
mov rcx, qword [rsp + 0x28]
call fcn.00408304
cmp al, dil
je 0x406751
mov ecx, 0xb7
call qword [sym.imp.KERNEL32.dll_SetLastError]
nop
mov rcx, qword [rsp + 0x28]
call sub.msvcrt.dll_free
jmp 0x406798
cmp rbp, rdi
je 0x40676d
mov r8d, r15d
mov rdx, qword [rsp + 0x28]
mov rcx, rbp
call fcn.004090a8
cmp al, dil
jne 0x4067a6
jmp 0x40677c
mov rcx, qword [rsp + 0x28]
call fcn.00406258
cmp al, dil
jne 0x4067b5
call qword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 0x50
je 0x40678e
cmp eax, 0xb7
jne 0x4067c4
mov rcx, qword [rsp + 0x28]
call sub.msvcrt.dll_free
add ebx, r15d
cmp ebx, 0x64
jb 0x406682
jmp 0x4067ce
mov rcx, qword [rsp + 0x28]
call sub.msvcrt.dll_free
mov al, r15b
jmp 0x4067d9
mov rcx, qword [rsp + 0x28]
call sub.msvcrt.dll_free
mov al, r15b
jmp 0x4067d9
mov rcx, qword [rsp + 0x28]
call sub.msvcrt.dll_free
mov dword [rsi + 8], edi
mov rax, qword [rsi]
mov byte [rax], dil
xor al, al
add rsp, 0x58
pop r15
pop r14
pop r13
pop r12
pop rdi
pop rsi
pop rbp
pop rbx
ret
Function at 0x407634
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.0040a510
mov ebx, eax
cmp eax, 1
je 0x407661
mov rcx, rdi
call qword [sym.imp.KERNEL32.dll_GetFileAttributesW]
cmp eax, 0xffffffff
jne 0x4076b2
test ebx, ebx
je 0x4076ad
lea rcx, [rsp + 0x28]
call fcn.004028fc
nop
cmp ebx, 1
setne r8b
lea rdx, [rsp + 0x28]
mov rcx, rdi
call fcn.0040abdc
test al, al
je 0x4076a3
mov rcx, qword [rsp + 0x28]
call qword [sym.imp.KERNEL32.dll_GetFileAttributesW]
mov ebx, eax
mov rcx, qword [rsp + 0x28]
call sub.msvcrt.dll_free
mov eax, ebx
jmp 0x4076b2
mov rcx, qword [rsp + 0x28]
call sub.msvcrt.dll_free
mov eax, 0xffffffff
add rsp, 0x48
pop rdi
pop rbx
ret

Function at 0x408444
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 0x408494
shl rdi, 3
add ebx, 0xffffffff
sub rdi, 8
mov rax, qword [rbp]
mov rsi, qword [rdi + rax]
test rsi, rsi
je 0x408490
mov rcx, qword [rsi]
call sub.msvcrt.dll_free
mov rcx, rsi
call sub.msvcrt.dll_free
test ebx, ebx
jne 0x40846c
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 0x408599
mov rcx, rdi
xor ebx, ebx
mov qword [rsp + 0x80], rbx
test eax, eax
je 0x4084d3
add rcx, rcx
call fcn.00403810
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 0x40858f
cmp eax, edi
ja 0x40858f
lea rcx, [rsp + 0x28]
call fcn.004028fc
nop
xor r13d, r13d
xor edi, edi
test esi, esi
je 0x408570
mov r12, rbx
cmp word [r12], 0
jne 0x408566
lea rdx, [rbx + r13*2]
lea rcx, [rsp + 0x28]
call fcn.00402b10
lea r13d, [rdi + 1]
mov rcx, rbp
call fcn.00423f68
mov ecx, InitCommonControls
call fcn.00403810
mov qword [rsp + 0x88], rax
test rax, rax
je 0x408552
lea rdx, [rsp + 0x28]
mov rcx, rax
call fcn.00402a88
mov r11, rax
jmp 0x408555
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 0x408507
cmp r13d, esi
sete dil
mov rcx, qword [rsp + 0x28]
call sub.msvcrt.dll_free
nop
mov rcx, rbx
call sub.msvcrt.dll_free
mov al, dil
jmp 0x408599
mov rcx, rbx
call sub.msvcrt.dll_free
xor al, al
add rsp, 0x48
pop r13
pop r12
pop rdi
pop rsi
pop rbp
pop rbx
ret
Function at 0x408668
Capabilities:
Get file size

Disassembly:
push rbx
push rdi
sub rsp, 0x28
cmp byte [rcx + 9], 0
mov rbx, rdx
je 0x408687
cmp byte [rcx + 0xa], 0
je 0x408687
mov rax, qword [rcx + 0x10]
mov qword [rdx], rax
jmp 0x4086c3
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 0x4086b2
call qword [sym.imp.KERNEL32.dll_GetLastError]
test eax, eax
je 0x4086b2
xor al, al
jmp 0x4086c5
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 0x4087e8
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 0x408824
Capabilities:
Read file on windows

Disassembly:
mov eax, 0x400000
cmp r8d, eax
cmova r8d, eax
jmp fcn.004087e8

Function at 0x408958
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 0x408a6c
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.00408728
xor ebx, ebx
cmp al, bl
je 0x408a94
cmp qword [rsp + 0x50], rdi
je 0x408a98
xor al, al
jmp 0x408aa6
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 0x40b3a0
Capabilities:
Create process on windows

Disassembly:
push rbx
push rbp
push rsi
push rdi
sub rsp, 0x128
mov qword [rsp + 0xa8], 0xfffffffffffffffe
mov rdi, r9
mov rsi, r8
mov rbp, rdx
mov rbx, rcx
mov rcx, qword [rcx]
test rcx, rcx
je 0x40b3dd
call qword [sym.imp.KERNEL32.dll_CloseHandle]
test eax, eax
je 0x40b3dd
mov qword [rbx], 0
mov rdx, rbp
lea rcx, [rsp + 0x60]
call fcn.00402998
nop
lea rdx, [rsp + 0x60]
lea rcx, [rsp + 0x80]
call fcn.00451b00
nop
mov r8w, 0x20
mov rdx, rax
lea rcx, [rsp + 0x70]
call fcn.0040b380
nop
mov r8, rsi
mov rdx, rax
lea rcx, [rsp + 0x50]
call fcn.00402838
nop
mov rcx, qword [rsp + 0x70]
call sub.msvcrt.dll_free
nop
mov rcx, qword [rsp + 0x80]
call sub.msvcrt.dll_free
nop
mov rcx, qword [rsp + 0x60]
call sub.msvcrt.dll_free
mov dword [rsp + 0xb0], 0x68
mov qword [rsp + 0xb8], 0
mov qword [rsp + 0xc0], 0
mov qword [rsp + 0xc8], 0
mov dword [rsp + 0xec], 0
mov word [rsp + 0xf2], 0
mov qword [rsp + 0xf8], 0
lea rax, [rsp + 0x90]
mov qword [rsp + 0x48], rax
lea rax, [rsp + 0xb0]
mov qword [rsp + 0x40], rax
mov qword [rsp + 0x38], rdi
mov qword [rsp + 0x30], 0
mov dword [rsp + 0x28], 0
mov dword [rsp + 0x20], 0
xor r9d, r9d
xor r8d, r8d
mov rdx, qword [rsp + 0x50]
xor ecx, ecx
call qword [sym.imp.KERNEL32.dll_CreateProcessW]
test eax, eax
jne 0x40b4ee
call qword [sym.imp.KERNEL32.dll_GetLastError]
mov ebx, eax
jmp 0x40b509
mov rcx, qword [rsp + 0x98]
call qword [sym.imp.KERNEL32.dll_CloseHandle]
mov r11, qword [rsp + 0x90]
mov qword [rbx], r11
xor ebx, ebx
mov rcx, qword [rsp + 0x50]
call sub.msvcrt.dll_free
mov eax, ebx
add rsp, 0x128
pop rdi
pop rsi
pop rbp
pop rbx
ret

Function at 0x40c0ac
Capabilities:
Set registry value

Disassembly:
mov dword [rsp + 0x18], r8d
sub rsp, 0x38
mov rcx, qword [rcx]
lea rax, [rsp + 0x50]
mov r9d, 4
mov dword [rsp + 0x28], r9d
xor r8d, r8d
mov qword [rsp + 0x20], rax
call qword [sym.imp.ADVAPI32.dll_RegSetValueExW]
add rsp, 0x38
ret

Function at 0x40c0dc
Capabilities:
Set registry value

Disassembly:
mov al, r8b
xor r8d, r8d
cmp al, r8b
setne r8b
jmp fcn.0040c0ac

Function at 0x40c0f0
Capabilities:
Set registry value

Disassembly:
push rbx
push rsi
push rdi
sub rsp, 0x30
mov rsi, rcx
mov rcx, r8
mov rbx, r8
mov rdi, rdx
call qword [sym.imp.KERNEL32.dll_lstrlenW]
mov rcx, qword [rsi]
lea eax, [rax + rax + 2]
mov r9d, 1
xor r8d, r8d
mov dword [rsp + 0x28], eax
mov rdx, rdi
mov qword [rsp + 0x20], rbx
call qword [sym.imp.ADVAPI32.dll_RegSetValueExW]
add rsp, 0x30
pop rdi
pop rsi
pop rbx
ret

Function at 0x40c134
Capabilities:
Set registry value

Disassembly:
sub rsp, 0x38
mov rcx, qword [rcx]
mov dword [rsp + 0x28], r9d
mov qword [rsp + 0x20], r8
mov r9d, 3
xor r8d, r8d
call qword [sym.imp.ADVAPI32.dll_RegSetValueExW]
add rsp, 0x38
ret

Function at 0x40c15c
Capabilities:
Query or enumerate registry value

Disassembly:
mov r11, rsp
sub rsp, 0x48
mov rcx, qword [rcx]
lea rax, [r11 + 0x20]
lea r9, [r11 - 0x18]
mov qword [r11 - 0x20], rax
mov qword [r11 - 0x28], r8
xor r8d, r8d
mov dword [rsp + 0x30], 0
mov dword [rsp + 0x68], 4
call qword [sym.imp.ADVAPI32.dll_RegQueryValueExW]
add rsp, 0x48
ret
Function at 0x40c210
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 0x40c26f
cmp eax, 0xea
jne 0x40c2e5
mov edx, dword [rsp + 0x70]
cmp edx, dword [rbx + 0xc]
mov dword [rsp + 0x78], edx
jbe 0x40c284
mov rcx, rbx
call fcn.00402588
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 0x40c2e2
add rdx, 2
inc ecx
cmp word [rdx], 0
jne 0x40c2d6
mov dword [rbx + 8], ecx
add rsp, 0x40
pop rdi
pop rsi
pop rbx
ret

Function at 0x40c3e4
Capabilities:
Delete registry key
Query or enumerate registry key

Disassembly:
push rbx
push rsi
push rdi
mov rax, rsp
sub rsp, 0x260
mov rdi, rdx
mov r8, rdx
mov rdx, qword [rcx]
mov rsi, rcx
lea rcx, [rax + 0x38]
mov r9d, 0x2001f
mov qword [rax + 0x38], 0
call fcn.0040c390
test eax, eax
mov ebx, eax
jne 0x40c498
mov ebx, 0x105
jmp 0x40c430
lea rdx, [rsp + 0x50]
call fcn.0040c3e4
test eax, eax
jne 0x40c496
mov rcx, qword [rsp + 0x298]
lea rax, [rsp + 0x40]
lea r9, [rsp + 0x290]
mov qword [rsp + 0x38], rax
mov qword [rsp + 0x30], 0
lea r8, [rsp + 0x50]
xor edx, edx
mov qword [rsp + 0x28], 0
mov dword [rsp + 0x290], ebx
mov qword [rsp + 0x20], 0
call qword [sym.imp.ADVAPI32.dll_RegEnumKeyExW]
lea rcx, [rsp + 0x298]
test eax, eax
je 0x40c422
call fcn.0040c078
mov rcx, qword [rsi]
mov rdx, rdi
call qword [sym.imp.ADVAPI32.dll_RegDeleteKeyW]
mov ebx, eax
lea rcx, [rsp + 0x298]
call fcn.0040c078
mov eax, ebx
add rsp, 0x260
pop rdi
pop rsi
pop rbx
ret