joyce8/EMBER2024-capa huggingface dataset:
Function at 0x140017f80
Capabilities:
Read file on windows

Disassembly:
push r15
push r14
push r13
push r12
push rbx
sub rsp, 0x30
mov r14d, ecx
mov rbx, rdx
mov ecx, 0x78
mov edx, 1
call sub.msvcrt.dll_calloc
mov r13, rax
test rax, rax
je 0x1400180b5
mov edx, 0x6160
mov ecx, 1
call sub.msvcrt.dll_calloc
mov r12, rax
test rax, rax
je 0x1400180ca
mov ecx, r14d
mov edx, 0x8000
call qword [sym.imp.msvcrt.dll__setmode]
mov ecx, r14d
lea rdx, [0x1400255b0]
call sub.msvcrt.dll__fdopen
mov qword [r13 + 0x70], r12
mov edx, 1
mov r8d, 6
mov qword [r13 + 0x68], 0
mov r9, rax
mov r15, rax
mov dword [r12 + 4], r14d
lea r14, [rsp + 0x29]
mov rcx, r14
mov qword [r12 + 0x38], rax
mov dword [r12], 8
mov qword [r12 + 0x40], 0
call sub.msvcrt.dll_fread
cmp eax, 6
jne 0x1400180a8
cmp word [rsp + 0x29], 0x4947
mov byte [rsp + 0x2f], 0
je 0x140018078
test rbx, rbx
je 0x140018049
mov dword [rbx], 0x67
mov rcx, r15
call sub.msvcrt.dll_fclose
mov rcx, r12
call fcn.140022740
mov rcx, r13
xor r13d, r13d
call fcn.140022740
mov rax, r13
add rsp, 0x30
pop rbx
pop r12
pop r13
pop r14
pop r15
ret
cmp byte [r14 + 2], 0x46
jne 0x14001803e
mov rcx, r13
call fcn.140017d30
test eax, eax
je 0x140018049
cmp byte [rsp + 0x2c], 0x39
mov dword [r13 + 0x60], 0
sete byte [r12 + 0x6158]
jmp 0x140018064
test rbx, rbx
je 0x140018049
mov dword [rbx], 0x66
jmp 0x140018049
test rbx, rbx
je 0x1400180c0
mov dword [rbx], 0x6d
mov ecx, r14d
call sub.msvcrt.dll__close
jmp 0x140018064
test rbx, rbx
je 0x1400180d5
mov dword [rbx], 0x6d
mov ecx, r14d
call sub.msvcrt.dll__close
mov rcx, r13
xor r13d, r13d
call fcn.140022740
jmp 0x140018064

Function at 0x1400182d0
Capabilities:
Read file on windows

Disassembly:
push rsi
push rbx
sub rsp, 0x38
mov rsi, rdx
mov rdx, qword [rcx + 0x70]
mov rbx, rcx
mov eax, dword [rdx]
and eax, 8
jne 0x1400182f8
mov dword [rcx + 0x60], 0x6f
add rsp, 0x38
pop rbx
pop rsi
ret
mov rax, qword [rdx + 0x40]
test rax, rax
je 0x140018380
lea rdx, [rsp + 0x2f]
mov r8d, 1
call rax
cmp eax, 1
je 0x140018328
xor eax, eax
mov dword [rbx + 0x60], 0x66
add rsp, 0x38
pop rbx
pop rsi
ret
movzx edx, byte [rsp + 0x2f]
cmp dl, 0x2c
je 0x140018370
cmp dl, 0x3b
je 0x140018350
cmp dl, 0x21
je 0x140018360
mov dword [rsi], 0
xor eax, eax
mov dword [rbx + 0x60], 0x6b
jmp 0x1400182ee
mov dword [rsi], 4
jmp 0x1400182ee
mov dword [rsi], 3
jmp 0x1400182ee
mov dword [rsi], 2
jmp 0x1400182ee
mov r9, qword [rdx + 0x38]
lea rcx, [rsp + 0x2f]
mov r8d, 1
mov edx, 1
call sub.msvcrt.dll_fread
jmp 0x14001830e
Function at 0x140018860
Capabilities:
Read file on windows

Disassembly:
push r12
push rdi
push rsi
push rbx
sub rsp, 0x38
mov rsi, qword [rcx + 0x70]
mov rax, qword [rsi + 0x40]
mov rbx, rcx
mov rdi, rdx
test rax, rax
je 0x140018910
lea rdx, [rsp + 0x2f]
mov r8d, 1
call rax
mov r12d, eax
cmp r12d, 1
jne 0x1400188f0
movzx eax, byte [rsp + 0x2f]
test al, al
jne 0x1400188b8
mov eax, r12d
mov qword [rdi], 0
add rsp, 0x38
pop rbx
pop rsi
pop rdi
pop r12
ret
lea rdx, [rsi + 0x50]
movzx r8d, al
mov qword [rdi], rdx
mov byte [rsi + 0x50], al
mov rdx, qword [rdi]
lea r10, [rdx + 1]
mov rdx, qword [rbx + 0x70]
mov r9, qword [rdx + 0x40]
test r9, r9
je 0x140018938
mov rdx, r10
mov rcx, rbx
call r9
movzx edx, byte [rsp + 0x2f]
cmp edx, eax
je 0x1400188fa
nop dword [rax]
mov dword [rbx + 0x60], 0x66
xor r12d, r12d
mov eax, r12d
add rsp, 0x38
pop rbx
pop rsi
pop rdi
pop r12
ret
mov r9, qword [rsi + 0x38]
lea rcx, [rsp + 0x2f]
mov r8d, 1
mov edx, 1
call sub.msvcrt.dll_fread
mov r12d, eax
jmp 0x140018890
mov r9, qword [rdx + 0x38]
movzx r8d, al
mov edx, 1
mov rcx, r10
call sub.msvcrt.dll_fread
jmp 0x1400188e3

Function at 0x140018c30
Capabilities:
Read file on windows

Disassembly:
push r12
push rdi
push rsi
push rbx
sub rsp, 0x38
mov rsi, qword [rcx + 0x70]
mov rax, qword [rsi + 0x40]
mov rbx, rcx
mov rdi, rdx
test rax, rax
je 0x140018ce0
lea rdx, [rsp + 0x2f]
mov r8d, 1
call rax
mov r12d, eax
cmp r12d, 1
jne 0x140018cc8
movzx eax, byte [rsp + 0x2f]
test al, al
jne 0x140018c90
mov eax, r12d
mov qword [rdi], 0
mov byte [rsi + 0x50], 0
mov dword [rsi + 0x34], 0
add rsp, 0x38
pop rbx
pop rsi
pop rdi
pop r12
ret
lea rdx, [rsi + 0x50]
movzx r8d, al
mov qword [rdi], rdx
mov byte [rsi + 0x50], al
mov rdx, qword [rdi]
lea r10, [rdx + 1]
mov rdx, qword [rbx + 0x70]
mov r9, qword [rdx + 0x40]
test r9, r9
je 0x140018d08
mov rdx, r10
mov rcx, rbx
call r9
movzx edx, byte [rsp + 0x2f]
cmp edx, eax
je 0x140018cd2
nop dword [rax]
mov dword [rbx + 0x60], 0x66
xor r12d, r12d
mov eax, r12d
add rsp, 0x38
pop rbx
pop rsi
pop rdi
pop r12
ret
mov r9, qword [rsi + 0x38]
lea rcx, [rsp + 0x2f]
mov r8d, 1
mov edx, 1
call sub.msvcrt.dll_fread
mov r12d, eax
jmp 0x140018c60
mov r9, qword [rdx + 0x38]
movzx r8d, al
mov edx, 1
mov rcx, r10
call sub.msvcrt.dll_fread
jmp 0x140018cbb
Function at 0x1400192a0
Capabilities:
Write file on windows

Disassembly:
push r15
push r14
push r13
push r12
push rbp
push rdi
push rsi
push rbx
sub rsp, 0x38
xor edi, edi
mov rsi, rcx
mov ebp, r8d
lea r12, [rsp + 0x2d]
mov rbx, rdx
lea r13d, [r8 - 1]
test r8d, r8d
jg 0x140019360
jmp 0x140019430
mov r14d, dword [rbx]
mov r15, qword [rbx + 8]
mov byte [rsp + 0x2d], r14b
mov rax, qword [rdx + 0x48]
test rax, rax
je 0x1400193e8
mov r8d, 1
mov rdx, r12
mov rcx, rsi
call rax
mov rdx, qword [rsi + 0x70]
mov rax, qword [rdx + 0x48]
test rax, rax
je 0x1400193c8
mov r8d, r14d
mov rdx, r15
mov rcx, rsi
call rax
cmp r13d, edi
je 0x140019327
mov eax, dword [rbx + 0x28]
test eax, eax
je 0x140019351
mov rax, qword [rsi + 0x70]
test byte [rax], 1
je 0x1400193a9
mov byte [rsp + 0x2d], 0
mov r9, qword [rax + 0x48]
test r9, r9
je 0x140019408
mov r8d, 1
mov rdx, r12
mov rcx, rsi
call r9
add edi, 1
add rbx, 0x18
cmp ebp, edi
je 0x140019430
mov rdx, qword [rsi + 0x70]
mov ecx, dword [rbx + 0x10]
mov eax, dword [rdx]
and eax, 1
test ecx, ecx
je 0x1400193a1
test eax, eax
je 0x1400193a9
mov byte [rsp + 0x2d], 0x21
mov byte [rsp + 0x2e], cl
mov rax, qword [rdx + 0x48]
test rax, rax
je 0x140019440
mov r8d, 2
mov rdx, r12
mov rcx, rsi
call rax
mov rdx, qword [rsi + 0x70]
mov eax, dword [rdx]
and eax, 1
test eax, eax
jne 0x1400192d8
mov dword [rsi + 0x60], 0xa
xor eax, eax
add rsp, 0x38
pop rbx
pop rsi
pop rdi
pop rbp
pop r12
pop r13
pop r14
pop r15
ret
mov r9, qword [rdx + 0x38]
movsxd r8, r14d
mov edx, 1
mov rcx, r15
call sub.msvcrt.dll_fwrite
jmp 0x14001931b
mov r9, qword [rdx + 0x38]
mov r8d, 1
mov edx, 1
mov rcx, r12
call sub.msvcrt.dll_fwrite
jmp 0x1400192ff
mov r9, qword [rax + 0x38]
mov r8d, 1
mov rcx, r12
add edi, 1
mov edx, 1
add rbx, 0x18
call sub.msvcrt.dll_fwrite
cmp ebp, edi
jne 0x140019360
nop
mov eax, 1
jmp 0x1400193b2
mov r9, qword [rdx + 0x38]
mov r8d, 2
mov edx, 1
mov rcx, r12
call sub.msvcrt.dll_fwrite
jmp 0x140019398
Function at 0x140019460
Capabilities:
Write file on windows

Disassembly:
push r12
push rsi
push rbx
sub rsp, 0x20
movzx eax, byte [rdx]
mov rsi, rcx
mov r12, rdx
mov ebx, r8d
cmp r8d, 0x1000
je 0x1400194a8
cmp al, 0xff
je 0x140019510
add eax, 1
movzx edx, al
mov byte [r12], al
mov eax, 1
mov byte [r12 + rdx], bl
add rsp, 0x20
pop rbx
pop rsi
pop r12
ret
test al, al
je 0x1400194d4
mov rdx, qword [rcx + 0x70]
lea r8d, [rax + 1]
mov rax, qword [rdx + 0x48]
test rax, rax
je 0x140019568
mov rdx, r12
call rax
mov edx, eax
movzx eax, byte [r12]
add eax, 1
cmp eax, edx
jne 0x1400194f9
mov byte [r12], 0
mov rdx, qword [rsi + 0x70]
mov rax, qword [rdx + 0x48]
test rax, rax
je 0x140019548
mov r8d, 1
mov rdx, r12
mov rcx, rsi
call rax
cmp eax, 1
je 0x140019498
xor eax, eax
mov dword [rsi + 0x60], 2
add rsp, 0x20
pop rbx
pop rsi
pop r12
ret
mov rdx, qword [rcx + 0x70]
mov rax, qword [rdx + 0x48]
test rax, rax
je 0x140019590
mov r8d, 0x100
mov rdx, r12
call rax
movzx edx, byte [r12]
add edx, 1
cmp edx, eax
jne 0x1400194f9
mov edx, 1
mov eax, 1
jmp 0x14001948b
mov r9, qword [rdx + 0x38]
mov r8d, 1
mov edx, 1
mov rcx, r12
call sub.msvcrt.dll_fwrite
jmp 0x1400194f4
mov r9, qword [rdx + 0x38]
and r8d, 0x1ff
mov edx, 1
mov rcx, r12
call sub.msvcrt.dll_fwrite
mov edx, eax
jmp 0x1400194c8
mov r9, qword [rdx + 0x38]
mov r8d, 0x100
mov edx, 1
mov rcx, r12
call sub.msvcrt.dll_fwrite
jmp 0x140019528
Function at 0x14001ace0
Capabilities:
Write file on windows

Disassembly:
push r15
push r14
push r13
push r12
push rbx
sub rsp, 0x30
mov r12, rcx
mov rbx, rdx
test rcx, rcx
je 0x14001ade0
mov r13, qword [rcx + 0x70]
test r13, r13
je 0x14001ade0
mov r14d, dword [r13]
and r14d, 1
jne 0x14001ad40
test rdx, rdx
je 0x14001ad1e
mov dword [rdx], 0xa
mov rcx, r12
xor r14d, r14d
call fcn.140022740
mov eax, r14d
add rsp, 0x30
pop rbx
pop r12
pop r13
pop r14
pop r15
ret
mov rax, qword [r13 + 0x48]
mov r15, qword [r13 + 0x38]
mov byte [rsp + 0x2f], 0x3b
test rax, rax
je 0x14001ae08
lea rdx, [rsp + 0x2f]
mov r8d, 1
call rax
mov rcx, qword [r12 + 0x40]
test rcx, rcx
je 0x14001ad7b
call fcn.14001b170
mov qword [r12 + 0x40], 0
mov rcx, qword [r12 + 0x18]
test rcx, rcx
je 0x14001ad93
call fcn.14001b170
mov qword [r12 + 0x18], 0
mov rcx, qword [r13 + 0x6150]
test rcx, rcx
je 0x14001ada4
call fcn.140022740
mov rcx, r13
call fcn.140022740
test r15, r15
je 0x14001adbd
mov rcx, r15
call sub.msvcrt.dll_fclose
test eax, eax
jne 0x14001adf0
mov rcx, r12
call fcn.140022740
test rbx, rbx
je 0x14001ad29
mov dword [rbx], 0
jmp 0x14001ad29
xor r14d, r14d
jmp 0x14001ad29
test rbx, rbx
je 0x14001ad1e
mov dword [rbx], 9
jmp 0x14001ad1e
lea rcx, [rsp + 0x2f]
mov r9, r15
mov r8d, 1
mov edx, 1
call sub.msvcrt.dll_fwrite
jmp 0x14001ad63

Function at 0x14001bf40
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 fcn.140022d40
mov r8d, 0x1b
mov edx, 1
lea rcx, str.Mingw_w64_runtime_failure:_n
mov r9, rax
call sub.msvcrt.dll_fwrite
mov rbx, qword [rsp + 0x28]
mov ecx, 2
call fcn.140022d40
mov rdx, r12
mov rcx, rax
mov r8, rbx
call sub.msvcrt.dll_vfprintf
call sub.msvcrt.dll_abort
nop
nop word [rax + rax]
Function at 0x14001bfb0
Capabilities:
Allocate or change rwx memory

