Function at 0x404ce0
Capabilities:
Extract resource via kernel32 functions
Terminate process

Disassembly:
push edi
lea edi, [esp + 8]
and esp, 0xfffffff8
push dword [edi - 4]
push ebp
mov ebp, esp
push edi
push esi
mov esi, eax
push ebx
sub esp, 0x50
movzx ebx, word [ecx + 4]
mov dword [ebp - 0x24], edx
mov dword [ebp - 0x30], ecx
mov dword [ebp - 0x20], 0
test bx, bx
je 0x4051f7
mov eax, ecx
movzx ecx, bx
xor edx, edx
imul ecx, ecx, 0xe
add eax, 0xe
add ecx, eax
nop
add edx, dword [eax]
add eax, 0xe
cmp ecx, eax
jne 0x404d20
mov dword [esp], edx
mov edi, dword [sym.imp.ucrtbase.dll_malloc]
call edi
mov dword [ebp - 0x48], eax
test eax, eax
je 0x40531c
movzx ebx, bx
shl ebx, 4
mov dword [esp], ebx
call edi
mov dword [ebp - 0x44], eax
test eax, eax
je 0x40531c
lea eax, [ebp - 0x20]
mov dword [esp + 4], 1
mov dword [esp + 8], eax
mov dword [esp], 0
call dword [sym.imp.ole32.dll_CreateStreamOnHGlobal]
sub esp, 0xc
test eax, eax
js 0x4050e8
test esi, esi
je 0x404ec0
mov eax, dword [ebp - 0x30]
cmp word [eax + 4], 0
je 0x404fe8
mov eax, dword [ebp - 0x30]
mov dword [ebp - 0x3c], 0
mov dword [ebp - 0x40], 0
mov dword [ebp - 0x28], 0
lea edi, [eax + 6]
mov eax, esi
mov esi, edi
mov edi, eax
lea esi, cs:[esi]
mov edx, dword [edi + 8]
movzx ebx, word [edx + 2]
lea eax, [edx + 8]
test ebx, ebx
je 0x404e00
mov edx, dword [edi + 4]
mov ecx, dword [edi]
mov dword [ebp - 0x34], edx
mov dword [ebp - 0x38], ecx
add ecx, edx
mov dword [ebp - 0x24], ecx
xor ecx, ecx
mov dword [ebp - 0x2c], eax
add eax, 0xc
cmp eax, dword [ebp - 0x24]
ja 0x405020
movzx edx, word [esi + 0xc]
or dx, 0x8000
cmp word [eax - 6], dx
je 0x405060
inc ecx
cmp ecx, ebx
jne 0x404dd8
nop
mov eax, dword [ebp - 0x30]
inc dword [ebp - 0x28]
add esi, 0xe
mov ebx, dword [ebp - 0x28]
movzx eax, word [eax + 4]
cmp ebx, eax
jl 0x404db8
mov eax, dword [ebp - 0x40]
test eax, eax
je 0x404fe8
mov eax, dword [ebp - 0x20]
mov esi, dword [ebp - 0x40]
mov dword [ebp - 0x16], 0x10000
lea ecx, [ebp - 0x16]
lea ebx, [ebp - 0x1c]
mov word [ebp - 0x12], si
mov edx, dword [eax]
mov dword [esp + 0xc], ebx
mov dword [esp + 8], 6
mov dword [esp + 4], ecx
mov dword [esp], eax
call dword [edx + 0x10]
sub esp, 0x10
mov edi, eax
test eax, eax
js 0x4051e5
cmp dword [ebp - 0x1c], 6
je 0x40512f
test byte [section..data], 2
je 0x404ff5
mov dword [esp + 0x10], edi
mov dword [esp + 0xc], str.error_0x_08lX_writing_icon_stream_n
mov dword [esp + 8], str.add_module_icons_to_stream
mov dword [esp + 4], 0x40c000
mov dword [esp], 1
call sym._wine_dbg_log.constprop.0
mov eax, dword [ebp - 0x48]
mov ebx, dword [sym.imp.ucrtbase.dll_free]
mov dword [esp], eax
call ebx
mov eax, dword [ebp - 0x44]
mov dword [esp], eax
call ebx
test edi, edi
jns 0x40500b
jmp 0x40510b
mov edx, dword [ebp - 0x24]
test edx, edx
je 0x404fe8
mov eax, dword [ebp - 0x30]
cmp word [eax + 4], 0
je 0x404fe8
mov dword [ebp - 0x3c], 0
lea ebx, [eax + 6]
xor edi, edi
mov dword [ebp - 0x40], 0
lea esi, [esi]
mov dword [esp + 8], 3
movzx eax, word [ebx + 0xc]
mov dword [esp + 4], eax
mov eax, dword [ebp - 0x24]
mov dword [esp], eax
call dword [sym.imp.kernel32.dll_FindResourceW]
sub esp, 0xc
mov esi, eax
test eax, eax
je 0x404fc3
mov dword [esp + 4], eax
mov eax, dword [ebp - 0x24]
mov dword [esp], eax
call dword [sym.imp.kernel32.dll_LoadResource]
sub esp, 8
mov edx, eax
test eax, eax
je 0x404fc3
mov eax, dword [esi + 4]
mov esi, dword [ebx + 8]
mov dword [ebp - 0x28], edx
mov dword [esp], edx
mov dword [ebp - 0x2c], eax
call dword [sym.imp.kernel32.dll_LockResource]
mov edx, dword [ebp - 0x28]
sub esp, 4
test eax, eax
je 0x404fb7
mov ecx, dword [ebp - 0x2c]
movzx edx, byte [ebx]
cmp ecx, esi
cmovbe esi, ecx
mov ecx, dword [ebp - 0x40]
inc dword [ebp - 0x40]
shl ecx, 4
add ecx, dword [ebp - 0x44]
mov byte [ecx], dl
movzx edx, byte [ebx + 1]
mov dword [ecx + 8], esi
mov byte [ecx + 1], dl
movzx edx, byte [ebx + 2]
mov byte [ecx + 2], dl
movzx edx, byte [ebx + 3]
mov byte [ecx + 3], dl
movzx edx, word [ebx + 4]
mov word [ecx + 4], dx
movzx edx, word [ebx + 6]
mov word [ecx + 6], dx
mov edx, dword [ebp - 0x3c]
mov dword [ecx + 0xc], edx
mov ecx, dword [ebp - 0x48]
mov dword [esp + 8], esi
add ecx, edx
mov dword [esp + 4], eax
mov dword [esp], ecx
call sym._memcpy
add dword [ebp - 0x3c], esi
mov edx, dword [ebp - 0x28]
mov dword [esp], edx
call dword [sym.imp.kernel32.dll_FreeResource]
sub esp, 4
mov eax, dword [ebp - 0x30]
inc edi
add ebx, 0xe
movzx eax, word [eax + 4]
cmp edi, eax
jl 0x404ef0
mov eax, dword [ebp - 0x40]
test eax, eax
jne 0x404e1f
lea esi, [esi]
test byte [section..data], 2
jne 0x4051fe
mov eax, dword [ebp - 0x48]
mov ebx, dword [sym.imp.ucrtbase.dll_free]
mov dword [esp], eax
call ebx
mov eax, dword [ebp - 0x44]
mov dword [esp], eax
call ebx
mov eax, dword [ebp - 0x20]
lea esp, [ebp - 0xc]
pop ebx
pop esi
pop edi
pop ebp
lea esp, [edi - 8]
pop edi
ret
test byte [section..data], 4
je 0x404e00
mov dword [esp + 0xc], str.file_too_small_for_icon_NE_NAMEINFO_n
mov dword [esp + 8], str.populate_module16_icons
mov dword [esp + 4], 0x40c000
mov dword [esp], 2
call sym._wine_dbg_log.constprop.0
jmp 0x404e00
mov eax, dword [ebp - 0x2c]
movzx ecx, word [edi + 0xc]
mov ebx, dword [esi + 8]
movzx eax, word [eax]
shl eax, cl
add eax, ebx
cmp dword [ebp - 0x34], eax
jb 0x40529f
mov eax, dword [ebp - 0x40]
movzx edx, byte [esi]
inc dword [ebp - 0x40]
shl eax, 4
add eax, dword [ebp - 0x44]
mov byte [eax], dl
movzx edx, byte [esi + 1]
mov dword [eax + 8], ebx
mov byte [eax + 1], dl
movzx edx, byte [esi + 2]
mov byte [eax + 2], dl
movzx edx, byte [esi + 3]
mov byte [eax + 3], dl
movzx edx, word [esi + 4]
mov word [eax + 4], dx
movzx edx, word [esi + 6]
mov word [eax + 6], dx
mov edx, dword [ebp - 0x3c]
mov dword [eax + 0xc], edx
mov eax, dword [ebp - 0x48]
add eax, edx
mov edx, dword [ebp - 0x2c]
movzx edx, word [edx]
mov dword [esp + 8], ebx
mov dword [esp], eax
shl edx, cl
add edx, dword [ebp - 0x38]
mov dword [esp + 4], edx
call sym._memcpy
add dword [ebp - 0x3c], ebx
jmp 0x404e00
test byte [section..data], 2
jne 0x4051bc
mov eax, dword [ebp - 0x48]
mov ebx, dword [sym.imp.ucrtbase.dll_free]
mov dword [esp], eax
call ebx
mov eax, dword [ebp - 0x44]
mov dword [esp], eax
call ebx
mov eax, dword [ebp - 0x20]
test eax, eax
je 0x40500e
mov edx, dword [eax]
mov dword [esp], eax
call dword [edx + 8]
xor eax, eax
sub esp, 4
lea esp, [ebp - 0xc]
pop ebx
pop esi
pop edi
pop ebp
lea esp, [edi - 8]
pop edi
ret
mov edx, dword [ebp - 0x44]
mov edi, esi
shl esi, 4
lea ecx, [esi + 6]
mov eax, edx
add edx, esi
test edi, edi
jle 0x405152
lea esi, [esi]
add dword [eax + 0xc], ecx
add eax, 0x10
cmp edx, eax
jne 0x405148
mov eax, dword [ebp - 0x20]
mov edi, dword [ebp - 0x44]
mov edx, dword [eax]
mov dword [esp + 4], edi
mov dword [esp + 0xc], ebx
mov dword [esp + 8], esi
mov dword [esp], eax
call dword [edx + 0x10]
sub esp, 0x10
mov edi, eax
test eax, eax
js 0x4052d5
cmp dword [ebp - 0x1c], esi
je 0x405227
test byte [section..data], 2
je 0x404ff5
mov dword [esp + 0x10], edi
mov dword [esp + 0xc], str.error_0x_08lX_writing_icon_dir_entries_to_stream_n
mov dword [esp + 8], str.add_module_icons_to_stream
mov dword [esp + 4], 0x40c000
mov dword [esp], 1
call sym._wine_dbg_log.constprop.0
jmp 0x404e9a
mov dword [esp + 0xc], str.error_creating_icon_stream_n
mov dword [esp + 8], str.add_module_icons_to_stream
mov dword [esp + 4], 0x40c000
mov dword [esp], 1
call sym._wine_dbg_log.constprop.0
jmp 0x4050f5
test byte [section..data], 2
je 0x4050f5
jmp 0x404e72
xor edx, edx
jmp 0x404d29
mov dword [esp + 0xc], str.no_valid_icon_entries_n
mov dword [esp + 8], str.add_module_icons_to_stream
mov dword [esp + 4], 0x40c000
mov dword [esp], 1
call sym._wine_dbg_log.constprop.0
jmp 0x404ff5
mov eax, dword [ebp - 0x20]
mov edi, dword [ebp - 0x48]
mov esi, dword [ebp - 0x3c]
mov edx, dword [eax]
mov dword [esp + 4], edi
mov dword [esp + 0xc], ebx
mov dword [esp + 8], esi
mov dword [esp], eax
call dword [edx + 0x10]
sub esp, 0x10
mov edi, eax
test eax, eax
js 0x405290
cmp dword [ebp - 0x1c], esi
je 0x4052e7
test byte [section..data], 2
je 0x404ff5
mov dword [esp + 0x10], edi
mov dword [esp + 0xc], str.error_0x_08lX_writing_icon_images_to_stream_n
mov dword [esp + 8], str.add_module_icons_to_stream
mov dword [esp + 4], 0x40c000
mov dword [esp], 1
call sym._wine_dbg_log.constprop.0
jmp 0x404e9a
test byte [section..data], 2
je 0x4050f5
jmp 0x405263
test byte [section..data], 4
je 0x404e14
mov dword [esp + 0xc], str.file_too_small_for_icon_contents_n
mov dword [esp + 8], str.populate_module16_icons
mov dword [esp + 4], 0x40c000
mov dword [esp], 2
call sym._wine_dbg_log.constprop.0
jmp 0x404e14
test byte [section..data], 2
je 0x4050f5
jmp 0x40518f
mov eax, dword [ebp - 0x20]
mov edx, dword [eax]
mov dword [esp + 0x10], 0
mov dword [esp + 0xc], 0
mov dword [esp + 4], 0
mov dword [esp + 8], 0
mov dword [esp], eax
call dword [edx + 0x14]
sub esp, 0x14
mov edi, eax
jmp 0x404e9a
test byte [section..data], 2
jne 0x405332
mov dword [esp], 1
call dword [sym.imp.kernel32.dll_ExitProcess]
mov dword [esp + 0xc], str.out_of_memory_n
mov dword [esp + 8], str.xmalloc
mov dword [esp + 4], 0x40c000
mov dword [esp], 1
call sym._wine_dbg_log.constprop.0
jmp 0x405325