Function at 0x438bbc
Capabilities:
Clear file content
Get file size
Write file on windows

Disassembly:
push ebp
mov ebp, esp
add esp, 0xfffff004
push eax
add esp, 0xffffffe0
push ebx
push esi
push edi
mov edi, dword [ebp + 0x20]
mov ebx, dword [ebp + 0xc]
test edi, 0x10000000
mov esi, dword [ebp + 8]
je 0x438be2
call fcn.00403314
test edi, 0x20
je 0x438c05
mov al, byte [ebx + 0x2c]
test al, al
jne 0x438c05
mov dl, byte [ebx + 0x130]
test dl, dl
jne 0x438c05
mov eax, 1
jmp 0x439038
test edi, 0x200
jne 0x438c25
lea edx, [ebx + 0x2c]
push edx
call fcn.00438ab4
pop ecx
test al, al
je 0x438c25
mov eax, 1
jmp 0x439038
mov edx, dword [ebp + 0x14]
mov ecx, dword [ebx + 0x20]
add dword [edx], ecx
test byte [ebx], 0x10
je 0x438c39
mov eax, dword [ebp + 0x1c]
inc dword [eax]
jmp 0x438c3e
mov edx, dword [ebp + 0x18]
inc dword [edx]
test edi, 0x8000
je 0x438c55
test byte [ebx], 0x10
jne 0x438c55
mov eax, 1
jmp 0x439038
mov eax, dword [ebx]
test al, 0x10
je 0x438c8a
test edi, 0x100
je 0x438c8a
test ah, 4
je 0x438c7a
push 5
push 0x5ea4af
push esi
call fcn.004042d0
add esp, 0xc
jmp 0x438c8a
push 5
push 0x5ea4b5
push esi
call fcn.004042d0
add esp, 0xc
test edi, 0x20
je 0x438df4
test byte [ebx], 4
je 0x438cad
push 1
push 0x5ea4bb
push esi
call fcn.004042d0
add esp, 0xc
jmp 0x438cbd
push 1
push 0x5ea4bd
push esi
call fcn.004042d0
add esp, 0xc
test byte [ebx], 2
je 0x438cd4
push 1
push 0x5ea4bf
push esi
call fcn.004042d0
add esp, 0xc
jmp 0x438ce4
push 1
push 0x5ea4c1
push esi
call fcn.004042d0
add esp, 0xc
test byte [ebx], 1
je 0x438cfb
push 1
push 0x5ea4c3
push esi
call fcn.004042d0
add esp, 0xc
jmp 0x438d0b
push 1
push 0x5ea4c5
push esi
call fcn.004042d0
add esp, 0xc
test byte [ebx], 0x20
je 0x438d22
push 1
push 0x5ea4c7
push esi
call fcn.004042d0
add esp, 0xc
jmp 0x438d32
push 1
push 0x5ea4c9
push esi
call fcn.004042d0
add esp, 0xc
test byte [ebx + 1], 4
je 0x438d4a
push 1
push 0x5ea4cb
push esi
call fcn.004042d0
add esp, 0xc
jmp 0x438d71
test byte [ebx], 0x10
je 0x438d61
push 1
push 0x5ea4cd
push esi
call fcn.004042d0
add esp, 0xc
jmp 0x438d71
push 1
push 0x5ea4cf
push esi
call fcn.004042d0
add esp, 0xc
lea edx, [ebp - 0xc]
push edx
lea ecx, [ebx + 0x14]
push ecx
call sub.KERNEL32.dll_FileTimeToLocalFileTime
lea eax, [ebp - 0x1020]
push eax
lea edx, [ebp - 0xc]
push edx
call sub.KERNEL32.dll_FileTimeToSystemTime
movzx ecx, word [ebp - 0x1020]
push ecx
movzx eax, word [ebp - 0x101e]
push eax
movzx edx, word [ebp - 0x101a]
push edx
movzx ecx, word [ebp - 0x1014]
push ecx
movzx eax, word [ebp - 0x1016]
push eax
lea eax, [ebp - 0x1010]
movzx edx, word [ebp - 0x1018]
push edx
mov ecx, dword [ebx + 0x20]
push ecx
push 0x5ea4d1
push eax
call fcn.004d75f8
add esp, 0x24
lea edx, [ebp - 0x1010]
push edx
call fcn.004d2f1c
pop ecx
push eax
lea ecx, [ebp - 0x1010]
push ecx
push esi
call fcn.004042d0
add esp, 0xc
test edi, 0x40
je 0x438e34
mov eax, dword [ebp + 0x10]
push esi
push edi
mov edi, eax
xor eax, eax
or ecx, 0xffffffff
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
lea esi, [ebp - 0x1010]
xchg edi, esi
mov edx, ecx
mov eax, edi
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, edx
and ecx, 3
rep movsb byte es:[edi], byte [esi]
pop edi
pop esi
mov eax, dword [ebp + 0x10]
push eax
call fcn.004d2f1c
pop ecx
jmp 0x438e3d
mov byte [ebp - 0x1010], 0
xor eax, eax
push edi
push eax
push ebx
call fcn.00438a2c
add esp, 0xc
mov dword [ebp - 4], eax
mov edx, dword [ebp - 4]
test edx, edx
je 0x438e7a
test edi, 0x40
je 0x438e67
lea ecx, [ebp - 0x1010]
push ecx
call fcn.00438ae8
pop ecx
mov eax, dword [ebp - 4]
push eax
lea edx, [ebp - 0x1010]
push edx
call fcn.004d2e40
add esp, 8
test edi, 0x200000
je 0x438e93
push 0
lea ecx, [ebp - 0x1010]
push ecx
call fcn.00438900
add esp, 8
lea eax, [ebp - 0x1010]
push eax
call fcn.004d2f1c
pop ecx
push eax
lea edx, [ebp - 0x1010]
push edx
push esi
call fcn.004042d0
add esp, 0xc
push esi
call fcn.004043a4
test edi, 0x400000
pop ecx
je 0x439033
push 0x5ea4f8
lea esi, [ebx + 0x2c]
push esi
call fcn.004d30a0
add esp, 8
test eax, eax
jne 0x439033
mov eax, edi
and eax, 0x10000000
test eax, eax
je 0x438f2a
push esi
push 0x5ea502
lea edx, [ebp - 0x1010]
push edx
call fcn.004d75f8
add esp, 0xc
and edi, 0x10000000
test edi, edi
je 0x438f2a
push 0
push 0x2006
push 0x3c
push 0xffffffffffffff9c
push 0x8c
push 0x50
push 0
lea ecx, [ebp - 0x1010]
push ecx
call fcn.00403134
add esp, 0x20
mov eax, dword [ebp + 0x10]
push esi
mov edi, eax
xor eax, eax
or ecx, 0xffffffff
lea esi, [ebp - 0x1010]
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
mov edx, ecx
xchg edi, esi
shr ecx, 2
mov eax, edi
rep movsd dword es:[edi], dword [esi]
mov ecx, edx
lea eax, [ebp - 0x1010]
and ecx, 3
rep movsb byte es:[edi], byte [esi]
pop esi
push eax
call fcn.004d2f1c
pop ecx
test eax, eax
je 0x438f93
lea edx, [ebp - 0x1010]
push edx
call fcn.004d2f1c
pop ecx
movsx ecx, byte [ebp + eax - 0x1011]
cmp ecx, 0x5c
je 0x438f93
push 0x5ea50a
lea eax, [ebp - 0x1010]
push eax
call fcn.004d2e40
add esp, 8
push esi
lea edx, [ebp - 0x1010]
push edx
call fcn.004d2e40
add esp, 8
lea ecx, [ebp - 0x1010]
push 0
push 0x80
push 3
push 0
push 3
push 0x40000000
push ecx
call sub.KERNEL32.dll_CreateFileA
mov ebx, eax
cmp ebx, 0xffffffff
je 0x439033
push 0x1000
push 0
lea eax, [ebp - 0x1010]
push eax
call fcn.004d2d9c
add esp, 0xc
push 0
push ebx
call sub.KERNEL32.dll_GetFileSize
mov edi, eax
xor esi, esi
test edi, edi
je 0x43902d
push ebx
call fcn.00404054
pop ecx
lea eax, [ebp - 0x10]
push 0
push eax
lea edx, [ebp - 0x1010]
push 0x1000
push edx
push ebx
call sub.KERNEL32.dll_WriteFile
test eax, eax
je 0x439018
add esi, dword [ebp - 0x10]
cmp edi, esi
ja 0x438ff5
cmp edi, 0x100000
jbe 0x43902d
push ebx
call fcn.00404054
pop ecx
push ebx
call sub.KERNEL32.dll_SetEndOfFile
push ebx
call sub.KERNEL32.dll_CloseHandle
mov eax, 1
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret