joyce8/EMBER2024-capa huggingface dataset:
Function at 0x1400222d0
Capabilities:
Query or enumerate registry value

Disassembly:
mov qword [rsp + 0x20], rbx
push rbp
push rsi
push rdi
lea rbp, [rsp - 0x5a0]
sub rsp, 0x6a0
mov rax, qword [0x140070070]
xor rax, rsp
mov qword [rbp + 0x590], rax
mov rdi, rdx
mov rsi, rcx
test r8, r8
je 0x1400223c1
mov rdx, r8
lea rcx, [rsp + 0x50]
call fcn.1400224ec
lea rcx, [rsp + 0x38]
mov qword [rsp + 0x20], rcx
mov r9d, 0x20019
xor r8d, r8d
mov rdx, qword [rax]
mov rcx, 0xffffffff80000001
call qword [sym.imp.ADVAPI32.dll_RegOpenKeyExW]
mov ebx, eax
mov rdx, qword [rsp + 0x50]
add rdx, 0xffffffffffffffe8
or ecx, 0xffffffff
lock xadd dword [rdx + 0x10], ecx
sub ecx, 1
jg 0x140022359
mov rcx, qword [rdx]
mov r8, qword [rcx]
call qword [r8 + 8]
test ebx, ebx
jne 0x1400223c1
xor edx, edx
mov r8d, 0x412
lea rcx, [rbp + 0x170]
call fcn.14002dc80
mov ebx, 1
mov dword [rsp + 0x34], ebx
mov dword [rsp + 0x30], 0x208
lea rax, [rsp + 0x30]
mov qword [rsp + 0x28], rax
lea rax, [rbp + 0x170]
mov qword [rsp + 0x20], rax
lea r9, [rsp + 0x34]
xor r8d, r8d
lea rdx, str.InstallDir
mov rcx, qword [rsp + 0x38]
call qword [sym.imp.ADVAPI32.dll_RegQueryValueExW]
test eax, eax
je 0x1400223e5
mov rcx, qword [rsp + 0x38]
call qword [sym.imp.ADVAPI32.dll_RegCloseKey]
xor eax, eax
mov rcx, qword [rbp + 0x590]
xor rcx, rsp
call fcn.14002b930
mov rbx, qword [rsp + 0x6d8]
add rsp, 0x6a0
pop rdi
pop rsi
pop rbp
ret
lea rdx, [rbp + 0x170]
lea rcx, [rsp + 0x40]
call fcn.14000d338
nop
lea rdx, [0x140060fac]
lea rcx, [rsp + 0x48]
call fcn.14000d338
nop
mov r8, rsi
lea rdx, [rsp + 0x48]
lea rcx, [rsp + 0x40]
call fcn.1400257a8
xor edx, edx
mov r8d, 0x20a
lea rcx, [rsp + 0x60]
call fcn.14002dc80
mov dword [rsp + 0x34], ebx
mov dword [rsp + 0x30], 0x104
lea rax, [rsp + 0x30]
mov qword [rsp + 0x28], rax
lea rax, [rsp + 0x60]
mov qword [rsp + 0x20], rax
lea r9, [rsp + 0x34]
xor r8d, r8d
lea rdx, str.ExcDir
mov rcx, qword [rsp + 0x38]
call qword [sym.imp.ADVAPI32.dll_RegQueryValueExW]
test eax, eax
jne 0x140022499
lea rcx, [rsp + 0x60]
call fcn.140032038
mov r8d, eax
lea rdx, [rsp + 0x60]
lea rcx, [rsp + 0x40]
call fcn.1400060fc
mov r8, rdi
lea rdx, [rsp + 0x48]
lea rcx, [rsp + 0x40]
call fcn.1400257a8
mov rcx, qword [rsp + 0x38]
call qword [sym.imp.ADVAPI32.dll_RegCloseKey]
nop
mov rdx, qword [rsp + 0x48]
add rdx, 0xffffffffffffffe8
or eax, 0xffffffff
lock xadd dword [rdx + 0x10], eax
sub eax, 1
jg 0x1400224c5
mov rcx, qword [rdx]
mov rax, qword [rcx]
call qword [rax + 8]
nop
mov rdx, qword [rsp + 0x40]
add rdx, 0xffffffffffffffe8
or ecx, 0xffffffff
lock xadd dword [rdx + 0x10], ecx
sub ecx, 1
jg 0x1400224e5
mov rcx, qword [rdx]
mov r8, qword [rcx]
call qword [r8 + 8]
mov eax, ebx
jmp 0x1400223c3
Function at 0x140022544
Capabilities:
Check if file exists
Read .ini file

