|
SASC
DVBSoftCAM
|
#include <data.h>
Inheritance diagram for cEcmInfo:Public Member Functions | |
| cEcmInfo (void) | |
| cEcmInfo (const cEcmInfo *e) | |
| cEcmInfo (const char *Name, int Pid, int CaId, int ProvId) | |
| ~cEcmInfo () | |
| virtual cString | ToString (bool hide=false) |
| bool | Compare (const cEcmInfo *e) |
| void | SetDvb (int DvbAdapter, int DvbFrontend) |
| void | SetSource (int GrPrgId, int Source, int Transponder) |
| void | SetName (const char *Name) |
| void | SetDataIdx (int idx) |
| const unsigned char * | Data (void) const |
| bool | AddCaDescr (const cEcmInfo *e) |
| bool | AddCaDescr (const unsigned char *descr, int len) |
| const unsigned char * | GetCaDescr (int *l) const |
| void | SetRewriter (void) |
| void | Fail (bool st) |
| bool | Failed (void) const |
| void | SetCached (void) |
| bool | Cached (void) const |
| cEcmInfo (void) | |
| cEcmInfo (const cEcmInfo *e) | |
| cEcmInfo (const char *Name, int Pid, int CaId, int ProvId) | |
| ~cEcmInfo () | |
| virtual cString | ToString (bool hide=false) |
| bool | Compare (const cEcmInfo *e) |
| void | SetDvb (int DvbAdapter, int DvbFrontend) |
| void | SetSource (int GrPrgId, int Source, int Transponder) |
| void | SetName (const char *Name) |
| void | SetDataIdx (int idx) |
| const unsigned char * | Data (void) const |
| bool | AddCaDescr (const cEcmInfo *e) |
| bool | AddCaDescr (const unsigned char *descr, int len) |
| const unsigned char * | GetCaDescr (int *l) const |
| void | SetRewriter (void) |
| void | Fail (bool st) |
| bool | Failed (void) const |
| void | SetCached (void) |
| bool | Cached (void) const |
Public Attributes | |
| char * | name |
| int | ecm_pid |
| int | ecm_table |
| int | caId |
| int | provId |
| int | emmCaId |
| int | prgId |
| int | grPrgId |
| int | source |
| int | transponder |
| cRewriter * | rewriter |
| int | rewriterId |
| int | dvbAdapter |
| int | dvbFrontend |
Protected Member Functions | |
| void | ClearCaDescr (void) |
| void | ClearCaDescr (void) |
Protected Attributes | |
| int | caDescrLen |
| int | dataIdx |
| unsigned char * | caDescr |
| cEcmInfo::cEcmInfo | ( | const cEcmInfo * | e | ) |
Definition at line 580 of file data.c.
References AddCaDescr(), caId, dataIdx, dvbAdapter, dvbFrontend, ecm_pid, ecm_table, emmCaId, grPrgId, name, prgId, provId, rewriterId, SetName(), SetRewriter(), Setup, SIDGRP_SHIFT, source, and transponder.
{
Setup(); SetName(e->name);
ecm_pid=e->ecm_pid;
ecm_table=e->ecm_table;
caId=e->caId;
emmCaId=e->emmCaId;
provId=e->provId;
AddCaDescr(e);
dataIdx=e->dataIdx;
grPrgId=e->grPrgId; prgId=grPrgId%SIDGRP_SHIFT;
source=e->source;
transponder=e->transponder;
rewriterId=e->rewriterId;
SetRewriter();
dvbAdapter=e->dvbAdapter; dvbFrontend=e->dvbFrontend;
}
| cEcmInfo::cEcmInfo | ( | const char * | Name, |
| int | Pid, | ||
| int | CaId, | ||
| int | ProvId | ||
| ) |
| cEcmInfo::~cEcmInfo | ( | ) |
Definition at line 606 of file data.c.
References ClearCaDescr(), free, name, and rewriter.
{
ClearCaDescr();
free(name);
delete rewriter;
}
| cEcmInfo::cEcmInfo | ( | void | ) |
| cEcmInfo::cEcmInfo | ( | const cEcmInfo * | e | ) |
| cEcmInfo::cEcmInfo | ( | const char * | Name, |
| int | Pid, | ||
| int | CaId, | ||
| int | ProvId | ||
| ) |
| cEcmInfo::~cEcmInfo | ( | ) |
| bool cEcmInfo::AddCaDescr | ( | const cEcmInfo * | e | ) |
Definition at line 646 of file data.c.
References caDescr, caDescrLen, and dataIdx.
Referenced by cEcmInfo(), cEcmCache::New(), and cEcmData::Parse().
{
bool res=AddCaDescr(e->caDescr,e->caDescrLen);
if(e->dataIdx>=0 && (dataIdx<0 || e->dataIdx!=dataIdx)) res=true;
dataIdx=e->dataIdx;
return res;
}
| bool cEcmInfo::AddCaDescr | ( | const unsigned char * | descr, |
| int | len | ||
| ) |
Definition at line 668 of file data.c.
References caDescr, caDescrLen, ClearCaDescr(), L_GEN_ERROR, MALLOC, and PRINTF.
{
bool res=false;
if(descr && (!caDescr || caDescrLen!=len || memcmp(caDescr,descr,len)!=0)) {
unsigned char *mem=MALLOC(unsigned char,len);
if(mem) {
ClearCaDescr();
memcpy(mem,descr,len);
caDescr=mem; caDescrLen=len;
res=true;
}
else PRINTF(L_GEN_ERROR,"malloc failed in cEcmInfo::AddCaDescr()");
}
return res;
}
| bool cEcmInfo::AddCaDescr | ( | const cEcmInfo * | e | ) |
| bool cEcmInfo::AddCaDescr | ( | const unsigned char * | descr, |
| int | len | ||
| ) |
| bool cEcmInfo::Cached | ( | void | ) | const [inline] |
| bool cEcmInfo::Cached | ( | void | ) | const [inline] |
| void cEcmInfo::ClearCaDescr | ( | void | ) | [protected] |
| void cEcmInfo::ClearCaDescr | ( | void | ) | [protected] |
Definition at line 641 of file data.c.
References caDescr, caDescrLen, and free.
Referenced by AddCaDescr(), and ~cEcmInfo().
{
free(caDescr); caDescr=0; caDescrLen=0;
}
| bool cEcmInfo::Compare | ( | const cEcmInfo * | e | ) |
| bool cEcmInfo::Compare | ( | const cEcmInfo * | e | ) |
| const unsigned char * cEcmInfo::Data | ( | void | ) | const |
Definition at line 695 of file data.c.
References caDescr, caDescrLen, and dataIdx.
Referenced by cSmartCardSeca::Decode().
| const unsigned char* cEcmInfo::Data | ( | void | ) | const |
| bool cEcmInfo::Failed | ( | void | ) | const [inline] |
| bool cEcmInfo::Failed | ( | void | ) | const [inline] |
| const unsigned char * cEcmInfo::GetCaDescr | ( | int * | l | ) | const |
Definition at line 684 of file data.c.
References caDescr, and caDescrLen.
Referenced by cCardClientGbox::ProcessECM(), and cCardClientCCcam::ProcessECM().
{
if(l) *l=caDescrLen;
return caDescr;
}
| const unsigned char* cEcmInfo::GetCaDescr | ( | int * | l | ) | const |
| void cEcmInfo::SetCached | ( | void | ) | [inline] |
Definition at line 259 of file data.h.
Referenced by cEcmCache::GetCached(), and cEcmCache::New().
{ cached=true; }
| void cEcmInfo::SetDataIdx | ( | int | idx | ) |
Definition at line 690 of file data.c.
References dataIdx.
Referenced by cSystem::ParseCADescriptor().
{
dataIdx=idx;
}
| void cEcmInfo::SetDataIdx | ( | int | idx | ) |
| void cEcmInfo::SetDvb | ( | int | DvbAdapter, |
| int | DvbFrontend | ||
| ) |
Definition at line 629 of file data.c.
References dvbAdapter, and dvbFrontend.
{
dvbAdapter=DvbAdapter; dvbFrontend=DvbFrontend;
}
| void cEcmInfo::SetDvb | ( | int | DvbAdapter, |
| int | DvbFrontend | ||
| ) |
| void cEcmInfo::SetName | ( | const char * | Name | ) |
Definition at line 700 of file data.c.
Referenced by cEcmInfo(), cEcmCache::New(), and cEcmData::Parse().
| void cEcmInfo::SetName | ( | const char * | Name | ) |
| void cEcmInfo::SetRewriter | ( | void | ) |
| void cEcmInfo::SetRewriter | ( | void | ) |
Definition at line 654 of file data.c.
References cRewriters::CreateById(), cRewriter::Id(), rewriter, and rewriterId.
Referenced by cEcmInfo(), and cEcmData::Parse().
{
if(rewriterId>0) {
if(!rewriter || rewriter->Id()!=rewriterId) {
delete rewriter;
rewriter=cRewriters::CreateById(rewriterId);
}
}
else {
delete rewriter;
rewriter=0;
}
}
| void cEcmInfo::SetSource | ( | int | GrPrgId, |
| int | Source, | ||
| int | Transponder | ||
| ) |
Definition at line 634 of file data.c.
References grPrgId, prgId, SIDGRP_SHIFT, source, and transponder.
Referenced by main().
{
grPrgId=GrPrgId; prgId=grPrgId%SIDGRP_SHIFT;
source=Source;
transponder=Transponder;
}
| void cEcmInfo::SetSource | ( | int | GrPrgId, |
| int | Source, | ||
| int | Transponder | ||
| ) |
| virtual cString cEcmInfo::ToString | ( | bool | hide = false | ) | [inline, virtual] |
Reimplemented from cStructItem.
Reimplemented in cEcmData, and cEcmData.
Definition at line 246 of file data.h.
{ return ""; }
| virtual cString cEcmInfo::ToString | ( | bool | hide = false | ) | [inline, virtual] |
Reimplemented from cStructItem.
Reimplemented in cEcmData, and cEcmData.
Definition at line 246 of file data.h.
{ return ""; }
unsigned char * cEcmInfo::caDescr [protected] |
Definition at line 230 of file data.h.
Referenced by AddCaDescr(), ClearCaDescr(), Data(), GetCaDescr(), and cEcmData::ToString().
int cEcmInfo::caDescrLen [protected] |
Definition at line 229 of file data.h.
Referenced by AddCaDescr(), ClearCaDescr(), Data(), GetCaDescr(), and cEcmData::ToString().
| int cEcmInfo::caId |
Definition at line 236 of file data.h.
Referenced by cEcmInfo(), cSystem::CheckECM(), cSystem::CheckECMResult(), Compare(), cLogger::EcmStatus(), cEcmCache::GetCached(), cShares::GetShares(), cEcmData::Parse(), cEcmHandler::Process(), cSystemNagra2::ProcessECM(), cSystemIrd2::ProcessECM(), cSystemCryptoworks::ProcessECM(), cSystemConstCw::ProcessECM(), cCardClientRadegast::ProcessECM(), cCardClientNewCamd::ProcessECM(), cCardClientGbox::ProcessECM(), cCardClientCCcam2::ProcessECM(), cCardClientCCcam::ProcessECM(), cSystemCardClient::ProcessECM(), cCardClientCamd35::ProcessECM(), cCardClientCommon::ProcessECM(), cSystem::StartLog(), cEcmData::ToString(), and cOverrides::UpdateEcm().
int cEcmInfo::dataIdx [protected] |
Definition at line 229 of file data.h.
Referenced by AddCaDescr(), cEcmInfo(), Data(), cEcmData::Parse(), SetDataIdx(), and cEcmData::ToString().
Definition at line 240 of file data.h.
Referenced by cEcmInfo(), cCardClientCCcam::ProcessECM(), and SetDvb().
Definition at line 240 of file data.h.
Referenced by cEcmInfo(), cCardClientCCcam::ProcessECM(), and SetDvb().
Definition at line 235 of file data.h.
Referenced by cEcmShares::AddStatus(), cEcmInfo(), cEcmShare::cEcmShare(), Compare(), cEcmCache::Delete(), cEcmShares::FindStatus(), cEcmCache::GetCached(), cEcmCache::New(), cEcmData::Parse(), cCardClientGbox::ProcessECM(), cCardClientCCcam2::ProcessECM(), cCardClientCCcam::ProcessECM(), and cEcmData::ToString().
Definition at line 235 of file data.h.
Referenced by cEcmInfo(), cEcmCache::Delete(), cEcmCache::GetCached(), cEcmCache::New(), cEcmData::Parse(), cEcmData::ToString(), and cOverrides::UpdateEcm().
Definition at line 236 of file data.h.
Referenced by cEcmInfo(), cEcmData::Parse(), cSystem::StartLog(), cEcmData::ToString(), and cOverrides::UpdateEcm().
Definition at line 237 of file data.h.
Referenced by cEcmInfo(), Compare(), cEcmCache::Delete(), cEcmCache::GetCached(), cEcmCache::New(), cEcmData::Parse(), SetSource(), and cEcmData::ToString().
| char * cEcmInfo::name |
Definition at line 234 of file data.h.
Referenced by cEcmInfo(), cEcmCache::GetCached(), cEcmCache::New(), SetName(), cEcmData::ToString(), and ~cEcmInfo().
| int cEcmInfo::prgId |
Definition at line 237 of file data.h.
Referenced by cEcmInfo(), cLogger::EcmStatus(), cPlainKeyConstCw::Matches(), cEcmData::Parse(), cCardClientNewCamd::ProcessECM(), cCardClientGbox::ProcessECM(), cCardClientCCcam2::ProcessECM(), cCardClientCCcam::ProcessECM(), cCardClientCamd35::ProcessECM(), and SetSource().
| int cEcmInfo::provId |
Definition at line 236 of file data.h.
Referenced by cEcmInfo(), Compare(), cLogger::EcmStatus(), cEcmCache::GetCached(), cShares::GetShares(), cEcmData::Parse(), cEcmHandler::Process(), cSystemViaccess::ProcessECM(), cSystemSeca::ProcessECM(), cCardClientRadegast::ProcessECM(), cCardClientGbox::ProcessECM(), cCardClientCCcam2::ProcessECM(), cCardClientCCcam::ProcessECM(), cCardClientCamd35::ProcessECM(), cEcmData::ToString(), and cOverrides::UpdateEcm().
Definition at line 238 of file data.h.
Referenced by cEcmHandler::Process(), SetRewriter(), cOverrides::UpdateEcm(), and ~cEcmInfo().
Definition at line 239 of file data.h.
Referenced by cEcmInfo(), cEcmData::Parse(), SetRewriter(), cEcmData::ToString(), and cOverrides::UpdateEcm().
| int cEcmInfo::source |
Definition at line 237 of file data.h.
Referenced by cEcmShares::AddStatus(), cEcmInfo(), cEcmShare::cEcmShare(), Compare(), cEcmCache::Delete(), cLogger::EcmStatus(), cEcmShares::FindStatus(), cEcmCache::GetCached(), cPlainKeyConstCw::Matches(), cEcmCache::New(), cEcmData::Parse(), cSystemViaccess::ProcessECM(), cSystemNagra2::ProcessECM(), SetSource(), cEcmData::ToString(), and cOverrides::UpdateEcm().
Definition at line 237 of file data.h.
Referenced by cEcmShares::AddStatus(), cEcmInfo(), cEcmShare::cEcmShare(), Compare(), cEcmCache::Delete(), cLogger::EcmStatus(), cEcmShares::FindStatus(), cEcmCache::GetCached(), cPlainKeyConstCw::Matches(), cEcmCache::New(), cEcmData::Parse(), cSystemViaccess::ProcessECM(), cCardClientCCcam::ProcessECM(), SetSource(), cEcmData::ToString(), and cOverrides::UpdateEcm().