Disassembly:
push r12
push rsi
push rbx
sub rsp, 0x50
movsxd rbx, dword [0x1400290c4]
mov r12, rcx
test ebx, ebx
jle 0x14001c0e0
mov rax, qword [0x1400290c8]
xor ecx, ecx
add rax, 0x18
nop word [rax + rax]
mov rdx, qword [rax]
cmp rdx, r12
ja 0x14001bffc
mov r8, qword [rax + 8]
mov r8d, dword [r8 + 8]
add rdx, r8
cmp r12, rdx
jb 0x14001c083
add ecx, 1
add rax, 0x28
cmp ecx, ebx
jne 0x14001bfe0
mov rcx, r12
call fcn.14001c960
mov rsi, rax
test rax, rax
je 0x14001c102
mov rax, qword [0x1400290c8]
lea rbx, [rbx + rbx*4]
shl rbx, 3
add rax, rbx
mov qword [rax + 0x20], rsi
mov dword [rax], 0
call fcn.14001ca90
mov ecx, dword [rsi + 0xc]
lea rdx, [rsp + 0x20]
mov r8d, 0x30
add rcx, rax
mov rax, qword [0x1400290c8]
mov qword [rax + rbx + 0x18], rcx
call qword [sym.imp.KERNEL32.dll_VirtualQuery]
test rax, rax
je 0x14001c0e7
mov eax, dword [rsp + 0x44]
lea edx, [rax - 0x40]
and edx, 0xffffffbf
je 0x14001c07c
lea edx, [rax - 4]
and edx, 0xfffffffb
jne 0x14001c090
add dword [0x1400290c4], 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 [0x1400290c8]
mov qword [rbx + 8], rcx
mov r9, rbx
mov qword [rbx + 0x10], rdx
call qword [sym.imp.KERNEL32.dll_VirtualProtect]
test eax, eax
jne 0x14001c07c
call qword [sym.imp.KERNEL32.dll_GetLastError]
lea rcx, str.__VirtualProtect_failed_with_code_0x_x
mov edx, eax
call fcn.14001bf40
nop dword [rax]
xor ebx, ebx
jmp 0x14001c007
mov rax, qword [0x1400290c8]
mov edx, dword [rsi + 8]
lea rcx, str.__VirtualQuery_failed_for__d_bytes_at_address__p
mov r8, qword [rax + rbx + 0x18]
call fcn.14001bf40
mov rdx, r12
lea rcx, str.Address__p_has_no_image_section
call fcn.14001bf40
nop
nop word cs:[rax + rax]
nop dword [rax]

Function at 0x14001c5d0
Capabilities:
Get thread local storage value

Disassembly:
push r12
push rdi
push rsi
push rbx
sub rsp, 0x28
lea rcx, [0x140029120]
call qword [sym.imp.KERNEL32.dll_EnterCriticalSection]
mov rbx, qword [0x140029100]
test rbx, rbx
je 0x14001c624
mov rdi, qword [sym.imp.KERNEL32.dll_TlsGetValue]
mov rsi, qword [sym.imp.KERNEL32.dll_GetLastError]
mov ecx, dword [rbx]
call rdi
mov r12, rax
call rsi
test eax, eax
jne 0x14001c61b
test r12, r12
je 0x14001c61b
mov rax, qword [rbx + 8]
mov rcx, r12
call rax
mov rbx, qword [rbx + 0x10]
test rbx, rbx
jne 0x14001c600
lea rcx, [0x140029120]
add rsp, 0x28
pop rbx
pop rsi
pop rdi
pop r12
jmp qword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
Function at 0x14001c960
Capabilities:
Enumerate pe sections
Parse pe header

Disassembly:
mov rdx, qword [0x1400262c0]
xor eax, eax
cmp word [rdx], 0x5a4d
jne 0x14001c980
movsxd r8, dword [rdx + 0x3c]
add r8, rdx
cmp dword [r8], 0x4550
je 0x14001c988
ret
cmp word [r8 + 0x18], 0x20b
jne 0x14001c980
movzx eax, word [r8 + 0x14]
sub rcx, rdx
movzx edx, word [r8 + 6]
lea rax, [r8 + rax + 0x18]
test edx, edx
je 0x14001c9d5
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 0x14001c9cc
add edx, dword [rax + 8]
cmp rcx, rdx
jb 0x14001c980
add rax, 0x28
cmp rax, r9
jne 0x14001c9b8
xor eax, eax
ret

Function at 0x14001c9e0
Capabilities:
Parse pe header

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

Function at 0x14001ca90
Capabilities:
Parse pe header

Disassembly:
mov rax, qword [0x1400262c0]
xor r8d, r8d
cmp word [rax], 0x5a4d
jne 0x14001cab0
movsxd rdx, dword [rax + 0x3c]
add rdx, rax
cmp dword [rdx], 0x4550
je 0x14001cab8
mov rax, r8
ret
cmp word [rdx + 0x18], 0x20b
cmove r8, rax
mov rax, r8
ret
Function at 0x140a28058
Capabilities:
Decompress data using aplib

