joyce8/EMBER2024-capa huggingface dataset:
Function at 0x45c080
Capabilities:
Encrypt data using aes via x86 extensions

Disassembly:
mov rax, qword [rax]
movabs rcx, 0xe7037ed1a0b428db
xor rcx, rax
xor rax, rbx
xor rax, qword [0x00593160]
movabs rdx, 0xa0761d6478bd642f
xor rdx, rax
mov rax, rcx
mul rdx
xor rax, rdx
mov rcx, rax
movabs rax, 0x1d8e4e27c47d1247
mul rcx
nop
nop
xor rax, rdx
ret
cmp byte [0x00592ed3], 0
je 0x45c0b6
movq xmm0, rbx
pinsrq xmm0, qword [rax], 1
aesenc xmm0, xmmword [0x005933e0]
aesenc xmm0, xmmword [0x005933f0]
aesenc xmm0, xmmword [0x00593400]
movq rax, xmm0
ret
jmp 0x408aa0

Function at 0x45d9e0
Capabilities:
Write file on windows

Disassembly:
sub rsp, 0x30
mov rcx, 0xfffffffffffffff4
mov qword [rsp], rcx
mov rax, qword [sym.imp.kernel32.dll_GetStdHandle]
call rax
mov rcx, rax
mov qword [rsp], rcx
lea rdx, [0x00593360]
mov qword [rsp + 8], rdx
lea r8d, [0x00592ee8]
mov qword [rsp + 0x10], r8
lea r9, [rsp + 0x28]
mov qword [r9], 0
mov qword [rsp + 0x18], r9
mov qword [rsp + 0x20], 0
mov rax, qword [sym.imp.kernel32.dll_WriteFile]
call rax
call fcn.0045bf80
add rsp, 0x30
ret

Function at 0x45e820
Capabilities:
Access peb ldr_data

Disassembly:
sub rsp, 0x78
mov qword [rsp + 0x70], rbp
lea rbp, [rsp + 0x70]
mov qword [rsp], rax
mov qword [rsp + 8], rbx
mov qword [rsp + 0x10], rcx
mov qword [rsp + 0x18], rdi
mov qword [rsp + 0x20], rsi
mov qword [rsp + 0x28], r8
mov qword [rsp + 0x30], r9
mov qword [rsp + 0x38], r10
mov qword [rsp + 0x40], r11
mov rax, qword [rsp + 0x80]
mov qword [rsp + 0x48], rax
mov rax, qword [rsp + 0x88]
mov qword [rsp + 0x50], rax
call fcn.00458c80
xorps xmm15, xmm15
mov r14, qword gs:[0x28]
mov r14, qword [r14]
mov rax, qword [rsp + 0x58]
mov rbx, qword [rsp + 0x60]
mov rcx, qword [rsp + 0x68]
mov rbp, qword [rsp + 0x70]
add rsp, 0x78
ret

Function at 0x45e8c0
Capabilities:
Access peb ldr_data

Disassembly:
sub rsp, 0x90
mov qword [rsp + 0x88], rbp
lea rbp, [rsp + 0x88]
mov qword [rsp], rax
mov qword [rsp + 8], rbx
mov qword [rsp + 0x10], rcx
mov qword [rsp + 0x18], rdi
mov qword [rsp + 0x20], rsi
mov qword [rsp + 0x28], r8
mov qword [rsp + 0x30], r9
mov qword [rsp + 0x38], r10
mov qword [rsp + 0x40], r11
mov rax, qword [rsp + 0x98]
mov qword [rsp + 0x48], rax
mov rax, qword [rsp + 0xa0]
mov qword [rsp + 0x50], rax
mov rax, qword [rsp + 0xa8]
mov qword [rsp + 0x58], rax
mov rax, qword [rsp + 0xb0]
mov qword [rsp + 0x60], rax
mov rax, qword [rsp + 0xb8]
mov qword [rsp + 0x68], rax
call fcn.00458dc0
xorps xmm15, xmm15
mov r14, qword gs:[0x28]
mov r14, qword [r14]
mov rax, qword [rsp + 0x70]
mov rbx, qword [rsp + 0x78]
mov rcx, qword [rsp + 0x80]
mov rbp, qword [rsp + 0x88]
add rsp, 0x90
ret
Function at 0x140001000
Capabilities:
Terminate process

Disassembly:
mov qword [rsp + 8], rbx
mov qword [rsp + 0x10], rsi
push rdi
sub rsp, 0x920
mov eax, dword [0x14002bd68]
mov rdi, rcx
cmp dword [rcx], eax
je 0x1400010cc
mov rax, qword [0x14002bd60]
xor ebx, ebx
cmp rax, rbx
je 0x14000104f
cmp word [0x14002bd62], bx
je 0x140001043
call rax
mov qword [0x14002bd60], rax
mov ecx, eax
call fcn.140002bb4
mov rcx, rax
jmp 0x1400010b6
mov ecx, 0x27
call fcn.140002bb4
mov r9, qword [rdi + 0x10]
mov r8d, dword [rdi]
lea rcx, [rsp + 0x120]
mov rdx, rax
call qword [sym.imp.USER32.dll_wsprintfW]
cmp dword [rdi + 0x18], ebx
jbe 0x1400010ae
lea rsi, [rdi + 0x20]
mov r8, qword [rsi]
lea rdx, str._t0x_p_n
lea rcx, [rsp + 0x20]
call qword [sym.imp.USER32.dll_wsprintfW]
lea rdx, [rsp + 0x20]
lea rcx, [rsp + 0x120]
call qword [sym.imp.KERNEL32.dll_lstrcatW]
add ebx, 1
add rsi, 8
cmp ebx, dword [rdi + 0x18]
jb 0x14000107a
lea rcx, [rsp + 0x120]
call fcn.14000d1cc
call fcn.1400062f0
mov ecx, 0xa
call qword [sym.imp.KERNEL32.dll_ExitProcess]
lea r11, [rsp + 0x920]
mov rbx, qword [r11 + 0x10]
mov rsi, qword [r11 + 0x18]
mov rsp, r11
pop rdi
ret
Function at 0x140001b04
Capabilities:
Create thread

Disassembly:
mov qword [rsp + 0x18], rbx
mov qword [rsp + 0x20], rsi
push rdi
sub rsp, 0x30
test rdx, rdx
mov rsi, r8
mov rbx, rdx
mov rdi, rcx
je 0x140001b2a
mov rax, qword [rdx]
mov rcx, rdx
call qword [rax + VariantCopy]
mov rcx, qword [rdi + 0x18]
test rcx, rcx
je 0x140001b39
mov rax, qword [rcx]
call qword [rax + InitCommonControls]
lea rcx, [rdi + 0x20]
mov rdx, rsi
mov qword [rdi + 0x18], rbx
call fcn.1400014a0
lea rcx, [rdi + 0x20]
mov dx, 0x5c
call fcn.1400018e8
and dword [0x14002bd80], 0
lea rax, [rsp + 0x48]
mov qword [rsp + 0x28], rax
and dword [rsp + 0x20], 0
lea r8, [0x140001380]
mov r9, rdi
xor edx, edx
xor ecx, ecx
mov qword [0x14002bd70], rdi
call qword [sym.imp.KERNEL32.dll_CreateThread]
cmp dword [0x14002be00], 2
mov qword [0x14002bd78], rax
je 0x140001ba3
call fcn.14000c544
mov rax, qword [0x14002bd78]
or edx, 0xffffffff
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_WaitForSingleObject]
mov r8d, dword [0x14002bd80]
and qword [0x14002bec8], 0
test r8d, r8d
je 0x140001c12
cmp r8d, 1
je 0x140001c04
cmp r8d, 2
je 0x140001bfd
cmp r8d, 3
je 0x140001bf6
cmp r8d, 0x67
jle 0x140001be5
cmp r8d, 0x6b
jle 0x140001c7d
mov edx, 0x14
xor ecx, ecx
call fcn.14000d328
jmp 0x140001c7d
mov edx, 0x12
jmp 0x140001c09
mov edx, 0x13
jmp 0x140001c09
mov edx, reloc.COMCTL32.dll_InitCommonControls
xor ecx, ecx
call fcn.14000d328
jmp 0x140001c7d
cmp dword [0x14002bec4], 0
jne 0x140001c7d
mov rcx, qword [0x14002bd78]
lea rdx, [rsp + 0x40]
call qword [sym.imp.KERNEL32.dll_GetExitCodeThread]
mov ecx, dword [rsp + 0x40]
test eax, eax
je 0x140001c3d
test ecx, ecx
jne 0x140001c3d
xor eax, eax
jmp 0x140001c82
mov edx, 0x80070000
mov eax, ecx
and eax, edx
cmp eax, edx
je 0x140001c54
mov r8d, ecx
mov edx, 0x21
jmp 0x140001bea
movzx ecx, cx
cmp ecx, 0xe
jne 0x140001c65
cmp dword [0x14002be04], 0xffffffff
je 0x140001c7d
call qword [sym.imp.KERNEL32.dll_SetLastError]
mov r8d, dword [rsp + 0x40]
mov edx, 0x22
lea ecx, [rdx - 0x21]
call fcn.14000d328
mov eax, 0x80004005
mov rbx, qword [rsp + 0x50]
mov rsi, qword [rsp + 0x58]
add rsp, 0x30
pop rdi
ret

Function at 0x140002348
Capabilities:
Check if file exists
Create directory
Get file attributes

Disassembly:
push rbx
sub rsp, 0x20
xor edx, edx
mov rbx, rcx
call qword [sym.imp.KERNEL32.dll_CreateDirectoryW]
test eax, eax
jne 0x14000238f
call qword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 0xb7
je 0x140002376
mov ecx, eax
call qword [sym.imp.KERNEL32.dll_SetLastError]
xor eax, eax
jmp 0x140002394
mov rcx, rbx
call qword [sym.imp.KERNEL32.dll_GetFileAttributesW]
cmp eax, 0xffffffff
je 0x14000238f
test al, 0x10
jne 0x14000238f
mov ecx, 0xb7
jmp 0x14000236c
mov eax, 1
add rsp, 0x20
pop rbx
ret

Function at 0x14000239c
Capabilities:
Write file on windows

Disassembly:
sub rsp, 0x38
mov byte [rsp + 0x40], cl
mov ecx, 0xfffffff5
mov byte [rsp + 0x41], InitCommonControls
mov byte [rsp + 0x42], 0xa
call qword [sym.imp.KERNEL32.dll_GetStdHandle]
and qword [rsp + 0x20], 0
lea r9, [rsp + 0x48]
lea rdx, [rsp + 0x40]
mov rcx, rax
mov r8d, 3
call qword [sym.imp.KERNEL32.dll_WriteFile]
add rsp, 0x38
ret
Function at 0x140002640
Capabilities:
Extract resource via kernel32 functions

Disassembly:
mov rax, rsp
mov qword [rax + 8], rbx
mov qword [rax + 0x10], rbp
mov qword [rax + 0x18], rsi
mov qword [rax + 0x20], rdi
push r12
sub rsp, 0x70
mov r12, rcx
xor ecx, ecx
mov rsi, r8
mov rbp, rdx
call qword [sym.imp.KERNEL32.dll_GetModuleHandleW]
movzx r9d, word [0x14002bd98]
mov r8, rbp
mov rdx, r12
mov rcx, rax
mov rdi, rax
call qword [sym.imp.KERNEL32.dll_FindResourceExA]
test rax, rax
mov rbx, rax
jne 0x1400026a8
mov r9w, 0x409
mov r8, rbp
mov rdx, r12
mov rcx, rdi
call qword [sym.imp.KERNEL32.dll_FindResourceExA]
test rax, rax
mov rbx, rax
je 0x1400026de
test rsi, rsi
je 0x1400026bf
mov rdx, rbx
mov rcx, rdi
call qword [sym.imp.KERNEL32.dll_SizeofResource]
mov r11d, eax
mov qword [rsi], r11
mov rdx, rbx
mov rcx, rdi
call qword [sym.imp.KERNEL32.dll_LoadResource]
test rax, rax
je 0x1400026de
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_LockResource]
jmp 0x14000277a
cmp dword [0x14002bd9c], 0
jne 0x140002778
lea rcx, str.kernel32
mov dword [0x14002bd9c], 1
call qword [sym.imp.KERNEL32.dll_LoadLibraryA]
lea rdx, str.SetProcessPreferredUILanguages
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_GetProcAddress]
movzx r8d, word [0x14002bd98]
and qword [rsp + 0x28], 0
lea rdx, str._04X_c_04X_c
lea rcx, [rsp + 0x30]
xor r9d, r9d
mov rbx, rax
mov dword [rsp + 0x20], 0x409
call qword [sym.imp.USER32.dll_wsprintfW]
test rbx, rbx
jne 0x14000276a
lea rcx, str.kernel32
call qword [sym.imp.KERNEL32.dll_LoadLibraryA]
lea rdx, str.SetThreadPreferredUILanguages
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_GetProcAddress]
test rax, rax
mov rbx, rax
je 0x140002778
xor r8d, r8d
lea rdx, [rsp + 0x30]
lea ecx, [r8 + 4]
call rbx
xor eax, eax
lea r11, [rsp + 0x70]
mov rbx, qword [r11 + 0x10]
mov rbp, qword [r11 + 0x18]
mov rsi, qword [r11 + 0x20]
mov rdi, qword [r11 + 0x28]
mov rsp, r11
pop r12
ret

Function at 0x140002b44
Capabilities:
Identify system language via api

Disassembly:
sub rsp, 0x28
movzx edx, word [0x14002bd98]
test dx, dx
jne 0x140002ba9
call qword [sym.imp.KERNEL32.dll_GetUserDefaultUILanguage]
movzx ecx, ax
mov word [0x14002bd98], ax
and cx, 0x3ff
cmp cx, 9
je 0x140002b74
movzx eax, ax
jmp 0x140002bac
call qword [sym.imp.KERNEL32.dll_GetSystemDefaultUILanguage]
cmp ax, 0x409
jne 0x140002ba2
call qword [sym.imp.KERNEL32.dll_GetSystemDefaultLCID]
mov ecx, dword [0x140025a2c]
mov dx, word [0x14002bd98]
cmp eax, ecx
cmove dx, cx
mov word [0x14002bd98], dx
jmp 0x140002ba9
mov dx, word [0x14002bd98]
movzx eax, dx
add rsp, 0x28
ret
Function at 0x140002bb4
Capabilities:
Get geographical location
Query environment variable

Disassembly:
mov qword [rsp + 8], rbx
mov qword [rsp + 0x10], rbp
mov qword [rsp + 0x18], rsi
push rdi
push r12
push r15
sub rsp, 0xd0
xor edx, edx
xor r8d, r8d
mov edi, ecx
cmp dword [0x14002b060], edx
lea r12, [0x14002b060]
je 0x140002c02
mov rax, r12
cmp dword [rax], ecx
je 0x140002c02
add r8, 1
add edx, 1
mov rax, r8
shl rax, 5
add rax, r12
cmp dword [rax], 0
jne 0x140002be8
mov ebx, edx
shl rbx, 5
cmp dword [rbx + r12], 0
jne 0x140002c1b
lea rax, [0x140024b20]
jmp 0x140002d98
call qword [sym.imp.KERNEL32.dll_GetLastError]
lea rdx, str.SfxString_d
lea rcx, [rsp + 0x30]
mov r8d, edi
mov ebp, eax
call qword [sym.imp.USER32.dll_wsprintfW]
lea rcx, [rsp + 0x30]
xor r8d, r8d
xor edx, edx
call qword [sym.imp.KERNEL32.dll_GetEnvironmentVariableW]
mov esi, eax
call qword [sym.imp.KERNEL32.dll_GetLastError]
or r15, 0xffffffffffffffff
test eax, eax
jne 0x140002cc1
lea edx, [rsi + 2]
lea eax, [r15 + 3]
mul rdx
cmovo rax, r15
mov rcx, rax
call sub.msvcrt.dll_void____ptr64___cdecl_operator_new_unsigned_long_long_unsigned___int64__
lea r8d, [rsi + 1]
lea rcx, [rsp + 0x30]
mov rdx, rax
mov rdi, rax
call qword [sym.imp.KERNEL32.dll_GetEnvironmentVariableW]
cmp eax, esi
ja 0x140002cb9
call qword [sym.imp.KERNEL32.dll_GetLastError]
test eax, eax
jne 0x140002cb9
mov rcx, qword [rbx + r12 + 0x18]
test rcx, rcx
je 0x140002cb2
mov rdx, rdi
call qword [sym.imp.KERNEL32.dll_lstrcmpiW]
test eax, eax
je 0x140002cb9
mov rcx, qword [rbx + r12 + 0x18]
call sub.msvcrt.dll_void___cdecl_operator_delete_void____ptr64_
mov qword [rbx + r12 + 0x18], rdi
jmp 0x140002cc1
mov rcx, rdi
call sub.msvcrt.dll_void___cdecl_operator_delete_void____ptr64_
mov ecx, ebp
call qword [sym.imp.KERNEL32.dll_SetLastError]
mov rax, qword [rbx + r12 + 0x18]
test rax, rax
jne 0x140002d98
cmp qword [rbx + r12 + 0x10], rax
mov rdi, qword [rbx + r12 + 8]
je 0x140002cf5
call fcn.140002b44
cmp eax, dword [0x140025a2c]
jne 0x140002cf5
mov rdi, qword [rbx + r12 + 0x10]
mov rcx, rdi
call qword [sym.imp.KERNEL32.dll_lstrlenA]
mov esi, eax
lea ecx, [rax + 3]
mov eax, 2
movsxd rdx, ecx
mul rdx
cmovo rax, r15
mov rcx, rax
call sub.msvcrt.dll_void____ptr64___cdecl_operator_new_unsigned_long_long_unsigned___int64__
mov ecx, dword [0x14002b004]
cmp ecx, 0xffffffff
mov qword [rbx + r12 + 0x18], rax
jne 0x140002d73
movzx ecx, word [0x14002bd98]
and dword [0x14002b004], 0
lea r8, [rsp + 0x90]
mov r9d, 0x1f
mov edx, 0x1004
call qword [sym.imp.KERNEL32.dll_GetLocaleInfoW]
test eax, eax
jle 0x140002d6d
lea rcx, [rsp + 0x90]
call qword [sym.imp.msvcrt.dll__wtol]
mov ecx, eax
mov dword [0x14002b004], eax
jmp 0x140002d73
mov ecx, dword [0x14002b004]
lea eax, [rsi + 2]
lea r9d, [rsi + 1]
mov r8, rdi
mov dword [rsp + 0x28], eax
mov rax, qword [rbx + r12 + 0x18]
xor edx, edx
mov qword [rsp + 0x20], rax
call qword [sym.imp.KERNEL32.dll_MultiByteToWideChar]
mov rax, qword [rbx + r12 + 0x18]
lea r11, [rsp + 0xd0]
mov rbx, qword [r11 + 0x20]
mov rbp, qword [r11 + 0x28]
mov rsi, qword [r11 + 0x30]
mov rsp, r11
pop r15
pop r12
pop rdi
ret
Function at 0x140002e64
Capabilities:
Get token membership

Disassembly:
mov rax, rsp
push rbx
sub rsp, 0x60
xor ebx, ebx
mov byte [rax + 0x15], 5
lea rax, [rax + 0x18]
mov qword [rsp + 0x50], rax
mov dword [rsp + 0x48], ebx
mov dword [rsp + 0x40], ebx
mov dword [rsp + 0x38], ebx
mov dword [rax - 0x10], ebx
mov qword [rax], rbx
mov byte [rax - 8], bl
mov byte [rax - 7], bl
mov byte [rax - 6], bl
mov byte [rax - 5], bl
mov byte [rax - 4], bl
mov dword [rsp + 0x30], ebx
lea r8d, [rbx + 0x20]
lea rcx, [rsp + 0x78]
mov r9d, 0x220
mov dl, 2
mov dword [rsp + 0x28], ebx
mov dword [rsp + 0x20], ebx
call qword [sym.imp.ADVAPI32.dll_AllocateAndInitializeSid]
cmp eax, ebx
jne 0x140002ec7
xor eax, eax
jmp 0x140002eee
mov rdx, qword [rsp + 0x80]
lea r8, [rsp + 0x70]
xor ecx, ecx
call qword [sym.imp.ADVAPI32.dll_CheckTokenMembership]
mov rcx, qword [rsp + 0x80]
call qword [sym.imp.ADVAPI32.dll_FreeSid]
mov eax, dword [rsp + 0x70]
add rsp, 0x60
pop rbx
ret

Function at 0x140003074
Capabilities:
Get memory capacity

Disassembly:
push rbx
sub rsp, 0x60
test rcx, rcx
mov rbx, rcx
jne 0x140003086
xor eax, eax
jmp 0x1400030da
test byte [0x14002be04], 2
mov dword [rsp + 0x20], 0x40
jne 0x1400030d5
lea rcx, [rsp + 0x20]
call qword [sym.imp.KERNEL32.dll_GlobalMemoryStatusEx]
test eax, eax
je 0x1400030d5
cmp qword [rsp + 0x30], rbx
jae 0x1400030d5
mov ecx, 0x2b
call fcn.140002bb4
mov rcx, rax
call fcn.14000d280
cmp rax, 1
je 0x1400030ce
or dword [0x14002be04], 0xffffffff
jmp 0x140003082
or dword [0x14002be04], 2
mov eax, 1
add rsp, 0x60
pop rbx
ret

Function at 0x1400037b8
Capabilities:
Query environment variable

Disassembly:
mov rax, rsp
mov qword [rax + 8], rbx
mov qword [rax + 0x10], rbp
mov qword [rax + 0x18], rsi
push rdi
sub rsp, 0x30
and qword [rax - 0x18], 0
and dword [rax - 0x10], 0
and dword [rax - 0xc], 0
mov rsi, rcx
lea rcx, [rax - 0x18]
mov edx, 3
call fcn.1400011b4
mov edi, dword [rsp + 0x2c]
cmp edi, 1
jg 0x140003806
lea rcx, [rsp + 0x20]
mov edx, 1
call fcn.1400011b4
mov edi, dword [rsp + 0x2c]
mov rbx, qword [rsp + 0x20]
mov rcx, qword [rsi]
mov r8d, 1
mov rdx, rbx
call qword [sym.imp.KERNEL32.dll_ExpandEnvironmentStringsW]
test eax, eax
je 0x1400038a7
lea ebp, [rax + 1]
cmp ebp, edi
jl 0x14000383d
lea rcx, [rsp + 0x20]
mov edx, ebp
call fcn.1400011b4
mov rbx, qword [rsp + 0x20]
mov rcx, qword [rsi]
mov r8d, ebp
mov rdx, rbx
call qword [sym.imp.KERNEL32.dll_ExpandEnvironmentStringsW]
xor edi, edi
cmp word [rbx], di
je 0x140003863
mov rax, rbx
add rax, 2
add edi, 1
cmp word [rax], 0
jne 0x140003856
movsxd rax, edi
and word [rbx + rax*2], 0
lea rax, [rsp + 0x20]
cmp rax, rsi
je 0x1400038a7
mov rax, qword [rsi]
and dword [rsi + 8], 0
mov edx, edi
and word [rax], 0
mov rcx, rsi
call fcn.1400011b4
mov rcx, qword [rsi]
mov r11, rbx
movzx eax, word [r11]
add r11, 2
mov word [rcx], ax
add rcx, 2
test ax, ax
jne 0x140003890
mov dword [rsi + 8], edi
mov rcx, rbx
mov rbx, qword [rsp + 0x40]
mov rbp, qword [rsp + 0x48]
mov rsi, qword [rsp + 0x50]
add rsp, 0x30
pop rdi
jmp sub.msvcrt.dll_void___cdecl_operator_delete_void____ptr64_
Function at 0x140003e88
Capabilities:
Delete directory
Delete file
Enumerate files on windows
Enumerate files recursively
Set file attributes

Disassembly:
mov qword [rsp + 8], rbx
mov qword [rsp + 0x10], rsi
push rdi
sub rsp, 0x280
mov rdi, rcx
mov rdx, rcx
lea rcx, [rsp + 0x20]
call fcn.14000313c
lea rdx, [0x140024bf4]
lea rcx, [rsp + 0x20]
call fcn.1400031a8
mov rbx, qword [rsp + 0x20]
lea rdx, [rsp + 0x30]
mov rcx, rbx
call qword [sym.imp.KERNEL32.dll_FindFirstFileW]
cmp rax, 0xffffffffffffffff
mov rsi, rax
je 0x140003f82
lea rcx, [rsp + 0x20]
mov rdx, rdi
call fcn.1400014a0
lea rcx, [rsp + 0x20]
mov dx, 0x5c
call fcn.1400018e8
lea rdx, [rsp + 0x5c]
lea rcx, [rsp + 0x20]
call fcn.1400031a8
test byte [rsp + 0x30], 0x10
mov rbx, qword [rsp + 0x20]
je 0x140003f47
lea rdx, [0x140024bf0]
lea rcx, [rsp + 0x5c]
call qword [sym.imp.KERNEL32.dll_lstrcmpW]
test eax, eax
je 0x140003f63
lea rdx, [0x140024be8]
lea rcx, [rsp + 0x5c]
call qword [sym.imp.KERNEL32.dll_lstrcmpW]
test eax, eax
je 0x140003f63
mov rcx, rbx
call fcn.140003e88
jmp 0x140003f5f
xor edx, edx
mov rcx, rbx
call qword [sym.imp.KERNEL32.dll_SetFileAttributesW]
test eax, eax
je 0x140003fad
mov rcx, rbx
call qword [sym.imp.KERNEL32.dll_DeleteFileW]
test eax, eax
je 0x140003fad
lea rdx, [rsp + 0x30]
mov rcx, rsi
call qword [sym.imp.KERNEL32.dll_FindNextFileW]
test eax, eax
jne 0x140003edb
mov rcx, rsi
call qword [sym.imp.KERNEL32.dll_FindClose]
xor edx, edx
mov rcx, rdi
call qword [sym.imp.KERNEL32.dll_SetFileAttributesW]
test eax, eax
je 0x140003fad
mov rcx, rdi
call qword [sym.imp.KERNEL32.dll_RemoveDirectoryW]
test eax, eax
je 0x140003fad
mov rcx, rbx
call sub.msvcrt.dll_void___cdecl_operator_delete_void____ptr64_
mov eax, 1
jmp 0x140003fb7
mov rcx, rbx
call sub.msvcrt.dll_void___cdecl_operator_delete_void____ptr64_
xor eax, eax
lea r11, [rsp + 0x280]
mov rbx, qword [r11 + 0x10]
mov rsi, qword [r11 + 0x18]
mov rsp, r11
pop rdi
ret

Function at 0x140003fcc
Capabilities:
Check if file exists
Delete file
Get file attributes
Set file attributes

Disassembly:
push rbx
sub rsp, 0x20
cmp dword [0x14002bee4], 0
mov rbx, rcx
je 0x140003fe5
mov eax, 1
jmp 0x140004017
call qword [sym.imp.KERNEL32.dll_GetFileAttributesW]
cmp eax, 0xffffffff
je 0x140003fde
test al, 0x10
mov rcx, rbx
jne 0x140004012
xor edx, edx
call qword [sym.imp.KERNEL32.dll_SetFileAttributesW]
test eax, eax
je 0x14000400e
mov rcx, rbx
call qword [sym.imp.KERNEL32.dll_DeleteFileW]
jmp 0x140004017
xor eax, eax
jmp 0x140004017
call fcn.140003e88
add rsp, 0x20
pop rbx
ret
Function at 0x14000412c
Capabilities:
Get graphical window text

Disassembly:
mov qword [rsp + 8], rbx
mov qword [rsp + 0x10], rbp
mov qword [rsp + 0x18], rsi
push rdi
sub rsp, 0x20
and qword [rcx], 0
and dword [rcx + 8], 0
and dword [rcx + 0xc], 0
mov rbp, rdx
mov edx, 3
mov rbx, rcx
call fcn.1400011b4
mov rcx, rbp
call qword [sym.imp.USER32.dll_GetWindowTextLengthW]
test eax, eax
movsxd rsi, eax
jle 0x140004198
lea edi, [rsi + 1]
cmp edi, dword [rbx + 0xc]
jl 0x14000417e
mov edx, edi
mov rcx, rbx
call fcn.1400011b4
mov rdx, qword [rbx]
mov r8d, edi
mov rcx, rbp
call qword [sym.imp.USER32.dll_GetWindowTextW]
mov rax, qword [rbx]
and word [rax + rsi*2], 0
mov dword [rbx + 8], esi
mov rbp, qword [rsp + 0x38]
mov rsi, qword [rsp + 0x40]
mov rax, rbx
mov rbx, qword [rsp + 0x30]
add rsp, 0x20
pop rdi
ret

Function at 0x140004398
Capabilities:
Query environment variable

Disassembly:
mov rax, rsp
mov qword [rax + 0x10], rbx
mov qword [rax + 0x18], rbp
mov qword [rax + 0x20], rsi
push rdi
sub rsp, 0x20
mov rsi, rdx
mov rbx, rcx
lea rdx, [rax + 8]
mov rcx, rsi
mov r8d, 1
call qword [sym.imp.KERNEL32.dll_GetEnvironmentVariableW]
and qword [rbx], 0
and dword [rbx + 8], 0
and dword [rbx + 0xc], 0
mov edx, 3
mov rcx, rbx
mov ebp, eax
call fcn.1400011b4
lea edi, [rbp + 2]
cmp edi, dword [rbx + 0xc]
jl 0x140004401
mov edx, edi
mov rcx, rbx
call fcn.1400011b4
cmp edi, dword [rbx + 0xc]
jl 0x140004401
mov edx, edi
mov rcx, rbx
call fcn.1400011b4
mov rdx, qword [rbx]
lea r8d, [rbp + 1]
mov rcx, rsi
call qword [sym.imp.KERNEL32.dll_GetEnvironmentVariableW]
mov rcx, qword [rbx]
xor r11d, r11d
cmp word [rcx], r11w
je 0x14000442e
mov rax, rcx
add rax, 2
add r11d, 1
cmp word [rax], 0
jne 0x140004420
mov rbp, qword [rsp + 0x40]
mov rsi, qword [rsp + 0x48]
movsxd rax, r11d
and word [rcx + rax*2], 0
mov dword [rbx + 8], r11d
mov rax, rbx
mov rbx, qword [rsp + 0x38]
add rsp, 0x20
pop rdi
ret

Function at 0x140004620
Capabilities:
Check if file exists
Get file attributes

Disassembly:
mov qword [rsp + 8], rbx
push rdi
sub rsp, 0x270
mov rdi, rdx
mov rbx, rcx
call qword [sym.imp.KERNEL32.dll_GetFileAttributesW]
cmp eax, 0xffffffff
jne 0x140004642
xor eax, eax
jmp 0x1400046a3
mov ecx, InitCommonControls
test cl, al
je 0x140004656
call qword [sym.imp.KERNEL32.dll_SetLastError]
or eax, 0xffffffff
jmp 0x1400046a3
mov eax, dword [0x14002be08]
test eax, eax
jne 0x14000466a
mov rcx, rbx
call fcn.1400045ec
jmp 0x1400046a3
cmp eax, 2
jne 0x14000469e
lea rdx, [rsp + 0x20]
mov rcx, rbx
call qword [sym.imp.KERNEL32.dll_FindFirstFileW]
cmp rax, 0xffffffffffffffff
je 0x140004660
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_FindClose]
lea rcx, [rsp + 0x34]
mov rdx, rdi
call qword [sym.imp.KERNEL32.dll_CompareFileTime]
test eax, eax
js 0x140004660
mov eax, 1
mov rbx, qword [rsp + 0x280]
add rsp, 0x270
pop rdi
ret
Function at 0x140004c64
Capabilities:
Get file attributes

Disassembly:
mov qword [rsp + 0x10], rbx
mov qword [rsp + 0x18], rbp
push rsi
push rdi
push r12
push r13
push r14
sub rsp, 0x30
mov rbp, rcx
call qword [sym.imp.KERNEL32.dll_lstrlenW]
lea rcx, [rsp + 0x20]
mov rdx, rbp
movsxd r13, eax
call fcn.14000313c
cmp dword [rsp + 0x2c], 0
jg 0x140004ca6
lea rcx, [rsp + 0x20]
xor edx, edx
call fcn.1400011b4
cmp word [rbp + r13*2 - 2], 0x5c
mov rbx, qword [rsp + 0x20]
mov edi, 1
je 0x140004cc2
cmp word [rbp + r13*2 - 2], 0x2f
jne 0x140004ccc
and word [rbx + r13*2 - 2], 0
sub r13d, edi
movsxd r14, r13d
mov r12d, r13d
mov rsi, r14
jmp 0x140004cfa
cmp word [rbx + rsi*2], 0x2f
je 0x140004cf0
cmp word [rbx + rsi*2], 0x5c
je 0x140004cf0
sub r12d, edi
sub rsi, rdi
test rsi, rsi
jg 0x140004cd7
test rsi, rsi
je 0x140004d4b
and word [rbx + rsi*2], 0
mov rcx, rbx
call fcn.140002348
test eax, eax
je 0x140004ceb
lea rcx, [rsp + 0x60]
call qword [sym.imp.KERNEL32.dll_GetSystemTimeAsFileTime]
mov rcx, rbx
call qword [sym.imp.KERNEL32.dll_GetFileAttributesW]
test al, 0x10
jne 0x140004d33
lea rdx, [rsp + 0x60]
mov rcx, rbx
call fcn.140004620
test eax, eax
jne 0x140004df0
mov rcx, rbx
call fcn.140002348
test eax, eax
je 0x140004de1
movsxd rsi, r12d
jmp 0x140004dda
cmp r13d, 2
jne 0x140004d70
movzx eax, word [rbp]
or ax, 0x20
cmp ax, 0x61
jb 0x140004d70
cmp ax, 0x7a
ja 0x140004d70
cmp word [rbp + 2], 0x3a
je 0x140004df2
mov r8, rbp
mov edx, 0xc
mov ecx, edi
call fcn.14000d328
mov rcx, rbx
call sub.msvcrt.dll_void___cdecl_operator_delete_void____ptr64_
xor eax, eax
jmp 0x140004dfc
mov eax, r13d
movsxd rcx, r12d
sub eax, r12d
lea rdx, [rbp + rcx*2]
lea rcx, [rbx + rcx*2]
add eax, edi
movsxd r8, eax
call sub.msvcrt.dll_memcpy
cmp word [rbx + rsi*2], 0
jmp 0x140004dba
cmp word [rbx + rsi*2], 0x5c
je 0x140004dc9
cmp word [rbx + rsi*2], 0x2f
je 0x140004dc9
add rsi, rdi
add r12d, edi
cmp word [rbx + rsi*2], 0
jne 0x140004dae
and word [rbx + rsi*2], 0
mov rcx, rbx
call fcn.140002348
test eax, eax
je 0x140004de1
cmp rsi, r14
jl 0x140004d8b
jmp 0x140004df2
mov r8, rbx
mov edx, 0xc
mov ecx, edi
call fcn.14000d328
xor edi, edi
mov rcx, rbx
call sub.msvcrt.dll_void___cdecl_operator_delete_void____ptr64_
mov eax, edi
mov rbx, qword [rsp + 0x68]
mov rbp, qword [rsp + 0x70]
add rsp, 0x30
pop r14
pop r13
pop r12
pop rdi
pop rsi
ret