joyce8/EMBER2024-capa huggingface dataset:
Function at 0x180004360
Capabilities:
Encode data using xor
Generate random numbers using a mersenne twister

Disassembly:
sub rsp, 8
mov r10, rcx
mov r9d, 0x270
mov ecx, dword [rcx]
cmp ecx, r9d
jne 0x1800043c1
lea r8, [r10 + 8]
nop dword [rax + rax]
mov edx, dword [r8 - 4]
xor edx, dword [r8]
lea r8, [r8 + 4]
btr edx, 0x1f
xor edx, dword [r8 - 8]
mov eax, edx
and al, 1
neg al
sbb ecx, ecx
shr edx, 1
and ecx, 0x9908b0df
xor ecx, dword [r8 + 0x62c]
xor ecx, edx
mov dword [r8 + 0x9b8], ecx
sub r9, 1
jne 0x180004380
mov ecx, dword [r10]
jmp 0x1800044aa
cmp ecx, 0x4e0
jb 0x1800044aa
lea r11, [r10 + 0x9c4]
mov qword [rsp], rbx
mov eax, dword [r11]
mov ebx, 0xe3
mov edx, dword [r11 + 4]
lea r8, [r11 + 4]
xor edx, eax
btr edx, 0x1f
xor edx, eax
mov eax, edx
and al, 1
neg al
mov eax, dword [r8]
sbb ecx, ecx
shr edx, 1
and ecx, 0x9908b0df
xor ecx, dword [r11 + 0x634]
xor ecx, edx
mov dword [r11 - 0x9c0], ecx
lea r11, [r8]
sub rbx, 1
jne 0x1800043e0
lea r11, [r10 + 0xd50]
mov ebx, 0x18c
mov eax, dword [r11]
nop dword [rax + rax]
mov edx, eax
lea r8, [r11 + 4]
xor edx, dword [r8]
btr edx, 0x1f
xor edx, eax
mov eax, edx
and al, 1
neg al
mov eax, dword [r8]
sbb ecx, ecx
shr edx, 1
and ecx, 0x9908b0df
xor ecx, dword [r11 - 0xd4c]
xor ecx, edx
mov dword [r11 - 0x9c0], ecx
lea r11, [r8]
sub rbx, 1
jne 0x180004430
mov edx, dword [r10 + 0x1380]
xor edx, dword [r10 + 4]
mov rbx, qword [rsp]
btr edx, 0x1f
xor edx, dword [r10 + 0x1380]
mov eax, edx
and al, 1
neg al
sbb ecx, ecx
shr edx, 1
and ecx, 0x9908b0df
xor ecx, dword [r10 + 0x634]
xor ecx, edx
mov dword [r10 + 0x9c0], ecx
xor ecx, ecx
mov dword [r10], ecx
mov eax, ecx
mov edx, dword [r10 + rax*4 + 4]
lea eax, [rcx + 1]
mov dword [r10], eax
mov ecx, edx
mov eax, dword [r10 + 0x1384]
shr ecx, 0xb
and eax, ecx
xor edx, eax
mov eax, edx
and eax, 0xff3a58ad
shl eax, 7
xor edx, eax
mov eax, edx
and eax, 0xffffdf8c
shl eax, 0xf
xor edx, eax
mov eax, edx
shr eax, 0x12
xor eax, edx
add rsp, 8
ret
Function at 0x1800044f0
Capabilities:
Connect socket
Connect udp socket
Create udp socket
Resolve dns
Set socket configuration

