joyce8/EMBER2024-capa huggingface dataset:
Function at 0x140004300
Capabilities:
Check mutex on windows

Disassembly:
mov qword [rsp + 8], rbx
mov qword [rsp + 0x10], rbp
mov qword [rsp + 0x18], rsi
push rdi
mov eax, 0x20
call fcn.140009290
sub rsp, rax
cmp qword [0x1400368e8], 0
mov rbp, rcx
jne 0x14000437f
xor r8d, r8d
lea edx, [rax - 0x1f]
xor ecx, ecx
call qword [sym.imp.KERNEL32.dll_CreateMutexA]
mov qword [0x1400368e0], rax
test rax, rax
jne 0x14000435b
lea r8d, [rax + 1]
lea rdx, str.CreateMutex
lea rcx, str.ss_ch
call fcn.140004940
mov ecx, 0x1000
call fcn.1400066b0
mov ecx, 0x2000
mov qword [0x1400368e8], rax
call fcn.1400066b0
mov qword [0x1400368f0], rax
jmp 0x1400043af
mov rcx, qword [0x1400368e0]
mov edx, 0xffffffff
call qword [sym.imp.KERNEL32.dll_WaitForSingleObject]
cmp eax, 0xffffffff
jne 0x1400043af
mov r8d, 1
lea rdx, [0x140028080]
lea rcx, str.ss_ch
call fcn.140004940
movsxd rbx, dword [0x1400368c4]
lea eax, [rbx + 1]
mov dword [0x1400368c4], eax
cmp eax, 0x400
jl 0x1400043d0
mov dword [0x1400368c4], 0
mov rcx, rbp
call fcn.1400065f0
mov rcx, qword [0x1400368f0]
lea rdi, [rbx*4]
lea rbx, [rbx*8]
lea esi, [rax + 8]
cmp qword [rbx + rcx], 0
jne 0x140004430
mov eax, 0x20
mov ecx, esi
cmp esi, eax
cmovl ecx, eax
mov rax, qword [0x1400368e8]
mov dword [rdi + rax], ecx
mov rcx, qword [0x1400368e8]
mov ecx, dword [rdi + rcx]
call fcn.1400066b0
mov rcx, qword [0x1400368f0]
mov qword [rbx + rcx], rax
mov rcx, qword [0x1400368f0]
mov rax, qword [0x1400368e8]
cmp dword [rdi + rax], esi
jge 0x140004461
mov rcx, qword [rbx + rcx]
call fcn.140006610
mov ecx, esi
call fcn.1400066b0
mov rdx, qword [0x1400368f0]
mov qword [rbx + rdx], rax
mov rax, qword [0x1400368e8]
mov dword [rdi + rax], esi
mov rcx, qword [0x1400368e0]
call qword [sym.imp.KERNEL32.dll_ReleaseMutex]
test eax, eax
jne 0x140004489
lea r8d, [rax + 1]
lea rdx, [0x1400280a8]
lea rcx, str.ss_ch
call fcn.140004940
mov rcx, qword [0x1400368f0]
mov rdx, rbp
mov rcx, qword [rbx + rcx]
call fcn.140006e10
mov rax, qword [0x1400368f0]
mov rbp, qword [rsp + 0x38]
mov rsi, qword [rsp + 0x40]
mov rax, qword [rbx + rax]
mov rbx, qword [rsp + 0x30]
add rsp, 0x20
pop rdi
ret
Function at 0x1400044c0
Capabilities:
Check mutex on windows

Disassembly:
mov qword [rsp + 8], rbx
mov qword [rsp + 0x10], rbp
mov qword [rsp + 0x18], rsi
push rdi
mov eax, 0x20
call fcn.140009290
sub rsp, rax
cmp qword [0x1400368d0], 0
mov rbp, rcx
jne 0x14000453f
xor r8d, r8d
lea edx, [rax - 0x1f]
xor ecx, ecx
call qword [sym.imp.KERNEL32.dll_CreateMutexA]
mov qword [0x1400368c8], rax
test rax, rax
jne 0x14000451b
lea r8d, [rax + 1]
lea rdx, str.CreateMutex
lea rcx, str.ss_wc
call fcn.140004940
mov ecx, 0x1000
call fcn.1400066b0
mov ecx, 0x2000
mov qword [0x1400368d0], rax
call fcn.1400066b0
mov qword [0x1400368d8], rax
jmp 0x14000456f
mov rcx, qword [0x1400368c8]
mov edx, 0xffffffff
call qword [sym.imp.KERNEL32.dll_WaitForSingleObject]
cmp eax, 0xffffffff
jne 0x14000456f
mov r8d, 1
lea rdx, [0x140028080]
lea rcx, str.ss_wc
call fcn.140004940
movsxd rbx, dword [0x1400368c0]
lea eax, [rbx + 1]
mov dword [0x1400368c0], eax
cmp eax, 0x400
jl 0x140004590
mov dword [0x1400368c0], 0
mov rcx, rbp
call fcn.1400065d0
mov rcx, qword [0x1400368d8]
mov rsi, rbx
lea edi, [rax*2 + 0x10]
cmp qword [rcx + rbx*8], 0
lea rbx, [rbx*4]
jne 0x1400045f2
mov eax, 0x40
movsxd rcx, edi
cmp rcx, rax
cmovb rcx, rax
mov rax, qword [0x1400368d0]
mov dword [rbx + rax], ecx
mov rcx, qword [0x1400368d0]
mov ecx, dword [rbx + rcx]
call fcn.1400066b0
mov rcx, qword [0x1400368d8]
mov qword [rcx + rsi*8], rax
mov rcx, qword [0x1400368d8]
mov rax, qword [0x1400368d0]
cmp dword [rbx + rax], edi
jge 0x140004623
mov rcx, qword [rcx + rsi*8]
call fcn.140006610
mov ecx, edi
call fcn.1400066b0
mov rdx, qword [0x1400368d8]
mov qword [rdx + rsi*8], rax
mov rax, qword [0x1400368d0]
mov dword [rbx + rax], edi
mov rcx, qword [0x1400368c8]
call qword [sym.imp.KERNEL32.dll_ReleaseMutex]
test eax, eax
jne 0x14000464b
lea r8d, [rax + 1]
lea rdx, [0x1400280a8]
lea rcx, str.ss_wc
call fcn.140004940
mov rcx, qword [0x1400368d8]
mov rdx, rbp
mov rcx, qword [rcx + rsi*8]
call fcn.140006dd0
mov rax, qword [0x1400368d8]
mov rbx, qword [rsp + 0x30]
mov rbp, qword [rsp + 0x38]
mov rax, qword [rax + rsi*8]
mov rsi, qword [rsp + 0x40]
add rsp, 0x20
pop rdi
ret

Function at 0x140004840
Capabilities:
Check mutex on windows

Disassembly:
mov eax, 0x78
call fcn.140009290
sub rsp, rax
mov rax, qword [0x140035d40]
xor rax, rsp
mov qword [rsp + 0x60], rax
mov rax, qword [0x1400368f8]
test rax, rax
jne 0x1400048bf
call fcn.140007480
mov r9d, eax
lea r8, str._8.8x_ss_lock
mov edx, 0x40
lea rcx, [rsp + 0x20]
call fcn.140003be0
lea r8, [rsp + 0x20]
xor edx, edx
xor ecx, ecx
call qword [sym.imp.KERNEL32.dll_CreateMutexW]
mov qword [0x1400368f8], rax
test rax, rax
jne 0x1400048bf
lea r8d, [rax + 1]
lea rdx, str.CreateMutex
lea rcx, str.ss_lock
call fcn.140004940
mov rax, qword [0x1400368f8]
mov edx, 0xffffffff
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_WaitForSingleObject]
cmp eax, 0xffffffff
jne 0x1400048eb
mov r8d, 1
lea rdx, [0x140028080]
lea rcx, str.ss_lock
call fcn.140004940
xor eax, eax
mov rcx, qword [rsp + 0x60]
xor rcx, rsp
call fcn.1400092f0
add rsp, 0x78
ret
Function at 0x140004940
Capabilities:
Accept command line arguments

