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

Disassembly:
mov rax, rsp
mov qword [rax + 8], rbx
mov qword [rax + 0x10], rbp
mov qword [rax + 0x18], rsi
mov qword [rax + 0x20], rdi
push r14
sub rsp, 0x20
mov rbx, rcx
test rcx, rcx
jne 0x1400775ae
call fcn.1400671a0
mov dword [rax], 0x16
call fcn.140065748
jmp 0x1400776f9
mov eax, dword [rcx + 0x14]
shr eax, 0xd
test al, 1
je 0x1400776f9
mov eax, dword [rcx + 0x14]
shr eax, 0xc
test al, 1
jne 0x1400776f9
mov eax, dword [rcx + 0x14]
shr eax, 1
test al, 1
je 0x1400775dd
lock or dword [rcx + 0x14], 0x10
jmp 0x1400776f9
lock or dword [rcx + 0x14], 1
mov eax, dword [rcx + 0x14]
test eax, 0x4c0
jne 0x1400775f1
call fcn.140077d70
mov esi, dword [rbx + 0x10]
cmp esi, 1
jne 0x140077601
mov rax, qword [rbx]
mov bpl, byte [rax]
jmp 0x140077604
xor bpl, bpl
mov rdi, qword [rbx + 8]
mov rcx, rbx
mov qword [rbx], rdi
call fcn.140069824
mov r8d, dword [rbx + 0x20]
mov ecx, eax
mov rdx, rdi
call fcn.140078344
mov dword [rbx + 0x10], eax
lea ecx, [rax + 1]
cmp ecx, 2
jbe 0x1400776e7
mov eax, dword [rbx + 0x14]
test al, 6
jne 0x140077695
mov rcx, rbx
call fcn.140069824
cmp eax, 0xffffffff
je 0x140077680
mov rcx, rbx
call fcn.140069824
cmp eax, 0xfffffffe
je 0x140077680
mov rcx, rbx
call fcn.140069824
movsxd rdi, eax
lea r14, [0x1400b97f0]
mov rcx, rbx
sar rdi, 6
call fcn.140069824
and eax, 0x3f
lea rcx, [rax + rax*8]
mov rax, qword [r14 + rdi*8]
lea rdx, [rax + rcx*8]
jmp 0x140077687
lea rdx, [0x1400b35a0]
mov al, byte [rdx + 0x38]
and al, 0x82
cmp al, 0x82
jne 0x140077695
lock or dword [rbx + 0x14], 0x20
cmp dword [rbx + 0x20], 0x200
jne 0x1400776b9
mov eax, dword [rbx + 0x14]
shr eax, 6
test al, 1
je 0x1400776b9
mov eax, dword [rbx + 0x14]
shr eax, 8
test al, 1
jne 0x1400776b9
mov dword [rbx + 0x20], 0x1000
mov rax, qword [rbx]
cmp esi, 1
jne 0x1400776d7
movzx ecx, byte [rax]
dec dword [rbx + 0x10]
shl cx, 8
movzx eax, bpl
or cx, ax
inc qword [rbx]
jmp 0x1400776e2
movzx ecx, word [rax]
add dword [rbx + 0x10], 0xfffffffe
add qword [rbx], 2
movzx eax, cx
jmp 0x1400776fe
neg eax
sbb eax, eax
and eax, 8
add eax, 8
lock or dword [rbx + 0x14], eax
and dword [rbx + 0x10], 0
mov eax, 0xffff
mov rbx, qword [rsp + 0x30]
mov rbp, qword [rsp + 0x38]
mov rsi, qword [rsp + 0x40]
mov rdi, qword [rsp + 0x48]
add rsp, 0x20
pop r14
ret
jmp 0x140077578

Function at 0x140078a54
Capabilities:
Delete file

Disassembly:
sub rsp, 0x28
call qword [sym.imp.KERNEL32.dll_DeleteFileW]
test eax, eax
jne 0x140078a74
call qword [sym.imp.KERNEL32.dll_GetLastError]
mov ecx, eax
call fcn.140067130
or eax, 0xffffffff
jmp 0x140078a76
xor eax, eax
add rsp, 0x28
ret
Function at 0x140084c00
Capabilities:
Parse pe header

Disassembly:
mov eax, 0x5a4d
cmp word [rcx], ax
jne 0x140084c28
movsxd rdx, dword [rcx + 0x3c]
add rdx, rcx
cmp dword [rdx], 0x4550
jne 0x140084c28
xor eax, eax
mov ecx, 0x20b
cmp word [rdx + 0x18], cx
sete al
ret
xor eax, eax
ret
Function at 0x1400111ef
Capabilities:
Terminate process

