joyce8/EMBER2024-capa huggingface dataset:
Function at 0x401010
Capabilities:
Parse pe header

Disassembly:
sub rsp, 0x28
mov rax, qword [0x00420810]
xor edx, edx
mov dword [rax], 1
mov rax, qword [0x00420820]
mov dword [rax], 1
mov rax, qword [0x00420830]
mov dword [rax], 1
mov rax, qword [0x00420800]
mov dword [rax], 1
mov rax, qword [0x004206f0]
cmp word [rax], 0x5a4d
je 0x4010b0
mov rax, qword [0x004207f0]
mov dword [0x00423008], edx
mov eax, dword [rax]
test eax, eax
je 0x4010a0
mov ecx, 2
call sym.__set_app_type
call sym.__p__fmode
mov rdx, qword [0x004207b0]
mov edx, dword [rdx]
mov dword [rax], edx
call sym._wsetargv
mov rax, qword [0x004206a0]
cmp dword [rax], 1
je 0x4010f0
xor eax, eax
add rsp, 0x28
ret
mov ecx, 1
call sym.__set_app_type
jmp 0x401075
movsxd rcx, dword [rax + 0x3c]
add rax, rcx
cmp dword [rax], 0x4550
jne 0x401058
movzx ecx, word [rax + 0x18]
cmp cx, 0x10b
je 0x401103
cmp cx, 0x20b
jne 0x401058
cmp dword [rax + 0x84], 0xe
jbe 0x401058
mov ecx, dword [rax + 0xf8]
xor edx, edx
test ecx, ecx
setne dl
jmp 0x401058
lea rcx, [sym._matherr]
call sym.__mingw_setusermatherr
xor eax, eax
add rsp, 0x28
ret
cmp dword [rax + 0x74], 0xe
jbe 0x401058
mov r8d, dword [rax + 0xe8]
xor edx, edx
test r8d, r8d
setne dl
jmp 0x401058

Function at 0x401790
Capabilities:
Write file on windows

Disassembly:
push rbp
push rdi
push rsi
push rbx
sub rsp, 0x38
mov rbx, qword [rcx]
mov rsi, qword [rcx + 8]
test rbx, rbx
je 0x401830
mov ecx, 1
mov rdi, qword [sym.__acrt_iob_func]
call rdi
mov rcx, rax
call fcn.0041a6e0
mov ecx, 2
call rdi
mov rcx, rax
call fcn.0041a6e0
test esi, esi
jle 0x40180e
mov ecx, 1
movsxd rsi, esi
call rdi
mov ecx, 2
call rdi
mov rbp, rax
nop
nop word cs:[rax + rax]
mov r8, rsi
mov rcx, rbx
mov r9, rbp
mov edx, 1
call sym.fwrite
sub rsi, rax
add rbx, rax
test rsi, rsi
jg 0x4017f0
mov ecx, 2
call rdi
mov rcx, rax
add rsp, 0x38
pop rbx
pop rsi
pop rdi
pop rbp
jmp fcn.0041a6e0
lea rax, str.eprint_NIL_
mov qword [rsp + 0x20], rax
lea rcx, [rsp + 0x20]
movabs rax, 0x10000000b
mov qword [rsp + 0x28], rax
call sym.eprint.constprop.12
nop
add rsp, 0x38
pop rbx
pop rsi
pop rdi
pop rbp
ret

Function at 0x401860
Capabilities:
Write file on windows

Disassembly:
push rdi
push rsi
push rbx
sub rsp, 0x20
mov ecx, 1
mov ebx, 0x1e
lea rsi, str.double_string.free___detected_n
call qword [sym.__acrt_iob_func]
mov rdi, rax
nop dword [rax + rax]
nop word cs:[rax + rax]
mov r8, rbx
mov rcx, rsi
mov r9, rdi
mov edx, 1
call sym.fwrite
sub rbx, rax
add rsi, rax
test rbx, rbx
jg 0x401890
add rsp, 0x20
pop rbx
pop rsi
pop rdi
ret
Function at 0x4018c0
Capabilities:
Write file on windows

