Function at 0x45ee41
Capabilities:
Extract resource via kernel32 functions
Get file size
Read file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x348
push ebx
mov ebx, dword [sym.imp.msvcrt.dll_free]
push esi
push edi
mov esi, ecx
xor edi, edi
mov dword [ebp - 0x14], esi
test edx, edx
jne 0x45efec
push dword [0x4ad238]
lea ecx, [ebp - 0x28]
push dword [0x4ad234]
call fcn.0044f480
mov eax, dword [0x4ad248]
test eax, eax
jne 0x45ef21
test esi, esi
je 0x45ee90
push esi
lea ecx, [ebp - 0x28]
call fcn.0044f4c2
mov esi, dword [ebp - 0x28]
push 0
push 0x80
push 3
push 0
push 1
push 0x80000000
push esi
call dword [sym.imp.KERNEL32.dll_CreateFileW]
mov dword [ebp - 0x10], eax
cmp eax, 0xffffffff
jne 0x45eec5
test esi, esi
je 0x45f059
push esi
call ebx
pop ecx
jmp 0x45f059
push 0
push eax
call dword [sym.imp.KERNEL32.dll_GetFileSize]
mov ebx, eax
test ebx, ebx
jne 0x45eee5
test esi, esi
je 0x45f059
push esi
call dword [sym.imp.msvcrt.dll_free]
jmp 0x45eebf
and dword [ebp - 0x1c], edi
push ebx
call dword [sym.imp.msvcrt.dll_void____cdecl_operator_new___unsigned_int_]
pop ecx
push 0
mov edi, eax
lea eax, [ebp - 0x1c]
push eax
push ebx
push edi
push dword [ebp - 0x10]
call dword [sym.imp.KERNEL32.dll_ReadFile]
push dword [ebp - 0x10]
call dword [sym.imp.KERNEL32.dll_CloseHandle]
cmp dword [ebp - 0x1c], ebx
je 0x45efde
push edi
call dword [sym.imp.msvcrt.dll_void___cdecl_operator_delete___void__]
pop ecx
xor edi, edi
jmp 0x45eed4
push eax
push dword [0x4ad244]
lea ecx, [ebp - 0x28]
call fcn.0044f4e0
cmp byte [0x4ac174], 0
mov esi, dword [ebp - 0x28]
je 0x45ef43
mov eax, dword [0x4ad1ac]
jmp 0x45ef4a
mov ecx, esi
call fcn.0044adb6
mov dword [ebp - 0x10], eax
test eax, eax
je 0x45eeb4
mov edx, dword [ebp - 0x14]
lea ecx, [ebp - 0x344]
push ecx
lea ecx, [ebp - 0x18]
push ecx
push 1
mov ecx, eax
call fcn.0044ae48
add esp, 0xc
test eax, eax
jne 0x45eeb4
mov ebx, dword [ebp - 0x118]
test ebx, ebx
je 0x45eed4
push ebx
call dword [sym.imp.msvcrt.dll_void____cdecl_operator_new___unsigned_int_]
mov edx, dword [ebp - 0x18]
mov edi, eax
mov ecx, dword [ebp - 0x10]
push ebx
push edi
call fcn.0044ae7d
add esp, 0xc
test eax, eax
je 0x45efcd
cmp eax, 0x600
je 0x45efcd
push edi
call dword [sym.imp.msvcrt.dll_void___cdecl_operator_delete___void__]
xor edi, edi
cmp byte [0x4ac174], 0
pop ecx
jne 0x45eed4
mov ecx, dword [ebp - 0x10]
call fcn.0044aeb0
jmp 0x45eed4
cmp byte [0x4ac174], 0
jne 0x45efde
mov ecx, dword [ebp - 0x10]
call fcn.0044aeb0
test esi, esi
je 0x45f055
push esi
call dword [sym.imp.msvcrt.dll_free]
pop ecx
jmp 0x45f055
push edx
push esi
call fcn.0045695d
push eax
call dword [sym.imp.KERNEL32.dll_FindResourceW]
mov esi, eax
test esi, esi
je 0x45f059
push esi
call fcn.0045695d
push eax
call dword [sym.imp.KERNEL32.dll_LoadResource]
mov dword [ebp - 0x18], eax
push esi
test eax, eax
jne 0x45f01d
call dword [sym.imp.KERNEL32.dll_FreeResource]
jmp 0x45f059
call fcn.0045695d
push eax
call dword [sym.imp.KERNEL32.dll_SizeofResource]
mov ebx, eax
test ebx, ebx
je 0x45f059
push ebx
call dword [sym.imp.msvcrt.dll_void____cdecl_operator_new___unsigned_int_]
pop ecx
push ebx
push dword [ebp - 0x18]
mov edi, eax
call dword [sym.imp.KERNEL32.dll_LockResource]
push eax
push edi
call dword [sym.imp.msvcrt.dll_memcpy]
add esp, 0xc
push esi
call dword [sym.imp.KERNEL32.dll_FreeResource]
test edi, edi
jne 0x45f0c9
push 0
push 0x80
push 3
push 0
push 1
push 0x80000000
push dword [ebp - 0x14]
call dword [sym.imp.KERNEL32.dll_CreateFileW]
mov esi, eax
cmp esi, 0xffffffff
je 0x45f296
push 0
push esi
call dword [sym.imp.KERNEL32.dll_GetFileSize]
mov ebx, eax
test ebx, ebx
je 0x45f0ba
and dword [ebp - 0x14], 0
push ebx
call dword [sym.imp.msvcrt.dll_void____cdecl_operator_new___unsigned_int_]
pop ecx
push 0
mov edi, eax
lea eax, [ebp - 0x14]
push eax
push ebx
push edi
push esi
call dword [sym.imp.KERNEL32.dll_ReadFile]
cmp dword [ebp - 0x14], ebx
je 0x45f0ba
push edi
call dword [sym.imp.msvcrt.dll_void___cdecl_operator_delete___void__]
pop ecx
xor edi, edi
push esi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
test edi, edi
je 0x45f296
lea eax, [ebx + edi]
mov dword [ebp - 0x64], edi
mov dword [ebp - 0x68], eax
lea edx, [ebp - 0x10]
push ecx
lea eax, [ebp - 0x2c]
mov dword [ebp - 0x6c], edi
push eax
lea eax, [ebp - 0x18]
xor esi, esi
push eax
lea ecx, [ebp - 0x114]
mov dword [ebp - 0x104], esi
mov dword [ebp - 0xf4], esi
call fcn.0044fc64
add esp, 0xc
mov ebx, eax
push edi
call dword [sym.imp.msvcrt.dll_void___cdecl_operator_delete___void__]
pop ecx
test ebx, ebx
je 0x45f296
push 0x2c
lea eax, [ebp - 0x58]
push esi
push eax
call dword [sym.imp.msvcrt.dll_memset]
mov eax, dword [ebp - 0x18]
add esp, 0xc
mov ecx, dword [ebp - 0x10]
neg eax
mov dword [ebp - 0x50], eax
mov edi, ecx
imul edi, dword [ebp - 0x18]
xor eax, eax
inc eax
mov dword [ebp - 0x54], ecx
push 0x20
mov word [ebp - 0x4c], ax
xor ecx, ecx
pop eax
mov word [ebp - 0x4a], ax
mov eax, edi
push ecx
shl eax, 2
push ecx
mov dword [ebp - 0x44], eax
lea eax, [ebp - 0xc]
push eax
push ecx
lea eax, [ebp - 0x58]
mov dword [ebp - 0x58], 0x28
push eax
push ecx
mov dword [ebp - 0x48], esi
mov byte [ebp - 5], cl
mov dword [ebp - 0xc], ecx
call dword [sym.imp.GDI32.dll_CreateDIBSection]
mov dword [ebp - 0x1c], eax
test eax, eax
je 0x45f296
test edi, edi
jle 0x45f24d
mov edx, 0xff
mov eax, dword [ebp - 0xc]
mov cl, byte [ebx + esi*4 + 3]
mov byte [eax + esi*4 + 3], cl
mov ecx, dword [ebp - 0xc]
cmp byte [ecx + esi*4 + 3], dl
jae 0x45f1f6
movzx ecx, byte [ebx + esi*4 + 3]
xor edx, edx
movzx eax, byte [ebx + esi*4 + 2]
imul eax, ecx
mov ecx, 0xff
div ecx
mov ecx, dword [ebp - 0xc]
xor edx, edx
mov byte [ecx + esi*4], al
movzx ecx, byte [ebx + esi*4 + 3]
movzx eax, byte [ebx + esi*4 + 1]
imul eax, ecx
mov ecx, 0xff
div ecx
mov ecx, dword [ebp - 0xc]
xor edx, edx
mov byte [ecx + esi*4 + 1], al
movzx ecx, byte [ebx + esi*4 + 3]
movzx eax, byte [ebx + esi*4]
imul eax, ecx
mov ecx, 0xff
div ecx
mov ecx, dword [ebp - 0xc]
xor edx, edx
inc edx
mov byte [ebp - 5], dl
mov byte [ecx + esi*4 + 2], al
jmp 0x45f215
mov al, byte [ebx + esi*4 + 2]
xor edx, edx
mov byte [ecx + esi*4], al
inc edx
mov eax, dword [ebp - 0xc]
mov cl, byte [ebx + esi*4 + 1]
mov byte [eax + esi*4 + 1], cl
mov eax, dword [ebp - 0xc]
mov cl, byte [ebx + esi*4]
mov byte [eax + esi*4 + 2], cl
mov eax, dword [ebp - 0xc]
mov ecx, dword [ebp + 8]
cmp dword [eax + esi*4], ecx
jne 0x45f23f
mov byte [eax + esi*4], 0
mov eax, dword [ebp - 0xc]
mov byte [ebp - 5], dl
mov byte [eax + esi*4 + 1], 0
mov eax, dword [ebp - 0xc]
mov byte [eax + esi*4 + 2], 0
mov eax, dword [ebp - 0xc]
mov byte [eax + esi*4 + 3], 0
inc esi
mov edx, 0xff
cmp esi, edi
jl 0x45f185
push ebx
call dword [sym.imp.msvcrt.dll_free]
pop ecx
push 0x28
call dword [sym.imp.msvcrt.dll_void____cdecl_operator_new_unsigned_int_]
xor edx, edx
pop ecx
test eax, eax
je 0x45f26f
mov dword [eax + 0x18], edx
mov dword [eax + 0x1c], edx
mov dword [eax + 0x20], edx
jmp 0x45f271
mov eax, edx
mov ecx, dword [ebp - 0x1c]
mov dword [eax], ecx
mov ecx, dword [ebp - 0xc]
mov dword [eax + 4], ecx
mov ecx, dword [ebp - 0x10]
mov dword [eax + 0xc], ecx
mov ecx, dword [ebp - 0x18]
mov dword [eax + 0x10], ecx
mov cl, byte [ebp - 5]
mov byte [eax + 0x14], cl
mov byte [eax + 0x15], dl
mov dword [eax + 8], edx
jmp 0x45f298
xor eax, eax
pop edi
pop esi
pop ebx
leave
ret