Disassembly:
push rbp
push rsi
push rdi
mov eax, 0xc0
call fcn.140009290
sub rsp, rax
mov rax, qword [0x140035d40]
xor rax, rsp
mov qword [rsp + 0xb0], rax
cmp dword [0x140035420], 0
mov ebp, r8d
mov rdi, rdx
mov rsi, rcx
je 0x140004b51
mov qword [rsp + 0xf0], rbx
lea rcx, [rsp + 0x60]
mov qword [rsp + 0xf8], r14
call qword [sym.imp.KERNEL32.dll_GetLocalTime]
movzx ecx, word [rsp + 0x6c]
movzx edx, word [rsp + 0x6a]
movzx r8d, word [rsp + 0x68]
movzx eax, word [rsp + 0x6e]
movzx r10d, word [rsp + 0x66]
movzx r11d, word [rsp + 0x62]
movzx r9d, word [rsp + 0x60]
mov dword [rsp + 0x48], eax
mov dword [rsp + 0x40], ecx
lea rcx, [rsp + 0x70]
mov dword [rsp + 0x38], edx
mov edx, 0x40
mov dword [rsp + 0x30], r8d
lea r8, str._4.4d._2.2d._2.2d__2.2d:_2.2d:_2.2d._3.3d
mov dword [rsp + 0x28], r10d
mov dword [rsp + 0x20], r11d
call fcn.140003be0
call qword [sym.imp.KERNEL32.dll_GetLastError]
mov ebx, eax
test eax, eax
jne 0x140004a02
test ebp, ebp
mov eax, 1
cmovne ebx, eax
call fcn.1400074a0
lea rcx, [0x1400281a4]
call fcn.140004bf0
mov r8d, ebx
lea rcx, [0x1400281a8]
mov edx, ebx
call fcn.140004bf0
lea rdx, [rsp + 0x70]
lea rcx, str._Date:_______s_n
call fcn.140004bf0
call fcn.140003520
mov rdx, rax
lea rcx, str._Imagename:___s__n
call fcn.140004bf0
call qword [sym.imp.KERNEL32.dll_GetCommandLineW]
mov rdx, rax
lea rcx, str._Command:_____s__n
call fcn.140004bf0
lea rax, [rsp + 0x50]
mov dword [rsp + 0x58], 0xff
xor r14d, r14d
lea rdx, [rsp + 0x58]
mov qword [rsp + 0x30], r14
mov r9d, 0x400
mov dword [rsp + 0x28], pe_nt_image_headers64
mov r8d, ebx
mov ecx, 0x1100
mov qword [rsp + 0x20], rax
call qword [sym.imp.KERNEL32.dll_FormatMessageW]
test eax, eax
jle 0x140004b0e
mov rdx, qword [rsp + 0x50]
test rdx, rdx
je 0x140004b0e
movzx ecx, word [rdx]
mov rax, rdx
test cx, cx
je 0x140004ad5
cmp cx, 0xa
je 0x140004abe
cmp cx, 0xd
jne 0x140004ac3
mov word [rax], 0x20
movzx ecx, word [rax + 2]
add rax, 2
test cx, cx
jne 0x140004ab2
mov rdx, qword [rsp + 0x50]
cmp word [rax - 2], 0x20
jne 0x140004ae6
mov word [rax - 2], r14w
mov rdx, qword [rsp + 0x50]
cmp word [rax - 4], 0x20
jne 0x140004af7
mov word [rax - 4], r14w
mov rdx, qword [rsp + 0x50]
lea rcx, str._Message:_____s__n
call fcn.140004bf0
mov rcx, qword [rsp + 0x50]
call qword [sym.imp.KERNEL32.dll_LocalFree]
cmp word [rsi], 0
mov r14, qword [rsp + 0xf8]
je 0x140004b2b
mov rdx, rsi
lea rcx, str._Function:____s__n
call fcn.140004bf0
cmp word [rdi], 0
je 0x140004b40
mov rdx, rdi
lea rcx, str._Parameter:___s__n
call fcn.140004bf0
test ebp, ebp
jne 0x140004b6e
call fcn.140007560
mov rbx, qword [rsp + 0xf0]
xor eax, eax
mov rcx, qword [rsp + 0xb0]
xor rcx, rsp
call fcn.1400092f0
add rsp, 0xc0
pop rdi
pop rsi
pop rbp
ret
lea rcx, str._Status:_____Program_aborted___n
call fcn.140004bf0
mov ecx, ebx
call fcn.140012fa4
int3
Function at 0x140004cf0
Capabilities:
Query or enumerate registry value

