Function at 0x140047420
Capabilities:
Get file size
Read file on windows
Write file on windows

Disassembly:
mov qword [rsp + 8], rbx
push rdi
sub rsp, 0xf0
mov rax, qword [0x1400c7070]
xor rax, rsp
mov qword [rsp + 0xe0], rax
mov rcx, rdx
xor edi, edi
mov qword [rsp + 0x30], rdi
mov dword [rsp + 0x28], 0x80
mov dword [rsp + 0x20], 3
xor r9d, r9d
mov edx, 0xc0000000
lea r8d, [rdi + 1]
call qword [sym.imp.KERNEL32.dll_CreateFileW]
mov qword [rsp + 0x80], rax
cmp rax, 0xffffffffffffffff
jne 0x140047484
call qword [sym.imp.KERNEL32.dll_GetLastError]
jmp 0x140047949
lea rax, vtable.std::_Func_impl_no_alloc_class__lambda_956507e898d98b3a56256ec7fb7fd49c___void___.0
mov qword [rsp + 0x40], rax
lea rax, [rsp + 0x80]
mov qword [rsp + 0x48], rax
lea rax, [rsp + 0x40]
mov qword [rsp + 0x78], rax
lea rax, [rsp + 0xa0]
mov qword [rsp + 0x98], rax
mov qword [rsp + 0xd8], rdi
lea rdx, [rsp + 0xa0]
lea rcx, [rsp + 0x40]
mov rax, qword [vtable.std::_Func_impl_no_alloc_class__lambda_956507e898d98b3a56256ec7fb7fd49c___void___.0]
call qword [0x1400926f0]
mov qword [rsp + 0xd8], rax
mov rcx, qword [rsp + 0x78]
test rcx, rcx
je 0x140047503
mov rax, qword [rcx]
lea rdx, [rsp + 0x40]
cmp rcx, rdx
setne dl
mov rax, qword [rax + 0x20]
call qword [0x1400926f0]
lea rdx, [rsp + 0x88]
mov rcx, qword [rsp + 0x80]
call qword [sym.imp.KERNEL32.dll_GetFileSizeEx]
test eax, eax
jne 0x14004757d
call qword [sym.imp.KERNEL32.dll_GetLastError]
mov ebx, eax
mov rcx, qword [rsp + 0xd8]
test rcx, rcx
sete dl
test rcx, rcx
je 0x140047576
test dl, dl
jne 0x14004796a
mov rax, qword [rcx]
mov rax, qword [rax + 0x10]
call qword [0x1400926f0]
mov rcx, qword [rsp + 0xd8]
test rcx, rcx
je 0x140047576
mov rax, qword [rcx]
lea rdx, [rsp + 0xa0]
cmp rcx, rdx
setne dl
mov rax, qword [rax + 0x20]
call qword [0x1400926f0]
nop
mov eax, ebx
jmp 0x140047949
mov rcx, qword [rsp + 0x88]
cmp rcx, 0xc800
jle 0x1400475e6
mov rcx, qword [rsp + 0xd8]
test rcx, rcx
sete al
test rcx, rcx
je 0x1400475df
test al, al
jne 0x140047970
mov rax, qword [rcx]
mov rax, qword [rax + 0x10]
call qword [0x1400926f0]
mov rcx, qword [rsp + 0xd8]
test rcx, rcx
je 0x1400475df
mov rax, qword [rcx]
lea rdx, [rsp + 0xa0]
cmp rcx, rdx
setne dl
mov rax, qword [rax + 0x20]
call qword [0x1400926f0]
nop
xor eax, eax
jmp 0x140047949
mov qword [rsp + 0x98], rdi
call fcn.140062c38
mov rbx, rax
mov qword [rsp + 0x98], rax
mov dword [rsp + 0x94], edi
mov qword [rsp + 0x20], rdi
lea r9, [rsp + 0x94]
mov r8d, dword [rsp + 0x88]
mov rdx, rbx
mov rcx, qword [rsp + 0x80]
call qword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
jne 0x14004769d
call qword [sym.imp.KERNEL32.dll_GetLastError]
mov edi, eax
test rbx, rbx
je 0x140047645
mov rcx, rbx
call fcn.140062610
nop
mov rcx, qword [rsp + 0xd8]
test rcx, rcx
sete dl
test rcx, rcx
je 0x140047696
test dl, dl
jne 0x140047976
mov rax, qword [rcx]
mov rax, qword [rax + 0x10]
call qword [0x1400926f0]
mov rcx, qword [rsp + 0xd8]
test rcx, rcx
je 0x140047696
mov rax, qword [rcx]
lea rdx, [rsp + 0xa0]
cmp rcx, rdx
setne dl
mov rax, qword [rax + 0x20]
call qword [0x1400926f0]
nop
mov eax, edi
jmp 0x140047949
xor r9d, r9d
xor r8d, r8d
xor edx, edx
mov rcx, qword [rsp + 0x80]
call qword [sym.imp.KERNEL32.dll_SetFilePointer]
cmp eax, 0xffffffff
jne 0x140047726
call qword [sym.imp.KERNEL32.dll_GetLastError]
mov edi, eax
test rbx, rbx
je 0x1400476ce
mov rcx, rbx
call fcn.140062610
nop
mov rcx, qword [rsp + 0xd8]
test rcx, rcx
sete dl
test rcx, rcx
je 0x14004771f
test dl, dl
jne 0x14004797c
mov rax, qword [rcx]
mov rax, qword [rax + 0x10]
call qword [0x1400926f0]
mov rcx, qword [rsp + 0xd8]
test rcx, rcx
je 0x14004771f
mov rax, qword [rcx]
lea rdx, [rsp + 0xa0]
cmp rcx, rdx
setne dl
mov rax, qword [rax + 0x20]
call qword [0x1400926f0]
nop
mov eax, edi
jmp 0x140047949
mov word [rsp + 0x90], 0xbbef
mov byte [rsp + 0x92], 0xbf
mov qword [rsp + 0x20], rdi
lea r9, [rsp + 0x94]
mov r8d, 3
lea rdx, [rsp + 0x90]
mov rcx, qword [rsp + 0x80]
call qword [sym.imp.KERNEL32.dll_WriteFile]
test eax, eax
je 0x140047875
cmp dword [rsp + 0x94], 3
jne 0x140047875
mov qword [rsp + 0x20], rdi
lea r9, [rsp + 0x94]
mov r8d, dword [rsp + 0x88]
mov rdx, rbx
mov rcx, qword [rsp + 0x80]
call qword [sym.imp.KERNEL32.dll_WriteFile]
test eax, eax
jne 0x14004780f
call qword [sym.imp.KERNEL32.dll_GetLastError]
mov edi, eax
test rbx, rbx
je 0x1400477b7
mov rcx, rbx
call fcn.140062610
nop
mov rcx, qword [rsp + 0xd8]
test rcx, rcx
sete dl
test rcx, rcx
je 0x140047808
test dl, dl
jne 0x140047982
mov rax, qword [rcx]
mov rax, qword [rax + 0x10]
call qword [0x1400926f0]
mov rcx, qword [rsp + 0xd8]
test rcx, rcx
je 0x140047808
mov rax, qword [rcx]
lea rdx, [rsp + 0xa0]
cmp rcx, rdx
setne dl
mov rax, qword [rax + 0x20]
call qword [0x1400926f0]
nop
mov eax, edi
jmp 0x140047949
test rbx, rbx
je 0x14004781d
mov rcx, rbx
call fcn.140062610
nop
mov rcx, qword [rsp + 0xd8]
test rcx, rcx
sete al
test rcx, rcx
je 0x14004786e
test al, al
jne 0x140047988
mov rax, qword [rcx]
mov rax, qword [rax + 0x10]
call qword [0x1400926f0]
mov rcx, qword [rsp + 0xd8]
test rcx, rcx
je 0x14004786e
mov rax, qword [rcx]
lea rdx, [rsp + 0xa0]
cmp rcx, rdx
setne dl
mov rax, qword [rax + 0x20]
call qword [0x1400926f0]
nop
xor eax, eax
jmp 0x140047949
call qword [sym.imp.KERNEL32.dll_GetLastError]
mov edi, eax
test rbx, rbx
je 0x14004788b
mov rcx, rbx
call fcn.140062610
nop
mov rcx, qword [rsp + 0xd8]
test rcx, rcx
sete dl
test rcx, rcx
je 0x1400478dc
test dl, dl
jne 0x14004798e
mov rax, qword [rcx]
mov rax, qword [rax + 0x10]
call qword [0x1400926f0]
mov rcx, qword [rsp + 0xd8]
test rcx, rcx
je 0x1400478dc
mov rax, qword [rcx]
lea rdx, [rsp + 0xa0]
cmp rcx, rdx
setne dl
mov rax, qword [rax + 0x20]
call qword [0x1400926f0]
nop
mov eax, edi
jmp 0x140047949
mov rcx, qword [rsp + 0xe0]
xor rcx, rsp
call fcn.1400625f0
mov rbx, qword [rsp + 0x100]
add rsp, 0xf0
pop rdi
ret
call fcn.140060868
nop
call fcn.140060868
nop
call fcn.140060868
nop
call fcn.140060868
nop
call fcn.140060868
nop
call fcn.140060868
nop
call fcn.140060868
nop
call fcn.140060868
int3