marwensaid / eid-applet

Automatically exported from code.google.com/p/eid-applet
Other
1 stars 1 forks source link

connect() failed #22

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
What steps will reproduce the problem?

What is the expected output? What do you see instead?

Applet does not read the card.

What version of the product are you using? On what operating system?

Latest RC.

Please provide any additional information below.

We are beta testing a website, with the latest RC recompilated.

For some users, they are stuck on the applet asking them to introduce their
eID, even if the card is already inserted. And they can remove and put it
back it won't read the card.

The solution is to disconnect then reconnect the reader, and then the
applet does work without reloading.

Do you have any clue about this strange behavior? And how to improve this? 

Thanks in advance.

Original issue reported on code.google.com by sbuyss...@gmail.com on 6 Dec 2009 at 2:46

Attachments:

GoogleCodeExporter commented 9 years ago

Original comment by frank.co...@gmail.com on 11 Dec 2009 at 9:02

GoogleCodeExporter commented 9 years ago
I have been able to get more infos about this issue.

On this machine, the applet is executing:

    public boolean isEidPresent() throws CardException {

[...]

            if (cardTerminal.isCardPresent()) {
                Card card;
                try {
                    /*
                    /*
                     * eToken is not using T=0 apparently, hence the need for an
                     * explicit CardException catch
                     */
                    card = cardTerminal.connect("T=0");
                    /*
                     * The exclusive card lock in combination with reset at
                     * disconnect and some sleeps seems to fix the
                     * SCARD_E_SHARING_VIOLATION issue.
                     */
                    card.beginExclusive();
                } catch (CardException e) {
                    this.view.addDetailMessage("could not connect to card: "
                            + e.getMessage());
                    continue;
                }

[...]

It is entering the isCardPresent even with no card in the reader and then does 
not
return from the beginExclusive method.

I still believe there is a problem with the Middleware and I'm search for a 
clean way
to disable the usage of the middleware in the applet (remember Java is not my 
cup of
tea ;) ).

Or if you have an idea to fix this issue with the middleware, it might be worth 
too.

Original comment by sbuyss...@gmail.com on 25 Mar 2010 at 3:11

GoogleCodeExporter commented 9 years ago
Was related to the card removal fix.

Original comment by frank.co...@gmail.com on 19 Apr 2010 at 1:01