Disassembly:
mov qword [rsp + 0x10], rbx
mov qword [rsp + 0x18], rbp
push rdi
mov eax, 0x40
call fcn.140009290
sub rsp, rax
mov rdi, r9
mov byte [r9], 0
mov rbp, r8
mov rbx, rdx
call fcn.140004c50
lea rcx, [rsp + 0x38]
mov r9d, 0x20019
mov qword [rsp + 0x20], rcx
xor r8d, r8d
mov rcx, rax
mov rdx, rbx
call qword [sym.imp.ADVAPI32.dll_RegOpenKeyExA]
test eax, eax
je 0x140004d52
mov eax, 1
mov rbx, qword [rsp + 0x58]
mov rbp, qword [rsp + 0x60]
add rsp, 0x40
pop rdi
ret
mov rcx, qword [rsp + 0x38]
lea rax, [rsp + 0x68]
mov qword [rsp + 0x28], rax
lea r9, [rsp + 0x30]
mov qword [rsp + 0x50], rsi
xor r8d, r8d
mov esi, dword [rsp + 0x70]
mov rdx, rbp
mov qword [rsp + 0x20], rdi
mov dword [rsp + 0x68], esi
call qword [sym.imp.ADVAPI32.dll_RegQueryValueExA]
mov rcx, qword [rsp + 0x38]
mov ebx, eax
call qword [sym.imp.ADVAPI32.dll_RegCloseKey]
test ebx, ebx
jne 0x140004db3
xor ecx, ecx
cmp dword [rsp + 0x68], esi
mov eax, ecx
setle al
cmp dword [rsp + 0x30], 1
sete cl
test ecx, eax
jne 0x140004db3
mov byte [rdi], bl
lea eax, [rbx + 1]
jmp 0x140004db5
xor eax, eax
mov rsi, qword [rsp + 0x50]
mov rbx, qword [rsp + 0x58]
mov rbp, qword [rsp + 0x60]
add rsp, 0x40
pop rdi
ret

Function at 0x140004dd0
Capabilities:
Set registry value

Disassembly:
mov qword [rsp + 8], rbx
mov qword [rsp + 0x10], rsi
mov dword [rsp + 0x20], r9d
push rdi
mov eax, 0x60
call fcn.140009290
sub rsp, rax
mov rsi, r8
mov rbx, rdx
call fcn.140004c50
lea rcx, [rsp + 0x50]
xor edi, edi
mov qword [rsp + 0x40], rcx
lea r9, str.REG_DWORD
lea rcx, [rsp + 0x58]
xor r8d, r8d
mov qword [rsp + 0x38], rcx
mov rdx, rbx
mov qword [rsp + 0x30], rdi
mov rcx, rax
mov dword [rsp + 0x28], 0x20006
mov dword [rsp + 0x20], edi
call qword [sym.imp.ADVAPI32.dll_RegCreateKeyExA]
test eax, eax
jne 0x140004e88
mov rcx, qword [rsp + 0x58]
lea rax, [rsp + 0x88]
mov dword [rsp + 0x28], 4
lea r9d, [rdi + 4]
xor r8d, r8d
mov qword [rsp + 0x20], rax
mov rdx, rsi
call qword [sym.imp.ADVAPI32.dll_RegSetValueExA]
mov rcx, qword [rsp + 0x58]
mov ebx, eax
call qword [sym.imp.ADVAPI32.dll_RegCloseKey]
test ebx, ebx
setne dil
mov eax, edi
mov rbx, qword [rsp + 0x70]
mov rsi, qword [rsp + 0x78]
add rsp, 0x60
pop rdi
ret
mov rbx, qword [rsp + 0x70]
mov eax, 1
mov rsi, qword [rsp + 0x78]
add rsp, 0x60
pop rdi
ret
Function at 0x140004ea0
Capabilities:
Set registry value

Disassembly:
mov qword [rsp + 8], rbx
mov qword [rsp + 0x10], rbp
mov qword [rsp + 0x18], rsi
push rdi
mov eax, 0x60
call fcn.140009290
sub rsp, rax
mov rsi, r9
mov rbp, r8
mov rbx, rdx
call fcn.140004c50
lea rcx, [rsp + 0x50]
xor edi, edi
mov qword [rsp + 0x40], rcx
lea r9, str.REG_SZ
lea rcx, [rsp + 0x58]
xor r8d, r8d
mov qword [rsp + 0x38], rcx
mov rdx, rbx
mov qword [rsp + 0x30], rdi
mov rcx, rax
mov dword [rsp + 0x28], 0x20006
mov dword [rsp + 0x20], edi
call qword [sym.imp.ADVAPI32.dll_RegCreateKeyExA]
test eax, eax
jne 0x140004f49
mov rcx, rsi
call fcn.1400065d0
mov rcx, qword [rsp + 0x58]
lea r9d, [rdi + 1]
mov dword [rsp + 0x28], eax
xor r8d, r8d
mov rdx, rbp
mov qword [rsp + 0x20], rsi
call qword [sym.imp.ADVAPI32.dll_RegSetValueExA]
mov rcx, qword [rsp + 0x58]
mov ebx, eax
call qword [sym.imp.ADVAPI32.dll_RegCloseKey]
test ebx, ebx
setne dil
mov eax, edi
jmp 0x140004f4e
mov eax, 1
mov rbx, qword [rsp + 0x70]
mov rbp, qword [rsp + 0x78]
mov rsi, qword [rsp + 0x80]
add rsp, 0x60
pop rdi
ret

Function at 0x140004fc0
Capabilities:
Write file on windows

Disassembly:
mov qword [rsp + 0x10], rbx
push rdi
mov eax, 0x30
call fcn.140009290
sub rsp, rax
mov rbx, rcx
test rcx, rcx
jne 0x140004fe9
lea eax, [rcx + 1]
mov rbx, qword [rsp + 0x48]
add rsp, 0x30
pop rdi
ret
mov rcx, qword [rcx]
mov edi, 1
test rcx, rcx
je 0x140005057
cmp dword [rbx + 0x1c], 0
je 0x14000502f
mov r8d, dword [rbx + 0x24]
test r8d, r8d
jle 0x14000502f
mov rdx, qword [rbx + 0x10]
lea r9, [rsp + 0x40]
mov qword [rsp + 0x20], 0
call qword [sym.imp.KERNEL32.dll_WriteFile]
test eax, eax
jne 0x14000502f
lea eax, [rdi - 2]
mov rbx, qword [rsp + 0x48]
add rsp, 0x30
pop rdi
ret
cmp dword [rbx + 0x18], 0
jne 0x140005057
mov rcx, qword [rbx]
call qword [sym.imp.KERNEL32.dll_CloseHandle]
mov edi, eax
test eax, eax
jne 0x140005057
mov rdx, qword [rbx + 8]
lea rcx, str.ss_fclose
xor r8d, r8d
call fcn.140004940
mov rcx, qword [rbx + 8]
test rcx, rcx
je 0x140005065
call fcn.140006610
mov rcx, qword [rbx + 0x10]
test rcx, rcx
je 0x140005073
call fcn.140006610
mov rcx, rbx
call fcn.140006610
mov rbx, qword [rsp + 0x48]
mov eax, edi
add rsp, 0x30
pop rdi
ret

Function at 0x140005090
Capabilities:
Get file size

Disassembly:
push rbx
mov eax, 0x20
call fcn.140009290
sub rsp, rax
mov rbx, rcx
test rcx, rcx
jne 0x1400050be
lea r8d, [rax - 0x1f]
lea rdx, str.Called_with_NULL_pointer_for_SS_FileIO
lea rcx, str.ss_fhsize
call fcn.140004940
mov rcx, qword [rbx]
lea rdx, [rsp + 0x30]
mov qword [rsp + 0x30], 0
call qword [sym.imp.KERNEL32.dll_GetFileSizeEx]
mov rax, qword [rsp + 0x30]
add rsp, 0x20
pop rbx
ret
Function at 0x1400052e0
Capabilities:
Write file on windows

