Function at 0x1003e150
Capabilities:
Extract resource via kernel32 functions
Read file via mapping

Disassembly:
push ebp
mov ebp, esp
push 0xfffffffffffffffe
push 0x100f0920
push 0x10097990
mov eax, dword fs:[0]
push eax
sub esp, 0x28
push ebx
push esi
push edi
mov eax, dword [0x100f51d4]
xor dword [ebp - 8], eax
xor eax, ebp
push eax
lea eax, [ebp - 0x10]
mov dword fs:[0], eax
mov dword [ebp - 0x18], esp
mov dword [ebp - 0x20], ecx
xor edi, edi
mov dword [ebp - 0x1c], edi
xor esi, esi
mov dword [ebp - 0x30], 0xffffffff
mov dword [ebp - 0x2c], esi
xor ebx, ebx
mov dword [ebp - 0x28], ebx
mov eax, dword [ebp + 0x10]
test eax, eax
mov ecx, 0x10027030
jne 0x1003e1ae
mov ecx, dword [sym.imp.KERNEL32.dll_CreateFileW]
mov dword [ebp + 0x10], ecx
test eax, eax
mov eax, 0x10026ff0
jne 0x1003e1bf
mov eax, dword [sym.imp.KERNEL32.dll_CloseHandle]
mov dword [ebp - 0x34], eax
test ecx, ecx
je 0x1003e1d8
test eax, eax
je 0x1003e1d8
cmp dword [ebp + 8], 0x5c
jae 0x1003e1ec
push 0x7a
call dword [sym.imp.KERNEL32.dll_SetLastError]
xor eax, eax
mov ecx, dword [ebp - 0x10]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
push 1
call dword [sym.imp.KERNEL32.dll_SetErrorMode]
mov dword [ebp - 0x38], eax
cmp dword [ebp + 0x14], ebx
jne 0x1003e256
push 0
push 0x80
push 3
push 0
push 1
push SysReAllocString
push dword [ebp - 0x20]
call dword [ebp + 0x10]
mov dword [ebp - 0x30], eax
cmp eax, 0xffffffff
je 0x1003e268
push 0
push 0
push 0
push 0x1000002
push 0
push eax
call dword [sym.imp.KERNEL32.dll_CreateFileMappingW]
mov dword [ebp - 0x2c], eax
test eax, eax
je 0x1003e268
push 0
push 0
push 0
push 4
push eax
call dword [sym.imp.KERNEL32.dll_MapViewOfFile]
mov ebx, eax
mov dword [ebp - 0x28], ebx
test ebx, ebx
je 0x1003e268
mov edi, ebx
mov dword [ebp - 0x1c], edi
jmp 0x1003e268
push 2
push 0
push dword [ebp - 0x20]
call dword [0x100be420]
mov edi, eax
mov dword [ebp - 0x1c], eax
push dword [ebp - 0x38]
call dword [sym.imp.KERNEL32.dll_SetErrorMode]
test edi, edi
je 0x1003e33e
push 0x10
push 1
push edi
call dword [sym.imp.KERNEL32.dll_FindResourceW]
test eax, eax
je 0x1003e32f
push eax
push edi
call dword [sym.imp.KERNEL32.dll_LoadResource]
mov ecx, eax
test ecx, ecx
je 0x1003e32f
mov dword [ebp - 4], esi
movzx esi, word [ecx]
mov dword [ebp + 0x10], esi
lea eax, [esi*2 + 4]
mov edx, dword [ebp + 8]
cmp eax, edx
jbe 0x1003e2c6
shr edx, 1
lea esi, [edx - 4]
mov dword [ebp + 0x10], esi
mov dword [ebp + 0x10], 1
jmp 0x1003e2cd
mov dword [ebp + 0x10], 0
mov eax, esi
test eax, eax
jle 0x1003e304
push esi
push ecx
push dword [ebp + 0xc]
call fcn.10096ab0
add esp, 0xc
mov eax, dword [ebp + 0xc]
mov dword [esi + eax], 0x58324546
cmp dword [ebp + 0x10], 0
je 0x1003e2f3
mov word [eax], si
mov esi, 1
mov dword [ebp - 0x24], esi
mov dword [ebp - 4], 0xfffffffe
jmp 0x1003e331
xor esi, esi
mov dword [ebp - 0x24], esi
mov dword [ebp - 4], 0xfffffffe
jmp 0x1003e331
xor esi, esi
cmp dword [ebp + 0x14], 0
je 0x1003e33e
push edi
call dword [sym.imp.KERNEL32.dll_FreeLibrary]
test ebx, ebx
je 0x1003e349
push ebx
call dword [sym.imp.KERNEL32.dll_UnmapViewOfFile]
mov eax, dword [ebp - 0x2c]
test eax, eax
je 0x1003e357
push eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov eax, dword [ebp - 0x30]
cmp eax, 0xffffffff
je 0x1003e363
push eax
call dword [ebp - 0x34]
mov eax, esi
mov ecx, dword [ebp - 0x10]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret