Toggle navigation
Toggle navigation
此项目
正在载入...
Sign in
胡斌
/
srs
转到一个项目
Toggle navigation
项目
群组
代码片段
帮助
Toggle navigation pinning
Project
Activity
Repository
Pipelines
Graphs
Issues
0
Merge Requests
0
Wiki
Network
Create a new issue
Builds
Commits
Authored by
winlin
2014-12-02 15:41:54 +0800
Browse Files
Options
Browse Files
Download
Plain Diff
Commit
5905e5c0509767829a980831903332e687c8bd85
5905e5c0
2 parents
757cffba
9bda56cb
merge from 1.0release, traverse the token before response connect. 2.0.45.
显示空白字符变更
内嵌
并排对比
正在显示
4 个修改的文件
包含
15 行增加
和
9 行删除
AUTHORS.txt
README.md
trunk/src/app/srs_app_rtmp_conn.cpp
trunk/src/core/srs_core.hpp
AUTHORS.txt
查看文件 @
5905e5c
...
...
@@ -20,3 +20,4 @@ CONTRIBUTORS ordered by first contribution.
* karthikeyan<keyanmca@gmail.com> "Bug fixed"
* StevenLiu<lq@chinaffmpeg.org> "Build SRS on Darwin OSX"
* zhengfl<zhengfl_1989@126.com> "Bug fixed"
* tufang14<breadbean1449@gmail.com> "Bug fixed"
...
...
README.md
查看文件 @
5905e5c
...
...
@@ -485,6 +485,7 @@ Supported operating systems and hardware:
*
2013-10-17, Created.
<br/>
## History
*
v2.0, 2014-12-02, merge
[
#239
](
https://github.com/winlinvip/simple-rtmp-server/pull/239
)
, traverse the token before response connect. 2.0.45.
*
v2.0, 2014-12-02, srs-librtmp support hijack io apis for st-load. 2.0.42.
*
v2.0, 2014-12-01, for
[
#237
](
https://github.com/winlinvip/simple-rtmp-server/issues/237
)
, refine syscall for recv, supports 1.5k clients. 2.0.41.
*
v2.0, 2014-11-30, add qtcreate project file trunk/src/qt/srs/srs-qt.pro. 2.0.39.
...
...
trunk/src/app/srs_app_rtmp_conn.cpp
查看文件 @
5905e5c
...
...
@@ -242,6 +242,18 @@ int SrsRtmpConn::service_cycle()
return
bandwidth
->
bandwidth_check
(
rtmp
,
skt
,
req
,
local_ip
);
}
// do token traverse before serve it.
// @see https://github.com/winlinvip/simple-rtmp-server/pull/239
bool
vhost_is_edge
=
_srs_config
->
get_vhost_is_edge
(
req
->
vhost
);
bool
edge_traverse
=
_srs_config
->
get_vhost_edge_token_traverse
(
req
->
vhost
);
if
(
vhost_is_edge
&&
edge_traverse
)
{
if
((
ret
=
check_edge_token_traverse_auth
())
!=
ERROR_SUCCESS
)
{
srs_warn
(
"token auth failed, ret=%d"
,
ret
);
return
ret
;
}
}
// response the client connect ok.
if
((
ret
=
rtmp
->
response_connect_app
(
req
,
local_ip
.
c_str
()))
!=
ERROR_SUCCESS
)
{
srs_error
(
"response connect app failed. ret=%d"
,
ret
);
return
ret
;
...
...
@@ -324,15 +336,7 @@ int SrsRtmpConn::stream_service_cycle()
}
srs_info
(
"set chunk_size=%d success"
,
chunk_size
);
// do token traverse before serve it.
bool
vhost_is_edge
=
_srs_config
->
get_vhost_is_edge
(
req
->
vhost
);
bool
edge_traverse
=
_srs_config
->
get_vhost_edge_token_traverse
(
req
->
vhost
);
if
(
vhost_is_edge
&&
edge_traverse
)
{
if
((
ret
=
check_edge_token_traverse_auth
())
!=
ERROR_SUCCESS
)
{
srs_warn
(
"token auth failed, ret=%d"
,
ret
);
return
ret
;
}
}
// find a source to serve.
SrsSource
*
source
=
NULL
;
...
...
trunk/src/core/srs_core.hpp
查看文件 @
5905e5c
...
...
@@ -31,7 +31,7 @@ CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
// current release version
#define VERSION_MAJOR 2
#define VERSION_MINOR 0
#define VERSION_REVISION 4
4
#define VERSION_REVISION 4
5
// server info.
#define RTMP_SIG_SRS_KEY "SRS"
#define RTMP_SIG_SRS_ROLE "origin/edge server"
...
...
请
注册
或
登录
后发表评论