Disassembly:
push rbp
push rdi
push rsi
push rbx
sub rsp, 0x48
mov rbx, qword [rcx]
mov rsi, qword [rcx + 8]
test rbx, rbx
je 0x4019a0
mov ecx, 1
mov rdi, qword [sym.__acrt_iob_func]
call rdi
mov rcx, rax
call fcn.0041a6e0
mov ecx, 2
call rdi
mov rcx, rax
call fcn.0041a6e0
test esi, esi
mov byte [rsp + 0x3f], 0xa
jle 0x40193e
mov ecx, 1
movsxd rsi, esi
call rdi
mov ecx, 2
call rdi
mov rbp, rax
nop word [rax + rax]
mov r8, rsi
mov rcx, rbx
mov r9, rbp
mov edx, 1
call sym.fwrite
sub rsi, rax
add rbx, rax
test rsi, rsi
jg 0x401920
lea rsi, [rsp + 0x3f]
mov ecx, 1
mov ebx, 1
call rdi
mov ecx, 2
call rdi
mov rbp, rax
nop dword [rax]
mov r8, rbx
mov rcx, rsi
mov r9, rbp
mov edx, 1
call sym.fwrite
sub rbx, rax
add rsi, rax
test rbx, rbx
jg 0x401960
mov ecx, 2
call rdi
mov rcx, rax
call fcn.0041a6e0
nop
add rsp, 0x48
pop rbx
pop rsi
pop rdi
pop rbp
ret
lea rax, str.eprintln_NIL_
mov qword [rsp + 0x20], rax
lea rcx, [rsp + 0x20]
movabs rax, 0x10000000d
mov qword [rsp + 0x28], rax
call sym.eprintln
nop
add rsp, 0x48
pop rbx
pop rsi
pop rdi
pop rbp
ret
Function at 0x404830
Capabilities:
Write file on windows

Disassembly:
push r12
push rbp
push rdi
push rsi
push rbx
sub rsp, 0x90
mov rdx, qword [rcx]
mov eax, dword [rdx]
cmp eax, 0x4001000a
je 0x404981
cmp eax, 0xe06d7363
je 0x404981
cmp eax, 0x40010006
je 0x404981
xor eax, eax
mov ecx, 7
mov dword [rsp + 0x50], 0x7000fe86
lea rdi, [rsp + 0x54]
rep stosq qword [rdi], rax
lea rax, str.Unhandled_Exception_0x
mov qword [rsp + 0x40], rax
movabs rax, 0x100000016
mov qword [rsp + 0x48], rax
mov dword [rdi], 0
mov eax, dword [rdx]
lea rdi, [rsp + 0x20]
lea rdx, [rsp + 0x40]
mov rcx, rdi
mov dword [rsp + 0x74], 1
mov dword [rsp + 0x58], eax
lea rax, [0x0041e097]
mov qword [rsp + 0x68], rax
call sym.str_intp.constprop.2
mov rsi, qword [rsp + 0x20]
mov byte [rsp + 0x3f], 0xa
mov rbx, qword [rsp + 0x28]
test rsi, rsi
je 0x4049a0
test ebx, ebx
mov r12, qword [sym.__acrt_iob_func]
jle 0x40491e
mov ecx, 1
mov r12, qword [sym.__acrt_iob_func]
movsxd rbx, ebx
call r12
mov rbp, rax
nop
mov r8, rbx
mov rcx, rsi
mov r9, rbp
mov edx, 1
call sym.fwrite
sub rbx, rax
add rsi, rax
test rbx, rbx
jg 0x404900
lea rsi, [rsp + 0x3f]
mov ecx, 1
mov ebx, 1
call r12
mov rbp, rax
nop dword [rax]
nop word cs:[rax + rax]
mov r8, rbx
mov rcx, rsi
mov r9, rbp
mov edx, 1
call sym.fwrite
sub rbx, rax
add rsi, rax
test rbx, rbx
jg 0x404940
lea rax, str.print_backtrace_skipping_top_frames_is_not_implemented
mov rcx, rdi
mov qword [rsp + 0x20], rax
movabs rax, 0x100000036
mov qword [rsp + 0x28], rax
call sym.eprintln
xor eax, eax
add rsp, 0x90
pop rbx
pop rsi
pop rdi
pop rbp
pop r12
ret
mov ecx, 1
mov r12, qword [sym.__acrt_iob_func]
mov ebx, 0xc
call r12
lea rsi, str.println_NIL_
mov rbp, rax
mov r8, rbx
mov rcx, rsi
mov r9, rbp
mov edx, 1
call sym.fwrite
sub rbx, rax
add rsi, rax
test rbx, rbx
jg 0x4049be
lea rsi, [rsp + 0x3f]
mov ecx, 1
mov ebx, 1
call r12
mov rbp, rax
nop dword [rax + rax]
nop word cs:[rax + rax]
mov r8, rbx
mov rcx, rsi
mov r9, rbp
mov edx, 1
call sym.fwrite
sub rbx, rax
add rsi, rax
test rbx, rbx
jg 0x404a00
jmp 0x40495e
Function at 0x409650
Capabilities:
Allocate or change rwx memory
Execute shellcode via indirect call

Disassembly:
push r14
push rdi
push rsi
push rbx
sub rsp, 0x28
mov rsi, rcx
mov rcx, qword [0x00423a08]
shl rdx, 0xc
lea r10, [rsi + rdx]
mov rbx, rsi
lea rdx, [rcx + r10 - 1]
mov rax, rcx
neg rax
and rbx, rax
and rdx, rax
lea rax, [rbx + 0x1000]
cmp rdx, rax
je 0x409730
xor r8d, 1
mov rax, rbx
mov edi, 1
lea r11, [0x00423f00]
and r8d, 1
cmp rbx, rdx
jae 0x4096f8
nop dword [rax + rax]
cmp rsi, rax
seta r9b
cmp r10, rax
setbe cl
or r9b, cl
jne 0x4096c7
test r8b, r8b
je 0x4096ed
mov rcx, rax
mov r14, rdi
shr rcx, 0xc
and ecx, 0x3ffff
mov r9, rcx
shl r14, cl
shr r9, 6
add r9, 0x1c79
lock or qword [r11 + r9*8], r14
add rax, 0x1000
cmp rax, rdx
jb 0x4096b0
cmp dword [0x0041d6e0], 1
lea r9, [0x00423044]
mov rcx, rbx
sbb eax, eax
sub rdx, rbx
and eax, 0xffffffc4
lea r8d, [rax + 0x40]
call qword [sym.imp.KERNEL32.dll_VirtualProtect]
test eax, eax
je 0x409770
add rsp, 0x28
pop rbx
pop rsi
pop rdi
pop r14
ret
lea rcx, [0x00423f00]
mov rax, rbx
shr rax, 0x12
and eax, 0xfff
add rax, 0x1c78
mov rcx, qword [rcx + rax*8 + 8]
mov rax, rbx
shr rax, 0xc
bt rcx, rax
jae 0x40968f
add rsp, 0x28
pop rbx
pop rsi
pop rdi
pop r14
ret
call qword [sym.imp.KERNEL32.dll_GetLastError]
lea rcx, [0x0041e388]
mov edx, eax
call sym.GC_log_printf
lea rcx, [0x0041e3b1]
call sym.GC_default_on_abort.lto_priv.46
nop
add rsp, 0x28
pop rbx
pop rsi
pop rdi
pop r14
jmp qword [sym.imp.KERNEL32.dll_DebugBreak]
Function at 0x40dd00
Capabilities:
Query environment variable

Disassembly:
push rbp
push rdi
push rsi
push rbx
sub rsp, 0x168
mov esi, dword [0x004231a0]
mov dword [0x004231a4], 1
mov edi, dword [0x00423a88]
test esi, esi
jne 0x40dda0
test edi, edi
jne 0x40dd40
mov dword [0x004231a4], 0
add rsp, 0x168
pop rbx
pop rsi
pop rdi
pop rbp
ret
lea rcx, [0x00423a60]
call qword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
mov edx, dword [0x00423a88]
test edx, edx
je 0x40dd29
lea rcx, [0x00423a60]
call qword [sym.imp.KERNEL32.dll_EnterCriticalSection]
mov eax, dword [0x00423a88]
mov dword [0x004231a4], 0
test eax, eax
je 0x40dd33
lea rcx, [0x00423a60]
add rsp, 0x168
pop rbx
pop rsi
pop rdi
pop rbp
jmp qword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
lea rbx, [rsp + 0x20]
mov ebp, esi
lea rdx, [0x00423060]
shl rbp, 3
mov rcx, rbx
mov r8, rbp
call sym.memcpy
xor edx, edx
mov r8, rbp
mov dword [0x004231a0], 0
lea rcx, [0x00423060]
call sym.memset
test edi, edi
jne 0x40de50
lea rcx, str.Found__u_leaked_objects:_n
mov edx, esi
call sym.GC_err_printf
lea eax, [rsi - 1]
mov rcx, rbx
lea rbx, [rbx + 8]
lea rdi, [rbx + rax*8]
jmp 0x40de04
add rbx, 8
mov rsi, qword [rcx]
mov rcx, rsi
call sym.GC_default_print_heap_obj_proc.lto_priv.49
mov rcx, rsi
call sym.GC_free
cmp rbx, rdi
mov rcx, rbx
jne 0x40de00
lea rcx, str.GC_ABORT_ON_LEAK
call sub.msvcrt.dll_getenv
test rax, rax
je 0x40dd4d
lea rcx, str.Leaked_or_smashed_objects_encountered
call sym.GC_default_on_abort.lto_priv.46
call qword [sym.imp.KERNEL32.dll_DebugBreak]
jmp 0x40dd4d
lea rcx, [0x00423a60]
call qword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
jmp 0x40dddc

