EldoS | Feel safer!

Software components for data protection, secure storage and transfer

TElPKCSSlotEventEvent

Also by EldoS: Callback File System
Create virtual file systems and disks, expose and manage remote data as if they were files on the local disk.
#17713
Posted: 10/03/2011 05:38:39
by ingbabic  (Standard support level)
Joined: 09/27/2011
Posts: 114

Hello
I have problem with using TElPKCSSlotEventEvent. It doesn't gets fired when I put smard card in slot, or remove it. I have installed newest demo software from your site. Smart card reader is installed correctly (I can verify that thru using Token admin application from SafeSign).
#17714
Posted: 10/03/2011 05:43:28
by Vsevolod Ievgiienko (EldoS Corp.)

Thank you for contacting us.

You should also set TElPKCS11CertStorage.MonitorSlotEvents property value to 'true'.
#17715
Posted: 10/03/2011 05:53:47
by ingbabic  (Standard support level)
Joined: 09/27/2011
Posts: 114

Yes I have set it. What else can be a problem?
The same code works with following versions:
SecureBlackbox.dll 9.0.203.40591
SecureBlackbox.PKI.dll 9.0.203.40597

But does not work with this version:
SecureBlackbox.dll 9.0.203.40677
SecureBlackbox.PKI.dll 9.0.203.40682
#17716
Posted: 10/03/2011 06:03:06
by Ken Ivanov (EldoS Corp.)

Some tokens do not support asynchronous event reporting. Please try setting SlotEventMonitoringMode to semSynchronous, this should help.
#17717
Posted: 10/03/2011 06:03:11
by Eugene Mayevski (EldoS Corp.)

Try playing with SlotEventMonitoring* properties.

Also I am confused about build numbers - what are these assemblies? Are these assemblies of different flavors of .NET or why do they have the same 203 in version but different build numbers?


Sincerely yours
Eugene Mayevski
#17718
Posted: 10/03/2011 06:31:06
by ingbabic  (Standard support level)
Joined: 09/27/2011
Posts: 114

Setting SlotEventMonitoringMode to semSynchronous helped! Thanks a lot.

p.s. I had some previous installation of SecureBlackBox. When I tested it with that version it worked even without setting SlotEventMonitoringMode. With version that I downloaded from your site after I set SlotEventMonitoringMode to semSynchronous it worked again.

Best regards
#17740
Posted: 10/05/2011 08:27:28
by ingbabic  (Standard support level)
Joined: 09/27/2011
Posts: 114

Hello
Again me :). Another problem, connected to this SlotEventMonitoringMode. If I set it to semSynchronous, strange thing happen. If I after that sign document and then want to close program (meaning close session, storage and everything), program will never stop (I have to kill it from Visual studio - stop debug). If I just comment this line where I set SlotEventMonitoringMode, program terminates correctly.
What can I do now?
#17743
Posted: 10/05/2011 08:59:56
by Ken Ivanov (EldoS Corp.)

Could you please show us a piece of your code that you use to close the session and the storage? The storage is apparently not closed properly, so the monitoring thread remains active.
#17744
Posted: 10/05/2011 09:25:34
by ingbabic  (Standard support level)
Joined: 09/27/2011
Posts: 114

For closing storage I am using this function:

private void CloseStorage()
{
if (storage != null)
{
// disconnect from events;
storage.OnSlotEvent -= storage_OnSlotEvent;

storage.Close(); //close the PKCS#11 Storage
//FreeAndNil
storage.Dispose();
storage = null;
for (int i = 0; i < SBPKCS11Base.Unit.ModuleList.ModuleCount; i++)
{
SBPKCS11Base.Unit.ModuleList.UnloadModule(SBPKCS11Base.Unit.ModuleList.get_Modules(i));
}
}
}

Concerning session I open it and close it inside Sign method. Sequence for closing session is:

session.Logout();
session.Dispose();
session = null;

storage is class level and session is method level variable.

Thanks.
#17746
Posted: 10/05/2011 10:00:05
by ingbabic  (Standard support level)
Joined: 09/27/2011
Posts: 114

It was my bug :(
In one situation I opened storage two times, but closed it just once. Interesting is that thing about commenting line with SlotEventMonitoringMode, but never mind, I'm happy again. :)

Thank you very much again for your precious support.
Also by EldoS: CallbackFilter
A component to monitor and control disk activity, track file and directory operations (create, read, write, rename etc.), alter file data, encrypt files, create virtual files.

Reply

Statistics

Topic viewed 2058 times

Number of guests: 1, registered members: 0, in total hidden: 0




|

Back to top

As of July 15, 2016 EldoS Corporation will operate as a division of /n software inc. For more information, please read the announcement.

Got it!