Function at 0x401000
Capabilities:
Create process on windows
Extract resource via kernel32 functions
Get common file path
Write and execute a file
Write file on windows

Disassembly:
push ebp
mov ebp, esp
mov eax, 0x1e8c
call fcn.0040d970
mov eax, dword [0x415004]
xor eax, ebp
mov dword [ebp - 4], eax
push ebx
push esi
push edi
lea eax, [ebp - 0x1534]
push eax
push 0x105
call dword [sym.imp.KERNEL32.dll_GetTempPathW]
mov esi, dword [sym.imp.KERNEL32.dll_GetModuleFileNameA]
lea eax, [ebp - 0x1728]
push 0x1f4
push eax
push 0
call esi
push 0x1f4
lea eax, [ebp - 0x388]
push eax
push 0
call esi
lea eax, [ebp - 0x388]
lea edx, [eax + 1]
nop dword [eax + eax]
mov cl, byte [eax]
inc eax
test cl, cl
jne 0x401060
sub eax, edx
lea ecx, [eax - 1]
test ecx, ecx
je 0x40107f
cmp byte [ebp + ecx - 0x388], 0x5c
je 0x40107f
sub ecx, 1
jne 0x401070
test ecx, ecx
lea eax, [ecx + 1]
cmove eax, ecx
lea ecx, [ebp - 0x388]
add eax, ecx
push eax
mov eax, ecx
push 0x1f4
push eax
call fcn.004030a5
push 0x190
lea eax, [ebp - 0x1534]
push eax
push 0x190
lea eax, [ebp - 0x194]
push eax
lea eax, [ebp - 0x1e38]
push eax
call fcn.004034d0
lea eax, [ebp - 0x194]
push eax
lea eax, [ebp - 0x6a8]
push 0x190
push eax
call fcn.004030a5
lea eax, [ebp - 0x194]
push eax
lea eax, [ebp - 0x9c8]
push 0x190
push eax
call fcn.004030a5
lea eax, [ebp - 0x194]
push eax
lea eax, [ebp - 0xb58]
push 0x190
push eax
call fcn.004030a5
add esp, 0x44
lea eax, [ebp - 0x194]
push eax
lea eax, [ebp - 0xce8]
push 0x190
push eax
call fcn.004030a5
lea eax, [ebp - 0x194]
push eax
lea eax, [ebp - 0xe78]
push 0x190
push eax
call fcn.004030a5
lea eax, [ebp - 0x194]
push eax
lea eax, [ebp - 0x1008]
push 0x190
push eax
call fcn.004030a5
lea eax, [ebp - 0x194]
push eax
lea eax, [ebp - 0x838]
push 0x190
push eax
call fcn.004030a5
lea eax, [ebp - 0x194]
push eax
lea eax, [ebp - 0x1198]
push 0x190
push eax
call fcn.004030a5
lea eax, [ebp - 0x194]
push eax
lea eax, [ebp - 0x1328]
push 0x190
push eax
call fcn.004030a5
add esp, 0x48
lea eax, [ebp - 0x194]
push eax
lea eax, [ebp - 0x518]
push 0x190
push eax
call fcn.004030a5
lea eax, [ebp - 0x388]
push eax
lea eax, [ebp - 0x518]
push 0x190
push eax
call fcn.004034f0
push 0x4139ec
lea eax, [ebp - 0x6a8]
push 0x190
push eax
call fcn.004034f0
push 0x4139fc
lea eax, [ebp - 0x194]
push 0x190
push eax
call fcn.004034f0
push 0x413a08
lea eax, [ebp - 0x838]
push 0x190
push eax
call fcn.004034f0
push 0x413a14
lea eax, [ebp - 0x9c8]
push 0x190
push eax
call fcn.004034f0
add esp, 0x48
lea eax, [ebp - 0xb58]
push 0x413a24
push 0x190
push eax
call fcn.004034f0
push 0x413a30
lea eax, [ebp - 0xce8]
push 0x190
push eax
call fcn.004034f0
push 0x413a48
lea eax, [ebp - 0xe78]
push 0x190
push eax
call fcn.004034f0
push str.keyConfigurator.luax
lea eax, [ebp - 0x1008]
push 0x190
push eax
call fcn.004034f0
push str.FrankenKonnekt.luax
lea eax, [ebp - 0x1198]
push 0x190
push eax
call fcn.004034f0
push 0x413a7c
lea eax, [ebp - 0x1328]
push 0x190
push eax
call fcn.004034f0
add esp, 0x48
push 0x413a84
push 0x86
push 0
call dword [sym.imp.KERNEL32.dll_FindResourceW]
mov esi, eax
push esi
push 0
call dword [sym.imp.KERNEL32.dll_LoadResource]
push eax
call dword [sym.imp.KERNEL32.dll_LockResource]
mov ebx, dword [sym.imp.KERNEL32.dll_SizeofResource]
mov edi, eax
push esi
push 0
call ebx
mov esi, eax
lea eax, [ebp - 0x6a8]
push 0x4139e8
push eax
lea eax, [ebp - 0x1e34]
push eax
call fcn.00402cd8
push dword [ebp - 0x1e34]
push esi
push 1
push edi
call fcn.00402f57
push dword [ebp - 0x1e34]
call fcn.00403025
add esp, 0x20
push 0x413a84
push 0x87
push 0
call dword [sym.imp.KERNEL32.dll_FindResourceW]
mov esi, eax
push esi
push 0
call dword [sym.imp.KERNEL32.dll_LoadResource]
push eax
call dword [sym.imp.KERNEL32.dll_LockResource]
push esi
push 0
mov edi, eax
call ebx
mov esi, eax
lea eax, [ebp - 0x194]
push 0x4139e8
push eax
lea eax, [ebp - 0x1e34]
push eax
call fcn.00402cd8
push dword [ebp - 0x1e34]
push esi
push 1
push edi
call fcn.00402f57
push dword [ebp - 0x1e34]
call fcn.00403025
add esp, 0x20
push 0x413a84
push 0x98
push 0
call dword [sym.imp.KERNEL32.dll_FindResourceW]
mov esi, eax
push esi
push 0
call dword [sym.imp.KERNEL32.dll_LoadResource]
push eax
call dword [sym.imp.KERNEL32.dll_LockResource]
push esi
push 0
mov edi, eax
call ebx
mov esi, eax
lea eax, [ebp - 0x838]
push 0x4139e8
push eax
lea eax, [ebp - 0x1e34]
push eax
call fcn.00402cd8
push dword [ebp - 0x1e34]
push esi
push 1
push edi
call fcn.00402f57
push dword [ebp - 0x1e34]
call fcn.00403025
add esp, 0x20
push 0x413a84
push 0x8e
push 0
call dword [sym.imp.KERNEL32.dll_FindResourceW]
mov esi, eax
push esi
push 0
call dword [sym.imp.KERNEL32.dll_LoadResource]
push eax
call dword [sym.imp.KERNEL32.dll_LockResource]
push esi
push 0
mov edi, eax
call ebx
mov esi, eax
push 0x4139e8
lea eax, [ebp - 0x9c8]
push eax
lea eax, [ebp - 0x1e34]
push eax
call fcn.00402cd8
push dword [ebp - 0x1e34]
push esi
push 1
push edi
call fcn.00402f57
push dword [ebp - 0x1e34]
call fcn.00403025
add esp, 0x20
push 0x413a84
push 0x90
push 0
call dword [sym.imp.KERNEL32.dll_FindResourceW]
mov esi, eax
push esi
push 0
call dword [sym.imp.KERNEL32.dll_LoadResource]
push eax
call dword [sym.imp.KERNEL32.dll_LockResource]
push esi
push 0
mov edi, eax
call ebx
mov esi, eax
lea eax, [ebp - 0xb58]
push 0x4139e8
push eax
lea eax, [ebp - 0x1e34]
push eax
call fcn.00402cd8
push dword [ebp - 0x1e34]
push esi
push 1
push edi
call fcn.00402f57
push dword [ebp - 0x1e34]
call fcn.00403025
add esp, 0x20
push 0x413a84
push 0x8f
push 0
call dword [sym.imp.KERNEL32.dll_FindResourceW]
mov esi, eax
push esi
push 0
call dword [sym.imp.KERNEL32.dll_LoadResource]
push eax
call dword [sym.imp.KERNEL32.dll_LockResource]
push esi
push 0
mov edi, eax
call ebx
mov esi, eax
lea eax, [ebp - 0xce8]
push 0x4139e8
push eax
lea eax, [ebp - 0x1e34]
push eax
call fcn.00402cd8
push dword [ebp - 0x1e34]
push esi
push 1
push edi
call fcn.00402f57
push dword [ebp - 0x1e34]
call fcn.00403025
add esp, 0x20
push 0x413a84
push 0x91
push 0
call dword [sym.imp.KERNEL32.dll_FindResourceW]
mov esi, eax
push esi
push 0
call dword [sym.imp.KERNEL32.dll_LoadResource]
push eax
call dword [sym.imp.KERNEL32.dll_LockResource]
push esi
push 0
mov edi, eax
call ebx
mov esi, eax
lea eax, [ebp - 0xe78]
push 0x4139e8
push eax
lea eax, [ebp - 0x1e34]
push eax
call fcn.00402cd8
push dword [ebp - 0x1e34]
push esi
push 1
push edi
call fcn.00402f57
push dword [ebp - 0x1e34]
call fcn.00403025
add esp, 0x20
push 0x413a84
push 0x9a
push 0
call dword [sym.imp.KERNEL32.dll_FindResourceW]
mov esi, eax
push esi
push 0
call dword [sym.imp.KERNEL32.dll_LoadResource]
push eax
call dword [sym.imp.KERNEL32.dll_LockResource]
push esi
push 0
mov edi, eax
call ebx
mov esi, eax
lea eax, [ebp - 0x1008]
push 0x4139e8
push eax
lea eax, [ebp - 0x1e34]
push eax
call fcn.00402cd8
push dword [ebp - 0x1e34]
push esi
push 1
push edi
call fcn.00402f57
push dword [ebp - 0x1e34]
call fcn.00403025
add esp, 0x20
push 0x413a84
push 0x9c
push 0
call dword [sym.imp.KERNEL32.dll_FindResourceW]
mov esi, eax
push esi
push 0
call dword [sym.imp.KERNEL32.dll_LoadResource]
push eax
call dword [sym.imp.KERNEL32.dll_LockResource]
push esi
push 0
mov edi, eax
call ebx
mov esi, eax
lea eax, [ebp - 0x1198]
push 0x4139e8
push eax
lea eax, [ebp - 0x1e34]
push eax
call fcn.00402cd8
push dword [ebp - 0x1e34]
push esi
push 1
push edi
call fcn.00402f57
push dword [ebp - 0x1e34]
call fcn.00403025
add esp, 0x20
push 0x413a84
push 0x9d
push 0
call dword [sym.imp.KERNEL32.dll_FindResourceW]
mov esi, eax
push esi
push 0
call dword [sym.imp.KERNEL32.dll_LoadResource]
push eax
call dword [sym.imp.KERNEL32.dll_LockResource]
push esi
push 0
mov edi, eax
call ebx
mov esi, eax
lea eax, [ebp - 0x1328]
push 0x4139e8
push eax
lea eax, [ebp - 0x1e34]
push eax
call fcn.00402cd8
push dword [ebp - 0x1e34]
push esi
push 1
push edi
call fcn.00402f57
push dword [ebp - 0x1e34]
call fcn.00403025
add esp, 0x20
push 0x413a84
push 0x88
push 0
call dword [sym.imp.KERNEL32.dll_FindResourceW]
mov esi, eax
push esi
push 0
call dword [sym.imp.KERNEL32.dll_LoadResource]
push eax
call dword [sym.imp.KERNEL32.dll_LockResource]
push esi
push 0
mov edi, eax
call ebx
mov esi, eax
lea eax, [ebp - 0x518]
push 0x4139e8
push eax
lea eax, [ebp - 0x1e34]
push eax
call fcn.00402cd8
push dword [ebp - 0x1e34]
push esi
push 1
push edi
call fcn.00402f57
push dword [ebp - 0x1e34]
call fcn.00403025
push 0x190
lea eax, [ebp - 0x518]
push eax
lea eax, [ebp - 0x1a48]
push eax
call fcn.004036d2
push 0x44
lea eax, [ebp - 0x1e8c]
push 0
push eax
call fcn.00402480
push 0x190
lea eax, [ebp - 0x1728]
push eax
lea eax, [ebp - 0x1e30]
push eax
call fcn.004036d2
add esp, 0x44
lea eax, [ebp - 0x1e48]
push eax
lea eax, [ebp - 0x1e8c]
push eax
lea eax, [ebp - 0x1534]
push eax
push 0
push 0
push 0
push 0
push 0
lea eax, [ebp - 0x1e30]
push eax
lea eax, [ebp - 0x1a48]
push eax
call dword [sym.imp.KERNEL32.dll_CreateProcessW]
push 0xffffffffffffffff
push dword [ebp - 0x1e48]
call dword [sym.imp.KERNEL32.dll_WaitForSingleObject]
push dword [ebp - 0x1e48]
mov esi, dword [sym.imp.KERNEL32.dll_CloseHandle]
call esi
push dword [ebp - 0x1e44]
call esi
mov ecx, dword [ebp - 4]
mov eax, 1
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.0040179c
mov esp, ebp
pop ebp
ret 0x10