joyce8/EMBER2024-capa huggingface dataset:
Function at 0x1407a7370
Capabilities:
Decompress data using aplib

Disassembly:
call fcn.1407a74f7
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 0x1407a73a1
mov dl, byte [rsi]
inc rsi
adc dl, dl
jae 0x1407a7387
add dl, dl
jne 0x1407a73ae
mov dl, byte [rsi]
inc rsi
adc dl, dl
jae 0x1407a740e
xor eax, eax
add dl, dl
jne 0x1407a73bd
mov dl, byte [rsi]
inc rsi
adc dl, dl
jae 0x1407a74c5
add dl, dl
jne 0x1407a73ce
mov dl, byte [rsi]
inc rsi
adc dl, dl
adc eax, eax
add dl, dl
jne 0x1407a73db
mov dl, byte [rsi]
inc rsi
adc dl, dl
adc eax, eax
add dl, dl
jne 0x1407a73e8
mov dl, byte [rsi]
inc rsi
adc dl, dl
adc eax, eax
add dl, dl
jne 0x1407a73f5
mov dl, byte [rsi]
inc rsi
adc dl, dl
adc eax, eax
je 0x1407a7402
push rdi
mov eax, eax
sub rdi, rax
mov al, byte [rdi]
pop rdi
mov byte [rdi], al
inc rdi
mov ebx, 2
jmp 0x1407a7396
mov eax, 1
add dl, dl
jne 0x1407a741e
mov dl, byte [rsi]
inc rsi
adc dl, dl
adc eax, eax
add dl, dl
jne 0x1407a742b
mov dl, byte [rsi]
inc rsi
adc dl, dl
jb 0x1407a7413
sub eax, ebx
mov ebx, 1
jne 0x1407a7464
mov ecx, 1
add dl, dl
jne 0x1407a7446
mov dl, byte [rsi]
inc rsi
adc dl, dl
adc ecx, ecx
add dl, dl
jne 0x1407a7453
mov dl, byte [rsi]
inc rsi
adc dl, dl
jb 0x1407a743b
push rsi
mov rsi, rdi
sub rsi, rbp
rep movsb byte [rdi], byte [rsi]
pop rsi
jmp 0x1407a7396
dec eax
shl eax, 8
mov al, byte [rsi]
inc rsi
mov ebp, eax
mov ecx, 1
add dl, dl
jne 0x1407a7480
mov dl, byte [rsi]
inc rsi
adc dl, dl
adc ecx, ecx
add dl, dl
jne 0x1407a748d
mov dl, byte [rsi]
inc rsi
adc dl, dl
jb 0x1407a7475
cmp eax, 0x7d00
jae 0x1407a74b3
cmp eax, 0x500
jb 0x1407a74ae
inc ecx
push rsi
mov rsi, rdi
sub rsi, rax
rep movsb byte [rdi], byte [rsi]
pop rsi
jmp 0x1407a7396
cmp eax, 0x7f
ja 0x1407a74b6
add ecx, 2
push rsi
mov rsi, rdi
sub rsi, rax
rep movsb byte [rdi], byte [rsi]
pop rsi
jmp 0x1407a7396
mov al, byte [rsi]
inc rsi
xor ecx, ecx
shr al, 1
je 0x1407a74ea
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 0x1407a7396
pop r10
sub rdi, qword [r10 + 0x20]
mov eax, edi
pop r10
ret 0x20
Function at 0x140002b40
Capabilities:
Write file on windows

Disassembly:
push rsi
push rbx
sub rsp, 0x38
mov rbx, 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.140004610
mov r8d, 0x1b
mov edx, 1
lea rcx, str.Mingw_w64_runtime_failure:_n
mov r9, rax
call sub.msvcrt.dll_fwrite
mov rsi, qword [rsp + 0x28]
mov ecx, 2
call fcn.140004610
mov rdx, rbx
mov rcx, rax
mov r8, rsi
call sub.msvcrt.dll_vfprintf
call sub.msvcrt.dll_abort
nop
nop dword [rax]

Function at 0x140002bb0
Capabilities:
Allocate or change rwx memory

Disassembly:
push rdi
push rsi
push rbx
sub rsp, 0x50
movsxd rsi, dword [0x1400090a4]
mov rbx, rcx
test esi, esi
jle 0x140002ce0
mov rax, qword [0x1400090a8]
xor r9d, r9d
add rax, 0x18
nop word [rax + rax]
mov r8, qword [rax]
cmp rbx, r8
jb 0x140002bfb
mov rdx, qword [rax + 8]
mov edx, dword [rdx + 8]
add r8, rdx
cmp rbx, r8
jb 0x140002c85
add r9d, 1
add rax, 0x28
cmp r9d, esi
jne 0x140002be0
mov rcx, rbx
call fcn.140003600
mov rdi, rax
test rax, rax
je 0x140002d02
mov rax, qword [0x1400090a8]
lea rbx, [rsi + rsi*4]
shl rbx, 3
add rax, rbx
mov qword [rax + 0x20], rdi
mov dword [rax], 0
call fcn.140003740
mov edx, dword [rdi + 0xc]
mov r8d, 0x30
lea rcx, [rax + rdx]
mov rax, qword [0x1400090a8]
lea rdx, [rsp + 0x20]
mov qword [rax + rbx + 0x18], rcx
call qword [sym.imp.KERNEL32.dll_VirtualQuery]
test rax, rax
je 0x140002ce7
mov eax, dword [rsp + 0x44]
lea edx, [rax - 0x40]
and edx, 0xffffffbf
je 0x140002c7e
lea edx, [rax - 4]
and edx, 0xfffffffb
jne 0x140002c90
add dword [0x1400090a4], 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 [0x1400090a8]
mov qword [rbx + 8], rcx
mov r9, rbx
mov qword [rbx + 0x10], rdx
call qword [sym.imp.KERNEL32.dll_VirtualProtect]
test eax, eax
jne 0x140002c7e
call qword [sym.imp.KERNEL32.dll_GetLastError]
lea rcx, str.__VirtualProtect_failed_with_code_0x_x
mov edx, eax
call fcn.140002b40
nop dword [rax]
xor esi, esi
jmp 0x140002c08
mov rax, qword [0x1400090a8]
mov edx, dword [rdi + 8]
lea rcx, str.__VirtualQuery_failed_for__d_bytes_at_address__p
mov r8, qword [rax + rbx + 0x18]
call fcn.140002b40
mov rdx, rbx
lea rcx, str.Address__p_has_no_image_section
call fcn.140002b40
nop
nop word cs:[rax + rax]
nop dword [rax]

Function at 0x140003270
Capabilities:
Get thread local storage value

Disassembly:
push r12
push rbp
push rdi
push rsi
push rbx
sub rsp, 0x20
lea r12, [0x140009100]
mov rcx, r12
call qword [sym.imp.KERNEL32.dll_EnterCriticalSection]
mov rbx, qword [0x1400090e0]
test rbx, rbx
je 0x1400032cc
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 0x1400032c3
test rsi, rsi
je 0x1400032c3
mov rax, qword [rbx + 8]
mov rcx, rsi
call rax
mov rbx, qword [rbx + 0x10]
test rbx, rbx
jne 0x1400032a8
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 0x140003600
Capabilities:
Enumerate pe sections
Parse pe header

Disassembly:
mov rdx, qword [0x140006a70]
xor eax, eax
cmp word [rdx], 0x5a4d
jne 0x140003620
movsxd r8, dword [rdx + 0x3c]
add r8, rdx
cmp dword [r8], 0x4550
je 0x140003628
ret
cmp word [r8 + 0x18], 0x20b
jne 0x140003620
movzx eax, word [r8 + 0x14]
sub rcx, rdx
lea rax, [r8 + rax + 0x18]
movzx r8d, word [r8 + 6]
test r8w, r8w
je 0x14000367d
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 0x140003674
add edx, dword [rax + 8]
cmp rcx, rdx
jb 0x140003620
add rax, 0x28
cmp rax, r9
jne 0x140003660
xor eax, eax
ret

Function at 0x140003680
Capabilities:
Parse pe header

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

Function at 0x140003740
Capabilities:
Parse pe header

Disassembly:
mov rax, qword [0x140006a70]
xor edx, edx
cmp word [rax], 0x5a4d
jne 0x14000375f
movsxd rcx, dword [rax + 0x3c]
add rcx, rax
cmp dword [rcx], 0x4550
je 0x140003768
mov rax, rdx
ret
cmp word [rcx + 0x18], 0x20b
cmove rdx, rax
mov rax, rdx
ret
Function at 0x180001450
Capabilities:
Encode data using xor