Function at 0x40ebd0
Capabilities:
Resume thread

Disassembly:
push r13
push r12
push rbp
push rdi
push rsi
push rbx
sub rsp, 0x28
mov rdi, qword [sym.imp.KERNEL32.dll_ResumeThread]
lea rsi, [0x004231c0]
mov r12, qword [sym.imp.KERNEL32.dll_DebugBreak]
lea rbp, [rsi + 0x800]
lea r13, [0x0044e320]
nop
mov rbx, qword [rsi]
test rbx, rbx
jne 0x40ec18
jmp 0x40ec6c
mov rbx, qword [rbx]
test rbx, rbx
je 0x40ec6c
cmp byte [rbx + 0x3b], 0
je 0x40ec10
mov rcx, qword [rbx + 0x10]
call rdi
cmp eax, 0xffffffff
jne 0x40ec38
lea rcx, str.ResumeThread_failed
call sym.GC_default_on_abort.lto_priv.46
call r12
mov edx, dword [0x00423eec]
test edx, edx
je 0x40ec60
mov eax, dword [0x00423ee8]
test eax, eax
jne 0x40ec60
cmp rbx, r13
jne 0x40ec90
nop dword [rax + rax]
nop word cs:[rax + rax]
mov byte [rbx + 0x3b], 0
mov rbx, qword [rbx]
test rbx, rbx
jne 0x40ec18
add rsi, 8
cmp rsi, rbp
jne 0x40ec00
add rsp, 0x28
pop rbx
pop rsi
pop rdi
pop rbp
pop r12
pop r13
ret
cmp qword [0x00423ee0], 0
jne 0x40ec60
mov rcx, rbx
xor r8d, r8d
mov edx, 1
and rcx, 0xfffffffffffff000
call sym.GC_remove_protection.part.26
jmp 0x40ec60
Function at 0x40eff0
Capabilities:
Allocate or change rwx memory

Disassembly:
push rsi
push rbx
sub rsp, 0x28
mov rax, qword [0x004205e0]
mov r9d, 4
mov r8d, dword [0x004525e8]
mov eax, dword [rax]
test eax, eax
mov eax, 0x40
cmovne r9d, eax
mov rax, qword [0x00420680]
xor edx, edx
cmp qword [rax], 0
sete dl
mov rax, rdx
add rdx, rcx
not rax
cmp rax, rcx
mov rax, 0xffffffffffffffff
cmovbe rdx, rax
or r8d, 0x3000
xor ecx, ecx
call qword [sym.imp.KERNEL32.dll_VirtualAlloc]
test eax, 0xfff
mov rbx, rax
je 0x40f069
lea rcx, str.Bad_VirtualAlloc_result
call sym.GC_default_on_abort.lto_priv.46
call qword [sym.imp.KERNEL32.dll_DebugBreak]
mov rsi, qword [0x00420360]
cmp qword [rsi + 0xf0], 0x3ff
jbe 0x40f08f
lea rcx, str.Too_many_heap_sections
call sym.GC_default_on_abort.lto_priv.46
call qword [sym.imp.KERNEL32.dll_DebugBreak]
test rbx, rbx
je 0x40f0ae
mov rax, qword [rsi + 0xf0]
lea rdx, [rax + 1]
mov qword [rsi + rax*8 + 0x163d0], rbx
mov qword [rsi + 0xf0], rdx
mov rax, rbx
add rsp, 0x28
pop rbx
pop rsi
ret

Function at 0x40f0c0
Capabilities:
Query environment variable

Disassembly:
push rbx
sub rsp, 0x170
lea rcx, str.GC_LOG_FILE
mov r8d, 0x105
lea rbx, [rsp + 0x50]
mov rdx, rbx
call qword [sym.imp.KERNEL32.dll_GetEnvironmentVariableA]
sub eax, 1
cmp eax, 0x103
ja 0x40f180
mov rax, qword [0x00420600]
mov edx, pe_nt_image_headers64
mov rcx, rbx
mov r8d, 1
cmp dword [rax], 2
mov eax, 0x80000080
mov dword [rsp + 0x20], 4
mov qword [rsp + 0x30], 0
cmove eax, edx
xor r9d, r9d
mov edx, 0x40000000
mov dword [rsp + 0x28], eax
call qword [sym.imp.KERNEL32.dll_CreateFileA]
cmp rax, 0xffffffffffffffff
mov rbx, rax
jne 0x40f150
mov rax, rbx
add rsp, 0x170
pop rbx
ret
mov dword [rsp + 0x4c], 0
mov r9d, 2
xor edx, edx
mov rcx, rbx
lea r8, [rsp + 0x4c]
call qword [sym.imp.KERNEL32.dll_SetFilePointer]
mov rax, rbx
add rsp, 0x170
pop rbx
ret
xor ecx, ecx
mov r8d, 0x105
mov rdx, rbx
call qword [sym.imp.KERNEL32.dll_GetModuleFileNameA]
cmp eax, 4
jle 0x40f1a4
lea edx, [rax - 4]
movsxd rcx, edx
cmp byte [rsp + rcx + 0x50], 0x2e
cmove eax, edx
cdqe
mov edx, 0x80000080
movabs rcx, 0x676f6c2e63672e
mov r8d, 1
mov qword [rbx + rax], rcx
mov rax, qword [0x00420600]
mov rcx, rbx
cmp dword [rax], 2
mov eax, pe_nt_image_headers64
mov dword [rsp + 0x20], 2
mov qword [rsp + 0x30], 0
cmovne eax, edx
xor r9d, r9d
mov edx, 0x40000000
mov dword [rsp + 0x28], eax
call qword [sym.imp.KERNEL32.dll_CreateFileA]
mov rbx, rax
mov rax, rbx
add rsp, 0x170
pop rbx
ret
Function at 0x40f210
Capabilities:
Write file on windows

Disassembly:
push rdi
push rsi
push rbx
sub rsp, 0x50
xor eax, eax
test rdx, rdx
mov rdi, rcx
mov rbx, rdx
je 0x40f274
mov rsi, qword [0x00420550]
mov ecx, dword [rsi]
test ecx, ecx
jne 0x40f280
mov rax, qword [0x004525d8]
test rax, rax
je 0x40f299
cmp rax, 0xffffffffffffffff
je 0x40f2c7
mov r8d, ebx
mov rdx, rdi
mov rcx, rax
mov qword [rsp + 0x20], 0
lea r9, [rsp + 0x4c]
call qword [sym.imp.KERNEL32.dll_WriteFile]
mov ebx, eax
mov eax, dword [rsi]
test eax, eax
jne 0x40f2b0
test ebx, ebx
je 0x40f2c0
mov eax, dword [rsp + 0x4c]
add rsp, 0x50
pop rbx
pop rsi
pop rdi
ret
mov rcx, qword [0x00420660]
call qword [sym.imp.KERNEL32.dll_EnterCriticalSection]
mov rax, qword [0x004525d8]
test rax, rax
jne 0x40f23d
call sym.GC_CreateLogFile
mov qword [0x004525d8], rax
jmp 0x40f23d
mov rcx, qword [0x00420660]
call qword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
jmp 0x40f26c
mov eax, 0xffffffff
jmp 0x40f274
mov edx, dword [rsi]
test edx, edx
je 0x40f2c0
mov qword [rsp + 0x38], rax
mov rcx, qword [0x00420660]
call qword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
mov rax, qword [rsp + 0x38]
jmp 0x40f274

Function at 0x40f2f0
Capabilities:
Query environment variable

Disassembly:
push rbx
sub rsp, 0x20
mov dword [0x004525e0], 1
test rcx, rcx
mov rbx, rcx
je 0x40f336
lea r8, str.Fatal_error_in_GC
mov rdx, rcx
mov r9d, 0x10
xor ecx, ecx
call qword [sym.imp.USER32.dll_MessageBoxA]
mov rcx, rbx
call sym.strlen
mov rcx, rbx
mov rdx, rax
call sym.GC_write
test eax, eax
jns 0x40f350
lea rcx, str.GC_LOOP_ON_ABORT
call sub.msvcrt.dll_getenv
test rax, rax
je 0x40f363
jmp 0x40f347
lea rcx, [0x0041f4cd]
mov edx, 1
call sym.GC_write
jmp 0x40f336
add rsp, 0x20
pop rbx
ret
Function at 0x40f370
Capabilities:
Encrypt data using rc4 prga

