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

Disassembly:
cmp word [rcx], 0x5a4d
je 0x40c590
xor eax, eax
ret
jmp sym._ValidateImageBase.part.0

Function at 0x40c5a0
Capabilities:
Enumerate pe sections

Disassembly:
movsxd rax, dword [rcx + 0x3c]
add rcx, rax
movzx eax, word [rcx + 0x14]
lea rax, [rcx + rax + 0x18]
movzx ecx, word [rcx + 6]
test ecx, ecx
je 0x40c5e1
sub ecx, 1
lea rcx, [rcx + rcx*4]
lea r9, [rax + rcx*8 + 0x28]
mov r8d, dword [rax + 0xc]
cmp r8, rdx
mov rcx, r8
ja 0x40c5d8
add ecx, dword [rax + 8]
cmp rcx, rdx
ja 0x40c5e3
add rax, 0x28
cmp rax, r9
jne 0x40c5c4
xor eax, eax
ret

Function at 0x40c680
Capabilities:
Enumerate pe sections

Disassembly:
sub rsp, 0x28
mov r8, qword [0x004e3590]
cmp word [r8], 0x5a4d
mov rdx, rcx
jne 0x40c6ed
mov rcx, r8
call sym._ValidateImageBase.part.0
test eax, eax
je 0x40c6ed
movsxd rax, dword [r8 + 0x3c]
mov rcx, rdx
sub rcx, r8
add r8, rax
movzx edx, word [r8 + 6]
movzx eax, word [r8 + 0x14]
test edx, edx
lea rax, [r8 + rax + 0x18]
je 0x40c6ed
sub edx, 1
lea rdx, [rdx + rdx*4]
lea r9, [rax + rdx*8 + 0x28]
nop
mov r8d, dword [rax + 0xc]
cmp rcx, r8
mov rdx, r8
jb 0x40c6e4
add edx, dword [rax + 8]
cmp rcx, rdx
jb 0x40c6ef
add rax, 0x28
cmp rax, r9
jne 0x40c6d0
xor eax, eax
add rsp, 0x28
ret

Function at 0x40c7f0
Capabilities:
Enumerate pe sections

Disassembly:
sub rsp, 0x28
mov r8, qword [0x004e3590]
xor eax, eax
cmp word [r8], 0x5a4d
mov rdx, rcx
je 0x40c810
add rsp, 0x28
ret
mov rcx, r8
call sym._ValidateImageBase.part.0
test eax, eax
je 0x40c808
movsxd rax, dword [r8 + 0x3c]
mov rcx, rdx
sub rcx, r8
add r8, rax
movzx edx, word [r8 + 6]
movzx eax, word [r8 + 0x14]
test edx, edx
lea rax, [r8 + rax + 0x18]
je 0x40c86d
sub edx, 1
lea rdx, [rdx + rdx*4]
lea r9, [rax + rdx*8 + 0x28]
nop dword [rax + rax]
mov r8d, dword [rax + 0xc]
cmp rcx, r8
mov rdx, r8
jb 0x40c864
add edx, dword [rax + 8]
cmp rcx, rdx
jb 0x40c874
add rax, 0x28
cmp rax, r9
jne 0x40c850
xor eax, eax
add rsp, 0x28
ret
mov eax, dword [rax + 0x24]
not eax
shr eax, 0x1f
add rsp, 0x28
ret

Function at 0x40c890
Capabilities:
Enumerate pe sections

Disassembly:
sub rsp, 0x28
mov r11, qword [0x004e3590]
cmp word [r11], 0x5a4d
mov r9d, ecx
jne 0x40c8fe
mov rcx, r11
call sym._ValidateImageBase.part.0
test eax, eax
je 0x40c8fe
movsxd rax, dword [r11 + 0x3c]
add rax, r11
mov edx, dword [rax + 0x90]
test edx, edx
je 0x40c8fe
movzx ecx, word [rax + 0x14]
lea rcx, [rax + rcx + 0x18]
movzx eax, word [rax + 6]
test eax, eax
je 0x40c8fe
sub eax, 1
lea rax, [rax + rax*4]
lea rax, [rcx + rax*8 + 0x28]
mov r10d, dword [rcx + 0xc]
cmp rdx, r10
mov r8, r10
jb 0x40c8f5
add r8d, dword [rcx + 8]
cmp rdx, r8
jb 0x40c905
add rcx, 0x28
cmp rcx, rax
jne 0x40c8e0
xor eax, eax
add rsp, 0x28
ret
add rdx, r11
jne 0x40c918
jmp 0x40c8fe
sub r9d, 1
add rdx, 0x14
mov ecx, dword [rdx + 4]
test ecx, ecx
jne 0x40c926
mov eax, dword [rdx + 0xc]
test eax, eax
je 0x40c8fe
test r9d, r9d
jg 0x40c910
mov eax, dword [rdx + 0xc]
add rax, r11
add rsp, 0x28
ret
Function at 0x40ca00
Capabilities:
Allocate thread local storage

Disassembly:
push rsi
push rbx
sub rsp, 0x28
mov rsi, rcx
mov rbx, rdx
call qword [sym.imp.KERNEL32.dll_TlsAlloc]
cmp eax, 0xffffffff
je 0x40ca30
mov rdx, rbx
mov ecx, eax
mov dword [rsi], eax
add rsp, 0x28
pop rbx
pop rsi
jmp sym.__mingwthr_key_dtor
add rsp, 0x28
pop rbx
pop rsi
jmp qword [sym.imp.KERNEL32.dll_GetLastError]

Function at 0x40ca60
Capabilities:
Get thread local storage value

Disassembly:
push rsi
push rbx
sub rsp, 0x28
mov ebx, ecx
call qword [sym.imp.KERNEL32.dll_GetLastError]
mov ecx, ebx
mov esi, eax
call qword [sym.imp.KERNEL32.dll_TlsGetValue]
mov ecx, esi
mov rbx, rax
call qword [sym.imp.KERNEL32.dll_SetLastError]
mov rax, rbx
add rsp, 0x28
pop rbx
pop rsi
ret

Function at 0x40ca90
Capabilities:
Set thread local storage value

Disassembly:
sub rsp, 0x28
call qword [sym.imp.KERNEL32.dll_TlsSetValue]
test eax, eax
je 0x40caa5
xor eax, eax
add rsp, 0x28
ret
add rsp, 0x28
jmp qword [sym.imp.KERNEL32.dll_GetLastError]

Function at 0x40cde0
Capabilities:
Allocate thread local storage

Disassembly:
sub rsp, 0x28
call qword [sym.imp.KERNEL32.dll_TlsAlloc]
cmp eax, 0xffffffff
je 0x40ce11
xor edx, edx
mov ecx, eax
mov dword [0x00505950], eax
call sym.__mingwthr_key_dtor
test eax, eax
sete al
movzx eax, al
mov dword [0x004db068], eax
add rsp, 0x28
ret
call qword [sym.imp.KERNEL32.dll_GetLastError]
jmp 0x40cdfe

Function at 0x40cf20
Capabilities:
Set thread local storage value

Disassembly:
push r15
push r14
push r13
push r12
push rbp
push rdi
push rsi
push rbx
sub rsp, 0x38
mov edi, 1
mov rax, qword [rdx]
mov rbp, qword [rcx + 0x10]
mov r12, qword [rcx + 0x18]
test rax, rax
mov rsi, rcx
mov rbx, rdx
mov r15, r8
je 0x40d020
mov r13, qword [sym.imp.KERNEL32.dll_TlsSetValue]
jmp 0x40cf7c
mov qword [0x00505958], r14
mov rax, qword [rbx]
add edi, 1
mov rax, qword [rax]
test rax, rax
mov qword [rbx], rax
je 0x40d020
mov r9, rsi
mov r8, qword [rsi]
mov edx, 0xa
mov ecx, 1
mov r14, qword [rax + 0x30]
mov qword [rsp + 0x28], r12
mov qword [rsp + 0x20], rbx
call rbp
test eax, eax
jne 0x40d040
test r14, r14
je 0x40cfcf
mov qword [rsp + 0x20], rbx
mov r9, rsi
mov r8, qword [rsi]
mov edx, 0xa
mov ecx, 1
call r14
cmp eax, 7
je 0x40d065
cmp eax, 8
jne 0x40d040
mov rax, qword [rbx]
mov r14, qword [rax]
mov eax, dword [0x004db068]
test eax, eax
js 0x40d010
test eax, eax
je 0x40cf60
mov rdx, r14
mov ecx, dword [0x00505950]
call r13
test eax, eax
jne 0x40cf67
call qword [sym.imp.KERNEL32.dll_GetLastError]
jmp 0x40cf67
call dbg.fc_key_init_once
mov eax, dword [0x004db068]
jmp 0x40cfdf
mov qword [rsp + 0x28], r12
mov r9, rsi
mov r8, qword [rsi]
mov edx, 0x1a
mov qword [rsp + 0x20], rbx
mov ecx, 1
call rbp
test eax, eax
je 0x40d060
mov eax, 2
add rsp, 0x38
pop rbx
pop rsi
pop rdi
pop rbp
pop r12
pop r13
pop r14
pop r15
ret
mov eax, 5
mov dword [r15], edi
jmp 0x40d045
Function at 0x40d070
Capabilities:
Get thread local storage value
Set thread local storage value

