Function at 0x40d460
Capabilities:
Write file on windows

Disassembly:
push ebx
mov ebx, esp
sub esp, 8
and esp, 0xfffffff8
add esp, 4
push ebp
mov ebp, dword [ebx + 4]
mov dword [esp + 4], ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x45aef6
mov eax, dword fs:[0]
push eax
push ebx
sub esp, 0x9c
mov eax, dword [0x477010]
xor eax, ebp
mov dword [ebp - 0x14], eax
push esi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov esi, ecx
mov eax, dword [esi + 8]
mov ecx, dword [ebx + 8]
test eax, eax
je 0x40d783
cmp eax, 0xffffffff
je 0x40d783
push 0
lea edx, [ebp - 0x18]
mov dword [ebp - 0x18], 0
push edx
push dword [ebx + 0xc]
push ecx
push eax
call dword [sym.imp.KERNEL32.dll_WriteFile]
test eax, eax
jne 0x40d7a4
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov edx, eax
lea ecx, [ebp - 0xa8]
call fcn.0041eab0
mov dword [ebp - 4], 0
lea ecx, [ebp - 0x60]
push 9
xor eax, eax
mov dword [ebp - 0x50], 0
push str._failed:
mov dword [ebp - 0x4c], 7
mov word [ebp - 0x60], ax
call fcn.0040bcc0
mov byte [ebp - 4], 1
lea ecx, [ebp - 0x48]
push 9
xor eax, eax
mov dword [ebp - 0x38], 0
push str._ERROR_:
mov dword [ebp - 0x34], 7
mov word [ebp - 0x48], ax
call fcn.0040bcc0
push 0x46bff4
lea ecx, [ebp - 0x48]
mov byte [ebp - 4], 2
call fcn.0040aa60
mov dword [ebp - 0x20], 0
xor ecx, ecx
mov dword [ebp - 0x1c], 0
movups xmm0, xmmword [eax]
movups xmmword [ebp - 0x30], xmm0
movq xmm0, qword [eax + 0x10]
movq qword [ebp - 0x20], xmm0
mov dword [eax + 0x10], 0
mov dword [eax + 0x14], 7
mov word [eax], cx
lea eax, [ebp - 0x60]
mov byte [ebp - 4], 3
push eax
lea edx, [ebp - 0x30]
lea ecx, [ebp - 0x90]
call fcn.0040a950
add esp, 4
lea ecx, [ebp - 0xa8]
mov byte [ebp - 4], 4
push ecx
mov edx, eax
lea ecx, [ebp - 0x78]
call fcn.0040a950
add esp, 4
push eax
mov byte [ebp - 4], 5
call fcn.00401b50
mov edx, dword [ebp - 0x64]
cmp edx, 8
jb 0x40d5f5
mov ecx, dword [ebp - 0x78]
lea edx, [edx*2 + 2]
mov eax, ecx
cmp edx, 0x1000
jb 0x40d5eb
mov ecx, dword [ecx - 4]
add edx, 0x23
sub eax, ecx
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x40d7b7
push edx
push ecx
call fcn.00420a59
add esp, 8
mov edx, dword [ebp - 0x7c]
xor eax, eax
mov dword [ebp - 0x68], 0
mov dword [ebp - 0x64], 7
mov word [ebp - 0x78], ax
cmp edx, 8
jb 0x40d646
mov ecx, dword [ebp - 0x90]
lea edx, [edx*2 + 2]
mov eax, ecx
cmp edx, 0x1000
jb 0x40d63c
mov ecx, dword [ecx - 4]
add edx, 0x23
sub eax, ecx
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x40d7bc
push edx
push ecx
call fcn.00420a59
add esp, 8
mov edx, dword [ebp - 0x1c]
xor eax, eax
mov dword [ebp - 0x80], 0
mov dword [ebp - 0x7c], 7
mov word [ebp - 0x90], ax
cmp edx, 8
jb 0x40d697
mov ecx, dword [ebp - 0x30]
lea edx, [edx*2 + 2]
mov eax, ecx
cmp edx, 0x1000
jb 0x40d68d
mov ecx, dword [ecx - 4]
add edx, 0x23
sub eax, ecx
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x40d7c1
push edx
push ecx
call fcn.00420a59
add esp, 8
mov edx, dword [ebp - 0x34]
xor eax, eax
mov dword [ebp - 0x20], 0
mov dword [ebp - 0x1c], 7
mov word [ebp - 0x30], ax
cmp edx, 8
jb 0x40d6e5
mov ecx, dword [ebp - 0x48]
lea edx, [edx*2 + 2]
mov eax, ecx
cmp edx, 0x1000
jb 0x40d6db
mov ecx, dword [ecx - 4]
add edx, 0x23
sub eax, ecx
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x40d7c6
push edx
push ecx
call fcn.00420a59
add esp, 8
mov edx, dword [ebp - 0x4c]
xor eax, eax
mov dword [ebp - 0x38], 0
mov dword [ebp - 0x34], 7
mov word [ebp - 0x48], ax
cmp edx, 8
jb 0x40d733
mov ecx, dword [ebp - 0x60]
lea edx, [edx*2 + 2]
mov eax, ecx
cmp edx, 0x1000
jb 0x40d729
mov ecx, dword [ecx - 4]
add edx, 0x23
sub eax, ecx
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x40d7cb
push edx
push ecx
call fcn.00420a59
add esp, 8
mov edx, dword [ebp - 0x94]
xor eax, eax
mov dword [ebp - 0x50], 0
mov dword [ebp - 0x4c], 7
mov word [ebp - 0x60], ax
cmp edx, 8
jb 0x40d783
mov ecx, dword [ebp - 0xa8]
lea edx, [edx*2 + 2]
mov eax, ecx
cmp edx, 0x1000
jb 0x40d779
mov ecx, dword [ecx - 4]
add edx, 0x23
sub eax, ecx
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x40d7d0
push edx
push ecx
call fcn.00420a59
add esp, 8
xor al, al
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop esi
mov ecx, dword [ebp - 0x14]
xor ecx, ebp
call fcn.00420a25
mov esp, ebp
pop ebp
mov esp, ebx
pop ebx
ret 8
mov eax, dword [ebp - 0x18]
cmp eax, dword [ebx + 0xc]
jne 0x40d783
add dword [esi + 0x28], eax
mov al, 1
adc dword [esi + 0x2c], 0
jmp 0x40d785
call fcn.0042848b
call fcn.0042848b
call fcn.0042848b
call fcn.0042848b
call fcn.0042848b
call fcn.0042848b
int3