joyce8/EMBER2024-capa huggingface dataset:
Function at 0x1400075c0
Capabilities:
Allocate or change rwx memory

Disassembly:
push rdi
push rsi
push rbx
sub rsp, 0x50
movsxd rsi, dword [0x140014224]
mov rbx, rcx
test esi, esi
jle 0x1400076f0
mov rax, qword [0x140014228]
xor r9d, r9d
add rax, 0x18
nop word [rax + rax]
mov r8, qword [rax]
cmp rbx, r8
jb 0x14000760b
mov rdx, qword [rax + 8]
mov edx, dword [rdx + 8]
add r8, rdx
cmp rbx, r8
jb 0x140007695
add r9d, 1
add rax, 0x28
cmp r9d, esi
jne 0x1400075f0
mov rcx, rbx
call fcn.140008010
mov rdi, rax
test rax, rax
je 0x140007712
mov rax, qword [0x140014228]
lea rbx, [rsi + rsi*4]
shl rbx, 3
add rax, rbx
mov qword [rax + 0x20], rdi
mov dword [rax], 0
call fcn.140008150
mov edx, dword [rdi + 0xc]
mov r8d, 0x30
lea rcx, [rax + rdx]
mov rax, qword [0x140014228]
lea rdx, [rsp + 0x20]
mov qword [rax + rbx + 0x18], rcx
call qword [sym.imp.KERNEL32.dll_VirtualQuery]
test rax, rax
je 0x1400076f7
mov eax, dword [rsp + 0x44]
lea edx, [rax - 0x40]
and edx, 0xffffffbf
je 0x14000768e
lea edx, [rax - 4]
and edx, 0xfffffffb
jne 0x1400076a0
add dword [0x140014224], 1
add rsp, 0x50
pop rbx
pop rsi
pop rdi
ret
cmp eax, 2
mov rcx, qword [rsp + 0x20]
mov rdx, qword [rsp + 0x38]
mov r8d, 0x40
mov eax, 4
cmove r8d, eax
add rbx, qword [0x140014228]
mov qword [rbx + 8], rcx
mov r9, rbx
mov qword [rbx + 0x10], rdx
call qword [sym.imp.KERNEL32.dll_VirtualProtect]
test eax, eax
jne 0x14000768e
call qword [sym.imp.KERNEL32.dll_GetLastError]
lea rcx, str.__VirtualProtect_failed_with_code_0x_x
mov edx, eax
call fcn.140007550
nop dword [rax]
xor esi, esi
jmp 0x140007618
mov rax, qword [0x140014228]
mov edx, dword [rdi + 8]
lea rcx, str.__VirtualQuery_failed_for__d_bytes_at_address__p
mov r8, qword [rax + rbx + 0x18]
call fcn.140007550
mov rdx, rbx
lea rcx, str.Address__p_has_no_image_section
call fcn.140007550
nop
nop word cs:[rax + rax]
nop dword [rax]

Function at 0x140007c80
Capabilities:
Get thread local storage value

Disassembly:
push r12
push rbp
push rdi
push rsi
push rbx
sub rsp, 0x20
lea r12, [0x140014280]
mov rcx, r12
call qword [sym.imp.KERNEL32.dll_EnterCriticalSection]
mov rbx, qword [0x140014260]
test rbx, rbx
je 0x140007cdc
mov rbp, qword [sym.imp.KERNEL32.dll_TlsGetValue]
mov rdi, qword [sym.imp.KERNEL32.dll_GetLastError]
nop dword [rax]
mov ecx, dword [rbx]
call rbp
mov rsi, rax
call rdi
test eax, eax
jne 0x140007cd3
test rsi, rsi
je 0x140007cd3
mov rax, qword [rbx + 8]
mov rcx, rsi
call rax
mov rbx, qword [rbx + 0x10]
test rbx, rbx
jne 0x140007cb8
mov rcx, r12
add rsp, 0x20
pop rbx
pop rsi
pop rdi
pop rbp
pop r12
jmp qword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
Function at 0x140008010
Capabilities:
Enumerate pe sections
Parse pe header