Disassembly:
push r15
push r14
push r13
push r12
push rbp
push rdi
push rsi
push rbx
sub rsp, 0x38
mov rsi, qword [0x00420360]
mov rax, qword [rsi + 0x138]
test rax, rax
je 0x40f4d6
mov rdi, qword [0x00420550]
mov ebx, dword [rdi]
test ebx, ebx
jne 0x40f4f0
cmp qword [rsi + 0x138], 0
je 0x40f4d6
call qword [sym.imp.KERNEL32.dll_GetCurrentThreadId]
mov rcx, qword [0x00420640]
mov edx, eax
shr edx, 8
xor edx, eax
movzx edx, dl
mov rbx, qword [rcx + rdx*8]
test rbx, rbx
jne 0x40f3ec
jmp sym.GC_notify_or_invoke_finalizers.cold.0
mov rbx, qword [rbx]
test rbx, rbx
je sym.GC_notify_or_invoke_finalizers.cold.0
cmp eax, dword [rbx + 8]
jne 0x40f3e0
movzx ecx, byte [rbx + 0x3a]
mov edx, dword [rdi]
test cl, cl
jne 0x40f540
add ecx, 1
test edx, edx
mov byte [rbx + 0x3a], cl
je 0x40f416
mov rcx, qword [0x00420350]
call qword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
mov r13, qword [0x00420350]
xor r12d, r12d
xor ebp, ebp
mov r14, qword [sym.imp.KERNEL32.dll_EnterCriticalSection]
mov qword [rsp + 0x28], r13
jmp 0x40f465
mov rdx, qword [r15 + 8]
mov qword [rsi + 0x138], rdx
mov r8d, dword [rdi]
test r8d, r8d
jne 0x40f5c8
mov qword [r15 + 8], 0
mov rdx, qword [r15 + 0x18]
add ebp, 1
mov rcx, qword [r15]
call qword [r15 + 0x10]
mov qword [r15 + 0x18], 0
mov rax, qword [rsi + 0x138]
test rax, rax
je 0x40f4b0
mov r9d, dword [rdi]
test r9d, r9d
jne 0x40f570
test ebp, ebp
jne 0x40f485
mov r12, qword [rsi + 0x58]
mov r15, qword [rsi + 0x138]
test r15, r15
jne 0x40f430
mov eax, dword [rdi]
test eax, eax
je 0x40f4b0
mov rcx, qword [0x00420350]
call qword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
nop
nop word cs:[rax + rax]
test ebp, ebp
je 0x40f4d2
mov rax, qword [rsi + 0x58]
cmp rax, r12
je 0x40f4d2
mov ecx, dword [rdi]
test ecx, ecx
jne 0x40f590
add rax, qword [rsi + 0x60]
sub rax, r12
mov qword [rsi + 0x60], rax
mov byte [rbx + 0x3a], 0
add rsp, 0x38
pop rbx
pop rsi
pop rdi
pop rbp
pop r12
pop r13
pop r14
pop r15
ret
mov rcx, qword [0x00420350]
call qword [sym.imp.KERNEL32.dll_EnterCriticalSection]
cmp qword [rsi + 0x138], 0
jne 0x40f3b6
mov r11d, dword [rdi]
test r11d, r11d
je 0x40f4d6
mov rcx, qword [0x00420350]
add rsp, 0x38
pop rbx
pop rsi
pop rdi
pop rbp
pop r12
pop r13
pop r14
pop r15
jmp qword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
movzx eax, word [rbx + 0x38]
add eax, 1
mov word [rbx + 0x38], ax
movzx eax, ax
shr eax, cl
test eax, eax
je 0x40f57b
xor r10d, r10d
mov word [rbx + 0x38], r10w
jmp 0x40f3ff
mov rcx, r13
call r14
jmp 0x40f47d
test edx, edx
je 0x40f4d6
jmp 0x40f513
mov rcx, qword [0x00420350]
call qword [sym.imp.KERNEL32.dll_EnterCriticalSection]
mov rax, qword [rsi + 0x60]
mov edx, dword [rdi]
sub rax, r12
add rax, qword [rsi + 0x58]
test edx, edx
mov qword [rsi + 0x60], rax
je 0x40f4d2
mov rcx, qword [0x00420350]
call qword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
jmp 0x40f4d2
mov rcx, qword [rsp + 0x28]
call qword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
jmp 0x40f447
Function at 0x40f7b0
Capabilities:
Query environment variable