Disassembly:
mov qword [rsp + 0x10], rbx
mov qword [rsp + 0x18], rsi
push rdi
mov eax, 0x40
call fcn.140009290
sub rsp, rax
mov rdi, rcx
call fcn.1400050e0
cmp word [rdi], 0x2d
mov rbx, rax
jne 0x140005350
cmp word [rdi + 2], 0
jne 0x140005350
mov ecx, 0xfffffff6
call qword [sym.imp.KERNEL32.dll_GetStdHandle]
mov dword [rbx + 0x18], 1
mov qword [rbx], rax
mov ecx, dword [0x140035428]
mov dword [rbx + 0x20], ecx
mov ecx, dword [0x140035428]
call fcn.1400066b0
mov qword [rbx + 0x10], rax
mov rax, rbx
mov rbx, qword [rsp + 0x58]
mov rsi, qword [rsp + 0x60]
add rsp, 0x40
pop rdi
ret
mov eax, dword [0x140035424]
xor esi, esi
mov qword [rsp + 0x30], rsi
xor r9d, r9d
mov dword [rsp + 0x28], eax
mov edx, 0x80000000
mov rcx, rdi
mov dword [rsp + 0x20], 3
lea r8d, [rsi + 1]
call qword [sym.imp.KERNEL32.dll_CreateFileW]
cmp rax, 0xffffffffffffffff
jne 0x140005322
mov ecx, 0xc8
call qword [sym.imp.KERNEL32.dll_Sleep]
mov eax, dword [0x140035424]
lea r8d, [rsi + 1]
mov qword [rsp + 0x30], rsi
xor r9d, r9d
mov dword [rsp + 0x28], eax
mov edx, 0x80000000
mov rcx, rdi
mov dword [rsp + 0x20], 3
call qword [sym.imp.KERNEL32.dll_CreateFileW]
cmp rax, 0xffffffffffffffff
jne 0x140005322
mov ecx, 0xc8
call qword [sym.imp.KERNEL32.dll_Sleep]
mov eax, dword [0x140035424]
lea r8d, [rsi + 3]
mov qword [rsp + 0x30], rsi
xor r9d, r9d
mov dword [rsp + 0x28], eax
mov edx, 0x80000000
mov rcx, rdi
mov dword [rsp + 0x20], 3
call qword [sym.imp.KERNEL32.dll_CreateFileW]
cmp rax, 0xffffffffffffffff
jne 0x140005322
test rbx, rbx
je 0x140005482
mov rcx, qword [rbx]
test rcx, rcx
je 0x14000545e
cmp dword [rbx + 0x1c], esi
je 0x140005439
mov r8d, dword [rbx + 0x24]
test r8d, r8d
jle 0x140005439
mov rdx, qword [rbx + 0x10]
lea r9, [rsp + 0x50]
mov qword [rsp + 0x20], rsi
call qword [sym.imp.KERNEL32.dll_WriteFile]
test eax, eax
je 0x140005482
cmp dword [rbx + 0x18], esi
jne 0x14000545e
mov rcx, qword [rbx]
call qword [sym.imp.KERNEL32.dll_CloseHandle]
test eax, eax
jne 0x14000545e
mov rdx, qword [rbx + 8]
lea rcx, str.ss_fclose
xor r8d, r8d
call fcn.140004940
mov rcx, qword [rbx + 8]
test rcx, rcx
je 0x14000546c
call fcn.140006610
mov rcx, qword [rbx + 0x10]
test rcx, rcx
je 0x14000547a
call fcn.140006610
mov rcx, rbx
call fcn.140006610
mov rbx, qword [rsp + 0x58]
mov rax, rsi
mov rsi, qword [rsp + 0x60]
add rsp, 0x40
pop rdi
ret
Function at 0x1400054a0
Capabilities:
Write file on windows

Disassembly:
mov qword [rsp + 0x18], rbx
push rdi
mov eax, 0x40
call fcn.140009290
sub rsp, rax
mov rdi, rcx
call fcn.1400050e0
cmp word [rdi], 0x2d
mov rbx, rax
jne 0x1400054ee
cmp word [rdi + 2], 0
jne 0x1400054ee
mov ecx, 0xfffffff6
call qword [sym.imp.KERNEL32.dll_GetStdHandle]
mov qword [rbx], rax
mov rax, rbx
mov dword [rbx + 0x18], 1
mov rbx, qword [rsp + 0x60]
add rsp, 0x40
pop rdi
ret
mov eax, dword [0x140035424]
xor r9d, r9d
mov qword [rsp + 0x58], rsi
mov edx, 0x80000000
xor esi, esi
mov rcx, rdi
mov qword [rsp + 0x30], rsi
mov dword [rsp + 0x28], eax
mov dword [rsp + 0x20], 3
lea r8d, [rsi + 1]
call qword [sym.imp.KERNEL32.dll_CreateFileW]
cmp rax, 0xffffffffffffffff
jne 0x14000563b
mov ecx, 0xc8
call qword [sym.imp.KERNEL32.dll_Sleep]
mov eax, dword [0x140035424]
lea r8d, [rsi + 1]
mov qword [rsp + 0x30], rsi
xor r9d, r9d
mov dword [rsp + 0x28], eax
mov edx, 0x80000000
mov rcx, rdi
mov dword [rsp + 0x20], 3
call qword [sym.imp.KERNEL32.dll_CreateFileW]
cmp rax, 0xffffffffffffffff
jne 0x14000563b
mov ecx, 0xc8
call qword [sym.imp.KERNEL32.dll_Sleep]
mov eax, dword [0x140035424]
lea r8d, [rsi + 3]
mov qword [rsp + 0x30], rsi
xor r9d, r9d
mov dword [rsp + 0x28], eax
mov edx, 0x80000000
mov rcx, rdi
mov dword [rsp + 0x20], 3
call qword [sym.imp.KERNEL32.dll_CreateFileW]
cmp rax, 0xffffffffffffffff
jne 0x14000563b
test rbx, rbx
je 0x140005629
mov rcx, qword [rbx]
test rcx, rcx
je 0x140005605
cmp dword [rbx + 0x1c], esi
je 0x1400055e0
mov r8d, dword [rbx + 0x24]
test r8d, r8d
jle 0x1400055e0
mov rdx, qword [rbx + 0x10]
lea r9, [rsp + 0x50]
mov qword [rsp + 0x20], rsi
call qword [sym.imp.KERNEL32.dll_WriteFile]
test eax, eax
je 0x140005629
cmp dword [rbx + 0x18], esi
jne 0x140005605
mov rcx, qword [rbx]
call qword [sym.imp.KERNEL32.dll_CloseHandle]
test eax, eax
jne 0x140005605
mov rdx, qword [rbx + 8]
lea rcx, str.ss_fclose
xor r8d, r8d
call fcn.140004940
mov rcx, qword [rbx + 8]
test rcx, rcx
je 0x140005613
call fcn.140006610
mov rcx, qword [rbx + 0x10]
test rcx, rcx
je 0x140005621
call fcn.140006610
mov rcx, rbx
call fcn.140006610
mov rsi, qword [rsp + 0x58]
xor eax, eax
mov rbx, qword [rsp + 0x60]
add rsp, 0x40
pop rdi
ret
mov rsi, qword [rsp + 0x58]
mov qword [rbx], rax
mov rax, rbx
mov rbx, qword [rsp + 0x60]
add rsp, 0x40
pop rdi
ret
Function at 0x140005660
Capabilities:
Write file on windows

