Skip to content

Commit

Permalink
Fix limelight authentication with abbreviated app names
Browse files Browse the repository at this point in the history
When streaming to limelight, the app name is either a full
"appname/subaccount" or "appname/_definst_". In the latter case,
the app name can be simplified into simply "appname", but the
authentication hashing assumes the /_definst_ still to be present.
  • Loading branch information
mstorsjo committed Aug 15, 2013
1 parent ec606b6 commit 5ba573a
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions librtmp/rtmp.c
Expand Up @@ -2792,6 +2792,8 @@ PublisherAuth(RTMP *r, AVal *description)
MD5_Update(&md5ctx, method, sizeof(method)-1);
MD5_Update(&md5ctx, ":/", 2);
MD5_Update(&md5ctx, apptmp.av_val, apptmp.av_len);
if (!AValChr(&apptmp, '/'))
MD5_Update(&md5ctx, "/_definst_", sizeof("/_definst_") - 1);
MD5_Final(md5sum_val, &md5ctx);
RTMP_Log(RTMP_LOGDEBUG, "%s, md5(%s:/%.*s) =>", __FUNCTION__,
method, apptmp.av_len, apptmp.av_val);
Expand Down

0 comments on commit 5ba573a

Please sign in to comment.