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

Disassembly:
mov qword [rsp + 8], rbx
mov qword [rsp + 0x10], rbp
mov qword [rsp + 0x18], rsi
push rdi
push r14
push r15
sub rsp, 0x20
movsxd rbp, r9d
mov rdi, r8
test r8, r8
je 0x180012d37
and dword [r8], 0
call fcn.180012e40
mov rbx, rax
test rax, rax
je 0x180012e23
xor edx, edx
mov rcx, rax
lea r8d, [rdx + 2]
call fcn.180037b60
test eax, eax
jne 0x180012e1b
mov rcx, rbx
call fcn.18003811c
movsxd r14, eax
cmp r14d, 0xffffffff
je 0x180012e1b
xor r8d, r8d
xor edx, edx
mov rcx, rbx
call fcn.180037b60
test eax, eax
jne 0x180012e1b
mov rcx, qword [0x180066470]
inc dword [rcx + 0x354]
mov rax, qword [0x180066470]
mov r8, qword [rax + 0xf0]
lea eax, [r14 + rbp]
movsxd rcx, eax
call r8
mov rsi, rax
test rax, rax
je 0x180012e1b
mov r9, rbx
mov r8, r14
mov edx, 1
mov rcx, rax
call fcn.180037828
cmp rax, r14
je 0x180012df4
mov rcx, rbx
call fcn.180037140
mov rax, qword [0x180066470]
mov rcx, rsi
dec dword [rax + 0x354]
mov rax, qword [0x180066470]
call qword [rax + 0xf8]
jmp 0x180012e23
test ebp, ebp
jle 0x180012e06
mov r8, rbp
lea rcx, [r14 + rsi]
xor edx, edx
call fcn.180050450
mov rcx, rbx
call fcn.180037140
test rdi, rdi
je 0x180012e16
mov dword [rdi], r14d
mov rax, rsi
jmp 0x180012e25
mov rcx, rbx
call fcn.180037140
xor eax, eax
mov rbx, qword [rsp + 0x40]
mov rbp, qword [rsp + 0x48]
mov rsi, qword [rsp + 0x50]
add rsp, 0x20
pop r15
pop r14
pop rdi
ret

Function at 0x18001301c
Capabilities:
Encode data using xor
Hash data with crc32

Disassembly:
mov qword [rsp + 8], rbx
mov qword [rsp + 0x10], rsi
mov qword [rsp + 0x18], rdi
cmp dword [0x18006b404], 0
lea rsi, [0x18006b400]
mov ebx, r8d
mov edi, edx
mov r10, rcx
jne 0x180013083
xor r9d, r9d
mov r11, rsi
mov r8d, r9d
mov edx, 8
mov ecx, r8d
mov eax, r8d
and ecx, 1
shr eax, 1
neg ecx
and ecx, 0xedb88320
mov r8d, ecx
xor r8d, eax
sub rdx, 1
jne 0x180013051
mov dword [r11], r8d
inc r9d
add r11, 4
cmp r9d, 0x100
jb 0x180013049
not ebx
mov edx, ebx
test edi, edi
jle 0x1800130a5
movzx eax, byte [r10]
inc r10
movzx ecx, dl
xor rcx, rax
shr edx, 8
xor edx, dword [rsi + rcx*4]
sub edi, 1
jne 0x18001308b
jmp 0x1800130df
mov r8b, byte [r10]
inc r10
test r8b, r8b
je 0x1800130df
mov r9b, 0x23
cmp r8b, r9b
jne 0x1800130c4
cmp byte [r10], r9b
jne 0x1800130c4
cmp byte [r10 + 1], r9b
cmove edx, ebx
movzx ecx, dl
movzx eax, r8b
mov r8b, byte [r10]
xor rcx, rax
shr edx, 8
inc r10
xor edx, dword [rsi + rcx*4]
test r8b, r8b
jne 0x1800130b3
mov rbx, qword [rsp + 8]
not edx
mov rsi, qword [rsp + 0x10]
mov eax, edx
mov rdi, qword [rsp + 0x18]
ret
Function at 0x180029d84
Capabilities:
Encrypt data using rc4 prga

