Function at 0x1000d782c
Capabilities:
Get file size

Disassembly:
mov qword [rsp + 0x10], rbx
mov qword [rsp + 0x18], rbp
push rsi
push rdi
push r12
push r13
push r15
sub rsp, 0x40
mov r12, r9
mov rbp, r8
mov rsi, rdx
mov rbx, rcx
mov rcx, qword [0x1001653b8]
lea r15, [0x1001653b8]
lea rdi, [0x100003188]
mov r13b, 4
cmp rcx, r15
je 0x1000d788f
test byte [rcx + 0x1c], r13b
je 0x1000d788f
cmp byte [rcx + 0x19], r13b
jb 0x1000d788f
mov rcx, qword [rcx + 0x10]
mov edx, 0x66
mov r8, rdi
call fcn.10001c7b8
mov rcx, qword [0x1001653b8]
cmp byte [rbx + 0x48], 0
jne 0x1000d78cf
mov rax, qword [rsp + 0x90]
mov dword [rax], 0x57
cmp rcx, r15
je 0x1000d78c5
test byte [rcx + 0x1c], r13b
je 0x1000d78c5
cmp byte [rcx + 0x19], 2
jb 0x1000d78c5
mov rcx, qword [rcx + 0x10]
mov edx, 0x67
mov r8, rdi
call fcn.10001c7b8
mov eax, 2
jmp 0x1000d7c5b
cmp qword [rbx], 0
je 0x1000d78ed
lea r8, [0x10000d650]
lea rcx, [0x10000d5f8]
mov edx, 0x7cf
call fcn.100099ad8
mov r9, qword [rbx + 8]
and qword [rbx + 0x38], 0
test r9, r9
je 0x1000d7933
mov rcx, qword [0x1001653b8]
cmp rcx, r15
je 0x1000d7924
test byte [rcx + 0x1c], r13b
je 0x1000d7924
cmp byte [rcx + 0x19], r13b
jb 0x1000d7924
mov rcx, qword [rcx + 0x10]
mov edx, 0x68
mov r8, rdi
call fcn.10001da24
mov rcx, qword [rbx + 8]
call qword [sym.imp.KERNEL32.dll_LocalFree]
and qword [rbx + 8], 0
or rcx, 0xffffffffffffffff
xor eax, eax
mov rdi, rsi
repne scasw ax, word [rdi]
not rcx
lea rdx, [rcx + rcx]
lea rdi, [rcx - 1]
xor ecx, ecx
call qword [sym.imp.KERNEL32.dll_LocalAlloc]
mov qword [rbx + 8], rax
test rax, rax
jne 0x1000d7965
mov eax, 8
jmp 0x1000d7c5b
lea rdx, [rdi + 1]
mov r8, rsi
mov rcx, rax
call fcn.100043e4c
test eax, eax
jns 0x1000d798f
movzx ecx, ax
mov rax, qword [rsp + 0x90]
mov dword [rax], ecx
mov rcx, rbx
call fcn.1000d4578
jmp 0x1000d795b
cmp byte [rbx + 0x49], 0
je 0x1000d7b07
mov rcx, qword [0x1001653b8]
cmp rcx, r15
je 0x1000d79c9
test byte [rcx + 0x1c], r13b
je 0x1000d79c9
cmp byte [rcx + 0x19], r13b
jb 0x1000d79c9
mov rcx, qword [rcx + 0x10]
lea r8, [0x100003188]
mov edx, 0x69
mov r9, rsi
call fcn.10001da24
and qword [rsp + 0x30], 0
xor r9d, r9d
mov edx, 0x80000000
lea r8d, [r9 + 1]
mov rcx, rsi
mov dword [rsp + 0x28], 0x60000080
mov dword [rsp + 0x20], 3
call qword [sym.imp.KERNEL32.dll_CreateFileW]
mov qword [rbx], rax
cmp rax, 0xffffffffffffffff
jne 0x1000d7a56
and qword [rbx], 0
call qword [sym.imp.KERNEL32.dll_GetLastError]
mov rcx, qword [rsp + 0x90]
mov dword [rcx], eax
mov rcx, qword [0x1001653b8]
cmp rcx, r15
je 0x1000d795b
test byte [rcx + 0x1c], r13b
je 0x1000d795b
cmp byte [rcx + 0x19], 2
jb 0x1000d795b
mov edx, 0x6a
mov rcx, qword [rcx + 0x10]
lea r8, [0x100003188]
mov r9, rsi
mov dword [rsp + 0x20], eax
call fcn.10001daa4
jmp 0x1000d795b
lea rdx, [rsp + 0x70]
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_GetFileSizeEx]
test eax, eax
jne 0x1000d7aa3
call qword [sym.imp.KERNEL32.dll_GetLastError]
mov rcx, qword [rsp + 0x90]
mov dword [rcx], eax
mov rcx, qword [0x1001653b8]
cmp rcx, r15
je 0x1000d795b
test byte [rcx + 0x1c], r13b
je 0x1000d795b
cmp byte [rcx + 0x19], 2
jb 0x1000d795b
mov edx, 0x6b
jmp 0x1000d7a3a
mov rax, qword [rsp + 0x70]
mov qword [rbx + 0x18], rax
mov rcx, qword [0x1001653b8]
cmp rcx, r15
je 0x1000d7ae8
test byte [rcx + 0x1c], r13b
je 0x1000d7ae8
cmp byte [rcx + 0x19], r13b
jb 0x1000d7ae8
mov rcx, qword [rcx + 0x10]
lea r8, [0x100003188]
mov edx, 0x6c
mov r9, rsi
mov qword [rsp + 0x20], rax
call fcn.100059300
mov rcx, qword [0x1001653b8]
cmp byte [rbx + 0x48], 0
je 0x1000d7c2c
mov rcx, rbx
call fcn.1000de814
mov rcx, rbx
call fcn.1000de900
jmp 0x1000d7c25
and qword [rsp + 0x30], 0
xor r9d, r9d
xor r8d, r8d
mov edx, 0xc0000000
mov rcx, rsi
mov dword [rsp + 0x28], 0x60000080
mov dword [rsp + 0x20], 2
call qword [sym.imp.KERNEL32.dll_CreateFileW]
mov qword [rbx], rax
cmp rax, 0xffffffffffffffff
jne 0x1000d7b8c
and qword [rbx], 0
call qword [sym.imp.KERNEL32.dll_GetLastError]
mov rcx, qword [rsp + 0x90]
mov dword [rcx], eax
mov rcx, qword [0x1001653b8]
cmp rcx, r15
je 0x1000d7b82
test byte [rcx + 0x1c], r13b
je 0x1000d7b82
cmp byte [rcx + 0x19], 2
jb 0x1000d7b82
mov rcx, qword [rcx + 0x10]
lea r8, [0x100003188]
mov edx, 0x6d
mov r9, rsi
mov dword [rsp + 0x20], eax
call fcn.10001daa4
mov eax, 7
jmp 0x1000d7c5b
mov qword [rbx + 0x18], rbp
test rbp, rbp
jne 0x1000d7ba3
movabs rax, 0x7fffffffffffffff
mov qword [rbx + 0x18], rax
mov r9d, dword [rbx + 0x90]
mov al, byte [rbx + 0x30]
sub r9d, dword [rbx + 0xa8]
inc r9d
imul r9, r9, 0x200200
neg al
sbb rcx, rcx
and rcx, 0xffffffffffdffe00
add rcx, 0x200400
add r9, rcx
cmp r9, rbp
cmovg r9, rbp
and qword [rbx + 0x160], 0
mov qword [rbx + 0x158], r9
mov rcx, qword [0x1001653b8]
cmp rcx, r15
je 0x1000d7c2c
test byte [rcx + 0x1c], r13b
je 0x1000d7c2c
cmp byte [rcx + 0x19], r13b
jb 0x1000d7c2c
mov rax, qword [rbx + 0x18]
mov rcx, qword [rcx + 0x10]
lea r8, [0x100003188]
mov qword [rsp + 0x28], rax
mov edx, 0x6e
mov qword [rsp + 0x20], r9
call fcn.1000d40b0
mov rcx, qword [0x1001653b8]
mov rax, qword [rbx]
mov qword [r12], rax
cmp rcx, r15
je 0x1000d7c59
test byte [rcx + 0x1c], r13b
je 0x1000d7c59
cmp byte [rcx + 0x19], r13b
jb 0x1000d7c59
mov rcx, qword [rcx + 0x10]
lea r8, [0x100003188]
mov edx, 0x6f
call fcn.10001c7b8
xor eax, eax
lea r11, [rsp + 0x40]
mov rbx, qword [r11 + 0x38]
mov rbp, qword [r11 + 0x40]
mov rsp, r11
pop r15
pop r13
pop r12
pop rdi
pop rsi
ret