Disassembly:
mov qword [rsp + 0x18], rbx
push rdi
mov eax, 0x40
call fcn.140009290
sub rsp, rax
mov rdi, rcx
call fcn.1400050e0
cmp word [rdi], 0x2d
mov rbx, rax
jne 0x1400056ae
cmp word [rdi + 2], 0
jne 0x1400056ae
mov ecx, 0xfffffff5
call qword [sym.imp.KERNEL32.dll_GetStdHandle]
mov qword [rbx], rax
mov rax, rbx
mov dword [rbx + 0x18], 1
mov rbx, qword [rsp + 0x60]
add rsp, 0x40
pop rdi
ret
mov eax, dword [0x140035424]
xor r9d, r9d
mov qword [rsp + 0x58], rsi
mov edx, 0x40000000
xor esi, esi
mov rcx, rdi
mov qword [rsp + 0x30], rsi
mov dword [rsp + 0x28], eax
mov dword [rsp + 0x20], 2
lea r8d, [rsi + 1]
call qword [sym.imp.KERNEL32.dll_CreateFileW]
cmp rax, 0xffffffffffffffff
jne 0x14000587a
mov ecx, 0xc8
call qword [sym.imp.KERNEL32.dll_Sleep]
mov eax, dword [0x140035424]
lea r8d, [rsi + 1]
mov qword [rsp + 0x30], rsi
xor r9d, r9d
mov dword [rsp + 0x28], eax
mov edx, 0x40000000
mov rcx, rdi
mov dword [rsp + 0x20], 2
call qword [sym.imp.KERNEL32.dll_CreateFileW]
cmp rax, 0xffffffffffffffff
jne 0x14000587a
mov ecx, 0xc8
call qword [sym.imp.KERNEL32.dll_Sleep]
mov eax, dword [0x140035424]
xor r9d, r9d
mov qword [rsp + 0x30], rsi
xor r8d, r8d
mov dword [rsp + 0x28], eax
mov edx, 0x40000000
mov rcx, rdi
mov dword [rsp + 0x20], 2
call qword [sym.imp.KERNEL32.dll_CreateFileW]
cmp rax, 0xffffffffffffffff
jne 0x14000587a
mov ecx, 0xc8
call qword [sym.imp.KERNEL32.dll_Sleep]
mov eax, dword [0x140035424]
xor r9d, r9d
mov qword [rsp + 0x30], rsi
xor r8d, r8d
mov dword [rsp + 0x28], eax
mov edx, 0x40000000
mov rcx, rdi
mov dword [rsp + 0x20], 4
call qword [sym.imp.KERNEL32.dll_CreateFileW]
cmp rax, 0xffffffffffffffff
jne 0x14000587a
mov ecx, 0xc8
call qword [sym.imp.KERNEL32.dll_Sleep]
mov eax, dword [0x140035424]
xor r9d, r9d
mov qword [rsp + 0x30], rsi
xor r8d, r8d
mov dword [rsp + 0x28], eax
mov edx, 0x40000000
mov rcx, rdi
mov dword [rsp + 0x20], 3
call qword [sym.imp.KERNEL32.dll_CreateFileW]
cmp rax, 0xffffffffffffffff
jne 0x14000587a
test rbx, rbx
je 0x140005868
mov rcx, qword [rbx]
test rcx, rcx
je 0x140005844
cmp dword [rbx + 0x1c], esi
je 0x14000581f
mov r8d, dword [rbx + 0x24]
test r8d, r8d
jle 0x14000581f
mov rdx, qword [rbx + 0x10]
lea r9, [rsp + 0x50]
mov qword [rsp + 0x20], rsi
call qword [sym.imp.KERNEL32.dll_WriteFile]
test eax, eax
je 0x140005868
cmp dword [rbx + 0x18], esi
jne 0x140005844
mov rcx, qword [rbx]
call qword [sym.imp.KERNEL32.dll_CloseHandle]
test eax, eax
jne 0x140005844
mov rdx, qword [rbx + 8]
lea rcx, str.ss_fclose
xor r8d, r8d
call fcn.140004940
mov rcx, qword [rbx + 8]
test rcx, rcx
je 0x140005852
call fcn.140006610
mov rcx, qword [rbx + 0x10]
test rcx, rcx
je 0x140005860
call fcn.140006610
mov rcx, rbx
call fcn.140006610
mov rsi, qword [rsp + 0x58]
xor eax, eax
mov rbx, qword [rsp + 0x60]
add rsp, 0x40
pop rdi
ret
mov qword [rbx], rax
mov dword [rbx + 0x1c], 1
mov eax, dword [0x140035428]
mov dword [rbx + 0x20], eax
mov ecx, dword [0x140035428]
call fcn.1400066b0
mov rsi, qword [rsp + 0x58]
mov qword [rbx + 0x10], rax
mov rax, rbx
mov rbx, qword [rsp + 0x60]
add rsp, 0x40
pop rdi
ret
Function at 0x1400058b0
Capabilities:
Read file on windows

