diff options
| author | Luke Pulverenti <luke.pulverenti@gmail.com> | 2014-11-08 22:18:14 -0500 |
|---|---|---|
| committer | Luke Pulverenti <luke.pulverenti@gmail.com> | 2014-11-08 22:18:14 -0500 |
| commit | 40897bac1494791e1ec6abcfe85cda27d4664a32 (patch) | |
| tree | 4788db3f5e35a3a06c9668f4460299c4f4a17ca1 /MediaBrowser.Server.Implementations/HttpServer/Security/AuthService.cs | |
| parent | 0ef95fb19cde8f4443e2cede94ec21583c3dc9d7 (diff) | |
fixes #941 - Rework password recovery and remove IsLocal checks
Diffstat (limited to 'MediaBrowser.Server.Implementations/HttpServer/Security/AuthService.cs')
| -rw-r--r-- | MediaBrowser.Server.Implementations/HttpServer/Security/AuthService.cs | 15 |
1 files changed, 6 insertions, 9 deletions
diff --git a/MediaBrowser.Server.Implementations/HttpServer/Security/AuthService.cs b/MediaBrowser.Server.Implementations/HttpServer/Security/AuthService.cs index 295f0c775..dde61079b 100644 --- a/MediaBrowser.Server.Implementations/HttpServer/Security/AuthService.cs +++ b/MediaBrowser.Server.Implementations/HttpServer/Security/AuthService.cs @@ -63,17 +63,14 @@ namespace MediaBrowser.Server.Implementations.HttpServer.Security // This code is executed before the service var auth = AuthorizationContext.GetAuthorizationInfo(req); - if (!authAttribtues.AllowLocal || !req.IsLocal) + if (!string.IsNullOrWhiteSpace(auth.Token) || + !_config.Configuration.InsecureApps6.Contains(auth.Client ?? string.Empty, StringComparer.OrdinalIgnoreCase)) { - if (!string.IsNullOrWhiteSpace(auth.Token) || - !_config.Configuration.InsecureApps6.Contains(auth.Client ?? string.Empty, StringComparer.OrdinalIgnoreCase)) - { - var valid = IsValidConnectKey(auth.Token); + var valid = IsValidConnectKey(auth.Token); - if (!valid) - { - SessionManager.ValidateSecurityToken(auth.Token); - } + if (!valid) + { + SessionManager.ValidateSecurityToken(auth.Token); } } |
