31 lines
763 B
C#
31 lines
763 B
C#
using AsyncRAT_Sharp.RenamingObfuscation.Interfaces;
|
|
using System;
|
|
using System.Collections.Generic;
|
|
using System.Linq;
|
|
using System.Text;
|
|
using System.Threading.Tasks;
|
|
|
|
namespace AsyncRAT_Sharp.RenamingObfuscation.Classes
|
|
{
|
|
public class Base64 : ICrypto
|
|
{
|
|
/// <summary>
|
|
/// Method for encrypt string with Base64.
|
|
/// </summary>
|
|
/// <param name="dataPlain">Input plain string</param>
|
|
/// <returns>Encode string</returns>
|
|
public string Encrypt(string dataPlain)
|
|
{
|
|
try
|
|
{
|
|
return Convert.ToBase64String(Encoding.UTF8.GetBytes(dataPlain));
|
|
}
|
|
|
|
catch (Exception)
|
|
{
|
|
return null;
|
|
}
|
|
}
|
|
}
|
|
}
|