joyce8/EMBER2024-capa huggingface dataset:
Function at 0x14002c428
Capabilities:
Get graphical window text

Disassembly:
push rdi
sub rsp, 0x30
mov qword [rsp + 0x20], 0xfffffffffffffffe
mov qword [rsp + 0x48], rbx
mov qword [rsp + 0x50], rsi
movsxd rsi, r8d
mov rbx, rdx
mov rdi, rcx
cmp qword [rcx + 0xd0], 0
jne 0x14002c466
mov r8d, esi
mov rcx, qword [rcx + 0x40]
call qword [sym.imp.USER32.dll_GetWindowTextW]
jmp 0x14002c510
call fcn.1400305dc
mov rcx, rax
test rax, rax
je 0x14002c526
mov rax, qword [rax]
mov rax, qword [rax + 0x18]
call qword [case.0x14006074e.0]
add rax, 0x18
mov qword [rsp + 0x40], rax
mov rcx, qword [rdi + 0xd0]
mov rax, qword [rcx]
lea rdx, [rsp + 0x40]
mov rax, qword [rax + 0x118]
call qword [case.0x14006074e.0]
mov rdx, rsi
or rdi, 0xffffffffffffffff
mov r9, rdi
mov r8, qword [rsp + 0x40]
mov rcx, rbx
call fcn.140288f6c
test eax, eax
je 0x14002c4d8
cmp eax, 0xc
je 0x14002c520
cmp eax, 0x16
je 0x14002c537
cmp eax, 0x22
je 0x14002c537
cmp eax, 0x50
jne 0x14002c531
test rbx, rbx
je 0x14002c4e8
mov rcx, rbx
call fcn.14026dd38
mov rbx, rax
mov rdx, qword [rsp + 0x40]
add rdx, 0xffffffffffffffe8
mov ecx, edi
lock xadd dword [rdx + 0x10], ecx
add ecx, edi
test ecx, ecx
jg 0x14002c50e
mov rcx, qword [rdx]
mov rax, qword [rcx]
mov rax, qword [rax + 8]
call qword [case.0x14006074e.0]
mov eax, ebx
mov rbx, qword [rsp + 0x48]
mov rsi, qword [rsp + 0x50]
add rsp, 0x30
pop rdi
ret
call fcn.14002d270
nop
mov ecx, 0x80004005
call fcn.1400080a4
nop
call fcn.14002d1f8
int3
call fcn.14002d1f8
int3

Function at 0x14003c2f8
Capabilities:
Delete file

Disassembly:
mov qword [rsp + 8], rbx
push rdi
sub rsp, 0x20
mov rdi, rcx
mov rbx, rdx
mov rcx, qword [rdx]
cmp dword [rcx - 0x10], 0
je 0x14003c32a
call qword [sym.imp.KERNEL32.dll_DeleteFileW]
test eax, eax
jne 0x14003c32a
lea rcx, [rdi + 0x120]
mov rdx, rbx
call fcn.1400f5d88
mov rbx, qword [rsp + 0x30]
mov eax, 1
add rsp, 0x20
pop rdi
ret

Function at 0x14003c33c
Capabilities:
Delete registry key

Disassembly:
mov qword [rsp + 8], rbx
push rdi
sub rsp, 0x30
mov rbx, rcx
mov rdi, rdx
mov rcx, qword [rcx + 0x10]
test rcx, rcx
je 0x14003c362
mov r8, rdx
mov rdx, qword [rbx]
call fcn.140020b30
jmp 0x14003c3cd
cmp byte [0x1403f25a8], 0
jne 0x14003c3a6
lea rcx, str.Advapi32.dll
call qword [sym.imp.KERNEL32.dll_GetModuleHandleW]
test rax, rax
je 0x14003c396
lea rdx, str.RegDeleteKeyExW
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_GetProcAddress]
mov qword [0x1403f25a0], rax
jmp 0x14003c39d
mov rax, qword [0x1403f25a0]
mov byte [0x1403f25a8], 1
jmp 0x14003c3ad
mov rax, qword [0x1403f25a0]
mov rcx, qword [rbx]
mov rdx, rdi
test rax, rax
je 0x14003c3c7
mov r8d, dword [rbx + 8]
xor r9d, r9d
call qword [case.0x14006074e.0]
jmp 0x14003c3cd
call qword [sym.imp.ADVAPI32.dll_RegDeleteKeyW]
mov rbx, qword [rsp + 0x40]
add rsp, 0x30
pop rdi
ret
Function at 0x1400508c8
Capabilities:
Extract resource via kernel32 functions

