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

Disassembly:
push rbp
push rbx
push rsi
push rdi
push r12
push r13
push r14
push r15
lea rbp, [rsp - 0x17]
sub rsp, 0xf8
mov qword [rbp - 0x19], 0xfffffffffffffffe
mov rax, qword [0x1402cece8]
xor rax, rsp
mov qword [rbp - 1], rax
mov rbx, r9
mov r12, r8
mov qword [rbp - 0x41], r8
mov dword [rbp - 0x49], edx
mov rdi, rcx
mov qword [rbp - 0x29], rcx
mov r14, qword [rbp + 0x7f]
mov rax, qword [rcx + 0x2010]
cmp dword [rax - 0x10], 0
je 0x140025eaa
mov rax, qword [rcx + 0x2018]
cmp dword [rax - 0x10], 0
je 0x140025eaa
call fcn.140016860
mov rcx, rax
test rax, rax
jne 0x140025b31
mov ecx, 0x80004005
call fcn.140016620
int3
mov rax, qword [rax]
call qword [rax + 0x18]
add rax, 0x18
mov qword [rbp - 0x59], rax
or rsi, 0xffffffffffffffff
test rbx, rbx
je 0x140025b6e
test rbx, 0xffffffffffff0000
jne 0x140025b5f
movzx edx, bx
lea rcx, [rbp - 0x59]
call fcn.140016fb0
jmp 0x140025b80
mov rax, rsi
inc rax
cmp word [rbx + rax*2], 0
jne 0x140025b62
jmp 0x140025b70
xor eax, eax
mov r8d, eax
mov rdx, rbx
lea rcx, [rbp - 0x59]
call fcn.1400164c0
nop
lea r8, [0x140284b80]
lea rdx, [0x14020e3d4]
lea rcx, [rbp - 0x59]
call fcn.140022a80
lea r8, [0x140284b80]
lea rdx, reloc.OLEAUT32.dll_VariantCopyInd
lea rcx, [rbp - 0x59]
call fcn.140022a80
test r14, r14
je 0x140025e8f
xor bl, bl
mov rdx, r14
lea rcx, [rbp - 0x51]
call fcn.140017080
nop
lea r8, [0x140284b80]
lea rdx, [0x14020e3d4]
lea rcx, [rbp - 0x51]
call fcn.140022a80
lea r8, [0x140284b80]
lea rdx, reloc.OLEAUT32.dll_VariantCopyInd
lea rcx, [rbp - 0x51]
call fcn.140022a80
lea r13, [rdi + 0x2030]
mov qword [rbp - 0x21], r13
mov rcx, r13
call qword [sym.imp.KERNEL32.dll_EnterCriticalSection]
mov eax, dword [rdi + 0x2004]
mov ecx, 1
test eax, eax
je 0x140025c2c
cmp dword [rdi + 0x2058], eax
jb 0x140025c2c
mov rcx, rdi
call fcn.140025ed0
mov r14b, 1
jmp 0x140025c3b
movzx r14d, bl
cmp dword [rdi + 0x2058], 2
cmovbe r14d, ecx
xor r15b, r15b
mov rbx, qword [rdi + 0x2020]
call fcn.1400258a0
mov r9, rax
mov qword [rsp + 0x30], 0
mov dword [rsp + 0x28], 0x2000080
mov dword [rsp + 0x20], 4
mov edx, 0x40000000
mov r8d, 1
mov rcx, rbx
call qword [sym.imp.KERNEL32.dll_CreateFileW]
mov rbx, rax
mov qword [rbp - 0x39], rax
lea rcx, [rax - 1]
cmp rcx, 0xfffffffffffffffd
ja 0x140025cda
xor edx, edx
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_GetFileSize]
cmp eax, 0xffffffff
je 0x140025cdd
test eax, eax
jne 0x140025ccf
mov word [rbp - 0x61], 0xfeff
mov qword [rsp + 0x20], 0
lea r9, [rbp - 0x31]
lea r8d, [rax + 2]
lea rdx, [rbp - 0x61]
mov rcx, rbx
call qword [sym.imp.KERNEL32.dll_WriteFile]
mov dword [rdi + 0x2058], 2
jmp 0x140025cd5
mov dword [rdi + 0x2058], eax
mov r15b, 1
jmp 0x140025cdd
xor r15b, r15b
mov r9d, 2
xor r8d, r8d
xor edx, edx
mov rcx, rbx
call qword [sym.imp.KERNEL32.dll_SetFilePointer]
cmp eax, 0xffffffff
je 0x140025e67
test r15b, r15b
je 0x140025e67
xor ecx, ecx
mov dword [rbp - 0x5d], ecx
cmp r14b, 1
jne 0x140025d61
lea rax, str.Type_tPID_tTID_tDateTime_local__tSystem_tContext_tMessage_r_n
lea rdx, str._r_n_r_n_r_n_r_n_r_nType_tPID_tTID_tDateTime_local__tSystem_tContext_tMessage_r_n
cmp dword [rdi + 0x2058], 2
cmovbe rdx, rax
mov rax, rsi
nop word [rax + rax]
lea rax, [rax + 1]
cmp word [rdx + rax*2], cx
jne 0x140025d30
lea r8d, [rax + rax]
mov qword [rsp + 0x20], rcx
lea r9, [rbp - 0x5d]
mov rcx, rbx
call qword [sym.imp.KERNEL32.dll_WriteFile]
mov ecx, dword [rbp - 0x5d]
add dword [rdi + 0x2058], ecx
test eax, eax
je 0x140025e5e
xor eax, eax
mov qword [rbp - 0x11], rax
mov qword [rbp - 9], rax
lea rcx, [rbp - 0x11]
call qword [sym.imp.KERNEL32.dll_GetLocalTime]
test r12, r12
je 0x140025d82
cmp word [r12], 0
jne 0x140025d8d
lea rax, [0x140276550]
mov qword [rbp - 0x41], rax
mov rbx, qword [rbp - 0x51]
movzx esi, word [rbp - 3]
movzx r14d, word [rbp - 5]
movzx r15d, word [rbp - 7]
movzx r12d, word [rbp - 9]
movzx r13d, word [rbp - 0xb]
movzx eax, word [rbp - 0xf]
mov dword [rbp - 0x45], eax
call qword [sym.imp.KERNEL32.dll_GetCurrentThreadId]
mov edi, eax
call qword [sym.imp.KERNEL32.dll_GetCurrentProcessId]
movsxd rdx, dword [rbp - 0x49]
lea r8, section..data
mov qword [rsp + 0x78], rbx
mov rcx, qword [rbp - 0x59]
mov qword [rsp + 0x70], rcx
mov rcx, qword [rbp - 0x41]
mov qword [rsp + 0x68], rcx
mov dword [rsp + 0x60], esi
mov dword [rsp + 0x58], r14d
mov dword [rsp + 0x50], r15d
mov dword [rsp + 0x48], r12d
mov dword [rsp + 0x40], r13d
mov ecx, dword [rbp - 0x45]
mov dword [rsp + 0x38], ecx
mov dword [rsp + 0x30], edi
mov dword [rsp + 0x28], eax
mov rax, qword [r8 + rdx*8]
mov qword [rsp + 0x20], rax
lea r9, str._s_t_4u_t_4u_t_02d__02d__02d:_02d:_02d._03d_t_s_t_s:_t_s_r_n
or rsi, 0xffffffffffffffff
mov r8, rsi
mov edx, 0x1000
mov rbx, qword [rbp - 0x29]
mov rcx, rbx
call fcn.140022860
lea r8d, [rax + rax]
mov qword [rsp + 0x20], 0
lea r9, [rbp - 0x5d]
mov rdx, rbx
mov rcx, qword [rbp - 0x39]
call qword [sym.imp.KERNEL32.dll_WriteFile]
mov eax, dword [rbp - 0x5d]
add dword [rbx + 0x2058], eax
mov rbx, qword [rbp - 0x39]
mov r13, qword [rbp - 0x21]
mov rcx, rbx
call qword [sym.imp.KERNEL32.dll_CloseHandle]
mov rcx, r13
call qword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
nop
mov rdx, qword [rbp - 0x51]
add rdx, 0xffffffffffffffe8
mov eax, esi
lock xadd dword [rdx + 0x10], eax
sub eax, 1
jg 0x140025e8f
mov rcx, qword [rdx]
mov rax, qword [rcx]
call qword [rax + reloc.OLEAUT32.dll_VariantClear]
nop
mov rdx, qword [rbp - 0x59]
add rdx, 0xffffffffffffffe8
lock xadd dword [rdx + 0x10], esi
sub esi, 1
jg 0x140025eaa
mov rcx, qword [rdx]
mov rax, qword [rcx]
call qword [rax + reloc.OLEAUT32.dll_VariantClear]
mov rcx, qword [rbp - 1]
xor rcx, rsp
call fcn.1401c73d0
add rsp, 0xf8
pop r15
pop r14
pop r13
pop r12
pop rdi
pop rsi
pop rbx
pop rbp
ret