Disassembly:
push rbp
push rdi
push rsi
push rbx
sub rsp, 0x28
mov eax, dword [0x004db068]
test eax, eax
mov rbx, rcx
js 0x40d0f0
test eax, eax
jne 0x40d0a3
mov rax, qword [0x00505958]
mov qword [0x00505958], rbx
mov qword [rbx], rax
add rsp, 0x28
pop rbx
pop rsi
pop rdi
pop rbp
ret
mov edi, dword [0x00505950]
mov rsi, qword [sym.imp.KERNEL32.dll_GetLastError]
call rsi
mov ebp, eax
mov ecx, edi
call qword [sym.imp.KERNEL32.dll_TlsGetValue]
mov ecx, ebp
mov rdi, rax
call qword [sym.imp.KERNEL32.dll_SetLastError]
mov qword [rbx], rdi
mov rdx, rbx
mov ecx, dword [0x00505950]
call qword [sym.imp.KERNEL32.dll_TlsSetValue]
test eax, eax
jne 0x40d09a
mov rax, rsi
add rsp, 0x28
pop rbx
pop rsi
pop rdi
pop rbp
jmp rax
call dbg.fc_key_init_once
mov eax, dword [0x004db068]
jmp 0x40d085

Function at 0x40d100
Capabilities:
Set thread local storage value

Disassembly:
push rbx
sub rsp, 0x20
mov eax, dword [0x004db068]
mov rbx, qword [rcx]
test eax, eax
js 0x40d142
test eax, eax
jne 0x40d123
mov qword [0x00505958], rbx
add rsp, 0x20
pop rbx
ret
mov rdx, rbx
mov ecx, dword [0x00505950]
call qword [sym.imp.KERNEL32.dll_TlsSetValue]
test eax, eax
jne 0x40d11d
add rsp, 0x20
pop rbx
jmp qword [sym.imp.KERNEL32.dll_GetLastError]
call dbg.fc_key_init_once
mov eax, dword [0x004db068]
jmp 0x40d112

Function at 0x40d210
Capabilities:
Get thread local storage value

Disassembly:
push rdi
push rsi
push rbx
sub rsp, 0x40
mov eax, dword [0x004db068]
test eax, eax
mov rbx, rcx
js 0x40d290
test eax, eax
mov rsi, qword [0x00505958]
jne 0x40d2a6
test rsi, rsi
mov qword [rsp + 0x38], rsi
je 0x40d281
lea rdi, [rsp + 0x38]
mov rax, rsi
mov rax, qword [rax + 0x30]
test rax, rax
je 0x40d26f
mov qword [rsp + 0x20], rdi
mov r9, rbx
mov r8, qword [rbx]
mov edx, 1
mov ecx, 1
call rax
cmp eax, 6
je 0x40d2d0
cmp eax, 8
jne 0x40d303
mov rax, qword [rsp + 0x38]
mov rax, qword [rax]
test rax, rax
mov qword [rsp + 0x38], rax
jne 0x40d241
mov eax, 5
add rsp, 0x40
pop rbx
pop rsi
pop rdi
ret
call dbg.fc_key_init_once
mov eax, dword [0x004db068]
mov rsi, qword [0x00505958]
test eax, eax
je 0x40d22f
mov esi, dword [0x00505950]
call qword [sym.imp.KERNEL32.dll_GetLastError]
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]
jmp 0x40d22f
mov rax, qword [rsp + 0x38]
lea r8, [rsp + 0x34]
mov rdx, rdi
mov rcx, rbx
mov qword [rbx + 0x10], 0
mov qword [rsp + 0x38], rsi
mov qword [rbx + 0x18], rax
call dbg._Unwind_RaiseException_Phase2
cmp eax, 7
jne 0x40d286
mov rcx, rdi
call sym.uw_install_context.isra.5
mov eax, 3
jmp 0x40d286
Function at 0x40d310
Capabilities:
Get thread local storage value

