Function at 0x10006820
Capabilities:
Delete file
Get file size
Read file on windows
Write file on windows

Disassembly:
push ebp
lea ebp, [esp - 0x1be8]
mov eax, 0x1be8
call fcn.10078100
push 0xffffffffffffffff
push 0x100e72eb
mov eax, dword fs:[0]
push eax
sub esp, 0xc4
mov eax, dword [0x10139d20]
xor eax, ebp
mov dword [ebp + 0x1be4], eax
push ebx
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov edi, ecx
call fcn.100058ef
mov ecx, eax
call fcn.10017c13
push eax
lea ecx, [ebp]
call fcn.10001df0
lea eax, [ebp]
xor ebx, ebx
push eax
lea ecx, [ebp + 0x38]
mov dword [ebp - 4], ebx
call fcn.10003c90
lea eax, [ebp]
push eax
lea ecx, [ebp + 0x70]
mov byte [ebp - 4], 1
call fcn.10003c90
push str.LatelyCharDraw.xml
lea ecx, [ebp + 0x38]
mov byte [ebp - 4], 2
call fcn.10003cf0
push 0x100f23a4
lea ecx, [ebp + 0x70]
call fcn.10003cf0
cmp dword [ebp + 0x50], 8
mov eax, dword [ebp + 0x3c]
jae 0x100068c2
lea eax, [ebp + 0x3c]
mov esi, dword [sym.imp.KERNEL32.dll_DeleteFileW]
push eax
call esi
cmp dword [ebp + 0x88], 8
mov eax, dword [ebp + 0x74]
jae 0x100068da
lea eax, [ebp + 0x74]
push eax
call esi
lea eax, [ebp + 0x70]
push eax
lea eax, [ebp + 0x1c]
push eax
call fcn.1001b179
pop ecx
pop ecx
lea ecx, [ebp - 0xd0]
mov byte [ebp - 4], 3
call fcn.100b4a50
push 0x38
mov byte [ebp - 4], 4
call fcn.10054d4d
pop ecx
mov dword [ebp - 0x14], eax
cmp eax, ebx
mov byte [ebp - 4], 5
mov esi, 0x100f23a0
je 0x1000692b
push 0x1011e018
push 0x100f2398
push esi
mov ecx, eax
call fcn.100b5160
jmp 0x1000692d
xor eax, eax
push eax
lea ecx, [ebp - 0xd0]
mov byte [ebp - 4], 4
call fcn.100b3ee0
push 0x50
call fcn.10054d4d
pop ecx
mov dword [ebp - 0x14], eax
cmp eax, ebx
mov byte [ebp - 4], 6
je 0x10006961
push 0x100f2390
mov ecx, eax
call fcn.100b5640
mov dword [ebp - 0x14], eax
jmp 0x10006964
mov dword [ebp - 0x14], ebx
mov ecx, dword [ebp - 0x14]
push esi
push 0x100f2388
mov byte [ebp - 4], 4
call fcn.100b5820
mov ecx, dword [edi + 0x360]
call fcn.10013595
mov edi, eax
mov eax, dword [edi + 4]
push edi
push eax
lea ecx, [ebp - 0x24]
call fcn.1004a4ca
jmp 0x10006bd6
lea ecx, [ebp - 0x24]
call fcn.1000c5bc
mov esi, dword [eax]
push 0x50
call fcn.10054d4d
pop ecx
mov dword [ebp - 0x1c], eax
cmp eax, ebx
mov byte [ebp - 4], 7
je 0x100069c3
push str.sign
mov ecx, eax
call fcn.100b5640
mov dword [ebp - 0x1c], eax
jmp 0x100069c6
mov dword [ebp - 0x1c], ebx
push 0x100f2330
lea ecx, [ebp - 0x88]
mov byte [ebp - 4], 4
call fcn.10001df0
mov eax, dword [esi]
lea ecx, [ebp - 0x88]
push ecx
lea ecx, [ebp + 0x54]
push ecx
mov ecx, esi
mov byte [ebp - 4], 8
call dword [eax + 0x18]
push ebx
push 1
lea ecx, [ebp - 0x88]
mov byte [ebp - 4], 0xa
call fcn.10001fc0
push 0xf9e
lea eax, [ebp + 0xc46]
push ebx
push eax
mov word [ebp + 0xc44], bx
call fcn.10077be0
push 0xbb7
lea eax, [ebp + 0x8d]
push ebx
push eax
mov byte [ebp + 0x8c], bl
call fcn.10077be0
mov eax, dword [ebp + 0x58]
add esp, 0x18
cmp dword [ebp + 0x6c], 8
jae 0x10006a42
lea eax, [ebp + 0x58]
push eax
lea eax, [ebp + 0xc44]
push eax
call fcn.100780db
lea eax, [ebp + 0x8c]
push eax
lea eax, [ebp + 0xc44]
push eax
call fcn.1001953a
mov ecx, dword [ebp - 0x1c]
add esp, 0x10
lea eax, [ebp + 0x8c]
push eax
push str.name
call fcn.100b5820
push 0x100f2320
lea ecx, [ebp - 0x50]
call fcn.10001df0
mov eax, dword [esi]
lea ecx, [ebp - 0x50]
push ecx
lea ecx, [ebp - 0x6c]
push ecx
mov ecx, esi
mov byte [ebp - 4], 0xb
call dword [eax + 0x18]
push 0xffffffffffffffff
push ebx
push eax
lea ecx, [ebp + 0x54]
mov byte [ebp - 4], 0xc
call fcn.10002540
push ebx
push 1
lea ecx, [ebp - 0x6c]
call fcn.10001fc0
push ebx
push 1
lea ecx, [ebp - 0x50]
mov byte [ebp - 4], 0xa
call fcn.10001fc0
cmp dword [ebp + 0x6c], 8
mov eax, dword [ebp + 0x58]
jae 0x10006acf
lea eax, [ebp + 0x58]
push eax
lea eax, [ebp + 0xc44]
push eax
call fcn.100780db
lea eax, [ebp + 0x8c]
push eax
lea eax, [ebp + 0xc44]
push eax
call fcn.1001953a
mov ecx, dword [ebp - 0x1c]
add esp, 0x10
lea eax, [ebp + 0x8c]
push eax
push str.height
call fcn.100b5820
push str.content
lea ecx, [ebp - 0x50]
call fcn.10001df0
mov eax, dword [esi]
lea ecx, [ebp - 0x50]
push ecx
lea ecx, [ebp - 0x6c]
push ecx
mov ecx, esi
mov byte [ebp - 4], 0xd
call dword [eax + 0x18]
push 0xffffffffffffffff
push ebx
push eax
lea ecx, [ebp + 0x54]
mov byte [ebp - 4], 0xe
call fcn.10002540
push ebx
push 1
lea ecx, [ebp - 0x6c]
call fcn.10001fc0
push ebx
push 1
lea ecx, [ebp - 0x50]
mov byte [ebp - 4], 0xa
call fcn.10001fc0
cmp dword [ebp + 0x6c], 8
mov eax, dword [ebp + 0x58]
jae 0x10006b5c
lea eax, [ebp + 0x58]
push eax
lea eax, [ebp + 0xc44]
push eax
call fcn.100780db
lea eax, [ebp + 0x8c]
push eax
lea eax, [ebp + 0xc44]
push eax
call fcn.1001953a
push 0x30
call fcn.10054d4d
add esp, 0x14
mov dword [ebp - 0x34], eax
cmp eax, ebx
mov byte [ebp - 4], 0xf
je 0x10006ba1
lea ecx, [ebp + 0x8c]
push ecx
mov ecx, eax
call fcn.1000550b
jmp 0x10006ba3
xor eax, eax
mov ecx, dword [ebp - 0x1c]
push eax
mov byte [ebp - 4], 0xa
mov byte [eax + 0x2c], 1
call fcn.100b3ee0
push dword [ebp - 0x1c]
mov ecx, dword [ebp - 0x14]
call fcn.100b3ee0
push ebx
push 1
lea ecx, [ebp + 0x54]
mov byte [ebp - 4], 4
call fcn.10001fc0
lea ecx, [ebp - 0x24]
call fcn.1002a950
mov eax, dword [edi + 8]
push edi
push eax
lea ecx, [ebp - 0x2c]
call fcn.1004a4ca
lea eax, [ebp - 0x2c]
push eax
lea ecx, [ebp - 0x24]
call fcn.1003f8a6
test al, al
je 0x10006995
push dword [ebp - 0x14]
lea ecx, [ebp - 0xd0]
call fcn.100b3ee0
cmp dword [ebp + 0x34], 0x10
mov eax, dword [ebp + 0x20]
jae 0x10006c11
lea eax, [ebp + 0x20]
push eax
lea ecx, [ebp - 0xd0]
call fcn.100b4de0
cmp dword [ebp + 0x88], 8
mov eax, dword [ebp + 0x74]
mov dword [ebp - 0x18], ebx
jae 0x10006c2f
lea eax, [ebp + 0x74]
push ebx
push 0x80
push 4
push ebx
push 1
push SysReAllocString
push eax
call dword [sym.imp.KERNEL32.dll_CreateFileW]
mov edi, eax
cmp edi, 0xffffffff
je 0x10006c58
push ebx
push edi
call dword [sym.imp.KERNEL32.dll_GetFileSize]
mov dword [ebp - 0x18], eax
mov eax, dword [ebp - 0x18]
inc eax
push eax
call fcn.10054d7d
mov esi, eax
mov eax, dword [ebp - 0x18]
inc eax
push eax
push ebx
push esi
call fcn.10077be0
add esp, 0x10
push ebx
lea eax, [ebp - 0x30]
push eax
mov eax, dword [ebp - 0x18]
inc eax
push eax
push esi
push edi
mov dword [ebp - 0x30], ebx
call dword [sym.imp.KERNEL32.dll_ReadFile]
push edi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov eax, dword [ebp - 0x18]
xor ecx, ecx
push 2
inc eax
pop edx
mul edx
seto cl
neg ecx
or ecx, eax
push ecx
call fcn.10054d7d
mov edi, eax
mov eax, dword [ebp - 0x18]
lea eax, [eax + eax + 2]
push eax
push ebx
push edi
call fcn.10077be0
push edi
push esi
call fcn.10019511
mov eax, dword [ebp - 0x18]
inc eax
push eax
push ebx
push esi
call fcn.10077be0
mov eax, dword [ebp - 0x18]
lea eax, [eax + eax + 1]
push eax
call fcn.10054d7d
mov ecx, dword [ebp - 0x18]
lea ecx, [ecx + ecx + 1]
push ecx
push ebx
push eax
mov dword [ebp - 0x1c], eax
call fcn.10077be0
lea eax, [ebp - 0x18]
push eax
push dword [ebp - 0x1c]
push edi
call fcn.10019568
mov eax, dword [ebp + 0x3c]
add esp, 0x40
cmp dword [ebp + 0x50], 8
jae 0x10006d06
lea eax, [ebp + 0x3c]
push 0x100f2368
push eax
call fcn.1007809e
cmp eax, ebx
pop ecx
pop ecx
mov dword [ebp - 0x14], eax
je 0x10006d72
push eax
push 1
lea eax, [ebp - 0xd]
push 1
push eax
mov byte [ebp - 0xd], 0xef
call fcn.10077f4b
push dword [ebp - 0x14]
lea eax, [ebp - 0xd]
push 1
push 1
push eax
mov byte [ebp - 0xd], 0xbb
call fcn.10077f4b
push dword [ebp - 0x14]
lea eax, [ebp - 0xd]
push 1
push 1
push eax
mov byte [ebp - 0xd], 0xbf
call fcn.10077f4b
push dword [ebp - 0x14]
mov eax, dword [ebp - 0x18]
dec eax
push eax
push 1
push dword [ebp - 0x1c]
call fcn.10077f4b
add esp, 0x40
push dword [ebp - 0x14]
call fcn.10077db5
pop ecx
push esi
call fcn.10054d78
push edi
call fcn.10054d78
push dword [ebp - 0x1c]
call fcn.10054d78
mov eax, dword [ebp + 0x74]
add esp, 0xc
cmp dword [ebp + 0x88], 8
jae 0x10006d98
lea eax, [ebp + 0x74]
push eax
call dword [sym.imp.KERNEL32.dll_DeleteFileW]
lea ecx, [ebp - 0xd0]
mov byte [ebp - 4], 3
call fcn.10005a2e
xor esi, esi
push ebx
inc esi
push esi
lea ecx, [ebp + 0x1c]
call fcn.10001f70
push ebx
push esi
lea ecx, [ebp + 0x70]
call fcn.10001fc0
push ebx
push esi
lea ecx, [ebp + 0x38]
call fcn.10001fc0
push ebx
push esi
lea ecx, [ebp]
call fcn.10001fc0
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [ebp + 0x1be4]
xor ecx, ebp
call fcn.100773e8
add ebp, 0x1be8
leave
ret