mirror of
https://github.com/jellyfin/jellyfin.git
synced 2026-04-20 09:04:42 +01:00
Merge pull request #1397 from Bond-009/passfast
Streamline authentication proccess
This commit is contained in:
@@ -0,0 +1,28 @@
|
||||
using System;
|
||||
namespace MediaBrowser.Controller.Authentication
|
||||
{
|
||||
/// <summary>
|
||||
/// The exception that is thrown when an attempt to authenticate fails.
|
||||
/// </summary>
|
||||
public class AuthenticationException : Exception
|
||||
{
|
||||
/// <inheritdoc />
|
||||
public AuthenticationException() : base()
|
||||
{
|
||||
|
||||
}
|
||||
|
||||
/// <inheritdoc />
|
||||
public AuthenticationException(string message) : base(message)
|
||||
{
|
||||
|
||||
}
|
||||
|
||||
/// <inheritdoc />
|
||||
public AuthenticationException(string message, Exception innerException)
|
||||
: base(message, innerException)
|
||||
{
|
||||
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -9,10 +9,9 @@ namespace MediaBrowser.Controller.Authentication
|
||||
string Name { get; }
|
||||
bool IsEnabled { get; }
|
||||
Task<ProviderAuthenticationResult> Authenticate(string username, string password);
|
||||
Task<bool> HasPassword(User user);
|
||||
bool HasPassword(User user);
|
||||
Task ChangePassword(User user, string newPassword);
|
||||
void ChangeEasyPassword(User user, string newPassword, string newPasswordHash);
|
||||
string GetPasswordHash(User user);
|
||||
string GetEasyPasswordHash(User user);
|
||||
}
|
||||
|
||||
|
||||
@@ -12,6 +12,7 @@ namespace MediaBrowser.Controller.Authentication
|
||||
Task<ForgotPasswordResult> StartForgotPasswordProcess(User user, bool isInNetwork);
|
||||
Task<PinRedeemResult> RedeemPasswordResetPin(string pin);
|
||||
}
|
||||
|
||||
public class PasswordPinCreationResult
|
||||
{
|
||||
public string PinFile { get; set; }
|
||||
|
||||
Reference in New Issue
Block a user