joyce8/EMBER2024-capa huggingface dataset:
Function at 0x14001193d
Capabilities:
Parse pe header

Disassembly:
jmp 0x14002a950
sub rsp, 0x38
xor ecx, ecx
call qword [sym.imp.KERNEL32.dll_GetModuleHandleW]
mov qword [rsp + 0x20], rax
cmp qword [rsp + 0x20], 0
jne 0x14002a970
xor al, al
jmp 0x14002a9f1
mov rax, qword [rsp + 0x20]
movzx eax, word [rax]
cmp eax, 0x5a4d
je 0x14002a983
xor al, al
jmp 0x14002a9f1
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 0x14002a9ad
xor al, al
jmp 0x14002a9f1
mov rax, qword [rsp + 0x28]
movzx eax, word [rax + 0x18]
cmp eax, 0x20b
je 0x14002a9c1
xor al, al
jmp 0x14002a9f1
mov rax, qword [rsp + 0x28]
cmp dword [rax + 0x84], 0xe
ja 0x14002a9d3
xor al, al
jmp 0x14002a9f1
mov eax, 8
imul rax, rax, 0xe
mov rcx, qword [rsp + 0x28]
cmp dword [rcx + rax + 0x88], 0
jne 0x14002a9ef
xor al, al
jmp 0x14002a9f1
mov al, 1
add rsp, 0x38
ret
Function at 0x140011c76
Capabilities:
Check if file exists
Get file attributes

Disassembly:
jmp 0x140022b10
mov qword [rsp + 8], rcx
push rbp
push rdi
sub rsp, 0x108
lea rbp, [rsp + 0x20]
lea rcx, [0x14004710a]
call fcn.140011d4d
nop
mov rcx, qword [rbp + 0x100]
call fcn.140011140
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_GetFileAttributesA]
mov dword [rbp + 4], eax
cmp dword [rbp + 4], 0xffffffff
je 0x140022b64
mov eax, dword [rbp + 4]
and eax, 0x10
test eax, eax
je 0x140022b64
mov dword [rbp + 0xd4], 1
jmp 0x140022b6e
mov dword [rbp + 0xd4], 0
movzx eax, byte [rbp + 0xd4]
lea rsp, [rbp + 0xe8]
pop rdi
pop rbp
ret

Function at 0x140011d1b
Capabilities:
Write file on windows