Disassembly:
jmp 0x14002ae00
mov qword [rsp + 8], rcx
sub rsp, 0x28
xor ecx, ecx
call qword [sym.imp.KERNEL32.dll_SetUnhandledExceptionFilter]
mov rcx, qword [rsp + 0x30]
call qword [sym.imp.KERNEL32.dll_UnhandledExceptionFilter]
call qword [sym.imp.KERNEL32.dll_GetCurrentProcess]
mov edx, 0xc0000409
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_TerminateProcess]
add rsp, 0x28
ret

Function at 0x14001126c
Capabilities:
Allocate or change rwx memory

Disassembly:
jmp 0x140029600
push rbp
push rsi
push rdi
mov eax, 0x2980
call fcn.1400110b4
sub rsp, rax
lea rbp, [rsp + 0x20]
lea rdi, [rsp + 0x20]
mov ecx, 0x8d8
mov eax, 0xcccccccc
rep stosd dword [rdi], eax
mov rax, qword [0x14001ca50]
xor rax, rbp
mov qword [rbp + 0x2950], rax
lea rcx, [0x1400370f3]
call fcn.140011375
lea rax, [rbp + 4]
lea rcx, [0x14001dd4c]
mov rdi, rax
mov rsi, rcx
mov ecx, 7
rep movsb byte [rdi], byte [rsi]
lea rax, [rbp + 0x1f90]
lea rcx, [0x14001dd60]
mov rdi, rax
mov rsi, rcx
mov ecx, 0x1ff
rep movsb byte [rdi], byte [rsi]
lea rax, [rbp + 0x1f90]
mov qword [rbp + 0x21a8], rax
lea rcx, [rbp + 0x1f90]
call fcn.140011172
mov dword [rbp + 0x21c4], eax
mov dword [rbp + 0x21e4], 0
jmp 0x1400296b1
mov eax, dword [rbp + 0x21e4]
inc eax
mov dword [rbp + 0x21e4], eax
mov eax, dword [rbp + 0x21c4]
cmp dword [rbp + 0x21e4], eax
jge 0x140029707
movsxd rax, dword [rbp + 0x21e4]
mov qword [rbp + 0x2948], rax
mov eax, dword [rbp + 0x21e4]
cdq
mov ecx, 6
idiv ecx
mov eax, edx
cdqe
movzx eax, byte [rbp + rax + 4]
mov rcx, qword [rbp + 0x2948]
movzx ecx, byte [rbp + rcx + 0x1f90]
xor ecx, eax
mov eax, ecx
movsxd rcx, dword [rbp + 0x21e4]
mov byte [rbp + rcx + 0x1f90], al
jmp 0x1400296a3
mov r9d, 0x40
mov r8d, 0x3000
mov edx, 0x1f40
xor ecx, ecx
call qword [sym.imp.KERNEL32.dll_VirtualAlloc]
mov qword [rbp + 0x2208], rax
lea rdx, [rbp + 0x2208]
lea rcx, [rbp + 0x2898]
call fcn.140029200
mov rdx, qword [rax]
lea rcx, [rbp + 0x2228]
call fcn.1400290a0
nop
lea r8, [rbp + 0x30]
lea rdx, [rbp + 0x2208]
lea rcx, [rbp + 0x28b8]
call fcn.140029120
lea rcx, [rbp + 0x2930]
mov rdi, rcx
mov rsi, rax
mov ecx, 0x10
rep movsb byte [rdi], byte [rsi]
lea rdx, [rbp + 0x2930]
lea rcx, [rbp + 0x2248]
call fcn.140028f80
nop
lea rdx, [rbp + 0x2208]
lea rcx, [rbp + 0x28e8]
call fcn.1400291a0
mov rdx, qword [rax]
lea rcx, [rbp + 0x2278]
call fcn.140029020
mov dword [rbp + 0x2904], 0
lea rcx, [rbp + 0x2278]
call fcn.1400293d0
nop
lea rcx, [rbp + 0x2248]
call fcn.140029380
nop
lea rcx, [rbp + 0x2228]
call fcn.140029420
mov eax, dword [rbp + 0x2904]
mov edi, eax
lea rcx, [rbp - 0x20]
lea rdx, [0x14001dcd0]
call fcn.140011307
mov eax, edi
mov rcx, qword [rbp + 0x2950]
xor rcx, rbp
call fcn.1400111ae
lea rsp, [rbp + 0x2960]
pop rdi
pop rsi
pop rbp
ret
Function at 0x140011276
Capabilities:
Parse pe header

