Function at 0x1000d5584
Capabilities:
Get file size

Disassembly:
push rbx
push rbp
push rsi
push rdi
push r12
push r13
push r14
push r15
sub rsp, 0x498
mov rax, qword [0x100165138]
xor rax, rsp
mov qword [rsp + 0x480], rax
mov rdi, r9
mov r12, r8
mov rsi, rdx
mov rbp, rcx
mov rcx, qword [0x1001653b8]
lea r14, [0x1001653b8]
lea r15, [0x100003188]
mov r13b, 4
cmp rcx, r14
je 0x1000d55f0
test byte [rcx + 0x1c], r13b
je 0x1000d55f0
cmp byte [rcx + 0x19], r13b
jb 0x1000d55f0
mov rcx, qword [rcx + 0x10]
mov edx, 0x29
mov r8, r15
call fcn.10001c7b8
xor eax, eax
xor ecx, ecx
mov ebx, 0x1f8
mov byte [rsp + 0x40], cl
mov dword [rsp + 0x48], ecx
mov dword [rsp + 0x78], ecx
mov qword [rsp + 0x58], rcx
mov byte [rsp + 0x80], cl
lea rcx, [rsp + 0x88]
mov r8, rbx
xor edx, edx
mov dword [rsp + 0x7c], eax
mov qword [rsp + 0x60], rax
mov qword [rsp + 0x68], rax
mov qword [rsp + 0x70], rax
mov dword [rsp + 0x81], eax
mov word [rsp + 0x85], ax
mov byte [rsp + 0x87], al
call sub.msvcrt.dll_memset
xor eax, eax
lea rcx, [rsp + 0x288]
mov r8, rbx
xor edx, edx
mov byte [rsp + 0x280], 0
mov dword [rsp + 0x281], eax
mov word [rsp + 0x285], ax
mov byte [rsp + 0x287], al
call sub.msvcrt.dll_memset
and qword [rsp + 0x30], 0
mov ebx, 3
lea r8d, [rbx - 2]
xor r9d, r9d
mov edx, 0xc0000000
mov rcx, rsi
mov dword [rsp + 0x28], 0x60000080
mov dword [rsp + 0x20], ebx
call qword [sym.imp.KERNEL32.dll_CreateFileW]
mov qword [rbp], rax
cmp rax, 0xffffffffffffffff
jne 0x1000d56f4
call qword [sym.imp.KERNEL32.dll_GetLastError]
mov dword [rdi], eax
mov rcx, qword [0x1001653b8]
cmp rcx, r14
je 0x1000d56ea
test byte [rcx + 0x1c], r13b
je 0x1000d56ea
cmp byte [rcx + 0x19], 2
jb 0x1000d56ea
mov rcx, qword [rcx + 0x10]
lea edx, [rbx + 0x27]
mov r9, rsi
mov r8, r15
mov dword [rsp + 0x20], eax
call fcn.10001daa4
mov eax, 8
jmp 0x1000d5b27
mov rcx, qword [0x1001653b8]
cmp rcx, r14
je 0x1000d5725
test byte [rcx + 0x1c], r13b
je 0x1000d5725
cmp byte [rcx + 0x19], r13b
jb 0x1000d5725
mov rcx, qword [rcx + 0x10]
mov edx, 0x2b
mov r9, rsi
mov r8, r15
mov qword [rsp + 0x20], rax
call fcn.100059300
lea r8, [rsp + 0x40]
lea rdx, [rsp + 0x80]
mov r9, rdi
mov rcx, rbp
call fcn.1000dc46c
mov esi, eax
test eax, eax
je 0x1000d5776
mov rcx, qword [0x1001653b8]
cmp rcx, r14
je 0x1000d576f
test byte [rcx + 0x1c], r13b
je 0x1000d576f
cmp byte [rcx + 0x19], 2
jb 0x1000d576f
mov edx, 0x2c
mov rcx, qword [rcx + 0x10]
mov r9d, eax
mov r8, r15
call fcn.10001c7dc
mov eax, esi
jmp 0x1000d5b27
cmp byte [rsp + 0x40], 0
je 0x1000d57b0
mov rcx, qword [0x1001653b8]
cmp rcx, r14
je 0x1000d57a6
test byte [rcx + 0x1c], r13b
je 0x1000d57a6
cmp byte [rcx + 0x19], 2
jb 0x1000d57a6
mov edx, 0x2d
mov rcx, qword [rcx + 0x10]
mov r8, r15
call fcn.10001c7b8
mov eax, 2
jmp 0x1000d5b27
mov al, byte [rsp + 0xa3]
mov byte [rsp + 0x44], al
mov al, byte [rsp + 0xa2]
mov byte [rsp + 0x45], al
mov al, byte [rsp + 0xa1]
mov byte [rsp + 0x46], al
mov al, byte [rsp + 0xa0]
mov byte [rsp + 0x47], al
cmp dword [rsp + 0x44], 0x10001
je 0x1000d5805
mov rcx, qword [0x1001653b8]
cmp rcx, r14
je 0x1000d57a6
test byte [rcx + 0x1c], r13b
je 0x1000d57a6
cmp byte [rcx + 0x19], 2
jb 0x1000d57a6
mov edx, 0x2e
jmp 0x1000d579a
mov al, byte [rsp + 0xaf]
lea rdx, [rsp + 0x280]
mov r9, r12
mov byte [rsp + 0x50], al
mov al, byte [rsp + 0xae]
mov rcx, rbp
mov byte [rsp + 0x51], al
mov al, byte [rsp + 0xad]
mov qword [rsp + 0x28], rdi
mov byte [rsp + 0x52], al
mov al, byte [rsp + 0xac]
mov byte [rbp + 0x30], 1
mov byte [rsp + 0x53], al
mov al, byte [rsp + 0xab]
mov byte [rsp + 0x54], al
mov al, byte [rsp + 0xaa]
mov byte [rsp + 0x55], al
mov al, byte [rsp + 0xa9]
mov byte [rsp + 0x56], al
mov al, byte [rsp + 0xa8]
mov byte [rsp + 0x57], al
mov al, byte [rsp + 0xbf]
mov r8, qword [rsp + 0x50]
mov byte [rsp + 0x44], al
mov al, byte [rsp + 0xbe]
mov byte [rsp + 0x45], al
mov al, byte [rsp + 0xbd]
mov byte [rsp + 0x46], al
mov al, byte [rsp + 0xbc]
mov byte [rsp + 0x47], al
mov eax, dword [rsp + 0x44]
mov dword [rsp + 0x20], eax
call fcn.1000df19c
mov esi, eax
test eax, eax
je 0x1000d58e6
mov rcx, qword [0x1001653b8]
cmp rcx, r14
je 0x1000d576f
test byte [rcx + 0x1c], r13b
je 0x1000d576f
cmp byte [rcx + 0x19], 2
jb 0x1000d576f
mov edx, 0x2f
jmp 0x1000d5760
mov r12d, 0x20000
xor ecx, ecx
mov rdx, r12
call qword [sym.imp.KERNEL32.dll_LocalAlloc]
mov rsi, rax
test rax, rax
jne 0x1000d590e
call qword [sym.imp.KERNEL32.dll_GetLastError]
mov dword [rdi], eax
mov eax, ebx
jmp 0x1000d5b27
mov r8, r12
xor edx, edx
mov rcx, rax
call sub.msvcrt.dll_memset
lea r12, [rsi + 0xffff]
lea rdx, [rsp + 0x280]
and r12, 0xffffffffffff0000
mov r8d, 0x200
mov rcx, r12
call sub.msvcrt.dll_memcpy
xor r9d, r9d
xor r8d, r8d
lea edx, [r9 + 1]
xor ecx, ecx
call qword [sym.imp.KERNEL32.dll_CreateEventW]
mov qword [rsp + 0x70], rax
test rax, rax
jne 0x1000d5968
call qword [sym.imp.KERNEL32.dll_GetLastError]
mov dword [rdi], eax
jmp 0x1000d5ae5
mov rcx, qword [rbp]
and dword [rsp + 0x68], 0
and dword [rsp + 0x6c], 0
mov ebx, 0x200
lea r9, [rsp + 0x58]
mov rdx, r12
mov r8d, ebx
call fcn.1000d3504
mov rcx, qword [rbp]
lea r8, [rsp + 0x48]
lea rdx, [rsp + 0x58]
mov r9d, 1
call qword [sym.imp.KERNEL32.dll_GetOverlappedResult]
test eax, eax
jne 0x1000d59b6
call qword [sym.imp.KERNEL32.dll_GetLastError]
mov dword [rdi], eax
jmp 0x1000d5ad5
mov r9d, dword [rsp + 0x48]
cmp r9d, ebx
je 0x1000d59ee
mov rcx, qword [0x1001653b8]
cmp rcx, r14
je 0x1000d5acf
test byte [rcx + 0x1c], r13b
je 0x1000d5acf
cmp byte [rcx + 0x19], 2
jb 0x1000d5acf
mov edx, 0x30
jmp 0x1000d5ac3
mov rcx, qword [rbp]
lea rdx, [rsp + 0x78]
call qword [sym.imp.KERNEL32.dll_GetFileSizeEx]
test eax, eax
jne 0x1000d5a4f
call qword [sym.imp.KERNEL32.dll_GetLastError]
mov dword [rdi], eax
mov rcx, qword [0x1001653b8]
cmp rcx, r14
je 0x1000d5a3a
test byte [rcx + 0x1c], r13b
je 0x1000d5a3a
cmp byte [rcx + 0x19], 2
jb 0x1000d5a3a
mov r9, qword [rbp]
mov rcx, qword [rcx + 0x10]
mov edx, 0x31
mov r8, r15
mov dword [rsp + 0x20], eax
call fcn.1000c2b34
mov rcx, qword [rsp + 0x70]
call qword [sym.imp.KERNEL32.dll_CloseHandle]
mov ebx, 8
jmp 0x1000d5ae5
mov rax, qword [rsp + 0x78]
mov rcx, qword [rbp]
lea r9, [rsp + 0x58]
add rax, 0xfffffffffffffe00
mov r8d, ebx
mov rdx, r12
mov dword [rsp + 0x68], eax
shr rax, 0x20
mov dword [rsp + 0x6c], eax
call fcn.1000d3504
mov rcx, qword [rbp]
lea r8, [rsp + 0x48]
lea rdx, [rsp + 0x58]
mov r9d, 1
call qword [sym.imp.KERNEL32.dll_GetOverlappedResult]
test eax, eax
je 0x1000d59a9
mov r9d, dword [rsp + 0x48]
cmp r9d, ebx
je 0x1000d5af3
mov rcx, qword [0x1001653b8]
cmp rcx, r14
je 0x1000d5acf
test byte [rcx + 0x1c], r13b
je 0x1000d5acf
cmp byte [rcx + 0x19], 2
jb 0x1000d5acf
mov edx, 0x32
mov rcx, qword [rcx + 0x10]
mov r8, r15
call fcn.10001c7dc
mov dword [rdi], 0x45d
mov rcx, qword [rsp + 0x70]
call qword [sym.imp.KERNEL32.dll_CloseHandle]
mov ebx, 5
mov rcx, rsi
call qword [sym.imp.KERNEL32.dll_LocalFree]
jmp 0x1000d5907
mov rcx, rsi
call qword [sym.imp.KERNEL32.dll_LocalFree]
mov rcx, qword [0x1001653b8]
cmp rcx, r14
je 0x1000d5b25
test byte [rcx + 0x1c], r13b
je 0x1000d5b25
cmp byte [rcx + 0x19], r13b
jb 0x1000d5b25
mov rcx, qword [rcx + 0x10]
mov edx, 0x33
mov r8, r15
call fcn.10001c7b8
xor eax, eax
mov rcx, qword [rsp + 0x480]
xor rcx, rsp
call fcn.10014e480
add rsp, 0x498
pop r15
pop r14
pop r13
pop r12
pop rdi
pop rsi
pop rbp
pop rbx
ret