Function at 0x14001d870
Capabilities:
Write file on windows

Disassembly:
mov rax, rsp
mov qword [rax + 0x10], rbx
mov dword [rax + 0x20], r9d
mov qword [rax + 0x18], r8
push rbp
push rsi
push rdi
push r12
push r13
push r14
push r15
sub rsp, 0x50
xor ebp, ebp
mov rbx, 0xffffffffffffffff
mov qword [rax - 0x48], rbp
mov r14d, r9d
mov qword [rax - 0x40], rbp
mov r15, r8
mov dword [rax + 8], ebp
mov rdi, rdx
mov rsi, rcx
mov r13, rbx
test rcx, rcx
jne 0x14001d8cf
mov r8d, 0x171
lea rdx, str.C:_src_r3dusb_src_net.c
lea rcx, str.url___NULL
call fcn.1400a15c4
mov rcx, rbx
inc rcx
cmp byte [rsi + rcx], bpl
jne 0x14001d8d2
add rcx, 5
call fcn.14009b5b4
mov r12, rax
test rax, rax
jne 0x14001d8fd
lea rcx, str.Could_not_allocate_signature_URL
call fcn.140041aa0
jmp 0x14001dbb1
mov rdx, r12
mov rcx, rsi
sub rdx, rsi
nop word [rax + rax]
movzx eax, byte [rcx]
mov byte [rdx + rcx], al
lea rcx, [rcx + 1]
test al, al
jne 0x14001d910
lea rcx, [r12 - 1]
cmp byte [rcx + 1], bpl
lea rcx, [rcx + 1]
jne 0x14001d923
mov eax, dword [str..sig]
lea r9, [rsp + 0x40]
mov dword [rcx], eax
xor r8d, r8d
movzx eax, byte [0x1400df8a8]
xor edx, edx
mov byte [rcx + 4], al
mov rcx, rsi
mov dword [rsp + 0x28], ebp
mov qword [rsp + 0x20], r15
call fcn.14001cab0
mov r14, rax
test eax, eax
je 0x14001dba9
mov dword [rsp + 0x28], ebp
lea r9, [rsp + 0x48]
xor r8d, r8d
mov qword [rsp + 0x20], rbp
xor edx, edx
mov rcx, r12
call fcn.14001cab0
cmp eax, 0x100
jne 0x14001db47
mov r8, qword [rsp + 0x48]
mov r9d, eax
mov rcx, qword [rsp + 0x40]
mov edx, r14d
call fcn.140023f40
test eax, eax
je 0x14001db47
lea rcx, str.Download_signature_is_valid_
call fcn.140041aa0
mov rcx, rdi
mov dword [0x14015ae98], 0xce
call fcn.140003550
xor r9d, r9d
mov qword [rsp + 0x30], rbp
mov dword [rsp + 0x28], 0x80
mov edx, 0xc0000000
mov rcx, rax
mov dword [rsp + 0x20], 2
mov rsi, rax
lea r8d, [r9 + 1]
call qword [sym.imp.KERNEL32.dll_CreateFileW]
mov r13, rax
call qword [sym.imp.KERNEL32.dll_GetLastError]
mov r15d, eax
test rsi, rsi
je 0x14001da0c
mov rcx, rsi
call fcn.14009b5a0
mov ecx, r15d
call qword [sym.imp.KERNEL32.dll_SetLastError]
cmp r13, rbx
jne 0x14001da67
test rdi, rdi
je 0x14001da4b
nop
inc rbx
cmp byte [rdi + rbx], bpl
jne 0x14001da20
test rbx, rbx
je 0x14001da47
nop
movzx eax, byte [rbx + rdi]
cmp al, 0x2f
je 0x14001da44
cmp al, 0x5c
je 0x14001da44
sub rbx, 1
jne 0x14001da30
jmp 0x14001da47
inc rbx
lea rbp, [rbx + rdi]
call fcn.140041e50
mov r8, rax
lea rcx, str.Unable_to_create_file__s:__s
mov rdx, rbp
call fcn.140041aa0
jmp 0x14001dba9
mov rdx, qword [rsp + 0x40]
lea r9, [rsp + 0x90]
mov r8d, r14d
mov qword [rsp + 0x20], rbp
mov rcx, r13
call qword [sym.imp.KERNEL32.dll_WriteFile]
test eax, eax
jne 0x14001dade
test rdi, rdi
jne 0x14001da93
mov rbx, rbp
jmp 0x14001dabb
inc rbx
cmp byte [rdi + rbx], bpl
jne 0x14001da93
test rbx, rbx
je 0x14001dab8
movzx eax, byte [rbx + rdi]
cmp al, 0x2f
je 0x14001dab5
cmp al, 0x5c
je 0x14001dab5
sub rbx, 1
jne 0x14001daa1
jmp 0x14001dab8
inc rbx
add rbx, rdi
call fcn.140041e50
mov r8, rax
lea rcx, str.Error_writing_file__s:__s
mov rdx, rbx
call fcn.140041aa0
mov dword [rsp + 0x90], ebp
jmp 0x14001dba9
cmp dword [rsp + 0x90], r14d
je 0x14001db3b
test rdi, rdi
jne 0x14001daf2
mov rdx, rbp
jmp 0x14001db1b
inc rbx
cmp byte [rdi + rbx], bpl
jne 0x14001daf2
test rbx, rbx
je 0x14001db17
movzx eax, byte [rbx + rdi]
cmp al, 0x2f
je 0x14001db14
cmp al, 0x5c
je 0x14001db14
sub rbx, 1
jne 0x14001db00
jmp 0x14001db17
inc rbx
lea rdx, [rbx + rdi]
mov r8d, dword [rsp + 0x90]
lea rcx, str.Error_writing_file__s:_Only__d__d_bytes_written
mov r9d, r14d
call fcn.140041aa0
mov dword [rsp + 0x90], ebp
jmp 0x14001dba9
mov dword [0x14015ae98], 0xc8
jmp 0x14001dba9
lea rcx, str.FATAL:_Download_signature_is_invalid_
call fcn.140041aa0
mov edx, 0x3f2
mov dword [0x14015ae98], 0x193
mov rcx, r15
mov dword [0x140111620], 0xe003120d
call qword [sym.imp.USER32.dll_GetDlgItem]
xor r9d, r9d
mov edx, 0x410
mov rcx, rax
lea r8d, [r9 + 2]
call qword [sym.imp.USER32.dll_SendMessageW]
mov rcx, qword [0x140156458]
test rcx, rcx
je 0x14001dba9
mov rax, qword [rcx]
mov r8d, 4
mov rdx, qword [0x14015a568]
call qword [rax + 0x50]
mov r14d, dword [rsp + 0xa8]
mov rax, qword [rsp + 0xa0]
test rax, rax
je 0x14001dbd7
mov r8d, dword [rsp + 0x90]
xor r9d, r9d
mov edx, 0x8003
mov rcx, rax
call qword [sym.imp.USER32.dll_SendMessageW]
test r14d, r14d
je 0x14001dcae
cmp dword [0x14015ae98], 0xc8
je 0x14001dcae
xor edx, edx
mov r9d, 0xcaa
xor r8d, r8d
lea ecx, [rdx + 1]
call fcn.14001b7e0
mov ecx, dword [0x14015338c]
call qword [sym.imp.KERNEL32.dll_SetLastError]
mov ecx, dword [0x140111620]
test ecx, ecx
jns 0x14001dc20
call fcn.140042560
jmp 0x14001dc25
call fcn.140041e50
cmp dword [0x1401128e0], 0
mov r14, rax
movzx esi, word [0x140109ee0]
mov eax, 0x180010
mov ebp, 0x10
mov ecx, 0xbe4
cmovne ebp, eax
call fcn.14001b320
mov rdi, qword [0x14015a568]
mov rcx, r14
mov rbx, rax
call fcn.140003550
mov rcx, rbx
mov r14, rax
call fcn.140003550
mov r9d, ebp
mov word [rsp + 0x20], si
mov r8, rax
mov rdx, r14
mov rcx, rdi
mov rbx, rax
call qword [sym.imp.USER32.dll_MessageBoxExW]
call qword [sym.imp.KERNEL32.dll_GetLastError]
mov edi, eax
test r14, r14
je 0x14001dc99
mov rcx, r14
call fcn.14009b5a0
test rbx, rbx
je 0x14001dca6
mov rcx, rbx
call fcn.14009b5a0
mov ecx, edi
call qword [sym.imp.KERNEL32.dll_SetLastError]
lea rax, [r13 - 1]
cmp rax, 0xfffffffffffffffd
ja 0x14001dcc1
mov rcx, r13
call qword [sym.imp.KERNEL32.dll_CloseHandle]
mov rcx, r12
call fcn.14009b5a0
mov rcx, qword [rsp + 0x40]
call fcn.14009b5a0
mov rcx, qword [rsp + 0x48]
call fcn.14009b5a0
mov eax, dword [rsp + 0x90]
mov rbx, qword [rsp + 0x98]
add rsp, 0x50
pop r15
pop r14
pop r13
pop r12
pop rdi
pop rsi
pop rbp
ret