Function at 0x40aff0
Capabilities:
Extract resource via kernel32 functions

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x4197e0
mov eax, dword fs:[0]
push eax
sub esp, 0x14
push ebx
push esi
push edi
mov eax, dword [0x4241dc]
xor eax, ebp
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov ebx, ecx
mov dword [ebp - 0x14], ebx
lea ecx, [ebp + 0x1c]
mov dword [ebp - 4], 1
xor edi, edi
call fcn.00402170
test eax, eax
jle 0x40b0e5
lea ecx, [ebp + 0x1c]
call fcn.00402110
push eax
call dword [sym.imp.KERNEL32.dll_LoadLibraryW]
mov edi, eax
test edi, edi
jne 0x40b0e5
call dword [sym.imp.KERNEL32.dll_GetLastError]
sub esp, 8
mov ecx, esp
mov dword [ebp + 0x10], esp
push edi
mov esi, eax
push 0xa
push esi
call fcn.00401020
sub esp, 8
mov ecx, esp
mov dword [ebp + 0x2c], esp
push 0x41aa20
mov byte [ebp - 4], 2
call fcn.00401070
lea eax, [ebp + 8]
push eax
lea ecx, [ebp - 0x18]
mov byte [ebp - 4], 3
call fcn.00401000
mov byte [ebp - 4], 4
mov ecx, eax
mov byte [ebp - 4], 5
call fcn.00401450
mov ecx, eax
mov byte [ebp - 4], 6
call fcn.00401450
sub esp, 8
mov ecx, esp
push eax
call fcn.00401000
mov ecx, dword [ebx]
push 0x402
push 1
push edi
call fcn.00406bd0
lea ecx, [ebp - 0x18]
mov byte [ebp - 4], 1
call fcn.004010d0
mov eax, dword [ebp + 0x24]
mov byte [ebp - 0xd], 0
mov dword [eax], 0x402
mov eax, dword [ebp + 0x28]
mov dword [eax], esi
jmp 0x40b350
mov eax, dword [ebp + 0x10]
xor ecx, ecx
mov byte [ebp - 0xd], 0
test al, 1
jne 0x40b0fd
test eax, eax
je 0x40b0fd
shr eax, 1
inc ecx
test al, 1
je 0x40b0f2
lea eax, [ecx + 0xc8]
movzx eax, ax
push 0xa
push eax
push edi
call dword [sym.imp.KERNEL32.dll_FindResourceW]
mov esi, eax
test esi, esi
jne 0x40b1b2
call dword [sym.imp.KERNEL32.dll_GetLastError]
sub esp, 8
mov ecx, esp
mov dword [ebp + 0x10], esp
push 0
mov esi, eax
push 0xa
push esi
call fcn.00401020
sub esp, 8
mov ecx, esp
mov dword [ebp + 0x2c], esp
push 0x41aa20
mov byte [ebp - 4], 7
call fcn.00401070
lea eax, [ebp + 8]
push eax
lea ecx, [ebp - 0x18]
mov byte [ebp - 4], 8
call fcn.00401000
mov byte [ebp - 4], 9
mov ecx, eax
mov byte [ebp - 4], 0xa
call fcn.00401450
mov ecx, eax
mov byte [ebp - 4], 0xb
call fcn.00401450
sub esp, 8
mov ecx, esp
push eax
call fcn.00401000
mov ecx, dword [ebx]
push 0x403
push 1
push 0
call fcn.00406bd0
lea ecx, [ebp - 0x18]
mov byte [ebp - 4], 1
call fcn.004010d0
mov eax, dword [ebp + 0x24]
mov byte [ebp - 0xd], 0
mov dword [eax], 0x403
mov eax, dword [ebp + 0x28]
mov dword [eax], esi
jmp 0x40b350
push esi
push edi
call dword [sym.imp.KERNEL32.dll_LoadResource]
mov ebx, eax
test ebx, ebx
jne 0x40b25c
call dword [sym.imp.KERNEL32.dll_GetLastError]
sub esp, 8
mov ecx, esp
mov dword [ebp + 0x10], esp
push ebx
mov esi, eax
push 0xa
push esi
call fcn.00401020
sub esp, 8
mov ecx, esp
mov dword [ebp + 0x2c], esp
push 0x41aa20
mov byte [ebp - 4], 0xc
call fcn.00401070
lea eax, [ebp + 8]
push eax
lea ecx, [ebp - 0x20]
mov byte [ebp - 4], 0xd
call fcn.00401000
mov byte [ebp - 4], 0xe
mov ecx, eax
mov byte [ebp - 4], 0xf
call fcn.00401450
mov ecx, eax
mov byte [ebp - 4], 0x10
call fcn.00401450
sub esp, 8
mov ecx, esp
push eax
call fcn.00401000
mov ecx, dword [ebp - 0x14]
push 0x404
mov ecx, dword [ecx]
push 1
push ebx
call fcn.00406bd0
lea ecx, [ebp - 0x20]
mov byte [ebp - 4], 1
call fcn.004010d0
mov eax, dword [ebp + 0x24]
mov byte [ebp - 0xd], bl
mov dword [eax], 0x404
mov eax, dword [ebp + 0x28]
mov dword [eax], esi
jmp 0x40b350
push esi
push edi
call dword [sym.imp.KERNEL32.dll_SizeofResource]
push ebx
mov esi, eax
call dword [sym.imp.KERNEL32.dll_LockResource]
test eax, eax
jne 0x40b309
call dword [sym.imp.KERNEL32.dll_GetLastError]
sub esp, 8
mov ecx, esp
mov dword [ebp + 0x10], esp
push 0
mov esi, eax
push 0xa
push esi
call fcn.00401020
sub esp, 8
mov ecx, esp
mov dword [ebp + 0x2c], esp
push 0x41aa20
mov byte [ebp - 4], 0x11
call fcn.00401070
lea eax, [ebp + 8]
push eax
lea ecx, [ebp - 0x20]
mov byte [ebp - 4], 0x12
call fcn.00401000
mov byte [ebp - 4], 0x13
mov ecx, eax
mov byte [ebp - 4], 0x14
call fcn.00401450
mov ecx, eax
mov byte [ebp - 4], 0x15
call fcn.00401450
sub esp, 8
mov ecx, esp
push eax
call fcn.00401000
mov ecx, dword [ebp - 0x14]
push 0x405
mov ecx, dword [ecx]
push 1
push 0
call fcn.00406bd0
lea ecx, [ebp - 0x20]
mov byte [ebp - 4], 1
call fcn.004010d0
mov eax, dword [ebp + 0x24]
mov dword [eax], 0x405
mov eax, dword [ebp + 0x28]
mov dword [eax], esi
jmp 0x40b336
push dword [ebp + 0x2c]
push dword [ebp + 0x28]
push dword [ebp + 0x24]
push dword [ebp + 0x18]
push dword [ebp + 0x14]
push esi
push eax
sub esp, 8
lea eax, [ebp + 8]
mov ecx, esp
push eax
call fcn.00401000
mov ecx, dword [ebp - 0x14]
call fcn.0040ad90
test eax, eax
setne byte [ebp - 0xd]
push ebx
call dword [sym.imp.KERNEL32.dll_FreeResource]
lea ecx, [ebp + 0x1c]
call fcn.00402170
test eax, eax
jle 0x40b350
push edi
call dword [sym.imp.KERNEL32.dll_FreeLibrary]
lea ecx, [ebp + 8]
mov byte [ebp - 4], 0
call fcn.004010d0
lea ecx, [ebp + 0x1c]
mov dword [ebp - 4], 0xffffffff
call fcn.004010d0
mov al, byte [ebp - 0xd]
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 0x28