Function at 0x41a8cc
Capabilities:
Write file on windows

Disassembly:
push ebp
mov ebp, esp
push ebx
push edi
push esi
sub esp, 0x72c
mov eax, dword [ebp + 0x18]
mov ecx, dword [ebp + 0x14]
mov edx, dword [ebp + 0x10]
mov esi, dword [ebp + 0xc]
mov edi, dword [ebp + 8]
mov ebx, dword [ebp + 8]
cmp dword [ebp + 0x18], 3
mov dword [ebp - 0x68c], eax
mov dword [ebp - 0x690], ecx
mov dword [ebp - 0x694], edx
mov dword [ebp - 0x698], esi
mov dword [ebp - 0x69c], edi
mov dword [ebp - 0x6a0], ebx
je 0x41a92c
cmp dword [ebp + 0x18], 2
je 0x41a92c
cmp dword [ebp + 0x18], 1
je 0x41a92c
mov dword [ebp - 0x10], 0x10000
jmp 0x41b0c7
cmp dword [ebp + 0x18], 3
jne 0x41aa9c
mov eax, dword [ebp + 0xc]
mov ecx, dword [ebp - 0x6a0]
cmp eax, dword [ecx + 4]
je 0x41aa09
mov eax, dword [ebp - 0x6a0]
cmp dword [eax + 4], 0xffffffff
je 0x41a96a
mov eax, dword [ebp - 0x6a0]
mov ecx, dword [eax]
mov dword [esp], ecx
call fcn.004185c4
mov dword [ebp - 0x6a4], eax
mov eax, dword [ebp - 0x6a0]
mov dword [eax + 4], 0xffffffff
mov ecx, dword [ebp + 0xc]
mov edx, dword [eax]
cmp ecx, dword [edx + 4]
jl 0x41a98d
mov dword [ebp - 0x10], 0x10000
jmp 0x41b0c7
mov eax, dword [ebp + 0xc]
mov ecx, dword [ebp - 0x6a0]
mov edx, dword [ecx]
cmp eax, dword [edx + 0x10]
jge 0x41a9b3
mov eax, dword [ebp - 0x6a0]
mov ecx, dword [eax]
mov dword [esp], ecx
call fcn.004184a4
mov dword [ebp - 0x6a8], eax
jmp 0x41a9b5
mov eax, dword [ebp - 0x6a0]
mov ecx, dword [eax]
mov ecx, dword [ecx + 0x10]
cmp ecx, dword [ebp + 0xc]
jge 0x41a9dd
mov eax, dword [ebp - 0x6a0]
mov ecx, dword [eax]
mov dword [esp], ecx
call fcn.00418d74
mov dword [ebp - 0x6ac], eax
jmp 0x41a9b5
mov eax, dword [ebp - 0x6a0]
mov ecx, dword [eax]
mov edx, dword [eax + 0x23c]
mov dword [esp], ecx
mov dword [esp + 4], edx
call fcn.00419160
mov ecx, dword [ebp + 0xc]
mov edx, dword [ebp - 0x6a0]
mov dword [edx + 4], ecx
mov dword [ebp - 0x6b0], eax
lea eax, [ebp - 0x11]
mov ecx, dword [ebp - 0x6a0]
mov edx, dword [ecx]
mov esi, dword [ebp + 0x10]
mov edi, dword [ebp + 0x14]
mov dword [esp], edx
mov dword [esp + 4], esi
mov dword [esp + 8], edi
mov dword [esp + 0xc], eax
call fcn.0041946c
mov dword [ebp - 0x18], eax
cmp dword [ebp - 0x18], 0
jg 0x41aa5a
mov eax, dword [ebp - 0x6a0]
mov ecx, dword [eax]
mov dword [esp], ecx
call fcn.004185c4
mov ecx, dword [ebp - 0x6a0]
mov dword [ecx + 4], 0xffffffff
mov dword [ebp - 0x6b4], eax
test byte [ebp - 0x11], 1
je 0x41aa6c
mov dword [ebp - 0x10], 0
jmp 0x41b0c7
cmp dword [ebp - 0x18], 0
jle 0x41aa7e
mov dword [ebp - 0x10], 0x600
jmp 0x41b0c7
cmp dword [ebp - 0x18], 0xffffff96
jne 0x41aa90
mov dword [ebp - 0x10], 0x1000
jmp 0x41b0c7
mov dword [ebp - 0x10], 0x5000000
jmp 0x41b0c7
mov eax, dword [ebp - 0x6a0]
cmp dword [eax + 4], 0xffffffff
je 0x41aabe
mov eax, dword [ebp - 0x6a0]
mov ecx, dword [eax]
mov dword [esp], ecx
call fcn.004185c4
mov dword [ebp - 0x6b8], eax
mov eax, dword [ebp - 0x6a0]
mov dword [eax + 4], 0xffffffff
mov ecx, dword [ebp + 0xc]
mov edx, dword [eax]
cmp ecx, dword [edx + 4]
jl 0x41aae1
mov dword [ebp - 0x10], 0x10000
jmp 0x41b0c7
mov eax, dword [ebp + 0xc]
mov ecx, dword [ebp - 0x6a0]
mov edx, dword [ecx]
cmp eax, dword [edx + 0x10]
jge 0x41ab07
mov eax, dword [ebp - 0x6a0]
mov ecx, dword [eax]
mov dword [esp], ecx
call fcn.004184a4
mov dword [ebp - 0x6bc], eax
jmp 0x41ab09
mov eax, dword [ebp - 0x6a0]
mov ecx, dword [eax]
mov ecx, dword [ecx + 0x10]
cmp ecx, dword [ebp + 0xc]
jge 0x41ab31
mov eax, dword [ebp - 0x6a0]
mov ecx, dword [eax]
mov dword [esp], ecx
call fcn.00418d74
mov dword [ebp - 0x6c0], eax
jmp 0x41ab09
lea eax, [ebp - 0x248]
mov ecx, dword [ebp + 0xc]
mov edx, dword [ebp - 0x6a0]
mov dword [esp], edx
mov dword [esp + 4], ecx
mov dword [esp + 8], eax
call fcn.00419be8
mov ecx, dword [ebp - 0x3c]
and ecx, 0x10
cmp ecx, 0
mov dword [ebp - 0x6c4], eax
je 0x41ac46
cmp dword [ebp + 0x18], 1
jne 0x41ab77
mov dword [ebp - 0x10], 0
jmp 0x41b0c7
mov al, 1
mov ecx, dword [ebp + 0x10]
mov dword [ebp - 0x24c], ecx
mov ecx, dword [ebp - 0x24c]
movzx ecx, word [ecx]
cmp ecx, 0x2f
mov byte [ebp - 0x6c5], al
je 0x41abe6
mov al, 1
mov ecx, dword [ebp - 0x24c]
movzx ecx, word [ecx]
cmp ecx, 0x5c
mov byte [ebp - 0x6c5], al
je 0x41abe6
xor eax, eax
mov cl, al
mov eax, dword [ebp - 0x24c]
movzx eax, word [eax]
cmp eax, 0
mov byte [ebp - 0x6c6], cl
je 0x41abda
mov eax, dword [ebp - 0x24c]
movzx eax, word [eax + 2]
cmp eax, 0x3a
sete cl
mov byte [ebp - 0x6c6], cl
mov al, byte [ebp - 0x6c6]
mov byte [ebp - 0x6c5], al
mov al, byte [ebp - 0x6c5]
and al, 1
mov byte [ebp - 0x24d], al
test byte [ebp - 0x24d], 1
je 0x41ac1d
xor eax, eax
mov ecx, dword [ebp - 0x24c]
mov dword [esp], 0
mov dword [esp + 4], ecx
mov dword [ebp - 0x6cc], eax
call fcn.0041a728
jmp 0x41ac3a
mov eax, dword [ebp - 0x6a0]
add eax, 0x244
mov ecx, dword [ebp - 0x24c]
mov dword [esp], eax
mov dword [esp + 4], ecx
call fcn.0041a728
mov dword [ebp - 0x10], 0
jmp 0x41b0c7
cmp dword [ebp + 0x18], 1
jne 0x41ac5a
mov eax, dword [ebp + 0x10]
mov dword [ebp - 0x254], eax
jmp 0x41aeab
mov eax, dword [ebp + 0x10]
mov dword [ebp - 0x258], eax
mov eax, dword [ebp - 0x258]
mov dword [ebp - 0x25c], eax
mov eax, dword [ebp - 0x25c]
mov dword [ebp - 0x260], eax
mov eax, dword [ebp - 0x260]
movzx eax, word [eax]
cmp eax, 0
je 0x41acc5
mov eax, dword [ebp - 0x260]
movzx eax, word [eax]
cmp eax, 0x2f
je 0x41aca5
mov eax, dword [ebp - 0x260]
movzx eax, word [eax]
cmp eax, 0x5c
jne 0x41acb4
mov eax, dword [ebp - 0x260]
add eax, 2
mov dword [ebp - 0x25c], eax
mov eax, dword [ebp - 0x260]
add eax, 2
mov dword [ebp - 0x260], eax
jmp 0x41ac7b
lea eax, [ebp - 0x468]
mov ecx, dword [ebp - 0x258]
mov dword [esp], eax
mov dword [esp + 4], ecx
call fcn.005669f4
mov ecx, dword [ebp - 0x25c]
cmp ecx, dword [ebp - 0x258]
mov dword [ebp - 0x6d0], eax
jne 0x41acfc
mov word [ebp - 0x468], 0
jmp 0x41ad17
mov eax, dword [ebp - 0x25c]
mov ecx, dword [ebp - 0x258]
sub eax, ecx
sar eax, 1
mov word [ebp + eax*2 - 0x468], 0
mov al, 1
movzx ecx, word [ebp - 0x468]
cmp ecx, 0x2f
mov byte [ebp - 0x6d1], al
je 0x41ad74
mov al, 1
movzx ecx, word [ebp - 0x468]
cmp ecx, 0x5c
mov byte [ebp - 0x6d1], al
je 0x41ad74
xor eax, eax
mov cl, al
movzx eax, word [ebp - 0x468]
cmp eax, 0
mov byte [ebp - 0x6d2], cl
je 0x41ad68
movzx eax, word [ebp - 0x466]
cmp eax, 0x3a
sete cl
mov byte [ebp - 0x6d2], cl
mov al, byte [ebp - 0x6d2]
mov byte [ebp - 0x6d1], al
mov al, byte [ebp - 0x6d1]
and al, 1
mov byte [ebp - 0x671], al
test byte [ebp - 0x671], 1
je 0x41ade5
lea eax, str._s_s
lea ecx, [ebp - 0x468]
lea edx, [ebp - 0x670]
mov esi, dword [ebp - 0x25c]
mov edi, esp
mov dword [edi + 0xc], esi
mov dword [edi + 8], ecx
mov dword [edi], edx
mov dword [edi + 4], str._s_s
mov dword [ebp - 0x6d8], eax
call sub.USER32.DLL_wsprintfW
xor ecx, ecx
lea edx, [ebp - 0x468]
mov dword [esp], 0
mov dword [esp + 4], edx
mov dword [ebp - 0x6dc], eax
mov dword [ebp - 0x6e0], ecx
call fcn.0041a728
jmp 0x41ae4c
lea eax, str._s_s_s
lea ecx, [ebp - 0x468]
lea edx, [ebp - 0x670]
mov esi, dword [ebp - 0x6a0]
add esi, 0x244
mov edi, dword [ebp - 0x25c]
mov ebx, esp
mov dword [ebx + 0x10], edi
mov dword [ebx + 0xc], ecx
mov dword [ebx + 8], esi
mov dword [ebx], edx
mov dword [ebx + 4], str._s_s_s
mov dword [ebp - 0x6e4], eax
call sub.USER32.DLL_wsprintfW
lea ecx, [ebp - 0x468]
mov edx, dword [ebp - 0x6a0]
add edx, 0x244
mov dword [esp], edx
mov dword [esp + 4], ecx
mov dword [ebp - 0x6e8], eax
call fcn.0041a728
mov eax, 0x40000000
xor ecx, ecx
mov edx, 2
lea esi, [ebp - 0x670]
mov edi, dword [ebp - 0x3c]
mov ebx, esp
mov dword [ebx + 0x14], edi
mov dword [ebx], esi
mov dword [ebx + 0x18], 0
mov dword [ebx + 0x10], 2
mov dword [ebx + 0xc], 0
mov dword [ebx + 8], 0
mov dword [ebx + 4], 0x40000000
mov dword [ebp - 0x6ec], eax
mov dword [ebp - 0x6f0], ecx
mov dword [ebp - 0x6f4], edx
call sub.KERNEL32.DLL_CreateFileW
sub esp, 0x1c
mov dword [ebp - 0x254], eax
mov eax, 0xffffffff
cmp dword [ebp - 0x254], eax
jne 0x41aec4
mov dword [ebp - 0x10], pe_nt_image_headers32
jmp 0x41b0c7
mov eax, dword [ebp - 0x6a0]
mov ecx, dword [eax]
mov edx, dword [eax + 0x23c]
mov dword [esp], ecx
mov dword [esp + 4], edx
call fcn.00419160
mov ecx, dword [ebp - 0x6a0]
cmp dword [ecx + 0x240], 0
mov dword [ebp - 0x6f8], eax
jne 0x41af16
mov eax, 0x4000
mov dword [esp], 0x4000
mov dword [ebp - 0x6fc], eax
call fcn.0055e258
mov ecx, dword [ebp - 0x6a0]
mov dword [ecx + 0x240], eax
mov dword [ebp - 0x678], 0
cmp dword [ebp - 0x678], 0
jne 0x41b033
mov eax, 0x4000
lea ecx, [ebp - 0x679]
mov edx, dword [ebp - 0x6a0]
mov esi, dword [edx]
mov edi, dword [edx + 0x240]
mov dword [esp], esi
mov dword [esp + 4], edi
mov dword [esp + 8], 0x4000
mov dword [esp + 0xc], ecx
mov dword [ebp - 0x700], eax
call fcn.0041946c
mov dword [ebp - 0x680], eax
cmp dword [ebp - 0x680], 0xffffff96
jne 0x41af82
mov dword [ebp - 0x678], 0x1000
jmp 0x41b033
cmp dword [ebp - 0x680], 0
jge 0x41af9a
mov dword [ebp - 0x678], 0x5000000
jmp 0x41b033
cmp dword [ebp - 0x680], 0
jle 0x41b00e
lea eax, [ebp - 0x684]
xor ecx, ecx
mov edx, dword [ebp - 0x254]
mov esi, dword [ebp - 0x6a0]
mov edi, dword [esi + 0x240]
mov ebx, dword [ebp - 0x680]
mov esi, esp
mov dword [ebp - 0x704], eax
lea eax, [ebp - 0x684]
mov dword [esi + 0xc], eax
mov dword [esi + 8], ebx
mov dword [esi + 4], edi
mov dword [esi], edx
mov dword [esi + 0x10], 0
mov dword [ebp - 0x708], ecx
call sub.KERNEL32.DLL_WriteFile
sub esp, 0x14
mov dword [ebp - 0x688], eax
cmp dword [ebp - 0x688], 0
jne 0x41b00c
mov dword [ebp - 0x678], 0x400
jmp 0x41b033
jmp 0x41b00e
test byte [ebp - 0x679], 1
je 0x41b019
jmp 0x41b033
cmp dword [ebp - 0x680], 0
jne 0x41b02e
mov dword [ebp - 0x678], 0x5000000
jmp 0x41b033
jmp 0x41af20
cmp dword [ebp - 0x678], 0
jne 0x41b078
lea eax, [ebp - 0x248]
mov ecx, dword [ebp - 0x254]
mov edx, eax
add edx, 0x218
mov esi, eax
add esi, 0x210
add eax, 0x220
mov edi, esp
mov dword [edi + 0xc], eax
mov dword [edi + 8], esi
mov dword [edi + 4], edx
mov dword [edi], ecx
call sub.KERNEL32.DLL_SetFileTime
sub esp, 0x10
mov dword [ebp - 0x70c], eax
cmp dword [ebp + 0x18], 1
je 0x41b096
mov eax, dword [ebp - 0x254]
mov ecx, esp
mov dword [ecx], eax
call sub.KERNEL32.DLL_CloseHandle
sub esp, 4
mov dword [ebp - 0x710], eax
mov eax, dword [ebp - 0x6a0]
mov ecx, dword [eax]
mov dword [esp], ecx
call fcn.004185c4
cmp dword [ebp - 0x678], 0
mov dword [ebp - 0x714], eax
je 0x41b0c0
mov eax, dword [ebp - 0x678]
mov dword [ebp - 0x10], eax
jmp 0x41b0c7
mov dword [ebp - 0x10], 0
mov eax, dword [ebp - 0x10]
add esp, 0x72c
pop esi
pop edi
pop ebx
pop ebp
ret