joyce8/EMBER2024-capa huggingface dataset:
Function at 0x180050c10
Capabilities:
Check if file exists
Enumerate files on windows
Get common file path
Get file attributes

Disassembly:
mov r11, rsp
mov qword [r11 + 0x10], rbx
mov qword [r11 + 0x18], rsi
mov qword [r11 + 0x20], rdi
push r12
sub rsp, 0xad0
mov rax, qword [0x180101090]
xor rax, rsp
mov qword [rsp + 0xac0], rax
xor esi, esi
mov rbx, rcx
mov qword [rsp + 0x30], rsi
mov qword [rsp + 0x38], rsi
cmp rcx, rsi
je 0x180050dcc
lea r12, [fcn.180050dfc]
cmp r12, rsi
je 0x180050dcc
cmp word [rcx + 2], 0x3a
je 0x180050cb8
cmp word [rcx + 2], 0x5c
je 0x180050cb8
lea rcx, [r11 - 0x426]
xor edx, edx
mov r8d, 0x40e
mov word [rsp + 0x6b0], si
call fcn.18009e990
lea rdx, [rsp + 0x6b0]
mov ecx, 0x208
call qword [sym.imp.KERNEL32.dll_GetCurrentDirectoryW]
lea rcx, [rsp + 0x6b0]
mov rdx, rbx
call qword [sym.imp.SHLWAPI.dll_PathAppendW]
lea rbx, [rsp + 0x6b0]
mov rcx, rbx
call qword [sym.imp.KERNEL32.dll_GetFileAttributesW]
cmp eax, 0xffffffff
je 0x180050dcc
test al, 0x10
je 0x180050dcc
lea rcx, [rsp + 0x4a0]
mov rdx, rbx
call qword [sym.imp.KERNEL32.dll_lstrcpyW]
lea rdx, [0x1800d1804]
lea rcx, [rsp + 0x4a0]
call qword [sym.imp.SHLWAPI.dll_PathAppendW]
lea rdx, [rsp + 0x40]
lea rcx, [rsp + 0x4a0]
call qword [sym.imp.KERNEL32.dll_FindFirstFileW]
mov rdi, rax
cmp rax, 0xffffffffffffffff
je 0x180050dcc
lea rdx, [0x1800d34d8]
lea rcx, [rsp + 0x6c]
call qword [sym.imp.KERNEL32.dll_lstrcmpW]
cmp eax, esi
je 0x180050dad
lea rdx, [0x1800d1a48]
lea rcx, [rsp + 0x6c]
call qword [sym.imp.KERNEL32.dll_lstrcmpW]
cmp eax, esi
je 0x180050dad
cmp dword [rsp + 0x40], 0xffffffff
je 0x180050dad
lea rcx, [rsp + 0x290]
mov rdx, rbx
call qword [sym.imp.KERNEL32.dll_lstrcpyW]
lea rdx, [rsp + 0x6c]
lea rcx, [rsp + 0x290]
call qword [sym.imp.SHLWAPI.dll_PathAppendW]
test byte [rsp + 0x40], 0x10
lea rcx, [rsp + 0x290]
je 0x180050d9f
lea r9, [rsp + 0x30]
mov r8, r12
mov edx, 1
mov qword [rsp + 0x28], rsi
mov qword [rsp + 0x20], rsi
call fcn.18004fd0c
cmp eax, 2
jmp 0x180050dab
lea rdx, [rsp + 0x30]
call fcn.180050dfc
cmp eax, esi
je 0x180050dc3
lea rdx, [rsp + 0x40]
mov rcx, rdi
call qword [sym.imp.KERNEL32.dll_FindNextFileW]
cmp eax, esi
jne 0x180050d18
mov rcx, rdi
call qword [sym.imp.KERNEL32.dll_FindClose]
mov rax, qword [rsp + 0x30]
mov rcx, qword [rsp + 0xac0]
xor rcx, rsp
call fcn.180099fe0
lea r11, [rsp + 0xad0]
mov rbx, qword [r11 + 0x18]
mov rsi, qword [r11 + 0x20]
mov rdi, qword [r11 + 0x28]
mov rsp, r11
pop r12
ret
Function at 0x180050e2c
Capabilities:
Get file size
Read file on windows

