Function at 0x1400373d0
Capabilities:
Clear file content

Disassembly:
mov qword [rsp + 0x18], r8
mov qword [rsp + 0x10], rdx
push rbx
push r14
push r15
sub rsp, 0x90
mov r15, r9
mov r14, rcx
test r8, r8
je 0x1400377eb
xor ebx, ebx
mov qword [r8], 0xffffffffffffffff
test r9, r9
je 0x140037406
mov dword [r9], ebx
test r14, r14
je 0x1400377eb
lea rcx, [rsp + 0xb8]
call fcn.1400453b0
test eax, eax
js 0x14003775e
mov qword [rsp + 0xb0], rbp
mov edx, 0x100
mov qword [rsp + 0x88], rsi
mov ebp, 3
mov rsi, qword [rsp + 0xb8]
mov rax, rsi
mov qword [rsp + 0x80], rdi
and eax, 0x700
mov qword [rsp + 0x78], r12
lea r9d, [rbp + 2]
cmp rax, rdx
je 0x14003749b
cmp rax, 0x200
je 0x140037494
cmp rax, 0x300
je 0x14003748d
cmp rax, 0x700
jne case.0x140037588.17
bt rsi, 0xc
mov edi, ebp
cmovb edi, r9d
jmp 0x1400374a0
mov edi, 2
jmp 0x1400374a0
mov edi, 1
jmp 0x1400374a0
mov edi, 4
mov rcx, rsi
and ecx, ebp
mov eax, ecx
test rcx, rcx
je 0x1400374ed
sub rax, 1
je 0x1400374e6
sub rax, 1
je 0x1400374d4
cmp rax, 1
jne case.0x140037588.17
mov rax, rsi
shr rax, 1
not eax
and eax, 2
or eax, 0x12019d
jmp 0x1400374fc
mov rax, rsi
shr rax, 1
not eax
and eax, 2
or eax, 0x120114
jmp 0x1400374fc
mov eax, 0x120089
jmp 0x1400374fc
test rsi, 0x30000
je case.0x140037588.17
mov eax, ebx
mov r12d, eax
bts r12d, 0x1e
cmp edi, r9d
cmovne r12d, eax
mov rax, rsi
and eax, 0x30000
cmp rax, 0x10000
je 0x14003754f
cmp rax, 0x20000
je 0x140037548
cmp rax, 0x30000
je 0x140037541
sub rcx, 1
je 0x14003754f
sub rcx, 1
je 0x140037548
cmp rcx, 1
jne case.0x140037588.17
mov eax, 0x100180
jmp 0x140037554
mov eax, 0x100100
jmp 0x140037554
mov eax, 0x100080
or r12d, eax
mov rax, rsi
and eax, 0xf0
add rax, 0xfffffffffffffff0
cmp rax, 0x70
ja case.0x140037588.17
lea r8, [0x140000000]
movzx eax, byte [r8 + rax + 0x37824]
mov ecx, dword [r8 + rax*4 + 0x37800]
add rcx, r8
jmp rcx
mov ebp, 2
jmp case.0x140037588.128
mov ebp, 1
jmp case.0x140037588.128
mov ebp, ebx
jmp case.0x140037588.128
mov ebp, 7
jmp case.0x140037588.128
mov ebp, 6
jmp case.0x140037588.128
mov ebp, r9d
jmp case.0x140037588.128
mov ebp, 4
mov qword [rsp + 0x70], r13
mov r13, rbx
bt rsi, 0xd
jae 0x1400375dd
mov dword [rsp + 0x50], 0x18
lea r13, [rsp + 0x50]
mov qword [rsp + 0x58], rbx
mov dword [rsp + 0x60], 1
mov rax, rsi
mov ecx, 0x80
and eax, 0x40000000
cmove edx, ecx
test rax, rax
je 0x1400375ff
bts rsi, 0x1a
mov qword [rsp + 0xb8], rsi
mov ecx, edx
mov rax, rsi
and eax, 0x8000
bts ecx, 0x1f
test rax, rax
mov rax, rsi
cmove ecx, edx
and eax, 0x40000
mov edx, ecx
bts edx, 0x1e
test rax, rax
cmove edx, ecx
xor r8d, r8d
mov dword [rsp + 0x40], edx
lea rcx, [rsp + 0x48]
mov rdx, r14
and esi, 0x80000
call fcn.14005d980
mov r14d, eax
test eax, eax
js 0x1400377d9
mov ecx, dword [rsp + 0x40]
mov edx, r12d
bts ecx, 0x1d
mov qword [rsp + 0x30], rbx
test rsi, rsi
mov r9, r13
mov r8d, ebp
cmove ecx, dword [rsp + 0x40]
and edx, 0xfffffffb
mov dword [rsp + 0x28], ecx
test rsi, rsi
mov rcx, qword [rsp + 0x48]
cmove edx, r12d
mov dword [rsp + 0x20], edi
call qword [sym.imp.KERNEL32.dll_CreateFileW]
mov rsi, rax
call qword [sym.imp.KERNEL32.dll_GetLastError]
cmp rsi, 0xffffffffffffffff
je 0x1400377af
sub edi, 1
je 0x1400376d8
sub edi, 1
je 0x1400376cb
sub edi, 1
je 0x1400376c4
sub edi, 1
je 0x1400376b8
cmp edi, 1
jne 0x1400376dd
lea ebx, [rdi + 3]
jmp 0x1400376dd
cmp eax, 0xb7
setne bl
inc ebx
jmp 0x1400376dd
mov ebx, 1
jmp 0x1400376dd
cmp eax, 0xb7
sete bl
add ebx, 2
jmp 0x1400376dd
mov ebx, 2
mov rcx, qword [rsp + 0xb8]
bt rcx, 0xb
jae 0x14003776b
lea eax, [rbx - 2]
cmp eax, 1
ja 0x14003776b
mov rcx, qword [rsp + 0x48]
mov edx, 0x2000
call qword [sym.imp.KERNEL32.dll_SetFileAttributesW]
test eax, eax
jne 0x140037718
call qword [sym.imp.KERNEL32.dll_GetLastError]
mov ecx, eax
call fcn.14005db40
mov r14d, eax
test r15, r15
je 0x140037720
mov dword [r15], ebx
test r14d, r14d
js 0x140037797
mov rax, qword [rsp + 0xc0]
mov rcx, qword [rsp + 0x48]
mov qword [rax], rsi
call fcn.14005d970
xor eax, eax
mov r13, qword [rsp + 0x70]
mov rdi, qword [rsp + 0x80]
mov rsi, qword [rsp + 0x88]
mov rbp, qword [rsp + 0xb0]
mov r12, qword [rsp + 0x78]
add rsp, 0x90
pop r15
pop r14
pop rbx
ret
and ecx, 0x1700
cmp rcx, 0x1100
jne 0x140037718
cmp ebx, 1
jne 0x140037718
mov rcx, rsi
call qword [sym.imp.KERNEL32.dll_SetEndOfFile]
test eax, eax
je 0x140037708
mov ebx, 4
jmp 0x140037718
mov rcx, rsi
call qword [sym.imp.KERNEL32.dll_CloseHandle]
mov rcx, qword [rsp + 0x48]
call fcn.14005d970
mov eax, r14d
jmp 0x14003773c
test r15, r15
je 0x1400377c5
cmp edi, 1
jne 0x1400377c5
cmp eax, 0x50
jne 0x1400377c5
mov dword [r15], 5
mov ecx, eax
call fcn.14005db40
mov rcx, qword [rsp + 0x48]
mov r14d, eax
call fcn.14005d970
mov eax, r14d
jmp 0x14003773c
mov eax, 0xfffffff3
jmp 0x140037741
mov eax, 0xfffffffe
add rsp, 0x90
pop r15
pop r14
pop rbx
ret