Function at 0x10007f30
Capabilities:
Write file on windows

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x1004c028
mov eax, dword fs:[0]
push eax
sub esp, 0x3c
mov eax, dword [0x10062064]
xor eax, ebp
mov dword [ebp - 0x10], eax
push ebx
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov ebx, ecx
mov dword [ebp - 0x48], ebx
cmp dword [ebx + 0x38], 0
je 0x10008109
cmp byte [ebx + 0x3e], 0
je 0x10008109
push 0xffff
call fcn.10006e20
mov ecx, 0xffff
cmp cx, ax
jne 0x10007f8f
xor al, al
jmp 0x1000810b
push 0
push 8
lea ecx, [ebp - 0x30]
mov dword [ebp - 0x20], 0
mov dword [ebp - 0x1c], 0xf
mov byte [ebp - 0x30], 0
call fcn.100078e0
lea esi, [ebx + 0x40]
mov dword [ebp - 4], 0
mov dword [ebp - 0x40], esi
mov edx, dword [ebp - 0x30]
mov edi, dword [ebp - 0x1c]
cmp edi, 0x10
lea ecx, [ebp - 0x30]
lea eax, [ebp - 0x30]
cmovae eax, edx
cmovae ecx, edx
mov edx, dword [ebx + 0x38]
add ecx, dword [ebp - 0x20]
mov dword [ebp - 0x38], eax
mov dword [ebp - 0x3c], ecx
mov eax, dword [edx]
mov edi, dword [eax + 0x20]
cmp eax, vtable.std::codecvt_wchar_t__char__struct__Mbstatet_.0
jne 0x10008127
mov eax, dword [ebp - 0x38]
xor edi, edi
mov dword [ebp - 0x34], eax
mov eax, dword [esi]
mov dword [ebp - 0x38], eax
mov eax, dword [esi + 4]
mov dword [ebp - 0x44], eax
lea eax, [edx + 8]
push eax
push esi
lea eax, [ebp - 0x18]
push edi
push eax
call fcn.1002e924
mov esi, dword [ebp - 0x34]
mov ebx, eax
add esp, 0x10
test ebx, ebx
jg 0x10008023
mov ebx, dword [ebp - 0x48]
mov edi, 2
jmp 0x10008062
mov eax, dword [ebp - 0x3c]
dec ebx
sub eax, esi
cmp eax, ebx
jge 0x10008045
mov eax, dword [ebp - 0x40]
mov edi, 1
mov ecx, dword [ebp - 0x38]
mov ebx, dword [ebp - 0x48]
mov dword [eax], ecx
mov ecx, dword [ebp - 0x44]
mov dword [eax + 4], ecx
jmp 0x10008062
test ebx, ebx
jle 0x1000805f
push ebx
lea eax, [ebp - 0x18]
push eax
push esi
call fcn.10030650
mov esi, dword [ebp - 0x34]
add esp, 0xc
add esi, ebx
mov dword [ebp - 0x34], esi
mov ebx, dword [ebp - 0x48]
sub edi, 0
je 0x1000807b
sub edi, 1
je 0x1000807f
mov edx, dword [ebp - 0x30]
sub edi, 2
mov edi, dword [ebp - 0x1c]
je 0x100080d9
xor bl, bl
jmp 0x100080db
mov byte [ebx + 0x3e], 0
mov edi, dword [ebp - 0x1c]
lea eax, [ebp - 0x30]
mov edx, dword [ebp - 0x30]
cmp edi, 0x10
cmovae eax, edx
sub esi, eax
je 0x100080b4
push dword [ebx + 0x4c]
cmp edi, 0x10
lea eax, [ebp - 0x30]
push esi
cmovae eax, edx
push 1
push eax
call fcn.100364b3
mov edi, dword [ebp - 0x1c]
add esp, 0x10
mov edx, dword [ebp - 0x30]
cmp esi, eax
jne 0x10008077
cmp byte [ebx + 0x3e], 0
je 0x100080d9
test esi, esi
lea esi, [ebx + 0x40]
jne 0x10007fc0
push 0
push 8
lea ecx, [ebp - 0x30]
call fcn.10007b60
lea esi, [ebx + 0x40]
jmp 0x10007fba
mov bl, 1
cmp edi, 0x10
jb 0x10008105
inc edi
mov eax, edx
cmp edi, 0x1000
jb 0x100080fb
mov edx, dword [edx - 4]
add edi, 0x23
sub eax, edx
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x1000813f
push edi
push edx
call fcn.1002f104
add esp, 8
mov al, bl
jmp 0x1000810b
mov al, 1
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 0x10]
xor ecx, ebp
call fcn.1002f0be
mov esp, ebp
pop ebp
ret
lea eax, [ebp - 0x34]
push eax
mov eax, dword [ebp - 0x38]
push ecx
push eax
push esi
mov ecx, edx
call edi
mov esi, dword [ebp - 0x34]
mov edi, eax
jmp 0x10008062
call fcn.10035ebd
int3