Disassembly:
jmp 0x14001f4a0
mov qword [rsp + 8], rcx
push rbp
push rdi
sub rsp, 0x1a8
lea rbp, [rsp + 0x30]
lea rdi, [rsp + 0x30]
mov ecx, 0x2e
mov eax, 0xcccccccc
rep stosd dword [rdi], eax
mov rcx, qword [rsp + 0x1c8]
mov rax, qword [0x14003d040]
xor rax, rbp
mov qword [rbp + 0x168], rax
lea rcx, [0x140047068]
call fcn.140011d4d
nop
mov rax, qword [rbp + 0x190]
cmp qword [rax + 0x68], 0
je 0x14001f507
mov rax, qword [rbp + 0x190]
movzx eax, byte [rax + 0x71]
test eax, eax
jne 0x14001f50e
mov al, 1
jmp 0x14001f65e
call fcn.14001138e
mov rcx, qword [rbp + 0x190]
mov rcx, qword [rcx]
mov qword [rbp + 0x158], rcx
mov edx, eax
mov rcx, qword [rbp + 0x190]
mov rax, qword [rbp + 0x158]
call qword [rax + 0x18]
mov dword [rbp + 0x160], eax
call fcn.14001138e
mov ecx, dword [rbp + 0x160]
mov edx, ecx
mov ecx, eax
call fcn.140011a8c
movzx eax, al
test eax, eax
je 0x14001f55f
xor al, al
jmp 0x14001f65e
mov qword [rbp + 8], 0x20
lea rax, [rbp + 0x48]
mov rcx, qword [rbp + 0x190]
add rcx, 0x74
lea rdx, [rbp + 0x68]
mov qword [rsp + 0x20], rdx
mov r9, rax
lea r8, [rbp + 0x28]
mov rdx, rcx
mov rax, qword [rbp + 0x190]
mov rcx, qword [rax + 0x68]
call qword [sym.imp.MSVCP140D.dll_public:_int___cdecl_std::codecvt_char__char__struct__Mbstatet_::unshift_struct__Mbstatet____ptr64__char____ptr64__char____ptr64__char____ptr64____ptr64_const___ptr64]
mov dword [rbp + 0x154], eax
cmp dword [rbp + 0x154], 0
je 0x14001f5c4
cmp dword [rbp + 0x154], 1
je 0x14001f5cf
cmp dword [rbp + 0x154], 3
je 0x14001f64d
jmp 0x14001f65c
mov rax, qword [rbp + 0x190]
mov byte [rax + 0x71], 0
lea rax, [rbp + 0x28]
mov rcx, qword [rbp + 0x68]
sub rcx, rax
mov rax, rcx
mov qword [rbp + 0x88], rax
cmp qword [rbp + 0x88], 0
jbe 0x14001f61f
mov rax, qword [rbp + 0x190]
mov r9, qword [rax + 0x80]
mov r8, qword [rbp + 0x88]
mov edx, 1
lea rcx, [rbp + 0x28]
call qword [sym.imp.ucrtbased.dll_fwrite]
cmp qword [rbp + 0x88], rax
je 0x14001f61f
xor al, al
jmp 0x14001f65e
mov rax, qword [rbp + 0x190]
movzx eax, byte [rax + 0x71]
test eax, eax
jne 0x14001f63a
mov dword [rbp + 0x154], 1
jmp 0x14001f644
mov dword [rbp + 0x154], 0
movzx eax, byte [rbp + 0x154]
jmp 0x14001f65e
mov rax, qword [rbp + 0x190]
mov byte [rax + 0x71], 0
mov al, 1
jmp 0x14001f65e
xor al, al
mov rdi, rax
lea rcx, [rbp - 0x30]
lea rdx, [0x140033d90]
call fcn.140011aff
mov rax, rdi
mov rcx, qword [rbp + 0x168]
xor rcx, rbp
call fcn.140011640
lea rsp, [rbp + 0x178]
pop rdi
pop rbp
ret
Function at 0x140028200
Capabilities:
Terminate process

Disassembly:
sub rsp, 0x68
mov ecx, 1
call fcn.140011dca
movzx eax, al
test eax, eax
jne 0x140028220
mov ecx, 7
call fcn.140011b13
nop
mov byte [rsp + 0x20], 0
call fcn.140011b5e
mov byte [rsp + 0x21], al
cmp dword [0x14003da30], 1
jne 0x140028244
mov ecx, 7
call fcn.140011b13
nop
jmp 0x14002829c
cmp dword [0x14003da30], 0
jne 0x140028297
mov dword [0x14003da30], 1
lea rdx, [0x140032770]
lea rcx, [0x140032440]
call fcn.140011609
test eax, eax
je 0x140028278
mov eax, 0xff
jmp 0x1400283a1
lea rdx, [0x140032330]
lea rcx, [section..rdata]
call fcn.140011b45
mov dword [0x14003da30], 2
jmp 0x14002829c
mov byte [rsp + 0x20], 1
movzx ecx, byte [rsp + 0x21]
call fcn.140011aeb
call fcn.14001197e
mov qword [rsp + 0x30], rax
mov rax, qword [rsp + 0x30]
cmp qword [rax], 0
je 0x1400282f9
mov rcx, qword [rsp + 0x30]
call fcn.1400114fb
movzx eax, al
test eax, eax
je 0x1400282f9
mov rax, qword [rsp + 0x30]
mov rax, qword [rax]
mov qword [rsp + 0x48], rax
mov rax, qword [rsp + 0x48]
mov qword [rsp + 0x50], rax
xor r8d, r8d
mov edx, 2
xor ecx, ecx
mov rax, qword [rsp + 0x50]
call qword [0x140048020]
nop
call fcn.140011a1e
mov qword [rsp + 0x38], rax
mov rax, qword [rsp + 0x38]
cmp qword [rax], 0
je 0x14002832d
mov rcx, qword [rsp + 0x38]
call fcn.1400114fb
movzx eax, al
test eax, eax
je 0x14002832d
mov rax, qword [rsp + 0x38]
mov rcx, qword [rax]
call fcn.140011cdf
nop
call fcn.140028450
mov dword [rsp + 0x28], eax
call fcn.14001193d
movzx eax, al
test eax, eax
jne 0x14002834c
mov ecx, dword [rsp + 0x28]
call fcn.1400110fa
nop
movzx eax, byte [rsp + 0x20]
test eax, eax
jne 0x14002835b
call fcn.140011d02
nop
xor edx, edx
mov cl, 1
call fcn.140011497
mov eax, dword [rsp + 0x28]
jmp 0x1400283a1
add rsp, 0x68
ret
Function at 0x140001010
Capabilities:
Parse pe header