Disassembly:
mov qword [rsp + 0x18], rbx
push rbp
push rdi
push r14
mov eax, 0x30
call fcn.140009290
sub rsp, rax
mov ebp, r8d
mov rdi, rdx
mov rbx, rcx
test rcx, rcx
jne 0x1400058eb
lea r8d, [rax - 0x2f]
lea rdx, str.Called_with_NULL_pointer_for_SS_FileIO
lea rcx, str.ss_fread
call fcn.140004940
xor r14d, r14d
mov qword [rsp + 0x58], rsi
mov dword [rsp + 0x50], r14d
cmp qword [rbx + 0x10], r14
jne 0x140005928
mov rcx, qword [rbx]
lea r9, [rsp + 0x50]
mov r8d, ebp
mov qword [rsp + 0x20], r14
mov rdx, rdi
call qword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
je 0x1400059af
mov eax, dword [rsp + 0x50]
jmp 0x1400059c1
mov esi, r14d
cmp ebp, 1
jle 0x1400059bc
mov edx, dword [rbx + 0x24]
cmp edx, dword [rbx + 0x28]
jl 0x14000596d
mov r8d, dword [rbx + 0x20]
lea r9, [rsp + 0x50]
mov rdx, qword [rbx + 0x10]
mov rcx, qword [rbx]
mov qword [rsp + 0x20], r14
call qword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
je 0x1400059af
mov eax, dword [rsp + 0x50]
mov edx, r14d
mov dword [rbx + 0x28], eax
mov dword [rbx + 0x24], r14d
test eax, eax
jle 0x1400059a1
mov rax, qword [rbx + 0x10]
movsxd rcx, edx
movzx r8d, byte [rcx + rax]
cmp r8b, 0xd
jne 0x140005987
lea eax, [rdx + 1]
mov dword [rbx + 0x24], eax
jmp 0x14000599a
cmp r8b, 0xa
je 0x1400059b6
mov byte [rdi], r8b
inc esi
inc dword [rbx + 0x24]
inc rdi
dec ebp
cmp ebp, 1
jg 0x140005934
jmp 0x1400059bc
test esi, esi
mov byte [rdi], dl
mov eax, 0xffffffff
cmove esi, eax
jmp 0x1400059bf
mov eax, 0xffffffff
jmp 0x1400059c1
lea eax, [rdx + 1]
mov dword [rbx + 0x24], eax
mov byte [rdi], r14b
mov eax, esi
mov rsi, qword [rsp + 0x58]
mov rbx, qword [rsp + 0x60]
add rsp, 0x30
pop r14
pop rdi
pop rbp
ret