Disassembly:
mov rax, rsp
mov qword [rax + 8], rbx
mov qword [rax + 0x10], rbp
mov qword [rax + 0x18], rsi
push rdi
push r12
push r13
push r14
push r15
sub rsp, 0x90
xor r14d, r14d
movaps xmmword [rax - 0x38], xmm6
movaps xmmword [rax - 0x48], xmm7
mov rsi, rdx
movsxd rdi, r9d
mov rbp, rcx
test r9d, r9d
jle 0x180029f75
lea rbx, [r8 + 0x20]
xor r13d, r13d
lea r8d, [r14 + 1]
mov r11d, 0x100
xorps xmm7, xmm7
movss xmm6, dword [rbx - 0x20]
comiss xmm6, xmm7
jbe 0x180029e26
movsxd r10, dword [rsi + 0x24]
mov r9, qword [rsi + 8]
movsx ecx, r11w
movzx eax, byte [r10 + r9 + 7]
movzx edx, byte [r10 + r9 + 6]
imul edx, ecx
movsx ecx, r11w
add dx, ax
movzx eax, byte [r10 + r9 + 5]
movsx r8d, dx
movzx edx, byte [r10 + r9 + 4]
imul edx, ecx
add ax, dx
cwde
sub eax, r8d
mov r8d, 1
movd xmm0, eax
jmp 0x180029e48
movsxd rdx, dword [rsi + 0x1c]
mov rax, qword [rsi + 8]
xorps xmm6, xmmword [0x180053410]
movzx ecx, byte [rdx + rax + 0x12]
movzx eax, byte [rdx + rax + 0x13]
shl ecx, 8
add ecx, eax
movd xmm0, ecx
mov al, byte [rbp + 0x20]
xor r15d, r15d
cvtdq2ps xmm0, xmm0
mov byte [rbx], al
mov al, byte [rbp + 0x24]
mov byte [rbx + 1], al
divss xmm6, xmm0
cmp dword [rbx - 0x10], r15d
jle 0x180029f68
mov rcx, qword [rsp + 0xe0]
mov rax, r13
shl rax, 4
add rcx, 6
xor r12d, r12d
add rcx, rax
mov qword [rsp + 0x60], rcx
mov rax, qword [rbx - 0x18]
test rax, rax
jne 0x180029e96
mov edx, dword [rbx - 0x1c]
add edx, r15d
jmp 0x180029e9a
mov edx, dword [rax + r12]
mov rcx, rsi
call fcn.1800294e8
mov edx, eax
xorps xmm3, xmm3
mov eax, dword [rbp + 0x24]
xorps xmm2, xmm2
mov rcx, rsi
cvtsi2ss xmm3, rax
mov eax, dword [rbp + 0x20]
cvtsi2ss xmm2, rax
lea rax, [rsp + 0x58]
mov qword [rsp + 0x48], rax
lea rax, [rsp + 0x50]
mov qword [rsp + 0x40], rax
lea rax, [rsp + 0x54]
mov qword [rsp + 0x38], rax
lea rax, [rsp + 0xd8]
mov qword [rsp + 0x30], rax
movss dword [rsp + 0x28], xmm7
mulss xmm3, xmm6
mulss xmm2, xmm6
movss dword [rsp + 0x20], xmm7
call fcn.180029920
mov rcx, qword [rsp + 0x60]
mov r8d, 1
movzx eax, word [rbp + 0x20]
add r14d, r8d
sub ax, word [rsp + 0xd8]
add r13, r8
add ax, word [rbp + 0x1c]
add r15d, r8d
add ax, word [rsp + 0x50]
add r12, 4
sub ax, r8w
mov word [rcx - 2], ax
movzx eax, word [rbp + 0x24]
sub ax, word [rsp + 0x54]
add ax, word [rbp + 0x1c]
add ax, word [rsp + 0x58]
sub ax, r8w
mov word [rcx], ax
add rcx, 0x10
mov qword [rsp + 0x60], rcx
cmp r15d, dword [rbx - 0x10]
jl 0x180029e85
mov r11d, 0x100
add rbx, 0x28
sub rdi, r8
jne 0x180029dd4
movaps xmm7, xmmword [rsp + 0x70]
lea r11, [rsp + 0x90]
mov rbx, qword [r11 + 0x30]
mov eax, r14d
mov rbp, qword [r11 + 0x38]
mov rsi, qword [r11 + 0x40]
movaps xmm6, xmmword [r11 - 0x10]
mov rsp, r11
pop r15
pop r14
pop r13
pop r12
pop rdi
ret
Function at 0x18002ab70
Capabilities:
Log keystrokes via polling

Disassembly:
mov qword [rsp + 0x18], rbx
push rbp
mov rbp, rsp
sub rsp, 0x30
cmp qword [0x18006b898], 0
jne 0x18002ab8c
call fcn.18002a558
call fcn.180012bc0
mov rcx, qword [0x18006b850]
lea rdx, [rbp - 0x10]
mov rbx, rax
call qword [sym.imp.USER32.dll_GetClientRect]
mov ecx, dword [rbp - 8]
sub ecx, dword [rbp - 0x10]
movd xmm1, ecx
mov ecx, dword [rbp - 4]
sub ecx, dword [rbp - 0xc]
cvtdq2ps xmm1, xmm1
movd xmm0, ecx
lea rcx, [rbp + 0x18]
cvtdq2ps xmm0, xmm0
movss dword [rbx], xmm1
movss dword [rbx + 4], xmm0
call qword [sym.imp.KERNEL32.dll_QueryPerformanceCounter]
mov rax, qword [rbp + 0x18]
xorps xmm1, xmm1
sub rax, qword [0x18006b840]
xorps xmm0, xmm0
cvtsi2ss xmm0, qword [0x18006b848]
mov ecx, 0x11
cvtsi2ss xmm1, rax
divss xmm1, xmm0
movss dword [rbx + 8], xmm1
mov rax, qword [rbp + 0x18]
mov qword [0x18006b840], rax
call qword [sym.imp.USER32.dll_GetKeyState]
shr eax, 0xf
mov ecx, 0x10
and al, 1
mov byte [rbx + 0x11d], al
call qword [sym.imp.USER32.dll_GetKeyState]
shr eax, 0xf
mov ecx, 0x12
and al, 1
mov byte [rbx + 0x11e], al
call qword [sym.imp.USER32.dll_GetKeyState]
shr eax, 0xf
and al, 1
mov byte [rbx + 0x120], 0
cmp byte [rbx + 0x347], 0
mov byte [rbx + 0x11f], al
je 0x18002ac8a
cvttss2si eax, dword [rbx + 0x108]
mov rcx, qword [0x18006b850]
lea rdx, [rbp + 0x10]
mov dword [rbp + 0x10], eax
cvttss2si eax, dword [rbx + 0x10c]
mov dword [rbp + 0x14], eax
call qword [sym.imp.USER32.dll_ClientToScreen]
mov edx, dword [rbp + 0x14]
mov ecx, dword [rbp + 0x10]
call qword [sym.imp.USER32.dll_SetCursorPos]
cmp byte [rbx + 0x11c], 0
je 0x18002ac9b
xor ecx, ecx
call qword [sym.imp.USER32.dll_SetCursor]
call fcn.180016a40
mov rbx, qword [rsp + 0x50]
add rsp, 0x30
pop rbp
ret
Function at 0x18002b96c
Capabilities:
Allocate or change rwx memory
Get system information on windows

Disassembly:
mov qword [rsp + 8], rbx
mov qword [rsp + 0x10], rsi
mov qword [rsp + 0x18], rdi
push rbp
push r12
push r13
push r14
push r15
mov rbp, rsp
sub rsp, 0x80
mov rdi, rcx
lea rcx, [rbp - 0x60]
call qword [sym.imp.KERNEL32.dll_GetSystemInfo]
mov r14, qword [rbp - 0x58]
cmp rdi, 0x40000000
jbe 0x18002b9b6
lea rax, [rdi - 0x40000000]
cmp r14, rax
cmovb r14, rax
mov rbx, qword [0x18006cab0]
lea r12, [rdi + 0x40000000]
cmp qword [rbp - 0x50], r12
cmovbe r12, qword [rbp - 0x50]
sub r12, 0xfff
xor esi, esi
jmp 0x18002b9ef
cmp rbx, r14
jb 0x18002b9ec
cmp rbx, r12
jae 0x18002b9ec
cmp qword [rbx + 8], rsi
jne 0x18002bb51
mov rbx, qword [rbx]
test rbx, rbx
jne 0x18002b9d8
mov r15, rdi
cmp rdi, r14
jb 0x18002bb0b
mov r13d, dword [rbp - 0x38]
xor edx, edx
mov rax, r15
div r13
sub r15, rdx
jmp 0x18002ba3b
mov r8d, 0x30
lea rdx, [rbp - 0x30]
mov rcx, r15
call qword [sym.imp.KERNEL32.dll_VirtualQuery]
test rax, rax
je 0x18002ba75
cmp dword [rbp - 0x10], 0x10000
je 0x18002ba45
mov r15, qword [rbp - 0x28]
cmp r15, r13
jb 0x18002ba75
sub r15, r13
cmp r15, r14
jae 0x18002ba11
jmp 0x18002ba75
test r15, r15
je 0x18002ba75
mov edx, 0x1000
mov r9d, 0x40
mov r8d, 0x3000
mov rcx, r15
call qword [sym.imp.KERNEL32.dll_VirtualAlloc]
mov rbx, rax
test rax, rax
jne 0x18002bb16
cmp r15, r14
jae 0x18002ba00
test rbx, rbx
jmp 0x18002bb09
mov r15d, dword [rbp - 0x38]
xor edx, edx
mov rax, rdi
mov r14d, r15d
div r15
mov eax, r15d
sub rax, rdx
add rax, rdi
mov rdi, rax
cmp rax, r12
ja 0x18002bb51
mov r8d, 0x30
lea rdx, [rbp - 0x30]
mov rcx, rdi
call qword [sym.imp.KERNEL32.dll_VirtualQuery]
test rax, rax
je 0x18002bb51
cmp dword [rbp - 0x10], 0x10000
je 0x18002bae4
xor edx, edx
lea edi, [r15 - 1]
add rdi, qword [rbp - 0x18]
add rdi, qword [rbp - 0x30]
mov rax, rdi
div r14
sub rdi, rdx
cmp rdi, r12
jbe 0x18002baa1
jmp 0x18002bb51
test rdi, rdi
je 0x18002bb51
mov edx, 0x1000
mov r9d, 0x40
mov r8d, 0x3000
mov rcx, rdi
call qword [sym.imp.KERNEL32.dll_VirtualAlloc]
mov rbx, rax
test rax, rax
jne 0x18002bb16
cmp rdi, r12
jbe 0x18002ba7d
jmp 0x18002bb51
lea rcx, [rbx + 0x40]
mov dword [rbx + 0x10], esi
mov edx, 0x40
mov qword [rcx], rsi
mov rax, rcx
mov qword [rbx + 8], rcx
add rdx, 0x40
add rcx, 0x40
mov rsi, rax
cmp rdx, 0xfc0
jbe 0x18002bb22
mov rax, qword [0x18006cab0]
mov qword [rbx], rax
mov qword [0x18006cab0], rbx
lea r11, [rsp + 0x80]
mov rax, rbx
mov rbx, qword [r11 + 0x30]
mov rsi, qword [r11 + 0x38]
mov rdi, qword [r11 + 0x40]
mov rsp, r11
pop r15
pop r14
pop r13
pop r12
pop rbp
ret
Function at 0x18002c490
Capabilities:
Allocate or change rwx memory

Disassembly:
mov r11, rsp
mov qword [r11 + 0x10], rbx
mov qword [r11 + 0x18], rbp
mov qword [r11 + 0x20], rsi
push rdi
sub rsp, 0x20
mov eax, ecx
lea r9, [r11 + 8]
imul rbx, rax, 0x38
mov esi, edx
add rbx, qword [0x18006caa0]
mov r8, qword [rbx]
mov al, byte [rbx + 0x20]
and al, 1
movzx ecx, al
lea rdi, [r8 - 5]
cmove rdi, r8
mov r8d, 0x40
lea rbp, [rcx*2 + 5]
mov rcx, rdi
mov rdx, rbp
call qword [sym.imp.KERNEL32.dll_VirtualProtect]
test eax, eax
jne 0x18002c4f2
mov eax, 0xa
jmp 0x18002c57e
test esi, esi
je 0x18002c514
mov byte [rdi], 0xe9
mov eax, dword [rbx + 8]
sub eax, edi
sub eax, 5
mov dword [rdi + 1], eax
test byte [rbx + 0x20], 1
je 0x18002c532
mov rax, qword [rbx]
mov word [rax], 0xf9eb
jmp 0x18002c532
test byte [rbx + 0x20], 1
lea rdx, [rbx + 0x18]
mov rcx, rdi
mov r8d, 7
jne 0x18002c52d
mov r8d, 5
call fcn.18004fdb0
mov r8d, dword [rsp + 0x30]
lea r9, [rsp + 0x30]
mov rdx, rbp
mov rcx, rdi
call qword [sym.imp.KERNEL32.dll_VirtualProtect]
call qword [sym.imp.KERNEL32.dll_GetCurrentProcess]
mov r8, rbp
mov rdx, rdi
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_FlushInstructionCache]
mov al, sil
shl sil, 2
add al, al
xor al, byte [rbx + 0x20]
and al, 2
xor al, byte [rbx + 0x20]
xor sil, al
and sil, 4
xor sil, al
mov byte [rbx + 0x20], sil
xor eax, eax
mov rbx, qword [rsp + 0x38]
mov rbp, qword [rsp + 0x40]
mov rsi, qword [rsp + 0x48]
add rsp, 0x20
pop rdi
ret
Function at 0x18002c5d4
Capabilities:
Enumerate threads
Suspend thread

Disassembly:
mov qword [rsp + 8], rbx
mov qword [rsp + 0x10], rbp
mov qword [rsp + 0x18], rsi
push rdi
push r14
push r15
sub rsp, 0x40
xor ebx, ebx
mov r15d, edx
mov rdi, rcx
mov qword [rcx], rbx
mov qword [rcx + 8], rbx
xor edx, edx
mov r14d, r8d
mov esi, ebx
lea ecx, [rbx + 4]
call sub.KERNEL32.dll_CreateToolhelp32Snapshot
mov rbp, rax
cmp rax, 0xffffffffffffffff
je 0x18002c769
lea rdx, [rsp + 0x20]
mov dword [rsp + 0x20], 0x1c
mov rcx, rax
call sub.KERNEL32.dll_Thread32First
test eax, eax
je 0x18002c70b
lea esi, [rbx + 1]
cmp dword [rsp + 0x20], 0x10
jb 0x18002c6c7
call qword [sym.imp.KERNEL32.dll_GetCurrentProcessId]
cmp dword [rsp + 0x2c], eax
jne 0x18002c6c7
call qword [sym.imp.KERNEL32.dll_GetCurrentThreadId]
cmp dword [rsp + 0x28], eax
je 0x18002c6c7
mov rdx, qword [rdi]
test rdx, rdx
jne 0x18002c689
mov dword [rdi + 8], 0x80
mov r8d, 0x200
mov rcx, qword [0x18006b8c8]
call qword [sym.imp.KERNEL32.dll_HeapAlloc]
mov qword [rdi], rax
mov rdx, rax
test rax, rax
je 0x18002c6ef
jmp 0x18002c6ba
mov eax, dword [rdi + 8]
cmp dword [rdi + 0xc], eax
jb 0x18002c6ba
add eax, eax
mov r8, rdx
mov r9d, eax
xor edx, edx
mov dword [rdi + 8], eax
mov rcx, qword [0x18006b8c8]
shl r9, 2
call qword [sym.imp.KERNEL32.dll_HeapReAlloc]
mov rdx, rax
test rax, rax
je 0x18002c6ef
mov qword [rdi], rax
mov ecx, dword [rdi + 0xc]
mov eax, dword [rsp + 0x28]
mov dword [rdx + rcx*4], eax
inc dword [rdi + 0xc]
lea rdx, [rsp + 0x20]
mov dword [rsp + 0x20], 0x1c
mov rcx, rbp
call sub.KERNEL32.dll_Thread32Next
test eax, eax
jne 0x18002c637
call qword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 0x12
je 0x18002c70b
mov esi, ebx
cmp qword [rdi], rbx
je 0x18002c70b
mov r8, qword [rdi]
xor edx, edx
mov rcx, qword [0x18006b8c8]
call qword [sym.imp.KERNEL32.dll_HeapFree]
mov qword [rdi], rbx
mov rcx, rbp
call qword [sym.imp.KERNEL32.dll_CloseHandle]
test esi, esi
je 0x18002c769
cmp qword [rdi], rbx
je 0x18002c76e
mov esi, ebx
cmp dword [rdi + 0xc], ebx
jbe 0x18002c76e
mov r8, qword [rdi]
xor edx, edx
mov eax, esi
lea ecx, [rdx + 0x5a]
mov r8d, dword [r8 + rax*4]
call qword [sym.imp.KERNEL32.dll_OpenThread]
mov rbp, rax
test rax, rax
je 0x18002c760
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_SuspendThread]
mov r8d, r14d
mov edx, r15d
mov rcx, rbp
call fcn.18002c9a8
mov rcx, rbp
call qword [sym.imp.KERNEL32.dll_CloseHandle]
inc esi
cmp esi, dword [rdi + 0xc]
jb 0x18002c724
jmp 0x18002c76e
mov ebx, 9
mov rbp, qword [rsp + 0x68]
mov eax, ebx
mov rbx, qword [rsp + 0x60]
mov rsi, qword [rsp + 0x70]
add rsp, 0x40
pop r15
pop r14
pop rdi
ret
Function at 0x18002cb18
Capabilities:
Resume thread

Disassembly:
mov qword [rsp + 8], rbx
mov qword [rsp + 0x10], rsi
push rdi
sub rsp, 0x20
cmp qword [rcx], 0
mov rbx, rcx
je 0x18002cb7c
xor edi, edi
cmp dword [rcx + 0xc], edi
jbe 0x18002cb6a
mov r8, qword [rbx]
xor edx, edx
mov r8d, dword [r8 + rdi*4]
lea ecx, [rdx + 0x5a]
call qword [sym.imp.KERNEL32.dll_OpenThread]
mov rsi, rax
test rax, rax
je 0x18002cb63
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_ResumeThread]
mov rcx, rsi
call qword [sym.imp.KERNEL32.dll_CloseHandle]
inc edi
cmp edi, dword [rbx + 0xc]
jb 0x18002cb37
mov r8, qword [rbx]
xor edx, edx
mov rcx, qword [0x18006b8c8]
call qword [sym.imp.KERNEL32.dll_HeapFree]
mov rbx, qword [rsp + 0x30]
mov rsi, qword [rsp + 0x38]
add rsp, 0x20
pop rdi
ret
Function at 0x18002cec4
Capabilities:
Check for software breakpoints

Disassembly:
mov r8b, byte [rcx]
mov r9d, edx
test r8b, r8b
je 0x18002cedb
cmp r8b, 0x90
je 0x18002cedb
cmp r8b, 0xcc
jne 0x18002cefd
mov r10d, 1
mov edx, r10d
cmp r9d, r10d
jbe 0x18002cef9
mov eax, edx
cmp byte [rax + rcx], r8b
jne 0x18002cefd
add edx, r10d
cmp edx, r9d
jb 0x18002cee9
mov eax, r10d
ret
xor eax, eax
ret