Disassembly:
mov qword [rsp + 0x20], rbx
mov qword [rsp + 0x10], rdx
push rbp
push rsi
push rdi
mov rbp, rsp
sub rsp, 0x40
mov rdi, rcx
test rcx, rcx
je 0x1400226ce
lea rcx, [rbp + 0x20]
call fcn.140020508
nop
lea r8, str.BREvent.ini
lea rdx, [rbp + 0x20]
lea rcx, [rbp + 0x28]
call fcn.14000ceb0
nop
mov rcx, qword [rbp + 0x28]
call qword [sym.imp.SHLWAPI.dll_PathFileExistsW]
test eax, eax
jne 0x1400225da
and qword [rsp + 0x30], 0
and dword [rsp + 0x28], eax
mov dword [rsp + 0x20], 2
xor r9d, r9d
mov edx, 0x40000000
lea r8d, [rax + 3]
mov rcx, qword [rbp + 0x28]
call qword [sym.imp.KERNEL32.dll_CreateFileW]
cmp rax, 0xffffffffffffffff
jne 0x1400225d1
call qword [sym.imp.KERNEL32.dll_GetLastError]
lea rdx, str._AddEventLog__create_file___s__failed___ld_
jmp 0x140022677
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_CloseHandle]
mov r9, qword [rbp + 0x28]
xor r8d, r8d
lea rdx, str.CrashCount
mov rcx, rdi
call qword [sym.imp.KERNEL32.dll_GetPrivateProfileIntW]
mov esi, 1
lea ebx, [rsi + rax]
mov dword [rsp + 0x20], ebx
lea r9, str.CrashCount
mov r8, rdi
lea rdx, str._s:_s_lu
lea rcx, [0x14005f708]
call fcn.140025b7c
mov r8d, ebx
lea rdx, [0x140061230]
lea rcx, [rbp + 0x30]
call fcn.1400219a0
mov r9, qword [rbp + 0x28]
mov r8, qword [rax]
lea rdx, str.CrashCount
mov rcx, rdi
call qword [sym.imp.KERNEL32.dll_WritePrivateProfileStringW]
test eax, eax
sete bl
mov rdx, qword [rbp + 0x30]
add rdx, 0xffffffffffffffe8
or eax, 0xffffffff
lock xadd dword [rdx + 0x10], eax
sub eax, esi
jg 0x140022666
mov rcx, qword [rdx]
mov rax, qword [rcx]
call qword [rax + 8]
test bl, bl
je 0x14002268c
call qword [sym.imp.KERNEL32.dll_GetLastError]
lea rdx, str._AddEventLog__write_file___s__failed___ld_
mov r9d, eax
mov r8, qword [rbp + 0x28]
lea rcx, [0x14005f708]
call fcn.140025b7c
xor esi, esi
mov rdx, qword [rbp + 0x28]
add rdx, 0xffffffffffffffe8
or eax, 0xffffffff
lock xadd dword [rdx + 0x10], eax
sub eax, 1
jg 0x1400226ab
mov rcx, qword [rdx]
mov rax, qword [rcx]
call qword [rax + 8]
nop
mov rdx, qword [rbp + 0x20]
add rdx, 0xffffffffffffffe8
or ecx, 0xffffffff
lock xadd dword [rdx + 0x10], ecx
sub ecx, 1
jg 0x1400226ca
mov rcx, qword [rdx]
mov r8, qword [rcx]
call qword [r8 + 8]
mov eax, esi
jmp 0x1400226d0
xor eax, eax
mov rbx, qword [rsp + 0x78]
add rsp, 0x40
pop rdi
pop rsi
pop rbp
ret
Function at 0x1400226e0
Capabilities:
Check if file exists

