Changeset 1277


Ignore:
Timestamp:
01/18/10 05:05:18 (11 years ago)
Author:
rorothetroll
Message:

resync with trunk

Location:
branches/smartreader
Files:
8 edited

Legend:

Unmodified
Added
Removed
  • branches/smartreader/Distribution/doc/example/oscam.user

    r867 r1277  
    3030caid       = 0200
    3131
    32 # user for group 2 without monitor access, AU disabled
     32# user for group 2 without monitor access, AU disabled, account disabled
    3333
    3434[account]
    3535user       = user3
    3636pwd        = password3
     37disabled   = 1
    3738group      = 2
    3839services   = services2
     
    4041caid       = 0200
    4142
    42 # user for group 3 without monitor access, only one connection possible, AU disabled
     43# user for group 3 without monitor access, only one connection possible, AU disabled, multiple idents
    4344
    4445[account]
     
    4849uniq       = 1
    4950group      = 3
    50 ident      = 0300:000000
     51ident      = 0300:000000,FFFFFF;0400:FFFFFF
    5152caid       = 0300
  • branches/smartreader/Distribution/doc/man/oscam.server.5

    r1225 r1277  
    9393.RE
    9494.PP
    95 \fBdetect\fP = \fBCD\fP|\fBDSR\fP|\fBCTS\fP|\fBRING\fP|\fBNONE\fP|\fBgpio[2-7]\fP
     95\fBdetect\fP = \fBCD\fP|\fBDSR\fP|\fBCTS\fP|\fBRING\fP|\fBNONE\fP|\fBgpio[1-7]\fP
    9696.RS 3n
    9797status detect of card (NONE = no detection), default:CD
  • branches/smartreader/Distribution/doc/man/oscam.user.5

    r1072 r1277  
    7676.RE
    7777.PP
    78 \fBident\fP = \fB<CAID>:<ident>[,<CAID>:<ident>]...\fP
     78\fBident\fP = \fB<CAID>:<ident>[,<ident>,...][;<CAID>:<ident>[,<ident>,...]]...\fP
    7979.RS 3n
    8080user assingment to idents, default:none
     
    112112.RE
    113113.PP
     114\fBdisabled\fP = \fB0\fP|\fB1\fP
     115.RS 3n
     1161 = account disabled, default:0
     117.RE
     118.PP
    114119\fBnumusers\fP = \fBquantity\fP \fI(only if anti-cascading enabled)\fR
    115120.RS 3n
  • branches/smartreader/Distribution/doc/txt/oscam.server.txt

    r1225 r1277  
    6969      AES key for Viaccess SCs
    7070
    71        detect = CD|DSR|CTS|RING|NONE|gpio[2-7]
     71       detect = CD|DSR|CTS|RING|NONE|gpio[1-7]
    7272      status detect of card (NONE = no detection), default:CD
    7373
  • branches/smartreader/Distribution/doc/txt/oscam.user.txt

    r1072 r1277  
    6060      user [de]assingment to service group, default:none
    6161
    62        ident = <CAID>:<ident>[,<CAID>:<ident>]...
     62       ident  = <CAID>:<ident>[,<ident>,...][;<CAID>:<ident>[,<ident>,...]]...
    6363      user assingment to idents, default:none
    6464
     
    8686            expdate = 2002/12/22
    8787
     88       disabled = 0|1
     89      1 = account disabled, default:0
     90
    8891       numusers = quantity (only if anti-cascading enabled)
    89       anti-cascading:  user per account, 0 = anti-cascading not permitted,
     92      anti-cascading: user per account, 0 = anti-cascading not permitted,
    9093      default:0
    9194
     
    103106
    104107SEE ALSO
    105        oscam(1),     oscam.conf(5),  oscam.server(5),      oscam.srvid(5),
    106        oscam.guess(5),    oscam.cert(5),    oscam.services(5),   oscam.ird(5),
     108       oscam(1),      oscam.conf(5),      oscam.server(5),     oscam.srvid(5),
     109       oscam.guess(5),   oscam.cert(5),    oscam.services(5),    oscam.ird(5),
    107110       oscam.ac(5)
    108111
  • branches/smartreader/globals.h

    r1271 r1277  
    321321  time_t    lastecm;
    322322  time_t    expirationdate;
     323  int       disabled;
    323324  ulong     grp;
    324325  int       crypted;
     
    501502  uchar     dyndns[64];
    502503  time_t    expirationdate;
    503   struct   s_auth *next;
     504  int       disabled;
     505  struct    s_auth *next;
    504506};
    505507
  • branches/smartreader/oscam-config.c

    r1254 r1277  
    746746  if (!strcmp(token, "monlevel")) { account->monlvl=atoi(value); return; }
    747747  if (!strcmp(token, "caid")) { chk_caidtab(value, &account->ctab); return; }
     748  if (!strcmp(token, "disabled")) { account->disabled=atoi(value); return; }
    748749  /*
    749750   *  case insensitive
     
    828829int init_userdb()
    829830{
    830   int tag=0, nr, nro, expired;
     831  int tag=0, nr, nro, expired, disabled;
    831832  //int first=1;
    832833  FILE *fp;
     
    889890  fclose(fp);
    890891
    891   for (expired=0, ptr=cfg->account; ptr;)
     892  for (expired=0, disabled=0, ptr=cfg->account; ptr;)
    892893  {
    893894    if(ptr->expirationdate && ptr->expirationdate<time(NULL)) expired++;
     895    if(ptr->disabled != 0) disabled++;
    894896    ptr=ptr->next;
    895897  }
    896898
    897   cs_log("userdb reloaded: %d accounts freed, %d accounts loaded, %d expired", nro, nr, expired);
     899  cs_log("userdb reloaded: %d accounts freed, %d accounts loaded, %d expired, %d disabled", nro, nr, expired, disabled);
    898900  return(0);
    899901}
  • branches/smartreader/oscam.c

    r1144 r1277  
    343343        client[i].autoau  = account->autoau;
    344344        client[i].expirationdate = account->expirationdate;
    345         client[i].tosleep = (60*account->tosleep);
     345        client[i].disabled = account->disabled;
     346    client[i].tosleep = (60*account->tosleep);
    346347        client[i].monlvl  = account->monlvl;
    347348        client[i].fchid   = account->fchid;  // CHID filters
     
    15271528  static char *stxt[]={"found", "cache1", "cache2", "emu",
    15281529                       "not found", "timeout", "sleeping",
    1529                        "fake", "invalid", "corrupt", "no card", "expdate"};
     1530                       "fake", "invalid", "corrupt", "no card", "expdate", "disabled"};
    15301531  static char *stxtEx[]={"", "group", "caid", "ident", "class", "chid", "queue", "peer"};
    15311532  static char *stxtWh[]={"", "user ", "reader ", "server ", "lserver "};
     
    18111812    if(client[cs_idx].expirationdate && client[cs_idx].expirationdate<client[cs_idx].lastecm)
    18121813      er->rc=11; //expired
     1814    if(client[cs_idx].disabled != 0)
     1815      er->rc=12; //disabled
    18131816    if ((client[cs_idx].tosleep) &&
    18141817        (now-client[cs_idx].lastswitch>client[cs_idx].tosleep))
Note: See TracChangeset for help on using the changeset viewer.