Disassembly:
mov qword [rsp + 0x18], rbx
mov qword [rsp + 0x20], rsi
push rdi
mov eax, 0x2070
call fcn.1800b3cb0
sub rsp, rax
mov rax, qword [0x180101090]
xor rax, rsp
mov qword [rsp + 0x2060], rax
xor esi, esi
mov rbx, rdx
mov rdi, rcx
cmp rcx, rsi
je 0x180050ff9
cmp rdx, rsi
je 0x180050ff9
call qword [sym.imp.KERNEL32.dll_lstrcmpiW]
cmp eax, esi
jne 0x180050e84
mov esi, 1
jmp 0x180050ff9
mov qword [rsp + 0x30], rsi
xor r9d, r9d
xor r8d, r8d
mov edx, 0x80000000
mov rcx, rdi
mov dword [rsp + 0x28], esi
mov dword [rsp + 0x20], 3
call qword [sym.imp.KERNEL32.dll_CreateFileW]
mov qword [rsp + 0x30], rsi
xor r9d, r9d
xor r8d, r8d
mov edx, 0x80000000
mov rcx, rbx
mov dword [rsp + 0x28], esi
mov rdi, rax
mov dword [rsp + 0x20], 3
call qword [sym.imp.KERNEL32.dll_CreateFileW]
mov rbx, rax
cmp rdi, rsi
je 0x180050fd1
cmp rdi, 0xffffffffffffffff
je 0x180050fd1
cmp rax, rsi
je 0x180050fd1
cmp rax, 0xffffffffffffffff
je 0x180050fe5
xor eax, eax
lea rdx, [rsp + 0x50]
mov rcx, rdi
mov dword [rsp + 0x50], esi
mov dword [rsp + 0x48], esi
mov dword [rsp + 0x54], eax
mov dword [rsp + 0x4c], eax
call qword [sym.imp.KERNEL32.dll_GetFileSizeEx]
cmp eax, esi
je 0x180050f3c
lea rdx, [rsp + 0x48]
mov rcx, rbx
call qword [sym.imp.KERNEL32.dll_GetFileSizeEx]
cmp eax, esi
je 0x180050f3c
mov rax, qword [rsp + 0x48]
cmp qword [rsp + 0x50], rax
je 0x180050f4a
mov rcx, rbx
call qword [sym.imp.KERNEL32.dll_CloseHandle]
jmp 0x180050ff0
mov dword [rsp + 0x40], esi
jmp 0x180050fa0
mov r8d, dword [rsp + 0x40]
cmp r8d, esi
je 0x180050fc7
lea r9, [rsp + 0x44]
lea rdx, [rsp + 0x1060]
mov rcx, rbx
mov dword [rsp + 0x44], esi
mov qword [rsp + 0x20], rsi
call qword [sym.imp.KERNEL32.dll_ReadFile]
cmp eax, esi
je 0x180050f3c
mov eax, dword [rsp + 0x40]
cmp eax, dword [rsp + 0x44]
jne 0x180050f3c
lea rdx, [rsp + 0x1060]
lea rcx, [rsp + 0x60]
mov r8, rax
call fcn.1800a4090
cmp eax, esi
jne 0x180050f3c
lea r9, [rsp + 0x40]
lea rdx, [rsp + 0x60]
mov r8d, 0x1000
mov rcx, rdi
mov qword [rsp + 0x20], rsi
call qword [sym.imp.KERNEL32.dll_ReadFile]
cmp eax, esi
jne 0x180050f50
jmp 0x180050f3c
mov esi, 1
jmp 0x180050f3c
cmp rax, 0xffffffffffffffff
je 0x180050fe5
cmp rax, rsi
je 0x180050fe5
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_CloseHandle]
cmp rdi, 0xffffffffffffffff
je 0x180050ff9
cmp rdi, rsi
je 0x180050ff9
mov rcx, rdi
call qword [sym.imp.KERNEL32.dll_CloseHandle]
mov eax, esi
mov rcx, qword [rsp + 0x2060]
xor rcx, rsp
call fcn.180099fe0
lea r11, [rsp + 0x2070]
mov rbx, qword [r11 + 0x20]
mov rsi, qword [r11 + 0x28]
mov rsp, r11
pop rdi
ret

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

Disassembly:
push rbx
sub rsp, 0x20
mov rbx, rcx
call qword [sym.imp.KERNEL32.dll_GetFileAttributesW]
cmp eax, 0xffffffff
jne 0x180051043
mov ecx, 2
call qword [sym.imp.KERNEL32.dll_SetLastError]
xor eax, eax
jmp 0x18005105e
test al, 1
je 0x180051055
and eax, 0xfffffffe
mov rcx, rbx
mov edx, eax
call qword [sym.imp.KERNEL32.dll_SetFileAttributesW]
mov rcx, rbx
call qword [sym.imp.KERNEL32.dll_DeleteFileW]
add rsp, 0x20
pop rbx
ret
Function at 0x180051064
Capabilities:
Check if file exists
Delete directory