Disassembly:
push rdi
push rsi
push rbx
sub rsp, 0xc0
mov eax, dword [0x004525e4]
test eax, eax
je 0x40f7d0
add rsp, 0xc0
pop rbx
pop rsi
pop rdi
ret
lea rcx, str.GC_USE_GETWRITEWATCH
call sub.msvcrt.dll_getenv
test rax, rax
je 0x40f7ea
cmp byte [rax], 0x30
je 0x40f8b0
lea rcx, str.kernel32.dll
call qword [sym.imp.KERNEL32.dll_GetModuleHandleA]
test rax, rax
je 0x40f897
lea rdx, str.GetWriteWatch
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_GetProcAddress]
mov rbx, qword [0x00420680]
test rax, rax
mov qword [rbx], rax
je 0x40f897
mov rdi, qword [0x004205d0]
xor ecx, ecx
mov r9d, 4
mov r8d, 0x202000
mov rdx, qword [rdi]
call qword [sym.imp.KERNEL32.dll_VirtualAlloc]
test rax, rax
mov rsi, rax
je 0x40f8d0
lea rax, [rsp + 0x34]
mov rdx, rsi
mov ecx, 1
mov qword [rsp + 0x38], 0x10
mov qword [rsp + 0x28], rax
lea rax, [rsp + 0x38]
mov qword [rsp + 0x20], rax
lea r9, [rsp + 0x40]
mov r8, qword [rdi]
call qword [rbx]
test eax, eax
jne 0x40f8c0
mov dword [0x004525e8], 0x200000
mov r8d, 0x8000
xor edx, edx
mov rcx, rsi
call qword [sym.imp.KERNEL32.dll_VirtualFree]
mov dword [0x004525e4], 1
add rsp, 0xc0
pop rbx
pop rsi
pop rdi
ret
cmp byte [rax + 1], 0
jne 0x40f7ea
jmp 0x40f897
mov qword [rbx], 0
jmp 0x40f886
mov qword [rbx], 0
jmp 0x40f897

Function at 0x40f9b0
Capabilities:
Allocate or change rwx memory

Disassembly:
push rdi
push rsi
push rbx
sub rsp, 0x20
xor eax, eax
mov rdx, qword [rcx]
cmp dword [rdx], 0xc0000005
je 0x40f9d0
add rsp, 0x20
pop rbx
pop rsi
pop rdi
ret
cmp qword [rdx + 0x20], 1
jne 0x40f9c4
mov r9, qword [rdx + 0x28]
mov rbx, qword [0x00420360]
mov rdx, r9
shr rdx, 0x16
mov rax, rdx
and eax, 0x7ff
mov rax, qword [rbx + rax*8 + 0x263d0]
cmp qword [rax + 0x2010], rdx
je 0x40fa60
mov r8, qword [rbx + 0xb8]
jmp 0x40fa20
mov rax, qword [rax + 0x2018]
cmp rdx, qword [rax + 0x2010]
je 0x40fa60
cmp rax, r8
jne 0x40fa10
mov rax, r9
shr rax, 0xc
and eax, 0x3ff
cmp qword [r8 + rax*8], 0
jne 0x40fa77
mov rax, qword [0x004205b0]
mov rax, qword [rax]
cmp rax, 0xffffffffffffffff
je 0x40fa70
add rsp, 0x20
pop rbx
pop rsi
pop rdi
jmp rax
mov r8, rax
jmp 0x40fa25
xor eax, eax
jmp 0x40f9c4
mov rax, qword [0x004205e0]
mov r8d, 4
mov rdi, qword [0x004205d0]
mov eax, dword [rax]
mov rdx, qword [rdi]
test eax, eax
mov eax, 0x40
cmovne r8d, eax
mov rsi, rdx
neg rsi
and rsi, r9
mov r9, qword [0x00420850]
mov rcx, rsi
call qword [sym.imp.KERNEL32.dll_VirtualProtect]
test eax, eax
je 0x40fb18
mov rax, qword [rdi]
xor edx, edx
mov r8d, 1
shr rax, 0xc
test rax, rax
je 0x40fb0e
nop dword [rax]
mov rcx, rsi
mov r10, r8
shr rcx, 0xc
and ecx, 0x3ffff
mov rax, rcx
shl r10, cl
shr rax, 6
lea rax, [rax*8 + 0xe3c8]
lock or qword [rax + rbx], r10
mov rax, qword [rdi]
add rdx, 1
shr rax, 0xc
add rsi, 0x1000
cmp rax, rdx
ja 0x40fad0
mov eax, 0xffffffff
jmp 0x40f9c4
call qword [sym.imp.KERNEL32.dll_GetLastError]
lea rcx, str.un_VirtualProtect_failed:_errcode_0x_X_n
mov edx, eax
call sym.GC_log_printf
lea rcx, str.un_VirtualProtect_failed
call sym.GC_default_on_abort.lto_priv.46
call qword [sym.imp.KERNEL32.dll_DebugBreak]
jmp 0x40fab8
Function at 0x4104d0
Capabilities:
Check for time delay via gettickcount
Get system information on windows
Query environment variable