Disassembly:
mov rdx, qword [0x140011320]
xor eax, eax
cmp word [rdx], 0x5a4d
jne 0x140008030
movsxd r8, dword [rdx + 0x3c]
add r8, rdx
cmp dword [r8], 0x4550
je 0x140008038
ret
cmp word [r8 + 0x18], 0x20b
jne 0x140008030
movzx eax, word [r8 + 0x14]
sub rcx, rdx
lea rax, [r8 + rax + 0x18]
movzx r8d, word [r8 + 6]
test r8w, r8w
je 0x14000808d
lea edx, [r8 - 1]
lea rdx, [rdx + rdx*4]
lea r9, [rax + rdx*8 + 0x28]
nop word cs:[rax + rax]
mov r8d, dword [rax + 0xc]
mov rdx, r8
cmp rcx, r8
jb 0x140008084
add edx, dword [rax + 8]
cmp rcx, rdx
jb 0x140008030
add rax, 0x28
cmp rax, r9
jne 0x140008070
xor eax, eax
ret

Function at 0x140008090
Capabilities:
Parse pe header

Disassembly:
mov rax, qword [0x140011320]
xor ecx, ecx
cmp word [rax], 0x5a4d
jne 0x1400080af
movsxd rdx, dword [rax + 0x3c]
add rax, rdx
cmp dword [rax], 0x4550
je 0x1400080b8
mov eax, ecx
ret
cmp word [rax + 0x18], 0x20b
jne 0x1400080af
movzx ecx, word [rax + 6]
mov eax, ecx
ret

Function at 0x140008150
Capabilities:
Parse pe header

Disassembly:
mov rax, qword [0x140011320]
xor edx, edx
cmp word [rax], 0x5a4d
jne 0x14000816f
movsxd rcx, dword [rax + 0x3c]
add rcx, rax
cmp dword [rcx], 0x4550
je 0x140008178
mov rax, rdx
ret
cmp word [rcx + 0x18], 0x20b
cmove rdx, rax
mov rax, rdx
ret

Function at 0x140008420
Capabilities:
Allocate thread local storage

Disassembly:
sub rsp, 0x28
xor r9d, r9d
xor edx, edx
xor ecx, ecx
mov dword [0x140014300], 0xffffffff
mov r8d, 0xffff
call qword [sym.imp.KERNEL32.dll_CreateSemaphoreW]
mov qword [0x140014308], rax
call qword [sym.imp.KERNEL32.dll_TlsAlloc]
cmp eax, 0xffffffff
je 0x140008470
lea rdx, [0x140008330]
mov ecx, eax
mov dword [0x1400142f8], eax
call fcn.14000ddc0
test eax, eax
jne 0x140008478
add rsp, 0x28
ret
call qword [sym.imp.KERNEL32.dll_GetLastError]
jmp 0x140008467
call sub.msvcrt.dll_abort
nop
nop
Function at 0x140008480
Capabilities:
Get thread local storage value
Set thread local storage value