Disassembly:
push rbx
push rbp
push rsi
push r12
push r14
push r15
sub rsp, 0x78
mov rax, qword [0x180030010]
xor rax, rsp
mov qword [rsp + 0x68], rax
mov r12d, 2
movzx r14d, r8w
mov r15, rdx
mov rbp, rcx
xor esi, esi
mov edx, r12d
mov ecx, r12d
lea r8d, [rsi + 0x11]
call qword [sym.imp.WS2_32.dll_socket]
mov qword [rbp + 0xb0], rax
cmp rax, 0xffffffffffffffff
je 0x1800046cf
mov qword [rsp + 0x40], rsi
lea rcx, [rsp + 0x54]
mov qword [rsp + 0x38], rsi
lea r9d, [rsi + 4]
mov qword [rsp + 0x30], rcx
lea r8, [rsp + 0x50]
mov dword [rsp + 0x28], esi
mov rcx, rax
mov edx, 0x9800000c
mov qword [rsp + 0x20], rsi
mov qword [rsp + 0x70], rdi
mov dword [rsp + 0x50], esi
call qword [sym.imp.WS2_32.dll_WSAIoctl]
mov rcx, qword [rbp + 0xb0]
lea r9, [rsp + 0x50]
mov edx, 0xffff
mov dword [rsp + 0x20], 4
lea r8d, [rsi - 5]
call qword [sym.imp.WS2_32.dll_setsockopt]
mov rcx, qword [rbp + 0xb0]
lea r9, [rsp + 0x50]
mov edx, 0xffff
mov dword [rsp + 0x20], 4
lea r8d, [rsi + 4]
call qword [sym.imp.WS2_32.dll_setsockopt]
call qword [sym.imp.WS2_32.dll_WSACreateEvent]
mov rcx, r15
mov qword [rbp + 0xb8], rax
call qword [sym.imp.KERNEL32.dll_lstrlenW]
mov qword [rsp + 0x38], rsi
mov r8, r15
mov qword [rsp + 0x30], rsi
mov r9d, eax
mov dword [rsp + 0x28], esi
xor edx, edx
xor ecx, ecx
mov qword [rsp + 0x20], rsi
call qword [sym.imp.KERNEL32.dll_WideCharToMultiByte]
movsxd rbx, eax
lea eax, [rbx + 1]
movsxd rcx, eax
call fcn.1800092b8
mov rcx, r15
mov rdi, rax
call qword [sym.imp.KERNEL32.dll_lstrlenW]
mov qword [rsp + 0x38], rsi
mov r8, r15
mov qword [rsp + 0x30], rsi
mov r9d, eax
mov dword [rsp + 0x28], ebx
xor edx, edx
xor ecx, ecx
mov qword [rsp + 0x20], rdi
call qword [sym.imp.KERNEL32.dll_WideCharToMultiByte]
mov rcx, rdi
mov byte [rbx + rdi], sil
call qword [sym.imp.WS2_32.dll_gethostbyname]
mov rcx, rdi
mov rbx, rax
call fcn.180009248
mov rdi, qword [rsp + 0x70]
test rbx, rbx
je 0x1800046cf
movzx ecx, r14w
mov word [rsp + 0x58], r12w
call qword [sym.imp.WS2_32.dll_htons]
mov rdx, qword [rbp + 0xb8]
lea r8d, [rsi + 0x30]
mov word [rsp + 0x5a], ax
mov rax, qword [rbx + 0x18]
mov rcx, qword [rax]
mov eax, dword [rcx]
mov rcx, qword [rbp + 0xb0]
mov dword [rsp + 0x5c], eax
call qword [sym.imp.WS2_32.dll_WSAEventSelect]
cmp eax, 0xffffffff
je 0x1800046cb
mov rcx, qword [rbp + 0xb0]
lea r8d, [rsi + 0x10]
lea rdx, [rsp + 0x58]
call qword [sym.imp.WS2_32.dll_connect]
test eax, eax
je 0x1800046c6
cmp eax, 0xffffffff
jne 0x1800046cb
call qword [sym.imp.WS2_32.dll_WSAGetLastError]
cmp eax, 0x2733
jne 0x1800046cb
mov esi, 1
mov eax, esi
jmp 0x1800046d1
xor eax, eax
mov rcx, qword [rsp + 0x68]
xor rcx, rsp
call fcn.180008c40
add rsp, 0x78
pop r15
pop r14
pop r12
pop rsi
pop rbp
pop rbx
ret
Function at 0x180004bd0
Capabilities:
Receive data
Receive data on socket

