SASC-NG
DVBSoftCAM

cCardIrdeto Class Reference

#include <parse.h>

Inheritance diagram for cCardIrdeto:

List of all members.

Public Member Functions

 cCardIrdeto (void)
 cCardIrdeto (unsigned char hb, const unsigned char *hs)
virtual bool MatchEMM (const unsigned char *data)
virtual int UpdateType (const unsigned char *data)

Public Attributes

unsigned char hexBase
unsigned char hexSer [3]

Detailed Description

Definition at line 96 of file parse.h.


Constructor & Destructor Documentation

cCardIrdeto::cCardIrdeto ( void  ) [inline]

Definition at line 101 of file parse.h.

{}
cCardIrdeto::cCardIrdeto ( unsigned char  hb,
const unsigned char *  hs 
)

Definition at line 194 of file parse.c.

References hexBase, and hexSer.

{
  hexBase=hb;
  memcpy(hexSer,hs,sizeof(hexSer));
}

Member Function Documentation

bool cCardIrdeto::MatchEMM ( const unsigned char *  data) [virtual]

Implements cCard.

Definition at line 200 of file parse.c.

References cParseIrdeto::AddrBase(), cParseIrdeto::AddrLen(), hexBase, and hexSer.

{
  const unsigned int len=cParseIrdeto::AddrLen(data);
  const unsigned int mode=cParseIrdeto::AddrBase(data);
  return (   mode>=0x10 && len<=sizeof(hexSer)
          && mode==hexBase && (!len || !memcmp(&data[4],hexSer,len)));
}
int cCardIrdeto::UpdateType ( const unsigned char *  data) [virtual]

Reimplemented from cCard.

Definition at line 208 of file parse.c.

References cParseIrdeto::AddrLen().

{
  switch(cParseIrdeto::AddrLen(data)) {
    case 0:  return 0; // global
    case 1:
    case 2:  return 2; // shared
    default: return 3; // unique
    }
}

Member Data Documentation

unsigned char cCardIrdeto::hexBase

Definition at line 98 of file parse.h.

Referenced by cCardIrdeto(), MatchEMM(), and cSystemIrd::ProcessEMM().


The documentation for this class was generated from the following files:
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines