Function at 0x478880
Capabilities:
Write file on windows

Disassembly:
push r15
push r14
push r13
push r12
push rbp
push rdi
push rsi
push rbx
sub rsp, 0x58
lea r13, [0x004e1cbb]
mov rdi, qword [rsp + 0xc0]
mov rbx, qword [rsp + 0xc8]
mov rax, qword [rsp + 0xd0]
mov r12d, r8d
mov r8, rdi
mov rbp, rdx
sub r8, qword [rbx]
mov r14d, r9d
mov qword [rsp + 0x20], r13
mov r9d, r12d
mov rsi, rcx
mov qword [rsp + 0x40], rax
lea rdx, str._03x__.s_Entry:
call sub.msvcrt.dll_fprintf
mov rax, qword [rbp + 8]
mov rcx, rdi
call qword [rax + 0x38]
test r14d, r14d
mov r15, rax
je 0x478a00
mov rdx, qword [rbx]
mov r10d, eax
and eax, 0x7fffffff
sub r10, qword [rsp + 0x40]
add rax, rdx
add r10, rdx
test r15d, r15d
cmovns rax, r10
mov r14, rax
lea rax, [rax + 2]
cmp qword [rbx + 8], rax
jbe 0x4789d0
cmp r14, rdx
jbe 0x4789d0
cmp qword [rbx + 0x10], 0
je 0x478b30
mov rax, qword [rbp + 8]
mov rcx, r14
call qword [rax + 0x50]
lea rdx, str.name:__val:__08lx_len__d_:
mov r8d, r15d
mov rcx, rsi
mov r9d, eax
mov qword [rsp + 0x48], rax
call sub.msvcrt.dll_fprintf
mov r11, qword [rsp + 0x48]
lea eax, [r11 + r11]
lea rax, [r14 + rax + 2]
cmp qword [rbx + 8], rax
jbe 0x478b40
mov r11d, r11d
lea r15, [r14 + r11*2]
cmp r14, r15
je 0x478a12
add r14, 2
movzx r8d, byte [r14]
lea eax, [r8 - 1]
cmp al, 0x1e
ja 0x4789b6
lea rdx, [0x004e1d61]
add r8d, 0x40
mov rcx, rsi
call sub.msvcrt.dll_fprintf
cmp r14, r15
je 0x478a12
add r14, 2
movzx r8d, byte [r14]
lea eax, [r8 - 1]
cmp al, 0x1e
jbe 0x47898e
lea rdx, str._.1s
mov r8, r14
mov rcx, rsi
call sub.msvcrt.dll_fprintf
jmp 0x478975
lea rdx, str._corrupt_string_offset:__lx__n
mov r8d, r15d
mov rcx, rsi
call sub.msvcrt.dll_fprintf
mov rax, qword [rbx + 8]
add rax, 1
add rsp, 0x58
pop rbx
pop rsi
pop rdi
pop rbp
pop r12
pop r13
pop r14
pop r15
ret
lea rdx, str.ID:__08lx
mov r8d, eax
mov rcx, rsi
call sub.msvcrt.dll_fprintf
mov rax, qword [rbp + 8]
lea rcx, [rdi + 4]
call qword [rax + 0x38]
lea rdx, str.__Value:__08lx_n
mov rcx, rsi
mov r15, rax
mov r8d, eax
call sub.msvcrt.dll_fprintf
test r15d, r15d
mov rdx, qword [rbx]
js 0x478b05
mov rax, qword [rbx + 8]
mov r10d, r15d
lea rdi, [rdx + r10]
lea rcx, [rdi + 0x10]
cmp rax, rcx
jbe 0x478b1e
cmp rdx, rdi
ja 0x478b1e
mov rax, qword [rbp + 8]
lea rcx, [rdi + 8]
call qword [rax + 0x38]
lea rcx, [rdi + 4]
mov qword [rsp + 0x48], rax
mov rax, qword [rbp + 8]
call qword [rax + 0x38]
mov rcx, rdi
mov r14, rax
mov rax, qword [rbp + 8]
call qword [rax + 0x38]
mov rdx, qword [rsp + 0x48]
mov r9d, r12d
mov r8d, r15d
mov rcx, rsi
mov dword [rsp + 0x30], r14d
mov dword [rsp + 0x28], eax
mov qword [rsp + 0x20], r13
mov dword [rsp + 0x38], edx
lea rdx, str._03x__.s__Leaf:_Addr:__08lx__Size:__08lx__Codepage:__d_n
mov qword [rsp + 0x48], rax
call sub.msvcrt.dll_fprintf
mov rax, qword [rbp + 8]
lea rcx, [rdi + 0xc]
call qword [rax + 0x38]
mov r11, qword [rsp + 0x48]
test rax, rax
jne 0x478b60
mov r11d, r11d
sub r11, qword [rsp + 0x40]
mov eax, r14d
mov rcx, qword [rbx]
mov rdx, qword [rbx + 8]
add rax, r11
add rax, rcx
cmp rax, rdx
ja 0x478b64
cmp qword [rbx + 0x18], 0
jne 0x4789ea
add rcx, r11
mov qword [rbx + 0x18], rcx
jmp 0x4789ea
and r15d, 0x7fffffff
mov rax, qword [rbx + 8]
lea r9, [rdx + r15]
cmp rdx, r9
jae 0x478b1e
cmp r9, rax
jbe 0x478b70
add rax, 1
jmp 0x4789ea
mov qword [rbx + 0x10], r14
jmp 0x478932
lea rdx, str._corrupt_string_length:__x__n
mov r8d, r11d
mov rcx, rsi
call sub.msvcrt.dll_fprintf
mov rax, qword [rbx + 8]
add rax, 1
jmp 0x4789ea
mov rdx, qword [rbx + 8]
lea rax, [rdx + 1]
jmp 0x4789ea
mov rax, qword [rsp + 0x40]
lea r8d, [r12 + 1]
mov rdx, rbp
mov rcx, rsi
mov qword [rsp + 0xc0], rbx
mov qword [rsp + 0xc8], rax
add rsp, 0x58
pop rbx
pop rsi
pop rdi
pop rbp
pop r12
pop r13
pop r14
pop r15
jmp fcn.00478600