Disassembly:
mov qword [rsp + 0x10], rbx
push rdi
sub rsp, 0x250
mov rax, qword [0x140070070]
xor rax, rsp
mov qword [rsp + 0x240], rax
mov rbx, rcx
mov qword [rsp + 0x28], rcx
xor edi, edi
mov dword [rsp + 0x20], edi
xor edx, edx
mov r8d, 0x208
lea rcx, [rsp + 0x30]
call fcn.14002dc80
mov r8d, 0x104
lea rdx, [rsp + 0x30]
xor ecx, ecx
call qword [sym.imp.KERNEL32.dll_GetModuleFileNameW]
lea edx, [rdi + 0x5c]
lea rcx, [rsp + 0x30]
call fcn.14002de38
test rax, rax
je 0x140022747
mov word [rax], di
call fcn.1400064a8
mov rcx, rax
test rax, rax
je 0x140022878
mov rax, qword [rax]
call qword [rax + 0x18]
add rax, 0x18
mov qword [rbx], rax
mov dword [rsp + 0x20], 1
lea rcx, [rsp + 0x30]
call fcn.140032038
mov r8d, eax
lea rdx, [rsp + 0x30]
mov rcx, rbx
call fcn.1400060fc
lea rcx, str._txupd.exe
call fcn.140032038
mov r8d, eax
lea rdx, str._txupd.exe
mov rcx, rbx
call fcn.14000e0f8
mov rcx, qword [rbx]
call qword [sym.imp.SHLWAPI.dll_PathFileExistsW]
test eax, eax
jne 0x140022854
mov r8, qword [rbx]
lea rdx, str.txupd___s__not_exist_so_uplevel_dir
lea rcx, [0x14005f708]
call fcn.140025b7c
mov edx, 0x5c
lea rcx, [rsp + 0x30]
call fcn.14002de38
test rax, rax
je 0x1400227e3
mov word [rax], di
lea rcx, [rsp + 0x30]
call fcn.140032038
mov r8d, eax
lea rdx, [rsp + 0x30]
mov rcx, rbx
call fcn.1400060fc
lea rcx, str._txupd.exe
call fcn.140032038
mov r8d, eax
lea rdx, str._txupd.exe
mov rcx, rbx
call fcn.14000e0f8
mov r8, qword [rbx]
lea rdx, str.txupd___s_
lea rcx, [0x14005f708]
call fcn.140025b7c
mov rcx, qword [rbx]
call qword [sym.imp.SHLWAPI.dll_PathFileExistsW]
test eax, eax
jne 0x140022854
mov r8, qword [rbx]
lea rdx, str.txupd___s__not_exist_error
lea rcx, [0x14005f708]
call fcn.140025b7c
mov rax, rbx
mov rcx, qword [rsp + 0x240]
xor rcx, rsp
call fcn.14002b930
mov rbx, qword [rsp + 0x268]
add rsp, 0x250
pop rdi
ret
mov ecx, 0x80004005
call fcn.140006280
int3
Function at 0x140024948
Capabilities:
Get file attributes