Disassembly:
call fcn.140a281df
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 0x140a28089
mov dl, byte [rsi]
inc rsi
adc dl, dl
jae 0x140a2806f
add dl, dl
jne 0x140a28096
mov dl, byte [rsi]
inc rsi
adc dl, dl
jae 0x140a280f6
xor eax, eax
add dl, dl
jne 0x140a280a5
mov dl, byte [rsi]
inc rsi
adc dl, dl
jae 0x140a281ad
add dl, dl
jne 0x140a280b6
mov dl, byte [rsi]
inc rsi
adc dl, dl
adc eax, eax
add dl, dl
jne 0x140a280c3
mov dl, byte [rsi]
inc rsi
adc dl, dl
adc eax, eax
add dl, dl
jne 0x140a280d0
mov dl, byte [rsi]
inc rsi
adc dl, dl
adc eax, eax
add dl, dl
jne 0x140a280dd
mov dl, byte [rsi]
inc rsi
adc dl, dl
adc eax, eax
je 0x140a280ea
push rdi
mov eax, eax
sub rdi, rax
mov al, byte [rdi]
pop rdi
mov byte [rdi], al
inc rdi
mov ebx, 2
jmp 0x140a2807e
mov eax, 1
add dl, dl
jne 0x140a28106
mov dl, byte [rsi]
inc rsi
adc dl, dl
adc eax, eax
add dl, dl
jne 0x140a28113
mov dl, byte [rsi]
inc rsi
adc dl, dl
jb 0x140a280fb
sub eax, ebx
mov ebx, 1
jne 0x140a2814c
mov ecx, 1
add dl, dl
jne 0x140a2812e
mov dl, byte [rsi]
inc rsi
adc dl, dl
adc ecx, ecx
add dl, dl
jne 0x140a2813b
mov dl, byte [rsi]
inc rsi
adc dl, dl
jb 0x140a28123
push rsi
mov rsi, rdi
sub rsi, rbp
rep movsb byte [rdi], byte [rsi]
pop rsi
jmp 0x140a2807e
dec eax
shl eax, 8
mov al, byte [rsi]
inc rsi
mov ebp, eax
mov ecx, 1
add dl, dl
jne 0x140a28168
mov dl, byte [rsi]
inc rsi
adc dl, dl
adc ecx, ecx
add dl, dl
jne 0x140a28175
mov dl, byte [rsi]
inc rsi
adc dl, dl
jb 0x140a2815d
cmp eax, 0x7d00
jae 0x140a2819b
cmp eax, 0x500
jb 0x140a28196
inc ecx
push rsi
mov rsi, rdi
sub rsi, rax
rep movsb byte [rdi], byte [rsi]
pop rsi
jmp 0x140a2807e
cmp eax, 0x7f
ja 0x140a2819e
add ecx, 2
push rsi
mov rsi, rdi
sub rsi, rax
rep movsb byte [rdi], byte [rsi]
pop rsi
jmp 0x140a2807e
mov al, byte [rsi]
inc rsi
xor ecx, ecx
shr al, 1
je 0x140a281d2
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 0x140a2807e
pop r10
sub rdi, qword [r10 + 0x20]
mov eax, edi
pop r10
ret 0x20
Function at 0x140001da0
Capabilities:
Allocate or change rwx memory