Disassembly:
mov qword [rsp + 8], rbx
mov qword [rsp + 0x10], rbp
mov qword [rsp + 0x18], rsi
push rdi
push r14
push r15
sub rsp, 0x20
xor ebx, ebx
mov rdi, r8
mov rsi, rdx
mov r15, rcx
test r8, r8
jne 0x1400508f9
call fcn.140031cac
mov rdi, qword [rax + 0x18]
lea r8, [0x1402e6c00]
mov rdx, rsi
mov rcx, rdi
call qword [sym.imp.KERNEL32.dll_FindResourceW]
mov rbp, rax
test rax, rax
je 0x140050962
mov rdx, rax
mov rcx, rdi
call qword [sym.imp.KERNEL32.dll_LoadResource]
mov rsi, rax
test rax, rax
je 0x140050962
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_LockResource]
mov r14, rax
test rax, rax
je 0x140050955
mov rdx, rbp
mov rcx, rdi
call qword [sym.imp.KERNEL32.dll_SizeofResource]
mov rdx, r14
mov rcx, r15
mov r8d, eax
call fcn.140050980
mov ebx, eax
mov rcx, rsi
call qword [sym.imp.KERNEL32.dll_FreeResource]
mov eax, ebx
jmp 0x140050964
xor eax, eax
mov rbx, qword [rsp + 0x40]
mov rbp, qword [rsp + 0x48]
mov rsi, qword [rsp + 0x50]
add rsp, 0x20
pop r15
pop r14
pop rdi
ret

Function at 0x1400e6160
Capabilities:
Delete file

Disassembly:
mov qword [rsp + 8], rbx
push rdi
sub rsp, 0x20
cmp qword [rcx], 0
mov rdi, rdx
mov rbx, rcx
je 0x1400e61ab
lea rcx, str.kernel32.dll
call qword [sym.imp.KERNEL32.dll_GetModuleHandleW]
test rax, rax
je 0x1400e61bc
lea rdx, str.DeleteFileTransactedW
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_GetProcAddress]
test rax, rax
je 0x1400e61bc
mov rdx, qword [rbx]
mov rcx, rdi
call qword [case.0x14006074e.0]
jmp 0x1400e61be
cmp dword [rcx + 8], 0
je 0x1400e61bc
mov rcx, rdi
call qword [sym.imp.KERNEL32.dll_DeleteFileW]
jmp 0x1400e61be
xor eax, eax
mov rbx, qword [rsp + 0x30]
add rsp, 0x20
pop rdi
ret

Function at 0x1400e6520
Capabilities:
Move file

Disassembly:
mov qword [rsp + 8], rbx
mov qword [rsp + 0x10], rsi
push rdi
sub rsp, 0x40
cmp qword [rcx], 0
mov rdi, r8
mov rsi, rdx
mov rbx, rcx
je 0x1400e6589
lea rcx, str.kernel32.dll
call qword [sym.imp.KERNEL32.dll_GetModuleHandleW]
test rax, rax
je 0x1400e659d
lea rdx, str.MoveFileTransactedW
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_GetProcAddress]
test rax, rax
je 0x1400e659d
mov rcx, qword [rbx]
xor r9d, r9d
mov qword [rsp + 0x28], rcx
xor r8d, r8d
mov rcx, rsi
mov dword [rsp + 0x20], 2
mov rdx, rdi
call qword [case.0x14006074e.0]
jmp 0x1400e659f
cmp dword [rcx + 8], 0
je 0x1400e659d
mov rdx, rdi
mov rcx, rsi
call qword [sym.imp.KERNEL32.dll_MoveFileW]
jmp 0x1400e659f
xor eax, eax
mov rbx, qword [rsp + 0x50]
mov rsi, qword [rsp + 0x58]
add rsp, 0x40
pop rdi
ret

Function at 0x1400e6860
Capabilities:
Delete file

Disassembly:
push rbx
sub rsp, 0x20
mov rax, rdx
mov rbx, rcx
test rdx, rdx
je 0x1400e687e
mov rdx, rcx
mov rcx, rax
call fcn.1400e6160
jmp 0x1400e6884
call qword [sym.imp.KERNEL32.dll_DeleteFileW]
test eax, eax
jne 0x1400e6898
call qword [sym.imp.KERNEL32.dll_GetLastError]
mov ecx, eax
mov rdx, rbx
call fcn.1400f46c4
add rsp, 0x20
pop rbx
ret
Function at 0x1400e68a0
Capabilities:
Move file

Disassembly:
push rbx
sub rsp, 0x20
mov rax, r8
mov rbx, rcx
test r8, r8
je 0x1400e68c1
mov r8, rdx
mov rdx, rcx
mov rcx, rax
call fcn.1400e6520
jmp 0x1400e68c7
call qword [sym.imp.KERNEL32.dll_MoveFileW]
test eax, eax
jne 0x1400e68db
call qword [sym.imp.KERNEL32.dll_GetLastError]
mov ecx, eax
mov rdx, rbx
call fcn.1400f46c4
add rsp, 0x20
pop rbx
ret