Disassembly:
push r12
push rbp
push rdi
push rsi
push rbx
sub rsp, 0x30
mov rbx, rcx
mov ecx, dword [0x004db068]
mov rbp, rdx
mov rdi, r8
test ecx, ecx
js 0x40d370
test ecx, ecx
mov rsi, qword [0x00505958]
jne 0x40d386
mov qword [rsp + 0x28], rsi
lea rsi, [rsp + 0x28]
mov rcx, rbx
mov qword [rbx + 0x10], rbp
lea r8, [rsp + 0x24]
mov rdx, rsi
mov qword [rbx + 0x18], rdi
call dbg._Unwind_ForcedUnwind_Phase2
cmp eax, 7
je 0x40d3ab
add rsp, 0x30
pop rbx
pop rsi
pop rdi
pop rbp
pop r12
ret
call dbg.fc_key_init_once
mov ecx, dword [0x004db068]
mov rsi, qword [0x00505958]
test ecx, ecx
je 0x40d338
mov esi, dword [0x00505950]
call qword [sym.imp.KERNEL32.dll_GetLastError]
mov r12d, eax
mov ecx, esi
call qword [sym.imp.KERNEL32.dll_TlsGetValue]
mov ecx, r12d
mov rsi, rax
call qword [sym.imp.KERNEL32.dll_SetLastError]
jmp 0x40d338
mov rcx, rsi
call sym.uw_install_context.isra.5
nop
nop
nop word cs:[rax + rax]

Function at 0x40d450
Capabilities:
Get thread local storage value

Disassembly:
push rdi
push rsi
push rbx
sub rsp, 0x30
cmp qword [rcx + 0x10], 0
mov rbx, rcx
je 0x40d4a0
mov edx, dword [0x004db068]
test edx, edx
js 0x40d4b0
test edx, edx
mov rsi, qword [0x00505958]
jne 0x40d4c6
mov qword [rsp + 0x28], rsi
lea rsi, [rsp + 0x28]
mov rcx, rbx
lea r8, [rsp + 0x24]
mov rdx, rsi
call dbg._Unwind_ForcedUnwind_Phase2
cmp eax, 7
jne 0x40d4e9
mov rcx, rsi
call sym.uw_install_context.isra.5
nop dword [rax]
call dbg._Unwind_SjLj_RaiseException
add rsp, 0x30
pop rbx
pop rsi
pop rdi
ret
call dbg.fc_key_init_once
mov edx, dword [0x004db068]
mov rsi, qword [0x00505958]
test edx, edx
je 0x40d476
mov esi, dword [0x00505950]
call qword [sym.imp.KERNEL32.dll_GetLastError]
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]
jmp 0x40d476
call sym.abort
nop
nop

Function at 0x40d510
Capabilities:
Get thread local storage value

Disassembly:
push rbp
push rdi
push rsi
push rbx
sub rsp, 0x38
mov eax, dword [0x004db068]
test eax, eax
mov rsi, rcx
mov rbp, rdx
js 0x40d590
test eax, eax
mov rbx, qword [0x00505958]
jne 0x40d5a6
mov qword [rsp + 0x28], rbx
lea rdi, [rsp + 0x28]
jmp 0x40d559
mov rdx, rbp
mov rcx, rdi
call rsi
test eax, eax
jne 0x40d580
mov rax, qword [rsp + 0x28]
mov rbx, qword [rax]
mov qword [rsp + 0x28], rbx
test rbx, rbx
jne 0x40d540
mov rdx, rbp
mov rcx, rdi
call rsi
test eax, eax
jne 0x40d580
mov eax, 5
add rsp, 0x38
pop rbx
pop rsi
pop rdi
pop rbp
ret
mov eax, 3
add rsp, 0x38
pop rbx
pop rsi
pop rdi
pop rbp
ret
call dbg.fc_key_init_once
mov eax, dword [0x004db068]
mov rbx, qword [0x00505958]
test eax, eax
je 0x40d533
mov ebx, dword [0x00505950]
call qword [sym.imp.KERNEL32.dll_GetLastError]
mov edi, eax
mov ecx, ebx
call qword [sym.imp.KERNEL32.dll_TlsGetValue]
mov ecx, edi
mov rbx, rax
call qword [sym.imp.KERNEL32.dll_SetLastError]
jmp 0x40d533
Function at 0x40d6b0
Capabilities:
Allocate thread local storage