Disassembly:
jmp 0x14002c150
sub rsp, 0x38
xor ecx, ecx
call qword [sym.imp.KERNEL32.dll_GetModuleHandleW]
mov qword [rsp + 0x20], rax
cmp qword [rsp + 0x20], 0
jne 0x14002c170
xor al, al
jmp 0x14002c1f1
mov rax, qword [rsp + 0x20]
movzx eax, word [rax]
cmp eax, 0x5a4d
je 0x14002c183
xor al, al
jmp 0x14002c1f1
mov rax, qword [rsp + 0x20]
movsxd rax, dword [rax + 0x3c]
mov rcx, qword [rsp + 0x20]
add rcx, rax
mov rax, rcx
mov qword [rsp + 0x28], rax
mov rax, qword [rsp + 0x28]
cmp dword [rax], 0x4550
je 0x14002c1ad
xor al, al
jmp 0x14002c1f1
mov rax, qword [rsp + 0x28]
movzx eax, word [rax + 0x18]
cmp eax, 0x20b
je 0x14002c1c1
xor al, al
jmp 0x14002c1f1
mov rax, qword [rsp + 0x28]
cmp dword [rax + 0x84], 0xe
ja 0x14002c1d3
xor al, al
jmp 0x14002c1f1
mov eax, 8
imul rax, rax, 0xe
mov rcx, qword [rsp + 0x28]
cmp dword [rcx + rax + 0x88], 0
jne 0x14002c1ef
xor al, al
jmp 0x14002c1f1
mov al, 1
add rsp, 0x38
ret
Function at 0x140007f60
Capabilities:
Query environment variable

Disassembly:
mov qword [rsp + 0x18], rbx
mov qword [rsp + 0x20], rbp
push rsi
push rdi
push r12
push r14
push r15
sub rsp, 0x50
mov rax, qword [0x140024020]
xor rax, rsp
mov qword [rsp + 0x40], rax
mov rsi, rdx
mov r14, rcx
lea r15, [rdx + 0x10]
xor r12d, r12d
mov qword [r15], r12
mov rax, rdx
cmp qword [rdx + 0x18], 8
jb 0x140007fa2
mov rax, qword [rdx]
mov word [rax], r12w
xorps xmm0, xmm0
movups xmmword [rsp + 0x20], xmm0
mov qword [rsp + 0x38], 7
mov qword [rsp + 0x30], r12
mov word [rsp + 0x20], r12w
xor r8d, r8d
xor edx, edx
call qword [sym.imp.KERNEL32.dll_GetEnvironmentVariableW]
mov edi, eax
test eax, eax
jne 0x140008007
call qword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 0xcb
je 0x140008125
test eax, eax
jle 0x140007ff0
movzx eax, ax
or eax, 0x80070000
mov r8d, eax
mov rdx, r14
lea rcx, str.Failed_to_read_environment_variable___s___HRESULT:_0x_X
call fcn.140007480
jmp 0x140008125
mov eax, 2
mul rdi
mov rbx, 0xffffffffffffffff
cmovo rax, rbx
mov rcx, rax
call fcn.14001408c
mov rbp, rax
mov r8d, edi
mov rdx, rax
mov rcx, r14
call qword [sym.imp.KERNEL32.dll_GetEnvironmentVariableW]
test eax, eax
je 0x140007fd3
nop dword [rax + rax]
inc rbx
cmp word [rbp + rbx*2], 0
jne 0x140008040
mov rax, qword [rsp + 0x38]
cmp rbx, rax
ja 0x140008081
lea rdi, [rsp + 0x20]
cmp rax, 8
cmovae rdi, qword [rsp + 0x20]
mov qword [rsp + 0x30], rbx
add rbx, rbx
mov r8, rbx
mov rdx, rbp
mov rcx, rdi
call fcn.140015680
mov word [rbx + rdi], r12w
jmp 0x140008091
mov r9, rbp
mov rdx, rbx
lea rcx, [rsp + 0x20]
call fcn.140005e20
mov rcx, rbp
call fcn.140013dc0
xor edx, edx
lea rcx, [rsp + 0x20]
call fcn.14000f7f0
test al, al
je 0x140008105
lea rax, [rsp + 0x20]
cmp rsi, rax
je 0x140008101
lea r9, [rsp + 0x20]
cmp qword [rsp + 0x38], 8
cmovae r9, qword [rsp + 0x20]
mov rbx, qword [rsp + 0x30]
mov rax, qword [rsi + 0x18]
cmp rbx, rax
ja 0x1400080f6
cmp rax, 8
jb 0x1400080db
mov rsi, qword [rsi]
mov qword [r15], rbx
lea r8, [rbx + rbx]
mov rdx, r9
mov rcx, rsi
call fcn.140015680
mov word [rsi + rbx*2], r12w
mov bl, 1
jmp 0x140008127
mov rdx, rbx
mov rcx, rsi
call fcn.140005e20
mov bl, 1
jmp 0x140008127
lea r8, [rsp + 0x20]
cmp qword [rsp + 0x38], 8
cmovae r8, qword [rsp + 0x20]
mov rdx, r14
lea rcx, str.Did_not_find___s__directory___s_
call fcn.1400070f0
xor bl, bl
mov rdx, qword [rsp + 0x38]
cmp rdx, 8
jb 0x14000816c
lea rdx, [rdx*2 + 2]
mov rcx, qword [rsp + 0x20]
mov rax, rcx
cmp rdx, 0x1000
jb 0x140008167
add rdx, 0x27
mov rcx, qword [rcx - 8]
sub rax, rcx
add rax, 0xfffffffffffffff8
cmp rax, 0x1f
jbe 0x140008167
call qword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll__invalid_parameter_noinfo_noreturn]
int3
call fcn.140013dc0
movzx eax, bl
mov rcx, qword [rsp + 0x40]
xor rcx, rsp
call fcn.140013da0
lea r11, [rsp + 0x50]
mov rbx, qword [r11 + 0x40]
mov rbp, qword [r11 + 0x48]
mov rsp, r11
pop r15
pop r14
pop r12
pop rdi
pop rsi
ret
Function at 0x14000f0b0
Capabilities:
Query environment variable