Disassembly:
sub rsp, 0x28
mov rax, qword [0x004204b0]
mov eax, dword [rax]
test eax, eax
je 0x4104f0
add rsp, 0x28
ret
lea rcx, str.kernel32.dll
call qword [sym.imp.KERNEL32.dll_GetModuleHandleA]
test rax, rax
je 0x410530
lea rdx, str.InitializeCriticalSectionAndSpinCount
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_GetProcAddress]
test rax, rax
je 0x410530
mov edx, 0xfa0
mov rcx, qword [0x00420350]
call rax
jmp 0x41053e
mov rcx, qword [0x00420350]
call qword [sym.imp.KERNEL32.dll_InitializeCriticalSection]
nop
add rsp, 0x28
jmp sym.GC_init.part.47
Function at 0x410880
Capabilities:
Check for time delay via gettickcount

Disassembly:
push r15
push r14
push r13
push r12
push rbp
push rdi
push rsi
push rbx
sub rsp, 0x58
mov rax, qword [0x00420600]
cmp dword [rax], 2
mov rbp, rcx
mov r12d, edx
mov dword [rsp + 0x44], 0
je 0x410aad
mov r13, qword [0x00420590]
mov rsi, qword [0x00420360]
mov r14, qword [0x00420420]
lea rax, [r13 + 0x60]
mov qword [rsp + 0x30], r13
mov qword [rsp + 0x48], rax
mov rax, qword [rsp + 0x30]
mov rax, qword [rax + 8]
lea rbx, [rax + 0x408]
test rax, rax
lea rdi, [rax + 8]
mov qword [rsp + 0x38], rbx
je 0x4109b2
mov rbx, qword [rdi]
nop word cs:[rax + rax]
test rbx, rbx
je 0x4109a3
test rbp, rbp
je 0x410918
call rbp
test eax, eax
jne 0x410a98
mov rdx, rbx
shr rdx, 0x16
mov rcx, rdx
and ecx, 0x7ff
add rcx, 0x4c7a
mov rax, qword [rsi + rcx*8]
cmp qword [rax + 0x2010], rdx
je 0x410a90
mov r8, qword [rsi + 0xb8]
jmp 0x410964
mov rax, qword [rax + 0x2018]
cmp rdx, qword [rax + 0x2010]
je 0x410a90
cmp rax, r8
jne 0x410950
mov r9, rbx
shr r9, 0xc
and r9d, 0x3ff
test r12d, r12d
mov rax, qword [r8 + r9*8]
mov r8, qword [rax]
mov qword [rdi], r8
je 0x410a00
mov r10, qword [r14]
movzx r15d, word [rax + 0x1a]
lea r11, [r10 - 1]
cmp r15, r11
je 0x410a0a
mov rbx, r8
test rbx, rbx
jne 0x410909
add rdi, 8
cmp rdi, qword [rsp + 0x38]
jne 0x4108f3
add qword [rsp + 0x30], 0x20
mov rax, qword [rsp + 0x30]
cmp qword [rsp + 0x48], rax
jne 0x4108d1
mov rax, qword [0x00420600]
mov ebx, 1
cmp dword [rax], 2
jne 0x410a9a
call qword [sym.imp.KERNEL32.dll_GetTickCount]
sub eax, dword [rsp + 0x44]
xor r8d, r8d
lea rcx, str.Disposing_of_reclaim_lists_took__lu_ms__lu_ns_n
mov edx, eax
call sym.GC_log_printf
jmp 0x410a9a
mov r11, qword [0x00420420]
mov r10, qword [r11]
mov r8, qword [rax + 0x20]
mov rax, qword [rsi + rcx*8]
cmp qword [rax + 0x2010], rdx
je 0x410a45
mov rcx, qword [rsi + 0xb8]
jmp 0x410a40
mov rax, qword [rax + 0x2018]
cmp rdx, qword [rax + 0x2010]
je 0x410a45
cmp rcx, rax
jne 0x410a30
mov rdx, qword [rax + r9*8]
mov r9, r8
shr r9, 4
movzx eax, byte [rdx + 0x18]
shl rax, 5
add rax, r13
mov rcx, qword [rax]
mov word [rdx + 0x1a], r10w
lea r15, [rcx + r9*8]
mov rcx, qword [r15]
mov qword [rsp + 0x20], rcx
mov r9d, dword [rax + 0x1c]
mov rcx, rbx
call sym.GC_reclaim_generic.constprop.35
mov qword [r15], rax
mov rbx, qword [rdi]
jmp 0x410900
mov r8, rax
jmp 0x410969
xor ebx, ebx
mov eax, ebx
add rsp, 0x58
pop rbx
pop rsi
pop rdi
pop rbp
pop r12
pop r13
pop r14
pop r15
ret
call qword [sym.imp.KERNEL32.dll_GetTickCount]
mov dword [rsp + 0x44], eax
jmp 0x4108ae