Function at 0x140003480
Capabilities:
Terminate process
Write file on windows

Disassembly:
push r15
push r14
push r13
push r12
push rbp
push rdi
push rsi
push rbx
sub rsp, 0x68
mov esi, ecx
mov rbx, rdx
cmp ecx, 3
jg 0x1400034d8
mov ecx, 0x69
mov r12d, 1
call sym.output_message
mov rcx, qword [rbx + 8]
call qword [sym.imp.ucrtbase.dll__wcsupr]
mov ecx, 0x6a
mov rdx, rax
call sym.output_message
mov eax, r12d
add rsp, 0x68
pop rbx
pop rsi
pop rdi
pop rbp
pop r12
pop r13
pop r14
pop r15
ret
mov rcx, qword [rbx + 0x10]
lea rdx, [rsp + 0x40]
lea r8, [rsp + 0x50]
call sym.parse_registry_key
test eax, eax
je 0x140003710
cmp esi, 4
je 0x14000371b
lea eax, [rsi - 5]
mov r12, qword [sym.imp.kernel32.dll_lstrcmpiW]
lea rdi, [rbx + 0x20]
xor ebp, ebp
lea r14, [rbx + rax*8 + 0x28]
xor r15d, r15d
lea r13, [0x1400091bc]
mov rsi, qword [rdi]
movzx eax, word [rsi]
and eax, 0xfffffffd
cmp ax, 0x2d
jne 0x14000349a
movzx ecx, word [rsi + 2]
mov edx, 0x79
call sym.is_char
test eax, eax
je 0x1400036b0
cmp word [rsi + 4], 0
jne 0x1400036b0
mov r15d, 1
add rdi, 8
cmp r14, rdi
jne 0x14000351b
mov r9d, ebp
or r9d, 0x20019
cmp ebp, 0x300
je 0x14000349a
lea rax, [rsp + 0x48]
xor r8d, r8d
mov rdx, qword [rsp + 0x50]
mov rcx, qword [rsp + 0x40]
mov qword [rsp + 0x20], rax
call qword [sym.imp.advapi32.dll_RegOpenKeyExW]
test eax, eax
jne 0x14000372b
mov rdx, qword [rsp + 0x50]
mov rcx, qword [rsp + 0x40]
inc r15d
call sym.get_long_key
mov r12, qword [rbx + 0x18]
xor r9d, r9d
xor r8d, r8d
mov dword [rsp + 0x28], pe_nt_image_headers64
mov rsi, rax
mov rbx, qword [sym.imp.kernel32.dll_CreateFileW]
mov edx, 0x40000000
mov qword [rsp + 0x30], 0
mov rcx, r12
mov dword [rsp + 0x20], r15d
call rbx
mov r13, rax
cmp rax, 0xffffffffffffffff
je 0x140003740
lea rdx, str.Windows_Registry_Editor_Version_5.00_r_n
mov eax, 0x57
mov r8, rdx
jmp 0x140003605
movzx eax, word [r8 + 2]
add r8, 2
test ax, ax
jne 0x140003600
sub r8d, edx
lea rbx, [rsp + 0x58]
lea rdx, str.Windows_Registry_Editor_Version_5.00_r_n
mov rcx, r13
mov r9, rbx
and r8d, 0xfffffffe
mov qword [rsp + 0x20], 0
mov rdi, qword [sym.imp.kernel32.dll_WriteFile]
call rdi
mov rdx, qword [rsp + 0x48]
mov r8, rsi
mov r9d, ebp
mov rcx, r13
call sym.export_registry_data
lea rdx, [0x14000915c]
mov r12d, eax
mov r8, rdx
mov eax, 0xa
jmp 0x140003665
movzx eax, word [r8 + 2]
add r8, 2
test ax, ax
jne 0x140003660
sub r8d, edx
mov r9, rbx
lea rdx, [0x14000915c]
mov rcx, r13
mov qword [rsp + 0x20], 0
and r8d, 0xfffffffe
call rdi
mov rcx, r13
call qword [sym.imp.kernel32.dll_CloseHandle]
mov rcx, qword [rsp + 0x48]
call qword [sym.imp.advapi32.dll_RegCloseKey]
jmp 0x1400034c1
add rsi, 2
mov rdx, r13
mov rcx, rsi
call r12
test eax, eax
jne 0x1400036e0
test ebp, 0x200
jne 0x14000349a
or ebp, 0x200
jmp 0x140003555
lea rdx, [0x1400091ca]
mov rcx, rsi
call r12
mov edx, ebp
and edx, 0x100
or edx, eax
jne 0x14000349a
or ebp, 0x100
jmp 0x140003555
mov r12d, 1
jmp 0x1400034c1
mov r9d, 0x20019
xor r15d, r15d
xor ebp, ebp
jmp 0x140003574
mov ecx, 0x6e
mov r12d, 1
call sym.output_message
jmp 0x1400034c1
mov rax, qword gs:[0x30]
mov r8d, dword [rax + 0x68]
cmp r8d, 0x50
jne 0x1400037a7
mov rdx, r12
mov ecx, 0x15e
call sym.ask_confirm
test eax, eax
jne 0x140003776
mov ecx, 0x6d
call sym.output_message
xor ecx, ecx
call qword [sym.imp.ucrtbase.dll_exit]
xor r9d, r9d
xor r8d, r8d
mov edx, 0x40000000
mov rcx, r12
mov qword [rsp + 0x30], 0
mov dword [rsp + 0x28], pe_nt_image_headers64
mov dword [rsp + 0x20], 2
call rbx
mov r13, rax
jmp 0x1400035ec
lea rax, [rsp + 0x58]
mov ecx, 0x1300
xor r9d, r9d
xor edx, edx
mov qword [rsp + 0x30], 0
mov dword [rsp + 0x28], 0
mov qword [rsp + 0x20], rax
call qword [sym.imp.kernel32.dll_FormatMessageW]
mov rcx, qword [rsp + 0x58]
mov rax, rcx
jmp 0x1400037e0
add rax, 2
cmp word [rax], 0
jne 0x1400037dc
sub rax, rcx
sar rax, 1
mov rdx, rax
call sym.output_writeconsole
mov rcx, qword [rsp + 0x58]
call qword [sym.imp.kernel32.dll_LocalFree]
mov ecx, 1
call qword [sym.imp.ucrtbase.dll_exit]
nop
nop
nop
nop
nop
nop