44 lines
No EOL
1 KiB
C#
44 lines
No EOL
1 KiB
C#
|
|
|
|
using System;
|
|
using lib;
|
|
|
|
namespace client;
|
|
|
|
/// Helper class to pretty print stuff with colors, client specific
|
|
public static class Log
|
|
{
|
|
public static void Encrypted(string message, byte[] payload)
|
|
{
|
|
Console.ForegroundColor = Utils.C_ENC;
|
|
Console.WriteLine($"{message}: {Convert.ToBase64String(payload)}");
|
|
Console.ResetColor();
|
|
}
|
|
|
|
public static void Decrypted(string message, byte[] payload)
|
|
{
|
|
Console.ForegroundColor = Utils.C_DEC;
|
|
Console.WriteLine($"{message}: {Convert.ToBase64String(payload)}");
|
|
Console.ResetColor();
|
|
}
|
|
|
|
public static void Decrypted(string message)
|
|
{
|
|
Console.ForegroundColor = Utils.C_DEC;
|
|
Console.WriteLine(message);
|
|
Console.ResetColor();
|
|
|
|
}
|
|
|
|
public static void System(string message)
|
|
{
|
|
Console.ForegroundColor = Utils.C_SYS;
|
|
Console.WriteLine(message);
|
|
Console.ResetColor();
|
|
}
|
|
|
|
public static void Message(string message)
|
|
{
|
|
Console.WriteLine(message);
|
|
}
|
|
} |