Disassembly:
push rbp
mov rbp, rsp
sub rsp, 0x50
mov rax, qword [0x18001b018]
xor rax, rsp
mov qword [rbp - 8], rax
call fcn.180003630
call qword [sym.imp.KERNEL32.dll_GetCurrentThread]
mov rcx, rax
call fcn.180003b50
mov dword [rbp - 0x30], 0x2b
mov cl, 0x65
mov eax, dword [rbp - 0x30]
xor al, 0x52
mov byte [rbp - 0x2c], al
mov eax, dword [rbp - 0x30]
inc al
xor al, 0x70
mov byte [rbp - 0x2b], al
mov eax, dword [rbp - 0x30]
add al, 2
xor al, 0x63
mov byte [rbp - 0x2a], al
mov eax, dword [rbp - 0x30]
add al, 3
xor al, 0x53
mov byte [rbp - 0x29], al
mov eax, dword [rbp - 0x30]
add al, 4
xor al, cl
mov byte [rbp - 0x28], al
mov eax, dword [rbp - 0x30]
add al, 5
xor al, 0x72
mov byte [rbp - 0x27], al
mov eax, dword [rbp - 0x30]
add al, 6
xor al, 0x76
mov byte [rbp - 0x26], al
mov eax, dword [rbp - 0x30]
add al, 7
xor al, cl
mov byte [rbp - 0x25], al
mov eax, dword [rbp - 0x30]
add al, 8
xor al, 0x72
mov byte [rbp - 0x24], al
mov eax, dword [rbp - 0x30]
add al, 9
xor al, 0x54
mov byte [rbp - 0x23], al
mov eax, dword [rbp - 0x30]
add al, 0xa
xor al, cl
mov byte [rbp - 0x22], al
mov eax, dword [rbp - 0x30]
add al, 0xb
xor al, 0x73
mov byte [rbp - 0x21], al
mov eax, dword [rbp - 0x30]
add al, 0xc
xor al, 0x74
mov byte [rbp - 0x20], al
mov eax, dword [rbp - 0x30]
add al, 0xd
xor al, 0x43
mov byte [rbp - 0x1f], al
mov eax, dword [rbp - 0x30]
add al, 0xe
xor al, 0x61
mov byte [rbp - 0x1e], al
mov eax, dword [rbp - 0x30]
add al, 0xf
xor al, 0x6e
mov byte [rbp - 0x1d], al
mov eax, dword [rbp - 0x30]
add al, 0x10
xor al, 0x63
mov byte [rbp - 0x1c], al
mov eax, dword [rbp - 0x30]
add al, 0x11
xor al, cl
mov byte [rbp - 0x1b], al
mov eax, dword [rbp - 0x30]
add al, 0x12
xor al, 0x6c
mov byte [rbp - 0x1a], al
xor eax, eax
xor r8d, r8d
mov byte [rbp - 0x19], al
mov al, byte [rbp - 0x2c]
mov edx, r8d
mov al, byte [rbp + rdx - 0x2c]
mov ecx, dword [rbp - 0x30]
add cl, dl
xor cl, al
mov byte [rbp + rdx - 0x2c], cl
inc rdx
cmp rdx, 0x13
jb 0x18000154d
mov byte [rbp - 0x19], r8b
xor eax, eax
mov dword [rbp - 0x18], 0x6c
mov rdx, r8
mov byte [rbp - 0x14], 0x3e
mov byte [rbp - 0x13], 0x1c
mov byte [rbp - 0x12], 0xf
mov byte [rbp - 0x11], 0x1e
mov byte [rbp - 0x10], 0x18
mov byte [rbp - 0xf], 0x58
mov byte [rbp - 0xe], 0x42
mov byte [rbp - 0xd], 8
mov byte [rbp - 0xc], r8b
mov byte [rbp - 0xb], r8b
mov byte [rbp - 0xa], al
mov al, byte [rbp - 0x14]
mov al, byte [rbp + rdx - 0x14]
mov ecx, dword [rbp - 0x18]
xor cl, al
mov byte [rbp + rdx - 0x14], cl
inc rdx
cmp rdx, 0xa
jb 0x1800015a3
mov byte [rbp - 0xa], r8b
lea r9, section..text
lea r8, [0x18001ba90]
lea rdx, [rbp - 0x2c]
lea rcx, [rbp - 0x14]
call fcn.180001400
call fcn.1800036a0
xor eax, eax
mov rcx, qword [rbp - 8]
xor rcx, rsp
call fcn.180005130
add rsp, 0x50
pop rbp
ret
Function at 0x180001780
Capabilities:
Allocate or change rwx memory