Disassembly:
mov qword [rsp + 0x10], rbx
push rdi
sub rsp, 0x30
mov rdi, rcx
call qword [sym.imp.KERNEL32.dll_lstrlenW]
xor ebx, ebx
cmp eax, ebx
jne 0x180051081
xor eax, eax
jmp 0x1800510c1
xor r9d, r9d
lea rax, [0x1800510e0]
lea r8, [0x1800510cc]
lea edx, [r9 + 1]
mov rcx, rdi
mov qword [rsp + 0x28], rbx
mov qword [rsp + 0x20], rax
call fcn.18004fd0c
mov rcx, rdi
call qword [sym.imp.KERNEL32.dll_RemoveDirectoryW]
mov rcx, rdi
call qword [sym.imp.SHLWAPI.dll_PathFileExistsW]
cmp eax, ebx
sete bl
mov eax, ebx
mov rbx, qword [rsp + 0x48]
add rsp, 0x30
pop rdi
ret

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

Disassembly:
mov qword [rsp + 8], rbx
mov qword [rsp + 0x10], rsi
push rdi
sub rsp, 0x20
mov edi, r8d
mov esi, edx
mov rbx, rcx
call qword [sym.imp.KERNEL32.dll_GetFileAttributesW]
cmp eax, 0xffffffff
jne 0x180051186
xor eax, eax
jmp 0x180051197
or eax, esi
not edi
mov rcx, rbx
and eax, edi
mov edx, eax
call qword [sym.imp.KERNEL32.dll_SetFileAttributesW]
mov rbx, qword [rsp + 0x30]
mov rsi, qword [rsp + 0x38]
add rsp, 0x20
pop rdi
ret

Function at 0x180051508
Capabilities:
Check if file exists
Delete file
Write file on windows

Disassembly:
mov qword [rsp + 8], rbx
mov qword [rsp + 0x10], rbp
push rsi
push rdi
push r12
sub rsp, 0x40
mov ebp, r8d
mov r12, rdx
mov rdi, rcx
call qword [sym.imp.SHLWAPI.dll_PathFileExistsW]
mov esi, eax
test eax, eax
jne 0x180051541
xor edx, edx
mov rcx, rdi
call fcn.180050354
test eax, eax
je 0x1800515ed
and qword [rsp + 0x30], 0
and dword [rsp + 0x28], 0
xor r9d, r9d
xor r8d, r8d
mov edx, 0x40000000
mov rcx, rdi
mov dword [rsp + 0x20], 2
call qword [sym.imp.KERNEL32.dll_CreateFileW]
mov rbx, rax
test rax, rax
je 0x1800515cc
cmp rax, 0xffffffffffffffff
je 0x1800515cc
and dword [rsp + 0x78], 0
and qword [rsp + 0x20], 0
lea r9, [rsp + 0x78]
mov r8d, ebp
mov rdx, r12
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_WriteFile]
test eax, eax
je 0x1800515af
cmp dword [rsp + 0x78], ebp
jne 0x1800515af
mov rcx, rbx
call qword [sym.imp.KERNEL32.dll_CloseHandle]
mov eax, 1
jmp 0x1800515ef
test esi, esi
jne 0x1800515d9
mov rcx, rbx
or rbx, 0xffffffffffffffff
cmp rcx, rbx
je 0x1800515d0
test rcx, rcx
je 0x1800515d0
call qword [sym.imp.KERNEL32.dll_CloseHandle]
jmp 0x1800515d0
test esi, esi
jne 0x1800515d9
mov rcx, rdi
call qword [sym.imp.KERNEL32.dll_DeleteFileW]
cmp rbx, 0xffffffffffffffff
je 0x1800515ed
test rbx, rbx
je 0x1800515ed
mov rcx, rbx
call qword [sym.imp.KERNEL32.dll_CloseHandle]
xor eax, eax
mov rbx, qword [rsp + 0x60]
mov rbp, qword [rsp + 0x68]
add rsp, 0x40
pop r12
pop rdi
pop rsi
ret
Function at 0x180051898
Capabilities:
Encode data using xor
Hash data with crc32