Disassembly:
push r13
push r12
push rbp
push rdi
push rsi
push rbx
sub rsp, 0x28
mov rsi, qword [0x1400112b0]
mov r11d, dword [rsi]
mov rbx, rcx
test r11d, r11d
jne 0x1400084b8
mov rax, qword [rcx + 0x10]
test rax, rax
je 0x140008520
add rsp, 0x28
pop rbx
pop rsi
pop rdi
pop rbp
pop r12
pop r13
ret
mov r12, qword [rcx + 0x10]
test r12, r12
je 0x140008530
mov esi, dword [0x1400142f8]
mov r13, qword [sym.imp.KERNEL32.dll_GetLastError]
call r13
mov edi, eax
mov ecx, esi
call qword [sym.imp.KERNEL32.dll_TlsGetValue]
mov ecx, edi
mov rsi, rax
call qword [sym.imp.KERNEL32.dll_SetLastError]
test rsi, rsi
je 0x1400085a0
mov rbp, qword [rsi]
cmp rbp, r12
jb 0x1400085e8
sub r12, 1
mov rax, qword [rsi + r12*8 + 8]
test rax, rax
jne 0x1400084a7
mov rcx, rbx
call fcn.140008380
mov qword [rsi + r12*8 + 8], rax
jmp 0x1400084a7
call fcn.140008380
mov qword [rbx + 0x10], rax
jmp 0x1400084a7
mov r10d, dword [rsi]
test r10d, r10d
je 0x14000864a
mov r9d, dword [0x14000ef90]
test r9d, r9d
je 0x140008678
lock add dword [0x140014300], 1
jne 0x1400086ac
mov r12, qword [rbx + 0x10]
test r12, r12
je 0x140008657
mov eax, dword [rsi]
test eax, eax
je 0x1400084c1
lock sub dword [0x140014300], 1
js 0x1400084c1
mov rcx, qword [0x140014308]
xor r8d, r8d
mov edx, 1
call qword [sym.imp.KERNEL32.dll_ReleaseSemaphore]
jmp 0x1400084c1
lea rcx, [r12 + 0x21]
mov edx, 8
lea rdi, [r12 + 0x20]
call sub.msvcrt.dll_calloc
mov rsi, rax
test rax, rax
je 0x1400086d3
mov qword [rax], rdi
mov ecx, dword [0x1400142f8]
mov rdx, rsi
call qword [sym.imp.KERNEL32.dll_TlsSetValue]
test eax, eax
jne 0x1400084fb
call r13
jmp 0x1400084fb
lea rdi, [rbp + rbp]
lea rax, [r12 + 0x20]
mov rcx, rsi
cmp rdi, r12
cmovb rdi, rax
lea rdx, [rdi*8 + 8]
call sub.msvcrt.dll_realloc
mov rsi, rax
test rax, rax
je 0x1400086d3
mov qword [rax], rdi
sub rdi, rbp
lea rcx, [rax + rbp*8 + 8]
xor edx, edx
lea r8, [rdi*8]
call sub.msvcrt.dll_memset
jmp 0x1400085c3
call fcn.140008420
mov dword [0x14000ef90], 1
mov edx, dword [rsi]
test edx, edx
jne 0x14000854c
mov r12, qword [rbx + 0x10]
test r12, r12
jne 0x1400084c1
mov rax, qword [0x1400142f0]
lea r12, [rax + 1]
mov qword [0x1400142f0], r12
mov qword [rbx + 0x10], r12
jmp 0x140008567
lock add dword [0x14000ef94], 1
je 0x140008631
mov r8d, dword [0x14000ef90]
mov rbp, qword [sym.imp.KERNEL32.dll_Sleep]
lea rdi, [0x14000ef90]
test r8d, r8d
jne 0x140008640
nop dword [rax]
xor ecx, ecx
call rbp
mov ecx, dword [rdi]
test ecx, ecx
je 0x1400086a0
jmp 0x140008640
mov rcx, qword [0x140014308]
mov edx, 0xffffffff
call qword [sym.imp.KERNEL32.dll_WaitForSingleObject]
test eax, eax
je 0x14000855a
lock sub dword [0x140014300], 1
jmp 0x14000855a
call sub.msvcrt.dll_abort
nop
nop dword [rax]
cmp qword [rcx], rdx
jae 0x1400086f0
mov qword [rcx], rdx
mov qword [rcx + 0x18], 0
cmp qword [rcx + 8], r8
jae 0x1400086fa
mov qword [rcx + 8], r8
test r9, r9
je 0x140008704
cmp qword [rcx], rdx
je 0x140008708
ret
mov qword [rcx + 0x18], r9
ret
Function at 0x22522c0
Capabilities:
Terminate process

