diff options
| author | Joshua M. Boniface <joshua@boniface.me> | 2020-05-26 12:14:40 -0400 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2020-05-26 12:14:40 -0400 |
| commit | 0be3dfe7c53d8c3bb43c28ea02c8a594bcb903b2 (patch) | |
| tree | 23177b8121dde236e129566d655c36806fb960a5 /Emby.Server.Implementations/Library/UserManager.cs | |
| parent | 976ae36bea0768f0e363bf0c5091b0853cc81c4d (diff) | |
Revert "Fix emby/user/public API leaking sensitive data"
Diffstat (limited to 'Emby.Server.Implementations/Library/UserManager.cs')
| -rw-r--r-- | Emby.Server.Implementations/Library/UserManager.cs | 25 |
1 files changed, 0 insertions, 25 deletions
diff --git a/Emby.Server.Implementations/Library/UserManager.cs b/Emby.Server.Implementations/Library/UserManager.cs index b8feb5535..d63bc6bda 100644 --- a/Emby.Server.Implementations/Library/UserManager.cs +++ b/Emby.Server.Implementations/Library/UserManager.cs @@ -608,31 +608,6 @@ namespace Emby.Server.Implementations.Library return dto; } - public PublicUserDto GetPublicUserDto(User user, string remoteEndPoint = null) - { - if (user == null) - { - throw new ArgumentNullException(nameof(user)); - } - - IAuthenticationProvider authenticationProvider = GetAuthenticationProvider(user); - bool hasConfiguredPassword = authenticationProvider.HasPassword(user); - bool hasConfiguredEasyPassword = !string.IsNullOrEmpty(authenticationProvider.GetEasyPasswordHash(user)); - - bool hasPassword = user.Configuration.EnableLocalPassword && - !string.IsNullOrEmpty(remoteEndPoint) && - _networkManager.IsInLocalNetwork(remoteEndPoint) ? hasConfiguredEasyPassword : hasConfiguredPassword; - - PublicUserDto dto = new PublicUserDto - { - Name = user.Name, - HasPassword = hasPassword, - HasConfiguredPassword = hasConfiguredPassword, - }; - - return dto; - } - public UserDto GetOfflineUserDto(User user) { var dto = GetUserDto(user); |
