Function at 0x4047d0
Capabilities:
Read file on windows

Disassembly:
push r13
push r12
push rbp
push rdi
push rsi
push rbx
sub rsp, 0xe8
mov r13d, ecx
mov rdi, rdx
call fcn.004016f0
lea rcx, str.czfupdate_v20
call sub.msvcrt.dll_puts
cmp r13d, 3
jg 0x404816
cmp r13d, 1
jle 0x40483e
mov rcx, qword [rdi + 8]
lea rdx, [0x0040600e]
call sub.msvcrt.dll_strcmp
test eax, eax
jne 0x40483e
mov r8, qword [rdi]
mov qword [rsp + 0x28], r8
call qword [sym.imp.msvcrt.dll___iob_func]
mov r8, qword [rsp + 0x28]
lea rcx, [rax + 0x60]
lea rdx, str.Usage:__s__ip___file.czf__n
call sub.msvcrt.dll_fprintf
jmp 0x404b08
cmp r13d, 3
jne 0x4048f6
mov rdx, qword [rdi + 8]
lea rcx, [rsp + 0x3e]
mov r8d, 0x10
lea rbx, [rsp + 0x38]
mov dword [rsp + 0x38], 0x21435a46
mov word [rsp + 0x3c], 0x102
call sub.msvcrt.dll_strncpy
mov rsi, qword [rdi + 0x10]
lea rcx, [rbx + 0x16]
mov r8d, 0x20
mov rdx, rsi
call sub.msvcrt.dll_strncpy
lea rcx, [rbx + 0x36]
lea rdx, [0x0040602c]
call sub.msvcrt.dll_strcpy
lea rcx, [rbx + 0x87]
lea rdx, [0x0040602c]
call sub.msvcrt.dll_strcpy
lea rdx, [0x00406030]
mov rcx, rsi
mov byte [rsp + 0x8e], 0
call sub.msvcrt.dll_fopen
test rax, rax
mov rsi, rax
jne 0x4048ce
mov rdx, qword [rdi + 0x10]
jmp 0x404910
mov r8d, 2
xor edx, edx
mov rcx, rax
call sub.msvcrt.dll_fseek
mov rcx, rsi
call sub.msvcrt.dll_ftell
mov rcx, rsi
movsxd rbx, eax
call sub.msvcrt.dll_rewind
jmp 0x404a6b
mov rcx, qword [rdi]
lea rdx, [0x00406030]
call sub.msvcrt.dll_fopen
test rax, rax
mov rsi, rax
jne 0x404921
mov rdx, qword [rdi]
lea rcx, str.Unable_to_open_local_file__s._n
call sub.msvcrt.dll_printf
jmp 0x404b08
xor edx, edx
mov r8d, 2
mov rcx, rax
call sub.msvcrt.dll_fseek
mov rcx, rsi
call sub.msvcrt.dll_ftell
mov r8d, 2
mov edx, 0xfffffffc
mov rcx, rsi
mov ebx, eax
call sub.msvcrt.dll_fseek
lea rcx, [rsp + 0x34]
mov r8d, 4
mov r9, rsi
mov edx, 1
call sub.msvcrt.dll_fread
cmp eax, 4
mov r8d, 4
jne 0x4049b5
mov edx, dword [rsp + 0x34]
lea rcx, str.info_pos_invalid___d___file_format_error_n
cmp edx, ebx
jae 0x404b03
lea rbp, [rsp + 0x38]
xor r8d, r8d
mov rcx, rsi
call sub.msvcrt.dll_fseek
mov r9, rsi
mov r8d, 5
mov edx, 1
mov rcx, rbp
call sub.msvcrt.dll_fread
cmp eax, 5
je 0x4049c8
mov r8d, 5
lea rcx, str.fread_returned__d__should_be__d_n
mov edx, eax
call sub.msvcrt.dll_printf
jmp 0x404b08
mov edx, dword [rsp + 0x38]
lea rcx, str.upd_tag_invalid___d__n
cmp edx, 0x21435a46
jne 0x404b03
movzx edx, byte [rsp + 0x3c]
cmp dl, 2
jbe 0x404a00
lea rcx, str.upd_info_version_unsupported___d___max___d__n
mov r8d, 2
call sub.msvcrt.dll_printf
jmp 0x404b08
mov rax, qword [0x00406e10]
movsxd rdx, edx
xor r8d, r8d
mov rcx, rsi
mov r12, qword [rax + rdx*8]
mov edx, dword [rsp + 0x34]
call sub.msvcrt.dll_fseek
mov r8, r12
mov edx, 1
mov r9, rsi
mov rcx, rbp
call sub.msvcrt.dll_fread
movsxd rdx, eax
mov r8, r12
cmp rdx, r12
jne 0x4049b5
mov rcx, rbp
call fcn.004047a0
cmp r13d, 2
jne 0x404a60
mov rdx, qword [rdi + 8]
lea rcx, [rbp + 6]
mov r8d, 0x10
call sub.msvcrt.dll_strncpy
sub ebx, dword [rsp + 0x34]
sub rbx, 4
sub rbx, r12
mov rcx, rbx
call sub.msvcrt.dll_malloc
test rax, rax
mov rdi, rax
jne 0x404a89
lea rcx, str.malloc_returned_NULL_
call sub.msvcrt.dll_puts
jmp 0x404b08
mov r8, rbx
mov edx, 1
mov r9, rsi
mov rcx, rax
call sub.msvcrt.dll_fread
movsxd rdx, eax
mov r8, rbx
cmp rdx, rbx
jne 0x4049b5
mov rcx, rsi
lea rsi, [rsp + 0x38]
call sub.msvcrt.dll_fclose
lea rdx, [rsi + 0x87]
lea rcx, str.CPU:_s_n
call sub.msvcrt.dll_printf
movzx edx, byte [rsp + 0x8e]
test dl, dl
je 0x404aec
cmp dl, 2
ja 0x404afc
mov r8, rbx
mov rdx, rdi
mov rcx, rsi
call fcn.00403aa0
jmp 0x404b0f
mov r8, rbx
mov rdx, rdi
mov rcx, rsi
call fcn.00403ff0
jmp 0x404b0f
lea rcx, str.Unsupported_updater_type__d_n
call sub.msvcrt.dll_printf
mov eax, 1
jmp 0x404b19
mov rcx, rdi
call sub.msvcrt.dll_free
xor eax, eax
add rsp, 0xe8
pop rbx
pop rsi
pop rdi
pop rbp
pop r12
pop r13
ret