[prev in list] [next in list] [prev in thread] [next in thread]
List: helix-server-cvs
Subject: [Server-cvs] protocol/http httpprot.cpp,1.146.2.20,1.146.2.21
From: yichen () helixcommunity ! org
Date: 2012-11-22 4:19:01
[Download RAW message or body]
Update of /cvsroot/server/protocol/http
In directory cvs01.internal.helixcommunity.org:/tmp/cvs-serv4443
Modified Files:
Tag: SERVER_15_0
httpprot.cpp
Log Message:
Synopsis:
===============
fix Bug 270838:[HLS-SSPL] if enable send playlist and eccrytion key file via https, \
CA occurs when request sspl list by http
Branch: SERVER_15_0_RN, HEAD
Suggested Reviewers: Xiaocheng Li, Richard Yuan
Description:
===============
BUILD VERSION:
Version: Helix Universal Media Server (RealNetworks) (15.0.0.275) (Build
234872/18737)
Platform: linux-rhel6-x86_64 (64-bit)
SUMMARY:
[HLS-SSPL] if enable send playlist and eccrytion key file via https, CA occurs
when request sspl list by http
CONFIGURE:
hms server: 192.168.35.90 helixqa2.realnetworks.com
Enable SSPL
Create a sspl play list in /segsrc
enable send playlist via https
enable send eccrytion key file by https
STEPS TO REPRODUCE:
1.create the playlist mylist.hpl as follow:
<smil xmlns="http://www.w3.org/2001/SMIL20/Language">
<head>
<meta name="title" content="Travel - H264"/>
<meta name="copyright" content="(c) 2010"/>
</head>
<body>
<video id="meet.mp4" src="/segsrc/meet.mp4"/>
</body>
</smil>
2.use ipad request:
http://192.168.35.90/m3ugen/segsrc/mylist.hpl
or
http://helixqa2.realnetworks.com:80/m3ugen/segsrc/mylist.hpl
EXPECTED RESULTS:
Client can't play, hms server give proper tips
ACTUAL RESULTS:
CA occurs as below:
-------------------------------------------------------------------------------
*** Helix Universal Media Server Fault Report
When: 17-Nov-2012 03:03:07
Environment: linux-rhel6-x86_64, (Build 234872/18737), 15.0.0.275
TID 140428548503264
Caught Signal 11 (Segmentation fault)
Fault State: 1
Stack Trace:
0x5a5225: _Z9dump_infoiiPKciP7siginfoP8ucontext+0x4c5 [008f469c 00000000 2d2d2d0a
2d2d2d2d 2d2d2d2d 2d2d2d2d] : rmserver.bin
0x5ada52: _Z12server_faultiP7siginfoP8ucontext+0x432 [ffffffff ffffffff ffffffff
ffffffff ffffffff ffffffff] : rmserver.bin
0x33d240f500: (null) [00000000 00000000 11a01000 00007fb8 00000000 ffffffff] :
libpthread.so.0
0x33d1d3259f: (null) [02a28188 00000000 00000000 00000000 00000000 00000000] :
libc.so.6
0x80143a: _ZN12HTTPProtocol18SetSessionLogEntryEv+0xea [00000000 00000000
00000000 00000000 02a1f208 00000000] : rmserver.bin
0x805f58: _ZN12HTTPProtocol8OnClosedEv+0x188 [02a38170 00000000 00000001 00000000
02a38170 00000000] : rmserver.bin
0x7097f0: _ZN10CHTTPDemux12EventPendingEji+0x210 [00000000 00000000 11bfab70
00007fb8 0bbad3b8 00000000] : rmserver.bin
0x725634: _ZN9CHXSocket7OnEventEj+0x84 [00000000 00000000 0b580310 00000000
00000000 00000000] : rmserver.bin
0x6b2172: _ZN11CServSockCB4FuncEv+0x22 [0733b8d8 00000000 11bfed00 00007fb8
0069f9d7 00000000] : rmserver.bin
0x69f9d7: _ZN12ServerEngine8mainloopEi+0x1c37 [ffffffff ffffffff ffffffff
ffffffff ffffffff ffffffff] : rmserver.bin
0x5a6554: _Z17PthreadEntryPointP11thread_args+0x184 [01f90038 00000000 11a01000
00007fb8 00000000 00000000] : rmserver.bin
0x33d2407851: (null) [ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff] :
libpthread.so.0
0x33d1ce811d: clone+0x6d [ffffffff ffffffff ffffffff ffffffff ffffffff
ffffffff] : libc.so.6
-------------------------------------------------------------------------------
Normal CA: In Scheduler/NetEvents!
The root cause for this problem is that, when a https request come, \
HTTPProtocol::SetSessionLogEntry is called, in this call \
HTTPProtocol::SetSessionLogEntry() {
.......
pFinalClipURL->Set((UCHAR*)m_pURL,UINT32(strlen(m_pURL) + 1));
pSessionStats->SetURL(pFinalClipURL);
.....
}
because m_pURL is a NULL pointer, therefore when the line contains strlen(m_pURL) is \
called, it causes a segment fault.
Why m_pURL is NULL? when a https request is come, HTTPProtocol::init_request is \
called
HTTPProtocol::init_request()
{
..........
if (m_bIsM3ugenReq && !CheckForSecurePlaylist())
{
hxreg->Release();
return -1;
}
..........
HX_VECTOR_DELETE(m_pURL);
m_pURL = new_string(pURL);
........
}
m_pURL is assigned a value in this call, but because the request is type of https, \
for configure reason, CheckForSecurePlaylist will return false, therefore, the call \
is return, and m_pURL = new_string(pURL); is never be called, and m_pURL remains as \
NULL.
my fix is in SetSessionLogEntry, check whether m_pURL is NULL or not, if it is, \
return directly .
Files affected
==================
server/protocol/http/httpprot.cpp
Test perform
====================
Retry the test case again and no CA is fond.
Integration Tests:
N/A
Performance Tests:
CentOS6
QA Hints
========
None.
Index: httpprot.cpp
===================================================================
RCS file: /cvsroot/server/protocol/http/httpprot.cpp,v
retrieving revision 1.146.2.20
retrieving revision 1.146.2.21
diff -u -d -r1.146.2.20 -r1.146.2.21
--- httpprot.cpp 21 Nov 2012 09:40:09 -0000 1.146.2.20
+++ httpprot.cpp 22 Nov 2012 04:18:52 -0000 1.146.2.21
@@ -1491,7 +1491,6 @@
HX_STAT_TIME_T tCreationTime,
const char* mimeType)
{
-printf("http: 0020\n");
m_nFileSize = size;
m_tCreationTime = tCreationTime;
if (mimeType)
_______________________________________________
Server-cvs mailing list
Server-cvs@helixcommunity.org
http://lists.helixcommunity.org/mailman/listinfo/server-cvs
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic