Function at 0x413510
Capabilities:
Write file on windows

Disassembly:
sub esp, 0x370
mov eax, dword [0x44aad4]
xor eax, esp
mov dword [esp + 0x368], eax
mov eax, dword [edi + 0x10cc07c]
mov ecx, dword [edi + 0x10cc080]
mov edx, dword [eax + 0xe0]
mov eax, dword [eax + 0xe4]
push ebx
push ebp
push esi
mov esi, dword [ecx + 0xe0]
mov ecx, dword [ecx + 0xe4]
cmp eax, ecx
lea ebx, [edi + 0x10969f8]
jg 0x41356d
jl 0x41355b
cmp edx, esi
jae 0x41356d
mov dword [esp + 0x10], edx
mov dword [esp + 0x14], eax
mov dword [esp + 0x18], esi
mov dword [esp + 0x1c], ecx
jmp 0x413589
mov dword [esp + 0x10], esi
mov dword [esp + 0x14], ecx
mov dword [esp + 0x18], edx
mov dword [esp + 0x1c], eax
mov esi, edx
mov edx, dword [esp + 0x10]
mov ecx, eax
mov eax, dword [esp + 0x14]
cmp edx, esi
jne 0x413595
cmp eax, ecx
je 0x413af8
xor ebp, ebp
sub esi, edx
sbb ecx, eax
mov eax, dword [edi + 0x10cc078]
mov dl, byte [eax + 0x781c]
mov dword [esp + 0x34], ecx
mov ecx, dword [eax + 0x34]
mov eax, dword [0x450440]
push 0x100
shl eax, 9
add eax, 0x44f440
push eax
mov dword [esp + 0x38], esi
fild qword [esp + 0x38]
mov dword [esp + 0x48], ecx
mov ecx, dword [0x44f3ac]
push 0xd4
push ecx
fstp qword [esp + 0x70]
mov dword [esp + 0x4c], ebp
mov dword [esp + 0x38], ebp
mov byte [esp + 0x1f], dl
call dword [sym.imp.USER32.dll_LoadStringW]
mov eax, dword [0x450440]
lea edx, [eax + 1]
and edx, 0x80000007
jns 0x413604
dec edx
or edx, 0xfffffff8
inc edx
mov ebp, dword [sym.imp.USER32.dll_SendMessageW]
shl eax, 9
add eax, 0x44f440
push eax
mov eax, dword [edi + 0x1097a10]
push 2
push 0x400
push eax
mov dword [0x450440], edx
call ebp
push str..alf
push ebx
call fcn.00424e4b
add esp, 8
test eax, eax
jne 0x413821
push str..ALF
push ebx
call fcn.00424e4b
add esp, 8
test eax, eax
jne 0x413821
push 0x44257c
lea edx, [esp + 0x24]
push ebx
push edx
mov dword [esp + 0x38], eax
call fcn.00424a9d
add esp, 0xc
cmp dword [edi + 0x1097600], 1
jne 0x413694
push str.From_Begin_mks_
push str._16s
lea eax, [esp + 0x178]
push 0x200
push eax
call fcn.004237d5
add esp, 0x10
cmp dword [edi + 0x1097600], 0
jne 0x4136cb
push str.mks
push str.UnixSecond
push str.Time
push str.Date
push str._7s__8s__10s___7s
lea ecx, [esp + 0x184]
push 0x200
push ecx
call fcn.004237d5
add esp, 0x1c
mov edx, dword [edi + 0x10cc078]
xor esi, esi
cmp dword [edx + 0x2c], esi
jle 0x413727
lea ebx, [edi + 0x10971f8]
mov edi, edi
cmp dword [ebx], 0
je 0x413716
lea eax, [esp + 0x170]
lea edx, [eax + 1]
nop
mov cl, byte [eax]
add eax, 1
test cl, cl
jne 0x4136f0
lea ecx, [esi + 1]
push ecx
sub eax, edx
push str.____Chan__04d
lea edx, [esp + eax + 0x178]
push 0x10
push edx
call fcn.004237d5
add esp, 0x10
mov eax, dword [edi + 0x10cc078]
add esi, 1
add ebx, 4
cmp esi, dword [eax + 0x2c]
jl 0x4136e0
mov edx, dword [esp + 0x20]
lea ecx, [esp + 0x170]
push ecx
push 0x441ff4
push edx
call fcn.00423e65
add esp, 0xc
mov ebx, dword [esp + 0x14]
cmp ebx, dword [esp + 0x1c]
mov ebp, dword [esp + 0x10]
mov dword [esp + 0x30], ebp
jg 0x413a9c
jl 0x413765
mov eax, ebp
cmp eax, dword [esp + 0x18]
jae 0x413a9c
mov ecx, ebp
sub ecx, dword [esp + 0x10]
mov edx, ebx
sbb edx, dword [esp + 0x14]
mov dword [esp + 0x58], ecx
mov dword [esp + 0x5c], edx
fild qword [esp + 0x58]
fst qword [esp + 0x48]
fld qword [esp + 0x60]
fdivr st(1)
fmul qword [0x4434c8]
call fcn.004278f0
mov esi, eax
cmp esi, dword [esp + 0x3c]
je 0x4137b9
mov eax, dword [edi + 0x1097a10]
fstp st(0)
push esi
push 1
push 0x400
push eax
call dword [sym.imp.USER32.dll_SendMessageW]
fld qword [esp + 0x48]
mov dword [esp + 0x3c], esi
cmp dword [esp + 0x2c], 0
jne 0x413a14
cmp dword [edi + 0x1097600], 1
jne 0x413885
mov ecx, dword [edi + 0x10cc078]
fld dword [ecx + 0x4ff0]
fdivr qword [0x443498]
fmulp st(1)
fld st(0)
call fcn.00427926
push 0
push 0xa
push edx
push eax
call fcn.004327b0
fdiv qword [0x4434e0]
push edx
push eax
sub esp, 8
lea edx, [esp + 0x80]
fstp qword [esp]
push str._14.0lf__1d
push 0x100
push edx
call fcn.004237d5
add esp, 0x1c
jmp 0x413887
mov esi, dword [edi + 0x10cc078]
push 0
push 0
push 1
push ebx
xor eax, eax
mov dword [esp + 0x3c], 1
call fcn.00403020
push 0
push 0x20
push 3
push 0
push 0
push 0x40000000
push ebx
call dword [sym.imp.KERNEL32.dll_CreateFileW]
cmp eax, 0xffffffff
mov dword [esp + 0x28], eax
jne 0x413873
mov ecx, dword [edi + 0x1097a10]
push 0x64
push 1
push 0x400
push ecx
call ebp
jmp 0x413aee
push 2
push 0
push 0
push eax
call dword [sym.imp.KERNEL32.dll_SetFilePointer]
jmp 0x413741
fstp st(0)
cmp dword [edi + 0x1097600], 0
jne 0x41392b
mov eax, dword [edi + 0x10cc078]
fld dword [eax + 0x4ff0]
fdivr qword [0x443500]
call fcn.00427926
push ebx
push ebp
push edx
push eax
call fcn.004279a0
mov ecx, dword [edi + 0x1095eb8]
sub ecx, eax
mov eax, dword [edi + 0x1095ebc]
sbb eax, edx
push eax
mov edx, eax
push ecx
lea eax, [esp + 0x5c]
push eax
sar edx, 0x1f
call fcn.004011a0
mov ecx, dword [esp + 0x54]
movzx edx, word [edi + 0x1095ed4]
push ecx
movzx ecx, word [edi + 0x1095ed0]
push eax
movzx eax, word [edi + 0x1095ed2]
push edx
movzx edx, word [edi + 0x1095ec8]
push eax
movzx eax, word [edi + 0x1095eca]
push ecx
movzx ecx, word [edi + 0x1095ece]
sub edx, 0x7d0
push edx
push eax
push ecx
push str._02d._02d._02d__2d:_02d:_02d__10d__6d
lea edx, [esp + 0x94]
push 0x100
push edx
call fcn.004237d5
add esp, 0x2c
mov eax, dword [edi + 0x10cc078]
xor esi, esi
cmp dword [eax + 0x2c], esi
jle 0x4139fb
lea ecx, [edi + 0x10971f8]
mov dword [esp + 0x24], ecx
mov edx, dword [esp + 0x24]
cmp dword [edx], 0
je 0x4139e4
lea eax, [esp + 0x70]
lea edx, [eax + 1]
lea ebx, [ebx]
mov cl, byte [eax]
add eax, 1
test cl, cl
jne 0x413960
mov ecx, dword [edi + 0x10cc078]
sub eax, edx
lea ebp, [esp + eax + 0x70]
mov eax, dword [esp + 0x30]
push ebx
push eax
mov eax, esi
call fcn.00402c90
fstp dword [esp + 0x48]
fld dword [esp + 0x48]
sub esp, 0xc
fst qword [esp + 4]
fstp dword [esp]
call fcn.004100e0
push eax
lea ecx, [esp + 0x17c]
push 0x100
push ecx
call fcn.004237d5
add esp, 0x14
lea edx, [esp + 0x170]
push 0x2e
push edx
call fcn.00424ec0
add esp, 8
test eax, eax
je 0x4139c8
mov byte [eax], 0x2c
lea eax, [esp + 0x170]
push eax
push str._12s
push 0xc
push ebp
call fcn.004237d5
mov ebp, dword [esp + 0x40]
add esp, 0x10
mov ecx, dword [edi + 0x10cc078]
add dword [esp + 0x24], 4
add esi, 1
cmp esi, dword [ecx + 0x2c]
jl 0x413946
mov eax, dword [esp + 0x20]
lea edx, [esp + 0x70]
push edx
push 0x441ff4
push eax
call fcn.00423e65
add esp, 0xc
jmp 0x413a7c
mov ecx, dword [edi + 0x10cc078]
fstp st(0)
xor esi, esi
cmp dword [ecx + 0x2c], esi
jle 0x413a7c
cmp byte [esp + 0xf], 0
je 0x413a42
mov eax, esi
cdq
idiv dword [esp + 0x40]
mov edx, 1
mov ecx, eax
mov al, byte [esp + 0xf]
shl edx, cl
test al, dl
je 0x413a6e
mov ecx, dword [edi + 0x10cc078]
push ebx
push ebp
mov eax, esi
call fcn.00402c90
fstp dword [esp + 0x44]
mov eax, dword [esp + 0x28]
push 0
lea ecx, [esp + 0x70]
push ecx
push 4
lea edx, [esp + 0x50]
push edx
push eax
call dword [sym.imp.KERNEL32.dll_WriteFile]
mov ecx, dword [edi + 0x10cc078]
add esi, 1
cmp esi, dword [ecx + 0x2c]
jl 0x413a23
add ebp, 1
adc ebx, 0
cmp ebx, dword [esp + 0x1c]
mov dword [esp + 0x30], ebp
jl 0x413765
jg 0x413a9c
cmp ebp, dword [esp + 0x18]
jb 0x413765
cmp dword [esp + 0x2c], 0
je 0x413ac1
mov edx, dword [esp + 0x14]
mov eax, dword [esp + 0x10]
mov ebx, dword [esp + 0x28]
push edx
push eax
mov ecx, edi
call fcn.00415c60
push ebx
call dword [sym.imp.KERNEL32.dll_CloseHandle]
jmp 0x413ace
mov ecx, dword [esp + 0x20]
push ecx
call fcn.0042406c
add esp, 4
mov edx, dword [edi + 0x1097a10]
push 0x64
push 1
push 0x400
push edx
mov dword [edi + 0x1097a30], 1
call dword [sym.imp.USER32.dll_SendMessageW]
mov dword [edi + 0x1097a10], 0
mov ecx, dword [esp + 0x374]
pop esi
pop ebp
pop ebx
xor ecx, esp
call fcn.0042374b
add esp, 0x370
ret