Disassembly:
cld
pop r11
jmp 0x22522cd
inc rsi
mov byte [rdi], dl
inc rdi
mov dl, byte [rsi]
add ebx, ebx
jne 0x22522dd
mov ebx, dword [rsi]
sub rsi, 0xfffffffffffffffc
adc ebx, ebx
mov dl, byte [rsi]
jb 0x22522c5
lea eax, [rcx + 1]
jmp 0x22522eb
dec eax
call r11
adc eax, eax
call r11
adc eax, eax
add ebx, ebx
jne 0x22522fe
mov ebx, dword [rsi]
sub rsi, 0xfffffffffffffffc
adc ebx, ebx
mov dl, byte [rsi]
jae 0x22522e4
sub eax, 3
jb 0x225231e
shl eax, 8
movzx edx, dl
or eax, edx
inc rsi
xor eax, 0xffffffff
je 0x225236d
sar eax, 1
movsxd rbp, eax
jb 0x2252354
jmp 0x225232c
add ebx, ebx
jne 0x225232a
mov ebx, dword [rsi]
sub rsi, 0xfffffffffffffffc
adc ebx, ebx
jb 0x2252354
inc ecx
add ebx, ebx
jne 0x225233a
mov ebx, dword [rsi]
sub rsi, 0xfffffffffffffffc
adc ebx, ebx
jb 0x2252354
call r11
adc ecx, ecx
add ebx, ebx
jne 0x225234d
mov ebx, dword [rsi]
sub rsi, 0xfffffffffffffffc
adc ebx, ebx
jae 0x225233c
add ecx, 2
jmp 0x2252359
call r11
adc ecx, ecx
cmp rbp, 0xfffffffffffffb00
adc ecx, 2
call fcn.02252282
jmp 0x22522cd
pop rsi
sub rsp, 0x28
lea rdi, [rsi + 0x1e32000]
mov eax, dword [rdi]
or eax, eax
je 0x22523c9
mov ebx, dword [rdi + 4]
lea rcx, [rax + rsi + 0x1e52000]
add rbx, rsi
add rdi, 8
call qword [sym.imp.KERNEL32.DLL_LoadLibraryA]
xchg rbp, rax
mov al, byte [rdi]
inc rdi
or al, al
je 0x2252379
mov rcx, rdi
mov rdx, rdi
dec eax
repne scasb al, byte [rdi]
mov rcx, rbp
call qword [sym.imp.KERNEL32.DLL_GetProcAddress]
or rax, rax
je 0x22523c3
mov qword [rbx], rax
add rbx, 8
jmp 0x2252399
jmp qword [sym.imp.KERNEL32.DLL_ExitProcess]
add rsp, 0x28
add rdi, 4
lea rbx, [rsi - 4]
xor eax, eax
mov al, byte [rdi]
inc rdi
or eax, eax
je 0x225240d
cmp al, 0xef
ja 0x22523f5
add rbx, rax
mov rax, qword [rbx]
bswap rax
add rax, rsi
mov qword [rbx], rax
jmp 0x22523d5
and al, 0xf
shl eax, 0x10
mov ax, word [rdi]
add rdi, 2
or eax, eax
jne 0x22523e4
mov eax, dword [rdi]
add rdi, 4
jmp 0x22523e4
mov rbp, qword [sym.imp.KERNEL32.DLL_VirtualProtect]
lea rdi, [rsi - 0x1000]
mov ebx, 0x1000
push rax
mov r9, rsp
mov r8d, 4
mov rdx, rbx
mov rcx, rdi
sub rsp, 0x20
call rbp
lea rax, [rdi + 0x1af]
and byte [rax], 0x7f
and byte [rax + 0x28], 0x7f
lea r9, [rsp + 0x20]
mov r8, qword [r9]
mov rdx, rbx
mov rcx, rdi
call rbp
add rsp, 0x28
pop rbp
pop rdi
pop rsi
pop rbx
lea rax, [rsp - 0x80]
push 0
cmp rsp, rax
jne 0x2252461
sub rsp, 0xffffffffffffff80
jmp 0x4683c0
Function at 0x141557058
Capabilities:
Decompress data using aplib

Disassembly:
call fcn.1415571df
push r10
mov r10, rsp
push r10
mov rsi, qword [r10 + 0x10]
mov rdi, qword [r10 + 0x20]
cld
mov dl, 0x80
mov al, byte [rsi]
inc rsi
mov byte [rdi], al
inc rdi
mov ebx, 2
add dl, dl
jne 0x141557089
mov dl, byte [rsi]
inc rsi
adc dl, dl
jae 0x14155706f
add dl, dl
jne 0x141557096
mov dl, byte [rsi]
inc rsi
adc dl, dl
jae 0x1415570f6
xor eax, eax
add dl, dl
jne 0x1415570a5
mov dl, byte [rsi]
inc rsi
adc dl, dl
jae 0x1415571ad
add dl, dl
jne 0x1415570b6
mov dl, byte [rsi]
inc rsi
adc dl, dl
adc eax, eax
add dl, dl
jne 0x1415570c3
mov dl, byte [rsi]
inc rsi
adc dl, dl
adc eax, eax
add dl, dl
jne 0x1415570d0
mov dl, byte [rsi]
inc rsi
adc dl, dl
adc eax, eax
add dl, dl
jne 0x1415570dd
mov dl, byte [rsi]
inc rsi
adc dl, dl
adc eax, eax
je 0x1415570ea
push rdi
mov eax, eax
sub rdi, rax
mov al, byte [rdi]
pop rdi
mov byte [rdi], al
inc rdi
mov ebx, 2
jmp 0x14155707e
mov eax, 1
add dl, dl
jne 0x141557106
mov dl, byte [rsi]
inc rsi
adc dl, dl
adc eax, eax
add dl, dl
jne 0x141557113
mov dl, byte [rsi]
inc rsi
adc dl, dl
jb 0x1415570fb
sub eax, ebx
mov ebx, 1
jne 0x14155714c
mov ecx, 1
add dl, dl
jne 0x14155712e
mov dl, byte [rsi]
inc rsi
adc dl, dl
adc ecx, ecx
add dl, dl
jne 0x14155713b
mov dl, byte [rsi]
inc rsi
adc dl, dl
jb 0x141557123
push rsi
mov rsi, rdi
sub rsi, rbp
rep movsb byte [rdi], byte [rsi]
pop rsi
jmp 0x14155707e
dec eax
shl eax, 8
mov al, byte [rsi]
inc rsi
mov ebp, eax
mov ecx, 1
add dl, dl
jne 0x141557168
mov dl, byte [rsi]
inc rsi
adc dl, dl
adc ecx, ecx
add dl, dl
jne 0x141557175
mov dl, byte [rsi]
inc rsi
adc dl, dl
jb 0x14155715d
cmp eax, 0x7d00
jae 0x14155719b
cmp eax, 0x500
jb 0x141557196
inc ecx
push rsi
mov rsi, rdi
sub rsi, rax
rep movsb byte [rdi], byte [rsi]
pop rsi
jmp 0x14155707e
cmp eax, 0x7f
ja 0x14155719e
add ecx, 2
push rsi
mov rsi, rdi
sub rsi, rax
rep movsb byte [rdi], byte [rsi]
pop rsi
jmp 0x14155707e
mov al, byte [rsi]
inc rsi
xor ecx, ecx
shr al, 1
je 0x1415571d2
adc ecx, 2
mov ebp, eax
push rsi
mov rsi, rdi
sub rsi, rax
rep movsb byte [rdi], byte [rsi]
pop rsi
mov ebx, 1
jmp 0x14155707e
pop r10
sub rdi, qword [r10 + 0x20]
mov eax, edi
pop r10
ret 0x20
Function at 0x140001d40
Capabilities:
Query environment variable

Disassembly:
mov qword [rsp + 8], rbx
push rdi
sub rsp, 0x30
mov rbx, rdx
mov edi, ecx
call fcn.1400020c0
test eax, eax
jne 0x140001e7f
xor r8d, r8d
mov rdx, rbx
mov ecx, edi
call sym.run_py3.6_win_amd64.exe_PySys_SetArgvEx
mov rax, qword [0x14000c2a8]
test rax, rax
jne 0x140001dd3
mov r10, qword [0x14000c268]
mov rbx, qword [0x14000c370]
test r10, r10
je 0x140001da2
nop dword [rax + rax]
cmp rbx, qword [r10]
je 0x140001e8a
mov r10, qword [r10 + 0x10]
test r10, r10
jne 0x140001d90
xor ecx, ecx
call qword [sym.imp.KERNEL32.dll_SetLastError]
lea rdx, [0x14000b858]
mov rcx, rbx
call qword [sym.imp.KERNEL32.dll_GetProcAddress]
cmp rax, qword [sym.imp.KERNEL32.dll_GetModuleHandleExW]
lea rcx, [0x140004410]
cmove rax, rcx
mov qword [0x14000c2a8], rax
lea rcx, [0x14000b1fc]
call rax
mov rbx, rax
test rax, rax
je 0x140001e2a
xor r8d, r8d
lea rcx, str._MessageBox
xor edx, edx
call sym.run_py3.6_win_amd64.exe_PyCFunction_NewEx
mov rdx, qword [str._MessageBox]
mov r8, rax
mov rcx, rbx
call sym.run_py3.6_win_amd64.exe_PyObject_SetAttrString
xor r8d, r8d
lea rcx, str._SHGetSpecialFolderPath
xor edx, edx
call sym.run_py3.6_win_amd64.exe_PyCFunction_NewEx
mov rdx, qword [str._SHGetSpecialFolderPath]
mov r8, rax
mov rcx, rbx
call sym.run_py3.6_win_amd64.exe_PyObject_SetAttrString
call fcn.140002a60
lea rcx, [0x14000b3b8]
mov ebx, eax
call qword [sym.imp.api_ms_win_crt_environment_l1_1_0.dll_getenv]
test rax, rax
je 0x140001e78
xor ecx, ecx
call qword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll___acrt_iob_func]
mov rcx, rax
lea rdx, [0x14000b3b0]
call sym.run_py3.6_win_amd64.exe_Py_FdIsInteractive
test eax, eax
je 0x140001e78
xor ecx, ecx
call qword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll___acrt_iob_func]
xor r8d, r8d
lea rdx, [0x14000b3a8]
mov rcx, rax
call sym.run_py3.6_win_amd64.exe_PyRun_InteractiveLoopFlags
call sym.run_py3.6_win_amd64.exe_Py_Finalize
mov eax, ebx
mov rbx, qword [rsp + 0x40]
add rsp, 0x30
pop rdi
ret
mov eax, dword [r10 + 0x20]
lea rcx, [0x14000b578]
mov r9, qword [r10 + 8]
mov r8, rbx
xor edx, edx
mov dword [rsp + 0x20], eax
call fcn.140004970
mov rcx, qword [r10]
lea rdx, [0x14000b858]
call fcn.1400032f0
jmp 0x140001dcc
Function at 0x140002d00
Capabilities:
Extract resource via kernel32 functions

