Opened 13 years ago

Closed 13 years ago

#1003 closed defect (fixed)

OScam with two or more pcsc readers don't work

Reported by: roni261980 Owned by: roni261980
Priority: major Component: Reader
Severity: medium Keywords:
Cc: roni261980, lubos@… Sensitive: no

Description

i compiled oscam with pcsc suport but with all threaded versions of oscam it don't work. i get this: loged with -d255


OSCam << cardserver started at Wed Oct 6 19:53:37 2010


2010/10/06 19:53:37 31902 s version=1.00-svn, build #3396, system=mips-wrt54g-linux, nice=-5
2010/10/06 19:53:37 31902 s max. clients=29, client max. idle=120 sec, debug level=255
2010/10/06 19:53:37 31902 s max. logsize=3000 Kb
2010/10/06 19:53:37 31902 s client timeout=5000 ms, fallback timeout=2500 ms, cache delay=120 ms
2010/10/06 19:53:37 31902 s auth size=4784
2010/10/06 19:53:37 31902 s services reloaded: 0 services freed, 14 services loaded
2010/10/06 19:53:37 31902 s userdb reloaded: 0 accounts freed, 2 accounts loaded, 0 expired, 0 disabled
2010/10/06 19:53:37 31902 s signal handling initialized (type=sysv)
2010/10/06 19:53:37 31902 s 431 service-id's loaded
2010/10/06 19:53:37 31902 s 38 tier-id's loaded
2010/10/06 19:53:37 31902 s 5 provid's loaded
2010/10/06 19:53:37 31902 s monitor: disabled
2010/10/06 19:53:37 31902 s camd 3.3x: disabled
2010/10/06 19:53:37 31902 s camd 3.5x: disabled
2010/10/06 19:53:37 31902 s cs378x: disabled
2010/10/06 19:53:37 31902 s newcamd: initialized (fd=6, port=xxxxx, crypted)
2010/10/06 19:53:37 31902 s CAID: 0B00
2010/10/06 19:53:37 31902 s provid #0: 000000
2010/10/06 19:53:37 31902 s newcamd: initialized (fd=8, port=xxxxx, crypted)
2010/10/06 19:53:37 31902 s CAID: 0BAA
2010/10/06 19:53:37 31902 s provid #0: 000000
2010/10/06 19:53:37 31902 s newcamd: initialized (fd=9, port=xxxxx, crypted)
2010/10/06 19:53:37 31902 s CAID: 183D
2010/10/06 19:53:37 31902 s provid #0: 005411
2010/10/06 19:53:37 31902 s newcamd: initialized (fd=10, port=xxxxx, crypted)
2010/10/06 19:53:37 31902 s CAID: 093B
2010/10/06 19:53:37 31902 s provid #0: 000000
2010/10/06 19:53:37 31902 s cccam: disabled
2010/10/06 19:53:37 31902 s radegast: disabled
2010/10/06 19:53:37 31904 s HTTP Server listening on port xxxxx
2010/10/06 19:53:37 31902 s http thread started
2010/10/06 19:53:37 31902 s creating thread for device 0 slot 0 with ridx 0 cs_idx 2
2010/10/06 19:53:37 31905 r02 PCSC establish context for PCSC reader 0
2010/10/06 19:53:37 31902 s reader thread started (pid=31902, device=0)
2010/10/06 19:53:37 31902 s creating thread for device 1 slot 0 with ridx 1 cs_idx 3
2010/10/06 19:53:37 31907 r03 PCSC establish context for PCSC reader 1
2010/10/06 19:53:37 31905 r02 PCSC reader 0: OmniKey CardMan 3121 00 00
2010/10/06 19:53:37 31905 r02 PCSC reader 1: OmniKey CardMan 3121 01 00
2010/10/06 19:53:37 31905 r02 PCSC reader 2: OmniKey CardMan 3121 02 00
2010/10/06 19:53:37 31905 r02 PCSC reader 3: OmniKey CardMan 3121 03 00
2010/10/06 19:53:37 31907 r03 PCSC reader 0: OmniKey CardMan 3121 00 00
2010/10/06 19:53:37 31907 r03 PCSC reader 1: OmniKey CardMan 3121 01 00
2010/10/06 19:53:37 31907 r03 PCSC reader 2: OmniKey CardMan 3121 02 00
2010/10/06 19:53:37 31907 r03 PCSC reader 3: OmniKey CardMan 3121 03 00
2010/10/06 19:53:37 31902 s reader thread started (pid=31902, device=1)
2010/10/06 19:53:37 31902 s creating thread for device 2 slot 0 with ridx 2 cs_idx 4
2010/10/06 19:53:37 31909 r04 PCSC establish context for PCSC reader 2
2010/10/06 19:53:37 31902 s reader thread started (pid=31902, device=2)
2010/10/06 19:53:37 31902 s creating thread for device 3 slot 0 with ridx 3 cs_idx 5
2010/10/06 19:53:37 31911 r05 PCSC establish context for PCSC reader 3
2010/10/06 19:53:37 31902 s reader thread started (pid=31902, device=3)
2010/10/06 19:53:37 31902 s waiting for local card init
2010/10/06 19:53:37 31909 r04 PCSC reader 0: OmniKey CardMan 3121 00 00
2010/10/06 19:53:37 31909 r04 PCSC reader 1: OmniKey CardMan 3121 01 00
2010/10/06 19:53:37 31909 r04 PCSC reader 2: OmniKey CardMan 3121 02 00
2010/10/06 19:53:37 31909 r04 PCSC reader 3: OmniKey CardMan 3121 03 00
2010/10/06 19:53:37 31911 r05 PCSC reader 0: OmniKey CardMan 3121 00 00
2010/10/06 19:53:37 31911 r05 PCSC reader 1: OmniKey CardMan 3121 01 00
2010/10/06 19:53:37 31911 r05 PCSC reader 2: OmniKey CardMan 3121 02 00
2010/10/06 19:53:37 31911 r05 PCSC reader 3: OmniKey CardMan 3121 03 00
2010/10/06 19:53:40 31902 s init for all local cards done
2010/10/06 19:53:40 31902 s anti cascading disabled

