jellyfin/MediaBrowser.Model/Cryptography/ICryptoProvider.cs

27 lines
1.0 KiB
C#
Raw Normal View History

2019-03-05 02:58:25 -05:00
using System;
using System.IO;
using System.Collections.Generic;
namespace MediaBrowser.Model.Cryptography
{
public interface ICryptoProvider
{
2019-05-21 13:28:34 -04:00
string DefaultHashMethod { get; }
[Obsolete("Use System.Security.Cryptography.MD5 directly")]
2019-03-05 02:58:25 -05:00
Guid GetMD5(string str);
2019-05-21 13:28:34 -04:00
[Obsolete("Use System.Security.Cryptography.MD5 directly")]
2019-03-05 02:58:25 -05:00
byte[] ComputeMD5(Stream str);
2019-05-21 13:28:34 -04:00
[Obsolete("Use System.Security.Cryptography.MD5 directly")]
2019-03-05 02:58:25 -05:00
byte[] ComputeMD5(byte[] bytes);
2019-05-21 13:28:34 -04:00
[Obsolete("Use System.Security.Cryptography.SHA1 directly")]
2019-03-05 02:58:25 -05:00
byte[] ComputeSHA1(byte[] bytes);
IEnumerable<string> GetSupportedHashMethods();
byte[] ComputeHash(string HashMethod, byte[] bytes);
byte[] ComputeHashWithDefaultMethod(byte[] bytes);
byte[] ComputeHash(string HashMethod, byte[] bytes, byte[] salt);
byte[] ComputeHashWithDefaultMethod(byte[] bytes, byte[] salt);
byte[] ComputeHash(PasswordHash hash);
byte[] GenerateSalt();
2019-03-05 02:58:25 -05:00
}
}