Function at 0x406ae0
Capabilities:
Get disk size
Write file on windows

Disassembly:
push 0xffffffffffffffff
push 0x46b640
mov eax, dword fs:[0]
push eax
sub esp, 0x94
push ebx
push ebp
push esi
push edi
mov eax, dword [0x4854a0]
xor eax, esp
push eax
lea eax, [esp + 0xa8]
mov dword fs:[0], eax
mov ebp, dword [esp + 0xb8]
cmp dword [ebp + 0x30], 0xffffffff
je 0x406f99
cmp dword [ebp + 0x34], 0x40000000
jne 0x406f99
mov eax, dword [ebp]
mov eax, dword [eax + 0xc]
xor ebx, ebx
cmp eax, ebx
jne 0x406cc9
push 0x28
call fcn.0041bf5c
add esp, 4
cmp eax, ebx
je 0x406b5a
mov dword [eax + 0x18], 0xf
mov dword [eax + 0x14], ebx
mov byte [eax + 4], bl
mov edi, eax
jmp 0x406b5c
xor edi, edi
mov esi, dword [esp + 0xbc]
push esi
lea ecx, [esp + 0x90]
mov dword [esp + 0x20], edi
call fcn.00402480
push 0xffffffffffffffff
push ebx
push eax
mov ecx, edi
mov dword [esp + 0xbc], ebx
call fcn.00402f60
mov dword [esp + 0xb0], 0xffffffff
cmp dword [esp + 0xa4], 0x10
jb 0x406bab
mov ecx, dword [esp + 0x90]
push ecx
call fcn.0041bf87
add esp, 4
mov edx, dword [ebp]
mov eax, dword [edx + 0x10]
mov dword [edi + 0x1c], eax
mov eax, dword [esp + 0xc4]
mov dword [edi + 0x24], eax
mov dword [edi + 0x20], eax
mov eax, dword [ebp + 8]
cmp eax, ebx
je 0x406bd0
mov ebx, dword [ebp + 0xc]
sub ebx, eax
sar ebx, 2
push ebx
push esi
mov esi, dword [ebp + 0x140]
call fcn.0040e510
lea ebx, [esp + 0x1c]
lea esi, [ebp + 4]
call fcn.0040e230
push 0
push 0
lea ecx, [esp + 0x2c]
push ecx
push 0
call dword [sym.imp.KERNEL32.dll_GetDiskFreeSpaceExA]
cmp dword [esp + 0x28], 0
mov ebx, dword [esp + 0xc4]
jne 0x406c12
cmp dword [esp + 0x24], ebx
jb 0x406f99
mov edx, dword [edi + 0x1c]
mov eax, dword [ebp + 0x30]
push 0
push 0
push edx
push eax
call dword [sym.imp.KERNEL32.dll_SetFilePointer]
mov esi, ebx
shr esi, 0x11
xor edi, edi
test esi, esi
jle 0x406c84
mov ebx, dword [esp + 0xc0]
mov edx, dword [ebp + 0x30]
push 0
lea ecx, [esp + 0x1c]
push ecx
push 0x20000
push ebx
push edx
call dword [sym.imp.KERNEL32.dll_WriteFile]
test eax, eax
je 0x406f99
cmp dword [esp + 0x18], 0x20000
jne 0x406f99
cmp byte [0x48ac68], 0
jne 0x406f99
add edi, 1
add ebx, 0x20000
cmp edi, esi
jl 0x406c36
mov ebx, dword [esp + 0xc4]
mov ecx, dword [esp + 0xc0]
mov edx, dword [ebp + 0x30]
push 0
shl esi, 0x11
lea eax, [esp + 0x1c]
push eax
mov edi, ebx
sub edi, esi
push edi
add esi, ecx
push esi
push edx
call dword [sym.imp.KERNEL32.dll_WriteFile]
test eax, eax
je 0x406f99
cmp dword [esp + 0x18], edi
jne 0x406f99
mov ebp, dword [ebp]
add dword [ebp + 0x10], ebx
mov eax, 1
jmp 0x406f9b
cmp eax, 1
jne 0x406f99
mov eax, dword [esp + 0xc4]
mov esi, eax
push eax
shr esi, 0x11
call fcn.00417ad0
add esp, 4
push 4
push 0x1000
mov edi, eax
push edi
push ebx
call dword [sym.imp.KERNEL32.dll_VirtualAlloc]
cmp eax, ebx
mov dword [esp + 0x1c], eax
je 0x406f99
mov ecx, dword [esp + 0xc0]
push 0x38
push str.1.2.3
lea edx, [esp + 0x5c]
push 0xffffffffffffffff
push edx
mov dword [esp + 0x84], ebx
mov dword [esp + 0x88], ebx
mov dword [esp + 0x8c], ebx
mov dword [esp + 0x64], ecx
mov dword [esp + 0x68], ebx
mov dword [esp + 0x70], eax
mov dword [esp + 0x74], edi
call fcn.004195e0
add esp, 0x10
xor edi, edi
cmp esi, ebx
jl 0x406d8e
cmp edi, esi
jne 0x406d64
mov ecx, dword [esp + 0xc4]
mov eax, esi
shl eax, 0x11
sub ecx, eax
mov dword [esp + 0x58], ecx
jmp 0x406d6c
mov dword [esp + 0x58], 0x20000
lea edx, [esp + 0x54]
push ebx
push edx
call fcn.00417b90
add esp, 8
cmp byte [0x48ac68], bl
jne 0x406dce
cmp eax, 1
je 0x406d8e
add edi, 1
cmp edi, esi
jle 0x406d4e
lea ecx, [esp + 0x54]
push 4
push ecx
call fcn.00417b90
mov edx, dword [esp + 0x70]
lea eax, [esp + 0x5c]
push eax
mov dword [esp + 0x24], edx
call fcn.00418400
add esp, 0xc
push 0x28
call fcn.0041bf5c
add esp, 4
cmp eax, ebx
je 0x406dde
mov dword [eax + 0x18], 0xf
mov dword [eax + 0x14], ebx
mov byte [eax + 4], bl
mov edi, eax
jmp 0x406de0
mov eax, dword [esp + 0x1c]
push 0x8000
push ebx
push eax
jmp 0x406f93
xor edi, edi
mov esi, dword [esp + 0xbc]
mov eax, esi
mov dword [esp + 0x24], edi
mov dword [esp + 0x50], 0xf
mov dword [esp + 0x4c], ebx
mov byte [esp + 0x3c], bl
lea edx, [eax + 1]
mov cl, byte [eax]
add eax, 1
cmp cl, bl
jne 0x406e00
sub eax, edx
push eax
push esi
lea ecx, [esp + 0x40]
call fcn.00403a90
push 0xffffffffffffffff
push ebx
lea ecx, [esp + 0x40]
push ecx
mov ecx, edi
mov dword [esp + 0xbc], 1
call fcn.00402f60
mov dword [esp + 0xb0], 0xffffffff
cmp dword [esp + 0x50], 0x10
jb 0x406e4f
mov edx, dword [esp + 0x3c]
push edx
call fcn.0041bf87
add esp, 4
mov eax, dword [ebp]
mov ecx, dword [eax + 0x10]
mov edx, dword [esp + 0xc4]
mov eax, dword [esp + 0x18]
mov dword [edi + 0x1c], ecx
mov dword [edi + 0x20], edx
mov dword [edi + 0x24], eax
mov eax, dword [ebp + 8]
cmp eax, ebx
mov dword [esp + 0x50], 0xf
mov dword [esp + 0x4c], ebx
mov byte [esp + 0x3c], bl
je 0x406e88
mov ebx, dword [ebp + 0xc]
sub ebx, eax
sar ebx, 2
push ebx
push esi
mov esi, dword [ebp + 0x140]
call fcn.0040e510
lea ebx, [esp + 0x24]
lea esi, [ebp + 4]
call fcn.0040e230
push 0
push 0
lea ecx, [esp + 0x34]
push ecx
push 0
call dword [sym.imp.KERNEL32.dll_GetDiskFreeSpaceExA]
cmp dword [esp + 0x30], 0
jne 0x406ed4
mov edx, dword [esp + 0x2c]
cmp edx, dword [esp + 0x18]
jae 0x406ed4
mov eax, dword [esp + 0x1c]
push 0x8000
push 0
push eax
jmp 0x406f93
mov ecx, dword [edi + 0x1c]
mov edx, dword [ebp + 0x30]
push 0
push 0
push ecx
push edx
call dword [sym.imp.KERNEL32.dll_SetFilePointer]
mov esi, dword [esp + 0x18]
shr esi, 0x11
xor ebx, ebx
test esi, esi
jle 0x406f32
mov edi, dword [esp + 0x1c]
mov ecx, dword [ebp + 0x30]
push 0
lea eax, [esp + 0x24]
push eax
push 0x20000
push edi
push ecx
call dword [sym.imp.KERNEL32.dll_WriteFile]
test eax, eax
je 0x406ec3
cmp dword [esp + 0x20], 0x20000
jne 0x406ec3
cmp byte [0x48ac68], 0
jne 0x406f7d
add ebx, 1
add edi, 0x20000
cmp ebx, esi
jl 0x406ef7
mov edi, dword [esp + 0x18]
mov ebx, dword [esp + 0x1c]
mov edx, dword [ebp + 0x30]
push 0
shl esi, 0x11
lea ecx, [esp + 0x24]
push ecx
sub edi, esi
push edi
add esi, ebx
push esi
push edx
call dword [sym.imp.KERNEL32.dll_WriteFile]
test eax, eax
je 0x406f8b
cmp dword [esp + 0x20], edi
jne 0x406f8b
push 0x8000
push 0
push ebx
call dword [sym.imp.KERNEL32.dll_VirtualFree]
mov eax, dword [esp + 0x18]
mov ebp, dword [ebp]
add dword [ebp + 0x10], eax
mov eax, 1
jmp 0x406f9b
mov edx, dword [esp + 0x1c]
push 0x8000
push 0
push edx
jmp 0x406f93
push 0x8000
push 0
push ebx
call dword [sym.imp.KERNEL32.dll_VirtualFree]
xor eax, eax
mov ecx, dword [esp + 0xa8]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebp
pop ebx
add esp, 0xa0
ret 0x10