the last oscam svn that work is 3144 tag svn
can you fix please?

Attachments (1)

oscam log.txt (71.9 KB ) - added by av_jui 13 years ago.

Download all attachments as: .zip

Change History (32)

comment:1 by roni261980, 13 years ago

any soluton for this?please

comment:2 by roni261980, 13 years ago

please if posible fix this

comment:3 by idl0r, 13 years ago

You should give the developers some time...

comment:4 by Deas, 13 years ago

Owner: set to rorothetroll

comment:5 by rorothetroll, 13 years ago

Resolution: worksforme
Status: newclosed

I have only 1 reader on my config but I don't see this problem
Mine init the card :

2010/10/08 16:45:16 s A0751500 creating thread for device 0 slot 0 with ridx 1
2010/10/08 16:45:16 s A0751500 reader thread started (pid=29288, device=0)

2010/10/08 16:45:18 r B0185000 card detected
2010/10/08 16:45:18 r B0185000 Card activation attempt 1...
2010/10/08 16:45:19 r B0185000 type: SECA, caid: 0100, serial: XXXXXX, card: Siemens v3.0
2010/10/08 16:45:19 r B0185000 [seca-reader] provider: 1, valid: 0, name: SECA, expiry date: 1990/00/00
2010/10/08 16:45:19 r B0185000 [seca-reader] provider: 2, valid: 0, name: C?ble Num?rique, expiry date: 1998/11/30
2010/10/08 16:45:19 r B0185000 [seca-reader] provider: 3, valid: 0, name: CANAL+, expiry date: 1997/02/22
2010/10/08 16:45:19 r B0185000 providers: 3 (0000,0009,0003)
2010/10/08 16:45:19 r B0185000 [seca-reader] ins30_answer: 9000
2010/10/08 16:45:19 r B0185000 [seca-reader] ready for requests
2010/10/08 16:45:19 r B0185000 found cardsystem
2010/10/08 16:45:19 r B0185000 [seca-reader] no PBM for provider 1
2010/10/08 16:45:19 r B0185000 [seca-reader] PBM for provider 2: 0000000000100000
2010/10/08 16:45:19 r B0185000 [seca-reader] PBM for provider 3: 0000000000000002

test with latest version and re-open if the problem is still there.
R.

comment:6 by roni261980, 13 years ago

Cc: roni261980 added
Resolution: worksforme
Status: closedreopened

this is the log of pcsc daemon version 1.5.5
i receive this with all threaded versions of oscam

00000256 ccid_usb.c:929:get_data_rates() declared: 2929 bps
00000255 ccid_usb.c:929:get_data_rates() declared: 35156 bps
00000257 ccid_usb.c:929:get_data_rates() declared: 58593 bps
00006594 ifdhandler.c:364:IFDHGetCapabilities() tag: 0xFB0, usb:076b/3021:libusb:001:008 (lun: 30000)
00002141 readerfactory.c:249:RFAddReader() Using the pcscd polling thread
00003170 ifdhandler.c:364:IFDHGetCapabilities() tag: 0xFAE, usb:076b/3021:libusb:001:008 (lun: 30000)
00000315 ifdhandler.c:418:IFDHGetCapabilities() Reader supports 1 slot(s)
00001210 ifdhandler.c:1043:IFDHPowerICC() action: PowerUp, usb:076b/3021:libusb:001:008 (lun: 30000)
00000449 hotplug_libusb.c:403:HPEstablishUSBNotifications() Driver ifd-ccid.bundle does not support IFD_GENERATE_HOTPLUG. Using active polling instead.
00000620 hotplug_libusb.c:412:HPEstablishUSBNotifications() Polling forced every 1 second(s)
00314217 Card ATR: 3F FF 95 00 FF 91 81 71 FF 47 00 54 49 47 45 52 30 30 33 20 52 65 76 32 35 30 64

here i start oscam

30548639 winscard_msg_srv.c:239:SHMProcessEventsServer() Common channel packet arrival
00000416 winscard_msg_srv.c:248:SHMProcessEventsServer() SHMProcessCommonChannelRequest detects: 12
00000288 pcscdaemon.c:147:SVCServiceRunLoop() A new context thread creation is requested: 12
00003242 winscard_svc.c:133:ContextThread() Thread is started: 12
00008640 winscard_msg_srv.c:317:SHMProcessEventsContext() command CMD_VERSION received by client 12
00008436 winscard_svc.c:189:ContextThread() Client is protocol version 3:0
00009192 winscard_msg_srv.c:317:SHMProcessEventsContext() command ESTABLISH_CONTEXT received by client 12
00008685 winscard.c:242:SCardEstablishContext() Establishing Context: 17009991
00008124 winscard_msg_srv.c:306:SHMProcessEventsContext() Client has disappeared: 12
00003577 winscard_msg_srv.c:239:SHMProcessEventsServer() Common channel packet arrival
00000531 winscard_msg_srv.c:248:SHMProcessEventsServer() SHMProcessCommonChannelRequest detects: 12
00000285 pcscdaemon.c:147:SVCServiceRunLoop() A new context thread creation is requested: 12
00000377 winscard_svc.c:146:ContextThread() Client die: 12
00000265 winscard.c:253:SCardReleaseContext() Releasing Context: 17009991
00002807 winscard_svc.c:133:ContextThread() Thread is started: 12
00000449 winscard_msg_srv.c:317:SHMProcessEventsContext() command CMD_VERSION received by client 12
00000285 winscard_svc.c:189:ContextThread() Client is protocol version 3:0
00001870 winscard_msg_srv.c:317:SHMProcessEventsContext() command ESTABLISH_CONTEXT received by client 12
00000406 winscard.c:242:SCardEstablishContext() Establishing Context: 17005090
00011819 winscard_msg_srv.c:239:SHMProcessEventsServer() Common channel packet arrival
00000374 winscard_msg_srv.c:248:SHMProcessEventsServer() SHMProcessCommonChannelRequest detects: 13
00000284 pcscdaemon.c:147:SVCServiceRunLoop() A new context thread creation is requested: 13
00000592 winscard_msg_srv.c:306:SHMProcessEventsContext() Client has disappeared: 12
00002248 winscard_svc.c:146:ContextThread() Client die: 12
00000277 winscard.c:253:SCardReleaseContext() Releasing Context: 17005090
00003270 winscard_svc.c:133:ContextThread() Thread is started: 13
00008509 winscard_msg_srv.c:317:SHMProcessEventsContext() command CMD_VERSION received by client 13
00007701 winscard_svc.c:189:ContextThread() Client is protocol version 3:0
00009091 winscard_msg_srv.c:317:SHMProcessEventsContext() command ESTABLISH_CONTEXT received by client 13
00008360 winscard.c:242:SCardEstablishContext() Establishing Context: 16988514
00008747 winscard_msg_srv.c:239:SHMProcessEventsServer() Common channel packet arrival
00000388 winscard_msg_srv.c:248:SHMProcessEventsServer() SHMProcessCommonChannelRequest detects: 12
00000285 pcscdaemon.c:147:SVCServiceRunLoop() A new context thread creation is requested: 12
00001869 winscard_msg_srv.c:306:SHMProcessEventsContext() Client has disappeared: 13
00001129 winscard_svc.c:133:ContextThread() Thread is started: 12
00000448 winscard_msg_srv.c:317:SHMProcessEventsContext() command CMD_VERSION received by client 12
00000286 winscard_svc.c:189:ContextThread() Client is protocol version 3:0
00000775 winscard_msg_srv.c:317:SHMProcessEventsContext() command ESTABLISH_CONTEXT received by client 12
00000399 winscard.c:242:SCardEstablishContext() Establishing Context: 16994968
00004114 winscard_svc.c:146:ContextThread() Client die: 13
00000277 winscard.c:253:SCardReleaseContext() Releasing Context: 16988514
00012279 winscard_msg_srv.c:306:SHMProcessEventsContext() Client has disappeared: 12
00001946 winscard_svc.c:146:ContextThread() Client die: 12
00000273 winscard.c:253:SCardReleaseContext() Releasing Context: 16994968

platform (mips) asus router 32mb ram and 80mb swap

Last edited 13 years ago by roni261980 (previous) (diff)

comment:7 by rorothetroll, 13 years ago

I'll test with multiple reader latter but as far as I can tell this is a special case for your platform as I don't see this on mine with the threaded version.

comment:8 by roni261980, 13 years ago

ok,but with the all no threaded versions it work very very good.i change only the bin and not work any more.this i do not understand

comment:9 by roni261980, 13 years ago

Sensitive: set
Summary: PCSC suportOScam with two or more pcsc readers don't work

i discovered this: all the threaded version of oscam don't work with 2 or more pcsc readers
(works very fine with one reader)
can any one confirm this?i think this is a bug.i need help

comment:10 by roni261980, 13 years ago

Owner: changed from rorothetroll to roni261980
Sensitive: unset
Status: reopenednew

comment:11 by av_jui, 13 years ago

Hallo

I can confirm this. I have testet view Version´s. At the moment I have tested 3262, 3295, 3423 at my wrt1043nd. The last Version it works correct is the 3009, but I don´t have tested the version between 3009 and 3262.

mfg

comment:12 by roni261980, 13 years ago

any solution for this please
i have four pcsc reader (omnikey 3121) and oscam work only with one

comment:13 by roni261980, 13 years ago

is posible to resolve this?please

comment:14 by av_jui, 13 years ago

Hi

I have tested Version 3506. The same problem. All 3 pcsc raeder have the status off.

I have make a log with -d 255. I hope this will be helpfull.

mfg

by av_jui, 13 years ago

Attachment: oscam log.txt added

comment:15 by roni261980, 13 years ago

oscam only with one pcsc reader

please resolve this

comment:16 by roni261980, 13 years ago

HELP

comment:17 by Deas, 13 years ago

do you really think pushing a ticket will help to get it fixed earlier?!? i don´t think so...

comment:18 by Deas, 13 years ago

Resolution: fixed
Status: newclosed

please test with latest build and report in forum for UNSTABLE trunk...

comment:19 by roni261980, 13 years ago

don't work

OSCam << cardserver started at Fri Oct 22 20:07:43 2010