Function at 0x1400ec52c
Capabilities:
Extract resource via kernel32 functions

Disassembly:
mov qword [rsp + 8], rbx
mov qword [rsp + 0x10], rbp
mov qword [rsp + 0x18], rsi
push rdi
sub rsp, 0x20
test byte [rdx + 4], 1
mov esi, r8d
mov rbx, qword [rdx + 0x10]
mov rdi, rdx
mov rbp, rcx
jne 0x1400ec5a3
mov rcx, qword [rdi + 8]
mov r8d, 5
mov rdx, rbx
call qword [sym.imp.KERNEL32.dll_FindResourceW]
mov rbx, rax
test rax, rax
jne 0x1400ec573
call fcn.140041420
mov rcx, qword [rdi + 8]
mov rdx, rbx
call qword [sym.imp.KERNEL32.dll_LoadResource]
mov rbx, rax
test rax, rax
jne 0x1400ec58d
call fcn.140041420
mov rcx, rbx
call qword [sym.imp.KERNEL32.dll_LockResource]
mov rbx, rax
test rax, rax
jne 0x1400ec5a3
call fcn.140041420
call fcn.140031cac
cmp qword [rax + 0x68], 0
je 0x1400ec5bd
mov rdx, rbx
mov rcx, rbp
call fcn.1400eb894
mov rbx, rax
mov edx, esi
mov rcx, rbx
call fcn.1400ec938
mov rcx, qword [rbp + 0xf8]
mov rsi, rax
test rcx, rcx
je 0x1400ec5e4
call qword [sym.imp.KERNEL32.dll_GlobalFree]
and qword [rbp + 0xf8], 0
test rsi, rsi
je 0x1400ec5f3
mov rbx, rsi
mov qword [rbp + 0xf8], rsi
or dword [rdi + 4], 1
mov rbp, qword [rsp + 0x38]
mov rsi, qword [rsp + 0x40]
mov qword [rdi + 0x10], rbx
mov rbx, qword [rsp + 0x30]
add rsp, 0x20
pop rdi
ret

Function at 0x1400ee4c4
Capabilities:
Delete registry key

Disassembly:
push rdi
sub rsp, 0x30
mov qword [rsp + 0x20], 0xfffffffffffffffe
mov qword [rsp + 0x48], rbx
mov rdi, r8
mov rbx, rcx
lea rcx, [rsp + 0x40]
call fcn.140006f44
nop
cmp rbx, 0xffffffff80000000
jne 0x1400ee54e
call fcn.140031d20
cmp eax, 1
jne 0x1400ee54e
lea r8, [rsp + 0x40]
lea rdx, str.SoftwareClasses_
lea rcx, [rsp + 0x50]
call fcn.140018520
nop
mov rdx, rax
lea rcx, [rsp + 0x40]
call fcn.14000774c
nop
mov rdx, qword [rsp + 0x50]
add rdx, 0xffffffffffffffe8
or eax, 0xffffffff
lock xadd dword [rdx + 0x10], eax
sub eax, 1
jg 0x1400ee547
mov rcx, qword [rdx]
mov rax, qword [rcx]
mov rax, qword [rax + 8]
call qword [case.0x14006074e.0]
mov rbx, 0xffffffff80000001
test rdi, rdi
je 0x1400ee565
mov r8, qword [rsp + 0x40]
mov rdx, rbx
mov rcx, rdi
call fcn.140020b30
jmp 0x1400ee573
mov rdx, qword [rsp + 0x40]
mov rcx, rbx
call qword [sym.imp.ADVAPI32.dll_RegDeleteKeyW]
mov ebx, eax
mov rdx, qword [rsp + 0x40]
add rdx, 0xffffffffffffffe8
or eax, 0xffffffff
lock xadd dword [rdx + 0x10], eax
sub eax, 1
jg 0x1400ee59b
mov rcx, qword [rdx]
mov rax, qword [rcx]
mov rax, qword [rax + 8]
call qword [case.0x14006074e.0]
mov eax, ebx
mov rbx, qword [rsp + 0x48]
add rsp, 0x30
pop rdi
ret
Function at 0x1400ee7c8
Capabilities:
Query or enumerate registry value