Disassembly:
mov qword [rsp + 8], rbx
push rdi
sub rsp, 0x30
mov rbx, rcx
nop dword [rax]
mov rdx, qword [rbx + 0xf8]
xor r9d, r9d
mov rcx, qword [rbx + 0xb0]
mov r8d, 0x598
call qword [sym.imp.WS2_32.dll_recv]
mov edi, eax
test eax, eax
jle 0x180004c56
cmp eax, 0x10
je 0x180004c84
xor ecx, ecx
call qword [sym.imp.KERNEL32.dll_SetLastError]
mov eax, dword [rbx + 0x29c]
lea rcx, [rbx + 0x2c0]
mov rdx, qword [rbx + 0xf8]
cmp edi, 0x18
jl 0x180004c3e
mov r9, qword [rbx + 0x2a8]
mov r8d, edi
mov dword [rsp + 0x20], eax
call fcn.1800061e0
jmp 0x180004c4c
cmp edi, 0xc
jne 0x180004cd4
call fcn.180006470
cmp eax, 2
jne 0x180004be0
jmp 0x180004cdf
cmp edi, 0xffffffff
jne 0x180004be0
call qword [sym.imp.WS2_32.dll_WSAGetLastError]
cmp eax, 0x2733
je 0x180004d20
cmp eax, 0x2744
je 0x180004be0
cmp eax, 0x2746
je 0x180004be0
jmp 0x180004cef
mov rcx, qword [rbx + 0xf8]
mov rax, qword [rcx]
cmp rax, qword [0x18002b248]
jne 0x180004ccc
mov rax, qword [rcx + 8]
cmp rax, qword [0x18002b250]
jne 0x180004ccc
xor eax, eax
mov dword [rbx + 0xa0], 1
mov dword [rbx + 0xac], eax
mov qword [rbx + 0xa4], 5
mov rbx, qword [rsp + 0x40]
add rsp, 0x30
pop rdi
ret
xor ecx, ecx
call qword [sym.imp.KERNEL32.dll_SetLastError]
mov ecx, recv
call qword [sym.imp.WS2_32.dll_WSASetLastError]
call qword [sym.imp.KERNEL32.dll_GetLastError]
test eax, eax
mov ecx, 0x4c7
cmove eax, ecx
mov dword [rbx + 0xa0], 1
mov dword [rbx + 0xa4], 4
mov dword [rbx + 0xa8], eax
xor eax, eax
mov dword [rbx + 0xac], 1
mov rbx, qword [rsp + 0x40]
add rsp, 0x30
pop rdi
ret
mov rbx, qword [rsp + 0x40]
mov eax, 1
add rsp, 0x30
pop rdi
ret
Function at 0x180004d30
Capabilities:
Send data
Send data on socket

Disassembly:
mov qword [rsp + 0x18], rbx
push rdi
push r14
push r15
sub rsp, 0x20
mov qword [rsp + 0x40], rbp
lea rbx, [rcx + 0x210]
mov qword [rsp + 0x48], rsi
mov rdi, rcx
xor r15d, r15d
nop word [rax + rax]
mov eax, dword [rdi + 0x270]
test eax, eax
jle 0x180004e97
mov rcx, rbx
call qword [sym.imp.KERNEL32.dll_EnterCriticalSection]
mov rsi, qword [rdi + 0x240]
cmp rsi, qword [rdi + 0x248]
je 0x180004d9d
mov rax, qword [rsi + 8]
mov qword [rdi + 0x240], rax
mov qword [rax + 0x10], r15
test rsi, rsi
je 0x180004dbe
jmp 0x180004db0
test rsi, rsi
je 0x180004dbe
mov qword [rdi + 0x240], r15
mov qword [rdi + 0x248], r15
mov qword [rsi + 8], r15
mov qword [rsi + 0x10], r15
dec dword [rdi + 0x238]
mov rcx, rbx
call qword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
test rsi, rsi
je 0x180004e97
mov r8d, dword [rsi + 0x30]
xor r9d, r9d
sub r8d, dword [rsi + 0x28]
mov rdx, qword [rsi + 0x28]
mov rcx, qword [rdi + 0xb0]
call qword [sym.imp.WS2_32.dll_send]
mov ebp, eax
test eax, eax
jle 0x180004e26
mov rcx, rbx
call qword [sym.imp.KERNEL32.dll_EnterCriticalSection]
mov ecx, dword [rdi + 0x270]
sub ecx, ebp
mov dword [rdi + 0x270], ecx
mov rcx, rbx
call qword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
mov rdx, rsi
lea rcx, [rdi + 0x110]
call fcn.180001c50
jmp 0x180004d60
cmp ebp, 0xffffffff
je 0x180004e3f
mov rdx, rsi
lea rcx, [rdi + 0x110]
call fcn.180001c50
jmp 0x180004d60
call qword [sym.imp.WS2_32.dll_WSAGetLastError]
cmp eax, 0x2733
jne 0x180004eb5
mov rcx, rbx
call qword [sym.imp.KERNEL32.dll_EnterCriticalSection]
mov rax, qword [rdi + 0x240]
test rax, rax
je 0x180004e72
mov qword [rax + 0x10], rsi
mov rax, qword [rdi + 0x240]
mov qword [rsi + 8], rax
jmp 0x180004e81
mov qword [rsi + 0x10], r15
mov qword [rsi + 8], r15
mov qword [rdi + 0x248], rsi
inc dword [rdi + 0x238]
mov rcx, rbx
mov qword [rdi + 0x240], rsi
call qword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
mov eax, 1
mov rsi, qword [rsp + 0x48]
mov rbp, qword [rsp + 0x40]
mov rbx, qword [rsp + 0x50]
add rsp, 0x20
pop r15
pop r14
pop rdi
ret
mov rdx, rsi
mov dword [rdi + 0xa0], 1
lea rcx, [rdi + 0x110]
mov dword [rdi + 0xa4], 3
mov dword [rdi + 0xa8], eax
mov dword [rdi + 0xac], 1
call fcn.180001c50
xor eax, eax
jmp 0x180004e9c
Function at 0x180008620
Capabilities:
Create thread

Disassembly:
sub rsp, 0x38
cmp edx, 1
jne 0x180008670
cmp dword [0x180030c74], 0
je 0x180008670
cmp qword [0x180032398], 0
jne 0x180008670
xor eax, eax
lea r8, [0x180008310]
mov qword [rsp + 0x28], rax
xor r9d, r9d
xor edx, edx
mov dword [rsp + 0x20], eax
xor ecx, ecx
call qword [sym.imp.KERNEL32.dll_CreateThread]
mov rcx, rax
mov qword [0x180032398], rax
mov edx, 0xffffffff
call qword [sym.imp.KERNEL32.dll_WaitForSingleObject]
mov eax, 1
add rsp, 0x38
ret

Function at 0x180008680
Capabilities:
Create thread

Disassembly:
mov qword [rsp + 8], rbx
mov qword [rsp + 0x10], rsi
push rdi
sub rsp, 0x30
mov edi, r8d
mov ebx, edx
mov r8, rcx
mov edx, 0xff
lea rcx, str.192.168.50.142
mov esi, r9d
call fcn.1800100b0
xor eax, eax
mov dword [0x180030c6c], ebx
mov qword [rsp + 0x28], rax
lea r8, [0x180008310]
xor r9d, r9d
mov dword [rsp + 0x20], eax
xor edx, edx
mov dword [0x180030c70], edi
xor ecx, ecx
mov dword [0x180030c74], esi
call qword [sym.imp.KERNEL32.dll_CreateThread]
mov rcx, rax
mov qword [0x180032398], rax
mov edx, 0xffffffff
call qword [sym.imp.KERNEL32.dll_WaitForSingleObject]
mov ecx, 0x12c
call qword [sym.imp.KERNEL32.dll_Sleep]
mov rbx, qword [rsp + 0x40]
xor al, al
mov rsi, qword [rsp + 0x48]
add rsp, 0x30
pop rdi
ret