Disassembly:
mov qword [rsp + 0x10], rbx
mov qword [rsp + 0x18], rbp
push rsi
push rdi
push r14
sub rsp, 0x50
mov rax, qword [0x140024020]
xor rax, rsp
mov qword [rsp + 0x40], rax
mov r14, rcx
xorps xmm0, xmm0
movups xmmword [rsp + 0x20], xmm0
xor ebp, ebp
mov qword [rsp + 0x30], rbp
mov qword [rsp + 0x38], 7
mov word [rsp + 0x20], bp
movzx eax, byte [str.d38cc827_e34f_4453_9df4_1e796e9f1d07]
cmp al, 0x65
jne 0x14000f151
mov qword [rsp + 0x30], rbp
mov word [rsp + 0x20], bp
xor r8d, r8d
xor edx, edx
lea rcx, str._DOTNET_TEST_GLOBALLY_REGISTERED_PATH
call qword [sym.imp.KERNEL32.dll_GetEnvironmentVariableW]
mov edi, eax
test eax, eax
jne 0x14000f1ad
call qword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 0xcb
je 0x14000f151
test eax, eax
jle 0x14000f13b
movzx eax, ax
or eax, 0x80070000
mov r8d, eax
lea rdx, str._DOTNET_TEST_GLOBALLY_REGISTERED_PATH
lea rcx, str.Failed_to_read_environment_variable___s___HRESULT:_0x_X
call fcn.140007480
mov rdx, r14
mov ecx, 7
call fcn.14000f2d0
movzx ebx, al
mov rdx, qword [rsp + 0x38]
cmp rdx, 8
jb 0x14000f2a7
lea rdx, [rdx*2 + 2]
mov rcx, qword [rsp + 0x20]
mov rax, rcx
cmp rdx, 0x1000
jb 0x14000f2a2
add rdx, 0x27
mov rcx, qword [rcx - 8]
sub rax, rcx
add rax, 0xfffffffffffffff8
cmp rax, 0x1f
jbe 0x14000f2a2
call qword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll__invalid_parameter_noinfo_noreturn]
nop
mov eax, 2
mul rdi
mov rbx, 0xffffffffffffffff
cmovo rax, rbx
mov rcx, rax
call fcn.14001408c
mov rsi, rax
mov r8d, edi
mov rdx, rax
lea rcx, str._DOTNET_TEST_GLOBALLY_REGISTERED_PATH
call qword [sym.imp.KERNEL32.dll_GetEnvironmentVariableW]
test eax, eax
je 0x14000f122
inc rbx
cmp word [rsi + rbx*2], 0
jne 0x14000f1e6
mov rax, qword [rsp + 0x38]
cmp rbx, rax
ja 0x14000f225
lea rdi, [rsp + 0x20]
cmp rax, 8
cmovae rdi, qword [rsp + 0x20]
mov qword [rsp + 0x30], rbx
add rbx, rbx
mov r8, rbx
mov rdx, rsi
mov rcx, rdi
call fcn.140015680
mov word [rbx + rdi], bp
jmp 0x14000f235
mov r9, rsi
mov rdx, rbx
lea rcx, [rsp + 0x20]
call fcn.140005e20
mov rcx, rsi
call fcn.140013dc0
lea rax, [rsp + 0x20]
cmp r14, rax
je 0x14000f29b
lea r9, [rsp + 0x20]
cmp qword [rsp + 0x38], 8
cmovae r9, qword [rsp + 0x20]
mov rbx, qword [rsp + 0x30]
mov rax, qword [r14 + 0x18]
cmp rbx, rax
ja 0x14000f290
mov rdi, r14
cmp rax, 8
jb 0x14000f272
mov rdi, qword [r14]
mov qword [r14 + 0x10], rbx
lea r8, [rbx + rbx]
mov rdx, r9
mov rcx, rdi
call fcn.140015680
mov word [rdi + rbx*2], bp
mov bl, 1
jmp 0x14000f161
mov rdx, rbx
mov rcx, r14
call fcn.140005e20
mov bl, 1
jmp 0x14000f161
call fcn.140013dc0
movzx eax, bl
mov rcx, qword [rsp + 0x40]
xor rcx, rsp
call fcn.140013da0
mov rbx, qword [rsp + 0x78]
mov rbp, qword [rsp + 0x80]
add rsp, 0x50
pop r14
pop rdi
pop rsi
ret
Function at 0x140014920
Capabilities:
Parse pe header

