Function at 0x14000ff30
Capabilities:
Accept command line arguments
Create process on windows
Extract resource via kernel32 functions
Set environment variable
Write and execute a file
Write file on windows

Disassembly:
push rbp
push r13
push r12
push rbx
sub rsp, 0x28
lea rbp, [rsp + 0x20]
lea r13, str.libgcc_s_dw2_1.dll
mov rcx, r13
call qword [sym.imp.KERNEL32.dll_GetModuleHandleA]
mov r12, rax
test rax, rax
je 0x1400017a0
mov rcx, r13
call qword [sym.imp.KERNEL32.dll_LoadLibraryA]
mov r13, qword [sym.imp.KERNEL32.dll_GetProcAddress]
lea rdx, str.__register_frame_info
mov rcx, r12
mov qword [0x140025040], rax
call r13
lea rdx, str.__deregister_frame_info
mov rcx, r12
mov rbx, rax
call r13
mov qword [0x14001e010], rax
test rbx, rbx
jne 0x1400017b5
lea rcx, [0x1400017d0]
add rsp, 0x28
pop rbx
pop r12
pop r13
pop rbp
jmp fcn.1400016c7
lea rax, [0x140001710]
lea rbx, [0x140001700]
mov qword [0x14001e010], rax
lea rdx, [0x140025060]
lea rcx, [section..eh_fram]
call rbx
jmp 0x140001787
push r15
push r14
push r13
push r12
push rbp
push rdi
push rsi
push rbx
sub rsp, 0x298
movaps xmmword [rsp + 0x280], xmm6
lea r12, str.TEMPonefile_PID_TIME
mov r8d, 0x1000
lea rcx, [0x140032100]
mov rdx, r12
call fcn.140008c00
test al, al
je 0x1400108d7
mov edx, 1
lea rcx, [0x140009630]
call qword [sym.imp.KERNEL32.dll_SetConsoleCtrlHandler]
test eax, eax
je 0x140010977
mov r8d, 0xa
xor ecx, ecx
mov edx, 0x1b
call qword [sym.imp.KERNEL32.dll_FindResourceA]
xor ecx, ecx
mov rdx, rax
mov r12, rax
call qword [sym.imp.KERNEL32.dll_LoadResource]
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_LockResource]
xor ecx, ecx
mov rdx, r12
mov qword [0x1400320f0], rax
call qword [sym.imp.KERNEL32.dll_SizeofResource]
mov esi, eax
mov rax, qword [0x1400320f0]
mov qword [0x1400320e8], rsi
cmp byte [rax + 1], 0x41
lea rdi, [rax + 3]
movzx ecx, byte [rax + 2]
setne dl
cmp byte [rax], 0x4b
mov qword [0x1400320f0], rdi
setne al
or dl, al
jne 0x14001096b
cmp cl, 0x59
jne 0x14001096b
mov qword [0x140036110], 0
mov ecx, 0x20000
call sub.msvcrt.dll_malloc
mov qword [0x140036130], rax
test rax, rax
je 0x1400108ea
mov ecx, 0x274b8
call sub.msvcrt.dll_malloc
mov r8, rax
test rax, rax
je 0x1400108df
mov qword [rax + 0x73b0], 0
pxor xmm0, xmm0
mov qword [rax + 0x73c8], 0
mov qword [rax + 0x72d8], 0
mov qword [rax + 0x73ec], 0
mov qword [rax + 0x73f8], 0
mov qword [rax + 0x7400], 0
mov qword [rax + 0x7420], 0
mov dword [rax + 0x73f4], 0
mov qword [rax + 0x7440], 0
mov dword [rax + 0x7448], 0
mov dword [rax + 0x7454], 0
mov qword [rax + 0x274b0], 0
movups xmmword [rax + 0x73a0], xmm0
movups xmmword [rax + 0x73d8], xmm0
xor eax, eax
cpuid
xor ecx, ecx
cmp eax, 6
ja 0x140010490
mov dword [r8 + 0x73d0], ecx
movdqa xmm6, xmmword [0x1400202e0]
lea rbp, [rsp + 0x180]
mov qword [r8 + 0x7410], 0x8000001
mov dword [r8 + 0x7458], 0
mov qword [r8 + 0x7388], 0
mov dword [r8 + 0x7390], 1
mov qword [0x140036108], r8
mov qword [0x140036110], rdi
mov qword [0x140036120], 0
mov qword [0x140036118], rsi
mov byte [0x1400320e0], 1
mov r14, qword [0x140036140]
lea r12, [0x1400318e0]
nop word [rax + rax]
mov rbx, qword [0x140036138]
xor r15d, r15d
mov rdi, rbp
mov esi, 2
nop word [rax + rax]
mov r8, rbx
sub r8, r14
jne 0x1400101e5
mov rcx, qword [0x140036120]
mov rdx, qword [0x140036118]
cmp rcx, rdx
setb al
or r15b, al
je 0x140010238
mov rcx, qword [0x140036108]
movups xmmword [0x140036138], xmm6
call fcn.14000ea50
mov rbx, qword [0x140036140]
cmp qword [0x140036138], rbx
sete r15b
cmp rax, 0xffffffffffffff88
ja 0x140010241
xor r14d, r14d
mov r8, rbx
mov qword [0x140036138], rbx
mov qword [0x140036140], 0
sub r8, r14
je 0x140010180
cmp r8, rsi
mov rdx, qword [0x140036130]
mov rcx, rdi
cmova r8, rsi
add rdx, r14
mov r13, r8
call sub.msvcrt.dll_memcpy
add r14, r13
add rdi, r13
mov qword [0x140036140], r14
sub rsi, r13
jne 0x140010178
movzx eax, word [rsp + 0x180]
mov word [r12], ax
test ax, ax
je 0x14001024d
add r12, 2
jmp 0x140010160
cmp rcx, rdx
je 0x140010178
lea rcx, str.Error__couldnt_decode_attached_data.
call fcn.1400094b0
lea rax, [0x1400318e0]
movzx ecx, word [rax]
test cx, cx
je 0x1400104a4
lea rax, [0x140032100]
xor esi, esi
lea r8, [0x140032100]
movzx edx, word [rax]
lea rax, [0x1400250a0]
mov word [0x1400250a0], si
lea r9, [rax + 0x2000]
test dx, dx
jne 0x140010299
jmp 0x1400102ad
cmp rax, r9
je 0x14001d388
add r8, 2
mov word [rax], dx
add rax, 2
movzx edx, word [r8]
test dx, dx
jne 0x140010290
xor ebx, ebx
mov word [rax], bx
lea rax, [0x1400250a0]
cmp word [rax], 0
je 0x140010484
mov edx, 0x1000
nop dword [rax + rax]
add rax, 2
sub rdx, 1
cmp word [rax], 0
jne 0x1400102d0
test rdx, rdx
je 0x1400109cc
mov dword [rax], 0x5c
lea rax, [0x1400250a0]
mov edx, 0x1000
cmp word [rax], 0
je 0x140010478
nop dword [rax + rax]
add rax, 2
sub rdx, 1
cmp word [rax], 0
jne 0x140010308
test rdx, rdx
je 0x1400109c7
lea r8, [0x1400318e0]
jmp 0x140010339
test rdx, rdx
je 0x1400109c2
add r8, 2
mov word [rax], cx
add rax, 2
sub rdx, 1
movzx ecx, word [r8]
test cx, cx
jne 0x140010330
xor r11d, r11d
cmp word [0x1400310e0], 0
mov word [rax], r11w
je 0x14001042c
mov edx, 8
mov rcx, rbp
call fcn.14000fcd0
mov r15, qword [rsp + 0x180]
call fcn.140012010
mov dword [rsp + 0x28], 0
xor r9d, r9d
mov r8d, 2
mov qword [rsp + 0x30], 0
mov edx, 0x40000000
lea rcx, [0x1400250a0]
mov dword [rsp + 0x20], 2
call qword [sym.imp.KERNEL32.dll_CreateFileW]
mov r12, rax
cmp rax, 0xffffffffffffffff
je 0x140010940
mov rdi, qword [sym.imp.KERNEL32.dll_WriteFile]
lea rsi, [0x1400270a0]
test r15, r15
je 0x14001041e
nop dword [rax]
mov ebx, 0x8000
mov rcx, rsi
cmp r15, rbx
cmovbe rbx, r15
mov rdx, rbx
call fcn.14000fcd0
mov r9, rbp
mov r8d, ebx
mov rdx, rsi
mov dword [rsp + 0x180], 0
mov rcx, r12
mov qword [rsp + 0x20], 0
call rdi
test eax, eax
je 0x140010922
sub r15, rbx
jne 0x1400103d8
mov rcx, r12
call qword [sym.imp.KERNEL32.dll_CloseHandle]
jmp 0x140010149
lea rax, [0x1400250a0]
lea rdx, [0x1400310e0]
movzx ecx, word [rax]
lea r8, [rax + 0x2000]
test cx, cx
jne 0x140010459
jmp 0x14001046c
cmp rax, r8
je 0x14001d388
add rax, 2
mov word [rdx], cx
add rdx, 2
movzx ecx, word [rax]
test cx, cx
jne 0x140010450
xor r10d, r10d
mov word [rdx], r10w
jmp 0x140010366
lea rax, [0x1400250a0]
jmp 0x14001031f
lea rax, [0x1400250a0]
jmp 0x1400102e7
mov eax, 7
cpuid
shr ebx, 8
mov ecx, ebx
and ecx, 1
jmp 0x1400100df
mov r12, qword [0x140036108]
test r12, r12
je 0x14001055d
cmp qword [r12 + 0x73c8], 0
jne 0x14001055d
mov r13, qword [r12 + 0x73d8]
mov rbx, qword [r12 + 0x73a8]
mov r14, qword [r12 + 0x73b0]
test r13, r13
je 0x140010511
mov rdx, qword [r13]
mov rsi, qword [r13 + 0x6ac8]
mov r15, qword [r13 + 0x6ad0]
test rdx, rdx
je 0x14001090c
test rsi, rsi
je 0x1400109b5
mov rcx, r15
call rsi
mov rdx, r13
mov rcx, r15
call rsi
mov rdx, qword [r12 + 0x73f8]
pxor xmm0, xmm0
mov dword [r12 + 0x73f0], 0
movups xmmword [r12 + 0x73d8], xmm0
test rdx, rdx
je 0x1400108f6
test rbx, rbx
je 0x1400109a8
mov rcx, r14
call rbx
mov qword [r12 + 0x73f8], 0
mov rdx, r12
mov rcx, r14
call rbx
mov rcx, qword [0x140036130]
lea rsi, [rsp + 0x100]
lea r12, [rsp + 0xb0]
call sub.msvcrt.dll_free
call qword [sym.imp.KERNEL32.dll_GetCurrentProcessId]
lea r8, [0x14001f37c]
mov edx, pe_nt_image_headers64
mov rcx, rsi
mov r9d, eax
call fcn.140001a50
xor r9d, r9d
movzx r15d, byte [rsp + 0x100]
mov word [rsp + 0x180], r9w
test r15b, r15b
je 0x140010640
mov r13d, pe_nt_image_headers64
mov rdi, rbp
mov rbx, rbp
mov r14d, 1
lea r12, [rsp + 0xb0]
mov rcx, rbx
add rdi, 2
call sub.msvcrt.dll_wcslen
mov rdx, r12
mov r8d, 2
mov byte [rsp + 0xb0], r15b
lea rcx, [rbx + rax*2]
mov byte [rsp + 0xb1], 0
call sub.msvcrt.dll_mbstowcs
mov rdx, r13
mov rax, r14
sub r13, 1
sub rax, rdx
movzx r15d, byte [rbp + rax]
test r15b, r15b
je 0x140010640
cmp word [rdi], 0
mov rax, r13
mov rbx, rdi
je 0x14001062e
add rbx, 2
sub rax, 1
cmp word [rbx], 0
jne 0x140010620
test rax, rax
jne 0x1400105ce
jmp 0x14001d388
xor r8d, r8d
lea r15, [rsp + 0x60]
mov r13d, 0x28
mov edx, 0x4e
mov word [rsp + 0x60], r8w
mov rbx, r15
mov rdi, r15
lea r14, [0x14001f654]
mov rcx, rbx
mov byte [rsp + 0x5f], dl
add rdi, 2
call sub.msvcrt.dll_wcslen
movzx edx, byte [rsp + 0x5f]
mov r8d, 2
mov byte [rsp + 0xb1], 0
lea rcx, [rbx + rax*2]
mov byte [rsp + 0xb0], dl
mov rdx, r12
call sub.msvcrt.dll_mbstowcs
mov rdx, r13
mov eax, 1
sub r13, 1
sub rax, rdx
movzx edx, byte [r14 + rax]
test dl, dl
je 0x1400106e0
cmp word [rdi], 0
mov rax, r13
mov rbx, rdi
je 0x1400106ce
add rbx, 2
sub rax, 1
cmp word [rbx], 0
jne 0x1400106c0
test rax, rax
jne 0x140010666
jmp 0x14001d388
lea r14, [0x14002f0c0]
mov rdx, rbp
mov rcx, r15
mov r13, qword [sym.imp.KERNEL32.dll_SetEnvironmentVariableW]
call r13
mov rdx, r14
xor ecx, ecx
mov r8d, 0x1001
call qword [sym.imp.KERNEL32.dll_GetModuleFileNameW]
cmp word [0x14002f0c0], 0
mov rax, r14
lea rdx, [r14 + 0x2002]
je 0x140010730
add rax, 2
cmp word [rax], 0
je 0x140010730
cmp rax, rdx
jne 0x14001071c
jmp 0x14001d388
xor ecx, ecx
xor edx, edx
mov rbx, r12
mov r15d, 0x28
mov word [rsp + 0xb0], cx
mov rdi, r12
mov word [rax], dx
mov edx, 0x4e
mov rcx, rbx
mov byte [rsp + 0x5f], dl
add rdi, 2
call sub.msvcrt.dll_wcslen
movzx edx, byte [rsp + 0x5f]
mov r8d, 2
mov byte [rsp + 0x181], 0
lea rcx, [rbx + rax*2]
mov byte [rsp + 0x180], dl
mov rdx, rbp
call sub.msvcrt.dll_mbstowcs
mov rdx, r15
sub r15, 1
mov eax, 1
sub rax, rdx
lea r10, [0x14001f66a]
movzx edx, byte [r10 + rax]
test dl, dl
je 0x1400107d0
cmp word [rdi], 0
mov rax, r15
mov rbx, rdi
je 0x1400107c6
nop dword [rax]
add rbx, 2
sub rax, 1
cmp word [rbx], 0
jne 0x1400107b8
test rax, rax
jne 0x140010750
jmp 0x14001d388
mov rdx, r14
mov rcx, r12
mov rdi, rbp
call r13
xor eax, eax
mov ecx, 0xd
rep stosq qword [rdi], rax
mov dword [rsp + 0x180], 0x68
call qword [sym.imp.KERNEL32.dll_GetCommandLineW]
xor r9d, r9d
xor r8d, r8d
mov qword [rsp + 0x48], rsi
mov qword [rsp + 0x40], rbp
mov rdx, rax
lea rcx, [0x1400310e0]
mov qword [rsp + 0x38], 0
mov qword [rsp + 0x30], 0
mov dword [rsp + 0x28], 0x20
mov dword [rsp + 0x20], 0
call qword [sym.imp.KERNEL32.dll_CreateProcessW]
test eax, eax
je 0x140010983
mov rcx, qword [rsp + 0x108]
mov rbx, qword [sym.imp.KERNEL32.dll_CloseHandle]
call rbx
mov rcx, qword [rsp + 0x100]
mov dword [rsp + 0xb0], 0
mov qword [0x14002f0a0], rcx
test rcx, rcx
je 0x1400108af
mov edx, 0xffffffff
call qword [sym.imp.KERNEL32.dll_WaitForSingleObject]
mov rcx, qword [0x14002f0a0]
mov rdx, r12
call qword [sym.imp.KERNEL32.dll_GetExitCodeProcess]
test eax, eax
jne 0x14001089b
mov dword [rsp + 0xb0], 1
mov rcx, qword [0x14002f0a0]
call rbx
mov qword [0x14002f0a0], 0
call fcn.1400094d0
mov eax, dword [rsp + 0xb0]
movaps xmm6, xmmword [rsp + 0x280]
add rsp, 0x298
pop rbx
pop rsi
pop rdi
pop rbp
pop r12
pop r13
pop r14
pop r15
ret
mov rcx, r12
call fcn.140009410
mov qword [0x140036108], 0
lea rcx, str.Error__couldnt_allocate_memory.
call fcn.1400094b0
test rbx, rbx
jne 0x140010555
mov rcx, r12
call sub.msvcrt.dll_free
jmp 0x14001055d
test rsi, rsi
jne 0x140010509
mov rcx, r13
call sub.msvcrt.dll_free
jmp 0x140010511
call qword [sym.imp.KERNEL32.dll_GetLastError]
lea rcx, str.Error__couldnt_unpack_file_to_target_path.
mov edx, eax
call fcn.140009440
mov ecx, 2
call sub.msvcrt.dll_exit
mov ecx, 2
call qword [fcn.14001c9d0]
lea r8, [0x1400250a0]
lea rdx, str.Error__failed_to_open__ls_for_writing._n
mov rcx, rax
call fcn.140001a20
mov ecx, 2
call sub.msvcrt.dll_exit
lea rcx, str.Error__couldnt_find_attached_data_header.
call fcn.1400094b0
lea rcx, str.Error__failed_to_register_signal_handler.
call fcn.1400094b0
call qword [sym.imp.KERNEL32.dll_GetLastError]
lea rcx, str.Error__couldnt_launch_child
mov edx, eax
call fcn.140009440
mov ecx, 2
call sub.msvcrt.dll_exit
nop dword [rax]
mov rcx, rdx
call sub.msvcrt.dll_free
jmp 0x1400108ff
mov rcx, rdx
call sub.msvcrt.dll_free
jmp 0x140010915
jmp 0x14001d388
jmp 0x14001d388
jmp 0x14001d388
call sub.msvcrt.dll_abort
nop
nop
nop
call sub.msvcrt.dll_abort
nop
call sub.msvcrt.dll_abort
nop
nop
nop
nop
nop
jmp 0x140001720