Disassembly:
mov rax, rsp
push rdi
sub rsp, 0x30
mov qword [rax - 0x10], 0xfffffffffffffffe
mov qword [rax + 0x10], rbx
mov qword [rax + 0x18], rsi
mov rdi, r9
mov rsi, r8
mov rbx, rcx
lea rcx, [rax + 8]
call fcn.140006f44
nop
cmp rbx, 0xffffffff80000000
jne 0x1400ee858
call fcn.140031d20
cmp eax, 1
jne 0x1400ee858
lea r8, [rsp + 0x40]
lea rdx, str.SoftwareClasses_
lea rcx, [rsp + 0x20]
call fcn.140018520
nop
mov rdx, rax
lea rcx, [rsp + 0x40]
call fcn.14000774c
nop
mov rdx, qword [rsp + 0x20]
add rdx, 0xffffffffffffffe8
or eax, 0xffffffff
lock xadd dword [rdx + 0x10], eax
sub eax, 1
jg 0x1400ee851
mov rcx, qword [rdx]
mov rax, qword [rcx]
mov rax, qword [rax + 8]
call qword [case.0x14006074e.0]
mov rbx, 0xffffffff80000001
mov r9, rdi
mov r8, rsi
mov rdx, qword [rsp + 0x40]
mov rcx, rbx
call qword [sym.imp.ADVAPI32.dll_RegQueryValueW]
mov ebx, eax
mov rdx, qword [rsp + 0x40]
add rdx, 0xffffffffffffffe8
or ecx, 0xffffffff
lock xadd dword [rdx + 0x10], ecx
sub ecx, 1
jg 0x1400ee894
mov rcx, qword [rdx]
mov r8, qword [rcx]
mov rax, qword [r8 + 8]
call qword [case.0x14006074e.0]
mov eax, ebx
mov rbx, qword [rsp + 0x48]
mov rsi, qword [rsp + 0x50]
add rsp, 0x30
pop rdi
ret

Function at 0x1400ee8a8
Capabilities:
Set registry value

Disassembly:
mov rax, rsp
push rdi
sub rsp, 0x40
mov qword [rax - 0x10], 0xfffffffffffffffe
mov qword [rax + 0x10], rbx
mov qword [rax + 0x18], rsi
mov rdi, r9
mov esi, r8d
mov rbx, rcx
lea rcx, [rax + 8]
call fcn.140006f44
nop
cmp rbx, 0xffffffff80000000
jne 0x1400ee938
call fcn.140031d20
cmp eax, 1
jne 0x1400ee938
lea r8, [rsp + 0x50]
lea rdx, str.SoftwareClasses_
lea rcx, [rsp + 0x30]
call fcn.140018520
nop
mov rdx, rax
lea rcx, [rsp + 0x50]
call fcn.14000774c
nop
mov rdx, qword [rsp + 0x30]
add rdx, 0xffffffffffffffe8
or eax, 0xffffffff
lock xadd dword [rdx + 0x10], eax
sub eax, 1
jg 0x1400ee931
mov rcx, qword [rdx]
mov rax, qword [rcx]
mov rax, qword [rax + 8]
call qword [case.0x14006074e.0]
mov rbx, 0xffffffff80000001
mov eax, dword [rsp + 0x70]
mov dword [rsp + 0x20], eax
mov r9, rdi
mov r8d, esi
mov rdx, qword [rsp + 0x50]
mov rcx, rbx
call qword [sym.imp.ADVAPI32.dll_RegSetValueW]
mov ebx, eax
mov rdx, qword [rsp + 0x50]
add rdx, 0xffffffffffffffe8
or ecx, 0xffffffff
lock xadd dword [rdx + 0x10], ecx
sub ecx, 1
jg 0x1400ee97c
mov rcx, qword [rdx]
mov r8, qword [rcx]
mov rax, qword [r8 + 8]
call qword [case.0x14006074e.0]
mov eax, ebx
mov rbx, qword [rsp + 0x58]
mov rsi, qword [rsp + 0x60]
add rsp, 0x40
pop rdi
ret
Function at 0x1401363b4
Capabilities:
Set registry value

Disassembly:
push rbx
sub rsp, 0x30
xor ebx, ebx
cmp dword [rcx + 0x28], ebx
je 0x1401363c5
xor eax, eax
jmp 0x1401363e9
mov rcx, qword [rcx + 8]
mov dword [rsp + 0x28], r9d
mov r9d, 3
mov qword [rsp + 0x20], r8
xor r8d, r8d
call qword [sym.imp.ADVAPI32.dll_RegSetValueExW]
test eax, eax
sete bl
mov eax, ebx
add rsp, 0x30
pop rbx
ret

Function at 0x1401bf500
Capabilities:
Delete registry value

