Function at 0x435dd0
Capabilities:
Write file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x10
push ebx
mov ebx, dword [ebp + 0x10]
mov eax, dword [ebx + 0x30]
sub eax, dword [ebx + 0x2c]
push esi
push edi
mov dword [ebp - 4], ecx
test eax, 0xfffffffc
jne 0x435e07
mov ecx, dword [ebx + 0x20]
sub ecx, dword [ebx + 0x1c]
test ecx, 0xfffffffc
jne 0x435e07
mov edx, dword [ebx + 0xc]
cmp word [edx], 0
je 0x436072
mov eax, dword [ebx + 0x20]
sub eax, dword [ebx + 0x1c]
mov ecx, dword [ebx + 0x18]
mov edx, dword [ebx + 0x14]
sar eax, 2
lea ecx, [ecx + eax*4]
mov eax, dword [ebx + 8]
lea eax, [edx + eax*2 + 0x10]
add eax, ecx
add eax, dword [ebp + 0xc]
xor ecx, ecx
mov edx, 2
mul edx
seto cl
neg ecx
or ecx, eax
push ecx
call fcn.00497a23
mov ecx, dword [ebp + 0xc]
mov esi, eax
add esp, 4
xor eax, eax
test ecx, ecx
je 0x435e66
mov eax, 9
movzx edx, ax
mov eax, edx
shl edx, 0x10
or eax, edx
shr ecx, 1
mov edi, esi
rep stosd dword es:[edi], eax
adc ecx, ecx
rep stosw word es:[edi], ax
mov eax, dword [ebp + 0xc]
mov dword [esi + eax*2], 0x3c
mov eax, dword [ebx]
push eax
push esi
call dword [sym.imp.KERNEL32.dll_lstrcatW]
mov ecx, dword [ebx + 0x20]
sub ecx, dword [ebx + 0x1c]
xor edi, edi
sar ecx, 2
test ecx, ecx
je 0x435ee3
jmp 0x435e90
push 0x4d302c
push esi
call dword [sym.imp.KERNEL32.dll_lstrcatW]
mov edx, dword [ebx + 0x1c]
mov eax, dword [edx + edi*4]
mov ecx, dword [eax]
push ecx
push esi
call dword [sym.imp.KERNEL32.dll_lstrcatW]
push 0x4d5430
push esi
call dword [sym.imp.KERNEL32.dll_lstrcatW]
mov edx, dword [ebx + 0x1c]
mov eax, dword [edx + edi*4]
mov ecx, dword [eax + 0xc]
push ecx
push esi
call dword [sym.imp.KERNEL32.dll_lstrcatW]
push 0x4d5438
push esi
call dword [sym.imp.KERNEL32.dll_lstrcatW]
mov edx, dword [ebx + 0x20]
sub edx, dword [ebx + 0x1c]
inc edi
sar edx, 2
cmp edi, edx
jb 0x435e90
mov eax, dword [ebx + 0x30]
sub eax, dword [ebx + 0x2c]
test eax, 0xfffffffc
je 0x435f00
mov ecx, dword [ebx + 0xc]
cmp word [ecx], 0
jne 0x435f10
push 0x4d543c
jmp 0x435f15
mov edx, dword [ebx + 0xc]
cmp word [edx], 0
jne 0x435f10
push 0x4d5448
jmp 0x435f15
push 0x4d5444
push esi
call dword [sym.imp.KERNEL32.dll_lstrcatW]
mov edi, dword [sym.imp.KERNEL32.dll_lstrlenW]
push esi
call edi
mov ecx, dword [ebp + 8]
mov ecx, dword [ecx]
xor edx, edx
add eax, eax
mov dword [ebp - 8], edx
cmp ecx, 0xffffffff
je 0x435f47
push edx
mov dword [ebp + 0x10], edx
lea edx, [ebp + 0x10]
push edx
push eax
push esi
push ecx
call dword [sym.imp.KERNEL32.dll_WriteFile]
mov eax, dword [ebx + 0xc]
cmp word [eax], 0
je 0x435f9d
push eax
push esi
call dword [sym.imp.KERNEL32.dll_lstrcpyW]
mov eax, dword [ebx + 0x30]
sub eax, dword [ebx + 0x2c]
test eax, 0xfffffffc
je 0x435f71
push 0x4d5454
push esi
call dword [sym.imp.KERNEL32.dll_lstrcatW]
push esi
call edi
mov ecx, dword [ebp + 8]
mov ecx, dword [ecx]
add eax, eax
mov dword [ebp - 8], 0
cmp ecx, 0xffffffff
je 0x435f9d
push 0
lea edx, [ebp + 0x10]
push edx
push eax
push esi
push ecx
mov dword [ebp + 0x10], 0
call dword [sym.imp.KERNEL32.dll_WriteFile]
mov eax, dword [ebx + 0x2c]
mov ecx, dword [ebx + 0x30]
sub ecx, eax
sar ecx, 2
xor edi, edi
test ecx, ecx
je 0x435fd3
mov edx, dword [eax + edi*4]
mov eax, dword [ebp + 0xc]
mov ecx, dword [ebp - 4]
push edx
inc eax
push eax
mov eax, dword [ebp + 8]
push eax
call fcn.00435dd0
mov eax, dword [ebx + 0x2c]
mov ecx, dword [ebx + 0x30]
sub ecx, eax
inc edi
sar ecx, 2
cmp edi, ecx
jb 0x435fae
mov edx, dword [ebx + 0x30]
sub edx, dword [ebx + 0x2c]
xor eax, eax
test edx, 0xfffffffc
je 0x436007
mov ecx, dword [ebp + 0xc]
test ecx, ecx
je 0x436007
mov eax, 9
movzx edx, ax
mov eax, edx
shl edx, 0x10
or eax, edx
shr ecx, 1
mov edi, esi
rep stosd dword es:[edi], eax
adc ecx, ecx
rep stosw word es:[edi], ax
mov eax, dword [ebp + 0xc]
mov ecx, dword [ebx + 0xc]
cmp word [ecx], 0
jne 0x43601e
mov edx, dword [ebx + 0x30]
sub edx, dword [ebx + 0x2c]
test edx, 0xfffffffc
je 0x436069
mov edi, dword [sym.imp.KERNEL32.dll_lstrcatW]
mov dword [esi + eax*2], 0x2f003c
xor ecx, ecx
mov word [esi + eax*2 + 4], cx
mov edx, dword [ebx]
push edx
push esi
call edi
push 0x4d543c
push esi
call edi
push esi
call dword [sym.imp.KERNEL32.dll_lstrlenW]
mov ecx, dword [ebp + 8]
mov ecx, dword [ecx]
xor edx, edx
add eax, eax
mov dword [ebp - 8], edx
cmp ecx, 0xffffffff
je 0x436069
push edx
mov dword [ebp + 0xc], edx
lea edx, [ebp + 0xc]
push edx
push eax
push esi
push ecx
call dword [sym.imp.KERNEL32.dll_WriteFile]
push esi
call fcn.004996ce
add esp, 4
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 0xc