Function at 0x14000d14a
Capabilities:
Read file on windows
Write file on windows

Disassembly:
jmp 0x14000e510
mov qword [rsp + 8], rbx
mov qword [rsp + 0x18], rsi
mov qword [rsp + 0x20], rdi
push rbp
push r12
push r13
push r14
push r15
lea rbp, [rsp - 0x380]
sub rsp, 0x480
mov rax, qword [0x14001ace8]
xor rax, rsp
mov qword [rbp + 0x370], rax
mov ebx, ecx
mov dword [rsp + 0x30], ecx
xor esi, esi
mov qword [rsp + 0x40], rdx
xor ecx, ecx
mov qword [rsp + 0x58], rsi
mov r15d, esi
call qword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll___acrt_iob_func]
lea ecx, [rsi + 1]
mov r12, rax
call qword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll___acrt_iob_func]
xor ecx, ecx
mov dword [rsp + 0x34], esi
mov r13, rax
call qword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll___acrt_iob_func]
mov rcx, rax
call qword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll__fileno]
mov ecx, eax
mov edx, 0x8000
call qword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll__setmode]
lea ecx, [rsi + 1]
call qword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll___acrt_iob_func]
mov rcx, rax
call qword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll__fileno]
mov ecx, eax
mov edx, 0x8000
call qword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll__setmode]
mov r14d, 1
cmp ebx, r14d
jle 0x14000e93b
mov rdi, qword [rsp + 0x40]
mov eax, ebx
add rdi, 8
nop
mov rbx, qword [rdi]
cmp byte [rbx], 0x2d
jne 0x14000e644
cmp byte [rbx + 1], 0x6c
jne 0x14000e5e8
cmp byte [rbx + 2], sil
je 0x14000e694
cmp byte [rbx], 0x2d
jne 0x14000e644
cmp byte [rbx + 1], 0x66
jne 0x14000e60b
cmp byte [rbx + 2], sil
jne 0x14000e60b
mov rax, qword [rdi + 8]
inc r14d
add rdi, 8
mov qword [rsp + 0x58], rax
jmp 0x14000e67b
cmp byte [rbx], 0x2d
jne 0x14000e644
cmp byte [rbx + 1], 0x74
jne 0x14000e629
cmp byte [rbx + 2], sil
jne 0x14000e629
mov r15, qword [rdi + 8]
inc r14d
add rdi, 8
jmp 0x14000e67f
cmp byte [rbx], 0x2d
jne 0x14000e644
cmp byte [rbx + 1], 0x63
jne 0x14000e644
cmp byte [rbx + 2], sil
jne 0x14000e644
mov dword [rsp + 0x34], 1
jmp 0x14000e67f
lea rdx, str.__output
mov rcx, rbx
call sub.api_ms_win_crt_string_l1_1_0.dll_strcmp
test eax, eax
jne 0x14000e706
mov rcx, qword [rdi + 8]
lea rdx, [0x140016f84]
add rdi, 8
inc r14d
call qword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll_fopen]
mov r13, rax
test rax, rax
je 0x14000e6d6
mov eax, dword [rsp + 0x30]
inc r14d
add rdi, 8
cmp r14d, eax
jl 0x14000e5d0
jmp 0x14000e71e
mov rax, qword [str.CP65001]
test rax, rax
je 0x14000e94f
lea rbx, str.CP65001
nop dword [rax + rax]
mov rdx, rax
lea rcx, [0x140016f74]
call fcn.14000d0f0
inc rsi
mov rax, rsi
add rax, rax
mov rax, qword [rbx + rax*8]
test rax, rax
jne 0x14000e6b0
jmp 0x14000e94f
mov ecx, 2
movsxd rbx, r14d
call qword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll___acrt_iob_func]
mov rcx, rax
lea rdx, str.cannot_open__s_n
mov rax, qword [rsp + 0x40]
mov r8, qword [rax + rbx*8]
call fcn.14000d1cc
mov eax, 1
jmp 0x14000e951
lea rdx, [0x140016f9c]
mov rcx, rbx
call qword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll_fopen]
mov r12, rax
test rax, rax
je 0x14000e6d6
mov rdi, qword [rsp + 0x58]
test rdi, rdi
je 0x14000e93b
test r15, r15
je 0x14000e93b
cmp dword [rsp + 0x34], esi
je 0x14000e7b2
mov rbx, r15
mov rcx, 0xffffffffffffffff
inc rcx
cmp byte [r15 + rcx], sil
jne 0x14000e745
add rcx, 9
call qword [sym.imp.api_ms_win_crt_heap_l1_1_0.dll_malloc]
mov r15, rax
test rax, rax
jne 0x14000e776
lea rcx, str.fatal_error
call qword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll_perror]
lea eax, [r15 + 1]
jmp 0x14000e951
mov rcx, r15
sub rcx, rbx
nop dword [rax]
movzx eax, byte [rbx]
mov byte [rcx + rbx], al
lea rbx, [rbx + 1]
test al, al
jne 0x14000e780
lea rcx, [r15 - 1]
cmp byte [rcx + 1], sil
lea rcx, [rcx + 1]
jne 0x14000e792
movsd xmm0, qword [str.__IGNORE]
movsd qword [rcx], xmm0
movzx eax, byte [0x140016ff0]
mov byte [rcx + 8], al
mov rdx, rdi
mov rcx, r15
call fcn.14000d01e
mov r14, rax
cmp rax, 0xffffffffffffffff
jne 0x14000e7dc
lea rcx, str.iconv_open_error
call qword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll_perror]
lea eax, [r14 + 2]
jmp 0x14000e951
mov edi, 0x200
nop dword [rax]
nop word [rax + rax]
mov r8, rdi
lea rcx, [rbp + 0x170]
sub r8, rsi
add rcx, rsi
mov r9, r12
mov edx, 1
call qword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll_fread]
mov qword [rsp + 0x48], rax
test rax, rax
jne 0x14000e821
test rsi, rsi
je 0x14000e8ce
add rax, rsi
mov qword [rsp + 0x38], rdi
mov qword [rsp + 0x48], rax
lea r9, [rsp + 0x50]
lea rax, [rbp + 0x170]
mov rcx, r14
mov qword [rsp + 0x60], rax
lea r8, [rsp + 0x48]
lea rax, [rsp + 0x70]
mov qword [rsp + 0x50], rax
lea rdx, [rsp + 0x60]
lea rax, [rsp + 0x38]
mov qword [rsp + 0x20], rax
call fcn.14000d00a
mov r8, rdi
lea rcx, [rsp + 0x70]
sub r8, qword [rsp + 0x38]
mov r9, r13
mov edx, 1
mov rbx, rax
call qword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll_fwrite]
cmp rbx, 0xffffffffffffffff
jne 0x14000e8b0
call qword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll__errno]
cmp dword [rax], 7
je 0x14000e8b0
call qword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll__errno]
cmp dword [rax], 0x16
jne 0x14000e927
mov rcx, r12
call qword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll_feof]
test eax, eax
jne 0x14000e927
mov rsi, qword [rsp + 0x48]
lea rcx, [rbp + 0x170]
mov rdx, qword [rsp + 0x60]
mov r8, rsi
call sub.VCRUNTIME140.dll_memmove
jmp 0x14000e7f0
lea rax, [rsp + 0x70]
mov qword [rsp + 0x38], rdi
mov qword [rsp + 0x50], rax
lea r9, [rsp + 0x50]
lea rax, [rsp + 0x38]
xor r8d, r8d
xor edx, edx
mov qword [rsp + 0x20], rax
mov rcx, r14
call fcn.14000d00a
sub rdi, qword [rsp + 0x38]
lea rcx, [rsp + 0x70]
mov r8, rdi
mov r9, r13
mov edx, 1
mov rbx, rax
call qword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll_fwrite]
cmp rbx, 0xffffffffffffffff
je 0x14000e927
mov rcx, r14
call fcn.14000d082
jmp 0x14000e94f
lea rcx, str.conversion_error
call qword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll_perror]
mov eax, 1
jmp 0x14000e951
mov rax, qword [rsp + 0x40]
lea rcx, str.usage:__s___c___f_from_enc__t_to_enc__file__n
mov rdx, qword [rax]
call fcn.14000d0f0
xor eax, eax
mov rcx, qword [rbp + 0x370]
xor rcx, rsp
call fcn.14000d0ff
lea r11, [rsp + 0x480]
mov rbx, qword [r11 + 0x30]
mov rsi, qword [r11 + 0x40]
mov rdi, qword [r11 + 0x48]
mov rsp, r11
pop r15
pop r14
pop r13
pop r12
pop rbp
ret