Function at 0x481560
Capabilities:
Read file on windows

Disassembly:
push r15
push r14
push r13
push r12
push rbp
push rdi
push rsi
push rbx
sub rsp, 0x278
xor eax, eax
test r8, r8
mov qword [rsp + 0x40], rcx
mov qword [rsp + 0x38], rdx
mov rbp, r8
mov rbx, r9
mov qword [rsp + 0x58], 0
mov qword [rsp + 0x68], 0
mov qword [rdx], 0
je 0x481831
call fcn.004805f0
mov rdi, rax
mov qword [rsp + 0x30], rax
mov eax, 0x1b
test rdi, rdi
je 0x481831
lea r9, str.Content_Type:_multipart_form_data
test rbx, rbx
lea r8, str._s__boundary_s_r_n
mov qword [rsp + 0x20], rdi
cmovne r9, rbx
lea rbx, [rsp + 0x58]
xor edx, edx
mov rcx, rbx
call fcn.004807c0
test eax, eax
jne 0x481894
mov rax, qword [rsp + 0x58]
lea rsi, [rsp + 0x68]
lea r13, [rsp + 0x70]
xor r14d, r14d
mov qword [rsp + 0x60], rax
mov rax, qword [sym.imp.msvcrt.dll___iob_func]
mov qword [rsp + 0x48], rax
nop word cs:[rax + rax]
cmp qword [rsp + 0x68], 0
je 0x481645
lea r8, [0x0066879b]
mov rdx, rsi
mov rcx, rbx
call fcn.004807c0
test eax, eax
mov r15d, eax
jne 0x48186c
mov r9, qword [rsp + 0x30]
lea r8, str.___s_r_n
mov rdx, rsi
mov rcx, rbx
call fcn.004807c0
test eax, eax
mov r15d, eax
jne 0x48186c
lea r8, str.Content_Disposition:_form_data__name_
mov rdx, rsi
mov rcx, rbx
call fcn.004807c0
test eax, eax
mov r15d, eax
jne 0x48186c
movsxd r9, dword [rbp + 0x10]
mov r8, qword [rbp + 8]
xor edx, edx
mov qword [rsp + 0x20], rsi
mov rcx, rbx
call fcn.00480670
test eax, eax
mov r15d, eax
jne 0x48186c
lea r8, [0x006687c7]
mov rdx, rsi
mov rcx, rbx
call fcn.004807c0
test eax, eax
jne 0x481869
mov rax, qword [rbp + 0x48]
test rax, rax
je 0x48170c
test r14, r14
je 0x4816d7
mov rcx, r14
call qword [sub.msvcrt.dll_free]
call fcn.004805f0
test rax, rax
mov r14, rax
je 0x481a95
lea r8, str._r_nContent_Type:_multipart_mixed__boundary_s_r_n
mov r9, rax
mov rdx, rsi
mov rcx, rbx
call fcn.004807c0
test eax, eax
mov r15d, eax
jne 0x48186c
mov rax, qword [rbp + 0x48]
xor r15d, r15d
test rax, rax
mov rdi, rbp
je 0x481938
nop dword [rax + rax]
lea r8, str._r_n___s_r_nContent_Disposition:_attachment
mov r9, r14
mov rdx, rsi
mov rcx, rbx
call fcn.004807c0
test eax, eax
mov r15d, eax
jne 0x48186c
mov rdx, qword [rdi + 0x58]
mov rcx, qword [rdi + 0x18]
mov r9, rsi
mov r8, rbx
call fcn.004808b0
mov r15d, eax
test r15d, r15d
jne 0x48186c
xor r15d, r15d
mov r9, qword [rdi + 0x38]
test r9, r9
je 0x4818b0
lea r8, str._r_nContent_Type:__s
mov rdx, rsi
mov rcx, rbx
call fcn.004807c0
test eax, eax
mov r15d, eax
jne 0x48186c
mov r12, qword [rdi + 0x40]
test r12, r12
jne 0x48184f
jmp 0x4818c0
test r15d, r15d
jne 0x48186c
cmp qword [rbp + 0x48], 0
je 0x4817ce
lea r8, str._r_n___s__
mov r9, r14
mov rdx, rsi
mov rcx, rbx
call fcn.004807c0
test eax, eax
mov r15d, eax
jne 0x48186c
mov rbp, qword [rbp]
test rbp, rbp
jne 0x481620
mov r9, qword [rsp + 0x30]
lea r8, str._r_n___s___r_n
mov rdx, rsi
mov rcx, rbx
call fcn.004807c0
test eax, eax
mov r15d, eax
jne 0x48186c
mov rdx, qword [rsp + 0x68]
mov rax, qword [rsp + 0x2e0]
test r14, r14
mov qword [rax], rdx
je 0x481817
mov rcx, r14
call qword [sub.msvcrt.dll_free]
mov rcx, qword [rsp + 0x30]
call qword [sub.msvcrt.dll_free]
mov rax, qword [rsp + 0x60]
mov rdi, qword [rsp + 0x38]
mov qword [rdi], rax
xor eax, eax
add rsp, 0x278
pop rbx
pop rsi
pop rdi
pop rbp
pop r12
pop r13
pop r14
pop r15
ret
mov r12, qword [r12 + 8]
test r12, r12
je 0x4818c0
mov r9, qword [r12]
lea r8, str._r_n_s
mov rdx, rsi
mov rcx, rbx
call fcn.004807c0
test eax, eax
je 0x481845
mov r15d, eax
lea rcx, [rsp + 0x60]
call fcn.00481470
test r14, r14
je 0x481884
mov rcx, r14
call qword [sub.msvcrt.dll_free]
mov rcx, qword [rsp + 0x30]
call qword [sub.msvcrt.dll_free]
mov eax, r15d
jmp 0x481831
mov dword [rsp + 0x38], eax
mov rcx, qword [rsp + 0x30]
call qword [sub.msvcrt.dll_free]
mov eax, dword [rsp + 0x38]
jmp 0x481831
mov r12, qword [rdi + 0x40]
test r12, r12
jne 0x48184f
test r15d, r15d
jne 0x48186c
nop
lea r8, str._r_n_r_n
mov rdx, rsi
mov rcx, rbx
call fcn.004807c0
test eax, eax
mov r15d, eax
jne 0x48186c
mov eax, dword [rbp + 0x50]
test al, 3
jne 0x481970
test al, 0x10
jne 0x481a23
test al, 0x40
movsxd r9, dword [rbp + 0x20]
je 0x481a10
mov r8, qword [rbp + 0x60]
mov edx, 2
mov qword [rsp + 0x20], rsi
mov rcx, rbx
call fcn.00480670
test eax, eax
mov r15d, eax
sete al
test al, al
mov rdi, qword [rdi + 0x48]
je 0x48179e
test rdi, rdi
je 0x48179e
mov rax, qword [rbp + 0x48]
test rax, rax
jne 0x481720
mov eax, dword [rbp + 0x50]
test al, 0x51
je 0x481762
mov rdx, qword [rbp + 0x58]
test rdx, rdx
je 0x481a7d
mov rcx, qword [rbp + 0x18]
mov r9, rsi
mov r8, rbx
call fcn.004808b0
mov r15d, eax
jmp 0x481756
mov rdx, qword [rdi + 0x18]
lea rcx, [0x006686e3]
call fcn.0047a1d0
test eax, eax
je 0x481a30
mov rax, qword [rsp + 0x48]
call rax
mov r12, rax
test r12, r12
je 0x481a4c
call qword [sym.imp.msvcrt.dll___iob_func]
cmp r12, rax
je 0x4819e1
mov rcx, r12
call sub.msvcrt.dll_fclose
mov r8, qword [rdi + 0x18]
xor r9d, r9d
mov qword [rsp + 0x20], rsi
mov edx, 3
jmp 0x481906
mov qword [rsp + 0x20], rsi
mov r8, r13
mov edx, 1
mov rcx, rbx
call fcn.00480670
test eax, eax
jne 0x481a8a
mov r9, r12
mov r8d, 0x200
mov edx, 1
mov rcx, r13
call sub.msvcrt.dll_fread
test rax, rax
mov r9, rax
jne 0x4819c4
mov eax, 1
jmp 0x481916
mov r8, qword [rbp + 0x18]
mov qword [rsp + 0x20], rsi
mov edx, 1
jmp 0x481906
movsxd r9, dword [rbp + 0x30]
mov r8, qword [rbp + 0x28]
jmp 0x481a14
mov rcx, qword [rdi + 0x18]
lea rdx, [0x006686e0]
call sub.msvcrt.dll_fopen
mov r12, rax
test r12, r12
jne 0x48199b
mov rcx, qword [rsp + 0x40]
test rcx, rcx
je 0x481a66
mov r8, qword [rdi + 0x18]
lea rdx, str.couldnt_open_file___s_
call fcn.0044ea90
mov rax, qword [rsp + 0x38]
mov r15d, 0x1a
mov qword [rax], 0
jmp 0x48186c
test al, 1
je 0x481756
jmp 0x481950
mov r15d, eax
xor eax, eax
nop
jmp 0x481916
mov r15d, 0x1b
jmp 0x48186c