Disassembly:
mov rax, rsp
mov qword [rax + 8], rbx
mov qword [rax + 0x10], rsi
mov qword [rax + 0x18], rdi
push rbp
push r12
push r13
push r14
push r15
lea rbp, [rax - 0x5f]
sub rsp, 0x90
mov rsi, r9
mov r12d, r8d
mov r13d, edx
mov rdi, rcx
call qword [sym.imp.USER32.dll_CreatePopupMenu]
mov r14, rax
test rax, rax
jne 0x14002498f
mov eax, 0x80004005
jmp 0x140024b27
mov rcx, qword [rdi + 0x10]
call qword [sym.imp.KERNEL32.dll_GetFileAttributesW]
mov rax, qword [rdi]
mov rdx, r14
mov rcx, rdi
call qword [rax]
mov r15, qword [rdi + 8]
test r15, r15
je 0x1400249d8
mov rbx, qword [r15]
mov rcx, r14
call qword [sym.imp.USER32.dll_GetMenuItemCount]
and dword [rsp + 0x28], 0
mov r9d, 0x64
mov r8d, eax
mov dword [rsp + 0x20], 0x2710
mov rdx, r14
mov rcx, r15
call qword [rbx + 0x18]
mov rax, qword [rdi]
mov rdx, r14
mov rcx, rdi
call qword [rax + 8]
xor r15d, r15d
lea rdx, [rbp - 0x19]
mov rcx, rsi
mov dword [rbp - 0x19], r15d
call qword [sym.imp.USER32.dll_GetWindowThreadProcessId]
mov ebx, eax
cmp qword [rdi + 8], r15
je 0x140024aa4
call qword [sym.imp.KERNEL32.dll_GetCurrentProcessId]
cmp dword [rbp - 0x19], eax
jne 0x140024aa4
call qword [sym.imp.KERNEL32.dll_GetCurrentThreadId]
cmp ebx, eax
jne 0x140024aa4
mov rax, qword [rdi + 8]
mov qword [rbp - 0x11], rsi
mov qword [rbp + 0xf], rax
mov qword [rbp - 9], rsi
mov qword [rbp + 7], r15
mov qword [rbp - 1], r15
test rax, rax
je 0x140024a74
mov rcx, rsi
call qword [sym.imp.USER32.dll_IsWindow]
test eax, eax
je 0x140024a74
mov rcx, qword [rbp - 9]
lea r8, [0x1400244b0]
lea edx, [r15 - 4]
call qword [sym.imp.USER32.dll_SetWindowLongPtrW]
lea rdx, [rbp - 0x11]
mov qword [rbp - 1], rax
call fcn.140024b48
lea rcx, [rbp - 9]
mov qword [rax], rcx
mov qword [rsp + 0x30], r15
mov r9d, r12d
mov qword [rsp + 0x28], rsi
mov r8d, r13d
mov edx, 0x100
mov dword [rsp + 0x20], r15d
mov rcx, r14
call qword [sym.imp.USER32.dll_TrackPopupMenu]
lea rcx, [rbp - 9]
mov ebx, eax
call fcn.140024330
jmp 0x140024ac9
mov qword [rsp + 0x30], r15
mov r9d, r12d
mov qword [rsp + 0x28], rsi
mov r8d, r13d
mov edx, 0x100
mov dword [rsp + 0x20], r15d
mov rcx, r14
call qword [sym.imp.USER32.dll_TrackPopupMenu]
mov ebx, eax
mov rcx, r14
call qword [sym.imp.USER32.dll_DestroyMenu]
lea eax, [rbx - 0x64]
cmp eax, 0x26ac
ja 0x140024b19
mov rcx, qword [rdi + 8]
lea rdx, [rbp - 9]
xor eax, eax
mov dword [rbp - 9], 0x38
xorps xmm0, xmm0
mov dword [rbp + 0x2b], eax
movups xmmword [rbp - 5], xmm0
sub bx, 0x64
movups xmmword [rbp + 0xb], xmm0
movzx eax, bx
movups xmmword [rbp + 0x1b], xmm0
mov qword [rbp + 7], rax
mov dword [rbp + 0x1f], 1
mov rax, qword [rcx]
call qword [rax + 0x20]
jmp 0x140024b27
mov rax, qword [rdi]
mov r8, rsi
mov edx, ebx
mov rcx, rdi
call qword [rax + 0x10]
lea r11, [rsp + 0x90]
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 0x14002632c
Capabilities:
Create process on windows

Disassembly:
mov qword [rsp + 8], rbx
push rdi
sub rsp, 0x90
mov rbx, rcx
lea rdx, str.OpenUrlWithDefBrowserInternal__url_s
mov r8, rcx
lea rcx, [0x14005f720]
call fcn.140025b7c
call fcn.1400263b8
xor edx, edx
mov dword [rsp + 0x20], 0x70
lea rcx, [rsp + 0x24]
mov edi, eax
lea r8d, [rdx + 0x6c]
call fcn.14002dc80
mov dword [rsp + 0x24], 0x500
call qword [sym.imp.USER32.dll_GetDesktopWindow]
lea rcx, [rsp + 0x20]
mov dword [rsp + 0x50], 1
mov qword [rsp + 0x28], rax
mov qword [rsp + 0x38], rbx
call qword [sym.imp.SHELL32.dll_ShellExecuteExW]
test eax, eax
jne 0x1400263a4
test edi, edi
je 0x1400263a6
mov al, 1
mov rbx, qword [rsp + 0xa0]
add rsp, 0x90
pop rdi
ret
Function at 0x140026680
Capabilities:
Check if file exists
Create process on windows
Get common file path
Get file attributes
Get program files directory