Disassembly:
push rbx
sub rsp, 0x140
mov rax, qword [0x180101090]
xor rax, rsp
mov qword [rsp + 0x130], rax
lea rcx, [rsp + 0x21]
xor ebx, ebx
xor edx, edx
mov r8d, 0x103
mov byte [rsp + 0x20], bl
call fcn.18009e990
lea rcx, [rsp + 0x20]
mov edx, 0x104
call fcn.180051788
mov r11d, 0x179b06cc
movzx edx, byte [rsp + rbx + 0x20]
movzx eax, r11b
mov ecx, r11d
xor rdx, rax
shr ecx, 8
lea rax, [0x180105f20]
mov r11d, dword [rax + rdx*4]
inc rbx
xor r11d, ecx
cmp rbx, 0x24
jl 0x1800518e0
not r11d
mov eax, r11d
mov rcx, qword [rsp + 0x130]
xor rcx, rsp
call fcn.180099fe0
add rsp, 0x140
pop rbx
ret

Function at 0x1800519a0
Capabilities:
Get storage device properties

Disassembly:
mov qword [rsp + 0x10], rbx
push rdi
sub rsp, 0xb0
mov rax, qword [0x180101090]
xor rax, rsp
mov qword [rsp + 0xa8], rax
movsx r8d, cl
lea rdx, str.__c:
lea rcx, [rsp + 0x48]
call fcn.180053b08
cmp qword [rax + 0x20], 0x10
jb 0x1800519e1
mov rcx, qword [rax + 8]
jmp 0x1800519e5
lea rcx, [rax + 8]
and qword [rsp + 0x30], 0
and dword [rsp + 0x28], 0
mov r8d, 3
xor r9d, r9d
mov edx, 0x80000000
mov dword [rsp + 0x20], r8d
call qword [sym.imp.KERNEL32.dll_CreateFileA]
cmp qword [rsp + 0x68], 0x10
mov rbx, rax
jb 0x180051a1e
mov rcx, qword [rsp + 0x50]
call fcn.18009a864
and qword [rsp + 0x60], 0
or rdi, 0xffffffffffffffff
mov qword [rsp + 0x68], socket
mov byte [rsp + 0x50], 0
test rbx, rbx
je 0x180051ac2
cmp rbx, rdi
je 0x180051ad5
lea r8d, [rdi + 0x25]
lea rcx, [rsp + 0x84]
xor edx, edx
mov dword [rsp + 0x80], 0x28
call fcn.18009e990
and dword [rsp + 0x70], 0
and dword [rsp + 0x74], 0
xor eax, eax
lea r9d, [rdi + 0xd]
and qword [rsp + 0x38], rax
and dword [rsp + 0x40], eax
mov dword [rsp + 0x78], eax
lea rax, [rsp + 0x40]
lea r8, [rsp + 0x70]
mov edx, 0x2d1400
mov qword [rsp + 0x30], rax
lea rax, [rsp + 0x80]
mov rcx, rbx
mov dword [rsp + 0x28], 0x28
mov qword [rsp + 0x20], rax
call qword [sym.imp.KERNEL32.dll_DeviceIoControl]
test eax, eax
je 0x180051acc
mov edi, dword [rsp + 0x9c]
jmp 0x180051acc
cmp rbx, rdi
je 0x180051ad5
test rbx, rbx
je 0x180051ad5
mov rcx, rbx
call qword [sym.imp.KERNEL32.dll_CloseHandle]
mov eax, edi
mov rcx, qword [rsp + 0xa8]
xor rcx, rsp
call fcn.180099fe0
mov rbx, qword [rsp + 0xc8]
add rsp, 0xb0
pop rdi
ret
Function at 0x180051af8
Capabilities:
Get disk information

Disassembly:
mov qword [rsp + 0x18], rbx
mov qword [rsp + 0x20], rbp
push rsi
push rdi
push r12
sub rsp, 0x250
mov rax, qword [0x180101090]
xor rax, rsp
mov qword [rsp + 0x240], rax
xor r12d, r12d
mov rsi, rdx
mov rdi, rcx
cmp rdx, r12
je 0x180051bda
lea rdx, str.deviceMup_
call qword [sym.imp.SHLWAPI.dll_StrStrIW]
cmp rax, rdi
jne 0x180051b63
lea r8, [0x1800d3584]
lea rdx, str.deviceMup_
mov r9, rsi
mov rcx, rdi
call fcn.1800535d8
mov eax, 1
jmp 0x180051bdc
call qword [sym.imp.KERNEL32.dll_GetLogicalDrives]
mov ebx, r12d
mov ebp, eax
bt ebp, ebx
jae 0x180051bd3
lea ecx, [rbx + 0x61]
mov eax, 0x3a
xor edx, edx
mov word [rsp + 0x20], cx
mov word [rsp + 0x22], ax
xor eax, eax
lea rcx, [rsp + 0x32]
mov r8d, 0x206
mov word [rsp + 0x30], r12w
mov dword [rsp + 0x24], eax
call fcn.18009e990
lea rdx, [rsp + 0x30]
lea rcx, [rsp + 0x20]
mov r8d, 0x104
call qword [sym.imp.KERNEL32.dll_QueryDosDeviceW]
cmp eax, r12d
jbe 0x180051bd3
lea rdx, [rsp + 0x30]
xor r8d, r8d
mov rcx, rdi
call fcn.18005398c
cmp eax, r12d
jne 0x180051c04
inc ebx
cmp ebx, 0x1a
jl 0x180051b6e
xor eax, eax
mov rcx, qword [rsp + 0x240]
xor rcx, rsp
call fcn.180099fe0
lea r11, [rsp + 0x250]
mov rbx, qword [r11 + 0x30]
mov rbp, qword [r11 + 0x38]
mov rsp, r11
pop r12
pop rdi
pop rsi
ret
lea r8, [rsp + 0x20]
lea rdx, [rsp + 0x30]
jmp 0x180051b51

