Function at 0x140040ba0
Capabilities:
Accept command line arguments
Create process on windows
Terminate process

Disassembly:
sub rsp, 0x128
mov rax, qword [0x140052040]
xor rax, rsp
mov qword [rsp + 0x110], rax
lea rcx, str.user32.dll
call qword [sym.imp.KERNEL32.dll_LoadLibraryA]
test rax, rax
je 0x140040f15
lea rcx, str.win32u.dll
call qword [sym.imp.KERNEL32.dll_LoadLibraryA]
test rax, rax
je 0x140040f15
lea rcx, str.user32.dll
call qword [sym.imp.KERNEL32.dll_GetModuleHandleA]
mov qword [0x1400529a0], rax
test rax, rax
je 0x140040f15
lea rcx, str.win32u.dll
call qword [sym.imp.KERNEL32.dll_GetModuleHandleA]
mov qword [0x1400529a8], rax
test rax, rax
je 0x140040f15
mov rcx, qword [0x1400529a0]
lea rdx, str.NtUserSendInput
call qword [sym.imp.KERNEL32.dll_GetProcAddress]
mov rcx, rax
test rax, rax
jne 0x140040c5b
mov rcx, qword [0x1400529a8]
lea rdx, str.NtUserSendInput
call qword [sym.imp.KERNEL32.dll_GetProcAddress]
mov rcx, rax
test rax, rax
je 0x140040f15
movups xmm0, xmmword [rcx]
mov qword [rsp + 0x130], rbx
mov qword [rsp + 0x138], rsi
xor esi, esi
movups xmmword [0x1400529f0], xmm0
mov qword [rsp + 0x120], rdi
mov edi, esi
movsd xmm1, qword [rcx + 0x10]
movsd qword [0x140052a00], xmm1
mov eax, dword [rcx + 0x18]
mov dword [0x140052a08], eax
movzx eax, word [rcx + 0x1c]
mov word [0x140052a0c], ax
call qword [sym.imp.KERNEL32.dll_GetCurrentProcess]
lea r8, [rsp + 0x70]
mov edx, 8
mov rcx, rax
call qword [sym.imp.ADVAPI32.dll_OpenProcessToken]
test eax, eax
je 0x140040dca
mov rcx, qword [rsp + 0x70]
lea rax, [rsp + 0x98]
mov r9d, 4
mov qword [rsp + 0x20], rax
lea r8, [rsp + 0x94]
mov edx, 0x1a
call qword [sym.imp.ADVAPI32.dll_GetTokenInformation]
test eax, eax
je 0x140040d00
mov ebx, dword [rsp + 0x98]
mov edi, 1
jmp 0x140040d08
call qword [sym.imp.KERNEL32.dll_GetLastError]
mov ebx, eax
mov rcx, qword [rsp + 0x70]
call qword [sym.imp.KERNEL32.dll_CloseHandle]
test edi, edi
je 0x140040dd2
cmp dword [rsp + 0x94], esi
jne 0x140040dda
lea rcx, [rsp + 0x60]
call fcn.14003d640
test eax, eax
jne 0x140040ef5
lea rcx, [rsp + 0xa0]
call qword [sym.imp.KERNEL32.dll_GetStartupInfoW]
call qword [sym.imp.KERNEL32.dll_GetCommandLineW]
lea rcx, [rsp + 0x78]
xor r9d, r9d
mov qword [rsp + 0x50], rcx
mov r8, rax
lea rcx, [rsp + 0xa0]
xor edx, edx
mov qword [rsp + 0x48], rcx
mov rcx, qword [rsp + 0x60]
mov qword [rsp + 0x40], rsi
mov qword [rsp + 0x38], rsi
mov dword [rsp + 0x30], esi
mov dword [rsp + 0x28], esi
mov qword [rsp + 0x20], rsi
call qword [sym.imp.ADVAPI32.dll_CreateProcessAsUserW]
test eax, eax
je 0x140040db5
mov rcx, qword [rsp + 0x78]
call qword [sym.imp.KERNEL32.dll_CloseHandle]
mov rcx, qword [rsp + 0x80]
call qword [sym.imp.KERNEL32.dll_CloseHandle]
xor ecx, ecx
call qword [sym.imp.KERNEL32.dll_ExitProcess]
call qword [sym.imp.KERNEL32.dll_GetLastError]
mov rcx, qword [rsp + 0x60]
mov ebx, eax
call qword [sym.imp.KERNEL32.dll_CloseHandle]
jmp 0x140040dd2
call qword [sym.imp.KERNEL32.dll_GetLastError]
mov ebx, eax
test ebx, ebx
jne 0x140040ef5
mov rcx, qword [0x1400529a0]
lea rdx, str.CreateWindowInBand
call qword [sym.imp.KERNEL32.dll_GetProcAddress]
mov qword [0x140052900], rax
test rax, rax
jne 0x140040e1e
mov rcx, qword [0x1400529a8]
lea rdx, str.CreateWindowInBand
call qword [sym.imp.KERNEL32.dll_GetProcAddress]
mov qword [0x140052900], rax
test rax, rax
je 0x140040ef5
mov qword [rsp + 0x30], rsi
lea rcx, str..DeviceManagerKyoto
mov dword [rsp + 0x28], esi
xor r9d, r9d
mov edx, 0xc0000000
mov dword [rsp + 0x20], 3
mov r8d, 3
call qword [sym.imp.KERNEL32.dll_CreateFileW]
mov rcx, rax
mov qword [0x140052960], rax
inc rax
test rax, 0xfffffffffffffffe
jne 0x140040e7f
lea rcx, str.Failed_to_initialize_driver_:__n
call fcn.140001210
mov ecx, 0xbb8
call qword [sym.imp.KERNEL32.dll_Sleep]
xor ecx, ecx
call qword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll_exit]
int3
mov eax, dword [0x140052914]
lea r8, [rsp + 0x60]
mov qword [rsp + 0x38], rsi
mov r9d, 0x10
mov dword [rsp + 0x60], eax
mov edx, 0x22cab4
lea rax, [rsp + 0x90]
mov qword [rsp + 0x30], rsi
mov dword [rsp + 0x28], esi
mov qword [rsp + 0x68], rax
mov byte [rsp + 0x90], sil
mov dword [rsp + 0x64], esi
mov qword [rsp + 0x20], rsi
call qword [sym.imp.KERNEL32.dll_DeviceIoControl]
cmp byte [rsp + 0x90], sil
jne 0x140040f35
lea rcx, str.Driver_CR3_verification_failed._n
call fcn.140001210
mov ecx, 0xbb8
call qword [sym.imp.KERNEL32.dll_Sleep]
xor ecx, ecx
call qword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll_exit]
int3
lea rcx, str.Failed_to_initialize_GUI_:__n
call fcn.140001210
mov ecx, 0xbb8
call qword [sym.imp.KERNEL32.dll_Sleep]
xor ecx, ecx
call qword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll_exit]
int3
lea rcx, str.Failed_to_initialize_input_:__n
call fcn.140001210
mov ecx, 0xbb8
call qword [sym.imp.KERNEL32.dll_Sleep]
xor ecx, ecx
call qword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll_exit]
int3
mov rsi, qword [rsp + 0x138]
mov rbx, qword [rsp + 0x130]
mov rdi, qword [rsp + 0x120]
mov rcx, qword [rsp + 0x110]
xor rcx, rsp
call fcn.140041b70
add rsp, 0x128
ret