Disassembly:
push rbx
sub rsp, 0x460
mov rax, qword [0x14000b008]
xor rax, rsp
mov qword [rsp + 0x450], rax
lea r8, str.PYTHONSCRIPT
mov edx, 1
xor ecx, ecx
call qword [sym.imp.KERNEL32.dll_FindResourceA]
test rax, rax
jne 0x140002d50
call qword [sym.imp.KERNEL32.dll_GetLastError]
mov ecx, 2
mov ebx, eax
call qword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll___acrt_iob_func]
lea rdx, str.Could_not_locate_script_resource:
jmp 0x140002db9
mov rdx, rax
xor ecx, ecx
call qword [sym.imp.KERNEL32.dll_LoadResource]
test rax, rax
jne 0x140002d7c
call qword [sym.imp.KERNEL32.dll_GetLastError]
mov ecx, 2
mov ebx, eax
call qword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll___acrt_iob_func]
lea rdx, str.Could_not_load_script_resource:
jmp 0x140002db9
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_LockResource]
mov qword [0x14000c458], rax
mov rcx, rax
mov qword [0x14000d2a8], rax
test rax, rax
jne 0x140002e30
call qword [sym.imp.KERNEL32.dll_GetLastError]
mov ecx, 2
mov ebx, eax
call qword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll___acrt_iob_func]
lea rdx, str.Could_not_lock_script_resource:
mov rcx, rax
call fcn.140001010
test ebx, ebx
je 0x140002e29
xor ecx, ecx
lea rax, [rsp + 0x40]
mov qword [rsp + 0x30], rcx
mov r9d, 0x400
mov dword [rsp + 0x28], ecx
mov r8d, ebx
mov ecx, 0x1100
mov qword [rsp + 0x20], rax
xor edx, edx
call qword [sym.imp.KERNEL32.dll_FormatMessageA]
mov rdx, qword [rsp + 0x40]
lea rcx, [rsp + 0x50]
mov r8d, 0x400
call qword [sym.imp.api_ms_win_crt_string_l1_1_0.dll_strncpy]
mov rcx, qword [rsp + 0x40]
call qword [sym.imp.KERNEL32.dll_LocalFree]
mov ecx, 2
call qword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll___acrt_iob_func]
mov rcx, rax
lea rdx, [rsp + 0x50]
call fcn.140001010
xor eax, eax
jmp 0x140002ec1
cmp dword [rcx], 0x78563412
lea rdx, [rcx + 0x10]
mov eax, dword [rax + 0xc]
mov qword [0x14000c458], rdx
mov dword [0x14000c454], eax
je 0x140002e5e
lea rdx, str.Bug:_Invalid_script_resource
xor ecx, ecx
call fcn.140001ed0
xor eax, eax
jmp 0x140002ec1
mov rax, 0xffffffffffffffff
inc rax
cmp byte [rdx + rax], 0
jne 0x140002e65
add rax, 0x11
add rax, rcx
cmp byte [rdx], 0
mov qword [0x14000c458], rax
je 0x140002ea7
mov qword [rsp + 0x20], rdx
lea r9, [0x14000c460]
mov edx, 0x608
lea r8, str._s_S
lea rcx, [0x14000c680]
call fcn.140001060
jmp 0x140002ebc
mov r8d, 0x608
lea rdx, [0x14000c680]
xor ecx, ecx
call qword [sym.imp.KERNEL32.dll_GetModuleFileNameW]
mov eax, 1
mov rcx, qword [rsp + 0x450]
xor rcx, rsp
call fcn.1400010d0
add rsp, 0x460
pop rbx
ret
Function at 0x140ffa0b0
Capabilities:
Decompress data using aplib

