Function at 0x4061c0
Capabilities:
Allocate or change rwx memory
Execute shellcode via indirect call
Extract resource via kernel32 functions
Parse pe header

Disassembly:
sub esp, 0x10c
mov edx, dword [esp + 0x118]
mov eax, dword [esp + 0x110]
push ebx
mov ebx, ecx
mov ecx, dword [esp + 0x118]
push ebp
push esi
push edi
push ecx
push edx
push 0
mov dword [ebx + 8], eax
call dword [sym.imp.KERNEL32.dll_FindResourceA]
push eax
push 0
call dword [sym.imp.KERNEL32.dll_LoadResource]
push eax
call dword [sym.imp.KERNEL32.dll_LockResource]
mov ebp, eax
mov dword [esp + 0x18], ebp
mov eax, dword [ebp + 0x3c]
add eax, ebp
mov dword [ebx + 0xc], eax
cmp word [ebp], 0x5a4d
je 0x40623f
cmp dword [eax], 0x4550
je 0x40623f
push 0x10
push str.Failed_to_load_DLL
push str.The_Resource_is_invalid_DLL_
push 0
call dword [sym.imp.USER32.dll_MessageBoxA]
pop edi
pop esi
pop ebp
xor eax, eax
pop ebx
add esp, 0x10c
ret 0xc
mov esi, dword [eax + 0x50]
mov ecx, dword [eax + 0x34]
mov edi, dword [sym.imp.KERNEL32.dll_VirtualAlloc]
push 0x40
push 0x2000
push esi
push ecx
call edi
test eax, eax
mov dword [ebx + 4], eax
jne 0x40626b
push 0x40
push 0x2000
push esi
push eax
call edi
mov dword [ebx + 4], eax
mov edx, dword [ebx + 4]
push 0x40
push 0x1000
push esi
push edx
call edi
mov eax, dword [ebx + 0xc]
mov edi, dword [ebx + 4]
mov esi, ebp
mov ecx, dword [eax + 0x54]
mov edx, ecx
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, edx
xor edx, edx
and ecx, 3
rep movsb byte es:[edi], byte [esi]
mov eax, dword [ebx + 0xc]
xor ecx, ecx
mov dword [esp + 0x10], ecx
mov dx, word [eax + 6]
test edx, edx
jle 0x4062f9
add eax, 0x10c
mov esi, dword [eax]
lea edi, [esi + ebp]
mov dword [esp + 0x14], edi
mov edi, dword [eax - 4]
test edi, edi
je 0x4062ed
mov edi, dword [eax - 8]
mov ebp, dword [ebx + 4]
add edi, ebp
lea ebp, [edx - 1]
cmp ecx, ebp
jge 0x4062d0
mov ecx, dword [eax + 0x28]
sub ecx, esi
jmp 0x4062d3
mov ecx, dword [eax - 4]
mov esi, dword [esp + 0x14]
mov ebp, ecx
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, ebp
mov ebp, dword [esp + 0x18]
and ecx, 3
rep movsb byte es:[edi], byte [esi]
mov ecx, dword [esp + 0x10]
inc ecx
add eax, 0x28
cmp ecx, edx
mov dword [esp + 0x10], ecx
jl 0x4062aa
mov edx, dword [ebx + 0xc]
mov ecx, dword [edx + 0xa0]
test ecx, ecx
je 0x406365
mov eax, dword [ebx + 4]
mov edi, dword [edx + 0x34]
add ecx, eax
mov esi, eax
sub esi, edi
mov eax, dword [ecx]
test eax, eax
je 0x406365
add eax, dword [ebx + 4]
mov edi, eax
mov eax, dword [ecx + 4]
sub eax, 8
shr eax, 1
je 0x406365
test eax, eax
lea edx, [ecx + 8]
jle 0x40635c
mov dword [esp + 0x10], eax
mov ax, word [edx]
mov ebp, eax
and ebp, 0xf000
cmp ebp, 0x3000
jne 0x40634e
and eax, 0xfff
add eax, edi
add dword [eax], esi
mov eax, dword [esp + 0x10]
add edx, 2
dec eax
mov dword [esp + 0x10], eax
jne 0x406332
add ecx, dword [ecx + 4]
mov eax, dword [ecx]
test eax, eax
jne 0x406318
mov ecx, 0x3f
xor eax, eax
lea edi, [esp + 0x1d]
mov byte [esp + 0x1c], 0
rep stosd dword es:[edi], eax
stosw word es:[edi], ax
stosb byte es:[edi], al
mov eax, dword [ebx + 0xc]
mov edi, dword [eax + 0x80]
test edi, edi
je 0x406406
add edi, dword [ebx + 4]
mov dword [esp + 0x10], edi
mov eax, dword [edi + 0xc]
test eax, eax
je 0x406406
jmp 0x40639b
mov edi, dword [esp + 0x10]
add eax, dword [ebx + 4]
push eax
call dword [sym.imp.KERNEL32.dll_LoadLibraryA]
mov ebp, eax
test ebp, ebp
je 0x406435
mov ecx, dword [edi + 0x10]
mov eax, dword [ebx + 4]
mov edi, dword [edi]
test edi, edi
lea esi, [ecx + eax]
je 0x4063c0
mov ecx, edi
lea edi, [eax + ecx]
mov eax, dword [eax + ecx]
test eax, eax
je 0x4063f4
test eax, 0x800000
jne 0x4063d9
add eax, dword [ebx + 4]
add eax, 2
jmp 0x4063de
xor eax, 0x7fffff
push eax
push ebp
call dword [sym.imp.KERNEL32.dll_GetProcAddress]
add edi, 4
mov dword [esi], eax
add esi, 4
mov eax, dword [edi]
test eax, eax
jne 0x4063ca
mov eax, dword [esp + 0x10]
add eax, 0x14
mov dword [esp + 0x10], eax
mov eax, dword [eax + 0xc]
test eax, eax
jne 0x406397
mov ecx, dword [ebx + 0xc]
mov eax, dword [ebx + 4]
push 0
push 1
mov edx, dword [ecx + 0x28]
mov ecx, dword [ebx + 8]
add eax, edx
push ecx
mov dword [ebx + 0x10], eax
call eax
mov ecx, ebx
call fcn.00406550
mov eax, dword [ebx + 4]
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x10c
ret 0xc
mov ecx, dword [edi + 0xc]
mov edx, dword [ebx + 4]
add ecx, edx
lea edx, [esp + 0x1c]
push ecx
push str.Failed_to_load_DLL__s_
push edx
call dword [sym.imp.USER32.dll_wsprintfA]
add esp, 0xc
lea eax, [esp + 0x1c]
push 0x10
push str.Error
push eax
push 0
call dword [sym.imp.USER32.dll_MessageBoxA]
pop edi
pop esi
pop ebp
xor eax, eax
pop ebx
add esp, 0x10c
ret 0xc