Disassembly:
mov qword [rsp + 0x10], rdx
mov qword [rsp + 8], rcx
sub rsp, 0x68
mov rax, qword [rsp + 0x78]
sub rax, 0x10000
mov rcx, rax
call fcn.1800019d0
mov qword [rsp + 0x20], rax
mov rax, qword [rsp + 0x70]
cmp qword [rsp + 0x20], rax
jbe 0x18000189a
mov rax, qword [section..data]
cmp qword [rsp + 0x20], rax
jb 0x1800017e4
mov rax, qword [0x18001b008]
cmp qword [rsp + 0x20], rax
ja 0x1800017e4
mov rax, qword [rsp + 0x20]
sub rax, 0x8000000
mov qword [rsp + 0x20], rax
jmp 0x1800017a6
mov r8d, 0x30
xor edx, edx
lea rcx, [rsp + 0x30]
call fcn.1800067f0
mov r8d, 0x30
lea rdx, [rsp + 0x30]
mov rcx, qword [rsp + 0x20]
call sub.KERNEL32.dll_VirtualQuery
test rax, rax
jne 0x180001815
jmp 0x18000189a
cmp dword [rsp + 0x50], 0x10000
jne 0x18000187d
cmp qword [rsp + 0x48], 0x10000
jb 0x18000187d
mov r9d, 0x40
mov r8d, 0x3000
mov edx, 0x10000
mov rcx, qword [rsp + 0x20]
call sub.KERNEL32.dll_VirtualAlloc
mov qword [rsp + 0x28], rax
cmp qword [rsp + 0x28], 0
je 0x18000185b
mov rax, qword [rsp + 0x28]
jmp 0x18000189c
call sub.KERNEL32.dll_GetLastError
cmp eax, 0x677
jne 0x18000186b
xor eax, eax
jmp 0x18000189c
mov rax, qword [rsp + 0x20]
sub rax, 0x10000
mov qword [rsp + 0x20], rax
jmp 0x180001895
mov rax, qword [rsp + 0x38]
sub rax, 0x10000
mov rcx, rax
call fcn.1800019d0
mov qword [rsp + 0x20], rax
jmp 0x1800017a6
xor eax, eax
add rsp, 0x68
ret

Function at 0x1800018b0
Capabilities:
Allocate or change rwx memory

Disassembly:
mov qword [rsp + 0x10], rdx
mov qword [rsp + 8], rcx
sub rsp, 0x68
mov rcx, qword [rsp + 0x70]
call fcn.180001a10
mov qword [rsp + 0x20], rax
mov rax, qword [rsp + 0x78]
cmp qword [rsp + 0x20], rax
jae 0x1800019c6
mov rax, qword [section..data]
cmp qword [rsp + 0x20], rax
jb 0x18000190b
mov rax, qword [0x18001b008]
cmp qword [rsp + 0x20], rax
ja 0x18000190b
mov rax, qword [rsp + 0x20]
add rax, 0x8000000
mov qword [rsp + 0x20], rax
jmp 0x1800018cd
mov r8d, 0x30
xor edx, edx
lea rcx, [rsp + 0x30]
call fcn.1800067f0
mov r8d, 0x30
lea rdx, [rsp + 0x30]
mov rcx, qword [rsp + 0x20]
call sub.KERNEL32.dll_VirtualQuery
test rax, rax
jne 0x18000193c
jmp 0x1800019c6
cmp dword [rsp + 0x50], 0x10000
jne 0x1800019a4
cmp qword [rsp + 0x48], 0x10000
jb 0x1800019a4
mov r9d, 0x40
mov r8d, 0x3000
mov edx, 0x10000
mov rcx, qword [rsp + 0x20]
call sub.KERNEL32.dll_VirtualAlloc
mov qword [rsp + 0x28], rax
cmp qword [rsp + 0x28], 0
je 0x180001982
mov rax, qword [rsp + 0x28]
jmp 0x1800019c8
call sub.KERNEL32.dll_GetLastError
cmp eax, 0x677
jne 0x180001992
xor eax, eax
jmp 0x1800019c8
mov rax, qword [rsp + 0x20]
add rax, 0x10000
mov qword [rsp + 0x20], rax
jmp 0x1800019c1
mov rax, qword [rsp + 0x48]
mov rcx, qword [rsp + 0x30]
add rcx, rax
mov rax, rcx
mov rcx, rax
call fcn.180001a10
mov qword [rsp + 0x20], rax
jmp 0x1800018cd
xor eax, eax
add rsp, 0x68
ret
Function at 0x180001a60
Capabilities:
Hook routines via microsoft detours

Disassembly:
mov qword [rsp + 8], rcx
sub rsp, 0x58
lea r8, [rsp + 0x30]
lea rdx, [rsp + 0x38]
mov rcx, qword [rsp + 0x60]
call fcn.180001ff0
mov qword [rsp + 0x28], 0
cmp qword [0x18001bab0], 0
jne 0x180001aa8
cmp qword [0x18001baa8], 0
je 0x180001aa8
mov rax, qword [0x18001baa8]
mov qword [0x18001bab0], rax
cmp qword [0x18001bab0], 0
je 0x180001b4e
mov rax, qword [0x18001bab0]
cmp qword [rax + 0x10], 0
je 0x180001b4e
mov rax, qword [0x18001bab0]
mov rcx, qword [rsp + 0x38]
cmp qword [rax + 0x10], rcx
jb 0x180001b4e
mov rax, qword [0x18001bab0]
mov rcx, qword [rsp + 0x30]
cmp qword [rax + 0x10], rcx
ja 0x180001b4e
mov rax, qword [0x18001bab0]
mov rax, qword [rax + 0x10]
mov qword [rsp + 0x28], rax
mov rax, qword [rsp + 0x38]
cmp qword [rsp + 0x28], rax
jb 0x180001b14
mov rax, qword [rsp + 0x30]
cmp qword [rsp + 0x28], rax
jbe 0x180001b1b
xor eax, eax
jmp 0x180001cc9
mov rax, qword [0x18001bab0]
mov rcx, qword [rsp + 0x28]
mov rcx, qword [rcx + 0x48]
mov qword [rax + 0x10], rcx
mov r8d, 0x60
mov edx, 0xcc
mov rcx, qword [rsp + 0x28]
call fcn.1800067f0
mov rax, qword [rsp + 0x28]
jmp 0x180001cc9
mov rax, qword [0x18001baa8]
mov qword [0x18001bab0], rax
jmp 0x180001b70
mov rax, qword [0x18001bab0]
mov rax, qword [rax + 8]
mov qword [0x18001bab0], rax
cmp qword [0x18001bab0], 0
je 0x180001bbd
cmp qword [0x18001bab0], 0
je 0x180001bbb
mov rax, qword [0x18001bab0]
cmp qword [rax + 0x10], 0
je 0x180001bbb
mov rax, qword [0x18001bab0]
mov rcx, qword [rsp + 0x38]
cmp qword [rax + 0x10], rcx
jb 0x180001bbb
mov rax, qword [0x18001bab0]
mov rcx, qword [rsp + 0x30]
cmp qword [rax + 0x10], rcx
ja 0x180001bbb
jmp 0x180001aec
jmp 0x180001b5e
mov rcx, qword [rsp + 0x60]
call fcn.180003c40
and eax, 0xffff
mov eax, eax
mov rcx, qword [rsp + 0x60]
sub rcx, rax
mov rax, rcx
mov qword [rsp + 0x60], rax
mov r8, qword [rsp + 0x30]
mov rdx, qword [rsp + 0x38]
mov rcx, qword [rsp + 0x60]
call fcn.180001cd0
mov qword [rsp + 0x48], rax
cmp qword [rsp + 0x48], 0
je 0x180001cc7
mov rax, qword [rsp + 0x48]
mov qword [0x18001bab0], rax
mov rax, qword [0x18001bab0]
mov dword [rax], 0x52727464
mov rax, qword [0x18001bab0]
mov qword [rax + 0x10], 0
mov rax, qword [0x18001bab0]
mov rcx, qword [0x18001baa8]
mov qword [rax + 8], rcx
mov rax, qword [0x18001bab0]
mov qword [0x18001baa8], rax
mov qword [rsp + 0x40], 0
mov rax, qword [0x18001bab0]
add rax, 0x60
mov qword [rsp + 0x28], rax
mov dword [rsp + 0x20], 0x2a8
jmp 0x180001c78
mov eax, dword [rsp + 0x20]
dec eax
mov dword [rsp + 0x20], eax
cmp dword [rsp + 0x20], 1
jle 0x180001cb2
movsxd rax, dword [rsp + 0x20]
imul rax, rax, 0x60
mov rcx, qword [rsp + 0x28]
mov rdx, qword [rsp + 0x40]
mov qword [rcx + rax + 0x48], rdx
movsxd rax, dword [rsp + 0x20]
imul rax, rax, 0x60
mov rcx, qword [rsp + 0x28]
add rcx, rax
mov rax, rcx
mov qword [rsp + 0x40], rax
jmp 0x180001c6e
mov rax, qword [0x18001bab0]
mov rcx, qword [rsp + 0x40]
mov qword [rax + 0x10], rcx
jmp 0x180001aec
xor eax, eax
add rsp, 0x58
ret
Function at 0x1800029e0
Capabilities:
Parse pe header

Disassembly:
mov qword [rsp + 0x10], rdx
mov qword [rsp + 8], rcx
sub rsp, 0x78
mov r8d, 0x30
lea rdx, [rsp + 0x40]
mov rcx, qword [rsp + 0x80]
call sub.KERNEL32.dll_VirtualQuery
nop
mov rax, qword [rsp + 0x48]
mov qword [rsp + 0x28], rax
mov rax, qword [rsp + 0x28]
movzx eax, word [rax]
cmp eax, 0x5a4d
je 0x180002a27
xor al, al
jmp 0x180002ac9
mov rax, qword [rsp + 0x28]
movsxd rax, dword [rax + 0x3c]
mov rcx, qword [rsp + 0x28]
add rcx, rax
mov rax, rcx
mov qword [rsp + 0x30], rax
mov rax, qword [rsp + 0x30]
cmp dword [rax], 0x4550
je 0x180002a51
xor al, al
jmp 0x180002ac9
mov eax, 8
imul rax, rax, 0xc
mov rcx, qword [rsp + 0x30]
mov eax, dword [rcx + rax + 0x88]
mov rcx, qword [rsp + 0x28]
add rcx, rax
mov rax, rcx
cmp qword [rsp + 0x88], rax
jb 0x180002ac1
mov eax, 8
imul rax, rax, 0xc
mov rcx, qword [rsp + 0x30]
mov eax, dword [rcx + rax + 0x88]
mov rcx, qword [rsp + 0x28]
add rcx, rax
mov rax, rcx
mov ecx, 8
imul rcx, rcx, 0xc
mov rdx, qword [rsp + 0x30]
mov ecx, dword [rdx + rcx + 0x8c]
add rax, rcx
cmp qword [rsp + 0x88], rax
jae 0x180002ac1
mov al, 1
jmp 0x180002ac9
jmp 0x180002ac7
xor al, al
add rsp, 0x78
ret

Function at 0x180002dd0
Capabilities:
Allocate or change rwx memory

Disassembly:
sub rsp, 0x38
mov rax, qword [0x18001baa8]
mov qword [rsp + 0x28], rax
jmp 0x180002df0
mov rax, qword [rsp + 0x28]
mov rax, qword [rax + 8]
mov qword [rsp + 0x28], rax
cmp qword [rsp + 0x28], 0
je 0x180002e1f
lea r9, [rsp + 0x20]
mov r8d, 0x40
mov edx, 0x10000
mov rcx, qword [rsp + 0x28]
call sub.KERNEL32.dll_VirtualProtect
test eax, eax
jne 0x180002e1d
call sub.KERNEL32.dll_GetLastError
jmp 0x180002e21
jmp 0x180002de2
xor eax, eax
add rsp, 0x38
ret
Function at 0x1800034e0
Capabilities:
Resume thread

