Hello again,

We've made some progress with our tests. As it turns out, the main
problem was with the call to ENGINE_finish, which we eliminated from
our code for now.

Now we seem to be facing a new issue that comes up when a wrong PIN is
entered and then the card is removed from the reader. After that, we
can no longer do anything with the card after it is re-inserted. Not
even by cleaning and reloading all the ENGINE-related functions.

Would anyone have any hints on that? 

Thanks in advance

Cesar

On Wed, Mar 17, 2010 at 12:08:58PM -0700, John R Pierce wrote:
> Dr. Stephen Henson wrote:
> > On Wed, Mar 17, 2010, Cesar Henrique Keiti Kuroiwa wrote:
> >
> >   
> >> Hello
> >>
> >> We are trying to use the PKCS11 engine for OpenSSL to interface with a
> >> smart  card reader  "Gemplus GemPC  Twin 00  00". We  are  having some
> >> trouble  when trying  to retrieve  the private  from a  smart  card to
> >> decrypt some  data. The  problem arises when  the wrong PIN  number is
> >> given,  so that method  ENGINE_cleanup somehow  causes the  program to
> >> crash with a bus error.
> >>
> >> Below  is  a small  program  that reproduces  what  we  are trying  to
> >> do. We've tested this in FreeBSD 7.2 amd64 and Ubuntu 9.10 i386.
> >>
> >> Anyone would have any idea what is going on and how to solve it?
> >>
> >>     
> >
> > The PKCS#11 ENGINE is not a standard part of OpenSSL. I'd suggest asking in
> > some mailing list related to wherever you got it from.
> >   
> 
> 
> indeed, this gets really tricky.  you have 4+ layers interacting here..
> 
>     1) your application
>     2) openssl
>     3) engine_pkcs11 (presumably from the OpenSC project, 
> http://www.opensc-project.org/engine_pkcs11/)
>     4) your pkcs11 card drivers (either from gemplus or from openSC)
> 
> 
> 
> ______________________________________________________________________
> OpenSSL Project                                 http://www.openssl.org
> User Support Mailing List                    openssl-users@openssl.org
> Automated List Manager                           majord...@openssl.org
______________________________________________________________________
OpenSSL Project                                 http://www.openssl.org
User Support Mailing List                    openssl-users@openssl.org
Automated List Manager                           majord...@openssl.org

Reply via email to