Disassembly:
push rdi
push rsi
push rbx
sub rsp, 0x50
movsxd rsi, dword [0x14009d0a4]
mov rbx, rcx
test esi, esi
jle 0x140001ed0
mov rax, qword [0x14009d0a8]
xor r9d, r9d
add rax, 0x18
nop word [rax + rax]
mov r8, qword [rax]
cmp rbx, r8
jb 0x140001deb
mov rdx, qword [rax + 8]
mov edx, dword [rdx + 8]
add r8, rdx
cmp rbx, r8
jb 0x140001e75
add r9d, 1
add rax, 0x28
cmp r9d, esi
jne 0x140001dd0
mov rcx, rbx
call dbg.__mingw_GetSectionForAddress
mov rdi, rax
test rax, rax
je 0x140001ef2
mov rax, qword [0x14009d0a8]
lea rbx, [rsi + rsi*4]
shl rbx, 3
add rax, rbx
mov qword [rax + 0x20], rdi
mov dword [rax], 0
call dbg._GetPEImageBase
mov edx, dword [rdi + 0xc]
mov r8d, 0x30
lea rcx, [rax + rdx]
mov rax, qword [0x14009d0a8]
lea rdx, [rsp + 0x20]
mov qword [rax + rbx + 0x18], rcx
call qword [sym.imp.KERNEL32.dll_VirtualQuery]
test rax, rax
je 0x140001ed7
mov eax, dword [rsp + 0x44]
lea edx, [rax - 0x40]
and edx, 0xffffffbf
je 0x140001e6e
lea edx, [rax - 4]
and edx, 0xfffffffb
jne 0x140001e80
add dword [0x14009d0a4], 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 [0x14009d0a8]
mov qword [rbx + 8], rcx
mov r9, rbx
mov qword [rbx + 0x10], rdx
call qword [sym.imp.KERNEL32.dll_VirtualProtect]
test eax, eax
jne 0x140001e6e
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 esi, esi
jmp 0x140001df8
mov rax, qword [0x14009d0a8]
mov edx, dword [rdi + 8]
lea rcx, str.__VirtualQuery_failed_for__d_bytes_at_address__p
mov r8, qword [rax + rbx + 0x18]
call dbg.__report_error
mov rdx, rbx
lea rcx, str.Address__p_has_no_image_section
call dbg.__report_error
nop
nop word cs:[rax + rax]
nop dword [rax]

Function at 0x140002460
Capabilities:
Get thread local storage value

Disassembly:
push r12
push rbp
push rdi
push rsi
push rbx
sub rsp, 0x20
lea r12, [0x14009d100]
mov rcx, r12
call qword [sym.imp.KERNEL32.dll_EnterCriticalSection]
mov rbx, qword [0x14009d0e0]
test rbx, rbx
je 0x1400024bc
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 0x1400024b3
test rsi, rsi
je 0x1400024b3
mov rax, qword [rbx + 8]
mov rcx, rsi
call rax
mov rbx, qword [rbx + 0x10]
test rbx, rbx
jne 0x140002498
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 0x1400026d0
Capabilities:
Parse pe header

Disassembly:
xor eax, eax
cmp word [rcx], 0x5a4d
jne 0x1400026e8
movsxd rdx, dword [rcx + 0x3c]
add rcx, rdx
cmp dword [rcx], 0x4550
je 0x1400026f0
ret
xor eax, eax
cmp word [rcx + 0x18], 0x20b
sete al
ret
Function at 0x140002700
Capabilities:
Enumerate pe sections

Disassembly:
movsxd rax, dword [rcx + 0x3c]
add rcx, rax
movzx eax, word [rcx + 0x14]
movzx r8d, word [rcx + 6]
lea rax, [rcx + rax + 0x18]
test r8w, r8w
je 0x14000274d
lea ecx, [r8 - 1]
lea rcx, [rcx + rcx*4]
lea r9, [rax + rcx*8 + 0x28]
nop dword [rax + rax]
mov r8d, dword [rax + 0xc]
mov rcx, r8
cmp rdx, r8
jb 0x140002744
add ecx, dword [rax + 8]
cmp rdx, rcx
jb 0x14000274f
add rax, 0x28
cmp rax, r9
jne 0x140002730
xor eax, eax
ret

Function at 0x140002750
Capabilities:
Parse pe header

Disassembly:
push rdi
push rsi
push rbx
sub rsp, 0x20
mov rsi, rcx
call sym.strlen
cmp rax, 8
ja 0x1400027e0
mov rdx, qword [0x14009a780]
xor ebx, ebx
cmp word [rdx], 0x5a4d
jne 0x1400027ce
movsxd rax, dword [rdx + 0x3c]
add rax, rdx
cmp dword [rax], 0x4550
jne 0x1400027ce
cmp word [rax + 0x18], 0x20b
jne 0x1400027ce
movzx edx, word [rax + 0x14]
lea rbx, [rax + rdx + 0x18]
movzx edx, word [rax + 6]
test dx, dx
je 0x1400027e0
lea eax, [rdx - 1]
lea rax, [rax + rax*4]
lea rdi, [rbx + rax*8 + 0x28]
jmp 0x1400027b9
add rbx, 0x28
cmp rbx, rdi
je 0x1400027e0
mov r8d, 8
mov rdx, rsi
mov rcx, rbx
call sym.strncmp
test eax, eax
jne 0x1400027b0
mov rax, rbx
add rsp, 0x20
pop rbx
pop rsi
pop rdi
ret
xor ebx, ebx
mov rax, rbx
add rsp, 0x20
pop rbx
pop rsi
pop rdi
ret

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

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

