Function at 0x140040400
Capabilities:
Create process on windows
Set registry value

Disassembly:
mov qword [rsp + 8], rbx
mov qword [rsp + 0x10], rsi
mov qword [rsp + 0x18], rdi
mov qword [rsp + 0x20], r14
push rbp
lea rbp, [rsp - 0x1c0]
sub rsp, 0x2c0
mov rax, qword [0x14019f0c0]
xor rax, rsp
mov qword [rbp + 0x1b0], rax
xorps xmm0, xmm0
movups xmmword [rbp + 8], xmm0
xor r14d, r14d
mov qword [rbp + 0x18], r14
mov qword [rbp + 0x20], r14
mov r8d, 0x624
lea rdx, str._ECHO_OFF_nSETLOCAL_ENABLEDELAYEDEXPANSION_nSETLOCAL_ENABLEEXTENSIONS_n_nFOR__F__tokens1____a_IN__wmic_nic_where_physicaladaptertrue_get_deviceid__findstr__0_9___DO___n____CALL_:MAC_n____FOR___b_IN__0_00_000__DO___n________REG_QUERY_HKEY_LOCAL_MACHINESYSTEMCurrentControlSetControlClass4D36E972_E325_11CE_BFC1_08002bE10318__b__a__NUL_2_NUL_n________REG_ADD_HKEY_LOCAL_MACHINESYSTEMCurrentControlSetControlClass4D36E972_E325_11CE_BFC1_08002bE10318__b__a__v_NetworkAddress__t_REG_SZ__d__MAC____f__NUL_2_NUL_n______n__n_nFOR__F__tokens1____a_IN__wmic_nic_where_physicaladaptertrue_get_deviceid__findstr__0_9___DO___n____FOR___b_IN__0_00_000__DO___n________REG_QUERY_HKEY_LOCAL_MACHINESYSTEMCurrentControlSetControlClass4D36E972_E325_11CE_BFC1_08002bE10318__b__a__NUL_2_NUL_n________REG_ADD_HKEY_LOCAL_MACHINESYSTEMCurrentControlSetControlClass4D36E972_E325_11CE_BFC1_08002bE10318__b__a__v_PnPCapabilities__t_REG_DWORD__d_24__f__NUL_2_NUL_n______n__n_nFOR__F__tokens2_delims__skip2____a_IN___wmic_nic_where__netconnectionid_like_____get_netconnectionid__netconnectionstatus__format:csv___DO___n____netsh_interface_set_interface_name___a__disable__NUL_2_NUL_n____netsh_interface_set_interface_name___a__enable__NUL_2_NUL_n__n_nGOTO_:EOF_n_n:MAC_nSET_COUNT0_nSET_GENABCDEF0123456789_nSET_GEN226AE_nSET_MAC_n:MACLOOP_nSET__a_COUNT1_nSET_RND_random__nSET__A_RNDRND__16_nSET_RNDGEN_GEN:_RND__1__nSET__A_RND2RND__4_nSET_RNDGEN2_GEN2:_RND2__1__nIF___COUNT____EQU__2___SET_MAC_MAC__RNDGEN2___ELSE__SET_MAC_MAC__RNDGEN___nIF__COUNT___LEQ_11_GOTO_MACLOOP_n
lea rcx, [rbp + 8]
call fcn.140044700
nop
xorps xmm0, xmm0
movups xmmword [rbp - 0x38], xmm0
xorps xmm1, xmm1
movdqu xmmword [rbp - 0x28], xmm1
mov r8d, reloc.WLDAP32.dll_Ordinal_35
lea rdx, str.C:Windows_scsspooferChangeMac.bat
lea rcx, [rbp - 0x38]
call fcn.140044700
nop
xor edx, edx
mov r8d, 0x108
lea rcx, [rbp + 0xa0]
call sub.VCRUNTIME140.dll_memset
mov r8d, 2
lea rdx, [rbp - 0x38]
lea rcx, [rbp + 0xa0]
call fcn.140042690
nop
lea rdx, [rbp + 8]
cmp qword [rbp + 0x20], 0xf
cmova rdx, qword [rbp + 8]
mov r8, qword [rbp + 0x18]
lea rcx, [rbp + 0xa0]
call fcn.1400453f0
lea rcx, [rbp + 0xa8]
call fcn.140043030
test rax, rax
jne 0x140040501
mov rax, qword [rbp + 0xa0]
movsxd rcx, dword [rax + 4]
lea rax, [rbp + 0xa0]
add rcx, rax
xor r8d, r8d
mov edx, 2
call qword [sym.imp.MSVCP140.dll_public:_void___cdecl_std::basic_ios_char__struct_std::char_traits_char__::setstate_int__bool____ptr64]
mov dword [rbp + 0x30], 0x68
xorps xmm0, xmm0
movups xmmword [rbp + 0x38], xmm0
movups xmmword [rbp + 0x48], xmm0
movups xmmword [rbp + 0x58], xmm0
movups xmmword [rbp + 0x68], xmm0
movups xmmword [rbp + 0x78], xmm0
movups xmmword [rbp + 0x88], xmm0
mov dword [rbp + 0x6c], 1
mov word [rbp + 0x70], r14w
lea rdx, [rbp - 0x38]
cmp qword [rbp - 0x20], 0xf
cmova rdx, qword [rbp - 0x38]
mov r8, qword [rbp - 0x28]
add r8, rdx
lea rdx, [rbp - 0x38]
cmp qword [rbp - 0x20], 0xf
cmova rdx, qword [rbp - 0x38]
lea rcx, [rsp + 0x78]
call fcn.140043e20
nop
mov r8, rax
lea rcx, [rsp + 0x58]
call fcn.140043f70
nop
mov rdx, rax
lea rcx, [rbp - 0x18]
call fcn.1400440b0
nop
mov rdx, qword [rsp + 0x70]
cmp rdx, 7
jbe 0x1400405c0
lea rdx, [rdx*2 + 2]
mov rcx, qword [rsp + 0x58]
mov rax, rcx
cmp rdx, 0x1000
jb 0x1400405bb
add rdx, 0x27
mov rcx, qword [rcx - 8]
sub rax, rcx
add rax, 0xfffffffffffffff8
cmp rax, 0x1f
jbe 0x1400405bb
call qword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll__invalid_parameter_noinfo_noreturn]
int3
call fcn.1401159d4
movdqa xmm0, xmmword [0x140186620]
movdqu xmmword [rsp + 0x68], xmm0
mov word [rsp + 0x58], r14w
mov rdx, qword [rbp - 0x70]
cmp rdx, 7
jbe 0x140040620
lea rdx, [rdx*2 + 2]
mov rcx, qword [rsp + 0x78]
mov rax, rcx
cmp rdx, 0x1000
jb 0x140040613
add rdx, 0x27
mov rcx, qword [rcx - 8]
sub rax, rcx
add rax, 0xfffffffffffffff8
cmp rax, 0x1f
jbe 0x140040613
call qword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll__invalid_parameter_noinfo_noreturn]
int3
call fcn.1401159d4
movdqa xmm0, xmmword [0x140186620]
movdqu xmmword [rbp - 0x78], xmm0
mov word [rsp + 0x78], r14w
xorps xmm0, xmm0
lea rdx, [rbp - 0x18]
cmp qword [rbp], 7
cmova rdx, qword [rbp - 0x18]
mov rax, qword [rbp - 8]
lea rsi, [rdx + rax*2]
lea rdi, [rbp - 0x18]
cmova rdi, qword [rbp - 0x18]
movdqu xmmword [rbp - 0x50], xmm0
mov rax, r14
mov qword [rbp - 0x40], rax
sub rsi, rdi
mov rbx, rsi
sar rbx, 1
je 0x1400406e9
movabs rax, 0x7fffffffffffffff
cmp rbx, rax
ja 0x140040956
add rbx, rbx
jne 0x140040685
mov rax, r14
jmp 0x1400406c2
cmp rbx, 0x1000
jb 0x1400406ba
lea rcx, [rbx + 0x27]
cmp rcx, rbx
jbe 0x140040950
call fcn.140115680
mov rcx, rax
test rax, rax
je 0x1400407d1
add rax, 0x27
and rax, 0xffffffffffffffe0
mov qword [rax - 8], rcx
jmp 0x1400406c2
mov rcx, rbx
call fcn.140115680
mov qword [rbp - 0x50], rax
mov qword [rbp - 0x48], rax
add rbx, rax
mov qword [rbp - 0x40], rbx
mov r8, rsi
mov rdx, rdi
mov rcx, rax
call sub.VCRUNTIME140.dll_memmove
mov qword [rbp - 0x48], rbx
mov rax, qword [rbp - 0x40]
jmp 0x1400406ed
mov rbx, qword [rbp - 0x48]
mov word [rsp + 0x50], r14w
cmp rbx, rax
je 0x140040703
mov word [rbx], r14w
add qword [rbp - 0x48], 2
jmp 0x140040714
lea r8, [rsp + 0x50]
mov rdx, rbx
lea rcx, [rbp - 0x50]
call fcn.1400455b0
lea rax, [rbp - 0x68]
mov qword [rsp + 0x48], rax
lea rax, [rbp + 0x30]
mov qword [rsp + 0x40], rax
mov qword [rsp + 0x38], r14
mov qword [rsp + 0x30], r14
mov dword [rsp + 0x28], r14d
mov dword [rsp + 0x20], r14d
xor r9d, r9d
xor r8d, r8d
mov rdx, qword [rbp - 0x50]
xor ecx, ecx
call qword [sym.imp.KERNEL32.dll_CreateProcessW]
test eax, eax
je 0x140040775
mov edx, 0xffffffff
mov rcx, qword [rbp - 0x68]
call qword [sym.imp.KERNEL32.dll_WaitForSingleObject]
mov rcx, qword [rbp - 0x68]
call qword [sym.imp.KERNEL32.dll_CloseHandle]
mov rcx, qword [rbp - 0x60]
call qword [sym.imp.KERNEL32.dll_CloseHandle]
jmp 0x140040799
lea rdx, str.Failed_to_execute_MAC_change_script.
mov rcx, qword [sym.imp.MSVCP140.dll_class_std::basic_ostream_char__struct_std::char_traits_char___std::cerr]
call fcn.140043b40
lea rdx, [0x140043d20]
mov rcx, rax
call qword [sym.imp.MSVCP140.dll_public:_class_std::basic_ostream_char__struct_std::char_traits_char______ptr64___cdecl_std::basic_ostream_char__struct_std::char_traits_char__::operator___class_std::basic_ostream_char__struct_std::char_traits_char______ptr64____cdecl___class_std::basic_ostream_char__struct_std::char_traits_char______ptr64_____ptr64]
nop
mov rcx, qword [rbp - 0x50]
test rcx, rcx
je 0x1400407e9
mov rax, qword [rbp - 0x40]
sub rax, rcx
sar rax, 1
lea rdx, [rax + rax]
mov rax, rcx
cmp rdx, 0x1000
jb 0x1400407d8
add rdx, 0x27
mov rcx, qword [rcx - 8]
sub rax, rcx
add rax, 0xfffffffffffffff8
cmp rax, 0x1f
jbe 0x1400407d8
call qword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll__invalid_parameter_noinfo_noreturn]
int3
call fcn.1401159d4
xorps xmm0, xmm0
movdqu xmmword [rbp - 0x50], xmm0
mov qword [rbp - 0x40], r14
mov rdx, qword [rbp]
cmp rdx, 7
jbe 0x14004082c
lea rdx, [rdx*2 + 2]
mov rcx, qword [rbp - 0x18]
mov rax, rcx
cmp rdx, 0x1000
jb 0x140040827
add rdx, 0x27
mov rcx, qword [rcx - 8]
sub rax, rcx
add rax, 0xfffffffffffffff8
cmp rax, 0x1f
jbe 0x140040827
call qword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll__invalid_parameter_noinfo_noreturn]
int3
call fcn.1401159d4
movdqa xmm0, xmmword [0x140186620]
movdqu xmmword [rbp - 8], xmm0
mov word [rbp - 0x18], r14w
mov rax, qword [rbp + 0xa0]
movsxd rcx, dword [rax + 4]
lea rax, vtable.std::basic_ofstream_char__struct_std::char_traits_char__.0
mov qword [rbp + rcx + 0xa0], rax
mov rax, qword [rbp + 0xa0]
movsxd rcx, dword [rax + 4]
lea edx, [rcx - 0xa8]
mov dword [rbp + rcx + 0x9c], edx
lea rcx, [rbp + 0xa8]
call fcn.140042620
lea rcx, [rbp + 0xb0]
call qword [sym.imp.MSVCP140.dll_public_virtual:_void___cdecl_std::basic_ostream_char__struct_std::char_traits_char__::destructor_void____ptr64]
lea rcx, [rbp + 0x148]
call qword [sym.imp.MSVCP140.dll_public_virtual:_void___cdecl_std::basic_ios_char__struct_std::char_traits_char__::destructor_void____ptr64]
nop
mov rdx, qword [rbp - 0x20]
cmp rdx, 0xf
jbe 0x1400408d5
inc rdx
mov rcx, qword [rbp - 0x38]
mov rax, rcx
cmp rdx, 0x1000
jb 0x1400408d0
add rdx, 0x27
mov rcx, qword [rcx - 8]
sub rax, rcx
add rax, 0xfffffffffffffff8
cmp rax, 0x1f
jbe 0x1400408d0
call qword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll__invalid_parameter_noinfo_noreturn]
int3
call fcn.1401159d4
movdqa xmm0, xmmword [0x140186650]
movdqu xmmword [rbp - 0x28], xmm0
mov byte [rbp - 0x38], 0
mov rdx, qword [rbp + 0x20]
cmp rdx, 0xf
jbe 0x140040924
inc rdx
mov rcx, qword [rbp + 8]
mov rax, rcx
cmp rdx, 0x1000
jb 0x14004091f
add rdx, 0x27
mov rcx, qword [rcx - 8]
sub rax, rcx
add rax, 0xfffffffffffffff8
cmp rax, 0x1f
jbe 0x14004091f
call qword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll__invalid_parameter_noinfo_noreturn]
int3
call fcn.1401159d4
mov rcx, qword [rbp + 0x1b0]
xor rcx, rsp
call fcn.1401152a0
lea r11, [rsp + 0x2c0]
mov rbx, qword [r11 + 0x10]
mov rsi, qword [r11 + 0x18]
mov rdi, qword [r11 + 0x20]
mov r14, qword [r11 + 0x28]
mov rsp, r11
pop rbp
ret
call fcn.140002d50
nop
call fcn.1400452e0
int3