Skip to content

Commit

Permalink
tokens were not sent in hls, mse and hlsll bug fixed, it is taken as …
Browse files Browse the repository at this point in the history
…query instead of param
  • Loading branch information
sahin52 authored Feb 28, 2023
1 parent 814a137 commit 65219d3
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion apiHTTPHLS.go
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ func HTTPAPIServerStreamHLSM3U8(c *gin.Context) {
return
}

if !RemoteAuthorization("HLS", c.Param("uuid"), c.Param("channel"), c.Param("token"), c.ClientIP()) {
if !RemoteAuthorization("HLS", c.Param("uuid"), c.Param("channel"), c.Query("token"), c.ClientIP()) {
requestLogger.WithFields(logrus.Fields{
"call": "RemoteAuthorization",
}).Errorln(ErrorStreamUnauthorized.Error())
Expand Down
2 changes: 1 addition & 1 deletion apiHTTPHLSLL.go
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ func HTTPAPIServerStreamHLSLLInit(c *gin.Context) {
return
}

if !RemoteAuthorization("HLS", c.Param("uuid"), c.Param("channel"), c.Param("token"), c.ClientIP()) {
if !RemoteAuthorization("HLS", c.Param("uuid"), c.Param("channel"), c.Query("token"), c.ClientIP()) {
requestLogger.WithFields(logrus.Fields{
"call": "RemoteAuthorization",
}).Errorln(ErrorStreamUnauthorized.Error())
Expand Down
2 changes: 1 addition & 1 deletion apiHTTPMSE.go
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ func HTTPAPIServerStreamMSE(c *gin.Context) {
return
}

if !RemoteAuthorization("WS", c.Param("uuid"), c.Param("channel"), c.Param("token"), c.ClientIP()) {
if !RemoteAuthorization("WS", c.Param("uuid"), c.Param("channel"), c.Query("token"), c.ClientIP()) {
requestLogger.WithFields(logrus.Fields{
"call": "RemoteAuthorization",
}).Errorln(ErrorStreamUnauthorized.Error())
Expand Down

0 comments on commit 65219d3

Please sign in to comment.