Function at 0x1400435e4
Capabilities:
Write file on windows

Disassembly:
mov qword [rsp + 0x10], rdx
push rbp
push rbx
push rsi
push rdi
push r12
push r13
push r14
push r15
mov rbp, rsp
sub rsp, 0x68
mov qword [rbp - 0x20], 0xfffffffffffffffe
mov r14, rdx
mov r13, rcx
or qword [rbp + 0x60], 0xffffffffffffffff
xor ebx, ebx
mov qword [rbp - 0x28], rbx
and dword [rbp + 0x48], ebx
mov esi, 0x100000
and dword [rbp + 0x58], ebx
lea r8, str.CVdsRawDiskLun::CleanDiskThread__
lea edx, [rbx + 0x5e]
lea rcx, [rbp - 0x18]
call qword [sym.imp.vdsutil.dll_public:_void___cdecl_CVdsCallTracer::constructor_unsigned_long_int__char_const____ptr64____ptr64]
nop
lea r8, [rbp + 0x60]
mov edx, 0xc0000000
mov rcx, qword [r13 + 0xd8]
call qword [sym.imp.vdsutil.dll_unsigned_long_int___cdecl_OpenDevice_unsigned_short_int____ptr64__unsigned_long_int__void____ptr64____ptr64_]
mov edi, eax
test eax, eax
je 0x140043674
mov r9d, eax
lea r8, str.CRawDiskLun::Clean__1__error_ld
xor edx, edx
lea ecx, [rbx + 0x5e]
call qword [sym.imp.vdsutil.dll_void___cdecl_VdsTraceEx_unsigned_long_int__unsigned_long_int__char____ptr64_]
movzx esi, di
or esi, 0x80070000
jmp 0x14004383b
mov r15d, 0x80070000
cmp esi, 0x200
jb 0x1400437c7
call qword [sym.imp.api_ms_win_core_heap_l1_2_0.dll_GetProcessHeap]
mov rcx, rax
mov r8d, esi
mov edx, 8
call qword [sym.imp.vdsutil.dll_void____ptr64___cdecl_VdsHeapAlloc_void____ptr64__unsigned_long_int__unsigned_long_long_unsigned___int64__]
mov rbx, rax
mov qword [rbp - 0x28], rax
test rax, rax
jne 0x1400436ad
shr esi, 1
jmp 0x140043674
xor edx, edx
mov eax, 0x100000
div esi
mov r14d, eax
mov r12d, eax
mov eax, 1
xor edi, edi
test r12d, r12d
je 0x140043752
test eax, eax
je 0x140043711
and qword [rsp + 0x20], 0
lea r9, [rbp + 0x48]
mov r8d, esi
mov rdx, rbx
mov rcx, qword [rbp + 0x60]
call qword [sym.imp.api_ms_win_core_file_l1_2_1.dll_WriteFile]
test eax, eax
je 0x140043707
mov eax, dword [rbp + 0x48]
add rdi, rax
xor r9d, r9d
xor r8d, r8d
mov rdx, rdi
mov rcx, qword [rbp + 0x60]
call qword [sym.imp.api_ms_win_core_file_l1_2_1.dll_SetFilePointerEx]
add r12d, 0xffffffff
jne 0x1400436cc
test eax, eax
jne 0x140043752
call qword [sym.imp.api_ms_win_core_errorhandling_l1_1_1.dll_GetLastError]
mov edi, eax
lea ecx, [r14 - 1]
mov r9d, eax
xor edx, edx
cmp r12d, ecx
lea ecx, [rdx + 0x5e]
lea r8, str.CRawDiskLun::Clean__3__error_ld
je 0x140043738
lea r8, str.CRawDiskLun::Clean__4__error_ld
call qword [sym.imp.vdsutil.dll_void___cdecl_VdsTraceEx_unsigned_long_int__unsigned_long_int__char____ptr64_]
movzx esi, di
or esi, r15d
test edi, edi
cmovle esi, edi
mov r14, qword [rbp + 0x50]
jmp 0x1400437e1
mov rdx, qword [r13 + 0xa0]
sub rdx, 0x100000
xor r9d, r9d
xor r8d, r8d
mov rcx, qword [rbp + 0x60]
call qword [sym.imp.api_ms_win_core_file_l1_2_1.dll_SetFilePointerEx]
test eax, eax
je 0x1400437a2
mov eax, 1
test r14d, r14d
je 0x1400437c3
test eax, eax
je 0x1400437a2
and qword [rsp + 0x20], 0
lea r9, [rbp + 0x48]
mov r8d, esi
mov rdx, rbx
mov rcx, qword [rbp + 0x60]
call qword [sym.imp.api_ms_win_core_file_l1_2_1.dll_WriteFile]
add r14d, 0xffffffff
jne 0x14004377e
cmp eax, 1
je 0x1400437c3
call qword [sym.imp.api_ms_win_core_errorhandling_l1_1_1.dll_GetLastError]
mov edi, eax
mov r9d, eax
lea r8, str.CRawDiskLun::CleanDiskThread__5__error_ld
xor edx, edx
lea ecx, [rdx + 0x5e]
jmp 0x140043738
xor esi, esi
jmp 0x140043749
mov esi, 0x8007000e
mov r9d, esi
lea r8, str.CRawDiskLun::Clean__2__hr_lX
xor edx, edx
lea ecx, [rdx + 0x5e]
call qword [sym.imp.vdsutil.dll_void___cdecl_VdsTraceEx_unsigned_long_int__unsigned_long_int__char____ptr64_]
and qword [rsp + 0x38], 0
lea rax, [rbp + 0x58]
mov qword [rsp + 0x30], rax
and dword [rsp + 0x28], 0
and qword [rsp + 0x20], 0
xor r9d, r9d
xor r8d, r8d
mov edx, 0x70140
mov rcx, qword [rbp + 0x60]
call qword [sym.imp.api_ms_win_core_io_l1_1_1.dll_DeviceIoControl]
test eax, eax
jne 0x140043840
call qword [sym.imp.api_ms_win_core_errorhandling_l1_1_1.dll_GetLastError]
mov edi, eax
mov r9d, eax
lea r8, str.CRawDiskLun::CleanDiskThread__6___ld
xor edx, edx
lea ecx, [rdx + 0x5e]
call qword [sym.imp.vdsutil.dll_void___cdecl_VdsTraceEx_unsigned_long_int__unsigned_long_int__char____ptr64_]
test esi, esi
jne 0x140043840
movzx esi, di
or esi, r15d
test edi, edi
cmovle esi, edi
xor r8d, r8d
lea eax, [r8 + 0x64]
test esi, esi
cmovns r8d, eax
mov edx, esi
mov rcx, qword [r14 + 8]
call qword [sym.imp.vdsutil.dll_public:_void___cdecl_CVdsAsyncObjectBase::SetCompletionStatus_long_int__unsigned_long_int____ptr64]
mov rcx, qword [r14 + 8]
call qword [sym.imp.vdsutil.dll_public:_void___cdecl_CVdsAsyncObjectBase::Signal_void____ptr64]
mov rsi, qword [r14 + 8]
mov rax, qword [rsi]
mov rdi, qword [rax + 0x10]
mov rcx, rdi
call qword [sym.vds.exe_public:_void___cdecl_CVdsPtr_char_::destructor_void____ptr64]
mov rcx, rsi
call rdi
nop
lea rcx, [rbp - 0x18]
call qword [sym.imp.vdsutil.dll_public:_void___cdecl_CVdsCallTracer::destructor_void____ptr64]
nop
test rbx, rbx
je 0x1400438a6
call qword [sym.imp.api_ms_win_core_heap_l1_2_0.dll_GetProcessHeap]
mov rcx, rax
mov r8, rbx
xor edx, edx
call qword [sym.imp.vdsutil.dll_int___cdecl_VdsHeapFree_void____ptr64__unsigned_long_int__void____ptr64_]
and qword [rbp - 0x28], 0
mov rcx, qword [rbp + 0x60]
lea rax, [rcx - 1]
cmp rax, 0xfffffffffffffffd
ja 0x1400438bf
call qword [sym.imp.api_ms_win_core_handle_l1_1_0.dll_CloseHandle]
or qword [rbp + 0x60], 0xffffffffffffffff
xor eax, eax
add rsp, 0x68
pop r15
pop r14
pop r13
pop r12
pop rdi
pop rsi
pop rbx
pop rbp
ret