Disassembly:
call fcn.140ffa237
push r10
mov r10, rsp
push r10
mov rsi, qword [r10 + 0x10]
mov rdi, qword [r10 + 0x20]
cld
mov dl, 0x80
mov al, byte [rsi]
inc rsi
mov byte [rdi], al
inc rdi
mov ebx, 2
add dl, dl
jne 0x140ffa0e1
mov dl, byte [rsi]
inc rsi
adc dl, dl
jae 0x140ffa0c7
add dl, dl
jne 0x140ffa0ee
mov dl, byte [rsi]
inc rsi
adc dl, dl
jae 0x140ffa14e
xor eax, eax
add dl, dl
jne 0x140ffa0fd
mov dl, byte [rsi]
inc rsi
adc dl, dl
jae 0x140ffa205
add dl, dl
jne 0x140ffa10e
mov dl, byte [rsi]
inc rsi
adc dl, dl
adc eax, eax
add dl, dl
jne 0x140ffa11b
mov dl, byte [rsi]
inc rsi
adc dl, dl
adc eax, eax
add dl, dl
jne 0x140ffa128
mov dl, byte [rsi]
inc rsi
adc dl, dl
adc eax, eax
add dl, dl
jne 0x140ffa135
mov dl, byte [rsi]
inc rsi
adc dl, dl
adc eax, eax
je 0x140ffa142
push rdi
mov eax, eax
sub rdi, rax
mov al, byte [rdi]
pop rdi
mov byte [rdi], al
inc rdi
mov ebx, 2
jmp 0x140ffa0d6
mov eax, 1
add dl, dl
jne 0x140ffa15e
mov dl, byte [rsi]
inc rsi
adc dl, dl
adc eax, eax
add dl, dl
jne 0x140ffa16b
mov dl, byte [rsi]
inc rsi
adc dl, dl
jb 0x140ffa153
sub eax, ebx
mov ebx, 1
jne 0x140ffa1a4
mov ecx, 1
add dl, dl
jne 0x140ffa186
mov dl, byte [rsi]
inc rsi
adc dl, dl
adc ecx, ecx
add dl, dl
jne 0x140ffa193
mov dl, byte [rsi]
inc rsi
adc dl, dl
jb 0x140ffa17b
push rsi
mov rsi, rdi
sub rsi, rbp
rep movsb byte [rdi], byte [rsi]
pop rsi
jmp 0x140ffa0d6
dec eax
shl eax, 8
mov al, byte [rsi]
inc rsi
mov ebp, eax
mov ecx, 1
add dl, dl
jne 0x140ffa1c0
mov dl, byte [rsi]
inc rsi
adc dl, dl
adc ecx, ecx
add dl, dl
jne 0x140ffa1cd
mov dl, byte [rsi]
inc rsi
adc dl, dl
jb 0x140ffa1b5
cmp eax, 0x7d00
jae 0x140ffa1f3
cmp eax, 0x500
jb 0x140ffa1ee
inc ecx
push rsi
mov rsi, rdi
sub rsi, rax
rep movsb byte [rdi], byte [rsi]
pop rsi
jmp 0x140ffa0d6
cmp eax, 0x7f
ja 0x140ffa1f6
add ecx, 2
push rsi
mov rsi, rdi
sub rsi, rax
rep movsb byte [rdi], byte [rsi]
pop rsi
jmp 0x140ffa0d6
mov al, byte [rsi]
inc rsi
xor ecx, ecx
shr al, 1
je 0x140ffa22a
adc ecx, 2
mov ebp, eax
push rsi
mov rsi, rdi
sub rsi, rax
rep movsb byte [rdi], byte [rsi]
pop rsi
mov ebx, 1
jmp 0x140ffa0d6
pop r10
sub rdi, qword [r10 + 0x20]
mov eax, edi
pop r10
ret 0x20
Function at 0x14044debf
Capabilities:
Encode data using xor

Disassembly:
push 0xffffffff9d025289
lea rsp, [rsp + 0x18]
jne 0x1404871da
mov r8, rax
jmp 0x140483f93
mov r8d, 0x42b59180
pop r8
not eax
mov dword [r10], eax
call fcn.140471da8
mov rdi, qword [rdi]
push 0x16217bb5
mov qword [rsp], 0xffffffff8d9d5006
lea rsp, [rsp + 8]
jmp fcn.14044e176
call fcn.14045b593
lea rbx, [rdx + rdx - 0x5150acc9]
mov rdx, qword [rsp + r11*4 - 0xc6c0]
movsx r8d, r11b
movzx r9d, r8w
xchg qword [rsp + 8], rbx
lea rbx, [rbx + riz - 0x1418b]
jmp rbx
call fcn.140465b64
push 0xffffffff8f393195
add r10, 0xc
xor eax, eax
test rdx, rdx
lea rsp, [rsp + 8]
je 0x14046ec8b
mov esi, 0xeca3d48e
push r8
lea rsi, [0x14047acd0]
push 0x36a12ebd
mov r8d, dword [rsp + 2]
movzx r8d, byte [rbp + r8*8 - 0x1b508]
xor r8d, eax
and r8d, 0xff
mov r8d, dword [rsi + r8*4]
shr eax, 8
xor eax, r8d
ror qword [rsp], 0xc9
inc rbp
xor eax, 0x3f0b95bb
and dword [rsp + 4], 0xcb2029a0
shr qword [rsp], 0x8d
dec rdx
lea rsp, [rsp + 8]
jne 0x140487209
jmp 0x14046ec83
Function at 0x140053e40
Capabilities:
Check for outputdebugstring error
Check for peb beingdebugged flag
Patch process command line
Print debug messages

