Function at 0x683860
Capabilities:
Write file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x118
mov eax, dword [0x6d7a68]
xor eax, ebp
mov dword [ebp - 4], eax
push ebx
mov ebx, dword [ebp + 0xc]
push esi
push edi
mov edi, dword [ebp + 8]
push 0
mov esi, ecx
mov eax, dword [esi + 0xc]
push 0
push 0x19c
push eax
mov dword [ebp - 0x118], ebx
mov dword [ebp - 0x10c], 0
call fcn.008921c0
add esp, 0x10
test ax, ax
je 0x6838af
or dword [ebp - 0x10c], 1
mov ecx, dword [esi + 0xc]
push 0
push 0
push 0x12e
push ecx
call fcn.008921c0
add esp, 0x10
test ax, ax
je 0x6838d0
or dword [ebp - 0x10c], 2
mov edx, dword [esi + 0xc]
push 0
push 0
push 0x12c
push edx
call fcn.008921c0
add esp, 0x10
test ax, ax
je 0x6838f1
or dword [ebp - 0x10c], 4
mov eax, dword [esi + 0xc]
push 0
push 0
push 0x12d
push eax
call fcn.008921c0
add esp, 0x10
test ax, ax
je 0x683912
or dword [ebp - 0x10c], 8
mov ecx, dword [esi + 0xc]
push 0
push 0
push 1
push ecx
call fcn.008921c0
add esp, 0x10
test ax, ax
je 0x683930
or dword [ebp - 0x10c], 0x10
mov edx, dword [esi + 0xc]
push 0
push 0
push 0x230
push edx
call fcn.008921c0
add esp, 0x10
test ax, ax
je 0x683954
or dword [ebp - 0x10c], 0x2000
mov eax, dword [esi + 0xc]
push 0
push 0
push 0x19b
push eax
call fcn.008921c0
add esp, 0x10
test ax, ax
je 0x683975
or dword [ebp - 0x10c], 0x20
mov ecx, dword [esi + 0xc]
push 0
push 0
push 2
push ecx
call fcn.008921c0
add esp, 0x10
test ax, ax
je 0x683993
or dword [ebp - 0x10c], 0x40
mov edx, dword [esi + 0xc]
push 0
push 0
push 0x194
push edx
call fcn.008921c0
add esp, 0x10
test ax, ax
je 0x6839b7
or dword [ebp - 0x10c], 0x80
mov eax, dword [esi + 0xc]
push 0
push 0
push 0x1f6
push eax
call fcn.008921c0
add esp, 0x10
test ax, ax
je 0x6839db
or dword [ebp - 0x10c], 0x4000
mov ecx, dword [esi + 0xc]
push 0
push 0
push 0x191
push ecx
call fcn.008921c0
add esp, 0x10
test ax, ax
je 0x6839ff
or dword [ebp - 0x10c], 0x100
mov edx, dword [esi + 0xc]
push 0
push 0
push 0x1a6
push edx
call fcn.008921c0
add esp, 0x10
test ax, ax
je 0x683a23
or dword [ebp - 0x10c], 0x200
mov eax, dword [esi + 0xc]
push 0
push 0
push 0x193
push eax
call fcn.008921c0
add esp, 0x10
test ax, ax
je 0x683a47
or dword [ebp - 0x10c], 0x400
mov ecx, dword [esi + 0xc]
push 0
push 0
push 0x238
push ecx
call fcn.008921c0
add esp, 0x10
test ax, ax
je 0x683a6b
or dword [ebp - 0x10c], 0x800
mov edx, dword [esi + 0xc]
push 0
push 0
push 0x190
push edx
call fcn.008921c0
add esp, 0x10
test ax, ax
je 0x683a8f
or dword [ebp - 0x10c], 0x1000
push 0x68dd90
push edi
call fcn.0068b58d
mov edi, eax
add esp, 8
test edi, edi
je 0x683ba7
mov eax, dword [esi + 0x10]
and dword [eax], 1
mov eax, dword [esi + 0x10]
push edi
push 4
push 1
push eax
call fcn.0068b447
push edi
push 4
lea ecx, [ebp - 0x10c]
push 1
push ecx
call fcn.0068b447
add esp, 0x20
test ebx, ebx
je 0x683ba7
push 0
push 0
push 0x18b
push ebx
mov ebx, dword [fcn.0068c40c]
mov byte [ebp - 0x10d], 0
call ebx
push edi
push 4
lea edx, [ebp - 0x114]
push 1
push edx
mov dword [ebp - 0x114], eax
call fcn.0068b447
xor esi, esi
add esp, 0x10
cmp dword [ebp - 0x114], esi
jbe 0x683b9e
jmp 0x683b20
mov ecx, dword [ebp - 0x118]
lea eax, [ebp - 0x108]
push eax
push esi
push 0x189
push ecx
call ebx
lea edx, [ebp - 0x108]
push edx
mov byte [ebp - 5], 0
call dword [0x68c140]
cmp eax, 0xffffffff
je 0x683b93
lea eax, [ebp - 0x108]
lea edx, [eax + 1]
mov cl, byte [eax]
add eax, 1
test cl, cl
jne 0x683b55
sub eax, edx
push edi
add al, 1
push 1
mov byte [ebp - 0x10d], al
lea eax, [ebp - 0x10d]
push 1
push eax
call fcn.0068b447
movzx ecx, byte [ebp - 0x10d]
push edi
push ecx
lea edx, [ebp - 0x108]
push 1
push edx
call fcn.0068b447
add esp, 0x20
add esi, 1
cmp esi, dword [ebp - 0x114]
jb 0x683b20
push edi
call fcn.0068b26c
add esp, 4
mov ecx, dword [ebp - 4]
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.0067de1d
mov esp, ebp
pop ebp
ret 8