Function at 0x180037f38
Capabilities:
Read file on windows

Disassembly:
mov qword [rsp + 8], rbx
push rbp
push rsi
push rdi
push r12
push r13
push r14
push r15
mov eax, 0x1050
call fcn.18002d5b0
sub rsp, rax
mov rax, qword [0x180066e00]
xor rax, rsp
mov qword [rsp + 0x1040], rax
mov r15, r8
mov rbp, rdx
mov rbx, rcx
call fcn.18004470c
xor edi, edi
movsxd r14, eax
cmp dword [rbx + 0x10], edi
jne 0x180037f87
mov rax, rbp
jmp 0x18003808f
mov rax, qword [rbx]
mov rcx, r14
sub rax, qword [rbx + 8]
and ecx, 0x3f
cqo
mov rbx, r14
sub rax, rdx
sar rbx, 6
sar rax, 1
mov r9, r15
lea r12, [rcx + rcx*8]
mov rsi, rax
lea rax, [0x180000000]
xor r8d, r8d
mov rdx, qword [rax + rbx*8 + 0x6be20]
mov ecx, r14d
mov rdx, qword [rdx + r12*8 + 0x30]
call fcn.180046640
mov r13, rax
lea rax, [0x180000000]
mov rcx, qword [rax + rbx*8 + 0x6be20]
cmp r13, qword [rcx + r12*8 + 0x30]
jne 0x18003808b
mov rcx, qword [rcx + r12*8 + 0x28]
lea r9, [rsp + 0x30]
mov r8d, 0x1000
mov qword [rsp + 0x20], rdi
lea rdx, [rsp + 0x40]
call qword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
je 0x18003808b
mov r9, r15
xor r8d, r8d
mov rdx, rbp
mov ecx, r14d
call fcn.180046640
test rax, rax
js 0x18003808b
mov eax, dword [rsp + 0x30]
cmp rsi, rax
jg 0x18003808b
lea rdx, [rsp + 0x40]
add rdx, rax
lea rcx, [rsp + 0x40]
test rsi, rsi
je 0x18003807d
lea r8, [0x180000000]
cmp rcx, rdx
jae 0x18003807d
cmp byte [rcx], 0xd
jne 0x180038063
lea rax, [rdx - 1]
cmp rcx, rax
jae 0x180038072
cmp byte [rcx + 1], 0xa
jne 0x180038072
inc rcx
jmp 0x180038072
movzx eax, byte [rcx]
movsx rax, byte [rax + r8 + 0x67160]
add rcx, rax
inc rdi
inc rcx
cmp rdi, rsi
jne 0x180038045
lea rax, [rsp + 0x40]
sub rcx, rax
lea rax, [rcx + r13]
jmp 0x18003808f
or rax, 0xffffffffffffffff
mov rcx, qword [rsp + 0x1040]
xor rcx, rsp
call fcn.18004f720
mov rbx, qword [rsp + 0x1090]
add rsp, 0x1050
pop r15
pop r14
pop r13
pop r12
pop rdi
pop rsi
pop rbp
ret
Function at 0x180045878
Capabilities:
Read file on windows

Disassembly:
mov qword [rsp + 0x20], rbx
push rbp
push rsi
push rdi
push r12
push r13
push r14
push r15
sub rsp, 0x30
movsxd r15, ecx
lea r9, [0x18006be20]
mov rax, r15
mov rbp, r15
and eax, 0x3f
sar rbp, 6
mov ecx, 4
xor esi, esi
mov r14, rdx
lea rdi, [rax + rax*8]
mov rax, qword [r9 + rbp*8]
lea r13d, [rcx + 6]
mov r10, qword [rax + rdi*8 + 0x28]
test r8, r8
je 0x1800458cf
cmp word [rdx], r13w
jne 0x1800458cf
or byte [rax + rdi*8 + 0x38], cl
jmp 0x1800458d4
and byte [rax + rdi*8 + 0x38], 0xfb
lea r8, [rdx + r8*2]
mov rbx, r14
cmp r14, r8
jae 0x1800459f9
mov r11d, 0xd
lea r12d, [r11 - 0xb]
movzx ecx, word [rdx]
cmp cx, 0x1a
je 0x180045a1a
lea r9, [rdx + 2]
cmp cx, r11w
je 0x18004590d
mov rdx, r9
mov word [rbx], cx
jmp 0x180045934
cmp r9, r8
jae 0x180045944
cmp word [r9], r13w
mov rax, r12
mov ecx, 4
cmove rax, rcx
add rdx, rax
mov eax, r13d
cmp word [r9], r13w
cmovne ax, r11w
mov word [rbx], ax
mov rax, r12
add rbx, rax
cmp rdx, r8
jb 0x1800458ee
jmp 0x1800459f9
lea r9, [rsp + 0x80]
mov qword [rsp + 0x20], rsi
mov r8d, r12d
lea rdx, [rsp + 0x70]
mov rcx, r10
call qword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
je 0x1800459ee
cmp dword [rsp + 0x80], esi
je 0x1800459ee
lea r8, [0x18006be20]
mov rax, qword [r8 + rbp*8]
test byte [rax + rdi*8 + 0x38], 0x48
je 0x1800459c6
movzx eax, word [rsp + 0x70]
cmp ax, r13w
jne 0x180045996
mov word [rbx], r13w
jmp 0x1800459f6
mov ecx, 0xd
mov word [rsp + 0x78], ax
mov word [rbx], cx
mov rax, qword [r8 + rbp*8]
lea rcx, [rax + rdi*8]
mov al, byte [rsp + rsi + 0x78]
mov byte [rcx + rsi + 0x3a], al
inc rsi
cmp rsi, r12
jl 0x1800459a3
mov rax, qword [r8 + rbp*8]
mov byte [rax + rdi*8 + 0x3c], r13b
jmp 0x1800459f6
cmp word [rsp + 0x70], r13w
jne 0x1800459d3
cmp rbx, r14
je 0x180045990
mov rdx, 0xfffffffffffffffe
mov ecx, r15d
lea r8d, [rdx + 3]
call fcn.180046648
cmp word [rsp + 0x70], r13w
je 0x1800459f9
mov ecx, 0xd
mov word [rbx], cx
add rbx, r12
sub rbx, r14
sar rbx, 1
lea eax, [rbx + rbx]
mov rbx, qword [rsp + 0x88]
add rsp, 0x30
pop r15
pop r14
pop r13
pop r12
pop rdi
pop rsi
pop rbp
ret
lea r8, [0x18006be20]
mov rdx, qword [r8 + rbp*8]
mov al, byte [rdx + rdi*8 + 0x38]
test al, 0x40
jne 0x1800459f3
or al, r12b
mov byte [rdx + rdi*8 + 0x38], al
jmp 0x1800459f9
Function at 0x180049b70
Capabilities:
Query environment variable

Disassembly:
mov rax, rsp
mov qword [rax + 8], rbx
mov qword [rax + 0x10], rbp
mov qword [rax + 0x18], rsi
mov qword [rax + 0x20], rdi
push r14
sub rsp, 0x40
call qword [sym.imp.KERNEL32.dll_GetEnvironmentStringsW]
xor esi, esi
mov rbx, rax
test rax, rax
jne 0x180049ba0
xor eax, eax
jmp 0x180049c63
mov rbp, rbx
cmp word [rax], si
je 0x180049bc5
or rax, 0xffffffffffffffff
inc rax
cmp word [rbp + rax*2], si
jne 0x180049bac
lea rbp, [rbp + rax*2]
add rbp, 2
cmp word [rbp], si
jne 0x180049ba8
mov qword [rsp + 0x38], rsi
sub rbp, rbx
mov qword [rsp + 0x30], rsi
add rbp, 2
sar rbp, 1
mov r8, rbx
mov r9d, ebp
mov dword [rsp + 0x28], esi
xor edx, edx
mov qword [rsp + 0x20], rsi
xor ecx, ecx
call fcn.180049a90
movsxd r14, eax
test eax, eax
jne 0x180049c03
mov rcx, rbx
call qword [sym.imp.KERNEL32.dll_FreeEnvironmentStringsW]
jmp 0x180049b99
mov rcx, r14
call fcn.1800466ec
mov rdi, rax
test rax, rax
jne 0x180049c1c
xor ecx, ecx
call fcn.180042d60
jmp 0x180049bf8
mov qword [rsp + 0x38], rsi
mov r9d, ebp
mov qword [rsp + 0x30], rsi
mov r8, rbx
mov dword [rsp + 0x28], r14d
xor edx, edx
xor ecx, ecx
mov qword [rsp + 0x20], rdi
call fcn.180049a90
test eax, eax
jne 0x180049c4d
mov rcx, rdi
call fcn.180042d60
jmp 0x180049c57
xor ecx, ecx
call fcn.180042d60
mov rsi, rdi
mov rcx, rbx
call qword [sym.imp.KERNEL32.dll_FreeEnvironmentStringsW]
mov rax, rsi
mov rbx, qword [rsp + 0x50]
mov rbp, qword [rsp + 0x58]
mov rsi, qword [rsp + 0x60]
mov rdi, qword [rsp + 0x68]
add rsp, 0x40
pop r14
ret

Function at 0x18004d8b8
Capabilities:
Get file size

