Function at 0x10145dae
Capabilities:
Extract resource via kernel32 functions
Write file on windows

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x28
mov eax, dword [0x101d5abc]
xor eax, ebp
mov dword [ebp - 4], eax
push ebx
mov ebx, dword [ebp + 8]
push esi
mov esi, ecx
mov dword [ebp - 0x20], ebx
push edi
test esi, esi
je 0x10146125
cmp dword [esi], 0x666e7469
jne 0x10146125
test byte [esi + 0x224], 2
je 0x10146125
mov eax, dword [esi + 0x21c]
imul edi, edx, 0x24
push 0x24
pop ecx
and dword [ebp - 0x1c], 0
push 0x46
mov dword [edi + eax], 0x43455246
mov eax, dword [esi + 0x21c]
mov word [edi + eax + 4], cx
mov eax, dword [esi + 0x21c]
movzx ecx, dx
mov dword [ebp - 0x24], ecx
mov word [edi + eax + 6], cx
mov ecx, dword [esi + 0x21c]
mov ax, word [ebx + 0x30]
mov word [edi + ecx + 8], ax
mov eax, dword [esi + 0x21c]
pop ecx
mov word [edi + eax + 0xa], cx
mov eax, dword [esi + 0x21c]
mov dword [edi + eax + 0xc], 0x4946544e
mov ecx, dword [esi + 0x21c]
mov edx, dword [ebx + 0x34]
mov eax, dword [esi + 0x220]
mov dword [edi + ecx + 0x10], eax
mov ecx, edx
lea eax, [ecx + 2]
mov dword [ebp - 0x28], eax
mov ax, word [ecx]
add ecx, 2
cmp ax, word [ebp - 0x1c]
jne 0x10145e65
sub ecx, dword [ebp - 0x28]
xor eax, eax
push eax
sar ecx, 1
lea eax, [ebp - 0x18]
push eax
lea eax, [ecx*2 + 2]
push eax
push edx
push dword [esi + 0x214]
call dword [sym.imp.KERNEL32.dll_WriteFile]
test eax, eax
je 0x10146125
mov eax, dword [ebp - 0x18]
xor ecx, ecx
add eax, 3
add eax, dword [esi + 0x220]
push ecx
and eax, 0xfffffffc
push ecx
push eax
push dword [esi + 0x214]
mov dword [esi + 0x220], eax
call dword [sym.imp.KERNEL32.dll_SetFilePointer]
mov edx, dword [ebp - 0x24]
xor ecx, ecx
mov dword [esi + 0x220], eax
mov eax, dword [esi + 0x21c]
mov dword [edi + eax + 0x14], ecx
mov ecx, dword [esi + 0x21c]
mov eax, dword [esi + 0x220]
mov dword [edi + ecx + 0x18], eax
lea eax, [ebx + 0xc]
mov ecx, dword [esi + 0x214]
push eax
call fcn.10119940
mov dword [ebp - 0x18], eax
test eax, eax
je 0x10146125
mov ecx, dword [esi + 0x220]
add ecx, 3
add eax, ecx
xor ecx, ecx
push ecx
and eax, 0xfffffffc
push ecx
push eax
push dword [esi + 0x214]
mov dword [esi + 0x220], eax
call dword [sym.imp.KERNEL32.dll_SetFilePointer]
mov dword [esi + 0x220], eax
xor eax, eax
mov edx, eax
mov ecx, eax
cmp dword [esi + 0x230], eax
jbe 0x10145f67
mov eax, dword [esi + 0x21c]
movzx eax, word [edi + eax + 8]
mov dword [ebp - 0x24], eax
mov eax, dword [esi + 0x22c]
mov ebx, dword [ebp - 0x24]
cmp word [eax + ecx*8], bx
mov ebx, dword [ebp - 0x20]
je 0x10145f63
inc ecx
cmp ecx, dword [esi + 0x230]
jb 0x10145f4c
jmp 0x10145f67
mov edx, dword [eax + ecx*8 + 4]
mov eax, dword [esi + 0x21c]
test edx, edx
jne 0x101460b9
movzx ecx, word [edi + eax + 8]
mov ebx, edx
test cx, cx
jle 0x10145fc0
push 0x103
push ecx
push dword [0x101d6f40]
call dword [sym.imp.KERNEL32.dll_FindResourceW]
mov ebx, eax
test ebx, ebx
je 0x10146125
push ebx
push dword [0x101d6f40]
call dword [sym.imp.KERNEL32.dll_LoadResource]
push eax
call dword [sym.imp.KERNEL32.dll_LockResource]
mov ecx, eax
xor edx, edx
mov eax, dword [esi + 0x21c]
mov dword [ebp - 0x1c], ecx
jmp 0x10145fc5
mov ecx, edx
mov dword [ebp - 0x1c], edx
test ecx, ecx
je 0x101460b6
push 0x10
pop ecx
push ebx
push dword [0x101d6f40]
mov dword [ebp - 0x14], 0x54544344
mov word [ebp - 0x10], cx
mov ax, word [edi + eax + 8]
mov word [ebp - 0xe], ax
call dword [sym.imp.KERNEL32.dll_SizeofResource]
mov ecx, dword [esi + 0x21c]
xor ebx, ebx
mov dword [ebp - 0xc], eax
mov eax, dword [esi + 0x220]
push ebx
mov dword [ebp - 8], ebx
mov dword [edi + ecx + 0x1c], eax
lea eax, [ebp - 0x18]
push eax
push 0x10
lea eax, [ebp - 0x14]
push eax
push dword [esi + 0x214]
call dword [sym.imp.KERNEL32.dll_WriteFile]
test eax, eax
je 0x10146125
push ebx
lea eax, [ebp - 0x18]
push eax
push dword [ebp - 0xc]
push dword [ebp - 0x1c]
push dword [esi + 0x214]
call dword [sym.imp.KERNEL32.dll_WriteFile]
test eax, eax
je 0x10146125
mov eax, dword [esi + 0x21c]
mov edx, dword [esi + 0x230]
mov ecx, dword [esi + 0x22c]
push ebx
mov ax, word [edi + eax + 8]
push ebx
mov word [ecx + edx*8], ax
mov edx, dword [esi + 0x230]
mov ecx, dword [esi + 0x22c]
mov eax, dword [esi + 0x220]
mov dword [ecx + edx*8 + 4], eax
mov eax, dword [esi + 0x218]
inc dword [esi + 0x230]
inc dword [eax + 0x10]
mov eax, dword [ebp - 0x18]
add eax, 0x13
add eax, dword [esi + 0x220]
and eax, 0xfffffffc
push eax
push dword [esi + 0x214]
mov dword [esi + 0x220], eax
call dword [sym.imp.KERNEL32.dll_SetFilePointer]
mov ebx, dword [ebp - 0x20]
mov dword [esi + 0x220], eax
jmp 0x101460bd
mov ebx, dword [ebp - 0x20]
mov dword [edi + eax + 0x1c], edx
mov ecx, dword [esi + 0x21c]
mov eax, dword [esi + 0x220]
mov dword [edi + ecx + 0x20], eax
mov edx, dword [ebx + 4]
mov ecx, dword [esi + 0x214]
test edx, edx
jne 0x101460e4
lea edx, [ebx + 0x5c]
call fcn.101199be
jmp 0x101460ec
push dword [ebx + 8]
call fcn.10119a65
mov ecx, eax
mov dword [ebp - 0x18], ecx
test ecx, ecx
je 0x10146125
mov eax, dword [esi + 0x220]
add eax, 3
add eax, ecx
xor ecx, ecx
push ecx
and eax, 0xfffffffc
push ecx
push eax
push dword [esi + 0x214]
mov dword [esi + 0x220], eax
call dword [sym.imp.KERNEL32.dll_SetFilePointer]
mov dword [esi + 0x220], eax
xor eax, eax
inc eax
jmp 0x10146127
xor eax, eax
mov ecx, dword [ebp - 4]
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.101885f0
leave
ret 4