Function at 0x140002870
Capabilities:
Parse pe header

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

Function at 0x1400028b0
Capabilities:
Parse pe header

Disassembly:
mov r8, qword [0x14009a780]
xor eax, eax
cmp word [r8], 0x5a4d
jne 0x1400028d0
movsxd rdx, dword [r8 + 0x3c]
add rdx, r8
cmp dword [rdx], 0x4550
je 0x1400028d8
ret
cmp word [rdx + 0x18], 0x20b
jne 0x1400028d0
movzx eax, word [rdx + 0x14]
movzx r8d, word [rdx + 6]
lea rax, [rdx + rax + 0x18]
test r8w, r8w
je 0x140002920
lea edx, [r8 - 1]
lea rdx, [rdx + rdx*4]
lea rdx, [rax + rdx*8 + 0x28]
nop dword [rax]
test byte [rax + 0x27], 0x20
je 0x140002917
test rcx, rcx
je 0x1400028d0
sub rcx, 1
add rax, 0x28
cmp rax, rdx
jne 0x140002908
xor eax, eax
ret
Function at 0x140002930
Capabilities:
Parse pe header

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

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

Disassembly:
mov rdx, qword [0x14009a780]
xor eax, eax
cmp word [rdx], 0x5a4d
jne 0x140002990
movsxd r8, dword [rdx + 0x3c]
add r8, rdx
cmp dword [r8], 0x4550
je 0x140002998
ret
cmp word [r8 + 0x18], 0x20b
jne 0x140002990
sub rcx, rdx
movzx r9d, word [r8 + 6]
movzx edx, word [r8 + 0x14]
lea rdx, [r8 + rdx + 0x18]
test r9w, r9w
je 0x140002990
lea eax, [r9 - 1]
lea rax, [rax + rax*4]
lea r9, [rdx + rax*8 + 0x28]
nop word cs:[rax + rax]
mov r8d, dword [rdx + 0xc]
mov rax, r8
cmp rcx, r8
jb 0x1400029e4
add eax, dword [rdx + 8]
cmp rcx, rax
jb 0x1400029f0
add rdx, 0x28
cmp r9, rdx
jne 0x1400029d0
xor eax, eax
ret
mov eax, dword [rdx + 0x24]
not eax
shr eax, 0x1f
ret

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

Disassembly:
mov r11, qword [0x14009a780]
xor r9d, r9d
cmp word [r11], 0x5a4d
jne 0x140002a22
movsxd r8, dword [r11 + 0x3c]
add r8, r11
cmp dword [r8], 0x4550
je 0x140002a30
mov rax, r9
ret
cmp word [r8 + 0x18], 0x20b
jne 0x140002a22
mov eax, dword [r8 + 0x90]
test eax, eax
je 0x140002a22
movzx edx, word [r8 + 0x14]
movzx r10d, word [r8 + 6]
lea rdx, [r8 + rdx + 0x18]
test r10w, r10w
je 0x140002a22
lea r8d, [r10 - 1]
lea r8, [r8 + r8*4]
lea r10, [rdx + r8*8 + 0x28]
nop word cs:[rax + rax]
mov r9d, dword [rdx + 0xc]
mov r8, r9
cmp rax, r9
jb 0x140002a85
add r8d, dword [rdx + 8]
cmp rax, r8
jb 0x140002a98
add rdx, 0x28
cmp rdx, r10
jne 0x140002a70
xor r9d, r9d
mov rax, r9
ret
add rax, r11
jmp 0x140002aa7
sub ecx, 1
add rax, 0x14
mov r8d, dword [rax + 4]
test r8d, r8d
jne 0x140002ab7
mov edx, dword [rax + 0xc]
test edx, edx
je 0x140002a8e
test ecx, ecx
jg 0x140002aa0
mov r9d, dword [rax + 0xc]
add r9, r11
mov rax, r9
ret