Disassembly:
sub rsp, 0x28
mov rax, qword [0x140014d00]
xor ecx, ecx
mov dword [rax], 1
mov rax, qword [0x140014d10]
mov dword [rax], 1
mov rax, qword [0x140014d20]
mov dword [rax], 1
mov rax, qword [0x140014ca0]
cmp word [rax], 0x5a4d
jne 0x14000105a
movsxd rdx, dword [rax + 0x3c]
add rax, rdx
cmp dword [rax], 0x4550
je 0x1400010c0
mov rax, qword [0x140014cf0]
mov dword [0x140018020], ecx
mov eax, dword [rax]
test eax, eax
je 0x1400010b0
mov ecx, 2
call sym.__set_app_type
call sym.__p__fmode
mov rdx, qword [0x140014de0]
mov edx, dword [rdx]
mov dword [rax], edx
call sym.__p__commode
mov rdx, qword [0x140014dc0]
mov edx, dword [rdx]
mov dword [rax], edx
call sym._setargv
mov rax, qword [0x140014c30]
cmp dword [rax], 1
je 0x1400010f8
xor eax, eax
add rsp, 0x28
ret
mov ecx, 1
call sym.__set_app_type
jmp 0x140001077
movzx edx, word [rax + 0x18]
cmp dx, 0x10b
je 0x140001110
cmp dx, 0x20b
jne 0x14000105a
cmp dword [rax + 0x84], 0xe
jbe 0x14000105a
mov edx, dword [rax + 0xf8]
xor ecx, ecx
test edx, edx
setne cl
jmp 0x14000105a
mov rcx, qword [sym._matherr]
call sym.__mingw_setusermatherr
xor eax, eax
add rsp, 0x28
ret
cmp dword [rax + 0x74], 0xe
jbe 0x14000105a
mov r8d, dword [rax + 0xe8]
xor ecx, ecx
test r8d, r8d
setne cl
jmp 0x14000105a

Function at 0x140001c30
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 sym.__acrt_iob_func
mov r8d, 0x1b
mov edx, 1
lea rcx, str.Mingw_w64_runtime_failure:_n
mov r9, rax
call sym.fwrite
mov rsi, qword [rsp + 0x28]
mov ecx, 2
call sym.__acrt_iob_func
mov rdx, rbx
mov rcx, rax
mov r8, rsi
call sym.vfprintf
call sym.abort
nop
nop dword [rax]
Function at 0x140001ca0
Capabilities:
Allocate or change rwx memory

Disassembly:
push rdi
push rsi
push rbx
sub rsp, 0x50
movsxd rsi, dword [0x1400180b4]
mov rbx, rcx
test esi, esi
jle 0x140001dd0
mov rax, qword [0x1400180b8]
xor r9d, r9d
add rax, 0x18
nop word [rax + rax]
mov r8, qword [rax]
cmp rbx, r8
jb 0x140001ceb
mov rdx, qword [rax + 8]
mov edx, dword [rdx + 8]
add r8, rdx
cmp rbx, r8
jb 0x140001d75
add r9d, 1
add rax, 0x28
cmp r9d, esi
jne 0x140001cd0
mov rcx, rbx
call sym.__mingw_GetSectionForAddress
mov rdi, rax
test rax, rax
je 0x140001df2
mov rax, qword [0x1400180b8]
lea rbx, [rsi + rsi*4]
shl rbx, 3
add rax, rbx
mov qword [rax + 0x20], rdi
mov dword [rax], 0
call sym._GetPEImageBase
mov edx, dword [rdi + 0xc]
mov r8d, 0x30
lea rcx, [rax + rdx]
mov rax, qword [0x1400180b8]
lea rdx, [rsp + 0x20]
mov qword [rax + rbx + 0x18], rcx
call qword [sym.imp.KERNEL32.dll_VirtualQuery]
test rax, rax
je 0x140001dd7
mov eax, dword [rsp + 0x44]
lea edx, [rax - 4]
and edx, 0xfffffffb
je 0x140001d6e
lea edx, [rax - 0x40]
and edx, 0xffffffbf
jne 0x140001d80
add dword [0x1400180b4], 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 [0x1400180b8]
mov qword [rbx + 8], rcx
mov r9, rbx
mov qword [rbx + 0x10], rdx
call qword [sym.imp.KERNEL32.dll_VirtualProtect]
test eax, eax
jne 0x140001d6e
call qword [sym.imp.KERNEL32.dll_GetLastError]
lea rcx, str.__VirtualProtect_failed_with_code_0x_x
mov edx, eax
call sym.__report_error
nop dword [rax]
xor esi, esi
jmp 0x140001cf8
mov rax, qword [0x1400180b8]
mov edx, dword [rdi + 8]
lea rcx, str.__VirtualQuery_failed_for__d_bytes_at_address__p
mov r8, qword [rax + rbx + 0x18]
call sym.__report_error
mov rdx, rbx
lea rcx, str.Address__p_has_no_image_section
call sym.__report_error
nop
nop word cs:[rax + rax]
nop dword [rax]
Function at 0x1400024a0
Capabilities:
Get thread local storage value

Disassembly:
push r12
push rbp
push rdi
push rsi
push rbx
sub rsp, 0x20
cmp edx, 2
je 0x1400025d0
ja 0x1400024e8
test edx, edx
je 0x140002568
mov eax, dword [0x140018108]
test eax, eax
je 0x140002650
mov dword [0x140018108], 1
mov eax, 1
add rsp, 0x20
pop rbx
pop rsi
pop rdi
pop rbp
pop r12
ret
cmp edx, 3
jne 0x1400024d5
mov eax, dword [0x140018108]
test eax, eax
je 0x1400024d5
lea r12, [0x140018120]
mov rcx, r12
call qword [sym.imp.KERNEL32.dll_EnterCriticalSection]
mov rbx, qword [0x140018100]
test rbx, rbx
je 0x140002554
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 rsi, rsi
je 0x140002678
test eax, eax
jne 0x140002678
mov rax, qword [rbx + 8]
mov rcx, rsi
call rax
mov rbx, qword [rbx + 0x10]
test rbx, rbx
jne 0x140002528
mov rcx, r12
call qword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
jmp 0x1400024d5
mov eax, dword [0x140018108]
test eax, eax
jne 0x1400025e8
mov eax, dword [0x140018108]
cmp eax, 1
jne 0x1400024d5
mov rbx, qword [0x140018100]
test rbx, rbx
je 0x1400025a1
nop dword [rax]
mov rcx, rbx
mov rbx, qword [rbx + 0x10]
call sym.free
test rbx, rbx
jne 0x140002590
lea rcx, [0x140018120]
mov qword [0x140018100], 0
mov dword [0x140018108], 0
call qword [sym.imp.KERNEL32.dll_DeleteCriticalSection]
jmp 0x1400024d5
call sym._fpreset
mov eax, 1
add rsp, 0x20
pop rbx
pop rsi
pop rdi
pop rbp
pop r12
ret
lea r12, [0x140018120]
mov rcx, r12
call qword [sym.imp.KERNEL32.dll_EnterCriticalSection]
mov rbx, qword [0x140018100]
test rbx, rbx
je 0x14000263c
mov rbp, qword [sym.imp.KERNEL32.dll_TlsGetValue]
mov rdi, qword [sym.imp.KERNEL32.dll_GetLastError]
nop word [rax + rax]
mov ecx, dword [rbx]
call rbp
mov rsi, rax
call rdi
test eax, eax
jne 0x140002668
test rsi, rsi
je 0x140002668
mov rax, qword [rbx + 8]
mov rcx, rsi
call rax
mov rbx, qword [rbx + 0x10]
test rbx, rbx
jne 0x140002618
mov rcx, r12
call qword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
jmp 0x140002572
lea rcx, [0x140018120]
call qword [sym.imp.KERNEL32.dll_InitializeCriticalSection]
jmp 0x1400024cb
mov rbx, qword [rbx + 0x10]
test rbx, rbx
jne 0x140002618
jmp 0x14000263c
mov rbx, qword [rbx + 0x10]
test rbx, rbx
jne 0x140002528
jmp 0x140002554

Function at 0x140002690
Capabilities:
Parse pe header

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

Function at 0x1400026c0
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 0x14000270d
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 0x140002704
add ecx, dword [rax + 8]
cmp rdx, rcx
jb 0x14000270f
add rax, 0x28
cmp rax, r9
jne 0x1400026f0
xor eax, eax
ret
Function at 0x140002710
Capabilities:
Parse pe header

Disassembly:
push rdi
push rsi
push rbx
sub rsp, 0x20
mov rsi, rcx
call sym.strlen
cmp rax, 8
ja 0x1400027a0
mov rdx, qword [0x140014ca0]
xor ebx, ebx
cmp word [rdx], 0x5a4d
jne 0x14000278e
movsxd rax, dword [rdx + 0x3c]
add rax, rdx
cmp dword [rax], 0x4550
jne 0x14000278e
cmp word [rax + 0x18], 0x20b
jne 0x14000278e
movzx edx, word [rax + 0x14]
lea rbx, [rax + rdx + 0x18]
movzx edx, word [rax + 6]
test dx, dx
je 0x1400027a0
lea eax, [rdx - 1]
lea rax, [rax + rax*4]
lea rdi, [rbx + rax*8 + 0x28]
jmp 0x140002779
add rbx, 0x28
cmp rbx, rdi
je 0x1400027a0
mov r8d, 8
mov rdx, rsi
mov rcx, rbx
call sym.strncmp
test eax, eax
jne 0x140002770
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 0x1400027b0
Capabilities:
Enumerate pe sections
Parse pe header

Disassembly:
mov r8, qword [0x140014ca0]
xor eax, eax
cmp word [r8], 0x5a4d
jne 0x1400027d0
movsxd rdx, dword [r8 + 0x3c]
add rdx, r8
cmp dword [rdx], 0x4550
je 0x1400027d8
ret
cmp word [rdx + 0x18], 0x20b
jne 0x1400027d0
movzx eax, word [rdx + 0x14]
sub rcx, r8
movzx r8d, word [rdx + 6]
lea rax, [rdx + rax + 0x18]
test r8w, r8w
je 0x140002825
lea edx, [r8 - 1]
lea rdx, [rdx + rdx*4]
lea r9, [rax + rdx*8 + 0x28]
nop dword [rax]
mov r8d, dword [rax + 0xc]
mov rdx, r8
cmp rcx, r8
jb 0x14000281c
add edx, dword [rax + 8]
cmp rcx, rdx
jb 0x1400027d0
add rax, 0x28
cmp rax, r9
jne 0x140002808
xor eax, eax
ret

Function at 0x140002830
Capabilities:
Parse pe header

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

Function at 0x140002870
Capabilities:
Parse pe header

Disassembly:
mov r8, qword [0x140014ca0]
xor eax, eax
cmp word [r8], 0x5a4d
jne 0x140002890
movsxd rdx, dword [r8 + 0x3c]
add rdx, r8
cmp dword [rdx], 0x4550
je 0x140002898
ret
cmp word [rdx + 0x18], 0x20b
jne 0x140002890
movzx eax, word [rdx + 0x14]
movzx r8d, word [rdx + 6]
lea rax, [rdx + rax + 0x18]
test r8w, r8w
je 0x1400028e0
lea edx, [r8 - 1]
lea rdx, [rdx + rdx*4]
lea rdx, [rax + rdx*8 + 0x28]
nop dword [rax]
test byte [rax + 0x27], 0x20
je 0x1400028d7
test rcx, rcx
je 0x140002890
sub rcx, 1
add rax, 0x28
cmp rdx, rax
jne 0x1400028c8
xor eax, eax
ret

Function at 0x1400028f0
Capabilities:
Parse pe header

Disassembly:
mov rax, qword [0x140014ca0]
xor edx, edx
cmp word [rax], 0x5a4d
jne 0x14000290f
movsxd rcx, dword [rax + 0x3c]
add rcx, rax
cmp dword [rcx], 0x4550
je 0x140002918
mov rax, rdx
ret
cmp word [rcx + 0x18], 0x20b
cmove rdx, rax
mov rax, rdx
ret
Function at 0x140002930
Capabilities:
Enumerate pe sections
Parse pe header

Disassembly:
mov rdx, qword [0x140014ca0]
xor eax, eax
cmp word [rdx], 0x5a4d
jne 0x140002950
movsxd r8, dword [rdx + 0x3c]
add r8, rdx
cmp dword [r8], 0x4550
je 0x140002958
ret
cmp word [r8 + 0x18], 0x20b
jne 0x140002950
sub rcx, rdx
movzx r9d, word [r8 + 6]
movzx edx, word [r8 + 0x14]
lea rdx, [r8 + rdx + 0x18]
test r9w, r9w
je 0x140002950
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 0x1400029a4
add eax, dword [rdx + 8]
cmp rcx, rax
jb 0x1400029b0
add rdx, 0x28
cmp r9, rdx
jne 0x140002990
xor eax, eax
ret
mov eax, dword [rdx + 0x24]
not eax
shr eax, 0x1f
ret

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

Disassembly:
mov r11, qword [0x140014ca0]
xor r9d, r9d
cmp word [r11], 0x5a4d
mov r8d, ecx
jne 0x1400029e4
movsxd rcx, dword [r11 + 0x3c]
add rcx, r11
cmp dword [rcx], 0x4550
je 0x1400029f0
mov rax, r9
ret
cmp word [rcx + 0x18], 0x20b
jne 0x1400029e4
mov eax, dword [rcx + 0x90]
test eax, eax
je 0x1400029e4
movzx edx, word [rcx + 0x14]
movzx r10d, word [rcx + 6]
lea rdx, [rcx + rdx + 0x18]
test r10w, r10w
je 0x1400029e4
lea ecx, [r10 - 1]
lea rcx, [rcx + rcx*4]
lea r10, [rdx + rcx*8 + 0x28]
nop dword [rax + rax]
mov r9d, dword [rdx + 0xc]
mov rcx, r9
cmp rax, r9
jb 0x140002a3c
add ecx, dword [rdx + 8]
cmp rax, rcx
jb 0x140002a50
add rdx, 0x28
cmp rdx, r10
jne 0x140002a28
xor r9d, r9d
mov rax, r9
ret
add rax, r11
jmp 0x140002a60
sub r8d, 1
add rax, 0x14
mov ecx, dword [rax + 4]
test ecx, ecx
jne 0x140002a6e
mov edx, dword [rax + 0xc]
test edx, edx
je 0x140002a45
test r8d, r8d
jg 0x140002a58
mov r9d, dword [rax + 0xc]
add r9, r11
mov rax, r9
ret
Function at 0x140001000
Capabilities:
Create directory
Generate random numbers via winapi
Write file on windows