Disassembly:
sub rsp, 0x28
xor r9d, r9d
xor edx, edx
xor ecx, ecx
mov dword [0x00505970], 0xffffffff
mov r8d, 0xffff
call qword [sym.imp.KERNEL32.dll_CreateSemaphoreW]
mov qword [0x00505978], rax
call qword [sym.imp.KERNEL32.dll_TlsAlloc]
cmp eax, 0xffffffff
je 0x40d700
lea rdx, [dbg.emutls_destroy]
mov ecx, eax
mov dword [0x00505968], eax
call sym.__mingwthr_key_dtor
test eax, eax
jne 0x40d70a
add rsp, 0x28
ret
call qword [sym.imp.KERNEL32.dll_GetLastError]
test eax, eax
je 0x40d6fb
call sym.abort
nop
Function at 0x40d710
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 rbx, qword [0x004e2a00]
mov r11d, dword [rbx]
mov rdi, rcx
test r11d, r11d
jne 0x40d744
mov rax, qword [rcx + 0x10]
test rax, rax
je 0x40d7a0
add rsp, 0x28
pop rbx
pop rsi
pop rdi
pop rbp
pop r12
pop r13
ret
mov rsi, qword [rcx + 0x10]
test rsi, rsi
je 0x40d7b0
mov ebx, dword [0x00505968]
mov r12, qword [sym.imp.KERNEL32.dll_GetLastError]
call r12
mov ebp, eax
mov ecx, ebx
call qword [sym.imp.KERNEL32.dll_TlsGetValue]
mov ecx, ebp
mov rbx, rax
call qword [sym.imp.KERNEL32.dll_SetLastError]
test rbx, rbx
je 0x40d821
mov rbp, qword [rbx]
cmp rbp, rsi
jb 0x40d861
lea rbx, [rbx + rsi*8]
mov rax, qword [rbx]
test rax, rax
jne 0x40d737
mov rcx, rdi
call dbg.emutls_alloc
mov qword [rbx], rax
jmp 0x40d737
call dbg.emutls_alloc
mov qword [rdi + 0x10], rax
jmp 0x40d737
mov r10d, dword [rbx]
test r10d, r10d
je 0x40d8c2
mov r9d, dword [global_once]
test r9d, r9d
je 0x40d8f0
lock add dword [0x00505970], 1
jne 0x40d920
mov rsi, qword [rdi + 0x10]
test rsi, rsi
je 0x40d8cf
mov eax, dword [rbx]
test eax, eax
je 0x40d74d
mov eax, 0xffffffff
lock xadd dword [0x00505970], eax
sub eax, 1
js 0x40d74d
xor r8d, r8d
mov edx, 1
mov rcx, qword [0x00505978]
call qword [sym.imp.KERNEL32.dll_ReleaseSemaphore]
jmp 0x40d74d
lea rcx, [rsi + 0x21]
mov edx, 8
call sym.calloc
lea rbp, [rsi + 0x20]
test rax, rax
mov rbx, rax
je 0x40d947
mov qword [rax], rbp
mov rdx, rbx
mov ecx, dword [0x00505968]
call qword [sym.imp.KERNEL32.dll_TlsSetValue]
test eax, eax
jne 0x40d787
call r12
jmp 0x40d787
lea r13, [rbp + rbp]
mov rcx, rbx
lea rax, [rsi + 0x20]
cmp rsi, r13
cmova r13, rax
lea rdx, [r13*8 + 8]
call sym.realloc
test rax, rax
mov rbx, rax
je 0x40d947
mov qword [rax], r13
lea rcx, [rax + rbp*8 + 8]
sub r13, rbp
xor edx, edx
lea r8, [r13*8]
call sym.memset
jmp 0x40d842
call dbg.emutls_init
mov dword [global_once], 1
mov edx, dword [rbx]
test edx, edx
jne 0x40d7cc
mov rsi, qword [rdi + 0x10]
test rsi, rsi
jne 0x40d74d
mov rax, qword [0x00505960]
lea rsi, [rax + 1]
mov qword [0x00505960], rsi
mov qword [rdi + 0x10], rsi
jmp 0x40d7e7
lock add dword [0x004db074], 1
je 0x40d8a9
mov r8d, dword [global_once]
lea rsi, [0x004db070]
mov rbp, qword [sym.imp.KERNEL32.dll_Sleep]
test r8d, r8d
jne 0x40d8b8
xor ecx, ecx
call rbp
mov ecx, dword [rsi]
test ecx, ecx
je 0x40d914
jmp 0x40d8b8
mov edx, 0xffffffff
mov rcx, qword [0x00505978]
call qword [sym.imp.KERNEL32.dll_WaitForSingleObject]
test eax, eax
je 0x40d7da
lock sub dword [0x00505970], 1
jmp 0x40d7da
call sym.abort
nop
nop dword [rax]

Function at 0x41a240
Capabilities:
Read file on windows

Disassembly:
push rsi
push rbx
sub rsp, 0x28
mov r9, qword [rcx + 0x40]
mov rsi, rdx
mov rbx, rcx
mov edx, 1
mov rcx, rsi
call sym.fread
mov edx, 0xffffffff
test rax, rax
jle 0x41a26c
movzx edx, byte [rsi + rax - 1]
mov dword [rbx + 0x48], edx
add rsp, 0x28
pop rbx
pop rsi
ret
Function at 0x41afe0
Capabilities:
Write file on windows

Disassembly:
push rbp
sub rsp, 0xb0
lea rax, [sym.__gxx_personality_sj0]
mov qword [rsp + 0x60], rax
lea rax, [0x004f82b0]
mov qword [rsp + 0x68], rax
lea rax, [rsp + 0xb0]
mov qword [rsp + 0x70], rax
lea rcx, [rsp + 0x30]
lea rax, [0x0041b1bf]
mov qword [rsp + 0x80], rsp
mov qword [rsp + 0x78], rax
call dbg._Unwind_SjLj_Register
cmp byte [0x004ddf20], 0
jne 0x41b18d
mov byte [0x004ddf20], 1
call sym.__cxa_current_exception_type
test rax, rax
je 0x41b153
mov rdx, qword [rax + 8]
lea r9, [rsp + 0xac]
xor eax, eax
cmp byte [rdx], 0x2a
mov dword [rsp + 0x38], 0xffffffff
mov dword [rsp + 0xac], 0xffffffff
sete al
xor r8d, r8d
add rdx, rax
mov rcx, rdx
mov qword [rsp + 0x98], rdx
xor edx, edx
call sym.__cxa_demangle
mov rdx, qword [sym.__acrt_iob_func]
mov ecx, 2
mov qword [rsp + 0x28], rax
mov qword [rsp + 0x20], rdx
call rdx
mov edx, 1
mov r8d, 0x30
lea rcx, str.terminate_called_after_throwing_an_instance_of_
mov r9, rax
call sym.fwrite
mov edx, dword [rsp + 0xac]
mov ecx, 2
test edx, edx
je 0x41b13d
mov dword [rsp + 0x38], 0xffffffff
mov rax, qword [rsp + 0x20]
call rax
mov rcx, qword [rsp + 0x98]
mov rdx, rax
call sym.fputs
mov ecx, 2
mov dword [rsp + 0x38], 0xffffffff
mov rax, qword [rsp + 0x20]
call rax
mov r8d, 2
mov edx, 1
lea rcx, [0x004de121]
mov r9, rax
call sym.fwrite
mov eax, dword [rsp + 0xac]
test eax, eax
jne 0x41b130
mov rcx, qword [rsp + 0x28]
call sym.free
mov dword [rsp + 0x38], 1
call sym.__cxa_rethrow
mov rdx, qword [rsp + 0x20]
call rdx
mov rcx, qword [rsp + 0x28]
mov rdx, rax
call sym.fputs
jmp 0x41b0ed
mov ecx, 2
mov dword [rsp + 0x38], 0xffffffff
call qword [sym.__acrt_iob_func]
mov r8d, 0x2d
mov edx, 1
lea rcx, str.terminate_called_without_an_active_exception_n
mov r9, rax
call sym.fwrite
mov dword [rsp + 0x38], 0xffffffff
call sym.abort
mov ecx, 2
mov dword [rsp + 0x38], 0xffffffff
call qword [sym.__acrt_iob_func]
mov r8d, 0x1d
mov edx, 1
lea rcx, str.terminate_called_recursively_n
mov r9, rax
call sym.fwrite
call sym.abort
mov rax, qword [rsp + 0x40]
mov rdx, qword [rsp + 0x48]
mov qword [rsp + 0x28], rax
mov eax, dword [rsp + 0x38]
test eax, eax
jne 0x41b266
sub rdx, 1
mov rcx, qword [rsp + 0x28]
jne 0x41b282
call sym.__cxa_begin_catch
mov rdx, qword [rax]
mov rcx, rax
call qword [rdx + 0x10]
mov ecx, 2
mov dword [rsp + 0x38], 2
mov qword [rsp + 0x28], rax
mov rax, qword [rsp + 0x20]
call rax
mov r9, rax
mov r8d, 0xb
mov edx, 1
lea rcx, str.__what__:
call sym.fwrite
mov ecx, 2
mov rax, qword [rsp + 0x20]
call rax
mov rcx, qword [rsp + 0x28]
mov rdx, rax
call sym.fputs
mov ecx, 2
mov rax, qword [rsp + 0x20]
call rax
mov rdx, rax
mov ecx, 0xa
call sym.fputc
call sym.__cxa_end_catch
jmp 0x41b180
sub eax, 1
jne 0x41b299
call sym.__cxa_end_catch
mov rcx, qword [rsp + 0x28]
mov dword [rsp + 0x38], 0xffffffff
call dbg._Unwind_SjLj_Resume
call sym.__cxa_begin_catch
mov dword [rsp + 0x38], 0xffffffff
call sym.__cxa_end_catch
jmp 0x41b180
ud2
Function at 0x41b1bf
Capabilities:
Write file on windows

