mirror of
https://github.com/jellyfin/jellyfin.git
synced 2024-09-06 11:34:57 +02:00
Merge pull request #1372 from DrPandemic/fix-pin
Fix broken pin in 10.3.z
This commit is contained in:
commit
0a9a6b949c
2 changed files with 4 additions and 4 deletions
|
@ -19,7 +19,7 @@ namespace Emby.Server.Implementations.Library
|
||||||
public string Name => "Default";
|
public string Name => "Default";
|
||||||
|
|
||||||
public bool IsEnabled => true;
|
public bool IsEnabled => true;
|
||||||
|
|
||||||
// This is dumb and an artifact of the backwards way auth providers were designed.
|
// This is dumb and an artifact of the backwards way auth providers were designed.
|
||||||
// This version of authenticate was never meant to be called, but needs to be here for interface compat
|
// This version of authenticate was never meant to be called, but needs to be here for interface compat
|
||||||
// Only the providers that don't provide local user support use this
|
// Only the providers that don't provide local user support use this
|
||||||
|
@ -27,7 +27,7 @@ namespace Emby.Server.Implementations.Library
|
||||||
{
|
{
|
||||||
throw new NotImplementedException();
|
throw new NotImplementedException();
|
||||||
}
|
}
|
||||||
|
|
||||||
// This is the verson that we need to use for local users. Because reasons.
|
// This is the verson that we need to use for local users. Because reasons.
|
||||||
public Task<ProviderAuthenticationResult> Authenticate(string username, string password, User resolvedUser)
|
public Task<ProviderAuthenticationResult> Authenticate(string username, string password, User resolvedUser)
|
||||||
{
|
{
|
||||||
|
@ -103,7 +103,7 @@ namespace Emby.Server.Implementations.Library
|
||||||
string hash = user.Password;
|
string hash = user.Password;
|
||||||
user.Password = string.Format("$SHA1${0}", hash);
|
user.Password = string.Format("$SHA1${0}", hash);
|
||||||
}
|
}
|
||||||
|
|
||||||
if (user.EasyPassword != null && !user.EasyPassword.Contains("$"))
|
if (user.EasyPassword != null && !user.EasyPassword.Contains("$"))
|
||||||
{
|
{
|
||||||
string hash = user.EasyPassword;
|
string hash = user.EasyPassword;
|
||||||
|
|
|
@ -550,7 +550,7 @@ namespace Emby.Server.Implementations.Library
|
||||||
{
|
{
|
||||||
return string.IsNullOrEmpty(user.EasyPassword)
|
return string.IsNullOrEmpty(user.EasyPassword)
|
||||||
? null
|
? null
|
||||||
: user.EasyPassword;
|
: (new PasswordHash(user.EasyPassword)).Hash;
|
||||||
}
|
}
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
|
|
Loading…
Reference in a new issue