Function at 0x14002b07c
Capabilities:
Get file size
Write file on windows

Disassembly:
push rbx
push rsi
push rdi
push r12
push r13
push r14
push r15
sub rsp, 0x2d0
mov qword [rsp + 0x70], 0xfffffffffffffffe
mov rax, qword [0x14009b940]
xor rax, rsp
mov qword [rsp + 0x2c0], rax
mov r12, r8
mov r15, rdx
mov r13d, ecx
mov dword [rsp + 0x48], ecx
mov qword [rsp + 0x68], r8
or rsi, 0xffffffffffffffff
xor eax, eax
mov qword [rsp + 0x58], rax
xor ebx, ebx
mov edi, ebx
lea r14, [0x14009b028]
mov rcx, qword [0x14009b028]
cmp rcx, r14
je 0x14002b0fd
test byte [rcx + 0x1c], 4
je 0x14002b0fd
cmp byte [rcx + 0x19], 5
jb 0x14002b0fd
lea edx, [rsi + 0x54]
lea r8, [0x140088d60]
mov rcx, qword [rcx + 0x10]
call fcn.140001024
lea rcx, str.InboxLOG.txt
lea rax, str.OutboxLOG.txt
test r13d, r13d
cmove rax, rcx
mov qword [rsp + 0x20], rax
mov r9, r15
lea r8, [0x140088010]
mov edx, 0x104
lea rcx, [rsp + 0xb0]
call fcn.140002ac0
mov r15d, eax
test eax, eax
jns 0x14002b188
mov rcx, qword [0x14009b028]
cmp rcx, r14
je 0x14002b16a
test byte [rcx + 0x1c], 4
je 0x14002b16a
cmp byte [rcx + 0x19], 2
jb 0x14002b16a
mov edx, 0x54
mov r9d, eax
lea r8, [0x140088d60]
mov rcx, qword [rcx + 0x10]
call fcn.140001050
mov ecx, r15d
and ecx, 0x1fff0000
movzx eax, r15w
mov edi, r15d
cmp ecx, 0x70000
cmove edi, eax
jmp 0x14002b3cb
mov dword [rsp + 0x28], 0x80
mov dword [rsp + 0x20], 4
mov edx, 0x40000000
mov r8d, 1
lea rcx, [rsp + 0xb0]
call fcn.140069cbc
mov rsi, rax
mov qword [rsp + 0x60], rax
cmp rax, 0xffffffffffffffff
jne 0x14002b20b
call qword [sym.imp.KERNEL32.dll_GetLastError]
nop dword [rax + rax]
mov edi, eax
mov rcx, qword [0x14009b028]
cmp rcx, r14
je 0x14002b3cb
test byte [rcx + 0x1c], 4
je 0x14002b3cb
cmp byte [rcx + 0x19], 2
jb 0x14002b3cb
lea edx, [rsi + 0x56]
mov r9d, eax
lea r8, [0x140088d60]
mov rcx, qword [rcx + 0x10]
call fcn.140001050
jmp 0x14002b3cb
lea rdx, [rsp + 0x58]
mov rcx, rsi
call qword [sym.imp.KERNEL32.dll_GetFileSizeEx]
nop dword [rax + rax]
test eax, eax
jne 0x14002b25c
call qword [sym.imp.KERNEL32.dll_GetLastError]
nop dword [rax + rax]
mov edi, eax
mov rcx, qword [0x14009b028]
cmp rcx, r14
je 0x14002b3cb
test byte [rcx + 0x1c], 4
je 0x14002b3cb
cmp byte [rcx + 0x19], 2
jb 0x14002b3cb
mov edx, 0x56
jmp 0x14002b1f3
mov rcx, rsi
cmp qword [rsp + 0x58], rbx
jne 0x14002b439
mov eax, 0xfeff
mov word [rsp + 0x40], ax
mov qword [rsp + 0x20], rbx
lea r9, [rsp + 0x50]
mov r8d, 2
lea rdx, [rsp + 0x40]
call qword [sym.imp.KERNEL32.dll_WriteFile]
nop dword [rax + rax]
test eax, eax
jne 0x14002b2d5
call qword [sym.imp.KERNEL32.dll_GetLastError]
nop dword [rax + rax]
mov edi, eax
mov rcx, qword [0x14009b028]
cmp rcx, r14
je 0x14002b3cb
test byte [rcx + 0x1c], 4
je 0x14002b3cb
cmp byte [rcx + 0x19], 2
jb 0x14002b3cb
mov edx, 0x57
jmp 0x14002b1f3
mov qword [rsp + 0xa0], 7
mov qword [rsp + 0x98], rbx
mov word [rsp + 0x88], bx
lea rax, str.Inbox
lea rcx, str.Outbox
test r13d, r13d
cmove rcx, rax
lea rdx, [rsp + 0x80]
call fcn.140027d94
nop
lea rdx, [rsp + 0x88]
cmp qword [rsp + 0xa0], 8
cmovae rdx, qword [rsp + 0x88]
mov r8d, dword [rsp + 0x98]
add r8d, r8d
mov qword [rsp + 0x20], rbx
lea r9, [rsp + 0x50]
mov rcx, rsi
call qword [sym.imp.KERNEL32.dll_WriteFile]
nop dword [rax + rax]
test eax, eax
jne 0x14002b3af
call qword [sym.imp.KERNEL32.dll_GetLastError]
nop dword [rax + rax]
mov edi, eax
mov rcx, qword [0x14009b028]
cmp rcx, r14
je 0x14002b395
test byte [rcx + 0x1c], 4
je 0x14002b395
cmp byte [rcx + 0x19], 2
jb 0x14002b395
mov edx, 0x59
mov r9d, eax
lea r8, [0x140088d60]
mov rcx, qword [rcx + 0x10]
call fcn.140001050
nop
cmp qword [rsp + 0xa0], 8
jb 0x14002b3cb
mov rcx, qword [rsp + 0x88]
call fcn.14007e7a4
jmp 0x14002b3cb
cmp qword [rsp + 0xa0], 8
jb 0x14002b3c7
mov rcx, qword [rsp + 0x88]
call fcn.14007e7a4
mov qword [r12], rsi
test edi, edi
je 0x14002b55d
cmp qword [r12], 0xffffffffffffffff
je 0x14002b3ef
mov rcx, qword [r12]
call qword [sym.imp.KERNEL32.dll_CloseHandle]
nop dword [rax + rax]
or qword [r12], 0xffffffffffffffff
test r13d, r13d
jne 0x14002b495
mov dword [0x14009f294], ebx
jmp 0x14002b49b
mov r9d, 2
xor r8d, r8d
xor edx, edx
call qword [sym.imp.KERNEL32.dll_SetFilePointer]
nop dword [rax + rax]
cmp eax, 0xffffffff
jne 0x14002b3c7
call qword [sym.imp.KERNEL32.dll_GetLastError]
nop dword [rax + rax]
mov edi, eax
mov rcx, qword [0x14009b028]
cmp rcx, r14
je 0x14002b3cb
test byte [rcx + 0x1c], 4
je 0x14002b3cb
cmp byte [rcx + 0x19], 2
jb 0x14002b3cb
mov edx, 0x5a
jmp 0x14002b1f3
mov dword [0x14009f298], ebx
mov dword [rsp + 0x80], edi
mov word [rsp + 0x84], bx
mov r9d, edi
lea r8, [0x140087fd0]
mov edx, reloc.OLEAUT32.dll_VariantTimeToDosDateTime
lea rcx, [rsp + 0x84]
call fcn.140002ac0
lea r8, [rsp + 0x84]
test eax, eax
cmovs r8, rbx
neg r13d
sbb edx, edx
add edx, 3
mov qword [rsp + 0x28], r8
mov rax, qword [0x14009f2a0]
mov qword [rsp + 0x20], rax
mov ecx, 1
mov r9d, 0xc0007d3c
lea r8d, [rcx + 1]
call fcn.140067590
cmp rsi, 0xffffffffffffffff
je 0x14002b55d
mov rcx, rsi
call qword [sym.imp.KERNEL32.dll_CloseHandle]
nop dword [rax + rax]
test eax, eax
jne 0x14002b55d
mov rax, qword [0x14009b028]
cmp rax, r14
je 0x14002b55d
test byte [rax + 0x1c], 4
je 0x14002b55d
cmp byte [rax + 0x19], 2
jb 0x14002b55d
call qword [sym.imp.KERNEL32.dll_GetLastError]
nop dword [rax + rax]
mov r9d, eax
mov edx, 0x5b
lea r8, [0x140088d60]
mov rcx, qword [0x14009b028]
mov rcx, qword [rcx + 0x10]
call fcn.140001050
mov eax, edi
mov rcx, qword [rsp + 0x2c0]
xor rcx, rsp
call fcn.14007ec50
add rsp, 0x2d0
pop r15
pop r14
pop r13
pop r12
pop rdi
pop rsi
pop rbx
ret