You cannot select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
22 lines
548 B
C#
22 lines
548 B
C#
using System;
|
|
using System.Collections.Generic;
|
|
using System.Linq;
|
|
using System.Threading.Tasks;
|
|
|
|
namespace cugoj_ng_server.Utilities
|
|
{
|
|
public static class Crypto
|
|
{
|
|
public static byte[] SHA1(byte[] data)
|
|
{
|
|
using var sha1 = System.Security.Cryptography.SHA1.Create();
|
|
return sha1.ComputeHash(data);
|
|
}
|
|
public static byte[] MD5(byte[] data)
|
|
{
|
|
using var sha1 = System.Security.Cryptography.MD5.Create();
|
|
return sha1.ComputeHash(data);
|
|
}
|
|
}
|
|
}
|