Disassembly:
sub rsp, 0x88
mov rax, qword [0x1400b4008]
xor rax, rsp
mov qword [rsp + 0x78], rax
mov rax, qword gs:[0x60]
cmp byte [rax + 2], 0
jne 0x140053f6d
test byte [rax + 0xbc], 0x70
jne 0x140053f6d
mov ecx, 0x457
call qword [sym.imp.KERNEL32.dll_SetLastError]
lea rcx, [0x1400b2624]
call qword [sym.imp.KERNEL32.dll_OutputDebugStringW]
call qword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 0x457
jne 0x140053f6d
mov qword [rsp + 0x90], rbx
mov qword [rsp + 0x80], rdi
call qword [sym.imp.KERNEL32.dll_GetCurrentProcessId]
lea rcx, str.ntdll.dll
mov ebx, eax
call qword [sym.imp.KERNEL32.dll_GetModuleHandleW]
test rax, rax
jne 0x140053ecd
xor edi, edi
jmp 0x140053ee0
lea rdx, str.NtQueryInformationProcess
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_GetProcAddress]
mov rdi, rax
mov r8d, ebx
xor edx, edx
mov ecx, 0x1fffff
call qword [sym.imp.KERNEL32.dll_OpenProcess]
mov r9d, 0x30
lea r8, [rsp + 0x30]
mov rbx, rax
xor edx, edx
lea rax, [rsp + 0x68]
mov rcx, rbx
mov qword [rsp + 0x20], rax
call rdi
mov rdx, qword [rsp + 0x38]
lea rax, [rsp + 0x70]
add rdx, 0x50
mov qword [rsp + 0x60], 0xffffffffffffffff
mov r9d, 8
mov qword [rsp + 0x20], rax
lea r8, [rsp + 0x60]
mov rcx, rbx
call qword [sym.imp.KERNEL32.dll_ReadProcessMemory]
test byte [rsp + 0x60], 4
mov rdi, qword [rsp + 0x80]
mov rbx, qword [rsp + 0x90]
jne 0x140053f6d
xor al, al
mov rcx, qword [rsp + 0x78]
xor rcx, rsp
call fcn.140054280
add rsp, 0x88
ret
mov al, 1
mov rcx, qword [rsp + 0x78]
xor rcx, rsp
call fcn.140054280
add rsp, 0x88
ret

Function at 0x14005648c
Capabilities:
Parse pe header

Disassembly:
mov qword [rsp + 8], rbx
mov dword [rsp + 0x18], r8d
mov dword [rsp + 0x10], edx
push rbp
mov rbp, rsp
sub rsp, 0x50
mov ebx, ecx
test r8d, r8d
jne 0x14005631f
xor ecx, ecx
call qword [sym.imp.KERNEL32.dll_GetModuleHandleW]
test rax, rax
je 0x14005631f
mov ecx, 0x5a4d
cmp word [rax], cx
jne 0x14005631f
movsxd rcx, dword [rax + 0x3c]
add rcx, rax
cmp dword [rcx], 0x4550
jne 0x14005631f
mov eax, 0x20b
cmp word [rcx + 0x18], ax
jne 0x14005631f
cmp dword [rcx + 0x84], 0xe
jbe 0x14005631f
cmp dword [rcx + 0xf8], 0
je 0x14005631f
mov ecx, ebx
call fcn.1400563c0
lea rax, [rbp + 0x18]
mov byte [rbp + 0x28], 0
mov qword [rbp - 0x20], rax
lea r9, [rbp - 0x2c]
lea rax, [rbp + 0x20]
mov qword [rbp - 0x18], rax
lea r8, [rbp - 0x20]
lea rax, [rbp + 0x28]
mov qword [rbp - 0x10], rax
lea rdx, [rbp - 0x28]
mov eax, 2
lea rcx, [rbp - 0x30]
mov dword [rbp - 0x2c], eax
mov dword [rbp - 0x28], eax
call fcn.1400561b0
cmp dword [rbp + 0x20], 0
je 0x14005636c
mov rbx, qword [rsp + 0x60]
add rsp, 0x50
pop rbp
ret
mov ecx, ebx
call fcn.140056374
int3
xor r8d, r8d
xor edx, edx
jmp 0x1400562b8