Function at 0x45d250
Capabilities:
Write file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x58
mov eax, dword [0x5854b4]
xor eax, ebp
mov dword [ebp - 4], eax
push esi
mov dword [ebp - 0x40], ecx
mov eax, dword [ebp - 0x40]
cmp dword [eax + 0x10], 0
jne 0x45d277
mov eax, 1
jmp 0x45d5f9
push 0
push 0
push 0
mov ecx, dword [ebp - 0x40]
mov edx, dword [ecx + 4]
push edx
call dword [sym.imp.KERNEL32.dll_SetFilePointer]
mov eax, dword [ebp - 0x40]
mov ecx, dword [eax + 4]
push ecx
call dword [sym.imp.KERNEL32.dll_SetEndOfFile]
mov dword [ebp - 0x4c], 0
mov dword [ebp - 0x44], 0
mov dword [ebp - 0x50], 0
mov dword [ebp - 0x48], 0
jmp 0x45d2be
mov edx, dword [ebp - 0x48]
add edx, 1
mov dword [ebp - 0x48], edx
mov ecx, dword [ebp - 0x40]
add ecx, 0x1c
call fcn.0045df20
cmp dword [ebp - 0x48], eax
jae 0x45d4b0
xor eax, eax
mov dword [ebp - 0x3c], eax
mov dword [ebp - 0x38], eax
mov dword [ebp - 0x34], eax
mov dword [ebp - 0x30], eax
mov dword [ebp - 0x2c], eax
mov dword [ebp - 0x28], eax
mov dword [ebp - 0x24], eax
mov word [ebp - 0x20], ax
mov dword [ebp - 0x3c], 0x4034b50
lea ecx, [ebp - 0x3c]
push ecx
mov edx, dword [ebp - 0x48]
push edx
mov ecx, dword [ebp - 0x40]
add ecx, 0x1c
call fcn.0045cb20
mov eax, dword [eax]
push eax
mov ecx, dword [ebp - 0x40]
call fcn.0045cbd0
test eax, eax
jne 0x45d31d
xor eax, eax
jmp 0x45d5f9
push 0x104
push 0
mov ecx, dword [ebp - 0x48]
push ecx
mov ecx, dword [ebp - 0x40]
add ecx, 0x1c
call fcn.0045cb20
add eax, 0x20c
push eax
call fcn.00511800
add esp, 0xc
push 0
push 0
push 0x104
mov edx, dword [ebp - 0x48]
push edx
mov ecx, dword [ebp - 0x40]
add ecx, 0x1c
call fcn.0045cb20
add eax, 0x20c
push eax
push 0xffffffffffffffff
mov eax, dword [ebp - 0x48]
push eax
mov ecx, dword [ebp - 0x40]
add ecx, 0x1c
call fcn.0045cb20
add eax, 4
push eax
push 0
push 0
call dword [sym.imp.KERNEL32.dll_WideCharToMultiByte]
mov dword [ebp - 0x58], eax
cmp dword [ebp - 0x58], 0
jne 0x45d38e
xor eax, eax
jmp 0x45d5f9
mov ecx, dword [ebp - 0x58]
sub ecx, 1
mov word [ebp - 0x22], cx
mov esi, dword [ebp - 0x58]
sub esi, 1
mov edx, dword [ebp - 0x48]
push edx
mov ecx, dword [ebp - 0x40]
add ecx, 0x1c
call fcn.0045cb20
mov eax, dword [eax]
mov word [eax + 0x1c], si
mov ecx, dword [ebp - 0x48]
push ecx
mov ecx, dword [ebp - 0x40]
add ecx, 0x1c
call fcn.0045cb20
mov edx, dword [eax]
mov eax, dword [ebp - 0x44]
mov dword [edx + 0x2a], eax
push 0
lea ecx, [ebp - 0x50]
push ecx
push 0x1e
lea edx, [ebp - 0x3c]
push edx
mov eax, dword [ebp - 0x40]
mov ecx, dword [eax + 4]
push ecx
call dword [sym.imp.KERNEL32.dll_WriteFile]
mov dword [ebp - 0x4c], eax
cmp dword [ebp - 0x4c], 0
jne 0x45d3f3
xor eax, eax
jmp 0x45d5f9
mov edx, dword [ebp - 0x44]
add edx, dword [ebp - 0x50]
mov dword [ebp - 0x44], edx
push 0
lea eax, [ebp - 0x50]
push eax
movzx ecx, word [ebp - 0x22]
push ecx
mov edx, dword [ebp - 0x48]
push edx
mov ecx, dword [ebp - 0x40]
add ecx, 0x1c
call fcn.0045cb20
add eax, 0x20c
push eax
mov eax, dword [ebp - 0x40]
mov ecx, dword [eax + 4]
push ecx
call dword [sym.imp.KERNEL32.dll_WriteFile]
mov dword [ebp - 0x4c], eax
cmp dword [ebp - 0x4c], 0
jne 0x45d439
xor eax, eax
jmp 0x45d5f9
mov edx, dword [ebp - 0x44]
add edx, dword [ebp - 0x50]
mov dword [ebp - 0x44], edx
cmp dword [ebp - 0x2a], 0
je 0x45d460
mov eax, dword [ebp - 0x48]
push eax
mov ecx, dword [ebp - 0x40]
add ecx, 0x1c
call fcn.0045cb20
cmp dword [eax + 0x310], 0
jne 0x45d465
jmp 0x45d2b5
push 0
lea ecx, [ebp - 0x50]
push ecx
mov edx, dword [ebp - 0x2a]
push edx
mov eax, dword [ebp - 0x48]
push eax
mov ecx, dword [ebp - 0x40]
add ecx, 0x1c
call fcn.0045cb20
mov ecx, dword [eax + 0x310]
push ecx
mov edx, dword [ebp - 0x40]
mov eax, dword [edx + 4]
push eax
call dword [sym.imp.KERNEL32.dll_WriteFile]
mov dword [ebp - 0x4c], eax
cmp dword [ebp - 0x4c], 0
jne 0x45d4a2
xor eax, eax
jmp 0x45d5f9
mov ecx, dword [ebp - 0x44]
add ecx, dword [ebp - 0x50]
mov dword [ebp - 0x44], ecx
jmp 0x45d2b5
xor edx, edx
mov dword [ebp - 0x1c], edx
mov dword [ebp - 0x18], edx
mov dword [ebp - 0x14], edx
mov dword [ebp - 0x10], edx
mov dword [ebp - 0xc], edx
mov word [ebp - 8], dx
mov dword [ebp - 0x1c], 0x6054b50
xor eax, eax
mov word [ebp - 0x18], ax
xor ecx, ecx
mov word [ebp - 0x16], cx
mov ecx, dword [ebp - 0x40]
add ecx, 0x1c
call fcn.0045df20
mov word [ebp - 0x14], ax
mov ecx, dword [ebp - 0x40]
add ecx, 0x1c
call fcn.0045df20
mov word [ebp - 0x12], ax
mov edx, dword [ebp - 0x44]
mov dword [ebp - 0xc], edx
xor eax, eax
mov word [ebp - 8], ax
mov dword [ebp - 0x44], 0
mov dword [ebp - 0x54], 0
jmp 0x45d51b
mov ecx, dword [ebp - 0x54]
add ecx, 1
mov dword [ebp - 0x54], ecx
mov ecx, dword [ebp - 0x40]
add ecx, 0x1c
call fcn.0045df20
cmp dword [ebp - 0x54], eax
jae 0x45d5c8
push 0
lea edx, [ebp - 0x50]
push edx
push 0x2e
mov eax, dword [ebp - 0x54]
push eax
mov ecx, dword [ebp - 0x40]
add ecx, 0x1c
call fcn.0045cb20
mov ecx, dword [eax]
push ecx
mov edx, dword [ebp - 0x40]
mov eax, dword [edx + 4]
push eax
call dword [sym.imp.KERNEL32.dll_WriteFile]
mov dword [ebp - 0x4c], eax
cmp dword [ebp - 0x4c], 0
jne 0x45d566
xor eax, eax
jmp 0x45d5f9
mov ecx, dword [ebp - 0x44]
add ecx, dword [ebp - 0x50]
mov dword [ebp - 0x44], ecx
push 0
lea edx, [ebp - 0x50]
push edx
mov eax, dword [ebp - 0x54]
push eax
mov ecx, dword [ebp - 0x40]
add ecx, 0x1c
call fcn.0045cb20
mov ecx, dword [eax]
movzx edx, word [ecx + 0x1c]
push edx
mov eax, dword [ebp - 0x54]
push eax
mov ecx, dword [ebp - 0x40]
add ecx, 0x1c
call fcn.0045cb20
add eax, 0x20c
push eax
mov ecx, dword [ebp - 0x40]
mov edx, dword [ecx + 4]
push edx
call dword [sym.imp.KERNEL32.dll_WriteFile]
mov dword [ebp - 0x4c], eax
cmp dword [ebp - 0x4c], 0
jne 0x45d5ba
xor eax, eax
jmp 0x45d5f9
mov eax, dword [ebp - 0x44]
add eax, dword [ebp - 0x50]
mov dword [ebp - 0x44], eax
jmp 0x45d512
mov ecx, dword [ebp - 0x44]
mov dword [ebp - 0x10], ecx
push 0
lea edx, [ebp - 0x50]
push edx
push 0x16
lea eax, [ebp - 0x1c]
push eax
mov ecx, dword [ebp - 0x40]
mov edx, dword [ecx + 4]
push edx
call dword [sym.imp.KERNEL32.dll_WriteFile]
mov dword [ebp - 0x4c], eax
cmp dword [ebp - 0x4c], 0
jne 0x45d5f4
xor eax, eax
jmp 0x45d5f9
mov eax, 1
pop esi
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.004d77de
mov esp, ebp
pop ebp
ret