Function at 0x427c60
Capabilities:
Write file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x94
mov ecx, dword [0x49ec84]
push ebx
mov eax, 0x1010101
mov dword [0x4a36e8], eax
mov dword [0x4a36ec], eax
push esi
mov dword [0x4a36f0], eax
push edi
xor edi, edi
mov dword [0x4a36f4], eax
mov dword [0x4a3710], edi
mov dword [0x4a3700], 0x10
mov dword [0x4a3714], edi
mov edx, dword [ecx + 0x15]
lea eax, [ebp - 0x94]
push str._bwdxf.drw
push eax
mov dword [ebp - 4], edi
mov dword [0x4a36fc], edx
mov dword [0x4a36f8], edi
mov dword [0x4a370c], edi
call sub.MSVCRT.dll_strcpy
mov ecx, dword [ebp + 8]
mov esi, dword [sym.imp.MSVCRT.dll__fsopen]
push 0x20
push 0x47bbe0
push ecx
call esi
mov ebx, eax
add esp, 0x14
cmp ebx, edi
je 0x428054
push 0x10
lea edx, [ebp - 0x94]
push 0x47bbe4
push edx
call esi
add esp, 0xc
cmp eax, edi
mov dword [0x4a36f8], eax
je 0x428054
push 0x10
push 0x47bbe8
push 0x47bbec
call esi
add esp, 0xc
cmp eax, edi
mov dword [0x4a370c], eax
je 0x428054
mov esi, dword [sym.imp.MSVCRT.dll_fgets]
push ebx
lea eax, [ebp - 0x68]
push 0x50
push eax
call esi
add esp, 0xc
test eax, eax
je 0x427f11
lea ecx, [ebp - 0x68]
push ecx
call fcn.00429680
lea edx, [ebp - 0x68]
push str._LIMMIN
push edx
call sub.MSVCRT.dll_strcmp
add esp, 0xc
test eax, eax
je 0x427eee
lea eax, [ebp - 0x68]
push str._EXTMIN
push eax
call sub.MSVCRT.dll_strcmp
add esp, 8
test eax, eax
je 0x427eee
lea ecx, [ebp - 0x68]
push str._LIMMAX
push ecx
call sub.MSVCRT.dll_strcmp
add esp, 8
test eax, eax
je 0x427edc
lea edx, [ebp - 0x68]
push str._EXTMAX
push edx
call sub.MSVCRT.dll_strcmp
add esp, 8
test eax, eax
je 0x427edc
lea eax, [ebp - 0x68]
push str._VIEWCTR
push eax
call sub.MSVCRT.dll_strcmp
add esp, 8
test eax, eax
jne 0x427dd1
push ebx
call fcn.00429fc0
jmp 0x427ef4
lea ecx, [ebp - 0x68]
push str._VIEWSIZE
push ecx
call sub.MSVCRT.dll_strcmp
add esp, 8
test eax, eax
jne 0x427dfb
push ebx
call fcn.0042a060
mov eax, dword [ebp - 4]
add esp, 4
inc eax
mov dword [ebp - 4], eax
jmp 0x427ef7
lea edx, [ebp - 0x68]
push str.ACTIVE
push edx
call sub.MSVCRT.dll_strcmp
add esp, 8
test eax, eax
jne 0x427e25
push ebx
call fcn.0042a100
mov eax, dword [ebp - 4]
add esp, 4
inc eax
mov dword [ebp - 4], eax
jmp 0x427ef7
lea eax, [ebp - 0x68]
push 0x47bc34
push eax
call sub.MSVCRT.dll_strcmp
add esp, 8
test eax, eax
jne 0x427e8f
push ebx
call fcn.004296c0
mov esi, dword [0x4a3700]
add esp, 4
cmp esi, 0x10
jle 0x427e53
mov esi, 0x10
xor ecx, ecx
cmp esi, edi
jle 0x427ef7
mov edx, dword [0x4a3710]
add edx, 0x20
xor eax, eax
mov ax, word [edx]
cmp ax, di
jl 0x427e79
mov byte [ecx + 0x4a36e8], 1
jmp 0x427e85
neg eax
mov word [edx], ax
mov byte [ecx + 0x4a36e8], 0
inc ecx
add edx, 0x23
cmp ecx, esi
jl 0x427e66
jmp 0x427ef7
lea eax, [ebp - 0x68]
push str.BLOCKS
push eax
call sub.MSVCRT.dll_strcmp
add esp, 8
test eax, eax
jne 0x427ec1
cmp dword [ebp - 4], edi
je 0x428031
push ebx
lea ecx, [ebp - 0x68]
push 0x50
push ecx
call esi
push ebx
call fcn.004298b0
add esp, 0x10
jmp 0x427ef7
lea edx, [ebp - 0x68]
push str.ENTITIES
push edx
call sub.MSVCRT.dll_strcmp
add esp, 8
test eax, eax
je 0x427fa6
jmp 0x427ef7
push ebx
call fcn.0042a2d0
mov eax, dword [ebp - 4]
add esp, 4
inc eax
mov dword [ebp - 4], eax
jmp 0x427ef7
push ebx
call fcn.0042a230
add esp, 4
mov esi, dword [sym.imp.MSVCRT.dll_fgets]
push ebx
lea eax, [ebp - 0x68]
push 0x50
push eax
call esi
add esp, 0xc
test eax, eax
jne 0x427d44
mov esi, dword [ebp + 8]
lea edx, [ebp - 0x80]
push 0x47bc50
push edx
call dword [sym.imp.MSVCRT.dll_sprintf]
mov eax, dword [0x4a36f8]
push eax
call dword [sym.imp.MSVCRT.dll_ftell]
mov edx, dword [0x4a36f8]
mov edi, eax
mov ecx, edi
sub ecx, esi
push 0
push esi
mov esi, dword [sym.imp.MSVCRT.dll_fseek]
sub ecx, 0x18
push edx
mov dword [ebp - 0x6c], ecx
call esi
mov eax, dword [0x4a36f8]
push eax
push 1
lea ecx, [ebp - 0x80]
push 0x18
push ecx
call dword [sym.imp.MSVCRT.dll_fwrite]
add esp, 0x28
cmp eax, 1
je 0x42800e
push 0x1d1
call fcn.00410630
push eax
call fcn.0040d270
mov eax, dword [0x4a3710]
add esp, 8
test eax, eax
je 0x427f9d
push eax
call dword [sym.imp.MSVCRT.dll_free]
add esp, 4
mov dword [0x4a3710], 0
pop edi
pop esi
xor eax, eax
pop ebx
mov esp, ebp
pop ebp
ret
cmp dword [ebp - 4], edi
je 0x428031
mov ecx, dword [0x4a36f8]
push 0xaca
push ecx
call fcn.00428c30
mov edx, dword [0x4a36f8]
push edx
call fcn.00428ba0
mov eax, dword [0x4a36f8]
push eax
call dword [sym.imp.MSVCRT.dll_ftell]
mov edx, dword [0x4a36f8]
mov esi, eax
push edi
lea ecx, [esi + 0x18]
push ecx
push edx
call dword [sym.imp.MSVCRT.dll_fseek]
push ebx
lea eax, [ebp - 0x68]
push 0x50
push eax
call dword [sym.imp.MSVCRT.dll_fgets]
mov ecx, dword [0x4a36f8]
push ecx
push ebx
call fcn.00429a90
add esp, 0x30
jmp 0x427f14
mov edx, dword [0x4a36f8]
push 0
push edi
push edx
call esi
mov eax, dword [0x4a36f8]
push eax
call fcn.00428ca0
mov eax, dword [ebp - 4]
add esp, 0x10
test eax, eax
jne 0x428060
xor edi, edi
push 0x1cd
call fcn.00410630
push eax
lea ecx, [ebp - 0x68]
push ecx
call dword [sym.imp.MSVCRT.dll_sprintf]
lea edx, [ebp - 0x68]
push edx
call fcn.0040d270
add esp, 0x10
jmp 0x428062
push 3
call fcn.0040c4d0
add esp, 4
jmp 0x428062
xor edi, edi
mov eax, dword [0x4a3710]
cmp eax, edi
je 0x42807b
push eax
call dword [sym.imp.MSVCRT.dll_free]
add esp, 4
mov dword [0x4a3710], edi
cmp ebx, edi
mov esi, dword [sym.imp.MSVCRT.dll_fclose]
je 0x42808b
push ebx
call esi
add esp, 4
mov eax, dword [0x4a36f8]
cmp eax, edi
je 0x42809a
push eax
call esi
add esp, 4
mov eax, dword [0x4a370c]
cmp eax, edi
je 0x4280a9
push eax
call esi
add esp, 4
push str.t1.tmp
call dword [sym.imp.MSVCRT.dll__unlink]
mov eax, dword [ebp - 4]
add esp, 4
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret