Function at 0x4157e0
Capabilities:
Write file on windows

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff8
sub esp, 0x43c
mov eax, dword [0x44a2f0]
xor eax, esp
mov dword [esp + 0x438], eax
push ebx
mov ebx, ecx
push esi
push edi
lea edi, [ebx + 8]
push edi
call fcn.00415af0
add esp, 4
lea eax, [esp + 0x10]
lea esi, [ebx + 0xc]
mov ecx, esi
push eax
call fcn.0040941d
mov eax, dword [0x44ccf4]
test eax, eax
je 0x415849
lea ecx, [esp + 0x10]
push ecx
push dword [ebx + 0xa0]
push dword [ebx + 0xa8]
push dword [ebx + 0xa4]
push dword [ebx]
call eax
add esp, 0x14
test al, al
jne 0x415943
cmp dword [ebx], 2
jl 0x415889
cmp dword [esp + 0x24], 0x10
lea edi, [esp + 0x10]
mov esi, dword [esp + 0x20]
cmovae edi, dword [esp + 0x10]
call fcn.004232c9
add eax, 0x40
push eax
push 1
push esi
push edi
call fcn.00423dd6
call fcn.004232c9
add eax, 0x40
push eax
call fcn.0042457a
add esp, 0x14
lea esi, [ebx + 0xc]
lea edi, [ebx + 8]
call fcn.00415670
test al, al
je 0x4158b8
cmp dword [esp + 0x24], 0x10
lea ecx, [esp + 0xc]
push 0
push ecx
push dword [esp + 0x28]
lea eax, [esp + 0x1c]
cmovae eax, dword [esp + 0x1c]
push eax
push dword [0x44ccfc]
call dword [sym.imp.KERNEL32.dll_WriteFile]
cmp dword [ebx], 3
jne 0x415943
mov ecx, 0x400
lea eax, [esp + 0x10]
cmp dword [esp + 0x20], ecx
cmovb ecx, dword [esp + 0x20]
cmp dword [esp + 0x24], 0x10
cmovae eax, dword [esp + 0x10]
test ecx, ecx
je 0x4158f0
push ecx
push eax
lea eax, [esp + 0x48]
push eax
call fcn.00422a50
add esp, 0xc
lea eax, [esp + 0x40]
push eax
call fcn.004182b0
add esp, 4
cmp dword [0x44ccf8], 0
je 0x415935
lea eax, [esp + 0x28]
mov ecx, esi
push eax
call fcn.0040941d
lea eax, [esp + 0x28]
push eax
call dword [0x44ccf8]
add esp, 4
cmp dword [esp + 0x3c], 0x10
jb 0x415943
push dword [esp + 0x28]
call fcn.0041e393
add esp, 4
jmp 0x415943
cmp byte [0x44cd20], 0
jne 0x415a47
int3
cmp dword [esp + 0x24], 0x10
jb 0x415956
push dword [esp + 0x10]
call fcn.0041e393
add esp, 4
push dword [ebx + 0xac]
call dword [sym.imp.KERNEL32.dll_SetLastError]
mov eax, dword [edi]
lea esi, [edi + 0x50]
mov eax, dword [eax + 4]
mov dword [eax + esi - 0x50], 0x443a44
mov eax, dword [esi - 0x50]
mov ecx, dword [eax + 4]
lea eax, [ecx - 0x50]
mov dword [ecx + esi - 0x54], eax
test byte [esi - 0x10], 1
mov dword [esi - 0x4c], 0x443a48
je 0x415999
mov eax, dword [esi - 0x40]
push dword [eax]
call fcn.0041e393
add esp, 4
mov eax, dword [esi - 0x40]
mov dword [eax], 0
mov eax, dword [esi - 0x30]
mov dword [eax], 0
mov eax, dword [esi - 0x20]
mov dword [eax], 0
mov eax, dword [esi - 0x3c]
mov dword [eax], 0
mov eax, dword [esi - 0x2c]
mov dword [eax], 0
mov eax, dword [esi - 0x1c]
mov dword [eax], 0
and dword [esi - 0x10], 0xfffffffe
mov edi, dword [esi - 0x18]
mov dword [esi - 0x14], 0
mov dword [esi - 0x4c], 0x4439b8
test edi, edi
je 0x415a08
mov ecx, dword [edi]
test ecx, ecx
je 0x4159ff
mov eax, dword [ecx]
call dword [eax + 8]
test eax, eax
je 0x4159ff
mov edx, dword [eax]
mov ecx, eax
push 1
call dword [edx]
push edi
call fcn.0041e393
add esp, 4
mov eax, dword [esi - 0x50]
push esi
mov eax, dword [eax + 4]
mov dword [eax + esi - 0x50], 0x443b04
mov eax, dword [esi - 0x50]
mov ecx, dword [eax + 4]
lea eax, [ecx - 8]
mov dword [ecx + esi - 0x54], eax
mov dword [esi], 0x443b00
call fcn.0041ddbb
mov ecx, dword [esp + 0x448]
add esp, 4
pop edi
pop esi
pop ebx
xor ecx, esp
call fcn.0041e398
mov esp, ebp
pop ebp
ret
push 1
call fcn.00425113
int3