Function at 0x1015b091
Capabilities:
Extract resource via kernel32 functions

Disassembly:
sub esp, 0xc
and dword [esp], 0
and dword [esp + 4], 0
push ebx
mov ebx, dword [esp + 0x18]
push ebp
push edi
mov edi, ebx
imul edi, edi, 0x38
push edi
call dword [sym.imp.msvcr100.dll_malloc]
mov ebp, dword [esp + 0x28]
pop ecx
mov dword [ebp], eax
test eax, eax
jne 0x1015b0c6
mov eax, 0x8007000e
jmp 0x1015b2b2
push esi
push edi
push dword [esp + 0x24]
push eax
call sub.msvcr100.dll_memcpy
add esp, 0xc
jmp 0x1015b283
mov esi, dword [ebp]
sub edi, 0x38
add esi, edi
lea eax, [esi + 4]
dec ebx
test byte [eax], 1
mov dword [esp + 0x24], esi
mov dword [esp + 0x18], eax
jne 0x1015b283
cmp dword [0x10244334], 0
jne 0x1015b15d
push 5
push 0x3ee
push dword [0x10241074]
call dword [sym.imp.kernel32.dll_FindResourceA]
push eax
push dword [0x10241074]
call dword [sym.imp.kernel32.dll_LoadResource]
push eax
call dword [sym.imp.kernel32.dll_LockResource]
push eax
mov dword [esp + 0x2c], eax
call fcn.1015692e
push 0x10244338
mov esi, eax
push 0x10244334
push esi
call fcn.10166e7e
push esi
call dword [sym.imp.GDI32.dll_DeleteObject]
mov eax, dword [esp + 0x28]
test eax, eax
je 0x1015b159
push eax
call dword [sym.imp.kernel32.dll_FreeResource]
mov esi, dword [esp + 0x24]
push 5
push dword [esi + 0xc]
push dword [esi + 8]
call dword [sym.imp.kernel32.dll_FindResourceA]
push eax
push dword [esi + 8]
mov dword [esp + 0x30], eax
call dword [sym.imp.kernel32.dll_LoadResource]
push eax
call dword [sym.imp.kernel32.dll_LockResource]
mov esi, eax
mov dword [esp + 0x20], esi
test esi, esi
je 0x1015b283
cmp dword [esp + 0x28], 0
je 0x1015b283
mov eax, dword [esp + 0x10]
test eax, eax
jne 0x1015b1c8
push esi
call fcn.1015692e
mov esi, eax
lea eax, [esp + 0x14]
push eax
lea eax, [esp + 0x14]
push eax
push esi
call fcn.10166e7e
push esi
call dword [sym.imp.GDI32.dll_DeleteObject]
mov eax, dword [esp + 0x10]
mov esi, dword [esp + 0x20]
mov edx, dword [0x10244334]
mov ecx, dword [0x10244338]
cmp eax, edx
jne 0x1015b1e2
cmp dword [esp + 0x14], ecx
je 0x1015b2a8
test edx, edx
je 0x1015b2a8
test ecx, ecx
je 0x1015b2a8
test eax, eax
je 0x1015b2a8
cmp dword [esp + 0x14], 0
je 0x1015b2a8
push dword [esp + 0x28]
mov eax, dword [esp + 0x28]
push dword [eax + 8]
call dword [sym.imp.kernel32.dll_SizeofResource]
push eax
mov dword [esp + 0x2c], eax
call dword [sym.imp.msvcr100.dll_malloc]
pop ecx
mov dword [esp + 0x20], eax
test eax, eax
je 0x1015b28c
push dword [esp + 0x28]
push esi
push eax
call sub.msvcr100.dll_memcpy
add esp, 0xc
push esi
call dword [sym.imp.kernel32.dll_FreeResource]
mov eax, dword [esp + 0x18]
or dword [eax], 1
mov eax, dword [esp + 0x24]
mov esi, dword [esp + 0x20]
mov dword [eax + 0xc], esi
push dword [0x10244334]
movsx eax, word [esi + 0xe]
push dword [esp + 0x14]
push eax
call dword [sym.imp.kernel32.dll_MulDiv]
mov word [esi + 0xe], ax
push dword [0x10244338]
movsx eax, word [esi + 0x10]
push dword [esp + 0x18]
push eax
call dword [sym.imp.kernel32.dll_MulDiv]
mov word [esi + 0x10], ax
test ebx, ebx
je 0x1015b2af
jmp 0x1015b0da
push esi
call dword [sym.imp.kernel32.dll_FreeResource]
push dword [ebp]
call dword [sym.imp.msvcr100.dll_free]
and dword [ebp], 0
pop ecx
mov eax, 0x8007000e
jmp 0x1015b2b1
push esi
call dword [sym.imp.kernel32.dll_FreeResource]
xor eax, eax
pop esi
pop edi
pop ebp
pop ebx
add esp, 0xc
ret 0xc