From f2ffacec019916c9dd9788a3d5f557ffa689c8a2 Mon Sep 17 00:00:00 2001 From: Laura Hausmann Date: Sun, 24 Jan 2021 17:51:33 +0100 Subject: [PATCH] Update to reflect nginx-mod-rtmp changes --- Controllers/RtmpAuthController.cs | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git a/Controllers/RtmpAuthController.cs b/Controllers/RtmpAuthController.cs index 912680a..b979eb1 100644 --- a/Controllers/RtmpAuthController.cs +++ b/Controllers/RtmpAuthController.cs @@ -17,11 +17,8 @@ namespace RTMPDash.Controllers { Response.Headers.Add("x-rtmp-user", user!.Username); - if (!user!.AllowRestream || string.IsNullOrWhiteSpace(user.RestreamTargets)) - Response.Headers.Add("x-rtmp-target", "rtmp://127.0.0.1/src/" + user!.Username); - else - Response.Headers.Add("x-rtmp-target", - "rtmp://127.0.0.1/src/" + user!.Username + "," + user.RestreamTargets); + if (user.AllowRestream && !string.IsNullOrWhiteSpace(user.RestreamTargets)) + Response.Headers.Add("x-rtmp-target", user.RestreamTargets); Response.StatusCode = 302; return "authorized as " + user!.Username;