[mythtv-commits] Ticket #8645: Change the way myth "decides" if a program is encrypted
MythTV
mythtv at cvs.mythtv.org
Sat Jul 10 11:06:14 UTC 2010
#8645: Change the way myth "decides" if a program is encrypted
--------------------------+-------------------------------------------------
Reporter: anonymous | Owner: janne
Type: defect | Status: new
Priority: minor | Milestone: unknown
Component: MythTV - DVB | Version: Trunk Head
Severity: medium | Mlocked: 0
--------------------------+-------------------------------------------------
I have a whole sat lineup, with almost only pay channels, BUT there is one
clear channel that mythtv, most of the time, tries to descramble whereas
it is clear, which does not work.
The reason is this code in mpegtables.cpp
/** \fn ProgramMapTable::IsEncrypted(void) const
* \brief Returns true iff PMT contains CA descriptor.
*/
bool ProgramMapTable::IsEncrypted(void) const
{
bool encrypted = IsProgramEncrypted();
for (uint i = 0; !encrypted && i < StreamCount(); i++)
encrypted |= IsStreamEncrypted(i);
return encrypted;
}
It happens in my case that the PMT of the free program is detected by myth
as:
2010-07-09 14:06:41.024 CreatePMTSingleProgram()
2010-07-09 14:06:41.024 PMT in input stream
2010-07-09 14:06:41.024 Program Map Table ver(16) pid(0x509) pnum(9069)
len(213)
Stream #0 pid(0xa9) type(video-mpeg2 0x2)
Stream #1 pid(0x74) type(audio-mp2-layer[1,2,3] 0x4)
ISO-639 Language: code(fra) canonical(fre) eng(French)
Stream #2 pid(0x35) type(private-data 0x6)
Teletext Descriptor (0x56) length(5)
Stream #3 pid(0xda) type(unknown 0xc0)
Unknown(198) Descriptor (0xc6) length(5)
Unknown(194) Descriptor (0xc2) length(40)
Stream #4 pid(0x119) type(unknown 0xc0)
Unknown(194) Descriptor (0xc2) length(8)
Stream #5 pid(0x4e2) type(unknown 0xc1)
Unknown(194) Descriptor (0xc2) length(8)
Stream #6 pid(0x153) type(unknown 0xc1)
Unknown(194) Descriptor (0xc2) length(8)
Stream #7 pid(0x4e3) type(unknown 0xc6)
Stream #8 pid(0xcf) type(unknown 0xc1)
Unknown(194) Descriptor (0xc2) length(8)
Conditional Access: sid(0x100) pid(0x708) data_size(13)
Conditional Access: sid(0x100) pid(0x16a8) data_size(13)
Stream #9 pid(0xce) type(unknown 0xc1)
Unknown(194) Descriptor (0xc2) length(8)
So this is flagged as being encrypted as at least one stream is (the one
before the last one). But if you compare with a PMT of a real pay channel
like this one:
2010-07-09 15:23:44.986 Program Map Table ver(28) pid(0x514) pnum(9100)
len(295)
Stream #0 pid(0xb4) type(video-mpeg2 0x2)
Conditional Access: sid(0x100) pid(0x6a4) data_size(28)
Stream #1 pid(0x9e) type(audio-mp2-layer[1,2,3] 0x4)
ISO-639 Language: code(fra) canonical(fre) eng(French)
Conditional Access: sid(0x100) pid(0x6a4) data_size(28)
Stream #2 pid(0xda) type(unknown 0xc0)
Unknown(198) Descriptor (0xc6) length(5)
Unknown(194) Descriptor (0xc2) length(40)
Stream #3 pid(0x119) type(unknown 0xc0)
Unknown(194) Descriptor (0xc2) length(8)
Stream #4 pid(0x4e2) type(unknown 0xc1)
Unknown(194) Descriptor (0xc2) length(8)
Stream #5 pid(0x153) type(unknown 0xc1)
Unknown(194) Descriptor (0xc2) length(8)
Stream #6 pid(0xce) type(unknown 0xc1)
Unknown(194) Descriptor (0xc2) length(8)
Stream #7 pid(0x155) type(unknown 0xc1)
Unknown(194) Descriptor (0xc2) length(8)
Stream #8 pid(0x159) type(unknown 0xc1)
Unknown(194) Descriptor (0xc2) length(8)
Stream #9 pid(0x4e3) type(unknown 0xc6)
Stream #10 pid(0xcf) type(unknown 0xc1)
Unknown(194) Descriptor (0xc2) length(8)
Conditional Access: sid(0x100) pid(0x708) data_size(28)
you can see that here the audio and video streams contain a ca descriptor.
So the fix I propose would be to only test the presence of ca descriptors
in audio or video streams only, which is what really matters.
I cant propose a patch as my system is too fragile right now, but it is a
matter of adding isaudio and isvideo calls in the loop.
HTH
--
Ticket URL: <http://svn.mythtv.org/trac/ticket/8645>
MythTV <http://www.mythtv.org/>
MythTV
More information about the mythtv-commits
mailing list