Function at 0x140069e80
Capabilities:
Write file on windows

Disassembly:
push rbp
push rbx
push rsi
push rdi
push r12
push r14
push r15
lea rbp, [rsp - 0x460]
sub rsp, 0x560
mov r15, rdx
mov rbx, rcx
xor edx, edx
lea rcx, [rbp + 0x50]
mov r8d, 0x400
call fcn.14014e180
lea rsi, [r15 + 0x1c]
xor r12d, r12d
mov rdi, 0xffffffffffffffff
cmp word [rsi], r12w
jne 0x140069ee6
test rsi, rsi
je 0x140069ee6
mov r9, rdi
lea r8, [0x1401ba4bc]
mov edx, 0x200
mov rcx, rsi
call fcn.14003c5c8
mov r8, rsi
jmp 0x140069eee
mov r8, rsi
test rsi, rsi
je 0x140069f3c
mov qword [rsp + 0x38], r12
lea rax, [rbp + 0x50]
mov qword [rsp + 0x30], r12
mov r9d, edi
mov dword [rsp + 0x28], 0x400
xor edx, edx
xor ecx, ecx
mov qword [rsp + 0x20], rax
call qword [sym.imp.KERNEL32.dll_WideCharToMultiByte]
test eax, eax
jg 0x140069f3c
jne 0x140069f33
call qword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 0x7a
jne 0x140069f33
mov byte [rbp + 0x44f], r12b
mov rax, rsi
jmp 0x140069f44
mov byte [rbp + 0x50], r12b
mov rax, rsi
jmp 0x140069f44
mov rax, rsi
test rsi, rsi
je 0x140069f5c
mov r9, rdi
nop word [rax + rax]
inc r9
cmp word [rax + r9*2], r12w
jne 0x140069f50
jmp 0x140069f5f
mov r9d, r12d
mov qword [rsp + 0x38], r12
mov r8, rsi
mov qword [rsp + 0x30], r12
xor edx, edx
mov dword [rsp + 0x28], r12d
mov ecx, 0xfde9
mov qword [rsp + 0x20], r12
call qword [sym.imp.KERNEL32.dll_WideCharToMultiByte]
movsxd r14, eax
test rsi, rsi
je 0x140069f9c
nop dword [rax + rax]
inc rdi
cmp word [rsi + rdi*2], r12w
jne 0x140069f90
jmp 0x140069f9f
mov edi, r12d
mov qword [rsp + 0x38], r12
lea rax, [rbp + 0x50]
mov qword [rsp + 0x30], r12
mov r9d, edi
mov dword [rsp + 0x28], 0x400
mov r8, rsi
xor edx, edx
mov qword [rsp + 0x20], rax
mov ecx, 0xfde9
call qword [sym.imp.KERNEL32.dll_WideCharToMultiByte]
cmp byte [rbx + 0x240], r12b
je 0x140069fde
mov rcx, rbx
call fcn.1400698b0
mov eax, dword [r15 + 0x10]
test eax, eax
jne 0x14006a043
lea rcx, [rbp - 0x60]
call qword [sym.imp.KERNEL32.dll_GetTimeZoneInformation]
lea r8, [rbp - 0x78]
mov rdx, r15
lea rcx, [rbp - 0x60]
call qword [sym.imp.KERNEL32.dll_SystemTimeToTzSpecificLocalTime]
lea rdx, [rbp - 0x80]
lea rcx, [rbp - 0x78]
call qword [sym.imp.KERNEL32.dll_SystemTimeToFileTime]
lea r8, [rbp + 0x4a0]
lea rdx, [rbp + 0x4a8]
lea rcx, [rbp - 0x80]
call qword [sym.imp.KERNEL32.dll_FileTimeToDosDateTime]
movzx eax, word [rbp + 0x4a0]
mov word [rsp + 0x68], ax
movzx eax, word [rbp + 0x4a8]
mov word [rsp + 0x6a], ax
mov eax, dword [rsp + 0x68]
mov dword [rbx + 0x2d8], eax
mov dword [rbx + 0x2c4], 0x800
mov dword [rbx + 0x2dc], r12d
mov dword [rbx + 0x2c8], 8
mov qword [rbx + 0x2a8], r12
mov rax, qword [r15 + 0x420]
mov qword [rbx + 0x2e0], rax
mov dword [rbx + 0x2e8], r14d
mov rcx, qword [rbx + 0x228]
cmp rcx, 0xffffffffffffffff
je 0x14006a60e
mov r9d, 1
mov qword [rsp + 0x78], r12
lea r8, [rsp + 0x7c]
xor edx, edx
call qword [sym.imp.KERNEL32.dll_SetFilePointer]
mov esi, 0xffffffff
mov dword [rsp + 0x78], eax
cmp eax, esi
jne 0x14006a0c4
call qword [sym.imp.KERNEL32.dll_GetLastError]
test eax, eax
jne 0x14006a60e
cmp qword [rsp + 0x78], 0xffffffffffffffff
je 0x14006a60e
lea rcx, [rbx + 0x220]
call fcn.1400044c0
mov dword [rbx + 0x2b0], eax
cmp qword [r15 + 0x420], rsi
jb 0x14006a0f2
mov byte [rbx + 0x2ec], 1
lea eax, [r14 + 0x2e]
mov ecx, eax
lea rdx, [0x1401ae572]
mov dword [rbx + 0x2c0], eax
call fcn.14002ec60
mov qword [rbx + 0x2b8], rax
test rax, rax
je 0x14006a60e
mov dword [rax], 0x2014b50
mov rax, qword [rbx + 0x2b8]
mov qword [rsp + 0x558], r13
mov r13d, 0x2d
mov word [rax + 4], r12w
mov eax, shutdown
mov rcx, qword [rbx + 0x2b8]
cmp byte [rbx + 0x2ec], r12b
cmovne eax, r13d
mov byte [rcx + 6], al
mov byte [rcx + 7], r12b
mov ecx, dword [rbx + 0x2c4]
mov rax, qword [rbx + 0x2b8]
mov byte [rax + 8], cl
shr ecx, 8
mov byte [rax + 9], cl
mov ecx, dword [rbx + 0x2c8]
mov rax, qword [rbx + 0x2b8]
mov byte [rax + 0xa], cl
shr ecx, 8
mov byte [rax + 0xb], cl
mov ecx, dword [rbx + 0x2d8]
mov rax, qword [rbx + 0x2b8]
mov byte [rax + 0xc], cl
shr ecx, 8
mov byte [rax + 0xd], cl
shr ecx, 8
mov byte [rax + 0xe], cl
shr ecx, 8
mov byte [rax + 0xf], cl
mov rax, qword [rbx + 0x2b8]
mov dword [rax + 0x10], r12d
mov rax, qword [rbx + 0x2b8]
mov dword [rax + 0x14], esi
mov rax, qword [rbx + 0x2b8]
mov dword [rax + 0x18], esi
mov eax, r14d
mov rcx, qword [rbx + 0x2b8]
lea rsi, [rbp + 0x50]
shr eax, 8
mov byte [rcx + 0x1d], al
mov byte [rcx + 0x1c], r14b
mov rax, qword [rbx + 0x2b8]
mov word [rax + 0x1e], r12w
mov rax, qword [rbx + 0x2b8]
mov word [rax + 0x20], r12w
mov rax, qword [rbx + 0x2b8]
mov word [rax + 0x22], r12w
mov ecx, dword [r15 + 0x14]
mov rax, qword [rbx + 0x2b8]
mov byte [rax + 0x24], cl
shr ecx, 8
mov byte [rax + 0x25], cl
mov ecx, dword [r15 + 0x18]
mov rax, qword [rbx + 0x2b8]
mov byte [rax + 0x26], cl
shr ecx, 8
mov byte [rax + 0x27], cl
shr ecx, 8
mov byte [rax + 0x28], cl
shr ecx, 8
mov byte [rax + 0x29], cl
mov ecx, dword [rbx + 0x2b0]
mov rax, qword [rbx + 0x2b8]
mov byte [rax + 0x2a], cl
shr ecx, 8
mov byte [rax + 0x2b], cl
shr ecx, 8
mov byte [rax + 0x2c], cl
shr ecx, 8
mov byte [rax + 0x2d], cl
mov rcx, r14
mov rdx, qword [rbx + 0x2b8]
mov rax, r14
shr rcx, 2
add rdx, 0x2e
mov rdi, rdx
rep movsd dword [rdi], dword [rsi]
mov rcx, r14
and ecx, 3
je 0x14006a290
and rax, 0xfffffffffffffffc
lea rsi, [rbp + 0x50]
add rsi, rax
lea rdi, [rdx + rax]
rep movsb byte [rdi], byte [rsi]
nop word [rax + rax]
mov rcx, qword [rbx + 0x228]
mov eax, r12d
mov dword [rbp + 0x4b0], 0x4034b50
mov dword [rsp + 0x4c], eax
cmp rcx, 0xffffffffffffffff
je 0x14006a2dc
lea r9, [rsp + 0x4c]
mov qword [rsp + 0x20], r12
mov r8d, 4
lea rdx, [rbp + 0x4b0]
call qword [sym.imp.KERNEL32.dll_WriteFile]
test eax, eax
jne 0x14006a2d8
mov eax, r12d
mov dword [rsp + 0x4c], eax
jmp 0x14006a2dc
mov eax, dword [rsp + 0x4c]
lock add qword [0x1401f4d68], rax
cmp byte [rbx + 0x2ec], r12b
mov edx, shutdown
mov r8d, 2
mov rcx, rbx
cmovne edx, r13d
call fcn.14006a6c0
mov eax, dword [rbx + 0x2c4]
mov rcx, qword [rbx + 0x228]
mov r13, qword [rsp + 0x558]
mov byte [rsp + 0x6c], al
shr eax, 8
mov byte [rsp + 0x6d], al
mov eax, r12d
mov dword [rsp + 0x50], eax
cmp rcx, 0xffffffffffffffff
je 0x14006a35b
lea r9, [rsp + 0x50]
mov qword [rsp + 0x20], r12
mov r8d, 2
lea rdx, [rsp + 0x6c]
call qword [sym.imp.KERNEL32.dll_WriteFile]
test eax, eax
jne 0x14006a357
mov eax, r12d
mov dword [rsp + 0x50], eax
jmp 0x14006a35b
mov eax, dword [rsp + 0x50]
lock add qword [0x1401f4d68], rax
mov eax, dword [rbx + 0x2c8]
mov rcx, qword [rbx + 0x228]
mov byte [rsp + 0x70], al
shr eax, 8
mov byte [rsp + 0x71], al
mov eax, r12d
mov dword [rsp + 0x54], eax
cmp rcx, 0xffffffffffffffff
je 0x14006a3b4
lea r9, [rsp + 0x54]
mov qword [rsp + 0x20], r12
mov r8d, 2
lea rdx, [rsp + 0x70]
call qword [sym.imp.KERNEL32.dll_WriteFile]
test eax, eax
jne 0x14006a3b0
mov eax, r12d
mov dword [rsp + 0x54], eax
jmp 0x14006a3b4
mov eax, dword [rsp + 0x54]
lock add qword [0x1401f4d68], rax
mov edx, dword [rbx + 0x2d8]
mov r8d, 4
mov rcx, rbx
call fcn.14006a6c0
mov rcx, qword [rbx + 0x228]
mov eax, r12d
mov dword [rbp + 0x4b8], r12d
mov dword [rsp + 0x58], eax
cmp rcx, 0xffffffffffffffff
je 0x14006a419
lea r9, [rsp + 0x58]
mov qword [rsp + 0x20], r12
mov r8d, 4
lea rdx, [rbp + 0x4b8]
call qword [sym.imp.KERNEL32.dll_WriteFile]
test eax, eax
jne 0x14006a415
mov eax, r12d
mov dword [rsp + 0x58], eax
jmp 0x14006a419
mov eax, dword [rsp + 0x58]
lock add qword [0x1401f4d68], rax
mov rcx, qword [rbx + 0x228]
mov eax, r12d
mov dword [rsp + 0x40], 0xffffffff
mov dword [rsp + 0x5c], eax
cmp rcx, 0xffffffffffffffff
je 0x14006a469
lea r9, [rsp + 0x5c]
mov qword [rsp + 0x20], r12
mov r8d, 4
lea rdx, [rsp + 0x40]
call qword [sym.imp.KERNEL32.dll_WriteFile]
test eax, eax
jne 0x14006a465
mov eax, r12d
mov dword [rsp + 0x5c], eax
jmp 0x14006a469
mov eax, dword [rsp + 0x5c]
lock add qword [0x1401f4d68], rax
mov rcx, qword [rbx + 0x228]
mov eax, r12d
mov dword [rsp + 0x44], 0xffffffff
mov dword [rsp + 0x60], eax
cmp rcx, 0xffffffffffffffff
je 0x14006a4b9
lea r9, [rsp + 0x60]
mov qword [rsp + 0x20], r12
mov r8d, 4
lea rdx, [rsp + 0x44]
call qword [sym.imp.KERNEL32.dll_WriteFile]
test eax, eax
jne 0x14006a4b5
mov eax, r12d
mov dword [rsp + 0x60], eax
jmp 0x14006a4b9
mov eax, dword [rsp + 0x60]
lock add qword [0x1401f4d68], rax
mov r8d, 2
mov edx, r14d
mov rcx, rbx
call fcn.14006a6c0
movzx eax, byte [rbx + 0x2ec]
mov r8d, 2
neg al
mov rcx, rbx
sbb edx, edx
and edx, 0x14
call fcn.14006a6c0
mov rcx, qword [rbx + 0x228]
mov eax, r12d
mov dword [rsp + 0x48], eax
cmp rcx, 0xffffffffffffffff
je 0x14006a52f
test r14d, r14d
je 0x14006a52f
lea r9, [rsp + 0x48]
mov qword [rsp + 0x20], r12
mov r8d, r14d
lea rdx, [rbp + 0x50]
call qword [sym.imp.KERNEL32.dll_WriteFile]
test eax, eax
jne 0x14006a52b
mov eax, r12d
mov dword [rsp + 0x48], eax
jmp 0x14006a52f
mov eax, dword [rsp + 0x48]
lock add qword [0x1401f4d68], rax
cmp dword [rsp + 0x48], r14d
jne 0x14006a60e
cmp byte [rbx + 0x2ec], r12b
je 0x14006a595
mov rcx, qword [rbx + 0x228]
mov eax, r12d
mov dword [rsp + 0x64], eax
cmp rcx, 0xffffffffffffffff
je 0x14006a58d
lea r9, [rsp + 0x64]
mov qword [rsp + 0x20], r12
mov r8d, shutdown
lea rdx, str.reserv_for_extra_fld
call qword [sym.imp.KERNEL32.dll_WriteFile]
test eax, eax
jne 0x14006a589
mov eax, r12d
mov dword [rsp + 0x64], eax
jmp 0x14006a58d
mov eax, dword [rsp + 0x64]
lock add qword [0x1401f4d68], rax
mov rax, qword [rbx + 0x2d0]
test rax, rax
jne 0x14006a5be
lea rdx, [0x1401ae572]
mov ecx, 0x100000
call fcn.14002ec60
mov qword [rbx + 0x2d0], rax
test rax, rax
je 0x14006a60e
mov edx, dword [rbx]
lea rcx, [rbx + 0x248]
mov dword [rbx + 0x250], r12d
mov dword [rbx + 0x268], 0x100000
mov qword [rbx + 0x260], rax
mov qword [rbx + 0x258], r12
mov qword [rbx + 0x270], r12
call fcn.140079270
test eax, 0xfffffffd
jne 0x14006a60e
mov dword [rbx + 0x2a8], 1
mov al, 1
mov byte [rbx + 0x240], 1
jmp 0x14006a610
xor al, al
add rsp, 0x560
pop r15
pop r14
pop r12
pop rdi
pop rsi
pop rbx
pop rbp
ret