Disassembly:
mov qword [rsp + 0x10], rbx
push rsi
sub rsp, 0x250
mov rax, qword [0x140070070]
xor rax, rsp
mov qword [rsp + 0x240], rax
mov rbx, rcx
lea rdx, str.OpenUrlWithIEInternal__url_s
mov r8, rcx
lea rcx, [0x14005f720]
call fcn.140025b7c
xor edx, edx
lea rcx, [rsp + 0x30]
mov r8d, 0x208
call fcn.14002dc80
xor r9d, r9d
lea rdx, [rsp + 0x30]
xor ecx, ecx
lea r8d, [r9 + 0x26]
call qword [sym.imp.SHELL32.dll_SHGetSpecialFolderPathW]
xor esi, esi
cmp word [rsp + 0x30], si
je 0x140026700
lea rcx, [rsp + 0x30]
call fcn.140032038
lea r8, str.Internet_ExplorerIEXPLORE.EXE
cmp word [rsp + rax*2 + 0x2e], 0x5c
jne 0x140026707
lea r8, [0x140066cc2]
mov edx, 0x104
lea rcx, [rsp + 0x30]
call fcn.140025b14
lea rcx, [rsp + 0x30]
call qword [sym.imp.KERNEL32.dll_GetFileAttributesW]
cmp eax, 0xffffffff
jne 0x140026741
lea r8, str.iexplore.exe
mov word [rsp + 0x30], si
mov edx, 0x104
lea rcx, [rsp + 0x30]
call fcn.140025b14
call qword [sym.imp.USER32.dll_GetDesktopWindow]
mov dword [rsp + 0x28], 5
lea r8, [rsp + 0x30]
mov rcx, rax
mov qword [rsp + 0x20], rsi
mov r9, rbx
lea rdx, str.open
call qword [sym.imp.SHELL32.dll_ShellExecuteW]
cmp rax, 0x20
setg al
mov rcx, qword [rsp + 0x240]
xor rcx, rsp
call fcn.14002b930
mov rbx, qword [rsp + 0x268]
add rsp, 0x250
pop rsi
ret

Function at 0x140026c2c
Capabilities:
Delete file
Move file

Disassembly:
mov qword [rsp + 0x10], rbx
mov qword [rsp + 0x18], rsi
push rbp
push rdi
push r14
lea rbp, [rsp - 0x5a0]
sub rsp, 0x6a0
mov rax, qword [0x140070070]
xor rax, rsp
mov qword [rbp + 0x590], rax
lea rdi, [rcx + 0x34]
mov rcx, rdi
lea rdx, [rsp + 0x20]
call qword [sym.imp.KERNEL32.dll_FindFirstFileW]
mov rsi, rax
cmp rax, 0xffffffffffffffff
je 0x140026d51
xor r14d, r14d
cmp dword [rsp + 0x3c], r14d
jne 0x140026c91
cmp dword [rsp + 0x40], 0x500000
jbe 0x140026d48
mov ebx, 0x104
mov word [rbp + 0x380], r14w
mov edx, ebx
lea rcx, [rbp + 0x380]
mov r8, rdi
call fcn.140025b14
mov r8, rdi
mov word [rbp + 0x170], r14w
mov edx, ebx
lea rcx, [rbp + 0x170]
call fcn.140025b14
lea r8, [0x140066d00]
mov edx, ebx
lea rcx, [rbp + 0x380]
call fcn.140025b14
lea r8, [0x140066d08]
mov edx, ebx
lea rcx, [rbp + 0x170]
call fcn.140025b14
mov ebx, r14d
lea rcx, [rbp + 0x170]
call qword [sym.imp.KERNEL32.dll_DeleteFileW]
test eax, eax
jne 0x140026d1b
cmp ebx, 2
jge 0x140026d14
lea ecx, [rax + 0x28]
call qword [sym.imp.KERNEL32.dll_Sleep]
inc ebx
cmp ebx, 3
jl 0x140026cf5
lea rdx, [rbp + 0x170]
lea rcx, [rbp + 0x380]
call qword [sym.imp.KERNEL32.dll_MoveFileW]
lea rdx, [rbp + 0x380]
mov rcx, rdi
call qword [sym.imp.KERNEL32.dll_MoveFileW]
mov rcx, rdi
call qword [sym.imp.KERNEL32.dll_DeleteFileW]
mov rcx, rsi
call qword [sym.imp.KERNEL32.dll_FindClose]
mov rcx, qword [rbp + 0x590]
xor rcx, rsp
call fcn.14002b930
lea r11, [rsp + 0x6a0]
mov rbx, qword [r11 + 0x28]
mov rsi, qword [r11 + 0x30]
mov rsp, r11
pop r14
pop rdi
pop rbp
ret
Function at 0x140029d70
Capabilities:
Get local ipv4 addresses

Disassembly:
mov rax, rsp
mov qword [rax + 8], rbx
mov qword [rax + 0x18], rbp
mov qword [rax + 0x20], rsi
mov dword [rax + 0x10], edx
push rdi
sub rsp, 0x30
mov rsi, rcx
lea rdx, str.M_GetAdaptersAddresses_begin.
lea rcx, str.bugreport
call fcn.140025b7c
and dword [rsp + 0x48], 0
xor ebx, ebx
xor ebp, ebp
xor edx, edx
lea rax, [rsp + 0x48]
mov r9, rbx
mov qword [rsp + 0x20], rax
xor r8d, r8d
lea ecx, [rdx + 2]
call qword [sym.imp.IPHLPAPI.DLL_GetAdaptersAddresses]
mov edi, eax
cmp eax, 0x6f
jne 0x140029e29
test rbx, rbx
je 0x140029dd5
mov rcx, rbx
call fcn.14002bbcc
mov ecx, dword [rsp + 0x48]
add rcx, 0x170
call fcn.14002bbd4
inc ebp
mov rbx, rax
cmp ebp, 5
jl 0x140029da6
test rbx, rbx
je 0x140029dfc
mov rcx, rbx
call fcn.14002bbcc
mov r8d, edi
lea rdx, str.GetAdaptersAddresses_failed___ld_.
lea rcx, str.bugreport
call fcn.140025b7c
xor eax, eax
mov rbx, qword [rsp + 0x40]
mov rbp, qword [rsp + 0x50]
mov rsi, qword [rsp + 0x58]
add rsp, 0x30
pop rdi
ret
test edi, edi
jne 0x140029def
test rbx, rbx
je 0x140029dfc
mov rdx, rbx
mov rcx, rsi
call fcn.140029e64
mov edi, eax
test eax, eax
je 0x140029e58
mov rcx, rsi
call fcn.14002a404
mov rcx, rsi
call fcn.14002a918
mov edi, 1
mov rcx, rbx
call fcn.14002bbcc
mov eax, edi
jmp 0x140029e14

Function at 0x14002b524
Capabilities:
Encode data using xor
Encrypt data using rc4 prga

Disassembly:
mov qword [rsp + 8], rbx
movsxd r9, r9d
mov rbx, r8
mov r11, rdx
mov r10, rcx
test r9, r9
jle 0x14002b59d
sub r11, rbx
inc byte [r10 + 0x100]
movzx r8d, byte [r10 + 0x100]
mov al, byte [r8 + r10]
add byte [r10 + 0x101], al
movzx edx, byte [r10 + 0x101]
mov cl, byte [r8 + r10]
mov al, byte [rdx + r10]
mov byte [r8 + r10], al
mov byte [rdx + r10], cl
movzx eax, byte [r10 + 0x101]
movzx ecx, byte [r10 + 0x100]
mov cl, byte [rcx + r10]
add cl, byte [rax + r10]
movzx eax, cl
mov cl, byte [rax + r10]
xor cl, byte [r11 + rbx]
mov byte [rbx], cl
inc rbx
sub r9, 1
jne 0x14002b53d
mov rbx, qword [rsp + 8]
ret
Function at 0x140041490
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.140050850
sub rsp, rax
mov rax, qword [0x140070070]
xor rax, rsp
mov qword [rsp + 0x1040], rax
mov r15, r8
mov rbp, rdx
mov rbx, rcx
call fcn.140045450
xor edi, edi
movsxd r14, eax
cmp dword [rbx + 0x10], edi
jne 0x1400414df
mov rax, rbp
jmp 0x1400415e7
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, [0x140000000]
xor r8d, r8d
mov rdx, qword [rax + rbx*8 + 0x72a20]
mov ecx, r14d
mov rdx, qword [rdx + r12*8 + 0x30]
call fcn.140047884
mov r13, rax
lea rax, [0x140000000]
mov rcx, qword [rax + rbx*8 + 0x72a20]
cmp r13, qword [rcx + r12*8 + 0x30]
jne 0x1400415e3
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 0x1400415e3
mov r9, r15
xor r8d, r8d
mov rdx, rbp
mov ecx, r14d
call fcn.140047884
test rax, rax
js 0x1400415e3
mov eax, dword [rsp + 0x30]
cmp rsi, rax
jg 0x1400415e3
lea rdx, [rsp + 0x40]
add rdx, rax
lea rcx, [rsp + 0x40]
test rsi, rsi
je 0x1400415d5
lea r8, [0x140000000]
cmp rcx, rdx
jae 0x1400415d5
cmp byte [rcx], 0xd
jne 0x1400415bb
lea rax, [rdx - 1]
cmp rcx, rax
jae 0x1400415ca
cmp byte [rcx + 1], 0xa
jne 0x1400415ca
inc rcx
jmp 0x1400415ca
movzx eax, byte [rcx]
movsx rax, byte [rax + r8 + 0x703b0]
add rcx, rax
inc rdi
inc rcx
cmp rdi, rsi
jne 0x14004159d
lea rax, [rsp + 0x40]
sub rcx, rax
lea rax, [rcx + r13]
jmp 0x1400415e7
or rax, 0xffffffffffffffff
mov rcx, qword [rsp + 0x1040]
xor rcx, rsp
call fcn.14002b930
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 0x140043594
Capabilities:
Parse pe header