Disassembly:
mov rax, rsp
push rdi
sub rsp, 0x40
and dword [rax - 0x20], 0
lea r8, str.SoftwareMicrosoftWindowsCurrentVersionPreviewHandlers
and qword [rax - 0x18], 0
mov rdi, rcx
mov rdx, 0xffffffff80000002
lea rcx, [rax - 0x28]
mov r9d, 0x2001f
mov qword [rax - 0x28], rdx
call fcn.14003d5f0
test eax, eax
jne 0x1401bf565
mov rcx, qword [rsp + 0x20]
mov rdx, rdi
call qword [sym.imp.ADVAPI32.dll_RegDeleteValueW]
cmp qword [rsp + 0x20], 0
je 0x1401bf560
mov rcx, qword [rsp + 0x20]
call qword [sym.imp.ADVAPI32.dll_RegCloseKey]
and qword [rsp + 0x20], 0
and dword [rsp + 0x28], 0
mov r9d, 0x2001f
lea r8, str.CLSID
mov rdx, 0xffffffff80000000
lea rcx, [rsp + 0x20]
call fcn.14003d5f0
test eax, eax
jne 0x1401bf5a8
mov rdx, rdi
lea rcx, [rsp + 0x20]
call fcn.140135f08
mov rcx, qword [rsp + 0x20]
test rcx, rcx
je 0x1401bf5b8
call qword [sym.imp.ADVAPI32.dll_RegCloseKey]
xor ecx, ecx
jmp 0x1401bf5ad
mov rcx, qword [rsp + 0x20]
test rcx, rcx
je 0x1401bf5b8
call qword [sym.imp.ADVAPI32.dll_RegCloseKey]
mov eax, 1
add rsp, 0x40
pop rdi
ret

Function at 0x1401c1254
Capabilities:
Check if file exists
Get common file path
Get file attributes

Disassembly:
mov rax, rsp
mov qword [rax + 8], rbx
mov qword [rax + 0x10], rbp
mov qword [rax + 0x18], rsi
push rdi
sub rsp, 0x40
and dword [rax - 0x18], 0
mov rbp, r9
mov rbx, r8
mov rdi, rdx
mov rsi, rcx
lea rcx, [rsp + 0x30]
call fcn.1402a0748
test eax, eax
jne 0x1401c12b8
mov eax, dword [rsp + 0x30]
lea r8, str._s_s_X.tmp
mov dword [rsp + 0x28], eax
mov r9, rsi
mov rdx, rbp
mov qword [rsp + 0x20], rdi
mov rcx, rbx
call fcn.1400203ec
mov rcx, rbx
call qword [sym.imp.KERNEL32.dll_GetFileAttributesW]
cmp eax, 0xffffffff
je 0x1401c12ca
jmp 0x1401c1278
mov r9, rbx
xor r8d, r8d
mov rdx, rdi
mov rcx, rsi
call qword [sym.imp.KERNEL32.dll_GetTempFileNameW]
mov rbx, qword [rsp + 0x50]
mov rbp, qword [rsp + 0x58]
mov rsi, qword [rsp + 0x60]
add rsp, 0x40
pop rdi
ret

Function at 0x1402a85ac
Capabilities:
Parse pe header

Disassembly:
xor r8d, r8d
xor edx, edx
jmp 0x1402a8274
Function at 0x14001cca0
Capabilities:
Write file on windows

Disassembly:
push r12
push rbx
sub rsp, 0x38
mov r12, rcx
lea rax, [rsp + 0x58]
mov ecx, 2
mov qword [rsp + 0x58], rdx
mov qword [rsp + 0x60], r8
mov qword [rsp + 0x68], r9
mov qword [rsp + 0x28], rax
call fcn.140028d80
mov r8d, 0x1b
mov edx, 1
lea rcx, str.Mingw_w64_runtime_failure:_n
mov r9, rax
call sub.msvcrt.dll_fwrite
mov rbx, qword [rsp + 0x28]
mov ecx, 2
call fcn.140028d80
mov rdx, r12
mov rcx, rax
mov r8, rbx
call sub.msvcrt.dll_vfprintf
call sub.msvcrt.dll_abort
nop
nop word [rax + rax]
Function at 0x14001cd10
Capabilities:
Allocate or change rwx memory

