Function at 0x14003c680
Capabilities:
Get session user name

Disassembly:
mov qword [rsp + 0x10], rbx
mov qword [rsp + 0x18], rsi
mov qword [rsp + 0x20], rdi
push r12
push r14
push r15
sub rsp, 0x2c0
mov rax, qword [0x1400ba180]
xor rax, rsp
mov qword [rsp + 0x2b0], rax
mov rdi, rcx
mov qword [rsp + 0x78], rcx
xor r15d, r15d
mov dword [rsp + 0x30], r15d
xorps xmm0, xmm0
movups xmmword [rcx], xmm0
mov qword [rcx + 0x10], r15
mov qword [rcx + 0x18], reloc.WS2_32.dll_ntohs
mov byte [rcx], r15b
mov dword [rsp + 0x30], 1
mov dword [rsp + 0xe0], 0x101
lea rdx, [rsp + 0xe0]
lea rcx, [rsp + 0x1a0]
call qword [sym.imp.ADVAPI32.dll_GetUserNameA]
test eax, eax
je 0x14003cd06
xorps xmm0, xmm0
movups xmmword [rsp + 0x58], xmm0
mov qword [rsp + 0x68], r15
mov qword [rsp + 0x70], r15
lea rax, [rsp + 0x1a0]
mov r12, 0xffffffffffffffff
mov rbx, r12
nop dword [rax + rax]
inc rbx
cmp byte [rax + rbx], 0
jne 0x14003c730
movabs r14, 0x7fffffffffffffff
cmp rbx, r14
ja 0x14003ccd2
mov qword [rsp + 0x70], reloc.WS2_32.dll_ntohs
cmp rbx, 0xf
ja 0x14003c77f
mov qword [rsp + 0x68], rbx
mov r8, rbx
lea rdx, [rsp + 0x1a0]
lea rcx, [rsp + 0x58]
call sub.VCRUNTIME140.dll_memcpy
mov byte [rsp + rbx + 0x58], 0
jmp 0x14003c81e
mov rax, rbx
or rax, 0xf
cmp rax, r14
jbe 0x14003c7b4
movabs rax, 0x8000000000000000
add rax, 0x27
mov rcx, rax
call fcn.14008e1a4
test rax, rax
je 0x14003c7df
lea rsi, [rax + 0x27]
and rsi, 0xffffffffffffffe0
mov qword [rsi - 8], rax
jmp 0x14003c7f8
mov ecx, reloc.WS2_32.dll_shutdown
cmp rax, rcx
cmovb rax, rcx
mov r14, rax
lea rcx, [rax + 1]
cmp rcx, 0x1000
jb 0x14003c7e6
lea rax, [rcx + 0x27]
cmp rax, rcx
jbe 0x14003ccd7
jmp 0x14003c799
call qword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll__invalid_parameter_noinfo_noreturn]
int3
test rcx, rcx
je 0x14003c7f5
call fcn.14008e1a4
mov rsi, rax
jmp 0x14003c7f8
mov rsi, r15
mov qword [rsp + 0x58], rsi
mov qword [rsp + 0x68], rbx
mov qword [rsp + 0x70], r14
mov r8, rbx
lea rdx, [rsp + 0x1a0]
mov rcx, rsi
call sub.VCRUNTIME140.dll_memcpy
mov byte [rsi + rbx], 0
lea r8, str.wmic_useraccount_where_name_
xor edx, edx
lea rcx, [rsp + 0x58]
call fcn.14003f0c0
xorps xmm0, xmm0
movups xmmword [rsp + 0x38], xmm0
mov qword [rsp + 0x48], r15
mov qword [rsp + 0x50], r15
movups xmm0, xmmword [rax]
movups xmmword [rsp + 0x38], xmm0
movups xmm1, xmmword [rax + 0x10]
movups xmmword [rsp + 0x48], xmm1
mov qword [rax + 0x10], r15
mov qword [rax + 0x18], reloc.WS2_32.dll_ntohs
mov byte [rax], 0
mov dword [rsp + 0x30], 3
mov rcx, qword [rsp + 0x48]
mov rdx, qword [rsp + 0x50]
mov rax, rdx
sub rax, rcx
cmp rax, 9
jb 0x14003c8bc
lea rax, [rcx + 9]
mov qword [rsp + 0x48], rax
lea rbx, [rsp + 0x38]
cmp rdx, 0xf
cmova rbx, qword [rsp + 0x38]
add rbx, rcx
mov r8d, 9
lea rdx, str.__get_sid
mov rcx, rbx
call sub.VCRUNTIME140.dll_memmove
mov byte [rbx + 9], 0
lea rax, [rsp + 0x38]
jmp 0x14003c8dd
mov qword [rsp + 0x20], 9
lea r9, str.__get_sid
xor r8d, r8d
lea edx, [r8 + 9]
lea rcx, [rsp + 0x38]
call fcn.1400402f0
xorps xmm0, xmm0
movups xmmword [rsp + 0xf8], xmm0
mov qword [rsp + 0x108], r15
mov qword [rsp + 0x110], r15
movups xmm0, xmmword [rax]
movups xmmword [rsp + 0xf8], xmm0
movups xmm1, xmmword [rax + 0x10]
movups xmmword [rsp + 0x108], xmm1
mov qword [rax + 0x10], r15
mov qword [rax + 0x18], reloc.WS2_32.dll_ntohs
mov byte [rax], 0
mov dword [rsp + 0x30], 7
mov rdx, qword [rsp + 0x50]
cmp rdx, 0xf
jbe 0x14003c966
inc rdx
mov rcx, qword [rsp + 0x38]
mov rax, rcx
cmp rdx, 0x1000
jb 0x14003c961
add rdx, 0x27
mov rcx, qword [rcx - 8]
sub rax, rcx
add rax, 0xfffffffffffffff8
cmp rax, 0x1f
jbe 0x14003c961
call qword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll__invalid_parameter_noinfo_noreturn]
int3
call fcn.14008ddcc
mov qword [rsp + 0x48], r15
mov qword [rsp + 0x50], reloc.WS2_32.dll_ntohs
mov byte [rsp + 0x38], 0
mov rdx, qword [rsp + 0x70]
cmp rdx, 0xf
jbe 0x14003c9b9
inc rdx
mov rcx, qword [rsp + 0x58]
mov rax, rcx
cmp rdx, 0x1000
jb 0x14003c9b4
add rdx, 0x27
mov rcx, qword [rcx - 8]
sub rax, rcx
add rax, 0xfffffffffffffff8
cmp rax, 0x1f
jbe 0x14003c9b4
call qword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll__invalid_parameter_noinfo_noreturn]
int3
call fcn.14008ddcc
lea rcx, [rsp + 0xf8]
cmp qword [rsp + 0x110], 0xf
cmova rcx, qword [rsp + 0xf8]
lea rdx, [0x1400a21b0]
call qword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll__popen]
mov rbx, rax
xorps xmm0, xmm0
movdqu xmmword [rsp + 0xe8], xmm0
mov rcx, qword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll__pclose]
mov qword [rsp + 0xd8], rcx
mov qword [rsp + 0x90], rax
lea rax, [rsp + 0xd8]
mov qword [rsp + 0x98], rax
mov byte [rsp + 0xa0], 1
mov ecx, 0x20
call fcn.14008e1a4
mov r14, rax
mov qword [rax], r15
mov qword [rax + 8], r15
mov qword [rax + 0x18], r15
mov rcx, qword [rsp + 0xd8]
mov dword [rax + 8], 1
mov dword [rax + 0xc], 1
lea rax, vtable.std::_Ref_count_resource_struct__iobuf____ptr64__int____cdecl___struct__iobuf____ptr64__.0
mov qword [r14], rax
mov qword [r14 + 0x10], rcx
mov qword [r14 + 0x18], rbx
mov qword [rsp + 0xe8], rbx
mov qword [rsp + 0xf0], r14
test rbx, rbx
je 0x14003ccdd
mov rcx, rbx
call qword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll_feof]
test eax, eax
jne 0x14003cab1
mov r8, rbx
mov edx, 0x80
lea rcx, [rsp + 0x120]
call qword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll_fgets]
test rax, rax
je 0x14003ca77
lea rdx, [rsp + 0x120]
mov rcx, rdi
call fcn.14003f1e0
jmp 0x14003ca77
cmp qword [rdi + 0x18], 0xf
jbe 0x14003cacc
mov rax, qword [rdi]
mov rcx, qword [rdi + 0x10]
lea rsi, [rax + rcx]
lea rbx, [rax + rcx]
mov rcx, rax
jmp 0x14003cadb
mov rax, qword [rdi + 0x10]
lea rsi, [rax + rdi]
lea rbx, [rdi + rax]
mov rcx, rdi
mov r15, rsi
mov r8b, 0xa
mov rdx, rbx
call fcn.14008eb60
mov rcx, rax
cmp rax, rbx
je 0x14003cb15
inc rax
cmp rax, rbx
je 0x14003cb15
nop dword [rax]
movzx edx, byte [rax]
cmp dl, 0xa
je 0x14003cb0d
mov byte [rcx], dl
inc rcx
inc rax
cmp rax, rbx
jne 0x14003cb00
mov rdx, rcx
mov rbx, qword [rdi + 0x10]
mov rax, rbx
cmp qword [rdi + 0x18], 0xf
jbe 0x14003cb3b
sub rdx, qword [rdi]
sub rsi, rcx
sub rax, rdx
cmp rax, rsi
cmovb rsi, rax
mov rax, qword [rdi]
jmp 0x14003cb51
sub rdx, rdi
mov rsi, r15
sub rsi, rcx
sub rax, rdx
cmp rax, rsi
cmovb rsi, rax
mov rax, rdi
lea rcx, [rax + rdx]
sub rbx, rsi
mov r8, rbx
sub r8, rdx
inc r8
lea rdx, [rcx + rsi]
call sub.VCRUNTIME140.dll_memmove
mov qword [rdi + 0x10], rbx
cmp qword [rdi + 0x18], 0xf
jbe 0x14003cb84
mov rax, qword [rdi]
lea rsi, [rax + rbx]
add rbx, rax
mov rcx, rax
jmp 0x14003cb8e
lea rsi, [rbx + rdi]
add rbx, rdi
mov rcx, rdi
mov r8b, 0x20
mov rdx, rbx
call fcn.14008eb60
mov rdx, rax
cmp rax, rbx
je 0x14003cbc5
inc rax
cmp rax, rbx
je 0x14003cbc5
nop dword [rax]
movzx ecx, byte [rax]
cmp cl, 0x20
je 0x14003cbbd
mov byte [rdx], cl
inc rdx
inc rax
cmp rax, rbx
jne 0x14003cbb0
sub rsi, rdx
mov rbx, qword [rdi + 0x10]
mov rax, rbx
cmp qword [rdi + 0x18], 0xf
jbe 0x14003cbe8
sub rdx, qword [rdi]
sub rax, rdx
cmp rax, rsi
cmovb rsi, rax
mov rax, qword [rdi]
jmp 0x14003cbf8
sub rdx, rdi
sub rax, rdx
cmp rax, rsi
cmovb rsi, rax
mov rax, rdi
lea rcx, [rax + rdx]
sub rbx, rsi
mov r8, rbx
sub r8, rdx
inc r8
lea rdx, [rcx + rsi]
call sub.VCRUNTIME140.dll_memmove
mov qword [rdi + 0x10], rbx
test r14, r14
je 0x14003cc53
mov eax, r12d
lock xadd dword [r14 + 8], eax
cmp eax, 1
jne 0x14003cc53
mov rbx, qword [rsp + 0xf0]
mov rax, qword [rbx]
mov rcx, rbx
call qword [rax]
lock xadd dword [rbx + 0xc], r12d
cmp r12d, 1
jne 0x14003cc53
mov rcx, qword [rsp + 0xf0]
mov rax, qword [rcx]
call qword [rax + ioctlsocket]
nop
mov rdx, qword [rsp + 0x110]
cmp rdx, 0xf
jbe 0x14003cc9a
inc rdx
mov rcx, qword [rsp + 0xf8]
mov rax, rcx
cmp rdx, 0x1000
jb 0x14003cc94
add rdx, 0x27
mov rcx, qword [rcx - 8]
sub rax, rcx
add rax, 0xfffffffffffffff8
cmp rax, 0x1f
jbe 0x14003cc94
call qword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll__invalid_parameter_noinfo_noreturn]
int3
call fcn.14008ddcc
nop
jmp 0x14003cca1
mov rax, rdi
mov rcx, qword [rsp + 0x2b0]
xor rcx, rsp
call fcn.14008db60
lea r11, [rsp + 0x2c0]
mov rbx, qword [r11 + 0x28]
mov rsi, qword [r11 + 0x30]
mov rdi, qword [r11 + 0x38]
mov rsp, r11
pop r15
pop r14
pop r12
ret
call fcn.14003c4f0
call fcn.140038960
nop
lea rdx, str.popen___failed_
lea rcx, [rsp + 0xa8]
call fcn.14003c510
lea rdx, [0x1400b65d8]
lea rcx, [rsp + 0xa8]
call sub.VCRUNTIME140.dll__CxxThrowException
nop
lea rdx, str.GetUserNameA___failed_
lea rcx, [rsp + 0xc0]
call fcn.14003c510
lea rdx, [0x1400b65d8]
lea rcx, [rsp + 0xc0]
call sub.VCRUNTIME140.dll__CxxThrowException
int3