Function at 0x180051f80
Capabilities:
Enumerate process modules

Disassembly:
mov qword [rsp + 0x18], rbx
push rdi
sub rsp, 0x470
mov rax, qword [0x180101090]
xor rax, rsp
mov qword [rsp + 0x460], rax
mov ebx, ecx
mov rdi, rdx
lea rcx, [rsp + 0x24]
xor edx, edx
mov r8d, 0x434
call fcn.18009e990
mov edx, ebx
mov ecx, 8
mov dword [rsp + 0x20], 0x438
call sub.KERNEL32.dll_CreateToolhelp32Snapshot
mov rbx, rax
test rax, rax
je 0x180052009
cmp rax, 0xffffffffffffffff
je 0x18005201d
lea rdx, [rsp + 0x20]
mov rcx, rax
call sub.KERNEL32.dll_Module32FirstW
jmp 0x180052005
lea rcx, [rsp + 0x20]
mov rdx, rdi
call fcn.180052d30
test eax, eax
je 0x180052009
lea rdx, [rsp + 0x20]
mov rcx, rbx
call sub.KERNEL32.dll_Module32NextW
test eax, eax
jne 0x180051fe7
cmp rbx, 0xffffffffffffffff
je 0x18005201d
test rbx, rbx
je 0x18005201d
mov rcx, rbx
call qword [sym.imp.KERNEL32.dll_CloseHandle]
mov rcx, qword [rsp + 0x460]
xor rcx, rsp
call fcn.180099fe0
mov rbx, qword [rsp + 0x490]
add rsp, 0x470
pop rdi
ret
Function at 0x180052040
Capabilities:
Enumerate processes

Disassembly:
mov rax, rsp
push rdi
sub rsp, 0x280
mov qword [rsp + 0x28], 0xfffffffffffffffe
mov qword [rax + 0x18], rbx
mov qword [rax + 0x20], rsi
mov rax, qword [0x180101090]
xor rax, rsp
mov qword [rsp + 0x270], rax
mov rsi, rdx
mov rdi, rcx
xor edx, edx
lea ecx, [rdx + 2]
call sub.KERNEL32.dll_CreateToolhelp32Snapshot
mov rbx, rax
mov qword [rsp + 0x20], rax
test rax, rax
je 0x1800520db
cmp rax, 0xffffffffffffffff
je 0x1800520db
mov dword [rsp + 0x30], 0x238
xor edx, edx
mov r8d, 0x234
lea rcx, [rsp + 0x34]
call fcn.18009e990
lea rdx, [rsp + 0x30]
mov rcx, rbx
call sub.KERNEL32.dll_Process32FirstW
test eax, eax
je 0x1800520db
mov rdx, rsi
lea rcx, [rsp + 0x30]
call rdi
test eax, eax
je 0x1800520db
lea rdx, [rsp + 0x30]
mov rcx, rbx
call sub.KERNEL32.dll_Process32NextW
test eax, eax
jne 0x1800520bc
cmp rbx, 0xffffffffffffffff
je 0x1800520ef
test rbx, rbx
je 0x1800520ef
mov rcx, rbx
call qword [sym.imp.KERNEL32.dll_CloseHandle]
mov rcx, qword [rsp + 0x270]
xor rcx, rsp
call fcn.180099fe0
lea r11, [rsp + 0x280]
mov rbx, qword [r11 + 0x20]
mov rsi, qword [r11 + 0x28]
mov rsp, r11
pop rdi
ret