Disassembly:
sub rsp, 0x28
xor ecx, ecx
call qword [sym.imp.KERNEL32.dll_GetModuleHandleW]
test rax, rax
je 0x14001496a
mov ecx, 0x5a4d
cmp word [rax], cx
jne 0x14001496a
movsxd rcx, dword [rax + 0x3c]
add rcx, rax
cmp dword [rcx], 0x4550
jne 0x14001496a
mov eax, 0x20b
cmp word [rcx + 0x18], ax
jne 0x14001496a
cmp dword [rcx + 0x84], 0xe
jbe 0x14001496a
cmp dword [rcx + 0xf8], 0
setne al
jmp 0x14001496c
xor al, al
add rsp, 0x28
ret
Function at 0x140002038
Capabilities:
Access peb ldr_data
Resolve function by parsing pe exports

Disassembly:
push r15
push r14
push r13
push r12
push rbp
push rdi
push rsi
push rbx
sub rsp, 0x28
cmp dword [0x14007a0c0], 0
je 0x14000205b
mov edx, 1
jmp 0x140002222
mov rax, qword gs:[0x60]
mov rax, qword [rax + 0x18]
xor ebx, ebx
mov r8, qword [rax + 0x10]
xor eax, eax
mov rdx, qword [r8 + 0x30]
test rdx, rdx
je 0x1400020be
movsxd rcx, dword [rdx + 0x3c]
mov ecx, dword [rdx + rcx + 0x88]
test ecx, ecx
je 0x1400020b6
lea rax, [rcx + rdx]
mov ecx, dword [rax + 0xc]
add rcx, rdx
mov r9d, dword [rcx]
or r9d, 0x20202020
cmp r9d, 0x6c64746e
jne 0x1400020b6
mov ecx, dword [rcx + 4]
or ecx, 0x20202020
cmp ecx, 0x6c642e6c
je 0x1400020c8
mov r8, qword [r8]
mov rbx, rdx
jmp 0x140002070
test rax, rax
jne 0x1400020cb
jmp 0x140002222
mov rbx, rdx
mov ebp, dword [rax + 0x1c]
mov edi, dword [rax + 0x24]
xor esi, esi
lea r13, [0x14007a0c8]
mov edx, dword [rax + 0x18]
mov eax, dword [rax + 0x20]
add rdi, rbx
add rbp, rbx
lea r10d, [rdx - 1]
add rax, rbx
lea r12, [rax + r10*4]
add r10, r10
add r10, rdi
mov ecx, dword [r12]
add rcx, rbx
cmp word [rcx], 0x775a
jne 0x140002133
call fcn.140001f80
mov r11d, esi
inc esi
shl r11, 4
add r11, r13
mov dword [r11], eax
movzx eax, word [r10]
mov eax, dword [rbp + rax*4]
mov dword [r11 + 4], eax
xor eax, eax
mov qword [r11 + 8], rax
cmp esi, 0x1f4
je 0x140002145
sub r12, 4
lea rax, [r10 - 2]
cmp rdi, r10
je 0x140002145
mov r10, rax
jmp 0x1400020f7
mov dword [0x14007a0c0], esi
lea ebp, [rsi - 1]
lea r10, [0x14007a0c8]
test ebp, ebp
je 0x1400021ac
lea rdx, [0x14007a0c0]
xor ecx, ecx
lea eax, [rcx + 1]
mov r8d, dword [rdx + 0xc]
mov rcx, rax
shl rax, 4
add rax, r10
mov r9d, dword [rax + 4]
cmp r9d, r8d
jae 0x1400021a0
mov edi, dword [rdx + 8]
mov r11, qword [rdx + 0x10]
mov r12d, dword [rax]
mov dword [rdx + 0xc], r9d
mov r9, qword [rax + 8]
mov dword [rdx + 8], r12d
mov qword [rdx + 0x10], r9
mov dword [rax], edi
mov dword [rax + 4], r8d
mov qword [rax + 8], r11
add rdx, 0x10
cmp ecx, ebp
jb 0x140002162
dec ebp
jmp 0x140002155
mov eax, dword [0x14007a0cc]
mov r13d, dword [0x14007a0dc]
xor edi, edi
lea r15, [0x140076a20]
sub r13d, eax
lea r12, [rbx + rax]
mov r14d, edi
cmp edi, r13d
jae 0x140002051
lea rdx, [r12 + rdi]
mov r8d, 3
mov rcx, r15
inc rdi
call sub.msvcrt.dll_memcmp
test eax, eax
jne 0x1400021c9
lea rdi, [0x14007a0c0]
test r14d, r14d
je 0x140002051
add rdi, 0x10
cmp esi, ebp
je 0x140002051
mov ecx, dword [rdi - 4]
mov r8d, r13d
mov edx, r14d
inc ebp
add rcx, rbx
call fcn.140001fa8
mov qword [rdi], rax
jmp 0x1400021fe
mov eax, edx
add rsp, 0x28
pop rbx
pop rsi
pop rdi
pop rbp
pop r12
pop r13
pop r14
pop r15
ret
Function at 0x140002e20
Capabilities:
Write file on windows

