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

Disassembly:
push 0x28c
mov eax, 0x56f7b8
call fcn.00523ae6
mov eax, dword [ebp + 0xc]
xor ebx, ebx
or edi, 0xffffffff
mov esi, 0x88
test eax, eax
jne 0x4f3016
call fcn.004d8c70
push eax
lea ecx, [ebp - 0xc4]
call fcn.004d53c2
mov dword [ebp - 4], ebx
call fcn.004d8c76
mov ecx, eax
call fcn.004d5ed5
test al, al
je 0x4f2f31
push dword [ebp + 8]
lea ecx, [ebp - 0xc4]
call fcn.004d586e
push ebx
push 0x80
push 3
push ebx
push 1
push accept
lea ecx, [ebp - 0xc4]
call fcn.004d5d57
push eax
call dword [sym.imp.KERNEL32.dll_CreateFileW]
mov ebx, eax
cmp ebx, edi
jne 0x4f2ed5
mov esi, dword [0x5c138c]
jmp 0x4f2eba
push esi
call fcn.004d55d0
push dword [ebp + 8]
lea ecx, [ebp - 0xc4]
call fcn.004d586e
push 0
push 0x80
push 3
push 0
push 1
push accept
lea ecx, [ebp - 0xc4]
call fcn.004d5d57
push eax
call dword [sym.imp.KERNEL32.dll_CreateFileW]
mov ebx, eax
cmp ebx, edi
jne 0x4f2ed5
add esi, 0x88
lea ecx, [ebp - 0xc4]
cmp esi, dword [0x5c1390]
jne 0x4f2e76
mov dword [ebp - 4], edi
call fcn.004d5536
jmp 0x4f308d
push 0
push ebx
call dword [sym.imp.KERNEL32.dll_GetFileSize]
mov esi, eax
test esi, esi
jne 0x4f2eef
mov dword [ebp - 4], edi
lea ecx, [ebp - 0xc4]
jmp 0x4f2ecb
and dword [ebp - 0x288], 0
push esi
call fcn.00523cdd
pop ecx
push 0
mov edi, eax
lea eax, [ebp - 0x288]
push eax
push esi
push edi
push ebx
call dword [sym.imp.KERNEL32.dll_ReadFile]
push ebx
call dword [sym.imp.KERNEL32.dll_CloseHandle]
cmp dword [ebp - 0x288], esi
je 0x4f3005
push edi
call fcn.00523ce6
pop ecx
or dword [ebp - 4], 0xffffffff
jmp 0x4f2ee7
call fcn.004d8c76
push eax
lea ecx, [ebp - 0xc4]
call fcn.004d57eb
call fcn.004d8d8f
test al, al
je 0x4f2f52
call fcn.004d8c7c
jmp 0x4f2f69
push 2
push ebx
lea ecx, [ebp - 0xc4]
call fcn.004d5d57
push eax
call fcn.004e516a
add esp, 0xc
mov ebx, eax
test ebx, ebx
jne 0x4f2f82
lea ecx, [ebp - 0xc4]
mov dword [ebp - 4], edi
call fcn.004d5536
jmp 0x4f3092
lea eax, [ebp - 0x278]
push eax
lea eax, [ebp - 0x284]
push eax
push 1
push dword [ebp + 8]
push ebx
call fcn.004e47f7
add esp, 0x14
test eax, eax
jne 0x4f2f6f
mov esi, dword [ebp - 0x150]
test esi, esi
je 0x4f2ee4
push esi
call fcn.00523cdd
push 3
push esi
mov edi, eax
push edi
push dword [ebp - 0x284]
push ebx
call fcn.004e55c7
add esp, 0x18
test eax, eax
je 0x4f2ff5
cmp eax, 0x600
je 0x4f2ff5
push edi
call fcn.00523ce6
pop ecx
call fcn.004d8d8f
test al, al
jne 0x4f2f2b
push ebx
call fcn.004e4647
jmp 0x4f2f2a
call fcn.004d8d8f
test al, al
jne 0x4f3005
push ebx
call fcn.004e4647
pop ecx
or dword [ebp - 4], 0xffffffff
lea ecx, [ebp - 0xc4]
call fcn.004d5536
jmp 0x4f3085
push eax
push dword [ebp + 8]
call fcn.004d8c61
push eax
call dword [sym.imp.KERNEL32.dll_FindResourceW]
mov ebx, eax
test ebx, ebx
je 0x4f3092
push ebx
call fcn.004d8c61
push eax
call dword [sym.imp.KERNEL32.dll_LoadResource]
mov dword [ebp - 0x284], eax
push ebx
test eax, eax
jne 0x4f304c
call dword [sym.imp.KERNEL32.dll_FreeResource]
jmp 0x4f3092
call fcn.004d8c61
push eax
call dword [sym.imp.KERNEL32.dll_SizeofResource]
mov esi, eax
test esi, esi
je 0x4f308d
push esi
call fcn.00523cdd
pop ecx
push esi
push dword [ebp - 0x284]
mov edi, eax
call dword [sym.imp.KERNEL32.dll_LockResource]
push eax
push edi
call sub.VCRUNTIME140.dll_memcpy
add esp, 0xc
push ebx
call dword [sym.imp.KERNEL32.dll_FreeResource]
test edi, edi
jne 0x4f31a6
mov esi, 0x88
mov edi, dword [sym.imp.KERNEL32.dll_CreateFileW]
push 0
push 0x80
push 3
push 0
push 1
push accept
push dword [ebp + 8]
call edi
mov ebx, eax
cmp ebx, 0xffffffff
jne 0x4f3151
mov eax, dword [0x5c1390]
sub eax, dword [0x5c138c]
cdq
idiv esi
test eax, eax
je 0x4f33ac
lea ecx, [ebp - 0x14c]
call fcn.004d540b
mov esi, dword [0x5c138c]
mov dword [ebp - 4], 1
jmp 0x4f3131
push esi
lea ecx, [ebp - 0x14c]
call fcn.004d55d0
push dword [ebp + 8]
lea ecx, [ebp - 0x14c]
call fcn.004d586e
push 0
push 0x80
push 3
push 0
push 1
push accept
lea ecx, [ebp - 0x14c]
call fcn.004d5d57
push eax
call edi
mov ebx, eax
cmp ebx, 0xffffffff
jne 0x4f3139
add esi, 0x88
cmp esi, dword [0x5c1390]
jne 0x4f30ea
or dword [ebp - 4], 0xffffffff
lea ecx, [ebp - 0x14c]
call fcn.004d5536
cmp ebx, 0xffffffff
je 0x4f33ac
push 0
push ebx
call dword [sym.imp.KERNEL32.dll_GetFileSize]
mov esi, eax
test esi, esi
je 0x4f33ac
and dword [ebp - 0x28c], 0
push esi
call fcn.00523cdd
pop ecx
push 0
mov edi, eax
lea eax, [ebp - 0x28c]
push eax
push esi
push edi
push ebx
call dword [sym.imp.KERNEL32.dll_ReadFile]
push ebx
call dword [sym.imp.KERNEL32.dll_CloseHandle]
cmp dword [ebp - 0x28c], esi
je 0x4f319e
push edi
call fcn.00523ce6
pop ecx
xor edi, edi
test edi, edi
je 0x4f33ac
push 4
lea eax, [ebp - 0x298]
push eax
lea eax, [ebp - 0x294]
push eax
lea eax, [ebp - 0x290]
push eax
push esi
push edi
call fcn.004ffe0d
push edi
mov ebx, eax
call fcn.00523ce6
add esp, 0x1c
test ebx, ebx
je 0x4f33ac
push 0x2c
lea eax, [ebp - 0x3c]
push 0
push eax
call sub.VCRUNTIME140.dll_memset
mov eax, dword [ebp - 0x294]
add esp, 0xc
mov ecx, dword [ebp - 0x290]
neg eax
and dword [ebp - 0x2c], 0
mov edi, ecx
imul edi, dword [ebp - 0x294]
mov dword [ebp - 0x34], eax
xor eax, eax
inc eax
mov dword [ebp - 0x38], ecx
push 0x20
mov word [ebp - 0x30], ax
xor ecx, ecx
pop eax
mov word [ebp - 0x2e], ax
mov eax, edi
push ecx
shl eax, 2
push ecx
mov dword [ebp - 0x28], eax
lea eax, [ebp - 0x280]
push eax
push ecx
lea eax, [ebp - 0x3c]
mov dword [ebp - 0x3c], 0x28
push eax
push ecx
mov byte [ebp - 0x279], cl
mov dword [ebp - 0x280], ecx
call dword [sym.imp.GDI32.dll_CreateDIBSection]
mov dword [ebp - 0x288], eax
test eax, eax
je 0x4f33ac
xor esi, esi
test edi, edi
jle 0x4f3354
mov edx, 0xff
mov eax, dword [ebp - 0x280]
mov cl, byte [ebx + esi*4 + 3]
mov byte [eax + esi*4 + 3], cl
mov ecx, dword [ebp - 0x280]
cmp byte [ecx + esi*4 + 3], dl
jae 0x4f32e8
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 - 0x280]
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 - 0x280]
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 - 0x280]
xor edx, edx
inc edx
mov byte [ebp - 0x279], dl
mov byte [ecx + esi*4 + 2], al
jmp 0x4f330d
mov al, byte [ebx + esi*4 + 2]
xor edx, edx
mov byte [ecx + esi*4], al
inc edx
mov eax, dword [ebp - 0x280]
mov cl, byte [ebx + esi*4 + 1]
mov byte [eax + esi*4 + 1], cl
mov eax, dword [ebp - 0x280]
mov cl, byte [ebx + esi*4]
mov byte [eax + esi*4 + 2], cl
mov eax, dword [ebp - 0x280]
mov ecx, dword [ebp + 0x10]
cmp dword [eax + esi*4], ecx
jne 0x4f3346
mov byte [eax + esi*4], 0
mov eax, dword [ebp - 0x280]
mov byte [ebp - 0x279], dl
mov byte [eax + esi*4 + 1], 0
mov eax, dword [ebp - 0x280]
mov byte [eax + esi*4 + 2], 0
mov eax, dword [ebp - 0x280]
mov byte [eax + esi*4 + 3], 0
inc esi
mov edx, 0xff
cmp esi, edi
jl 0x4f3265
push ebx
call fcn.004ff8c0
push 0x9c
call fcn.0052362a
pop ecx
mov esi, eax
pop ecx
mov dword [ebp - 0x298], esi
mov dword [ebp - 4], 2
test esi, esi
je 0x4f3383
lea ecx, [esi + 0x10]
call fcn.004d540b
jmp 0x4f3385
xor esi, esi
mov eax, dword [ebp - 0x288]
mov dword [esi], eax
mov eax, dword [ebp - 0x290]
mov dword [esi + 4], eax
mov eax, dword [ebp - 0x294]
mov dword [esi + 8], eax
mov al, byte [ebp - 0x279]
mov byte [esi + 0xc], al
mov eax, esi
jmp 0x4f33ae
xor eax, eax
call fcn.00523a90
ret