Disassembly:
push rbp
sub rsp, 0xb0
lea rax, [sym.__gxx_personality_sj0]
mov qword [rsp + 0x60], rax
lea rax, [0x004f82b0]
mov qword [rsp + 0x68], rax
lea rax, [rsp + 0xb0]
mov qword [rsp + 0x70], rax
lea rcx, [rsp + 0x30]
lea rax, [0x0041b1bf]
mov qword [rsp + 0x80], rsp
mov qword [rsp + 0x78], rax
call dbg._Unwind_SjLj_Register
cmp byte [0x004ddf20], 0
jne 0x41b18d
mov byte [0x004ddf20], 1
call sym.__cxa_current_exception_type
test rax, rax
je 0x41b153
mov rdx, qword [rax + 8]
lea r9, [rsp + 0xac]
xor eax, eax
cmp byte [rdx], 0x2a
mov dword [rsp + 0x38], 0xffffffff
mov dword [rsp + 0xac], 0xffffffff
sete al
xor r8d, r8d
add rdx, rax
mov rcx, rdx
mov qword [rsp + 0x98], rdx
xor edx, edx
call sym.__cxa_demangle
mov rdx, qword [sym.__acrt_iob_func]
mov ecx, 2
mov qword [rsp + 0x28], rax
mov qword [rsp + 0x20], rdx
call rdx
mov edx, 1
mov r8d, 0x30
lea rcx, str.terminate_called_after_throwing_an_instance_of_
mov r9, rax
call sym.fwrite
mov edx, dword [rsp + 0xac]
mov ecx, 2
test edx, edx
je 0x41b13d
mov dword [rsp + 0x38], 0xffffffff
mov rax, qword [rsp + 0x20]
call rax
mov rcx, qword [rsp + 0x98]
mov rdx, rax
call sym.fputs
mov ecx, 2
mov dword [rsp + 0x38], 0xffffffff
mov rax, qword [rsp + 0x20]
call rax
mov r8d, 2
mov edx, 1
lea rcx, [0x004de121]
mov r9, rax
call sym.fwrite
mov eax, dword [rsp + 0xac]
test eax, eax
jne 0x41b130
mov rcx, qword [rsp + 0x28]
call sym.free
mov dword [rsp + 0x38], 1
call sym.__cxa_rethrow
mov rdx, qword [rsp + 0x20]
call rdx
mov rcx, qword [rsp + 0x28]
mov rdx, rax
call sym.fputs
jmp 0x41b0ed
mov ecx, 2
mov dword [rsp + 0x38], 0xffffffff
call qword [sym.__acrt_iob_func]
mov r8d, 0x2d
mov edx, 1
lea rcx, str.terminate_called_without_an_active_exception_n
mov r9, rax
call sym.fwrite
mov dword [rsp + 0x38], 0xffffffff
call sym.abort
mov ecx, 2
mov dword [rsp + 0x38], 0xffffffff
call qword [sym.__acrt_iob_func]
mov r8d, 0x1d
mov edx, 1
lea rcx, str.terminate_called_recursively_n
mov r9, rax
call sym.fwrite
call sym.abort
mov rax, qword [rsp + 0x40]
mov rdx, qword [rsp + 0x48]
mov qword [rsp + 0x28], rax
mov eax, dword [rsp + 0x38]
test eax, eax
jne 0x41b266
sub rdx, 1
mov rcx, qword [rsp + 0x28]
jne 0x41b282
call sym.__cxa_begin_catch
mov rdx, qword [rax]
mov rcx, rax
call qword [rdx + 0x10]
mov ecx, 2
mov dword [rsp + 0x38], 2
mov qword [rsp + 0x28], rax
mov rax, qword [rsp + 0x20]
call rax
mov r9, rax
mov r8d, 0xb
mov edx, 1
lea rcx, str.__what__:
call sym.fwrite
mov ecx, 2
mov rax, qword [rsp + 0x20]
call rax
mov rcx, qword [rsp + 0x28]
mov rdx, rax
call sym.fputs
mov ecx, 2
mov rax, qword [rsp + 0x20]
call rax
mov rdx, rax
mov ecx, 0xa
call sym.fputc
call sym.__cxa_end_catch
jmp 0x41b180
sub eax, 1
jne 0x41b299
call sym.__cxa_end_catch
mov rcx, qword [rsp + 0x28]
mov dword [rsp + 0x38], 0xffffffff
call dbg._Unwind_SjLj_Resume
call sym.__cxa_begin_catch
mov dword [rsp + 0x38], 0xffffffff
call sym.__cxa_end_catch
jmp 0x41b180
ud2
Function at 0x482790
Capabilities:
Read file on windows