Disassembly:
xor r8d, r8d
xor edx, edx
jmp 0x140043384
Function at 0x140047c74
Capabilities:
Read file on windows

Disassembly:
push rbx
push rbp
push rsi
push rdi
push r12
push r13
push r14
sub rsp, 0x30
movsxd rbp, ecx
mov r9, r8
mov rax, rbp
lea rcx, [0x140072a20]
and eax, 0x3f
mov r10, rbp
sar r10, 6
xor edi, edi
mov rsi, rdx
mov r14, rbp
lea r8, [rax + rax*8]
mov rax, qword [rcx + r10*8]
mov ecx, 4
mov qword [rsp + 0x78], rcx
mov r11, qword [rax + r8*8 + 0x28]
lea r12d, [rcx + 6]
test r9, r9
je 0x140047cd2
cmp word [rdx], r12w
jne 0x140047cd2
or byte [rax + r8*8 + 0x38], cl
jmp 0x140047cd8
and byte [rax + r8*8 + 0x38], 0xfb
lea rdx, [rdx + r9*2]
mov rcx, rsi
mov rbx, rsi
cmp rsi, rdx
jae 0x140047e33
mov r9d, 0x1a
lea r13d, [r9 - 0xd]
movzx eax, word [rcx]
cmp ax, r9w
je 0x140047e0e
lea r9, [rcx + 2]
cmp ax, r13w
je 0x140047d11
mov rcx, r9
jmp 0x140047d34
cmp r9, rdx
jae 0x140047d4b
cmp word [r9], r12w
mov eax, 2
cmove rax, qword [rsp + 0x78]
add rcx, rax
mov eax, r12d
cmp word [r9], r12w
cmovne ax, r13w
mov word [rbx], ax
mov r9d, 0x1a
add rbx, 2
cmp rcx, rdx
jb 0x140047cf5
jmp 0x140047e33
lea r9, [rsp + 0x80]
mov qword [rsp + 0x20], rdi
mov r8d, 2
lea rdx, [rsp + 0x70]
mov rcx, r11
call qword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
je 0x140047e08
cmp dword [rsp + 0x80], edi
je 0x140047e08
mov rdx, r14
lea r11, [0x140072a20]
sar rdx, 6
and r14d, 0x3f
mov rax, qword [r11 + rdx*8]
lea r8, [r14 + r14*8]
test byte [rax + r8*8 + 0x38], 0x48
je 0x140047de1
movzx eax, word [rsp + 0x70]
cmp ax, r12w
jne 0x140047db4
mov word [rbx], r12w
jmp 0x140047e2f
mov word [rbx], r13w
mov word [rsp + 0x78], ax
mov rax, qword [r11 + rdx*8]
lea rcx, [rax + r8*8]
mov al, byte [rsp + rdi + 0x78]
mov byte [rcx + rdi + 0x3a], al
inc rdi
cmp rdi, 2
jl 0x140047dbd
mov rax, qword [r11 + rdx*8]
mov byte [rax + r8*8 + 0x3c], r12b
jmp 0x140047e2f
cmp word [rsp + 0x70], r12w
jne 0x140047dee
cmp rbx, rsi
je 0x140047dae
mov rdx, 0xfffffffffffffffe
mov ecx, ebp
lea r8d, [rdx + 3]
call fcn.14004788c
cmp word [rsp + 0x70], r12w
je 0x140047e33
mov word [rbx], r13w
jmp 0x140047e2f
lea r11, [0x140072a20]
mov rcx, qword [r11 + r10*8]
mov al, byte [rcx + r8*8 + 0x38]
test al, 0x40
jne 0x140047e2b
or al, 2
mov byte [rcx + r8*8 + 0x38], al
jmp 0x140047e33
mov word [rbx], r9w
add rbx, 2
sub rbx, rsi
sar rbx, 1
lea eax, [rbx + rbx]
add rsp, 0x30
pop r14
pop r13
pop r12
pop rdi
pop rsi
pop rbp
pop rbx
ret
Function at 0x140049ae0
Capabilities:
Read file on windows

