Function at 0x41ec07
Capabilities:
Write file on windows

Disassembly:
push 0x50
mov eax, 0x46f8fd
call fcn.004337ef
mov esi, ecx
mov ecx, dword [esi]
and dword [ebp - 4], 0
push str.Extracting_icon_resources.
push 2
call fcn.004035b3
push 0xe
push 0x84
lea eax, [ebp - 0x20]
mov ecx, esi
push eax
call fcn.0041ee7c
test al, al
je 0x41ec44
mov bl, 1
jmp 0x41edf4
push dword [ebp - 0x14]
call fcn.0044f10b
push dword [ebp - 0x14]
mov dword [ebp - 0x54], eax
push dword [ebp - 0x18]
push eax
call fcn.0044c940
add esp, 0x10
lea eax, [ebp + 8]
cmp dword [ebp + 0x1c], 8
cmovae eax, dword [ebp + 8]
push 0
push 0x80
push 2
push 0
push 0
push 0xc0000000
push eax
call dword [sym.imp.KERNEL32.DLL_CreateFileW]
mov dword [ebp - 0x58], eax
lea ecx, [ebp - 0x48]
lea eax, [ebp - 0x58]
mov dword [ebp - 0x50], eax
lea eax, [ebp - 0x54]
mov dword [ebp - 0x4c], eax
lea eax, [ebp - 0x50]
push eax
call fcn.0041eb36
cmp dword [ebp - 0x58], 0xffffffff
mov byte [ebp - 4], 1
jne 0x41ecd5
cmp dword [ebp + 0x1c], 8
lea eax, [ebp + 8]
mov ecx, dword [esi]
cmovae eax, dword [ebp + 8]
mov dword [ebp - 0x4c], eax
lea eax, [ebp - 0x4c]
push eax
push str.Failed_to_create_icon_file_in_path___.
push 4
call fcn.00403720
push dword [ebp - 0x54]
call fcn.0044f106
pop ecx
jmp 0x41ee75
mov eax, dword [ebp - 0x54]
movzx eax, word [eax + 4]
push eax
push dword [ebp - 0x58]
call fcn.0041eeed
pop ecx
pop ecx
test al, al
je 0x41ecfe
mov ecx, dword [esi]
push str.Failed_to_write_ICO_header.
push 4
call fcn.004035b3
jmp 0x41ee75
mov ecx, dword [ebp - 0x54]
and dword [ebp - 0x4c], 0
movzx eax, word [ecx + 4]
mov edi, eax
shl edi, 4
add edi, 6
test eax, eax
je 0x41ed8f
xor ebx, ebx
mov al, byte [ebx + ecx + 6]
mov byte [ebp - 0x20], al
mov al, byte [ebx + ecx + 7]
mov byte [ebp - 0x1f], al
mov al, byte [ebx + ecx + 8]
mov byte [ebp - 0x1e], al
mov al, byte [ebx + ecx + 9]
mov byte [ebp - 0x1d], al
mov ax, word [ebx + ecx + 0xa]
mov word [ebp - 0x1c], ax
mov ax, word [ebx + ecx + 0xc]
mov word [ebp - 0x1a], ax
mov eax, dword [ebx + ecx + 0xe]
mov dword [ebp - 0x18], eax
lea eax, [ebp - 0x5c]
push 0
push eax
push 0x10
lea eax, [ebp - 0x20]
mov dword [ebp - 0x14], edi
add edi, dword [ebx + ecx + 0xe]
push eax
push dword [ebp - 0x58]
call dword [sym.imp.KERNEL32.DLL_WriteFile]
test eax, eax
je 0x41ee23
cmp dword [ebp - 0x5c], 0x10
jne 0x41ee0a
mov ecx, dword [ebp - 0x54]
add ebx, 0xe
mov edx, dword [ebp - 0x4c]
inc edx
mov dword [ebp - 0x4c], edx
movzx eax, word [ecx + 4]
cmp edx, eax
jl 0x41ed17
xor eax, eax
xor edi, edi
cmp ax, word [ecx + 4]
jae 0x41edea
xor ebx, ebx
movzx eax, word [ebx + ecx + 0x12]
mov ecx, esi
push 3
push eax
lea eax, [ebp - 0x20]
push eax
call fcn.0041ee7c
test al, al
jne 0x41ee75
push 0
lea eax, [ebp - 0x5c]
push eax
push dword [ebp - 0x14]
push dword [ebp - 0x18]
push dword [ebp - 0x58]
call dword [sym.imp.KERNEL32.DLL_WriteFile]
test eax, eax
je 0x41ee55
mov eax, dword [ebp - 0x14]
cmp dword [ebp - 0x5c], eax
jne 0x41ee3c
mov ecx, dword [ebp - 0x54]
inc edi
add ebx, 0xe
movzx eax, word [ecx + 4]
cmp edi, eax
jl 0x41ed9b
xor bl, bl
lea ecx, [ebp - 0x48]
call fcn.00407433
push 0
push 1
lea ecx, [ebp + 8]
call fcn.0042a3d6
mov al, bl
call fcn.00433799
ret 0x18
cmp dword [ebp + 0x1c], 8
lea eax, [ebp + 8]
cmovae eax, dword [ebp + 8]
mov dword [ebp - 0x4c], eax
lea eax, [ebp - 0x4c]
push eax
push str.Bytes_written_to_file____does_not_match_expected_size.
jmp 0x41ee6c
cmp dword [ebp + 0x1c], 8
lea eax, [ebp + 8]
cmovae eax, dword [ebp + 8]
mov dword [ebp - 0x4c], eax
lea eax, [ebp - 0x4c]
push eax
push str.Couldnt_write_to_file___._Error_code_.
jmp 0x41ee6c
cmp dword [ebp + 0x1c], 8
lea eax, [ebp + 8]
cmovae eax, dword [ebp + 8]
mov dword [ebp - 0x4c], eax
lea eax, [ebp - 0x4c]
push eax
push str.Icon_data_written_to_file____does_not_match_expected_size.
jmp 0x41ee6c
cmp dword [ebp + 0x1c], 8
lea eax, [ebp + 8]
cmovae eax, dword [ebp + 8]
mov dword [ebp - 0x4c], eax
lea eax, [ebp - 0x4c]
push eax
push str.Could_not_write_icon_data_to_file___
mov ecx, dword [esi]
push 4
call fcn.00403720
mov bl, 1
jmp 0x41edec