aboutsummaryrefslogtreecommitdiff
path: root/MediaBrowser.Server.Implementations/HttpServer
diff options
context:
space:
mode:
Diffstat (limited to 'MediaBrowser.Server.Implementations/HttpServer')
-rw-r--r--MediaBrowser.Server.Implementations/HttpServer/LoggerUtils.cs2
-rw-r--r--MediaBrowser.Server.Implementations/HttpServer/Security/AuthService.cs2
-rw-r--r--MediaBrowser.Server.Implementations/HttpServer/Security/AuthorizationContext.cs6
-rw-r--r--MediaBrowser.Server.Implementations/HttpServer/SocketSharp/WebSocketSharpListener.cs2
4 files changed, 8 insertions, 4 deletions
diff --git a/MediaBrowser.Server.Implementations/HttpServer/LoggerUtils.cs b/MediaBrowser.Server.Implementations/HttpServer/LoggerUtils.cs
index 5558c24d7..f038591aa 100644
--- a/MediaBrowser.Server.Implementations/HttpServer/LoggerUtils.cs
+++ b/MediaBrowser.Server.Implementations/HttpServer/LoggerUtils.cs
@@ -27,7 +27,7 @@ namespace MediaBrowser.Server.Implementations.HttpServer
var msg = "HTTP Response " + statusCode + " to " + endPoint + responseTime;
- logger.LogMultiline(msg, LogSeverity.Debug, log);
+ logger.LogMultiline(msg, LogSeverity.Info, log);
}
}
}
diff --git a/MediaBrowser.Server.Implementations/HttpServer/Security/AuthService.cs b/MediaBrowser.Server.Implementations/HttpServer/Security/AuthService.cs
index b4da40702..f6b14fcab 100644
--- a/MediaBrowser.Server.Implementations/HttpServer/Security/AuthService.cs
+++ b/MediaBrowser.Server.Implementations/HttpServer/Security/AuthService.cs
@@ -220,7 +220,7 @@ namespace MediaBrowser.Server.Implementations.HttpServer.Security
{
if (string.IsNullOrWhiteSpace(token))
{
- throw new SecurityException("Access token is invalid or expired.");
+ throw new SecurityException("Access token is required.");
}
var info = GetTokenInfo(request);
diff --git a/MediaBrowser.Server.Implementations/HttpServer/Security/AuthorizationContext.cs b/MediaBrowser.Server.Implementations/HttpServer/Security/AuthorizationContext.cs
index ae5ce796e..509a00ff9 100644
--- a/MediaBrowser.Server.Implementations/HttpServer/Security/AuthorizationContext.cs
+++ b/MediaBrowser.Server.Implementations/HttpServer/Security/AuthorizationContext.cs
@@ -62,10 +62,14 @@ namespace MediaBrowser.Server.Implementations.HttpServer.Security
auth.TryGetValue("Version", out version);
}
- var token = httpReq.Headers["X-MediaBrowser-Token"];
+ var token = httpReq.Headers["X-Emby-Token"];
if (string.IsNullOrWhiteSpace(token))
{
+ token = httpReq.Headers["X-MediaBrowser-Token"];
+ }
+ if (string.IsNullOrWhiteSpace(token))
+ {
token = httpReq.QueryString["api_key"];
}
diff --git a/MediaBrowser.Server.Implementations/HttpServer/SocketSharp/WebSocketSharpListener.cs b/MediaBrowser.Server.Implementations/HttpServer/SocketSharp/WebSocketSharpListener.cs
index fdb27d40d..f8178c115 100644
--- a/MediaBrowser.Server.Implementations/HttpServer/SocketSharp/WebSocketSharpListener.cs
+++ b/MediaBrowser.Server.Implementations/HttpServer/SocketSharp/WebSocketSharpListener.cs
@@ -191,7 +191,7 @@ namespace MediaBrowser.Server.Implementations.HttpServer.SocketSharp
var type = request.IsWebSocketRequest ? "Web Socket" : "HTTP " + request.HttpMethod;
- logger.LogMultiline(type + " " + request.Url, LogSeverity.Debug, log);
+ logger.LogMultiline(type + " " + request.Url, LogSeverity.Info, log);
}
private void HandleError(Exception ex, HttpListenerContext context)