Function at 0x180052114
Capabilities:
Create process on windows

Disassembly:
mov qword [rsp + 8], rbx
mov qword [rsp + 0x10], rsi
push rdi
sub rsp, 0xe0
xor ebx, ebx
mov edi, r8d
mov rsi, rcx
cmp rcx, rbx
jne 0x18005213a
xor eax, eax
jmp 0x1800521e6
xor edx, edx
lea rcx, [rsp + 0x78]
mov dword [rsp + 0x70], 0x68
lea r8d, [rdx + 0x60]
call fcn.18009e990
cmp edi, ebx
jne 0x180052169
mov dword [rsp + 0xac], 1
mov word [rsp + 0xb0], bx
xor eax, eax
mov rcx, rsi
mov qword [rsp + 0x50], rbx
mov qword [rsp + 0x58], rax
mov qword [rsp + 0x60], rax
call fcn.18004fcc0
mov rsi, rax
lea rcx, [rsp + 0x50]
neg edi
mov qword [rsp + 0x48], rcx
sbb eax, eax
lea rcx, [rsp + 0x70]
mov qword [rsp + 0x40], rcx
mov qword [rsp + 0x38], rbx
not eax
and eax, 0x8000000
mov qword [rsp + 0x30], rbx
xor r9d, r9d
mov dword [rsp + 0x28], eax
xor r8d, r8d
mov rdx, rsi
xor ecx, ecx
mov dword [rsp + 0x20], ebx
call qword [sym.imp.KERNEL32.dll_CreateProcessW]
cmp eax, ebx
je 0x1800521db
mov rcx, qword [rsp + 0x58]
mov rbx, qword [rsp + 0x50]
call qword [sym.imp.KERNEL32.dll_CloseHandle]
mov rcx, rsi
call fcn.18009a9fc
mov rax, rbx
lea r11, [rsp + 0xe0]
mov rbx, qword [r11 + 0x10]
mov rsi, qword [r11 + 0x18]
mov rsp, r11
pop rdi
ret
Function at 0x180052330
Capabilities:
Create process on windows

Disassembly:
mov qword [rsp + 0x10], rbx
mov qword [rsp + 0x18], rsi
push rdi
sub rsp, 0x110
xor edi, edi
mov rsi, rcx
cmp rcx, rdi
je 0x1800524ed
call fcn.1800521fc
lea rcx, [0x180052504]
mov dword [rsp + 0x6c], edi
mov dword [rsp + 0x70], edi
mov dword [rsp + 0x68], eax
cmp rcx, rdi
je 0x1800524ed
lea rdx, [rsp + 0x68]
call fcn.180052040
cmp dword [rsp + 0x70], edi
je 0x1800524ed
mov r8d, dword [rsp + 0x6c]
xor edx, edx
mov ecx, 0x400
call qword [sym.imp.KERNEL32.dll_OpenProcess]
mov rbx, rax
cmp rax, rdi
je 0x1800524d9
cmp rax, 0xffffffffffffffff
je 0x1800524ed
lea r8, [rsp + 0x60]
mov edx, 0xf01ff
mov rcx, rax
mov qword [rsp + 0x60], rdi
call qword [sym.imp.ADVAPI32.dll_OpenProcessToken]
cmp eax, edi
je 0x1800524cb
mov rdx, qword [rsp + 0x60]
lea rcx, [rsp + 0x78]
xor r8d, r8d
mov qword [rsp + 0x78], rdi
call qword [sym.imp.USERENV.dll_CreateEnvironmentBlock]
cmp eax, edi
je 0x1800524c0
mov rcx, rsi
call fcn.18004fcc0
lea r8d, [rdi + 0x60]
lea rcx, [rsp + 0xa8]
xor edx, edx
mov dword [rsp + 0xa0], 0x68
mov rsi, rax
call fcn.18009e990
mov rcx, qword [rsp + 0x60]
lea eax, [rdi + 5]
mov word [rsp + 0xe0], ax
xor eax, eax
xor r9d, r9d
mov qword [rsp + 0x88], rax
mov qword [rsp + 0x90], rax
lea rax, [rsp + 0x80]
mov qword [rsp + 0x50], rax
lea rax, [rsp + 0xa0]
mov r8, rsi
mov qword [rsp + 0x48], rax
mov rax, qword [rsp + 0x78]
mov qword [rsp + 0x40], rdi
mov qword [rsp + 0x38], rax
mov dword [rsp + 0x30], 0x420
xor edx, edx
mov dword [rsp + 0x28], edi
mov dword [rsp + 0xdc], 1
mov qword [rsp + 0x80], rdi
mov qword [rsp + 0x20], rdi
call qword [sym.imp.ADVAPI32.dll_CreateProcessAsUserW]
cmp eax, edi
je 0x1800524ad
mov rcx, qword [rsp + 0x88]
mov rdi, qword [rsp + 0x80]
call qword [sym.imp.KERNEL32.dll_CloseHandle]
mov rcx, rsi
call fcn.18009a9fc
mov rcx, qword [rsp + 0x78]
call qword [sym.imp.USERENV.dll_DestroyEnvironmentBlock]
mov rcx, qword [rsp + 0x60]
call qword [sym.imp.KERNEL32.dll_CloseHandle]
mov rcx, rbx
call qword [sym.imp.KERNEL32.dll_CloseHandle]
mov rax, rdi
jmp 0x1800524ef
cmp rax, 0xffffffffffffffff
je 0x1800524ed
cmp rax, rdi
je 0x1800524ed
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_CloseHandle]
xor eax, eax
lea r11, [rsp + 0x110]
mov rbx, qword [r11 + 0x18]
mov rsi, qword [r11 + 0x20]
mov rsp, r11
pop rdi
ret
Function at 0x180052744
Capabilities:
Get process image filename

Disassembly:
mov qword [rsp + 0x18], rbx
mov qword [rsp + 0x20], rsi
push rdi
sub rsp, 0x240
mov rax, qword [0x180101090]
xor rax, rsp
mov qword [rsp + 0x230], rax
mov rsi, rdx
mov r8d, ecx
xor edx, edx
mov ecx, 0x410
call qword [sym.imp.KERNEL32.dll_OpenProcess]
xor edi, edi
mov rbx, rax
cmp rax, rdi
je 0x1800527d8
cmp rax, 0xffffffffffffffff
je 0x1800527ec
lea rcx, [rsp + 0x22]
xor edx, edx
mov r8d, 0x206
mov word [rsp + 0x20], di
call fcn.18009e990
lea rdx, [rsp + 0x20]
mov r8d, 0x104
mov rcx, rbx
call sub.PSAPI.DLL_GetProcessImageFileNameW
cmp eax, edi
jbe 0x1800527cb
lea rcx, [rsp + 0x20]
mov rdx, rsi
call fcn.180051af8
mov edi, 1
mov rcx, rbx
call qword [sym.imp.KERNEL32.dll_CloseHandle]
mov eax, edi
jmp 0x1800527ee
cmp rax, 0xffffffffffffffff
je 0x1800527ec
cmp rax, rdi
je 0x1800527ec
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_CloseHandle]
xor eax, eax
mov rcx, qword [rsp + 0x230]
xor rcx, rsp
call fcn.180099fe0
lea r11, [rsp + 0x240]
mov rbx, qword [r11 + 0x20]
mov rsi, qword [r11 + 0x28]
mov rsp, r11
pop rdi
ret

Function at 0x180052eac
Capabilities:
Parse pe header

Disassembly:
mov qword [rsp + 8], rbx
mov qword [rsp + 0x10], rsi
push rdi
sub rsp, 0x20
xor ebx, ebx
mov rsi, rdx
cmp rcx, rbx
je 0x180052f11
mov eax, 0x5a4d
cmp ax, word [rcx]
jne 0x180052f11
cmp dword [rcx + 0x3c], 0x400
jge 0x180052f11
movsxd rdi, dword [rcx + 0x3c]
lea edx, [rbx + 8]
add rdi, rcx
mov rcx, rdi
call qword [sym.imp.KERNEL32.dll_IsBadReadPtr]
cmp eax, ebx
jne 0x180052f11
cmp dword [rdi], 0x4550
jne 0x180052f11
cmp rsi, rbx
je 0x180052f0a
mov eax, pe_nt_image_headers64
cmp word [rdi + 0x14], ax
sete bl
mov dword [rsi], ebx
mov eax, 1
jmp 0x180052f13
xor eax, eax
mov rbx, qword [rsp + 0x30]
mov rsi, qword [rsp + 0x38]
add rsp, 0x20
pop rdi
ret

Function at 0x180052f24
Capabilities:
Get file size
Read file via mapping