Disassembly:
push rsi
push rbx
sub rsp, 0x38
mov rbx, rcx
lea rax, [rsp + 0x58]
mov ecx, 2
mov qword [rsp + 0x58], rdx
mov qword [rsp + 0x60], r8
mov qword [rsp + 0x68], r9
mov qword [rsp + 0x28], rax
call fcn.140008aa0
mov r8d, 0x1b
mov edx, 1
lea rcx, str.Mingw_w64_runtime_failure:_n
mov r9, rax
call sub.msvcrt.dll_fwrite
mov rsi, qword [rsp + 0x28]
mov ecx, 2
call fcn.140008aa0
mov rdx, rbx
mov rcx, rax
mov r8, rsi
call sub.msvcrt.dll_vfprintf
call sub.msvcrt.dll_abort
nop
nop dword [rax]

Function at 0x140002e90
Capabilities:
Allocate or change rwx memory

Disassembly:
push rdi
push rsi
push rbx
sub rsp, 0x50
movsxd rsi, dword [0x14007c0d4]
mov rbx, rcx
test esi, esi
jle 0x140002fc0
mov rax, qword [0x14007c0d8]
xor r9d, r9d
add rax, 0x18
nop word [rax + rax]
mov r8, qword [rax]
cmp rbx, r8
jb 0x140002edb
mov rdx, qword [rax + 8]
mov edx, dword [rdx + 8]
add r8, rdx
cmp rbx, r8
jb 0x140002f65
add r9d, 1
add rax, 0x28
cmp r9d, esi
jne 0x140002ec0
mov rcx, rbx
call fcn.1400038e0
mov rdi, rax
test rax, rax
je 0x140002fe2
mov rax, qword [0x14007c0d8]
lea rbx, [rsi + rsi*4]
shl rbx, 3
add rax, rbx
mov qword [rax + 0x20], rdi
mov dword [rax], 0
call fcn.140003a20
mov edx, dword [rdi + 0xc]
mov r8d, 0x30
lea rcx, [rax + rdx]
mov rax, qword [0x14007c0d8]
lea rdx, [rsp + 0x20]
mov qword [rax + rbx + 0x18], rcx
call qword [sym.imp.KERNEL32.dll_VirtualQuery]
test rax, rax
je 0x140002fc7
mov eax, dword [rsp + 0x44]
lea edx, [rax - 0x40]
and edx, 0xffffffbf
je 0x140002f5e
lea edx, [rax - 4]
and edx, 0xfffffffb
jne 0x140002f70
add dword [0x14007c0d4], 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 [0x14007c0d8]
mov qword [rbx + 8], rcx
mov r9, rbx
mov qword [rbx + 0x10], rdx
call qword [sym.imp.KERNEL32.dll_VirtualProtect]
test eax, eax
jne 0x140002f5e
call qword [sym.imp.KERNEL32.dll_GetLastError]
lea rcx, str.__VirtualProtect_failed_with_code_0x_x
mov edx, eax
call fcn.140002e20
nop dword [rax]
xor esi, esi
jmp 0x140002ee8
mov rax, qword [0x14007c0d8]
mov edx, dword [rdi + 8]
lea rcx, str.__VirtualQuery_failed_for__d_bytes_at_address__p
mov r8, qword [rax + rbx + 0x18]
call fcn.140002e20
mov rdx, rbx
lea rcx, str.Address__p_has_no_image_section
call fcn.140002e20
nop
nop word cs:[rax + rax]
nop dword [rax]

Function at 0x140003550
Capabilities:
Get thread local storage value

Disassembly:
push r12
push rbp
push rdi
push rsi
push rbx
sub rsp, 0x20
lea r12, [0x14007c140]
mov rcx, r12
call qword [sym.imp.KERNEL32.dll_EnterCriticalSection]
mov rbx, qword [0x14007c120]
test rbx, rbx
je 0x1400035ac
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 0x1400035a3
test rsi, rsi
je 0x1400035a3
mov rax, qword [rbx + 8]
mov rcx, rsi
call rax
mov rbx, qword [rbx + 0x10]
test rbx, rbx
jne 0x140003588
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 0x1400038e0
Capabilities:
Enumerate pe sections
Parse pe header

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

Function at 0x140003960
Capabilities:
Parse pe header

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

Function at 0x140003a20
Capabilities:
Parse pe header

Disassembly:
mov rax, qword [0x140077760]
xor edx, edx
cmp word [rax], 0x5a4d
jne 0x140003a3f
movsxd rcx, dword [rax + 0x3c]
add rcx, rax
cmp dword [rcx], 0x4550
je 0x140003a48
mov rax, rdx
ret
cmp word [rcx + 0x18], 0x20b
cmove rdx, rax
mov rax, rdx
ret
Function at 0x141213058
Capabilities:
Decompress data using aplib