2010/10/22 20:07:43 400 s version=1.00-unstable_svn, build #3673, system=mips-wrt54g-linux, nice=-5
2010/10/22 20:07:43 400 s client max. idle=120 sec, debug level=255
2010/10/22 20:07:43 400 s max. logsize=3000 Kb
2010/10/22 20:07:43 400 s client timeout=5000 ms, fallback timeout=2500 ms, cache delay=120 ms
2010/10/22 20:07:43 400 s auth size=4800
2010/10/22 20:07:43 400 s services reloaded: 0 services freed, 0 services loaded
2010/10/22 20:07:43 400 s userdb reloaded: 0 accounts freed, 2 accounts loaded, 0 expired, 0 disabled
2010/10/22 20:07:43 400 s signal handling initialized (type=sysv)
2010/10/22 20:07:43 400 s 431 service-id's loaded
2010/10/22 20:07:43 400 s 38 tier-id's loaded
2010/10/22 20:07:43 400 s 5 provid's loaded
2010/10/22 20:07:43 400 s can't open file "/jffs/oscam-test/oscam.ird" (errno=2) irdeto guessing not loaded
2010/10/22 20:07:43 400 s monitor: disabled
2010/10/22 20:07:43 400 s camd33: disabled
2010/10/22 20:07:43 400 s camd35: disabled
2010/10/22 20:07:43 400 s cs378x: disabled
2010/10/22 20:07:43 400 s newcamd: initialized (fd=6, port=29635, crypted)
2010/10/22 20:07:43 400 s CAID: 0B00
2010/10/22 20:07:43 400 s provid #0: 000000
2010/10/22 20:07:43 400 s newcamd: initialized (fd=8, port=29636, crypted)
2010/10/22 20:07:43 400 s CAID: 0BAA
2010/10/22 20:07:43 400 s provid #0: 000000
2010/10/22 20:07:43 400 s newcamd: initialized (fd=9, port=29634, crypted)
2010/10/22 20:07:43 400 s CAID: 183D
2010/10/22 20:07:43 400 s provid #0: 005411
2010/10/22 20:07:43 400 s newcamd: initialized (fd=10, port=29637, crypted)
2010/10/22 20:07:43 400 s CAID: 093B
2010/10/22 20:07:43 400 s provid #0: 000000
2010/10/22 20:07:43 400 s cccam: disabled
2010/10/22 20:07:43 400 s radegast: disabled
2010/10/22 20:07:43 402 h HTTP Server listening on port 9699
2010/10/22 20:07:43 400 s http thread started
2010/10/22 20:07:43 400 s creating thread for device 0 slot 0
2010/10/22 20:07:43 803 r reader thread started (thread= 803, device=0, detect=ring, mhz=357, cardmhz=357)
2010/10/22 20:07:43 803 r PCSC establish context for PCSC reader 0
2010/10/22 20:07:43 400 s creating thread for device 1 slot 0
2010/10/22 20:07:43 C04 r reader thread started (thread= C04, device=1, detect=ring, mhz=357, cardmhz=36cool
2010/10/22 20:07:43 C04 r PCSC establish context for PCSC reader 1
2010/10/22 20:07:43 803 r PCSC reader 0: OmniKey CardMan 3121 00 00
2010/10/22 20:07:43 803 r PCSC reader 1: OmniKey CardMan 3121 01 00
2010/10/22 20:07:43 803 r PCSC reader 2: OmniKey CardMan 3121 02 00
2010/10/22 20:07:43 803 r PCSC reader 3: OmniKey CardMan 3121 03 00
2010/10/22 20:07:43 400 s waiting for local card init
2010/10/22 20:07:43 C04 r PCSC reader 0: OmniKey CardMan 3121 00 00
2010/10/22 20:07:43 C04 r PCSC reader 1: OmniKey CardMan 3121 01 00
2010/10/22 20:07:43 C04 r PCSC reader 2: OmniKey CardMan 3121 02 00
2010/10/22 20:07:43 C04 r PCSC reader 3: OmniKey CardMan 3121 03 00
2010/10/22 20:07:47 400 s init for all local cards done
2010/10/22 20:07:47 400 s anti cascading disabled

Last edited 13 years ago by roni261980 (previous) (diff)

comment:20 by av_jui, 13 years ago

Hi

I have all so the same problem. Me PCSC cardreader won´t work.

comment:21 by av_jui, 13 years ago

Resolution: fixed
Status: closedreopened

comment:22 by m@…, 13 years ago

I can confirm this problem exists since oscam 1.0 (threaded). My platform is Fedora Linux 13, I use two Omnikey 3121 USB readers (PCSC) and one Smargo (FTDI). When both PCSC readers are enabled oscam will not pass the "NEED INIT" status of the PCSC's and doesnt answer ANY client request. Last confirmed today with svn3795 x86 (builded myself)

comment:23 by roni261980, 13 years ago

Please,can anyone fix this bug?
thankyou

comment:24 by cybernando, 13 years ago

I can confirm bug is also in last version 3980 !!!!

There is a possibility to resolve it ???

here my log !!!

http://www.streamboard.tv:8001/ticket/1304

comment:25 by roni261980, 13 years ago

oscam dont work with 2 or more pcsc readers

anyone isn't able to fix this bug

comment:26 by LubosD, 13 years ago

Cc: lubos@… added

comment:27 by LubosD, 13 years ago

I've just tried it with two identical readers connected at once and both cards work correctly.

# opensc-tool -l
Readers known about:
Nr.    Driver     Name
0      pcsc       Alcor Micro AU9520 00 00
1      pcsc       Alcor Micro AU9520 01 00

I just put two [reader] sections into oscam.server with device = 0 and device = 1 respectively and it "just works". The readers are cheap "SCR 001" readers available on deal-cool.com and similar sites.

comment:28 by Deas, 13 years ago

when the problem is solved, CLOSE IT!

comment:29 by roni261980, 13 years ago

oscam dont work with 2 or more pcsc readers

i have four omnikey 3121
with one work fine
with two or more in pcscd log i see client die

Last edited 13 years ago by roni261980 (previous) (diff)

comment:30 by roni261980, 13 years ago

now work.oscam 4736 with pcscd 1.6.6 ccid 1.4.1 on ar71xx platform

the problem is solved, CLOSE IT!

comment:31 by lattjo, 13 years ago

Resolution: fixed
Status: reopenedclosed
Note: See TracTickets for help on using tickets.