Function at 0x180008710
Capabilities:
Create thread

Disassembly:
sub rsp, 0x38
xor eax, eax
lea r8, [0x180008310]
mov qword [rsp + 0x28], rax
xor r9d, r9d
xor edx, edx
mov dword [rsp + 0x20], eax
xor ecx, ecx
call qword [sym.imp.KERNEL32.dll_CreateThread]
mov rcx, rax
mov edx, 0xffffffff
call qword [sym.imp.KERNEL32.dll_WaitForSingleObject]
mov ecx, 0x12c
call qword [sym.imp.KERNEL32.dll_Sleep]
xor al, al
add rsp, 0x38
ret
Function at 0x140004210
Capabilities:
Access peb ldr_data
Encode data using xor
Hash data using fnv
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
push r14
sub rsp, 0x20
mov rax, qword gs:[0x60]
mov rcx, qword [rax + 0x18]
mov rax, qword [rcx + 0x10]
mov rsi, qword [rax]
mov r11, rsi
mov r9, qword [r11 + 0x30]
xor r14d, r14d
movsxd rax, dword [r9 + 0x3c]
mov ebx, dword [rax + r9 + 0x88]
add rbx, r9
cmp rbx, r9
je 0x1400042b8
mov r8d, dword [rbx + 0x18]
test r8d, r8d
je 0x1400042b8
mov edi, dword [rbx + 0x20]
nop dword [rax + rax]
dec r8d
mov edx, 0xe1b536d
lea rax, [rdi + r8*4]
mov eax, dword [rax + r9]
add rax, r9
movzx ecx, byte [rax]
inc rax
test cl, cl
je 0x1400042b3
nop dword [rax]
movsx ecx, cl
lea rax, [rax + 1]
xor ecx, edx
imul edx, ecx, 0x1000193
movzx ecx, byte [rax - 1]
test cl, cl
jne 0x140004290
cmp edx, 0x7c13499d
je 0x1400043b7
test r8d, r8d
jne 0x140004270
mov rax, qword [r11]
mov r11, rax
cmp rax, rsi
je 0x1400042cd
cmp qword [rax + 0x30], r14
jne 0x140004241
mov rax, r14
call rax
mov ecx, 0x1f4
mov ebp, eax
call qword [sym.imp.KERNEL32.dll_Sleep]
mov rax, qword gs:[0x60]
mov rcx, qword [rax + 0x18]
mov rax, qword [rcx + 0x10]
mov rsi, qword [rax]
mov r11, rsi
nop word [rax + rax]
mov r9, qword [r11 + 0x30]
movsxd rax, dword [r9 + 0x3c]
mov ebx, dword [rax + r9 + 0x88]
add rbx, r9
cmp rbx, r9
je 0x140004374
mov r8d, dword [rbx + 0x18]
test r8d, r8d
je 0x140004374
mov edi, dword [rbx + 0x20]
nop dword [rax]
nop dword [rax + rax]
dec r8d
mov edx, 0x8315fb6e
lea rax, [rdi + r8*4]
mov ecx, dword [rax + r9]
add rcx, r9
movzx eax, byte [rcx]
inc rcx
test al, al
je 0x14000436f
nop dword [rax]
movsx eax, al
lea rcx, [rcx + 1]
xor eax, edx
imul edx, eax, 0x1000193
movzx eax, byte [rcx - 1]
test al, al
jne 0x140004350
cmp edx, 0x2895e306
je 0x1400043d3
test r8d, r8d
jne 0x140004330
mov rax, qword [r11]
mov r11, rax
cmp rax, rsi
je 0x140004389
cmp qword [rax + 0x30], r14
jne 0x140004300
mov rax, r14
call rax
mov rbx, qword [rsp + 0x30]
sub eax, ebp
mov rbp, qword [rsp + 0x38]
cmp eax, 0x1c2
mov rsi, qword [rsp + 0x40]
mov rdi, qword [rsp + 0x48]
setbe r14b
mov eax, r14d
add rsp, 0x20
pop r14
ret
mov ecx, dword [rbx + 0x24]
add rcx, r9
movzx edx, word [rcx + r8*2]
mov ecx, dword [rbx + 0x1c]
add rcx, r9
mov eax, dword [rcx + rdx*4]
add rax, r9
jmp 0x1400042d0
mov ecx, dword [rbx + 0x24]
add rcx, r9
movzx edx, word [rcx + r8*2]
mov ecx, dword [rbx + 0x1c]
add rcx, r9
mov eax, dword [rcx + rdx*4]
add rax, r9
jmp 0x14000438c
Function at 0x140005820
Capabilities:
Access peb ldr_data
Encode data using xor
Hash data using fnv
Resolve function by parsing pe exports

Disassembly:
mov qword [rsp + 0x10], rbx
mov qword [rsp + 0x18], rbp
push rsi
push rdi
push r14
sub rsp, 0x30
mov rax, qword [section..data]
xor rax, rsp
mov qword [rsp + 0x28], rax
mov r14, rcx
mov ebx, 0xffffffff
call fcn.140004d40
cmp eax, 1
jne 0x14000594b
xor ebp, ebp
lea rcx, [rsp + 0x20]
mov qword [rsp + 0x20], rbp
call fcn.1400046e0
test eax, eax
je 0x1400059f3
mov rax, qword gs:[0x60]
mov rcx, qword [rax + 0x18]
mov rax, qword [rcx + 0x10]
mov rsi, qword [rax]
mov r11, rsi
nop word [rax + rax]
mov r9, qword [r11 + 0x30]
movsxd rax, dword [r9 + 0x3c]
mov ebx, dword [rax + r9 + 0x88]
add rbx, r9
cmp rbx, r9
je 0x140005904
mov r8d, dword [rbx + 0x18]
test r8d, r8d
je 0x140005904
mov edi, dword [rbx + 0x20]
nop dword [rax]
nop dword [rax + rax]
dec r8d
mov edx, 0x10aae405
lea rax, [rdi + r8*4]
mov ecx, dword [rax + r9]
add rcx, r9
movzx eax, byte [rcx]
inc rcx
test al, al
je 0x1400058ff
nop dword [rax]
movsx eax, al
lea rcx, [rcx + 1]
xor eax, edx
imul edx, eax, 0x1000193
movzx eax, byte [rcx - 1]
test al, al
jne 0x1400058e0
cmp edx, 0xfab786a3
je 0x140005932
test r8d, r8d
jne 0x1400058c0
mov rax, qword [r11]
mov r11, rax
cmp rax, rsi
je 0x140005919
cmp qword [rax + 0x30], rbp
jne 0x140005890
mov rax, rbp
mov rcx, r14
call rax
mov rcx, qword [rsp + 0x20]
mov ebx, eax
call fcn.140004a10
jmp 0x1400059f3
mov ecx, dword [rbx + 0x24]
add rcx, r9
movzx edx, word [rcx + r8*2]
mov ecx, dword [rbx + 0x1c]
add rcx, r9
mov eax, dword [rcx + rdx*4]
add rax, r9
jmp 0x14000591c
mov rax, qword gs:[0x60]
mov rcx, qword [rax + 0x18]
mov rax, qword [rcx + 0x10]
mov rsi, qword [rax]
mov r11, rsi
mov r9, qword [r11 + 0x30]
xor ebp, ebp
movsxd rax, dword [r9 + 0x3c]
mov ebx, dword [rax + r9 + 0x88]
add rbx, r9
cmp rbx, r9
je 0x1400059d4
mov r8d, dword [rbx + 0x18]
test r8d, r8d
je 0x1400059d4
mov edi, dword [rbx + 0x20]
nop dword [rax + rax]
dec r8d
mov edx, 0x60d83239
lea rax, [rdi + r8*4]
mov eax, dword [rax + r9]
add rax, r9
movzx ecx, byte [rax]
inc rax
test cl, cl
je 0x1400059cf
nop dword [rax]
movsx ecx, cl
lea rax, [rax + 1]
xor ecx, edx
imul edx, ecx, 0x1000193
movzx ecx, byte [rax - 1]
test cl, cl
jne 0x1400059b0
cmp edx, 0x9df5c75f
je 0x140005a1c
test r8d, r8d
jne 0x140005990
mov rax, qword [r11]
mov r11, rax
cmp rax, rsi
je 0x1400059e9
cmp qword [rax + 0x30], rbp
jne 0x140005962
mov rax, rbp
mov rcx, r14
call rax
mov ebx, eax
cmp ebx, 0xffffffff
setne bpl
mov eax, ebp
mov rcx, qword [rsp + 0x28]
xor rcx, rsp
call fcn.14000a5f0
mov rbx, qword [rsp + 0x58]
mov rbp, qword [rsp + 0x60]
add rsp, 0x30
pop r14
pop rdi
pop rsi
ret
mov ecx, dword [rbx + 0x24]
add rcx, r9
movzx edx, word [rcx + r8*2]
mov ecx, dword [rbx + 0x1c]
add rcx, r9
mov eax, dword [rcx + rdx*4]
add rax, r9
jmp 0x1400059ec
Function at 0x14000aeb0
Capabilities:
Parse pe header

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