Disassembly:
mov qword [rsp + 8], rbx
push rdi
sub rsp, 0x40
and qword [rsp + 0x30], 0
mov rax, rdx
xor r9d, r9d
mov rbx, rcx
lea r8d, [r9 + 1]
mov edx, 0x80000000
mov rcx, rax
mov dword [rsp + 0x28], 0x80
mov dword [rsp + 0x20], 3
call qword [sym.imp.KERNEL32.dll_CreateFileW]
mov qword [rbx], rax
cmp rax, 0xffffffffffffffff
je 0x180052fd6
lea rdx, [rbx + 0x18]
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_GetFileSizeEx]
test eax, eax
je 0x180052fd6
cmp qword [rbx + 0x18], 0
je 0x180052fd6
mov eax, 0x400000
cmp qword [rbx + 0x18], rax
jg 0x180052f8e
mov eax, dword [rbx + 0x18]
mov rcx, qword [rbx]
and qword [rsp + 0x28], 0
and dword [rsp + 0x20], 0
xor r9d, r9d
xor edx, edx
mov dword [rbx + 0x20], eax
lea r8d, [r9 + 2]
call qword [sym.imp.KERNEL32.dll_CreateFileMappingW]
mov qword [rbx + 8], rax
test rax, rax
je 0x180052fd6
mov ecx, dword [rbx + 0x20]
xor r9d, r9d
xor r8d, r8d
mov qword [rsp + 0x20], rcx
lea edx, [r9 + 4]
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_MapViewOfFile]
mov qword [rbx + 0x10], rax
mov rax, rbx
mov rbx, qword [rsp + 0x50]
add rsp, 0x40
pop rdi
ret
Function at 0x180052fe4
Capabilities:
Check if file exists

Disassembly:
mov rax, rsp
mov qword [rax + 8], rbx
push rdi
sub rsp, 0x50
or qword [rax - 0x38], 0xffffffffffffffff
and qword [rax - 0x30], 0
and qword [rax - 0x28], 0
mov rdi, rdx
mov rbx, rcx
call qword [sym.imp.SHLWAPI.dll_PathFileExistsW]
test eax, eax
je 0x18005301c
lea rcx, [rsp + 0x20]
mov rdx, rbx
call fcn.180052f24
mov rcx, qword [rsp + 0x30]
test rcx, rcx
je 0x18005304d
cmp qword [rsp + 0x38], 0x138
jbe 0x180053040
mov rdx, rdi
call fcn.180052eac
mov rcx, qword [rsp + 0x30]
jmp 0x180053042
xor eax, eax
test eax, eax
je 0x18005304d
mov ebx, 1
jmp 0x18005304f
xor ebx, ebx
test rcx, rcx
je 0x18005305a
call qword [sym.imp.KERNEL32.dll_UnmapViewOfFile]
mov rcx, qword [rsp + 0x28]
test rcx, rcx
je 0x18005306a
call qword [sym.imp.KERNEL32.dll_CloseHandle]
mov rcx, qword [rsp + 0x20]
cmp rcx, 0xffffffffffffffff
je 0x18005307b
call qword [sym.imp.KERNEL32.dll_CloseHandle]
mov eax, ebx
mov rbx, qword [rsp + 0x60]
add rsp, 0x50
pop rdi
ret

Function at 0x180053bb0
Capabilities:
Set registry value

Disassembly:
mov r11, rsp
mov dword [r11 + 0x20], r9d
sub rsp, 0x38
lea rax, [r11 + 0x20]
mov r9d, 4
mov dword [r11 - 0x10], r9d
mov qword [r11 - 0x18], rax
call qword [sym.imp.SHLWAPI.dll_SHSetValueW]
xor ecx, ecx
cmp eax, ecx
sete cl
mov eax, ecx
add rsp, 0x38
ret

Function at 0x180053be4
Capabilities:
Set registry value

Disassembly:
push rbx
push rbp
push rsi
push rdi
push r12
sub rsp, 0x40
mov rax, qword [0x180101090]
xor rax, rsp
mov qword [rsp + 0x30], rax
xor ebx, ebx
mov rdi, r9
mov r12, r8
mov rbp, rdx
mov rsi, rcx
cmp r9, rbx
je 0x180053c1c
mov rcx, r9
call qword [sym.imp.KERNEL32.dll_lstrlenW]
jmp 0x180053c1e
mov eax, ebx
lea r9d, [rax + rax + 2]
mov r8, r12
mov rdx, rbp
mov dword [rsp + 0x28], r9d
mov r9d, 1
mov rcx, rsi
mov qword [rsp + 0x20], rdi
call qword [sym.imp.SHLWAPI.dll_SHSetValueW]
cmp eax, ebx
sete bl
mov eax, ebx
mov rcx, qword [rsp + 0x30]
xor rcx, rsp
call fcn.180099fe0
add rsp, 0x40
pop r12
pop rdi
pop rsi
pop rbp
pop rbx
ret