Disassembly:
call fcn.1412131df
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 0x141213089
mov dl, byte [rsi]
inc rsi
adc dl, dl
jae 0x14121306f
add dl, dl
jne 0x141213096
mov dl, byte [rsi]
inc rsi
adc dl, dl
jae 0x1412130f6
xor eax, eax
add dl, dl
jne 0x1412130a5
mov dl, byte [rsi]
inc rsi
adc dl, dl
jae 0x1412131ad
add dl, dl
jne 0x1412130b6
mov dl, byte [rsi]
inc rsi
adc dl, dl
adc eax, eax
add dl, dl
jne 0x1412130c3
mov dl, byte [rsi]
inc rsi
adc dl, dl
adc eax, eax
add dl, dl
jne 0x1412130d0
mov dl, byte [rsi]
inc rsi
adc dl, dl
adc eax, eax
add dl, dl
jne 0x1412130dd
mov dl, byte [rsi]
inc rsi
adc dl, dl
adc eax, eax
je 0x1412130ea
push rdi
mov eax, eax
sub rdi, rax
mov al, byte [rdi]
pop rdi
mov byte [rdi], al
inc rdi
mov ebx, 2
jmp 0x14121307e
mov eax, 1
add dl, dl
jne 0x141213106
mov dl, byte [rsi]
inc rsi
adc dl, dl
adc eax, eax
add dl, dl
jne 0x141213113
mov dl, byte [rsi]
inc rsi
adc dl, dl
jb 0x1412130fb
sub eax, ebx
mov ebx, 1
jne 0x14121314c
mov ecx, 1
add dl, dl
jne 0x14121312e
mov dl, byte [rsi]
inc rsi
adc dl, dl
adc ecx, ecx
add dl, dl
jne 0x14121313b
mov dl, byte [rsi]
inc rsi
adc dl, dl
jb 0x141213123
push rsi
mov rsi, rdi
sub rsi, rbp
rep movsb byte [rdi], byte [rsi]
pop rsi
jmp 0x14121307e
dec eax
shl eax, 8
mov al, byte [rsi]
inc rsi
mov ebp, eax
mov ecx, 1
add dl, dl
jne 0x141213168
mov dl, byte [rsi]
inc rsi
adc dl, dl
adc ecx, ecx
add dl, dl
jne 0x141213175
mov dl, byte [rsi]
inc rsi
adc dl, dl
jb 0x14121315d
cmp eax, 0x7d00
jae 0x14121319b
cmp eax, 0x500
jb 0x141213196
inc ecx
push rsi
mov rsi, rdi
sub rsi, rax
rep movsb byte [rdi], byte [rsi]
pop rsi
jmp 0x14121307e
cmp eax, 0x7f
ja 0x14121319e
add ecx, 2
push rsi
mov rsi, rdi
sub rsi, rax
rep movsb byte [rdi], byte [rsi]
pop rsi
jmp 0x14121307e
mov al, byte [rsi]
inc rsi
xor ecx, ecx
shr al, 1
je 0x1412131d2
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 0x14121307e
pop r10
sub rdi, qword [r10 + 0x20]
mov eax, edi
pop r10
ret 0x20
Function at 0x10003d398
Capabilities:
Query or enumerate registry value

Disassembly:
mov qword [rsp + 8], rbx
push rsi
push rdi
push r12
sub rsp, 0x40
mov rsi, rcx
mov rcx, qword [0x1000dedd8]
lea r12, [0x1000dedd8]
cmp rcx, r12
je 0x10003d3dc
test byte [rcx + 0x1c], 1
je 0x10003d3dc
cmp byte [rcx + 0x19], 5
jb 0x10003d3dc
mov rcx, qword [rcx + 0x10]
lea r8, [0x100008e80]
mov edx, 0x262
call fcn.100020584
lea rax, [rsp + 0x30]
lea rdx, [0x10000b5e0]
xor ebx, ebx
and qword [rsp + 0x30], rbx
mov r9d, 0x20019
xor r8d, r8d
mov rcx, 0xffffffff80000001
mov qword [rsp + 0x20], rax
xor edi, edi
call qword [sym.imp.ADVAPI32.dll_RegOpenKeyExW]
test eax, eax
jne 0x10003d415
mov rbx, qword [rsp + 0x30]
cdqe
test rax, rax
je 0x10003d42c
movzx edi, ax
or edi, 0x80070000
test eax, eax
cmovle edi, eax
jmp 0x10003d480
and dword [rsp + 0x68], edi
lea rax, [rsp + 0x70]
lea r9, [rsp + 0x78]
mov qword [rsp + 0x28], rax
lea rax, [rsp + 0x68]
lea rdx, [0x10000b8e0]
xor r8d, r8d
mov rcx, rbx
mov dword [rsp + 0x70], 4
mov qword [rsp + 0x20], rax
call qword [sym.imp.ADVAPI32.dll_RegQueryValueExW]
test eax, eax
jne 0x10003d480
cmp dword [rsp + 0x78], 4
jne 0x10003d480
test eax, eax
jne 0x10003d480
cmp dword [rsp + 0x68], edi
setne al
mov byte [rsi + 0x354], al
test rbx, rbx
je 0x10003d48e
mov rcx, rbx
call qword [sym.imp.ADVAPI32.dll_RegCloseKey]
mov rcx, qword [0x1000dedd8]
cmp rcx, r12
je 0x10003d4be
test byte [rcx + 0x1c], 1
je 0x10003d4be
cmp byte [rcx + 0x19], 5
jb 0x10003d4be
mov rcx, qword [rcx + 0x10]
lea r8, [0x100008e80]
mov edx, 0x263
mov r9d, edi
call fcn.100020d8c
mov eax, edi
mov rbx, qword [rsp + 0x60]
add rsp, 0x40
pop r12
pop rdi
pop rsi
ret