Disassembly:
push rbx
sub rsp, 0x30
cmp qword [rcx + 0x18], 7
mov rbx, rcx
mov qword [rsp + 0x20], rcx
jbe 0x140005bf8
mov rcx, qword [rcx]
mov qword [rsp + 0x48], rdi
call qword [sym.imp.KERNEL32.dll_GetFileAttributesW]
cmp eax, 0xffffffff
je 0x140005c11
test al, 0x10
je 0x140005c11
mov dil, 1
jmp 0x140005c14
xor dil, dil
mov rdx, qword [rbx + 0x18]
cmp rdx, 7
jbe 0x140005c4f
mov rcx, qword [rbx]
lea rdx, [rdx*2 + 2]
cmp rdx, 0x1000
jb 0x140005c4a
mov r8, qword [rcx - 8]
add rdx, 0x27
sub rcx, r8
lea rax, [rcx - 8]
cmp rax, 0x1f
ja 0x140005c6f
mov rcx, r8
call fcn.1400113c4
xor eax, eax
mov qword [rbx + 0x18], 7
mov qword [rbx + 0x10], rax
mov word [rbx], ax
movzx eax, dil
mov rdi, qword [rsp + 0x48]
add rsp, 0x30
pop rbx
ret
call qword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll__invalid_parameter_noinfo_noreturn]
int3
Function at 0x140006c40
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 0x140006c68
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 0x140006c8e
mov rax, qword [rcx + 0x58]
mov ecx, dword [rax]
jmp 0x140006c90
xor ecx, ecx
movsxd rbp, ecx
test rbx, rbx
jle 0x140006ce9
test ecx, ecx
jle 0x140006cc9
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 0x140006ce9
mov r9, qword [rdi + 0x80]
test r9, r9
je 0x140006ce9
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 0x140006d10
Capabilities:
Read file on windows