Disassembly:
sub rsp, 0x68
call sub.KERNEL32.dll_GetCurrentThreadId
cmp dword [0x18001bac0], eax
je 0x1800034fb
mov eax, 0x10dd
jmp 0x180003620
mov rax, qword [0x18001bad8]
mov qword [rsp + 0x28], rax
cmp qword [rsp + 0x28], 0
je 0x1800035a5
mov rax, qword [rsp + 0x28]
mov rax, qword [rax + 0x20]
movzx eax, byte [rax + 0x3e]
lea r9, [rsp + 0x20]
mov rcx, qword [rsp + 0x28]
mov r8d, dword [rcx + 0x28]
mov edx, eax
mov rax, qword [rsp + 0x28]
mov rcx, qword [rax + 0x18]
call sub.KERNEL32.dll_VirtualProtect
mov rax, qword [rsp + 0x28]
cmp dword [rax + 8], 0
jne 0x180003570
mov rax, qword [rsp + 0x28]
cmp qword [rax + 0x20], 0
je 0x180003570
mov rax, qword [rsp + 0x28]
mov rcx, qword [rax + 0x20]
call fcn.180002130
mov rax, qword [rsp + 0x28]
mov qword [rax + 0x20], 0
mov rax, qword [rsp + 0x28]
mov rax, qword [rax]
mov qword [rsp + 0x40], rax
mov rax, qword [rsp + 0x28]
mov qword [rsp + 0x38], rax
mov edx, 0x30
mov rcx, qword [rsp + 0x38]
call fcn.1800054ec
mov rax, qword [rsp + 0x40]
mov qword [rsp + 0x28], rax
jmp 0x180003507
mov qword [0x18001bad8], 0
call fcn.180002b90
mov rax, qword [0x18001bad0]
mov qword [rsp + 0x30], rax
cmp qword [rsp + 0x30], 0
je 0x180003609
mov rax, qword [rsp + 0x30]
mov rcx, qword [rax + 8]
call sub.KERNEL32.dll_ResumeThread
mov rax, qword [rsp + 0x30]
mov rax, qword [rax]
mov qword [rsp + 0x50], rax
mov rax, qword [rsp + 0x30]
mov qword [rsp + 0x48], rax
mov edx, 0x10
mov rcx, qword [rsp + 0x48]
call fcn.1800054ec
mov rax, qword [rsp + 0x50]
mov qword [rsp + 0x30], rax
jmp 0x1800035c1
mov qword [0x18001bad0], 0
mov dword [0x18001bac0], 0
xor eax, eax
add rsp, 0x68
ret
Function at 0x180003b50
Capabilities:
Suspend thread

Disassembly:
mov qword [rsp + 8], rcx
sub rsp, 0x48
cmp dword [0x18001bac4], 0
je 0x180003b6d
mov eax, dword [0x18001bac4]
jmp 0x180003c33
call sub.KERNEL32.dll_GetCurrentThread
cmp qword [rsp + 0x50], rax
jne 0x180003b80
xor eax, eax
jmp 0x180003c33
mov ecx, 0x10
call fcn.1800054b0
mov qword [rsp + 0x30], rax
mov rax, qword [rsp + 0x30]
mov qword [rsp + 0x28], rax
cmp qword [rsp + 0x28], 0
jne 0x180003bee
mov dword [rsp + 0x20], 8
cmp qword [rsp + 0x28], 0
je 0x180003bd3
mov rax, qword [rsp + 0x28]
mov qword [rsp + 0x38], rax
mov edx, 0x10
mov rcx, qword [rsp + 0x38]
call fcn.1800054ec
mov qword [rsp + 0x28], 0
mov eax, dword [rsp + 0x20]
mov dword [0x18001bac4], eax
mov qword [0x18001bac8], 0
mov eax, dword [rsp + 0x20]
jmp 0x180003c33
mov rcx, qword [rsp + 0x50]
call sub.KERNEL32.dll_SuspendThread
cmp eax, 0xffffffff
jne 0x180003c08
call sub.KERNEL32.dll_GetLastError
mov dword [rsp + 0x20], eax
jmp 0x180003ba9
mov rax, qword [rsp + 0x28]
mov rcx, qword [rsp + 0x50]
mov qword [rax + 8], rcx
mov rax, qword [rsp + 0x28]
mov rcx, qword [0x18001bad0]
mov qword [rax], rcx
mov rax, qword [rsp + 0x28]
mov qword [0x18001bad0], rax
xor eax, eax
add rsp, 0x48
ret
Function at 0x140002d60
Capabilities:
Write file on windows