Disassembly:
push r12
push rbp
push rdi
push rsi
push rbx
sub rsp, 0x50
movsxd rdi, dword [0x1401030c4]
mov r12, rcx
mov rsi, rdx
mov rbx, r8
test edi, edi
jle 0x14001cec0
mov rax, qword [0x1401030c8]
xor ecx, ecx
add rax, 0x18
nop
mov rdx, qword [rax]
cmp r12, rdx
jb 0x14001cd5c
mov r8, qword [rax + 8]
mov r8d, dword [r8 + 8]
add rdx, r8
cmp r12, rdx
jb 0x14001cde7
add ecx, 1
add rax, 0x28
cmp ecx, edi
jne 0x14001cd40
mov rcx, r12
call fcn.14001d7c0
mov rbp, rax
test rax, rax
je 0x14001cf1d
mov rax, qword [0x1401030c8]
lea rdi, [rdi + rdi*4]
shl rdi, 3
add rax, rdi
mov qword [rax + 0x20], rbp
mov dword [rax], 0
call fcn.14001d8f0
mov ecx, dword [rbp + 0xc]
lea rdx, [rsp + 0x20]
mov r8d, 0x30
add rcx, rax
mov rax, qword [0x1401030c8]
mov qword [rax + rdi + 0x18], rcx
call qword [sym.imp.KERNEL32.dll_VirtualQuery]
test rax, rax
je 0x14001cf02
mov eax, dword [rsp + 0x44]
lea edx, [rax - 0x40]
and edx, 0xffffffbf
je 0x14001cde0
lea edx, [rax - 4]
and edx, 0xfffffffb
jne 0x14001ce70
add dword [0x1401030c4], 1
cmp ebx, 8
jae 0x14001ce18
test bl, 4
jne 0x14001ced0
test ebx, ebx
je 0x14001ce09
movzx eax, byte [rsi]
mov byte [r12], al
test bl, 2
jne 0x14001cef0
add rsp, 0x50
pop rbx
pop rsi
pop rdi
pop rbp
pop r12
ret
mov rax, qword [rsi]
lea rcx, [r12 + 8]
and rcx, 0xfffffffffffffff8
mov qword [r12], rax
mov eax, ebx
mov rdx, qword [rsi + rax - 8]
mov qword [r12 + rax - 8], rdx
sub r12, rcx
add ebx, r12d
sub rsi, r12
and ebx, 0xfffffff8
cmp ebx, 8
jb 0x14001ce09
and ebx, 0xfffffff8
xor eax, eax
mov edx, eax
add eax, 8
mov r8, qword [rsi + rdx]
mov qword [rcx + rdx], r8
cmp eax, ebx
jb 0x14001ce4a
add rsp, 0x50
pop rbx
pop rsi
pop rdi
pop rbp
pop r12
ret
cmp eax, 2
mov rcx, qword [rsp + 0x20]
mov rdx, qword [rsp + 0x38]
mov r8d, 4
mov eax, 0x40
cmovne r8d, eax
add rdi, qword [0x1401030c8]
mov qword [rdi + 8], rcx
mov r9, rdi
mov qword [rdi + 0x10], rdx
call qword [sym.imp.KERNEL32.dll_VirtualProtect]
test eax, eax
jne 0x14001cde0
call qword [sym.imp.KERNEL32.dll_GetLastError]
lea rcx, str.__VirtualProtect_failed_with_code_0x_x
mov edx, eax
call fcn.14001cca0
xor edi, edi
jmp 0x14001cd67
mov eax, dword [rsi]
mov ebx, ebx
mov dword [r12], eax
mov eax, dword [rsi + rbx - 4]
mov dword [r12 + rbx - 4], eax
jmp 0x14001ce09
mov ebx, ebx
movzx eax, word [rsi + rbx - 2]
mov word [r12 + rbx - 2], ax
jmp 0x14001ce09
mov rax, qword [0x1401030c8]
mov edx, dword [rbp + 8]
lea rcx, str.__VirtualQuery_failed_for__d_bytes_at_address__p
mov r8, qword [rax + rdi + 0x18]
call fcn.14001cca0
mov rdx, r12
lea rcx, str.Address__p_has_no_image_section
call fcn.14001cca0
nop
nop dword [rax]
Function at 0x14001d430
Capabilities:
Get thread local storage value

Disassembly:
push r12
push rdi
push rsi
push rbx
sub rsp, 0x28
lea rcx, [0x140103120]
call qword [sym.imp.KERNEL32.dll_EnterCriticalSection]
mov rbx, qword [0x140103100]
test rbx, rbx
je 0x14001d484
mov rdi, qword [sym.imp.KERNEL32.dll_TlsGetValue]
mov rsi, qword [sym.imp.KERNEL32.dll_GetLastError]
mov ecx, dword [rbx]
call rdi
mov r12, rax
call rsi
test eax, eax
jne 0x14001d47b
test r12, r12
je 0x14001d47b
mov rax, qword [rbx + 8]
mov rcx, r12
call rax
mov rbx, qword [rbx + 0x10]
test rbx, rbx
jne 0x14001d460
lea rcx, [0x140103120]
add rsp, 0x28
pop rbx
pop rsi
pop rdi
pop r12
jmp qword [sym.imp.KERNEL32.dll_LeaveCriticalSection]

Function at 0x14001d7c0
Capabilities:
Enumerate pe sections

Disassembly:
sub rsp, 0x28
mov r10, qword [0x1400da8f0]
xor r8d, r8d
cmp word [r10], 0x5a4d
mov r9, rcx
jne 0x14001d839
mov rcx, r10
call fcn.14001d690
test eax, eax
je 0x14001d839
movsxd rax, dword [r10 + 0x3c]
mov rcx, r9
sub rcx, r10
add r10, rax
movzx eax, word [r10 + 0x14]
lea r8, [r10 + rax + 0x18]
movzx eax, word [r10 + 6]
test eax, eax
je 0x14001d836
sub eax, 1
lea rax, [rax + rax*4]
lea r9, [r8 + rax*8 + 0x28]
nop dword [rax]
mov edx, dword [r8 + 0xc]
mov rax, rdx
cmp rcx, rdx
jb 0x14001d82d
add eax, dword [r8 + 8]
cmp rcx, rax
jb 0x14001d839
add r8, 0x28
cmp r8, r9
jne 0x14001d818
xor r8d, r8d
mov rax, r8
add rsp, 0x28
ret

Function at 0x14001db30
Capabilities:
Allocate thread local storage

Disassembly:
push rdi
push rsi
push rbx
sub rsp, 0x20
mov eax, dword [0x140103108]
mov edi, ecx
mov rsi, rdx
test eax, eax
jne 0x14001d4c0
add rsp, 0x20
pop rbx
pop rsi
pop rdi
ret
mov edx, 0x18
mov ecx, 1
call sub.msvcrt.dll_calloc
mov rbx, rax
test rax, rax
je 0x14001d513
mov dword [rax], edi
lea rcx, [0x140103120]
mov qword [rax + 8], rsi
call qword [sym.imp.KERNEL32.dll_EnterCriticalSection]
mov rax, qword [0x140103100]
lea rcx, [0x140103120]
mov qword [0x140103100], rbx
mov qword [rbx + 0x10], rax
call qword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
xor eax, eax
add rsp, 0x20
pop rbx
pop rsi
pop rdi
ret
or eax, 0xffffffff
jmp 0x14001d4b6
push r12
push rbx
sub rsp, 0x28
mov rbx, rcx
mov r12, rdx
call qword [sym.imp.KERNEL32.dll_TlsAlloc]
mov ecx, eax
cmp eax, 0xffffffff
je 0x14001db60
mov rdx, r12
mov dword [rbx], eax
add rsp, 0x28
pop rbx
pop r12
jmp 0x140028fa0
add rsp, 0x28
pop rbx
pop r12
jmp qword [sym.imp.KERNEL32.dll_GetLastError]
test rdx, rdx
jne 0x140028fb0
xor eax, eax
ret
jmp 0x14001d4a0

Function at 0x14001dba0
Capabilities:
Get thread local storage value

Disassembly:
push r13
push r12
sub rsp, 0x28
mov r12d, ecx
call qword [sym.imp.KERNEL32.dll_GetLastError]
mov ecx, r12d
mov r13d, eax
call qword [sym.imp.KERNEL32.dll_TlsGetValue]
mov ecx, r13d
mov r12, rax
call qword [sym.imp.KERNEL32.dll_SetLastError]
mov rax, r12
add rsp, 0x28
pop r12
pop r13
ret

Function at 0x14001dbe0
Capabilities:
Set thread local storage value

Disassembly:
sub rsp, 0x28
call qword [sym.imp.KERNEL32.dll_TlsSetValue]
test eax, eax
je 0x14001dbf8
xor eax, eax
add rsp, 0x28
ret
add rsp, 0x28
jmp qword [sym.imp.KERNEL32.dll_GetLastError]
Function at 0x1400886e0
Capabilities:
Read file on windows

Disassembly:
push r12
push rbp
push rdi
push rsi
push rbx
sub rsp, 0x20
mov rbp, qword [sym.imp.msvcrt.dll__errno]
mov rdi, rcx
mov rsi, rdx
mov ebx, r8d
jmp 0x140088707
call rbp
cmp dword [rax], 4
jne 0x140088724
mov rcx, rdi
call fcn.140088500
mov r8d, ebx
mov rdx, rsi
mov ecx, eax
call sub.msvcrt.dll__read
movsxd r12, eax
cmp eax, 0xffffffff
je 0x140088700
mov rax, r12
add rsp, 0x20
pop rbx
pop rsi
pop rdi
pop rbp
pop r12
ret
Function at 0x1400012f0
Capabilities:
Get graphical window text