Disassembly:
mov qword [rsp + 0x18], rbp
mov qword [rsp + 0x20], rsi
push r14
sub rsp, 0x20
mov rbp, r8
mov r14, rdx
mov rsi, rcx
test r8, r8
jg 0x140006d41
xor eax, eax
mov rbp, qword [rsp + 0x40]
mov rsi, qword [rsp + 0x48]
add rsp, 0x20
pop r14
ret
cmp qword [rcx + 0x68], 0
je 0x140006d5f
mov rbp, qword [rsp + 0x40]
mov rsi, qword [rsp + 0x48]
add rsp, 0x20
pop r14
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 + 0x30], rbx
mov rbx, rbp
mov rdx, qword [rax]
test rdx, rdx
je 0x140006d7b
mov rax, qword [rcx + 0x50]
mov ecx, dword [rax]
jmp 0x140006d7d
xor ecx, ecx
movsxd rax, ecx
test ecx, ecx
je 0x140006db9
mov qword [rsp + 0x38], 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 + 0x38]
add qword [rcx], rax
cmp qword [rsi + 0x80], 0
je 0x140006e4e
mov r8, qword [rsi + 0x18]
lea rax, [rsi + 0x70]
cmp qword [r8], rax
jne 0x140006df4
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 0x140006e2e
nop dword [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 0x140006e4e
cmp rbx, rax
ja 0x140006e00
test rbx, rbx
je 0x140006e4e
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
mov rsi, qword [rsp + 0x48]
sub rbp, rbx
mov rbx, qword [rsp + 0x30]
mov rax, rbp
mov rbp, qword [rsp + 0x40]
add rsp, 0x20
pop r14
ret
Function at 0x1400072b0
Capabilities:
Write file on windows

Disassembly:
mov qword [rsp + 0x20], rbx
push rdi
sub rsp, 0x80
mov rax, qword [0x14003b040]
xor rax, rsp
mov qword [rsp + 0x78], rax
mov edi, edx
mov rbx, rcx
cmp edx, 0xffffffff
jne 0x1400072dd
xor eax, eax
jmp 0x140007449
mov rax, qword [rcx + 0x40]
mov rdx, qword [rax]
test rdx, rdx
je 0x140007317
mov rax, qword [rcx + 0x58]
movsxd r8, dword [rax]
lea rcx, [rdx + r8]
cmp rdx, rcx
jae 0x140007317
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 0x140007449
cmp qword [rbx + 0x80], 0
mov qword [rsp + 0xa0], rsi
je 0x14000743c
mov r8, qword [rbx + 0x18]
lea rax, [rbx + 0x70]
cmp qword [r8], rax
jne 0x14000735a
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 0x140007385
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 0x140007441
lea rax, [rsp + 0x48]
mov byte [rsp + 0x40], dil
mov qword [rsp + 0x38], rax
lea rdx, [rbx + 0x74]
lea rax, [rsp + 0x78]
mov qword [rsp + 0x30], rax
lea r9, [rsp + 0x41]
lea rax, [rsp + 0x58]
mov qword [rsp + 0x28], rax
lea r8, [rsp + 0x40]
lea rax, [rsp + 0x50]
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 0x1400073f4
sub eax, 1
je 0x1400073f4
cmp eax, 2
jne 0x14000743c
movsx ecx, byte [rsp + 0x40]
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 0x140007441
mov rsi, qword [rsp + 0x48]
lea rax, [rsp + 0x58]
sub rsi, rax
je 0x140007422
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 0x14000743c
lea rax, [rsp + 0x40]
mov byte [rbx + 0x71], 1
cmp qword [rsp + 0x50], rax
mov ecx, 0xffffffff
cmovne ecx, edi
mov eax, ecx
jmp 0x140007441
mov eax, 0xffffffff
mov rsi, qword [rsp + 0xa0]
mov rcx, qword [rsp + 0x78]
xor rcx, rsp
call fcn.140011000
mov rbx, qword [rsp + 0xa8]
add rsp, 0x80
pop rdi
ret