Disassembly:
push r12
push rbp
push rdi
push rsi
push rbx
sub rsp, 0x20
mov r12, qword [sym.imp.msvcrt.dll__errno]
mov rbp, rcx
mov rdi, rdx
mov esi, r8d
jmp 0x4827b8
call r12
cmp dword [rax], 4
jne 0x4827d6
mov rcx, rbp
call method.std::__basic_file_char_.fd__
mov r8d, esi
mov rdx, rdi
mov ecx, eax
call sym.read
movsxd rbx, eax
cmp rbx, 0xffffffffffffffff
je 0x4827b0
mov rax, rbx
add rsp, 0x20
pop rbx
pop rsi
pop rdi
pop rbp
pop r12
ret

Function at 0x4a1610
Capabilities:
Generate random numbers using a mersenne twister

Disassembly:
push rsi
push rbx
sub rsp, 0x38
mov rsi, rdx
mov rbx, rcx
lea rdx, str.mt19937
mov rcx, rsi
call method.std::string.compare_char_const__const
mov ecx, 0x1571
test eax, eax
jne 0x4a1675
mov dword [rbx], ecx
mov edx, 1
jmp 0x4a1644
mov ecx, dword [rbx + rdx*4 - 4]
mov eax, ecx
shr eax, 0x1e
xor eax, ecx
imul eax, eax, 0x6c078965
add eax, edx
mov dword [rbx + rdx*4], eax
add rdx, 1
cmp rdx, 0x270
jne 0x4a1640
mov qword [rbx + 0x9c0], 0x270
add rsp, 0x38
pop rbx
pop rsi
ret
mov rsi, qword [rsi]
lea rdx, [rsp + 0x28]
xor r8d, r8d
mov rcx, rsi
call sym.strtoul
cmp byte [rsi], 0
mov ecx, eax
je 0x4a1699
mov rax, qword [rsp + 0x28]
cmp byte [rax], 0
je 0x4a1634
lea rcx, str.random_device::random_device_const_std::string_
call method.std.__throw_runtime_error_char_const_
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop

Function at 0x4d9880
Capabilities:
Get thread local storage value
Set thread local storage value

Disassembly:
lea rcx, [0x004ddf40]
jmp dbg.__emutls_get_address

Function at 0x4dab40
Capabilities:
Write file on windows

Disassembly:
push rsi
push rbx
sub rsp, 0x38
lea rax, [rsp + 0x58]
mov rbx, rcx
mov ecx, 2
mov qword [rsp + 0x58], rdx
mov qword [rsp + 0x60], r8
mov qword [rsp + 0x68], r9
mov qword [rsp + 0x28], rax
call sym.__acrt_iob_func
mov r8d, 0x1b
mov edx, 1
lea rcx, str.Mingw_w64_runtime_failure:_n
mov r9, rax
call sym.fwrite
mov rsi, qword [rsp + 0x28]
mov ecx, 2
call sym.__acrt_iob_func
mov rdx, rbx
mov rcx, rax
mov r8, rsi
call sym.vfprintf
call sym.abort
nop
nop
nop
nop
nop
nop
nop
nop