Disassembly:
push rbx
sub rsp, 0x20
mov edx, dword [rcx + 0x14]
nop
shr edx, 3
test dl, 1
je 0x18004d8ce
mov al, 1
jmp 0x18004d92e
mov eax, dword [rcx + 0x14]
nop
test al, 0xc0
je 0x18004d8df
mov rax, qword [rcx + 8]
cmp qword [rcx], rax
je 0x18004d92c
mov ecx, dword [rcx + 0x18]
nop
call fcn.18004af3c
mov rbx, rax
cmp rax, 0xffffffffffffffff
je 0x18004d92c
mov r9d, 1
lea r8, [rsp + 0x38]
xor edx, edx
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_SetFilePointerEx]
test eax, eax
je 0x18004d92c
lea rdx, [rsp + 0x30]
mov rcx, rbx
call qword [sym.imp.KERNEL32.dll_GetFileSizeEx]
test eax, eax
je 0x18004d92c
mov rax, qword [rsp + 0x30]
cmp qword [rsp + 0x38], rax
sete al
jmp 0x18004d92e
xor al, al
add rsp, 0x20
pop rbx
ret
Function at 0x18004e67c
Capabilities:
Clear file content

Disassembly:
mov rax, rsp
mov qword [rax + 8], rbx
mov qword [rax + 0x10], rbp
mov qword [rax + 0x18], rsi
mov qword [rax + 0x20], rdi
push r12
push r14
push r15
sub rsp, 0x20
mov rbx, rdx
mov rsi, r8
xor edx, edx
mov r14d, ecx
lea r8d, [rdx + 1]
call fcn.180046648
xor edx, edx
mov ecx, r14d
mov r12, rax
lea r8d, [rdx + 2]
call fcn.180046648
mov rbp, rbx
sub rbp, rax
cmp r12, 0xffffffffffffffff
je 0x18004e7cc
cmp rax, 0xffffffffffffffff
je 0x18004e7cc
xor edi, edi
test rbp, rbp
jle 0x18004e777
lea edx, [rdi + 1]
mov ecx, 0x1000
call fcn.180042ce8
mov rbx, rax
test rax, rax
jne 0x18004e704
lea edi, [rax + 0xc]
mov byte [rsi + 0x30], 1
mov dword [rsi + 0x2c], edi
jmp 0x18004e76d
mov edx, 0x8000
mov ecx, r14d
call fcn.18004e500
mov r15d, eax
mov eax, 0x1000
mov r8d, ebp
cmp rbp, rax
mov r9, rsi
mov rdx, rbx
mov ecx, r14d
cmovge r8d, eax
call fcn.180045570
cmp eax, 0xffffffff
je 0x18004e74d
cdqe
sub rbp, rax
test rbp, rbp
jg 0x18004e714
mov edx, r15d
mov ecx, r14d
call fcn.18004e500
jmp 0x18004e76d
cmp byte [rsi + 0x38], dil
je 0x18004e764
cmp dword [rsi + 0x34], 5
jne 0x18004e764
mov byte [rsi + 0x30], 1
mov dword [rsi + 0x2c], 0xd
cmp byte [rsi + 0x30], dil
je 0x18004e76d
mov edi, dword [rsi + 0x2c]
mov rcx, rbx
call fcn.180042d60
jmp 0x18004e7e0
jns 0x18004e7e0
xor r8d, r8d
mov rdx, rbx
mov ecx, r14d
call fcn.180046648
cmp rax, 0xffffffffffffffff
jne 0x18004e798
cmp byte [rsi + 0x30], dil
je 0x18004e7e0
mov edi, dword [rsi + 0x2c]
jmp 0x18004e7e0
mov ecx, r14d
call fcn.18004af3c
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_SetEndOfFile]
test eax, eax
jne 0x18004e7e0
call qword [sym.imp.KERNEL32.dll_GetLastError]
mov byte [rsi + 0x38], 1
mov edi, 0xd
mov dword [rsi + 0x34], eax
mov byte [rsi + 0x30], 1
mov dword [rsi + 0x2c], 0xd
jmp 0x18004e7e0
xor edi, edi
cmp byte [rsi + 0x30], dil
je 0x18004e7d9
mov eax, dword [rsi + 0x2c]
jmp 0x18004e7de
mov eax, 0x16
mov edi, eax
xor r8d, r8d
mov rdx, r12
mov ecx, r14d
call fcn.180046648
mov rbx, qword [rsp + 0x40]
mov eax, edi
mov rdi, qword [rsp + 0x58]
mov rbp, qword [rsp + 0x48]
mov rsi, qword [rsp + 0x50]
add rsp, 0x20
pop r15
pop r14
pop r12
ret

Function at 0x18004f7e0
Capabilities:
Parse pe header

Disassembly:
mov eax, 0x5a4d
cmp word [rcx], ax
jne 0x18004f808
movsxd rdx, dword [rcx + 0x3c]
add rdx, rcx
cmp dword [rdx], 0x4550
jne 0x18004f808
xor eax, eax
mov ecx, 0x20b
cmp word [rdx + 0x18], cx
sete al
ret
xor eax, eax
ret