Function at 0x1400182b8
Capabilities:
Create directory
Delete file
Extract resource via kernel32 functions
Get common file path
Write file on windows

Disassembly:
mov qword [rsp + 0x18], rbx
push rbp
push rsi
push rdi
push r12
push r13
push r14
push r15
sub rsp, 0x460
mov rax, qword [0x14028b7c8]
xor rax, rsp
mov qword [rsp + 0x450], rax
mov r13d, edx
mov rdi, rcx
call fcn.140017e48
lea rcx, [rdi + 0x61c]
xor edx, edx
call qword [sym.imp.KERNEL32.dll_CreateDirectoryA]
xor ebx, ebx
mov r15d, 0x200
cmp eax, ebx
jne 0x14001832a
call qword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 0xb7
je 0x14001832a
lea r8, [rdi + 0x41c]
lea rcx, [rdi + 0x61c]
mov rdx, r15
call fcn.140158644
lea rcx, [rdi + 0x61c]
call fcn.140159970
lea rbp, [rdi + 0xa1c]
mov rdx, r15
cmp eax, ebx
lea rcx, [rsp + 0x50]
jle 0x140018376
cdqe
lea r9, [rdi + 0x61c]
mov qword [rsp + 0x20], rbp
cmp byte [rax + rdi + 0x61b], 0x5c
lea r8, str._s_s
je 0x14001836f
lea r8, [0x1401cec2c]
call fcn.140044464
jmp 0x140018385
lea r8, [0x1401cba80]
mov r9, rbp
call fcn.140044464
lea r8, [rsp + 0x50]
lea rdx, str._dwExtract_SYS__Extract__s_n
mov rcx, rdi
call fcn.140016c48
mov qword [rsp + 0x30], rbx
lea rcx, [rsp + 0x50]
xor r9d, r9d
xor r8d, r8d
mov edx, 0x80000000
mov dword [rsp + 0x28], 0x80
mov dword [rsp + 0x20], 3
call qword [sym.imp.KERNEL32.dll_CreateFileA]
lea r8, [rsp + 0x50]
mov rcx, rdi
mov r12, rax
cmp rax, 0xffffffffffffffff
je 0x1400183e6
lea rdx, str._dwExtract_SYS__File__s_does_already_exist_n
call fcn.140016c48
jmp 0x140018690
lea rdx, str._dwExtract_SYS__File__s_successfully_created_n
call fcn.140016c48
mov ecx, r13d
call fcn.140017fbc
cmp eax, ebx
jne 0x14001841a
lea rdx, str._dwExtract_SYS__Wrong_res_ID___X_n
mov r8d, r13d
mov rcx, rdi
call fcn.140016c48
mov eax, 0x5007
jmp 0x14001869b
cmp byte [rdi + 0x81c], bl
je 0x140018459
lea r8, [rdi + 0x81c]
lea rdx, str._dwExtract_SYS__host_name__s_n
mov rcx, rdi
call fcn.140016c48
lea r8, [rdi + 0x81c]
lea rcx, [rsp + 0x250]
mov rdx, r15
call fcn.140158644
lea rcx, [rsp + 0x250]
jmp 0x14001845b
xor ecx, ecx
call qword [sym.imp.KERNEL32.dll_GetModuleHandleA]
mov r12, rax
cmp rax, rbx
jne 0x140018490
call qword [sym.imp.KERNEL32.dll_GetLastError]
lea r8, [rsp + 0x250]
lea rdx, str._dwExtract_SYS__GetModuleHandle_on__s_failed__error_d_n
mov r9d, eax
mov rcx, rdi
mov ebx, eax
call fcn.140016c48
jmp 0x140018699
movzx edx, r13w
mov r8d, 0xa
mov rcx, r12
call qword [sym.imp.KERNEL32.dll_FindResourceA]
mov r13, rax
cmp rax, rbx
jne 0x1400184ca
call qword [sym.imp.KERNEL32.dll_GetLastError]
lea rdx, str._dwExtract_SYS__FindResource_failed__error_d_n
mov r8d, eax
mov rcx, rdi
mov ebx, eax
call fcn.140016c48
jmp 0x140018699
mov rdx, rax
mov rcx, r12
call qword [sym.imp.KERNEL32.dll_LoadResource]
cmp rax, rbx
jne 0x1400184ea
call qword [sym.imp.KERNEL32.dll_GetLastError]
lea rdx, str._dwExtract_SYS__LoadResource_failed__error_d_n
jmp 0x1400184b8
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_LockResource]
mov rdx, r13
mov rcx, r12
mov r14, rax
call qword [sym.imp.KERNEL32.dll_SizeofResource]
mov r13d, eax
cmp eax, ebx
jne 0x140018518
call qword [sym.imp.KERNEL32.dll_GetLastError]
lea rdx, str._dwExtract_SYS__Size_of_resousrce__0__error_d_n
jmp 0x1400184b8
mov qword [rsp + 0x30], rbx
lea rcx, [rsp + 0x50]
xor r9d, r9d
xor r8d, r8d
mov edx, 0xc0000000
mov dword [rsp + 0x28], 0x80
mov dword [rsp + 0x20], 2
call qword [sym.imp.KERNEL32.dll_CreateFileA]
mov r12, rax
cmp rax, 0xffffffffffffffff
jne 0x140018659
call qword [sym.imp.KERNEL32.dll_GetLastError]
lea r8, [rsp + 0x50]
lea rdx, str._dwExtract_SYS__Unable_to_create_the_file__s__error_d__1__n
mov r9d, eax
mov rcx, rdi
call fcn.140016c48
lea rcx, [rsp + 0x50]
call qword [sym.imp.KERNEL32.dll_DeleteFileA]
mov qword [rsp + 0x30], rbx
lea rcx, [rsp + 0x50]
xor r9d, r9d
xor r8d, r8d
mov edx, 0xc0000000
mov dword [rsp + 0x28], 0x80
mov dword [rsp + 0x20], 2
call qword [sym.imp.KERNEL32.dll_CreateFileA]
mov r12, rax
cmp rax, 0xffffffffffffffff
jne 0x140018659
lea rdx, [rsp + 0x50]
mov ecx, r15d
call qword [sym.imp.KERNEL32.dll_GetTempPathA]
cmp eax, ebx
jbe 0x140018659
lea r8, [0x1401cec70]
lea rcx, [rsp + 0x50]
mov rdx, r15
call fcn.14004453c
lea rcx, [rsp + 0x50]
mov r8, rbp
mov rdx, r15
call fcn.14004453c
mov qword [rsp + 0x30], rbx
lea rcx, [rsp + 0x50]
xor r9d, r9d
xor r8d, r8d
mov edx, 0xc0000000
mov dword [rsp + 0x28], 0x80
mov dword [rsp + 0x20], 2
call qword [sym.imp.KERNEL32.dll_CreateFileA]
mov r12, rax
cmp rax, 0xffffffffffffffff
jne 0x140018635
call qword [sym.imp.KERNEL32.dll_GetLastError]
lea r8, [rsp + 0x50]
lea rdx, str._dwExtract_SYS__Unable_to_create_the_file__s__error_d__2__n
jmp 0x14001847e
lea r8, [rsp + 0x50]
lea rdx, str._dwExtract_SYS__File__s_successfully_created__2_._n
mov rcx, rdi
call fcn.140016c48
lea rdx, [rdi + 0x61c]
mov ecx, r15d
call qword [sym.imp.KERNEL32.dll_GetTempPathA]
lea r9, [rsp + 0x40]
mov r8d, r13d
mov rdx, r14
mov rcx, r12
mov qword [rsp + 0x20], rbx
call qword [sym.imp.KERNEL32.dll_WriteFile]
cmp eax, ebx
jne 0x140018690
call qword [sym.imp.KERNEL32.dll_GetLastError]
lea rdx, str._dwExtract_SYS__WriteFile_failed__error_d__2__n
mov rcx, rdi
mov r8d, eax
mov ebx, eax
call fcn.140016c48
mov rcx, r12
call qword [sym.imp.KERNEL32.dll_CloseHandle]
mov eax, ebx
mov rcx, qword [rsp + 0x450]
xor rcx, rsp
call fcn.140156fd0
mov rbx, qword [rsp + 0x4b0]
add rsp, 0x460
pop r15
pop r14
pop r13
pop r12
pop rdi
pop rsi
pop rbp
ret