Function at 0x1400122b0
Capabilities:
Write file on windows

Disassembly:
push rsi
push rdi
push rbp
push rbx
sub rsp, 0x98
movaps xmmword [rsp + 0x80], xmm6
mov rdi, rcx
call fcn.14001a2a0
mov rcx, rax
call fcn.14006999c
mov ecx, eax
call fcn.14006ae20
mov rsi, rax
xorps xmm6, xmm6
movaps xmmword [rsp + 0x60], xmm6
mov qword [rsp + 0x6e], 0
lea rdx, [rsp + 0x60]
mov rcx, rax
call sub.KERNEL32.dll_GetConsoleScreenBufferInfo
mov ebx, eax
call fcn.14001a2a0
lea rdx, [0x14008ff9c]
mov rcx, rax
call fcn.14005a444
test eax, eax
jle 0x1400123ec
test ebx, ebx
je 0x14001249e
xorps xmm6, xmm6
movaps xmmword [rsp + 0x40], xmm6
lea rax, [rsp + 0x40]
mov qword [rsp + 0x50], rax
lea rax, [0x140012d80]
mov qword [rsp + 0x58], rax
mov rax, qword [rdi]
lea r8, [0x140012cb0]
lea rdx, [rsp + 0x50]
mov rcx, rdi
call qword [rax + reloc.WS2_32.dll_getservbyport]
cmp qword [rsp + 0x40], 0
je 0x140012542
call sub.KERNEL32.dll_GetConsoleOutputCP
mov edi, eax
mov r8, qword [rsp + 0x40]
mov r9d, dword [rsp + 0x48]
movups xmmword [rsp + 0x30], xmm6
mov dword [rsp + 0x28], 0
mov qword [rsp + 0x20], 0
mov ecx, eax
xor edx, edx
call sub.KERNEL32.dll_WideCharToMultiByte
mov ebx, eax
movsxd rcx, eax
call fcn.14006f9ec
test rax, rax
je 0x140012538
mov r8, qword [rsp + 0x40]
mov r9d, dword [rsp + 0x48]
xorps xmm0, xmm0
movups xmmword [rsp + 0x30], xmm0
mov dword [rsp + 0x28], ebx
mov qword [rsp + 0x20], rax
mov ecx, edi
xor edx, edx
mov rdi, rax
call sub.KERNEL32.dll_WideCharToMultiByte
mov qword [rsp + 0x20], 0
mov rcx, rsi
mov rdx, rdi
mov r8d, ebx
xor r9d, r9d
call sub.KERNEL32.dll_WriteFile
mov rcx, rdi
jmp 0x140012533
movaps xmmword [rsp + 0x40], xmm6
lea rax, [rsp + 0x40]
mov qword [rsp + 0x50], rax
lea rax, [0x140012d80]
mov qword [rsp + 0x58], rax
mov rsi, qword [rdi]
lea r8, [0x140012cb0]
lea rdx, [rsp + 0x50]
mov rcx, rdi
call qword [rsi + reloc.WS2_32.dll_getservbyport]
cmp qword [rsp + 0x40], 0
je 0x140012542
mov rax, qword [rsi]
mov rdi, qword [rax + 0x20]
test rdi, rdi
je 0x1400124ca
mov rbx, qword [rax + 0x28]
mov dword [rsp + 0x28], 0
mov qword [rsp + 0x20], 0
xor esi, esi
mov ecx, 0xfde9
xor edx, edx
mov r8, rbx
mov r9d, edi
call sub.KERNEL32.dll_MultiByteToWideChar
test eax, eax
je 0x1400124cc
mov ebp, eax
cdqe
lea rcx, [rax*2 + 2]
call fcn.14006f9ec
test rax, rax
je 0x1400124ca
mov rsi, rax
mov dword [rsp + 0x28], ebp
mov qword [rsp + 0x20], rax
mov ecx, 0xfde9
xor edx, edx
mov r8, rbx
mov r9d, edi
call sub.KERNEL32.dll_MultiByteToWideChar
movsxd rbx, eax
jmp 0x1400124ce
mov qword [rsp + 0x50], 0
lea rax, [0x140012e10]
mov qword [rsp + 0x58], rax
mov rax, qword [rdi]
lea r8, [0x140012cb0]
lea rdx, [rsp + 0x50]
mov rcx, rdi
call qword [rax + reloc.WS2_32.dll_getservbyport]
jmp 0x140012542
xor esi, esi
xor ebx, ebx
lea rcx, str.user32.dll
call sub.KERNEL32.dll_LoadLibraryW
mov rdi, rax
test rax, rax
je 0x140012528
lea rdx, str.MessageBoxW
mov rcx, rdi
call sub.KERNEL32.dll_GetProcAddress
test rax, rax
je 0x140012528
mov rcx, qword [rsp + 0x40]
test rcx, rcx
je 0x140012556
mov rdx, qword [rsp + 0x48]
mov word [rcx + rdx*2], 0
mov rdx, qword [rsp + 0x40]
test rsi, rsi
je 0x14001251b
mov word [rsi + rbx*2], 0
xor ecx, ecx
mov r8, rsi
mov r9d, reloc.WS2_32.dll_recv
call rax
mov rcx, rdi
call sub.KERNEL32.dll_FreeLibrary
mov rcx, rsi
call fcn.14006ecd8
mov rcx, qword [rsp + 0x40]
call fcn.14006ecd8
movaps xmm6, xmmword [rsp + 0x80]
add rsp, 0x98
pop rbx
pop rbp
pop rdi
pop rsi
ret
xor edx, edx
test rsi, rsi
jne 0x140012515
jmp 0x14001251b