Disassembly:
mov qword [rsp + 8], rbx
mov qword [rsp + 0x10], rsi
mov qword [rsp + 0x18], rdi
push r14
sub rsp, 0x20
mov rsi, rcx
test rcx, rcx
jne 0x140049b12
call fcn.140032898
mov dword [rax], 0x16
call fcn.14003272c
jmp 0x140049c31
mov eax, dword [rcx + 0x14]
shr eax, 0xd
test al, 1
je 0x140049c31
mov eax, dword [rcx + 0x14]
shr eax, 0xc
test al, 1
jne 0x140049c31
mov eax, dword [rcx + 0x14]
shr eax, 1
test al, 1
je 0x140049b41
lock or dword [rcx + 0x14], 0x10
jmp 0x140049c31
lock or dword [rcx + 0x14], 1
mov eax, dword [rcx + 0x14]
test eax, 0x4c0
jne 0x140049b55
call fcn.14004c410
mov rdi, qword [rsi + 8]
mov rcx, rsi
mov ebx, dword [rsi + 0x20]
mov qword [rsi], rdi
call fcn.140045450
mov r8d, ebx
mov rdx, rdi
mov ecx, eax
call fcn.140048120
mov dword [rsi + 0x10], eax
lea ecx, [rax + 1]
cmp ecx, 1
jbe 0x140049c1f
mov eax, dword [rsi + 0x14]
or edi, 0xffffffff
test al, 6
jne 0x140049bea
mov rcx, rsi
call fcn.140045450
cmp eax, edi
je 0x140049bd5
mov rcx, rsi
call fcn.140045450
cmp eax, 0xfffffffe
je 0x140049bd5
mov rcx, rsi
call fcn.140045450
movsxd rbx, eax
lea r14, [0x140072a20]
mov rcx, rsi
sar rbx, 6
call fcn.140045450
and eax, 0x3f
lea rcx, [rax + rax*8]
mov rax, qword [r14 + rbx*8]
lea rdx, [rax + rcx*8]
jmp 0x140049bdc
lea rdx, [0x140070360]
mov al, byte [rdx + 0x38]
and al, 0x82
cmp al, 0x82
jne 0x140049bea
lock or dword [rsi + 0x14], 0x20
cmp dword [rsi + 0x20], 0x200
jne 0x140049c0e
mov eax, dword [rsi + 0x14]
shr eax, 6
test al, 1
je 0x140049c0e
mov eax, dword [rsi + 0x14]
shr eax, 8
test al, 1
jne 0x140049c0e
mov dword [rsi + 0x20], 0x1000
mov rax, qword [rsi]
add dword [rsi + 0x10], edi
movzx edi, byte [rax]
inc rax
mov qword [rsi], rax
jmp 0x140049c34
neg eax
sbb eax, eax
and eax, 8
add eax, 8
lock or dword [rsi + 0x14], eax
and dword [rsi + 0x10], 0
or edi, 0xffffffff
mov rbx, qword [rsp + 0x30]
mov eax, edi
mov rdi, qword [rsp + 0x40]
mov rsi, qword [rsp + 0x38]
add rsp, 0x20
pop r14
ret