Disassembly:
push rsi
push rbx
sub rsp, 0x38
mov rbx, 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.140004e10
mov r8d, 0x1b
mov edx, 1
lea rcx, str.Mingw_w64_runtime_failure:_n
mov r9, rax
call sub.msvcrt.dll_fwrite
mov rsi, qword [rsp + 0x28]
mov ecx, 2
call fcn.140004e10
mov rdx, rbx
mov rcx, rax
mov r8, rsi
call sub.msvcrt.dll_vfprintf
call sub.msvcrt.dll_abort
nop
nop dword [rax]

Function at 0x140002dd0
Capabilities:
Allocate or change rwx memory

Disassembly:
push rdi
push rsi
push rbx
sub rsp, 0x50
movsxd rsi, dword [0x14000a0a4]
mov rbx, rcx
test esi, esi
jle 0x140002f00
mov rax, qword [0x14000a0a8]
xor r9d, r9d
add rax, 0x18
nop word [rax + rax]
mov r8, qword [rax]
cmp rbx, r8
jb 0x140002e1b
mov rdx, qword [rax + 8]
mov edx, dword [rdx + 8]
add r8, rdx
cmp rbx, r8
jb 0x140002ea5
add r9d, 1
add rax, 0x28
cmp r9d, esi
jne 0x140002e00
mov rcx, rbx
call fcn.140003820
mov rdi, rax
test rax, rax
je 0x140002f22
mov rax, qword [0x14000a0a8]
lea rbx, [rsi + rsi*4]
shl rbx, 3
add rax, rbx
mov qword [rax + 0x20], rdi
mov dword [rax], 0
call fcn.140003960
mov edx, dword [rdi + 0xc]
mov r8d, 0x30
lea rcx, [rax + rdx]
mov rax, qword [0x14000a0a8]
lea rdx, [rsp + 0x20]
mov qword [rax + rbx + 0x18], rcx
call qword [sym.imp.KERNEL32.dll_VirtualQuery]
test rax, rax
je 0x140002f07
mov eax, dword [rsp + 0x44]
lea edx, [rax - 0x40]
and edx, 0xffffffbf
je 0x140002e9e
lea edx, [rax - 4]
and edx, 0xfffffffb
jne 0x140002eb0
add dword [0x14000a0a4], 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 [0x14000a0a8]
mov qword [rbx + 8], rcx
mov r9, rbx
mov qword [rbx + 0x10], rdx
call qword [sym.imp.KERNEL32.dll_VirtualProtect]
test eax, eax
jne 0x140002e9e
call qword [sym.imp.KERNEL32.dll_GetLastError]
lea rcx, str.__VirtualProtect_failed_with_code_0x_x
mov edx, eax
call fcn.140002d60
nop dword [rax]
xor esi, esi
jmp 0x140002e28
mov rax, qword [0x14000a0a8]
mov edx, dword [rdi + 8]
lea rcx, str.__VirtualQuery_failed_for__d_bytes_at_address__p
mov r8, qword [rax + rbx + 0x18]
call fcn.140002d60
mov rdx, rbx
lea rcx, str.Address__p_has_no_image_section
call fcn.140002d60
nop
nop word cs:[rax + rax]
nop dword [rax]

Function at 0x140003490
Capabilities:
Get thread local storage value

Disassembly:
push r12
push rbp
push rdi
push rsi
push rbx
sub rsp, 0x20
lea r12, [0x14000a100]
mov rcx, r12
call qword [sym.imp.KERNEL32.dll_EnterCriticalSection]
mov rbx, qword [0x14000a0e0]
test rbx, rbx
je 0x1400034ec
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 0x1400034e3
test rsi, rsi
je 0x1400034e3
mov rax, qword [rbx + 8]
mov rcx, rsi
call rax
mov rbx, qword [rbx + 0x10]
test rbx, rbx
jne 0x1400034c8
mov rcx, r12
add rsp, 0x20
pop rbx
pop rsi
pop rdi
pop rbp
pop r12
jmp qword [sym.imp.KERNEL32.dll_LeaveCriticalSection]