Function at 0x410600
Capabilities:
Write file on windows

Disassembly:
push ebp
mov ebp, esp
push edi
push esi
push ebx
sub esp, 0x2bc
mov dword [esp], 0xfffffff4
lea esi, [ebp - 0x298]
call sub.KERNEL32.dll_GetStdHandle
sub esp, 4
mov edi, eax
mov dword [esp + 8], 0x208
mov dword [esp + 4], esi
mov dword [esp], 0
call sub.KERNEL32.dll_GetModuleFileNameW
sub esp, 0xc
cmp edi, 0xffffffff
mov ebx, eax
je 0x410798
test eax, eax
jle 0x4107c0
mov dword [esp + 4], esi
mov dword [esp], 3
call sub.cygwin1.dll_cygwin_create_path
mov dword [esp + 4], pe_nt_image_headers32
mov esi, eax
lea eax, [ebp + 0xc]
mov dword [esp + 0xc], eax
mov eax, dword [ebp + 8]
mov dword [esp + 8], eax
lea eax, [ebp - 0x90]
mov dword [ebp - 0x2ac], eax
mov dword [esp], eax
call sub.cygwin1.dll_vsnprintf
test esi, esi
mov byte [ebp - 0x11], 0
mov dword [ebp - 0x2a0], eax
mov dword [ebp - 0x2a4], eax
je 0x4107f4
lea ebx, [ebp - 0x10]
mov dword [esp + 0x10], 0
mov dword [esp + 0xc], ebx
mov dword [esp + 8], 0x18
mov dword [esp + 4], str.Cygwin_runtime_failure:
mov dword [esp], edi
call sub.KERNEL32.dll_WriteFile
sub esp, 0x14
mov dword [esp], esi
call sub.cygwin1.dll_strlen
mov dword [esp + 0x10], 0
mov dword [esp + 0xc], ebx
mov dword [esp + 4], esi
mov dword [esp], edi
mov dword [esp + 8], eax
call sub.KERNEL32.dll_WriteFile
sub esp, 0x14
mov dword [esp + 0x10], 0
mov dword [esp + 0xc], ebx
mov dword [esp + 8], 2
mov dword [esp + 4], 0x412b2c
mov dword [esp], edi
call sub.KERNEL32.dll_WriteFile
mov eax, dword [ebp - 0x2a0]
sub esp, 0x14
mov dword [esp + 8], eax
mov eax, dword [ebp - 0x2ac]
mov dword [esp + 0x10], 0
mov dword [esp + 0xc], ebx
mov dword [esp], edi
mov dword [esp + 4], eax
call sub.KERNEL32.dll_WriteFile
sub esp, 0x14
mov dword [esp], esi
call sub.cygwin1.dll_free
mov dword [esp + 0x10], 0
mov dword [esp + 0xc], ebx
mov dword [esp + 8], 1
mov dword [esp + 4], 0x412b2f
mov dword [esp], edi
call sub.KERNEL32.dll_WriteFile
sub esp, 0x14
mov dword [esp + 8], 1
mov dword [esp + 4], 0xe0000269
mov dword [esp], 0x25
call sub.cygwin1.dll_cygwin_internal
call sub.cygwin1.dll_abort
mov dword [esp + 8], 1
mov dword [esp + 4], 0xe0000269
mov dword [esp], 0x25
call sub.cygwin1.dll_cygwin_internal
test ebx, ebx
jg 0x410875
lea esi, [esi]
lea eax, [ebp + 0xc]
mov dword [esp + 0xc], eax
mov eax, dword [ebp + 8]
mov dword [esp + 4], pe_nt_image_headers32
mov dword [esp + 8], eax
lea eax, [ebp - 0x90]
mov dword [ebp - 0x2ac], eax
mov dword [esp], eax
call sub.cygwin1.dll_vsnprintf
mov byte [ebp - 0x11], 0
mov dword [ebp - 0x2a4], eax
lea ebx, [ebp - 0x10]
mov dword [esp + 0x10], 0
mov dword [esp + 0xc], ebx
mov dword [esp + 8], 0x18
mov dword [esp + 4], str.Cygwin_runtime_failure:
mov dword [esp], edi
call sub.KERNEL32.dll_WriteFile
sub esp, 0x14
mov dword [esp + 0x10], 0
mov dword [esp + 0xc], ebx
mov dword [esp + 8], 0x12
mov dword [esp + 4], str._unknown_module_:
mov dword [esp], edi
call sub.KERNEL32.dll_WriteFile
mov eax, dword [ebp - 0x2a4]
sub esp, 0x14
mov dword [esp + 8], eax
mov eax, dword [ebp - 0x2ac]
mov dword [esp + 0x10], 0
mov dword [esp + 0xc], ebx
mov dword [esp], edi
mov dword [esp + 4], eax
call sub.KERNEL32.dll_WriteFile
sub esp, 0x14
jmp 0x410750
mov dword [esp + 4], esi
mov dword [esp], 3
call sub.cygwin1.dll_cygwin_create_path
mov dword [esp + 4], pe_nt_image_headers32
mov esi, eax
lea eax, [ebp + 0xc]
mov dword [esp + 0xc], eax
mov eax, dword [ebp + 8]
mov dword [esp + 8], eax
lea eax, [ebp - 0x90]
mov dword [ebp - 0x2ac], eax
mov dword [esp], eax
call sub.cygwin1.dll_vsnprintf
test esi, esi
mov byte [ebp - 0x11], 0
mov dword [ebp - 0x2a8], eax
mov dword [ebp - 0x2a4], eax
je 0x4107f4
lea ebx, [ebp - 0x10]
mov dword [esp + 0xc], ebx
mov dword [esp + 0x10], 0
mov dword [esp + 8], 0x18
mov dword [esp + 4], str.Cygwin_runtime_failure:
mov dword [esp], 0xffffffff
call sub.KERNEL32.dll_WriteFile
sub esp, 0x14
mov dword [esp], esi
call sub.cygwin1.dll_strlen
mov dword [esp + 0xc], ebx
mov dword [esp + 4], esi
mov dword [esp + 0x10], 0
mov dword [esp], 0xffffffff
mov dword [esp + 8], eax
call sub.KERNEL32.dll_WriteFile
sub esp, 0x14
mov dword [esp + 0xc], ebx
mov dword [esp + 0x10], 0
mov dword [esp + 8], 2
mov dword [esp + 4], 0x412b2c
mov dword [esp], 0xffffffff
call sub.KERNEL32.dll_WriteFile
mov eax, dword [ebp - 0x2a8]
sub esp, 0x14
mov dword [esp + 8], eax
mov eax, dword [ebp - 0x2ac]
mov dword [esp + 0xc], ebx
mov dword [esp + 0x10], 0
mov dword [esp], 0xffffffff
mov dword [esp + 4], eax
call sub.KERNEL32.dll_WriteFile
sub esp, 0x14
mov dword [esp], esi
call sub.cygwin1.dll_free
jmp 0x410750