Function at 0x140085650
Capabilities:
Copy file
Create thread
Extract resource via kernel32 functions
Query environment variable

Disassembly:
mov qword [rsp + 0x20], rbx
push rbp
push rsi
push rdi
push r12
push r13
push r14
push r15
sub rsp, 0x240
mov rax, qword [section..data]
xor rax, rsp
mov qword [rsp + 0x230], rax
mov r15d, dword [r8 + 0x28]
mov r14, rcx
mov r13, r8
mov rdi, rdx
mov edx, 0x28b
imul r15d, ecx
xor ecx, ecx
lea r8d, [rcx + 0x16]
call qword [sym.imp.KERNEL32.dll_FindResourceA]
mov ebp, r14d
mov r12, rax
imul ebp, r15d
add ebp, ebp
sub ebp, eax
cmp r14d, r15d
ja 0x14008570d
xor ecx, ecx
mov edx, 0x218
lea r8d, [rcx + 0xf]
call qword [sym.imp.KERNEL32.dll_FindResourceA]
call qword [sym.imp.USER32.dll_GetForegroundWindow]
call qword [sym.imp.USER32.dll_GetActiveWindow]
call qword [sym.imp.USER32.dll_GetForegroundWindow]
call qword [sym.imp.USER32.dll_GetForegroundWindow]
xor ecx, ecx
lea r8d, [rcx + 1]
mov edx, 0x3d5
call qword [sym.imp.KERNEL32.dll_FindResourceA]
call qword [sym.imp.USER32.dll_GetActiveWindow]
lea rcx, [rsp + 0xf0]
mov edx, 0x104
call qword [sym.imp.KERNEL32.dll_FindFirstVolumeA]
call qword [sym.imp.USER32.dll_GetForegroundWindow]
call qword [sym.imp.KERNEL32.dll_GetCurrentThreadId]
call qword [sym.imp.KERNEL32.dll_GetEnvironmentStringsW]
mov r8d, ebp
mov rdx, rdi
mov rcx, rdi
call qword [sym.imp.KERNEL32.dll_CopyFileA]
mov dword [rsp + 0x74], eax
call qword [sym.imp.USER32.dll_GetActiveWindow]
call qword [sym.imp.KERNEL32.dll_GetCurrentThreadId]
mov dword [rsp + 0xdc], eax
call qword [sym.imp.USER32.dll_GetForegroundWindow]
mov rcx, r12
mov qword [rsp + 0x80], rax
call qword [sym.imp.KERNEL32.dll_LockResource]
lea ecx, [rbp*4]
sub ecx, dword [r13 + 0x18]
lea eax, [r14 + 2]
sub ecx, r12d
add eax, ecx
mov dword [rsp + 0x78], eax
call qword [sym.imp.USER32.dll_GetActiveWindow]
or rsi, 0xffffffffffffffff
mov rbx, rsi
inc rbx
cmp byte [rdi + rbx], 0
jne 0x140085775
lea eax, [r14 + 1]
lea rdx, [0x1400ed3b8]
mov r9d, 2
add al, al
xor ecx, ecx
sub al, byte [r13]
sub al, r15b
sub al, byte [rsp + 0x80]
sub al, r12b
add bl, al
add bl, bpl
movzx eax, bl
movzx r8d, bl
mov dword [rsp + 0x64], eax
call qword [sym.imp.KERNEL32.dll_EnumResourceNamesA]
mov rcx, rsi
mov dword [rsp + 0x70], eax
lea eax, [r14 + r14*4]
mov dword [rsp + 0x6c], eax
sub eax, ebp
add eax, 0xc
mov dword [rsp + 0x68], eax
inc rcx
cmp byte [rdi + rcx], 0
jne 0x1400857d2
movzx eax, cl
shl al, 2
add cl, al
movzx eax, byte [rsp + 0xdc]
add al, al
add cl, al
movzx eax, r14b
imul cl
add al, bl
mov byte [rsp + 0x60], al
call qword [sym.imp.USER32.dll_GetActiveWindow]
mov ecx, dword [rsp + 0x64]
mov qword [rsp + 0x88], rax
lea eax, [rcx*2 + 2]
cmp bl, al
jbe 0x1400858b7
mov ecx, r15d
call qword [sym.imp.KERNEL32.dll_GetStdHandle]
xor eax, eax
lea r8, [0x140001b00]
mov qword [rsp + 0x28], rax
lea r9d, [rax + 2]
xor edx, edx
xor ecx, ecx
mov dword [rsp + 0x20], eax
call qword [sym.imp.KERNEL32.dll_CreateThread]
xor ecx, ecx
mov edx, pe_nt_image_headers64
lea r8d, [rcx + 1]
call qword [sym.imp.KERNEL32.dll_FindResourceA]
lea rcx, [rsp + 0xf0]
xor edx, edx
mov r8d, 0x140
call fcn.1400e27d0
lea rdx, [rsp + 0xf0]
lea rcx, str.c0ret
call qword [sym.imp.KERNEL32.dll_FindFirstFileA]
call qword [sym.imp.USER32.dll_GetForegroundWindow]
mov rdx, r12
xor ecx, ecx
call qword [sym.imp.KERNEL32.dll_LoadResource]
mov edx, 0x7d
xor ecx, ecx
lea r8d, [rdx - 0x7c]
call qword [sym.imp.KERNEL32.dll_FindResourceA]
mov rcx, rdi
call qword [sym.imp.KERNEL32.dll_GetModuleHandleA]
mov rdx, r12
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_LoadResource]
call qword [sym.imp.USER32.dll_GetForegroundWindow]
xor ecx, ecx
mov edx, 0x3cf
lea r8d, [rcx + 1]
mov rbx, rax
mov qword [rsp + 0xa0], rax
call qword [sym.imp.KERNEL32.dll_FindResourceA]
mov edx, ebx
mov rbx, rsi
mov r8, rax
mov qword [rsp + 0x90], rax
imul edx, dword [rsp + 0x88]
sub edx, 2
mov ecx, edx
add ecx, dword [rsp + 0x80]
lea ecx, [rcx + rdx*4]
lea eax, [rcx + r14*4]
add eax, dword [rsp + 0x6c]
mov dword [rsp + 0x88], eax
nop
inc rbx
cmp byte [rdi + rbx], 0
jne 0x140085910
mov ecx, dword [rsp + 0x64]
imul ebx, r14d
xor edx, edx
mov qword [rsp + 0x58], rdx
mov qword [rsp + 0x50], rdx
mov qword [rsp + 0x48], rdx
lea eax, [r8 + r8*4]
lea rdx, str.c6a1
lea r8, str.c6a1
add eax, eax
mov r9d, ebp
sub ebx, eax
lea eax, [rcx*2 + 2]
sub ebx, eax
movsxd rax, dword [rsp + 0x70]
mov qword [rsp + 0x40], rax
mov dword [rsp + 0x38], r15d
mov dword [rsp + 0x30], ecx
mov dword [rsp + 0x28], 2
mov dword [rsp + 0x20], r14d
mov r14d, dword [rsp + 0x68]
sub ebx, r15d
mov ecx, r14d
sub ebx, 5
call qword [sym.imp.USER32.dll_CreateWindowExA]
lea r8, [0x140001b00]
mov qword [rsp + 0xa8], rax
xor eax, eax
xor edx, edx
mov qword [rsp + 0x28], rax
lea r9d, [rax + 1]
xor ecx, ecx
mov dword [rsp + 0x20], eax
call qword [sym.imp.KERNEL32.dll_CreateThread]
mov qword [rsp + 0x98], rax
call qword [sym.imp.KERNEL32.dll_GetCurrentThread]
call qword [sym.imp.KERNEL32.dll_GetLastError]
mov rdx, qword [rsp + 0x90]
xor ecx, ecx
mov dword [rsp + 0x68], eax
call qword [sym.imp.KERNEL32.dll_SizeofResource]
mov rdx, r12
xor ecx, ecx
mov dword [rsp + 0x6c], eax
call qword [sym.imp.KERNEL32.dll_LoadResource]
mov rdx, rax
nop word [rax + rax]
inc rsi
cmp byte [rdi + rsi], 0
jne 0x1400859f0
lea eax, [r14 + rax*2]
add edx, eax
movsx rax, byte [rsp + 0x60]
add edx, dword [rsp + 0x78]
lea ecx, [rax - 0x11]
lea ecx, [rax + rcx*4]
lea edx, [rcx + rdx*2]
movsxd rcx, dword [rsp + 0x68]
add edx, dword [r13 + 0x10]
movsx rax, cl
sub edx, eax
movsx rax, byte [rsp + 0x6c]
add edx, eax
sub edx, dword [rsp + 0x98]
sub edx, dword [rsp + 0xa8]
sub edx, ecx
mov ecx, dword [rsp + 0x64]
sub edx, dword [rsp + 0x88]
lea eax, [rcx*2 + 2]
sub edx, dword [rsp + 0x70]
sub edx, eax
sub edx, dword [rsp + 0x80]
sub edx, dword [rsp + 0x74]
sub edx, r12d
sub edx, ebp
lea eax, [rdx + rcx]
add eax, esi
add eax, dword [rsp + 0x90]
add eax, ebx
add eax, dword [rsp + 0xa0]
add eax, r15d
mov rcx, qword [rsp + 0x230]
xor rcx, rsp
call fcn.1400dd340
mov rbx, qword [rsp + 0x298]
add rsp, 0x240
pop r15
pop r14
pop r13
pop r12
pop rdi
pop rsi
pop rbp
ret