-
-
Notifications
You must be signed in to change notification settings - Fork 5.4k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
How to implement authentication by placing the srs3.0 token parameter after the streamID? #1110
Comments
2.0 branch have support this feature. You can look up changelog. |
2.0branch tried it, got the streamID, but there are no parameters with key=** in the hook information. Push stream address: Hook information: {u'stream': u'stream000', u'ip': u'172.16.162.190', u'app': u'live', u'vhost': u'defaultVhost',
|
Just add a field to the code of 'hook', I modified the source code myself. Winlin has completed 99% of it, so you just need to make the remaining changes yourself. Alternatively, you can create an issue and ask him to fix it.
|
SRS2:
Support params in |
SRS3:
Support params in |
In addition, the JSON data structure received by the proxy here is also somewhat different from the description in the http-hooks of full.conf. Do we need to adjust it ourselves in the source code to match the desired data structure?
|
The 'token' parameter of srs3.0 is placed after the StreamID. In the TcURL of http_hook, this token is not present. It is only present in the TcUrl when placed after 'live'.
How can I retrieve the token in the 'json_req' of server.py for authentication?
Push stream rtmp://test.lsspush.test.com/live/steam001?key=123000000000&t=20000.
on_connect
json_req:
{u'ip': u'192.168.0.101, u'app': u'live', u'vhost': u'defaultVhost', u'pageUrl': u'', u'client_id': 108, u'tcUrl': u'rtmp://test.lsspush.test.com/live', u'action': u'on_connect'}
on_publish
json_req:
{u'stream': u'steam001', u'ip': u'116.62.38.168', u'app': u'live', u'vhost': u'defaultVhost', u'client_id': 108, u'tcUrl': u'rtmp://test.lsspush.test.com/live', u'action': u'on_publish'}
TRANS_BY_GPT3
The text was updated successfully, but these errors were encountered: