Changeset 4348
- Timestamp:
- 01/06/11 22:34:29 (13 years ago)
- Location:
- trunk
- Files:
-
- 7 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/Distribution/doc/man/oscam.server.5
r4344 r4348 340 340 .RE 341 341 .PP 342 \fBaeskey\fP = \fBAES key\fP343 .RS 3n344 16 bytes AES key for Viaccess SCs345 .RE346 .PP347 342 \fBaeskeys\fP = \fBCAID #0\fP@\fBident\fP:\fBAES key #0 CAID #0\fP[,\fBAES key #1 CAID #0\fP],...[;\fBCAID #1\fP@\fBident\fP:\fBAES key #0 CAID #1\fP[,\fBAES key #1 CAID #1\fP],...]... 348 343 .RS 3n … … 356 351 example: 357 352 358 aeskeys = 0 100@012345:000102030405060708090a0b0c0d0e0f;0200@543210:0,0,0f0e0d0c0b0a090807060504030201353 aeskeys = 0500@012345:000102030405060708090a0b0c0d0e0f;0500@543210:000102030405060708090a0b0c0d0e0f,0,0f0e0d0c0b0a090807060504030201 359 354 .RE 360 355 .PP -
trunk/Distribution/doc/txt/oscam.server.txt
r4344 r4348 250 250 box key for Nagravision SCs / CAM key for Irdeto SCs 251 251 252 aeskey = AES key253 16 bytes AES key for Viaccess SCs254 255 252 aeskeys = CAID #0@ident:AES key #0 CAID #0[,AES key #1 CAID #0],...[;CAID #1@ident:AES key #0 CAID #1[,AES key #1 256 253 CAID #1],...]... 257 multiple 16 bytes AES keys for Viaccess SCs 254 multiple 16 bytes AES keys for Viaccess SCs (the used postprocessing AES key # is specified through the D2 nano of the ECM) 258 255 259 256 special AES keys: … … 264 261 example: 265 262 266 aeskeys = 0 100@012345:000102030405060708090a0b0c0d0e0f;0200@543210:0,0,0f0e0d0c0b0a090807060504030201263 aeskeys = 0500@012345:000102030405060708090a0b0c0d0e0f;0500@543210:000102030405060708090a0b0c0d0e0f,0,0f0e0d0c0b0a090807060504030201 267 264 268 265 showcls = quantity -
trunk/globals.h
r4347 r4348 777 777 char country_code[3]; // irdeto country code. 778 778 int force_irdeto; 779 uchar aes_key[16];780 779 uchar rsa_mod[120]; //rsa modulus for nagra cards. 781 780 uchar atr[64]; -
trunk/oscam-config.c
r4346 r4348 2253 2253 if (rdr->boxid && isphysical) 2254 2254 fprintf_conf(f, CONFVARWIDTH, "boxid", "%08X\n", rdr->boxid); 2255 2256 if (check_filled(rdr->aes_key, 16) > 0 && isphysical)2257 fprintf_conf(f, CONFVARWIDTH, "aeskey", "%s\n", cs_hexdump(0, rdr->aes_key, 16));2258 2255 2259 2256 // rsakey … … 3184 3181 } 3185 3182 3186 if (!strcmp(token, "aeskey")) {3187 if (strlen(value) != 32 ){3188 memset(rdr->aes_key, 0, 16);3189 return;3190 } else {3191 if (key_atob_l(value, rdr->aes_key, 32)) {3192 fprintf(stderr, "Configuration reader: Error in AES Key\n");3193 exit(1);3194 }3195 return;3196 }3197 }3198 3199 3183 if (!strcmp(token, "rsakey")) { 3200 3184 int len = strlen(value); -
trunk/oscam-http.c
r4346 r4348 908 908 tpl_addVar(vars, 0, "FORCEIRDETOCHECKED", "checked"); 909 909 910 int len = check_filled(rdr->aes_key, 16); 911 if(len > 0) { 912 for (i = 0; i < 16; i++) tpl_printf(vars, 1, "AESKEY", "%02X", rdr->aes_key[i]); 913 } 914 915 len = check_filled(rdr->rsa_mod, 120); 910 int len = check_filled(rdr->rsa_mod, 120); 916 911 if(len > 0) { 917 912 if(len > 64) len = 120; -
trunk/oscam-http.h
r4344 r4348 881 881 <TR><TD>Force Irdeto:<input name=\"force_irdeto\" type=\"hidden\" value=\"0\"></TD><TD><input name=\"force_irdeto\" type=\"checkbox\" value=\"1\" ##FORCEIRDETOCHECKED##></TD></TR>\n\ 882 882 <TR><TD>Boxid:</TD><TD><input name=\"boxid\" type=\"text\" size=\"15\" maxlength=\"8\" value=\"##BOXID##\"></TD></TR>\n\ 883 <TR><TD>AES Key:</TD><TD><input name=\"aeskey\" type=\"text\" size=\"35\" maxlength=\"32\" value=\"##AESKEY##\"></TD></TR>\n\884 883 <TR><TD>AES Keys:</TD><TD><textarea name=\"aeskeys\" cols=\"98\" rows=\"4\" class=\"bt\" maxlength=\"128\">##AESKEYS##</textarea></TD></TR>\n\ 885 <TR><TD>RSA key:</TD><TD><textarea name=\"rsakey\" cols=\"98\" rows=\"4\" class=\"bt\" maxlength=\"128\">##RSAKEY##</textarea></TD></TR>\n\884 <TR><TD>RSA Key:</TD><TD><textarea name=\"rsakey\" cols=\"98\" rows=\"4\" class=\"bt\" maxlength=\"128\">##RSAKEY##</textarea></TD></TR>\n\ 886 885 <TR><TD>Boxkey:</TD><TD><input name=\"boxkey\" type=\"text\" size=\"20\" maxlength=\"16\" value=\"##BOXKEY##\"></TD></TR>\n\ 887 886 <TR><TD>ATR:</TD><TD><input name=\"atr\" type=\"text\" size=\"100\" maxlength=\"54\" value=\"##ATR##\"></TD></TR>\n\ -
trunk/reader-viaccess.c
r4141 r4348 247 247 reader->nprov=i; 248 248 cs_ri_log(reader, "providers: %d (%s)", reader->nprov, buf+1); 249 250 /* init the maybe existing aes key */ 251 aes_set_key((char *)reader->aes_key); 252 249 253 250 if (cfg->ulparent) 254 251 unlock_parental(reader); … … 441 438 } 442 439 // use AES from list to decrypt CW 443 if(reader->aes_list) 444 { 445 cs_debug_mask(D_READER, "Decoding CW : using AES key id %d for provider %06x",D2KeyID, (provid & 0xFFFFF0)); 446 rc=aes_decrypt_from_list(reader->aes_list,0x500, (uint32) (provid & 0xFFFFF0), D2KeyID, &ecm88DataCW[0], 16); 447 if( rc == 0 ) 448 snprintf( er->msglog, MSGLOGSIZE, "AES Decrypt : key id %d not found for CAID %04X , provider %06lx", D2KeyID, 0x500, (provid & 0xFFFFF0) ); 449 } 450 else 451 { 452 aes_decrypt(&ecm88DataCW[0], 16); 453 } 440 cs_debug_mask(D_READER, "Decoding CW : using AES key id %d for provider %06x",D2KeyID, (provid & 0xFFFFF0)); 441 rc=aes_decrypt_from_list(reader->aes_list,0x500, (uint32) (provid & 0xFFFFF0), D2KeyID, &ecm88DataCW[0], 16); 442 if( rc == 0 ) 443 snprintf( er->msglog, MSGLOGSIZE, "AES Decrypt : key id %d not found for CAID %04X , provider %06lx", D2KeyID, 0x500, (provid & 0xFFFFF0) ); 454 444 } 455 445 … … 522 512 523 513 if ( hasD2 && !check_crc(er->cw) && nanoD2 == 2) { 524 if(reader->aes_list) { 525 cs_debug_mask(D_READER, "Decoding CW : using AES key id %d for provider %06x",D2KeyID, (provid & 0xFFFFF0)); 526 rc=aes_decrypt_from_list(reader->aes_list,0x500, (uint32) (provid & 0xFFFFF0), D2KeyID,er->cw, 16); 527 if( rc == 0 ) 528 snprintf( er->msglog, MSGLOGSIZE, "AES Decrypt : key id %d not found for CAID %04X , provider %06lx", D2KeyID, 0x500, (provid & 0xFFFFF0) ); 529 } 530 else 531 aes_decrypt(er->cw, 16); 514 cs_debug_mask(D_READER, "Decoding CW : using AES key id %d for provider %06x",D2KeyID, (provid & 0xFFFFF0)); 515 rc=aes_decrypt_from_list(reader->aes_list,0x500, (uint32) (provid & 0xFFFFF0), D2KeyID,er->cw, 16); 516 if( rc == 0 ) 517 snprintf( er->msglog, MSGLOGSIZE, "AES Decrypt : key id %d not found for CAID %04X , provider %06lx", D2KeyID, 0x500, (provid & 0xFFFFF0) ); 532 518 } 533 519
Note:
See TracChangeset
for help on using the changeset viewer.