Disassembly:
mov qword [rsp + 0x10], rbx
mov qword [rsp + 0x18], rbp
mov qword [rsp + 0x20], rsi
push rdi
sub rsp, 0x120
mov rbx, rcx
mov rcx, qword [rcx + 0x20]
call qword [sym.imp.USER32.dll_GetDlgItem]
mov rcx, qword [rbx + 0x20]
mov edx, 9
mov rbp, rax
call qword [sym.imp.USER32.dll_GetDlgItem]
xor edi, edi
lea rdx, [rsp + 0x50]
lea r8d, [rdi + 0x64]
mov rcx, rbp
mov rsi, rax
mov word [rsp + 0x50], di
call qword [sym.imp.USER32.dll_GetWindowTextW]
lea rdx, [rsp + 0x50]
mov rcx, rsi
call qword [sym.imp.USER32.dll_SetWindowTextW]
mov rcx, qword [rbx + 0x20]
lea rdx, [rsp + 0x130]
mov dword [rsp + 0x130], edi
mov dword [rsp + 0x134], edi
call qword [sym.imp.USER32.dll_ClientToScreen]
lea r8d, [rdi + 0x10]
lea rcx, [rsp + 0x40]
xor edx, edx
call fcn.1400f78a0
lea rdx, [rsp + 0x40]
mov rcx, rbp
call qword [sym.imp.USER32.dll_GetWindowRect]
mov r8d, dword [rsp + 0x40]
mov r9d, dword [rsp + 0x44]
mov edi, dword [rsp + 0x48]
mov ebx, dword [rsp + 0x4c]
mov dword [rsp + 0x30], 4
sub edi, r8d
sub r8d, dword [rsp + 0x130]
sub ebx, r9d
sub r9d, dword [rsp + 0x134]
xor edx, edx
mov rcx, rsi
mov dword [rsp + 0x28], ebx
mov dword [rsp + 0x40], r8d
mov dword [rsp + 0x20], edi
mov dword [rsp + 0x44], r9d
call qword [sym.imp.USER32.dll_SetWindowPos]
mov r8d, dword [rsp + 0x44]
mov edx, dword [rsp + 0x40]
mov r9d, edi
mov rcx, rsi
mov dword [rsp + 0x28], 1
mov dword [rsp + 0x20], ebx
call qword [sym.imp.USER32.dll_MoveWindow]
xor edx, edx
mov rcx, rbp
call qword [sym.imp.USER32.dll_ShowWindow]
lea r11, [rsp + 0x120]
mov rbx, qword [r11 + 0x18]
mov rbp, qword [r11 + 0x20]
mov rsi, qword [r11 + 0x28]
mov rsp, r11
pop rdi
ret
Function at 0x1400047b0
Capabilities:
Get common file path
Query environment variable

Disassembly:
mov qword [rsp + 8], rbx
mov qword [rsp + 0x10], rsi
push rdi
sub rsp, 0x20
xor esi, esi
mov rdi, rcx
mov rcx, qword [rcx]
mov ebx, esi
cmp rcx, rsi
je 0x1400047d6
call qword [sym.imp.KERNEL32.dll_lstrlenW]
mov ebx, eax
lea edx, [rbx + 0x2d0]
mov rcx, rdi
movsxd rdx, edx
call fcn.140061610
cmp ebx, esi
jg 0x140004885
mov rax, qword [rdi]
lea rcx, [0x140111910]
mov r8d, 0x208
mov word [rax], si
mov rdx, qword [rdi]
call qword [sym.imp.KERNEL32.dll_GetEnvironmentVariableW]
cmp eax, esi
mov ebx, eax
jg 0x14000486a
mov rdx, qword [rdi]
lea rcx, [0x140111900]
mov r8d, 0x208
call qword [sym.imp.KERNEL32.dll_GetEnvironmentVariableW]
cmp eax, esi
mov ebx, eax
jg 0x14000486a
mov rdx, qword [rdi]
xor r9d, r9d
xor ecx, ecx
lea r8d, [r9 + 0x24]
call qword [sym.imp.SHELL32.dll_SHGetSpecialFolderPathW]
mov rcx, qword [rdi]
call qword [sym.imp.KERNEL32.dll_lstrlenW]
movsxd rbx, eax
cmp ebx, esi
jle 0x140004885
mov rax, qword [rdi]
lea rdx, [0x1401118f0]
lea rcx, [rax + rbx*2]
call qword [sym.imp.KERNEL32.dll_lstrcpyW]
add ebx, 5
cmp ebx, esi
jle 0x140004885
mov rax, qword [rdi]
movsxd rcx, ebx
mov edx, 0x5c
mov word [rax + rcx*2], dx
mov rax, qword [rdi]
inc ebx
movsxd rcx, ebx
mov word [rax + rcx*2], si
mov rdx, qword [rdi]
lea rcx, [0x1401310e0]
call fcn.14002701c
cmp ebx, esi
jle 0x1400048a4
mov rcx, qword [rdi]
call fcn.1400f6bb0
cmp eax, esi
jne 0x1400048e0
mov rdx, qword [rdi]
xor r9d, r9d
xor ecx, ecx
lea r8d, [r9 + 0x24]
call qword [sym.imp.SHELL32.dll_SHGetSpecialFolderPathW]
mov rcx, qword [rdi]
lea rdx, str.TEMP_
call qword [sym.imp.KERNEL32.dll_lstrcatW]
mov rdx, qword [rdi]
lea rcx, [0x1401310e0]
call fcn.14002701c
mov rcx, qword [rdi]
call qword [sym.imp.KERNEL32.dll_lstrlenW]
mov ebx, eax
mov rsi, qword [rsp + 0x38]
mov eax, ebx
mov rbx, qword [rsp + 0x30]
add rsp, 0x20
pop rdi
ret