Disassembly:
mov qword [rsp + 8], rbx
mov qword [rsp + 0x10], rdi
push rbp
lea rbp, [rsp - 0xbd0]
sub rsp, 0xcd0
mov rax, qword [section..data]
xor rax, rsp
mov qword [rbp + 0xbc0], rax
mov r8d, 0x104
lea rdx, [rsp + 0x60]
xor ecx, ecx
call qword [sym.imp.KERNEL32.dll_GetModuleFileNameW]
test eax, eax
je 0x1400010f3
xor edi, edi
lea rcx, [rsp + 0x60]
mov word [rbp + 0x380], di
call qword [sym.imp.KERNEL32.dll_lstrlenW]
sub eax, 1
js 0x140001088
movsxd rcx, eax
lea rdx, [rsp + 0x60]
lea rdx, [rdx + rcx*2]
nop dword [rax + rax]
movzx ecx, word [rdx]
cmp cx, 0x5c
je 0x140001088
cmp cx, 0x2f
je 0x140001088
sub rdx, 2
sub eax, 1
jns 0x140001070
test eax, eax
jle 0x1400010f3
lea r8d, [rax + 1]
lea rdx, [rsp + 0x60]
lea rcx, [rbp + 0x380]
call qword [sym.imp.KERNEL32.dll_lstrcpynW]
mov r9d, 1
mov dword [rsp + 0x40], edi
xor r8d, r8d
mov qword [rsp + 0x48], rdi
xor edx, edx
mov dword [rsp + 0x20], 0xf0000000
lea rcx, [rsp + 0x48]
call qword [sym.imp.ADVAPI32.dll_CryptAcquireContextW]
test eax, eax
je 0x1400010f3
mov rcx, qword [rsp + 0x48]
lea r8, [rsp + 0x40]
mov edx, 4
call qword [sym.imp.ADVAPI32.dll_CryptGenRandom]
mov rcx, qword [rsp + 0x48]
xor edx, edx
test eax, eax
jne 0x14000111c
call qword [sym.imp.ADVAPI32.dll_CryptReleaseContext]
mov eax, 1
mov rcx, qword [rbp + 0xbc0]
xor rcx, rsp
call fcn.140001250
lea r11, [rsp + 0xcd0]
mov rbx, qword [r11 + 0x10]
mov rdi, qword [r11 + 0x18]
mov rsp, r11
pop rbp
ret
call qword [sym.imp.ADVAPI32.dll_CryptReleaseContext]
mov r8d, dword [rsp + 0x40]
lea rdx, str._As_u
lea rcx, [rbp + 0x590]
call qword [sym.imp.USER32.dll_wsprintfW]
lea r9, [rbp + 0x590]
lea r8, [rbp + 0x380]
lea rdx, str._s_s
lea rcx, [rbp + 0x170]
call qword [sym.imp.USER32.dll_wsprintfW]
xor edx, edx
lea rcx, [rbp + 0x170]
call qword [sym.imp.KERNEL32.dll_CreateDirectoryW]
test eax, eax
je 0x1400010f3
lea r8, [rbp + 0x170]
lea rdx, str._s_source
lea rcx, [rbp + 0x7a0]
call qword [sym.imp.USER32.dll_wsprintfW]
xor edx, edx
lea rcx, [rbp + 0x7a0]
call qword [sym.imp.KERNEL32.dll_CreateDirectoryW]
test eax, eax
je 0x1400010f3
lea r8, [rbp + 0x170]
lea rdx, str._sdata.bin
lea rcx, [rbp + 0x9b0]
call qword [sym.imp.USER32.dll_wsprintfW]
mov qword [rsp + 0x30], rdi
lea rcx, [rbp + 0x9b0]
mov dword [rsp + 0x28], 0x80
xor r9d, r9d
xor r8d, r8d
mov dword [rsp + 0x20], 2
mov edx, 0x40000000
call qword [sym.imp.KERNEL32.dll_CreateFileW]
mov rbx, rax
cmp rax, 0xffffffffffffffff
je 0x1400010f3
lea r9, [rsp + 0x50]
mov dword [rsp + 0x50], edi
mov r8d, 4
mov qword [rsp + 0x20], rdi
lea rdx, [0x140002140]
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_WriteFile]
mov rcx, rbx
test eax, eax
jne 0x14000122d
call qword [sym.imp.KERNEL32.dll_CloseHandle]
jmp 0x1400010f3
call qword [sym.imp.KERNEL32.dll_CloseHandle]
xor eax, eax
jmp 0x1400010f8
Function at 0x40188e
Capabilities:
Link many functions at runtime

Disassembly:
push rbx
sub rsp, 0x20
lea rcx, str.OmniMIDI
call qword [sym.imp.KERNEL32.dll_LoadLibraryA]
mov qword [0x0041a260], rax
mov rcx, rax
test rax, rax
jne 0x4018b8
lea rcx, str.KDMAPI_not_available._n
jmp 0x4018db
mov rbx, qword [sym.imp.KERNEL32.dll_GetProcAddress]
lea rdx, str.InitializeKDMAPIStream
call rbx
mov qword [0x0041a258], rax
test rax, rax
jne 0x4018e7
lea rcx, str.GetProcAddress_failed_for_KDMAPI_InitializeKDMAPIStream._n
call fcn.0040157c
xor eax, eax
jmp 0x4019d6
mov rcx, qword [0x0041a260]
lea rdx, str.SendDirectData
call rbx
lea rcx, str.GetProcAddress_failed_for_KDMAPI_SendDirectData._n
mov qword [0x0041a240], rax
test rax, rax
je 0x4018db
mov rcx, qword [0x0041a260]
lea rdx, str.SendDirectLongData
call rbx
lea rcx, str.GetProcAddress_failed_for_KDMAPI_SendDirectLongData._n
mov qword [0x0041a238], rax
test rax, rax
je 0x4018db
mov rcx, qword [0x0041a260]
lea rdx, str.PrepareLongData
call rbx
lea rcx, str.GetProcAddress_failed_for_KDMAPI_PrepareLongData._n
mov qword [0x0041a230], rax
test rax, rax
je 0x4018db
mov rcx, qword [0x0041a260]
lea rdx, str.UnprepareLongData
call rbx
lea rcx, str.GetProcAddress_failed_for_KDMAPI_UnprepareLongData._n
mov qword [0x0041a228], rax
test rax, rax
je 0x4018db
mov rcx, qword [0x0041a260]
lea rdx, str.TerminateKDMAPIStream
call rbx
lea rcx, str.GetProcAddress_failed_for_KDMAPI_TerminateKDMAPIStream._n
mov qword [0x0041a250], rax
test rax, rax
je 0x4018db
mov rcx, qword [0x0041a260]
lea rdx, str.ResetKDMAPIStream
call rbx
lea rcx, str.GetProcAddress_failed_for_KDMAPI_ResetKDMAPIStream._n
mov qword [0x0041a248], rax
test rax, rax
je 0x4018db
lea rcx, str.KDMAPI_FUNCTIONAL_n
call fcn.0040157c
mov eax, 1
add rsp, 0x20
pop rbx
ret